From f66381b967fc1c2bfb8bd9a73b7a5ab35ee9da6d Mon Sep 17 00:00:00 2001 From: Dmitry Vedenko Date: Fri, 21 May 2021 17:35:17 +0300 Subject: [PATCH] Removes previously vendored libraries from the source tree --- cmake-proxies/expat/CMakeLists.txt | 45 - cmake-proxies/lame/CMakeLists.txt | 89 - cmake-proxies/lame/config.h.in | 371 - cmake-proxies/libid3tag/CMakeLists.txt | 51 - cmake-proxies/libid3tag/config.h.in | 86 - cmake-proxies/libmad/CMakeLists.txt | 58 - cmake-proxies/libmad/config.h.in | 215 - cmake-proxies/libmad/mad.h.in | 15 - cmake-proxies/wxWidgets/CMakeLists.txt | 287 - lib-src/expat/CMake.README | 42 - lib-src/expat/CMakeLists.txt | 111 - lib-src/expat/COPYING | 22 - lib-src/expat/Changes | 205 - lib-src/expat/ConfigureChecks.cmake | 44 - lib-src/expat/MANIFEST | 141 - lib-src/expat/Makefile.in | 201 - lib-src/expat/README | 139 - lib-src/expat/amiga/Makefile | 336 - lib-src/expat/amiga/README.txt | 98 - lib-src/expat/amiga/expat.xml | 264 - lib-src/expat/amiga/expat_68k.c | 939 - lib-src/expat/amiga/expat_68k.h | 94 - lib-src/expat/amiga/expat_68k_handler_stubs.c | 185 - lib-src/expat/amiga/expat_base.h | 40 - lib-src/expat/amiga/expat_lib.c | 247 - lib-src/expat/amiga/expat_vectors.c | 505 - lib-src/expat/amiga/include/inline4/expat.h | 94 - .../expat/amiga/include/interfaces/expat.h | 98 - lib-src/expat/amiga/include/libraries/expat.h | 566 - lib-src/expat/amiga/include/proto/expat.h | 52 - lib-src/expat/amiga/launch.c | 57 - lib-src/expat/bcb5/README.txt | 87 - lib-src/expat/bcb5/all_projects.bpg | 49 - lib-src/expat/bcb5/elements.bpf | 4 - lib-src/expat/bcb5/elements.bpr | 149 - lib-src/expat/bcb5/elements.mak | 186 - lib-src/expat/bcb5/expat.bpf | 6 - lib-src/expat/bcb5/expat.bpr | 140 - lib-src/expat/bcb5/expat.mak | 187 - lib-src/expat/bcb5/expat_static.bpf | 5 - lib-src/expat/bcb5/expat_static.bpr | 143 - lib-src/expat/bcb5/expat_static.mak | 189 - lib-src/expat/bcb5/expatw.bpf | 6 - lib-src/expat/bcb5/expatw.bpr | 146 - lib-src/expat/bcb5/expatw.mak | 187 - lib-src/expat/bcb5/expatw_static.bpf | 5 - lib-src/expat/bcb5/expatw_static.bpr | 152 - lib-src/expat/bcb5/expatw_static.mak | 190 - lib-src/expat/bcb5/libexpat_mtd.def | 141 - lib-src/expat/bcb5/libexpatw_mtd.def | 140 - lib-src/expat/bcb5/makefile.mak | 37 - lib-src/expat/bcb5/outline.bpf | 4 - lib-src/expat/bcb5/outline.bpr | 132 - lib-src/expat/bcb5/outline.mak | 186 - lib-src/expat/bcb5/setup.bat | 9 - lib-src/expat/bcb5/xmlwf.bpf | 7 - lib-src/expat/bcb5/xmlwf.bpr | 136 - lib-src/expat/bcb5/xmlwf.mak | 187 - lib-src/expat/configure | 18668 ---------------- lib-src/expat/configure.in | 155 - lib-src/expat/conftools/PrintPath | 116 - .../expat/conftools/ac_c_bigendian_cross.m4 | 81 - lib-src/expat/conftools/config.guess | 1517 -- lib-src/expat/conftools/config.sub | 1760 -- lib-src/expat/conftools/expat.m4 | 43 - lib-src/expat/conftools/get-version.sh | 46 - lib-src/expat/conftools/install-sh | 520 - lib-src/expat/conftools/ltmain.sh | 9661 -------- lib-src/expat/conftools/mkinstalldirs | 40 - lib-src/expat/doc/expat.png | Bin 1027 -> 0 bytes lib-src/expat/doc/reference.html | 2390 -- lib-src/expat/doc/style.css | 101 - lib-src/expat/doc/valid-xhtml10.png | Bin 2368 -> 0 bytes lib-src/expat/doc/xmlwf.1 | 251 - lib-src/expat/doc/xmlwf.sgml | 468 - lib-src/expat/examples/elements.c | 65 - lib-src/expat/examples/elements.dsp | 103 - lib-src/expat/examples/outline.c | 106 - lib-src/expat/examples/outline.dsp | 103 - lib-src/expat/expat.dsw | 110 - lib-src/expat/expat.pc.in | 11 - lib-src/expat/expat_config.h.cmake | 91 - lib-src/expat/expat_config.h.in | 102 - lib-src/expat/lib/Makefile.MPW | 206 - lib-src/expat/lib/amigaconfig.h | 32 - lib-src/expat/lib/ascii.h | 92 - lib-src/expat/lib/asciitab.h | 36 - lib-src/expat/lib/expat.dsp | 185 - lib-src/expat/lib/expat.h | 1047 - lib-src/expat/lib/expat_external.h | 115 - lib-src/expat/lib/expat_static.dsp | 162 - lib-src/expat/lib/expatw.dsp | 185 - lib-src/expat/lib/expatw_static.dsp | 162 - lib-src/expat/lib/iasciitab.h | 37 - lib-src/expat/lib/internal.h | 73 - lib-src/expat/lib/latin1tab.h | 36 - lib-src/expat/lib/libexpat.def | 73 - lib-src/expat/lib/libexpatw.def | 73 - lib-src/expat/lib/macconfig.h | 53 - lib-src/expat/lib/nametab.h | 150 - lib-src/expat/lib/utf8tab.h | 37 - lib-src/expat/lib/winconfig.h | 30 - lib-src/expat/lib/xmlparse.c | 6403 ------ lib-src/expat/lib/xmlrole.c | 1336 -- lib-src/expat/lib/xmlrole.h | 114 - lib-src/expat/lib/xmltok.c | 1651 -- lib-src/expat/lib/xmltok.h | 316 - lib-src/expat/lib/xmltok_impl.c | 1783 -- lib-src/expat/lib/xmltok_impl.h | 46 - lib-src/expat/lib/xmltok_ns.c | 115 - lib-src/expat/m4/libtool.m4 | 7997 ------- lib-src/expat/m4/ltoptions.m4 | 384 - lib-src/expat/m4/ltsugar.m4 | 123 - lib-src/expat/m4/ltversion.m4 | 23 - lib-src/expat/m4/lt~obsolete.m4 | 98 - lib-src/expat/tests/README.txt | 13 - lib-src/expat/tests/benchmark/README.txt | 16 - lib-src/expat/tests/benchmark/benchmark.c | 114 - lib-src/expat/tests/benchmark/benchmark.dsp | 88 - lib-src/expat/tests/benchmark/benchmark.dsw | 44 - lib-src/expat/tests/chardata.c | 131 - lib-src/expat/tests/chardata.h | 40 - lib-src/expat/tests/minicheck.c | 182 - lib-src/expat/tests/minicheck.h | 90 - lib-src/expat/tests/runtests.c | 1515 -- lib-src/expat/tests/runtestspp.cpp | 6 - lib-src/expat/tests/xmltest.sh | 142 - lib-src/expat/vms/README.vms | 23 - lib-src/expat/vms/descrip.mms | 70 - lib-src/expat/vms/expat_config.h | 52 - lib-src/expat/win32/MANIFEST.txt | 27 - lib-src/expat/win32/README.txt | 80 - lib-src/expat/win32/expat.iss | 69 - lib-src/expat/xmlwf/codepage.c | 68 - lib-src/expat/xmlwf/codepage.h | 6 - lib-src/expat/xmlwf/ct.c | 147 - lib-src/expat/xmlwf/filemap.h | 17 - lib-src/expat/xmlwf/readfilemap.c | 100 - lib-src/expat/xmlwf/unixfilemap.c | 65 - lib-src/expat/xmlwf/win32filemap.c | 96 - lib-src/expat/xmlwf/xmlfile.c | 244 - lib-src/expat/xmlwf/xmlfile.h | 20 - lib-src/expat/xmlwf/xmlmime.c | 163 - lib-src/expat/xmlwf/xmlmime.h | 19 - lib-src/expat/xmlwf/xmltchar.h | 36 - lib-src/expat/xmlwf/xmlurl.h | 13 - lib-src/expat/xmlwf/xmlwf.c | 861 - lib-src/expat/xmlwf/xmlwf.dsp | 139 - lib-src/expat/xmlwf/xmlwin32url.cxx | 395 - lib-src/lame/lame/lame.h | 1342 -- lib-src/lame/libmp3lame/Makefile.am | 102 - lib-src/lame/libmp3lame/Makefile.in | 904 - lib-src/lame/libmp3lame/VbrTag.c | 1082 - lib-src/lame/libmp3lame/VbrTag.h | 79 - lib-src/lame/libmp3lame/bitstream.c | 1111 - lib-src/lame/libmp3lame/bitstream.h | 40 - lib-src/lame/libmp3lame/depcomp | 791 - lib-src/lame/libmp3lame/encoder.c | 574 - lib-src/lame/libmp3lame/encoder.h | 156 - lib-src/lame/libmp3lame/fft.c | 339 - lib-src/lame/libmp3lame/fft.h | 35 - lib-src/lame/libmp3lame/gain_analysis.c | 476 - lib-src/lame/libmp3lame/gain_analysis.h | 109 - lib-src/lame/libmp3lame/i386/Makefile.am | 73 - lib-src/lame/libmp3lame/i386/Makefile.in | 633 - lib-src/lame/libmp3lame/i386/choose_table.nas | 447 - lib-src/lame/libmp3lame/i386/cpu_feat.nas | 107 - lib-src/lame/libmp3lame/i386/fft.nas | 267 - lib-src/lame/libmp3lame/i386/fft3dn.nas | 488 - lib-src/lame/libmp3lame/i386/fftfpu.nas | 619 - lib-src/lame/libmp3lame/i386/fftsse.nas | 422 - lib-src/lame/libmp3lame/i386/ffttbl.nas | 78 - lib-src/lame/libmp3lame/i386/nasm.h | 268 - lib-src/lame/libmp3lame/i386/scalar.nas | 1022 - lib-src/lame/libmp3lame/id3tag.c | 1926 -- lib-src/lame/libmp3lame/id3tag.h | 64 - lib-src/lame/libmp3lame/l3side.h | 95 - lib-src/lame/libmp3lame/lame-analysis.h | 96 - lib-src/lame/libmp3lame/lame.c | 2665 --- lib-src/lame/libmp3lame/lame.rc | 50 - lib-src/lame/libmp3lame/lame_global_flags.h | 184 - lib-src/lame/libmp3lame/lameerror.h | 26 - lib-src/lame/libmp3lame/logoe.ico | Bin 51262 -> 0 bytes lib-src/lame/libmp3lame/machine.h | 189 - lib-src/lame/libmp3lame/mpglib_interface.c | 477 - lib-src/lame/libmp3lame/newmdct.c | 1039 - lib-src/lame/libmp3lame/newmdct.h | 27 - lib-src/lame/libmp3lame/presets.c | 404 - lib-src/lame/libmp3lame/psymodel.c | 2167 -- lib-src/lame/libmp3lame/psymodel.h | 64 - lib-src/lame/libmp3lame/quantize.c | 2050 -- lib-src/lame/libmp3lame/quantize.h | 38 - lib-src/lame/libmp3lame/quantize_pvt.c | 1074 - lib-src/lame/libmp3lame/quantize_pvt.h | 128 - lib-src/lame/libmp3lame/reservoir.c | 293 - lib-src/lame/libmp3lame/reservoir.h | 31 - lib-src/lame/libmp3lame/set_get.c | 2346 -- lib-src/lame/libmp3lame/set_get.h | 76 - lib-src/lame/libmp3lame/tables.c | 564 - lib-src/lame/libmp3lame/tables.h | 95 - lib-src/lame/libmp3lame/takehiro.c | 1375 -- lib-src/lame/libmp3lame/util.c | 1018 - lib-src/lame/libmp3lame/util.h | 616 - lib-src/lame/libmp3lame/vbrquantize.c | 1580 -- lib-src/lame/libmp3lame/vbrquantize.h | 28 - lib-src/lame/libmp3lame/vector/Makefile.am | 49 - lib-src/lame/libmp3lame/vector/Makefile.in | 656 - lib-src/lame/libmp3lame/vector/lame_intrin.h | 33 - .../lame/libmp3lame/vector/xmm_quantize_sub.c | 240 - lib-src/lame/libmp3lame/version.c | 254 - lib-src/lame/libmp3lame/version.h | 68 - lib-src/libid3tag/CHANGES | 83 - lib-src/libid3tag/COPYING | 340 - lib-src/libid3tag/COPYRIGHT | 21 - lib-src/libid3tag/CREDITS | 28 - lib-src/libid3tag/INSTALL | 183 - lib-src/libid3tag/Makefile.am | 126 - lib-src/libid3tag/Makefile.in | 1048 - lib-src/libid3tag/README | 102 - lib-src/libid3tag/TODO | 12 - lib-src/libid3tag/VERSION | 6 - lib-src/libid3tag/compat.c | 506 - lib-src/libid3tag/compat.gperf | 297 - lib-src/libid3tag/compat.h | 41 - lib-src/libid3tag/compile | 347 - lib-src/libid3tag/config.guess | 1558 -- lib-src/libid3tag/config.h.in | 86 - lib-src/libid3tag/config.sub | 1791 -- lib-src/libid3tag/configure | 14425 ------------ lib-src/libid3tag/configure.ac | 209 - lib-src/libid3tag/crc.c | 137 - lib-src/libid3tag/crc.h | 29 - lib-src/libid3tag/debug.c | 222 - lib-src/libid3tag/debug.h | 34 - lib-src/libid3tag/depcomp | 791 - lib-src/libid3tag/field.c | 890 - lib-src/libid3tag/field.h | 36 - lib-src/libid3tag/file.c | 674 - lib-src/libid3tag/file.h | 25 - lib-src/libid3tag/frame.c | 634 - lib-src/libid3tag/frame.h | 36 - lib-src/libid3tag/frametype.c | 571 - lib-src/libid3tag/frametype.gperf | 363 - lib-src/libid3tag/frametype.h | 42 - lib-src/libid3tag/genre.c | 151 - lib-src/libid3tag/genre.dat | 480 - lib-src/libid3tag/genre.dat.in | 180 - lib-src/libid3tag/genre.dat.sed | 54 - lib-src/libid3tag/genre.h | 27 - lib-src/libid3tag/global.h | 53 - lib-src/libid3tag/id3tag.h | 367 - lib-src/libid3tag/install-sh | 527 - lib-src/libid3tag/latin1.c | 217 - lib-src/libid3tag/latin1.h | 45 - lib-src/libid3tag/libid3tag-srcdir.patch | 150 - lib-src/libid3tag/libid3tag.list.in | 21 - lib-src/libid3tag/libid3tag.vcproj | 1971 -- lib-src/libid3tag/ltconfig | 3017 --- lib-src/libid3tag/ltmain.sh | 9661 -------- lib-src/libid3tag/m4/libtool.m4 | 7997 ------- lib-src/libid3tag/m4/ltoptions.m4 | 384 - lib-src/libid3tag/m4/ltsugar.m4 | 123 - lib-src/libid3tag/m4/ltversion.m4 | 23 - lib-src/libid3tag/m4/lt~obsolete.m4 | 98 - lib-src/libid3tag/missing | 215 - lib-src/libid3tag/mkinstalldirs | 162 - lib-src/libid3tag/msvc++/Makefile.am | 24 - lib-src/libid3tag/msvc++/Makefile.in | 425 - lib-src/libid3tag/msvc++/config.h | 78 - lib-src/libid3tag/msvc++/libid3tag.dsp | 250 - lib-src/libid3tag/parse.c | 196 - lib-src/libid3tag/parse.h | 34 - lib-src/libid3tag/render.c | 200 - lib-src/libid3tag/render.h | 40 - lib-src/libid3tag/stamp-h.in | 1 - lib-src/libid3tag/tag.c | 1061 - lib-src/libid3tag/tag.h | 30 - lib-src/libid3tag/ucs4.c | 224 - lib-src/libid3tag/ucs4.h | 41 - lib-src/libid3tag/utf16.c | 327 - lib-src/libid3tag/utf16.h | 51 - lib-src/libid3tag/utf8.c | 365 - lib-src/libid3tag/utf8.h | 42 - lib-src/libid3tag/util.c | 147 - lib-src/libid3tag/util.h | 35 - lib-src/libid3tag/version.c | 45 - lib-src/libid3tag/version.h | 25 - lib-src/libmad/CHANGES | 338 - lib-src/libmad/COPYING | 340 - lib-src/libmad/COPYRIGHT | 21 - lib-src/libmad/CREDITS | 116 - lib-src/libmad/D.dat | 607 - lib-src/libmad/INSTALL | 183 - lib-src/libmad/Makefile.am | 140 - lib-src/libmad/Makefile.in | 1095 - lib-src/libmad/README | 241 - lib-src/libmad/TODO | 69 - lib-src/libmad/VERSION | 7 - lib-src/libmad/acconfig.h | 63 - lib-src/libmad/bit.c | 237 - lib-src/libmad/bit.h | 47 - lib-src/libmad/compile | 347 - lib-src/libmad/config.guess | 1558 -- lib-src/libmad/config.h.in | 214 - lib-src/libmad/config.sub | 1791 -- lib-src/libmad/configunix.h.in | 159 - lib-src/libmad/configure | 15382 ------------- lib-src/libmad/configure.ac | 435 - lib-src/libmad/decoder.c | 582 - lib-src/libmad/decoder.h | 91 - lib-src/libmad/depcomp | 791 - lib-src/libmad/fixed.c | 81 - lib-src/libmad/fixed.h | 499 - lib-src/libmad/frame.c | 503 - lib-src/libmad/frame.h | 118 - lib-src/libmad/global.h | 58 - lib-src/libmad/huffman.c | 3109 --- lib-src/libmad/huffman.h | 66 - lib-src/libmad/imdct_l_arm.S | 1000 - lib-src/libmad/imdct_s.dat | 62 - lib-src/libmad/install-sh | 527 - lib-src/libmad/layer12.c | 536 - lib-src/libmad/layer12.h | 31 - lib-src/libmad/layer3.c | 2703 --- lib-src/libmad/layer3.h | 30 - lib-src/libmad/libmad-mp2-out-of-spec.patch | 27 - lib-src/libmad/libmad.list.in | 21 - lib-src/libmad/libmad.vcproj | 1479 -- lib-src/libmad/ltmain.sh | 9661 -------- lib-src/libmad/mad.h.sed | 36 - lib-src/libmad/minimad.c | 222 - lib-src/libmad/missing | 215 - lib-src/libmad/mkinstalldirs | 162 - lib-src/libmad/msvc++/Makefile.am | 24 - lib-src/libmad/msvc++/Makefile.in | 428 - lib-src/libmad/msvc++/config.h | 130 - lib-src/libmad/msvc++/libmad.dsp | 214 - lib-src/libmad/msvc++/mad.h | 948 - lib-src/libmad/osx-universal-build.patch | 25 - lib-src/libmad/qc_table.dat | 77 - lib-src/libmad/rq_table.dat | 8747 -------- lib-src/libmad/sf_table.dat | 106 - lib-src/libmad/stamp-h.in | 1 - lib-src/libmad/stream.c | 161 - lib-src/libmad/stream.h | 108 - lib-src/libmad/synth.c | 857 - lib-src/libmad/synth.h | 69 - lib-src/libmad/timer.c | 485 - lib-src/libmad/timer.h | 100 - lib-src/libmad/version.c | 91 - lib-src/libmad/version.h | 47 - 351 files changed, 220803 deletions(-) delete mode 100644 cmake-proxies/expat/CMakeLists.txt delete mode 100644 cmake-proxies/lame/CMakeLists.txt delete mode 100644 cmake-proxies/lame/config.h.in delete mode 100644 cmake-proxies/libid3tag/CMakeLists.txt delete mode 100644 cmake-proxies/libid3tag/config.h.in delete mode 100644 cmake-proxies/libmad/CMakeLists.txt delete mode 100644 cmake-proxies/libmad/config.h.in delete mode 100755 cmake-proxies/libmad/mad.h.in delete mode 100644 cmake-proxies/wxWidgets/CMakeLists.txt delete mode 100755 lib-src/expat/CMake.README delete mode 100755 lib-src/expat/CMakeLists.txt delete mode 100644 lib-src/expat/COPYING delete mode 100644 lib-src/expat/Changes delete mode 100755 lib-src/expat/ConfigureChecks.cmake delete mode 100644 lib-src/expat/MANIFEST delete mode 100644 lib-src/expat/Makefile.in delete mode 100644 lib-src/expat/README delete mode 100644 lib-src/expat/amiga/Makefile delete mode 100644 lib-src/expat/amiga/README.txt delete mode 100644 lib-src/expat/amiga/expat.xml delete mode 100644 lib-src/expat/amiga/expat_68k.c delete mode 100755 lib-src/expat/amiga/expat_68k.h delete mode 100755 lib-src/expat/amiga/expat_68k_handler_stubs.c delete mode 100644 lib-src/expat/amiga/expat_base.h delete mode 100755 lib-src/expat/amiga/expat_lib.c delete mode 100644 lib-src/expat/amiga/expat_vectors.c delete mode 100644 lib-src/expat/amiga/include/inline4/expat.h delete mode 100644 lib-src/expat/amiga/include/interfaces/expat.h delete mode 100644 lib-src/expat/amiga/include/libraries/expat.h delete mode 100644 lib-src/expat/amiga/include/proto/expat.h delete mode 100755 lib-src/expat/amiga/launch.c delete mode 100644 lib-src/expat/bcb5/README.txt delete mode 100644 lib-src/expat/bcb5/all_projects.bpg delete mode 100644 lib-src/expat/bcb5/elements.bpf delete mode 100644 lib-src/expat/bcb5/elements.bpr delete mode 100644 lib-src/expat/bcb5/elements.mak delete mode 100644 lib-src/expat/bcb5/expat.bpf delete mode 100644 lib-src/expat/bcb5/expat.bpr delete mode 100644 lib-src/expat/bcb5/expat.mak delete mode 100644 lib-src/expat/bcb5/expat_static.bpf delete mode 100644 lib-src/expat/bcb5/expat_static.bpr delete mode 100644 lib-src/expat/bcb5/expat_static.mak delete mode 100644 lib-src/expat/bcb5/expatw.bpf delete mode 100644 lib-src/expat/bcb5/expatw.bpr delete mode 100644 lib-src/expat/bcb5/expatw.mak delete mode 100644 lib-src/expat/bcb5/expatw_static.bpf delete mode 100644 lib-src/expat/bcb5/expatw_static.bpr delete mode 100644 lib-src/expat/bcb5/expatw_static.mak delete mode 100644 lib-src/expat/bcb5/libexpat_mtd.def delete mode 100644 lib-src/expat/bcb5/libexpatw_mtd.def delete mode 100644 lib-src/expat/bcb5/makefile.mak delete mode 100644 lib-src/expat/bcb5/outline.bpf delete mode 100644 lib-src/expat/bcb5/outline.bpr delete mode 100644 lib-src/expat/bcb5/outline.mak delete mode 100644 lib-src/expat/bcb5/setup.bat delete mode 100644 lib-src/expat/bcb5/xmlwf.bpf delete mode 100644 lib-src/expat/bcb5/xmlwf.bpr delete mode 100644 lib-src/expat/bcb5/xmlwf.mak delete mode 100755 lib-src/expat/configure delete mode 100644 lib-src/expat/configure.in delete mode 100755 lib-src/expat/conftools/PrintPath delete mode 100644 lib-src/expat/conftools/ac_c_bigendian_cross.m4 delete mode 100755 lib-src/expat/conftools/config.guess delete mode 100755 lib-src/expat/conftools/config.sub delete mode 100644 lib-src/expat/conftools/expat.m4 delete mode 100755 lib-src/expat/conftools/get-version.sh delete mode 100755 lib-src/expat/conftools/install-sh delete mode 100755 lib-src/expat/conftools/ltmain.sh delete mode 100755 lib-src/expat/conftools/mkinstalldirs delete mode 100644 lib-src/expat/doc/expat.png delete mode 100644 lib-src/expat/doc/reference.html delete mode 100644 lib-src/expat/doc/style.css delete mode 100644 lib-src/expat/doc/valid-xhtml10.png delete mode 100644 lib-src/expat/doc/xmlwf.1 delete mode 100644 lib-src/expat/doc/xmlwf.sgml delete mode 100644 lib-src/expat/examples/elements.c delete mode 100644 lib-src/expat/examples/elements.dsp delete mode 100644 lib-src/expat/examples/outline.c delete mode 100644 lib-src/expat/examples/outline.dsp delete mode 100755 lib-src/expat/expat.dsw delete mode 100644 lib-src/expat/expat.pc.in delete mode 100755 lib-src/expat/expat_config.h.cmake delete mode 100644 lib-src/expat/expat_config.h.in delete mode 100644 lib-src/expat/lib/Makefile.MPW delete mode 100644 lib-src/expat/lib/amigaconfig.h delete mode 100644 lib-src/expat/lib/ascii.h delete mode 100644 lib-src/expat/lib/asciitab.h delete mode 100644 lib-src/expat/lib/expat.dsp delete mode 100644 lib-src/expat/lib/expat.h delete mode 100644 lib-src/expat/lib/expat_external.h delete mode 100644 lib-src/expat/lib/expat_static.dsp delete mode 100644 lib-src/expat/lib/expatw.dsp delete mode 100644 lib-src/expat/lib/expatw_static.dsp delete mode 100644 lib-src/expat/lib/iasciitab.h delete mode 100644 lib-src/expat/lib/internal.h delete mode 100644 lib-src/expat/lib/latin1tab.h delete mode 100644 lib-src/expat/lib/libexpat.def delete mode 100644 lib-src/expat/lib/libexpatw.def delete mode 100644 lib-src/expat/lib/macconfig.h delete mode 100644 lib-src/expat/lib/nametab.h delete mode 100644 lib-src/expat/lib/utf8tab.h delete mode 100644 lib-src/expat/lib/winconfig.h delete mode 100644 lib-src/expat/lib/xmlparse.c delete mode 100644 lib-src/expat/lib/xmlrole.c delete mode 100644 lib-src/expat/lib/xmlrole.h delete mode 100644 lib-src/expat/lib/xmltok.c delete mode 100644 lib-src/expat/lib/xmltok.h delete mode 100644 lib-src/expat/lib/xmltok_impl.c delete mode 100644 lib-src/expat/lib/xmltok_impl.h delete mode 100644 lib-src/expat/lib/xmltok_ns.c delete mode 100644 lib-src/expat/m4/libtool.m4 delete mode 100644 lib-src/expat/m4/ltoptions.m4 delete mode 100644 lib-src/expat/m4/ltsugar.m4 delete mode 100644 lib-src/expat/m4/ltversion.m4 delete mode 100644 lib-src/expat/m4/lt~obsolete.m4 delete mode 100644 lib-src/expat/tests/README.txt delete mode 100644 lib-src/expat/tests/benchmark/README.txt delete mode 100644 lib-src/expat/tests/benchmark/benchmark.c delete mode 100644 lib-src/expat/tests/benchmark/benchmark.dsp delete mode 100644 lib-src/expat/tests/benchmark/benchmark.dsw delete mode 100644 lib-src/expat/tests/chardata.c delete mode 100644 lib-src/expat/tests/chardata.h delete mode 100644 lib-src/expat/tests/minicheck.c delete mode 100644 lib-src/expat/tests/minicheck.h delete mode 100644 lib-src/expat/tests/runtests.c delete mode 100644 lib-src/expat/tests/runtestspp.cpp delete mode 100755 lib-src/expat/tests/xmltest.sh delete mode 100644 lib-src/expat/vms/README.vms delete mode 100644 lib-src/expat/vms/descrip.mms delete mode 100644 lib-src/expat/vms/expat_config.h delete mode 100644 lib-src/expat/win32/MANIFEST.txt delete mode 100644 lib-src/expat/win32/README.txt delete mode 100644 lib-src/expat/win32/expat.iss delete mode 100755 lib-src/expat/xmlwf/codepage.c delete mode 100755 lib-src/expat/xmlwf/codepage.h delete mode 100755 lib-src/expat/xmlwf/ct.c delete mode 100755 lib-src/expat/xmlwf/filemap.h delete mode 100755 lib-src/expat/xmlwf/readfilemap.c delete mode 100755 lib-src/expat/xmlwf/unixfilemap.c delete mode 100755 lib-src/expat/xmlwf/win32filemap.c delete mode 100755 lib-src/expat/xmlwf/xmlfile.c delete mode 100755 lib-src/expat/xmlwf/xmlfile.h delete mode 100755 lib-src/expat/xmlwf/xmlmime.c delete mode 100755 lib-src/expat/xmlwf/xmlmime.h delete mode 100755 lib-src/expat/xmlwf/xmltchar.h delete mode 100755 lib-src/expat/xmlwf/xmlurl.h delete mode 100755 lib-src/expat/xmlwf/xmlwf.c delete mode 100755 lib-src/expat/xmlwf/xmlwf.dsp delete mode 100755 lib-src/expat/xmlwf/xmlwin32url.cxx delete mode 100644 lib-src/lame/lame/lame.h delete mode 100644 lib-src/lame/libmp3lame/Makefile.am delete mode 100644 lib-src/lame/libmp3lame/Makefile.in delete mode 100644 lib-src/lame/libmp3lame/VbrTag.c delete mode 100644 lib-src/lame/libmp3lame/VbrTag.h delete mode 100644 lib-src/lame/libmp3lame/bitstream.c delete mode 100644 lib-src/lame/libmp3lame/bitstream.h delete mode 100644 lib-src/lame/libmp3lame/depcomp delete mode 100644 lib-src/lame/libmp3lame/encoder.c delete mode 100644 lib-src/lame/libmp3lame/encoder.h delete mode 100644 lib-src/lame/libmp3lame/fft.c delete mode 100644 lib-src/lame/libmp3lame/fft.h delete mode 100644 lib-src/lame/libmp3lame/gain_analysis.c delete mode 100644 lib-src/lame/libmp3lame/gain_analysis.h delete mode 100644 lib-src/lame/libmp3lame/i386/Makefile.am delete mode 100644 lib-src/lame/libmp3lame/i386/Makefile.in delete mode 100644 lib-src/lame/libmp3lame/i386/choose_table.nas delete mode 100644 lib-src/lame/libmp3lame/i386/cpu_feat.nas delete mode 100644 lib-src/lame/libmp3lame/i386/fft.nas delete mode 100644 lib-src/lame/libmp3lame/i386/fft3dn.nas delete mode 100644 lib-src/lame/libmp3lame/i386/fftfpu.nas delete mode 100644 lib-src/lame/libmp3lame/i386/fftsse.nas delete mode 100644 lib-src/lame/libmp3lame/i386/ffttbl.nas delete mode 100644 lib-src/lame/libmp3lame/i386/nasm.h delete mode 100644 lib-src/lame/libmp3lame/i386/scalar.nas delete mode 100644 lib-src/lame/libmp3lame/id3tag.c delete mode 100644 lib-src/lame/libmp3lame/id3tag.h delete mode 100644 lib-src/lame/libmp3lame/l3side.h delete mode 100644 lib-src/lame/libmp3lame/lame-analysis.h delete mode 100644 lib-src/lame/libmp3lame/lame.c delete mode 100644 lib-src/lame/libmp3lame/lame.rc delete mode 100644 lib-src/lame/libmp3lame/lame_global_flags.h delete mode 100644 lib-src/lame/libmp3lame/lameerror.h delete mode 100644 lib-src/lame/libmp3lame/logoe.ico delete mode 100644 lib-src/lame/libmp3lame/machine.h delete mode 100644 lib-src/lame/libmp3lame/mpglib_interface.c delete mode 100644 lib-src/lame/libmp3lame/newmdct.c delete mode 100644 lib-src/lame/libmp3lame/newmdct.h delete mode 100644 lib-src/lame/libmp3lame/presets.c delete mode 100644 lib-src/lame/libmp3lame/psymodel.c delete mode 100644 lib-src/lame/libmp3lame/psymodel.h delete mode 100644 lib-src/lame/libmp3lame/quantize.c delete mode 100644 lib-src/lame/libmp3lame/quantize.h delete mode 100644 lib-src/lame/libmp3lame/quantize_pvt.c delete mode 100644 lib-src/lame/libmp3lame/quantize_pvt.h delete mode 100644 lib-src/lame/libmp3lame/reservoir.c delete mode 100644 lib-src/lame/libmp3lame/reservoir.h delete mode 100644 lib-src/lame/libmp3lame/set_get.c delete mode 100644 lib-src/lame/libmp3lame/set_get.h delete mode 100644 lib-src/lame/libmp3lame/tables.c delete mode 100644 lib-src/lame/libmp3lame/tables.h delete mode 100644 lib-src/lame/libmp3lame/takehiro.c delete mode 100644 lib-src/lame/libmp3lame/util.c delete mode 100644 lib-src/lame/libmp3lame/util.h delete mode 100644 lib-src/lame/libmp3lame/vbrquantize.c delete mode 100644 lib-src/lame/libmp3lame/vbrquantize.h delete mode 100644 lib-src/lame/libmp3lame/vector/Makefile.am delete mode 100644 lib-src/lame/libmp3lame/vector/Makefile.in delete mode 100644 lib-src/lame/libmp3lame/vector/lame_intrin.h delete mode 100644 lib-src/lame/libmp3lame/vector/xmm_quantize_sub.c delete mode 100644 lib-src/lame/libmp3lame/version.c delete mode 100644 lib-src/lame/libmp3lame/version.h delete mode 100644 lib-src/libid3tag/CHANGES delete mode 100644 lib-src/libid3tag/COPYING delete mode 100644 lib-src/libid3tag/COPYRIGHT delete mode 100644 lib-src/libid3tag/CREDITS delete mode 100644 lib-src/libid3tag/INSTALL delete mode 100644 lib-src/libid3tag/Makefile.am delete mode 100644 lib-src/libid3tag/Makefile.in delete mode 100644 lib-src/libid3tag/README delete mode 100644 lib-src/libid3tag/TODO delete mode 100644 lib-src/libid3tag/VERSION delete mode 100644 lib-src/libid3tag/compat.c delete mode 100644 lib-src/libid3tag/compat.gperf delete mode 100644 lib-src/libid3tag/compat.h delete mode 100755 lib-src/libid3tag/compile delete mode 100755 lib-src/libid3tag/config.guess delete mode 100644 lib-src/libid3tag/config.h.in delete mode 100755 lib-src/libid3tag/config.sub delete mode 100755 lib-src/libid3tag/configure delete mode 100644 lib-src/libid3tag/configure.ac delete mode 100644 lib-src/libid3tag/crc.c delete mode 100644 lib-src/libid3tag/crc.h delete mode 100644 lib-src/libid3tag/debug.c delete mode 100644 lib-src/libid3tag/debug.h delete mode 100755 lib-src/libid3tag/depcomp delete mode 100644 lib-src/libid3tag/field.c delete mode 100644 lib-src/libid3tag/field.h delete mode 100644 lib-src/libid3tag/file.c delete mode 100644 lib-src/libid3tag/file.h delete mode 100644 lib-src/libid3tag/frame.c delete mode 100644 lib-src/libid3tag/frame.h delete mode 100644 lib-src/libid3tag/frametype.c delete mode 100644 lib-src/libid3tag/frametype.gperf delete mode 100644 lib-src/libid3tag/frametype.h delete mode 100644 lib-src/libid3tag/genre.c delete mode 100644 lib-src/libid3tag/genre.dat delete mode 100644 lib-src/libid3tag/genre.dat.in delete mode 100644 lib-src/libid3tag/genre.dat.sed delete mode 100644 lib-src/libid3tag/genre.h delete mode 100644 lib-src/libid3tag/global.h delete mode 100644 lib-src/libid3tag/id3tag.h delete mode 100755 lib-src/libid3tag/install-sh delete mode 100644 lib-src/libid3tag/latin1.c delete mode 100644 lib-src/libid3tag/latin1.h delete mode 100644 lib-src/libid3tag/libid3tag-srcdir.patch delete mode 100644 lib-src/libid3tag/libid3tag.list.in delete mode 100644 lib-src/libid3tag/libid3tag.vcproj delete mode 100755 lib-src/libid3tag/ltconfig delete mode 100644 lib-src/libid3tag/ltmain.sh delete mode 100644 lib-src/libid3tag/m4/libtool.m4 delete mode 100644 lib-src/libid3tag/m4/ltoptions.m4 delete mode 100644 lib-src/libid3tag/m4/ltsugar.m4 delete mode 100644 lib-src/libid3tag/m4/ltversion.m4 delete mode 100644 lib-src/libid3tag/m4/lt~obsolete.m4 delete mode 100755 lib-src/libid3tag/missing delete mode 100755 lib-src/libid3tag/mkinstalldirs delete mode 100644 lib-src/libid3tag/msvc++/Makefile.am delete mode 100644 lib-src/libid3tag/msvc++/Makefile.in delete mode 100644 lib-src/libid3tag/msvc++/config.h delete mode 100644 lib-src/libid3tag/msvc++/libid3tag.dsp delete mode 100644 lib-src/libid3tag/parse.c delete mode 100644 lib-src/libid3tag/parse.h delete mode 100644 lib-src/libid3tag/render.c delete mode 100644 lib-src/libid3tag/render.h delete mode 100644 lib-src/libid3tag/stamp-h.in delete mode 100644 lib-src/libid3tag/tag.c delete mode 100644 lib-src/libid3tag/tag.h delete mode 100644 lib-src/libid3tag/ucs4.c delete mode 100644 lib-src/libid3tag/ucs4.h delete mode 100644 lib-src/libid3tag/utf16.c delete mode 100644 lib-src/libid3tag/utf16.h delete mode 100644 lib-src/libid3tag/utf8.c delete mode 100644 lib-src/libid3tag/utf8.h delete mode 100644 lib-src/libid3tag/util.c delete mode 100644 lib-src/libid3tag/util.h delete mode 100644 lib-src/libid3tag/version.c delete mode 100644 lib-src/libid3tag/version.h delete mode 100644 lib-src/libmad/CHANGES delete mode 100644 lib-src/libmad/COPYING delete mode 100644 lib-src/libmad/COPYRIGHT delete mode 100644 lib-src/libmad/CREDITS delete mode 100644 lib-src/libmad/D.dat delete mode 100644 lib-src/libmad/INSTALL delete mode 100644 lib-src/libmad/Makefile.am delete mode 100644 lib-src/libmad/Makefile.in delete mode 100644 lib-src/libmad/README delete mode 100644 lib-src/libmad/TODO delete mode 100644 lib-src/libmad/VERSION delete mode 100644 lib-src/libmad/acconfig.h delete mode 100644 lib-src/libmad/bit.c delete mode 100644 lib-src/libmad/bit.h delete mode 100755 lib-src/libmad/compile delete mode 100755 lib-src/libmad/config.guess delete mode 100644 lib-src/libmad/config.h.in delete mode 100755 lib-src/libmad/config.sub delete mode 100644 lib-src/libmad/configunix.h.in delete mode 100755 lib-src/libmad/configure delete mode 100644 lib-src/libmad/configure.ac delete mode 100644 lib-src/libmad/decoder.c delete mode 100644 lib-src/libmad/decoder.h delete mode 100755 lib-src/libmad/depcomp delete mode 100644 lib-src/libmad/fixed.c delete mode 100644 lib-src/libmad/fixed.h delete mode 100644 lib-src/libmad/frame.c delete mode 100644 lib-src/libmad/frame.h delete mode 100644 lib-src/libmad/global.h delete mode 100644 lib-src/libmad/huffman.c delete mode 100644 lib-src/libmad/huffman.h delete mode 100644 lib-src/libmad/imdct_l_arm.S delete mode 100644 lib-src/libmad/imdct_s.dat delete mode 100755 lib-src/libmad/install-sh delete mode 100644 lib-src/libmad/layer12.c delete mode 100644 lib-src/libmad/layer12.h delete mode 100644 lib-src/libmad/layer3.c delete mode 100644 lib-src/libmad/layer3.h delete mode 100644 lib-src/libmad/libmad-mp2-out-of-spec.patch delete mode 100644 lib-src/libmad/libmad.list.in delete mode 100644 lib-src/libmad/libmad.vcproj delete mode 100644 lib-src/libmad/ltmain.sh delete mode 100644 lib-src/libmad/mad.h.sed delete mode 100644 lib-src/libmad/minimad.c delete mode 100755 lib-src/libmad/missing delete mode 100755 lib-src/libmad/mkinstalldirs delete mode 100644 lib-src/libmad/msvc++/Makefile.am delete mode 100644 lib-src/libmad/msvc++/Makefile.in delete mode 100644 lib-src/libmad/msvc++/config.h delete mode 100644 lib-src/libmad/msvc++/libmad.dsp delete mode 100644 lib-src/libmad/msvc++/mad.h delete mode 100644 lib-src/libmad/osx-universal-build.patch delete mode 100644 lib-src/libmad/qc_table.dat delete mode 100644 lib-src/libmad/rq_table.dat delete mode 100644 lib-src/libmad/sf_table.dat delete mode 100644 lib-src/libmad/stamp-h.in delete mode 100644 lib-src/libmad/stream.c delete mode 100644 lib-src/libmad/stream.h delete mode 100644 lib-src/libmad/synth.c delete mode 100644 lib-src/libmad/synth.h delete mode 100644 lib-src/libmad/timer.c delete mode 100644 lib-src/libmad/timer.h delete mode 100644 lib-src/libmad/version.c delete mode 100644 lib-src/libmad/version.h diff --git a/cmake-proxies/expat/CMakeLists.txt b/cmake-proxies/expat/CMakeLists.txt deleted file mode 100644 index a5506f7ae..000000000 --- a/cmake-proxies/expat/CMakeLists.txt +++ /dev/null @@ -1,45 +0,0 @@ - -add_library( ${TARGET} STATIC ) - -def_vars() - -list( APPEND SOURCES - PRIVATE - ${TARGET_ROOT}/lib/xmlparse.c - ${TARGET_ROOT}/lib/xmlrole.c - ${TARGET_ROOT}/lib/xmltok.c - ${TARGET_ROOT}/lib/xmltok_impl.c - ${TARGET_ROOT}/lib/xmltok_ns.c -) - -list( APPEND INCLUDES - PRIVATE - ${_PRVDIR} - PUBLIC - ${TARGET_ROOT}/lib -) - -list( APPEND DEFINES - PRIVATE - HAVE_EXPAT_CONFIG_H - PUBLIC - XML_STATIC -) - -if( WORDS_BIGENDIAN ) - set( BYTEORDER 4321 ) -else( WORDS_BIGENDIAN ) - set( BYTEORDER 1234 ) -endif() - -set( XML_DTD OFF ) -set( XML_NS OFF ) - -configure_file( ${TARGET_ROOT}/expat_config.h.cmake private/expat_config.h ) - -organize_source( "${TARGET_ROOT}" "" "${SOURCES}" ) -target_sources( ${TARGET} PRIVATE ${SOURCES} ) -target_compile_definitions( ${TARGET} PRIVATE ${DEFINES} ) -target_include_directories( ${TARGET} PRIVATE ${INCLUDES} ) -target_link_libraries( ${TARGET} PRIVATE ${LIBRARIES} ) - diff --git a/cmake-proxies/lame/CMakeLists.txt b/cmake-proxies/lame/CMakeLists.txt deleted file mode 100644 index ac405a6d5..000000000 --- a/cmake-proxies/lame/CMakeLists.txt +++ /dev/null @@ -1,89 +0,0 @@ - -add_library( ${TARGET} STATIC ) - -def_vars() - -list( APPEND SOURCES - PRIVATE - # libmp3lame - ${TARGET_ROOT}/libmp3lame/bitstream.c - ${TARGET_ROOT}/libmp3lame/encoder.c - ${TARGET_ROOT}/libmp3lame/fft.c - ${TARGET_ROOT}/libmp3lame/gain_analysis.c - ${TARGET_ROOT}/libmp3lame/id3tag.c - ${TARGET_ROOT}/libmp3lame/lame.c - ${TARGET_ROOT}/libmp3lame/newmdct.c - ${TARGET_ROOT}/libmp3lame/presets.c - ${TARGET_ROOT}/libmp3lame/psymodel.c - ${TARGET_ROOT}/libmp3lame/quantize.c - ${TARGET_ROOT}/libmp3lame/quantize_pvt.c - ${TARGET_ROOT}/libmp3lame/reservoir.c - ${TARGET_ROOT}/libmp3lame/set_get.c - ${TARGET_ROOT}/libmp3lame/tables.c - ${TARGET_ROOT}/libmp3lame/takehiro.c - ${TARGET_ROOT}/libmp3lame/util.c - ${TARGET_ROOT}/libmp3lame/vbrquantize.c - ${TARGET_ROOT}/libmp3lame/VbrTag.c - ${TARGET_ROOT}/libmp3lame/version.c - ${TARGET_ROOT}/libmp3lame/vector/xmm_quantize_sub.c -) - -list( APPEND INCLUDES - PRIVATE - ${_PRVDIR} - ${TARGET_ROOT}/lame - ${TARGET_ROOT}/libmp3lame - PUBLIC - ${TARGET_ROOT} -) - -list( APPEND DEFINES - PRIVATE - HAVE_CONFIG_H -) - -list( APPEND OPTIONS - PRIVATE - ${MMX_FLAG} - ${SSE_FLAG} -) - -set( HAVE_INT8_T SIZEOF_INT8_T ) -set( HAVE_INT16_T SIZEOF_INT16_T ) -set( HAVE_INT32_T SIZEOF_INT32_T ) -set( HAVE_INT64_T SIZEOF_INT64_T ) -set( HAVE_UINT16_T SIZEOF_UINT16_T ) -set( HAVE_UINT32_T SIZEOF_UINT32_T ) -set( HAVE_UINT64_T SIZEOF_UINT64_T ) - -if( SIZEOF_SHORT EQUAL 4 ) - set( A_INT32_T int ) -elseif( SIZEOF_INT EQUAL 4 ) - set( A_INT32_T int ) -elseif( SIZEOF_LONG EQUAL 4 ) - set( A_INT32_T long ) -endif() - -if( SIZEOF_INT EQUAL 8 ) - set( A_INT64_T int ) -elseif( SIZEOF_LONG EQUAL 8 ) - set( A_INT64_T long ) -elseif( SIZEOF_LONG_LONG EQUAL 8 ) - set( A_INT64_T long long ) -endif() - -set( TAKEHIRO_IEEE754_HACK 1 ) -set( USE_FAST_LOG 1 ) -if( ${CMakeDetermineASM_NASMCompiler} ) - set( HAVE_NASM 1 ) -endif() - -configure_file( config.h.in private/config.h ) - -#organize_source( "${TARGET_ROOT}" "" "${SOURCES}" ) -target_sources( ${TARGET} PRIVATE ${SOURCES} ) -target_compile_definitions( ${TARGET} PRIVATE ${DEFINES} ) -target_include_directories( ${TARGET} PRIVATE ${INCLUDES} ) -target_compile_options( ${TARGET} PRIVATE ${OPTIONS} ) -target_link_libraries( ${TARGET} PRIVATE ${LIBRARIES} ) - diff --git a/cmake-proxies/lame/config.h.in b/cmake-proxies/lame/config.h.in deleted file mode 100644 index ca28db655..000000000 --- a/cmake-proxies/lame/config.h.in +++ /dev/null @@ -1,371 +0,0 @@ -/* config.h.in. Generated from configure.in by autoheader. */ - - -#ifndef LAME_CONFIG_H -#define LAME_CONFIG_H 1 - - -/* debug define */ -#cmakedefine ABORTFP 1 - -/* Define if building universal (internal helper macro) */ -#cmakedefine AC_APPLE_UNIVERSAL_BUILD 1 - -/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP - systems. This function is required for `alloca.c' support on those systems. - */ -#cmakedefine CRAY_STACKSEG_END @CRAY_STACKSEG_END@ - -/* Define to 1 if using `alloca.c'. */ -#cmakedefine C_ALLOCA 1 - -/* a lot of debug output */ -#cmakedefine DEBUG 1 - -/* allow to compute a more accurate replaygain value */ -#cmakedefine DECODE_ON_THE_FLY 1 - -/* double is faster than float on Alpha */ -#cmakedefine FLOAT @FLOAT@ - -/* Define to 1 if you have `alloca', as a function or macro. */ -#cmakedefine HAVE_ALLOCA 1 - -/* Define to 1 if you have and it should be used (not on Ultrix). - */ -#cmakedefine HAVE_ALLOCA_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_DLFCN_H 1 - -/* we link against libefence */ -#cmakedefine HAVE_EFENCE 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_ERRNO_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_FCNTL_H 1 - -/* Define to 1 if you have the `gettimeofday' function. */ -#cmakedefine HAVE_GETTIMEOFDAY 1 - -/* Define if you have the iconv() function and it works. */ -#cmakedefine HAVE_ICONV 1 - -/* add ieee754_float32_t type */ -#cmakedefine HAVE_IEEE754_FLOAT32_T 1 -#ifndef HAVE_IEEE754_FLOAT32_T - typedef float ieee754_float32_t; -#endif - -/* add ieee754_float64_t type */ -#cmakedefine HAVE_IEEE754_FLOAT64_T 1 -#ifndef HAVE_IEEE754_FLOAT64_T - typedef double ieee754_float64_t; -#endif - -/* system has 80 bit floats */ -#cmakedefine HAVE_IEEE854_FLOAT80 1 - -/* add ieee854_float80_t type */ -#cmakedefine HAVE_IEEE854_FLOAT80_T 1 -#ifndef HAVE_IEEE854_FLOAT80_T - typedef long double ieee854_float80_t; -#endif - -/* add int16_t type */ -#cmakedefine HAVE_INT16_T 1 -#ifndef HAVE_INT16_T - typedef short int16_t; -#endif - -/* add int32_t type */ -#cmakedefine HAVE_INT32_T 1 -#ifndef HAVE_INT32_T -#define A_INT32_T @A_INT32_T@ - typedef A_INT32_T int32_t; -#endif - -/* add int64_t type */ -#cmakedefine HAVE_INT64_T 1 -#ifndef HAVE_INT64_T -#define A_INT64_T @A_INT64_T@ - typedef A_INT64_T int64_t; -#endif - -/* add int8_t type */ -#cmakedefine HAVE_INT8_T 1 -#ifndef HAVE_INT8_T - typedef char int8_t; -#endif - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_LIMITS_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_LINUX_SOUNDCARD_H 1 - -/* Define to 1 if the type `long double' works and has more range or precision - than `double'. */ -#cmakedefine HAVE_LONG_DOUBLE 1 - -/* Define to 1 if the type `long double' works and has more range or precision - than `double'. */ -#cmakedefine HAVE_LONG_DOUBLE_WIDER 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_MEMORY_H 1 - -/* build with mpglib support */ -#cmakedefine HAVE_MPGLIB 1 - -/* have nasm */ -#cmakedefine HAVE_NASM 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_NCURSES_TERMCAP_H 1 - -/* Define to 1 if you have the `socket' function. */ -#cmakedefine HAVE_SOCKET 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRING_H 1 - -/* Define to 1 if you have the `strtol' function. */ -#cmakedefine HAVE_STRTOL 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_SOUNDCARD_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_TIME_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_TYPES_H 1 - -/* have termcap */ -#cmakedefine HAVE_TERMCAP 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_TERMCAP_H 1 - -/* add uint16_t type */ -#cmakedefine HAVE_UINT16_T 1 -#ifndef HAVE_UINT16_T - typedef unsigned short uint16_t; -#endif - -/* add uint32_t type */ -#cmakedefine HAVE_UINT32_T 1 -#ifndef HAVE_UINT32_T -#define A_UINT32_T @A_UINT32_T@ - typedef A_UINT32_T uint32_t; -#endif - -/* add uint64_t type */ -#cmakedefine HAVE_UINT64_T 1 -#ifndef HAVE_UINT64_T -#define A_UINT64_T @A_UINT64_T@ - typedef A_UINT64_T uint64_t; -#endif - -/* add uint8_t type */ -#cmakedefine HAVE_UINT8_T 1 -#ifndef HAVE_UINT8_T - typedef unsigned char uint8_t; -#endif - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_UNISTD_H 1 - -/* Define if SSE intrinsics work. */ -#cmakedefine HAVE_XMMINTRIN_H 1 - -/* Define as const if the declaration of iconv() needs const. */ -#define ICONV_CONST @ICONV_CONST@ - -/* requested by Frank, seems to be temporary needed for a smooth transition */ -#cmakedefine LAME_LIBRARY_BUILD 1 - -/* set to 1 if you have libsndfile */ -#cmakedefine LIBSNDFILE 1 - -/* Define to the sub-directory where libtool stores uninstalled libraries. */ -#cmakedefine LT_OBJDIR @LT_OBJDIR@ - -/* use MMX version of choose_table */ -#cmakedefine MMX_choose_table 1 - -/* build without hooks for analyzer */ -#cmakedefine NOANALYSIS 1 - -/* Name of package */ -#cmakedefine PACKAGE "@PACKAGE@" - -/* Define to the address where bug reports for this package should be sent. */ -#cmakedefine PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@" - -/* Define to the full name of this package. */ -#cmakedefine PACKAGE_NAME "@PACKAGE_NAME@" - -/* Define to the full name and version of this package. */ -#cmakedefine PACKAGE_STRING "@PACKAGE_STRING@" - -/* Define to the one symbol short name of this package. */ -#cmakedefine PACKAGE_TARNAME "@PACKAGE_TARNAME@" - -/* Define to the home page for this package. */ -#cmakedefine PACKAGE_URL "@PACKAGE_URL@" - -/* Define to the version of this package. */ -#cmakedefine PACKAGE_VERSION "@PACKAGE_VERSION@" - -/* The size of `double', as computed by sizeof. */ -#define SIZEOF_DOUBLE @SIZEOF_DOUBLE@ - -/* The size of `float', as computed by sizeof. */ -#define SIZEOF_FLOAT @SIZEOF_FLOAT@ - -/* The size of `int', as computed by sizeof. */ -#define SIZEOF_INT @SIZEOF_INT@ - -/* The size of `long', as computed by sizeof. */ -#define SIZEOF_LONG @SIZEOF_LONG@ - -/* The size of `long double', as computed by sizeof. */ -#define SIZEOF_LONG_DOUBLE @SIZEOF_LONG_DOUBLE@ - -/* The size of `long long', as computed by sizeof. */ -#define SIZEOF_LONG_LONG @SIZEOF_LONG_LONG@ - -/* The size of `short', as computed by sizeof. */ -#define SIZEOF_SHORT @SIZEOF_SHORT@ - -/* The size of `unsigned int', as computed by sizeof. */ -#define SIZEOF_UNSIGNED_INT @SIZEOF_UNSIGNED_INT@ - -/* The size of `unsigned long', as computed by sizeof. */ -#define SIZEOF_UNSIGNED_LONG @SIZEOF_UNSIGNED_LONG@ - -/* The size of `unsigned long long', as computed by sizeof. */ -#define SIZEOF_UNSIGNED_LONG_LONG @SIZEOF_UNSIGNED_LONG_LONG@ - -/* The size of `unsigned short', as computed by sizeof. */ -#define SIZEOF_UNSIGNED_SHORT @SIZEOF_UNSIGNED_SHORT@ - -/* If using the C implementation of alloca, define if you know the - direction of stack growth for your system; otherwise it will be - automatically deduced at runtime. - STACK_DIRECTION > 0 => grows toward higher addresses - STACK_DIRECTION < 0 => grows toward lower addresses - STACK_DIRECTION = 0 => direction of growth unknown */ -#cmakedefine STACK_DIRECTION @STACK_DIRECTION@ - -/* Define to 1 if you have the ANSI C header files. */ -#cmakedefine STDC_HEADERS 1 - -/* IEEE754 compatible machine */ -#cmakedefine TAKEHIRO_IEEE754_HACK 1 - -/* Define to 1 if you can safely include both and . */ -#cmakedefine TIME_WITH_SYS_TIME 1 - -/* faster log implementation with less but enough precision */ -#cmakedefine USE_FAST_LOG 1 - -/* Enable extensions on AIX 3, Interix. */ -#ifndef _ALL_SOURCE -#cmakedefine _ALL_SOURCE 1 -#endif -/* Enable GNU extensions on systems that have them. */ -#ifndef _GNU_SOURCE -#cmakedefine _GNU_SOURCE 1 -#endif -/* Enable threading extensions on Solaris. */ -#ifndef _POSIX_PTHREAD_SEMANTICS -#cmakedefine _POSIX_PTHREAD_SEMANTICS 1 -#endif -/* Enable extensions on HP NonStop. */ -#ifndef _TANDEM_SOURCE -#cmakedefine _TANDEM_SOURCE 1 -#endif -/* Enable general extensions on Solaris. */ -#ifndef __EXTENSIONS__ -#cmakedefine __EXTENSIONS__ 1 -#endif - - -/* Version number of package */ -#cmakedefine VERSION "@VERSION@" - -/* Define if using the dmalloc debugging malloc package */ -#cmakedefine WITH_DMALLOC 1 - -/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most - significant byte first (like Motorola and SPARC, unlike Intel). */ -#if defined AC_APPLE_UNIVERSAL_BUILD -# if defined __BIG_ENDIAN__ -# define WORDS_BIGENDIAN 1 -# endif -#else -# ifndef WORDS_BIGENDIAN -#cmakedefine WORDS_BIGENDIAN 1 -# endif -#endif - -/* Enable large inode numbers on Mac OS X 10.5. */ -#ifndef _DARWIN_USE_64_BIT_INODE -# define _DARWIN_USE_64_BIT_INODE 1 -#endif - -/* Number of bits in a file offset, on hosts where this is settable. */ -#cmakedefine _FILE_OFFSET_BITS @_FILE_OFFSET_BITS@ - -/* Define for large files, on AIX-style hosts. */ -#cmakedefine _LARGE_FILES @_LARGE_FILES@ - -/* Define to 1 if on MINIX. */ -#cmakedefine _MINIX 1 - -/* Define to 2 if the system does not provide POSIX.1 features except with - this defined. */ -#cmakedefine _POSIX_1_SOURCE @_POSIX_1_SOURCE@ - -/* Define to 1 if you need to in order for `stat' and other things to work. */ -#cmakedefine _POSIX_SOURCE 1 - -/* we're on DEC Alpha */ -#cmakedefine __DECALPHA__ 1 - -/* work around a glibc bug */ -#cmakedefine __NO_MATH_INLINES 1 - -/* Define to empty if `const' does not conform to ANSI C. */ -#cmakedefine const @const@ - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#cmakedefine inline @inline@ -#endif - -/* Define to `unsigned int' if does not define. */ -#cmakedefine size_t @size_t@ - -#endif /* LAME_CONFIG_H */ diff --git a/cmake-proxies/libid3tag/CMakeLists.txt b/cmake-proxies/libid3tag/CMakeLists.txt deleted file mode 100644 index 681bba790..000000000 --- a/cmake-proxies/libid3tag/CMakeLists.txt +++ /dev/null @@ -1,51 +0,0 @@ - -add_library( ${TARGET} STATIC ) - -def_vars() - -list( APPEND SOURCES - PRIVATE - ${TARGET_ROOT}/compat.c - ${TARGET_ROOT}/crc.c - ${TARGET_ROOT}/debug.c - ${TARGET_ROOT}/field.c - ${TARGET_ROOT}/file.c - ${TARGET_ROOT}/frame.c - ${TARGET_ROOT}/frametype.c - ${TARGET_ROOT}/genre.c - ${TARGET_ROOT}/latin1.c - ${TARGET_ROOT}/parse.c - ${TARGET_ROOT}/render.c - ${TARGET_ROOT}/tag.c - ${TARGET_ROOT}/ucs4.c - ${TARGET_ROOT}/utf16.c - ${TARGET_ROOT}/utf8.c - ${TARGET_ROOT}/util.c - ${TARGET_ROOT}/version.c -) - -list( APPEND INCLUDES - PRIVATE - ${_PRVDIR} - PUBLIC - ${TARGET_ROOT} -) - -list( APPEND OPTIONS - PRIVATE - $<$:-Wno-implicit-function-declaration> -) - -list( APPEND LIBRARIES - PRIVATE - -) - -configure_file( config.h.in private/config.h ) - -organize_source( "${TARGET_ROOT}" "src" "${SOURCES}" ) -target_sources( ${TARGET} PRIVATE ${SOURCES} ) -target_compile_options( ${TARGET} PRIVATE ${OPTIONS} ) -target_include_directories( ${TARGET} PRIVATE ${INCLUDES} ) -target_link_libraries( ${TARGET} PRIVATE ${LIBRARIES} ) - diff --git a/cmake-proxies/libid3tag/config.h.in b/cmake-proxies/libid3tag/config.h.in deleted file mode 100644 index 0a8ee48c8..000000000 --- a/cmake-proxies/libid3tag/config.h.in +++ /dev/null @@ -1,86 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to enable diagnostic debugging support. */ -#cmakedefine DEBUG 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_ASSERT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_DLFCN_H 1 - -/* Define to 1 if you have the `ftruncate' function. */ -#cmakedefine HAVE_FTRUNCATE 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the `z' library (-lz). */ -#cmakedefine HAVE_LIBZ 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_MEMORY_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRING_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_UNISTD_H 1 - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#cmakedefine LT_OBJDIR "@LT_OBJDIR@" - -/* Define to disable debugging assertions. */ -#cmakedefine NDEBUG 1 - -/* Name of package */ -#cmakedefine PACKAGE "@PACKAGE@" - -/* Define to the address where bug reports for this package should be sent. */ -#cmakedefine PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@" - -/* Define to the full name of this package. */ -#cmakedefine PACKAGE_NAME "@PACKAGE_NAME@" - -/* Define to the full name and version of this package. */ -#cmakedefine PACKAGE_STRING "@PACKAGE_STRING@" - -/* Define to the one symbol short name of this package. */ -#cmakedefine PACKAGE_TARNAME "@PACKAGE_TARNAME@" - -/* Define to the home page for this package. */ -#cmakedefine PACKAGE_URL "@PACKAGE_URL@" - -/* Define to the version of this package. */ -#cmakedefine PACKAGE_VERSION "@PACKAGE_VERSION@" - -/* Define to 1 if you have the ANSI C header files. */ -#cmakedefine STDC_HEADERS 1 - -/* Version number of package */ -#cmakedefine VERSION "@VERSION@" - -/* Define to empty if `const' does not conform to ANSI C. */ -#cmakedefine const @const@ - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#cmakedefine inline @inline@ -#endif diff --git a/cmake-proxies/libmad/CMakeLists.txt b/cmake-proxies/libmad/CMakeLists.txt deleted file mode 100644 index 0f0a13293..000000000 --- a/cmake-proxies/libmad/CMakeLists.txt +++ /dev/null @@ -1,58 +0,0 @@ - -add_library( ${TARGET} STATIC ) - -def_vars() - -if( IS_64BIT ) - set( FPM FPM_64BIT ) -elseif( ${CMAKE_HOST_SYSTEM_PROCESSOR} MATCHES "X86|AMD64|i386|i686|x86_64" ) - set( FPM FPM_INTEL ) -else() - set( FPM FPM_DEFAULT ) -endif() - -list( APPEND SOURCES - PRIVATE - ${TARGET_ROOT}/bit.c - ${TARGET_ROOT}/decoder.c - ${TARGET_ROOT}/fixed.c - ${TARGET_ROOT}/frame.c - ${TARGET_ROOT}/huffman.c - ${TARGET_ROOT}/layer12.c - ${TARGET_ROOT}/layer3.c - ${TARGET_ROOT}/stream.c - ${TARGET_ROOT}/synth.c - ${TARGET_ROOT}/timer.c - ${TARGET_ROOT}/version.c -) - -list( APPEND INCLUDES - PRIVATE - ${_PRVDIR} - PUBLIC - ${_PUBDIR} - ${TARGET_ROOT} -) - -list( APPEND DEFINES - PRIVATE - HAVE_CONFIG_H - OPT_ACCURACY - ${FPM} -) - -list( APPEND OPTIONS - PRIVATE - $<$:-Wall> -) - -configure_file( config.h.in private/config.h ) -configure_file( mad.h.in public/mad.h ) - -organize_source( "${TARGET_ROOT}" "" "${SOURCES}" ) -target_sources( ${TARGET} PRIVATE ${SOURCES} ) -target_compile_definitions( ${TARGET} PRIVATE ${DEFINES} ) -target_compile_options( ${TARGET} PRIVATE ${OPTIONS} ) -target_include_directories( ${TARGET} PRIVATE ${INCLUDES} ) -target_link_libraries( ${TARGET} PRIVATE ${LIBRARIES} ) - diff --git a/cmake-proxies/libmad/config.h.in b/cmake-proxies/libmad/config.h.in deleted file mode 100644 index 97924a322..000000000 --- a/cmake-proxies/libmad/config.h.in +++ /dev/null @@ -1,215 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2001 Robert Leslie - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: acconfig.h,v 1.2 2001-10-21 22:26:32 dmazzoni Exp $ - */ - -# ifndef LIBMAD_CONFIG_H -# define LIBMAD_CONFIG_H 1 - -/***************************************************************************** - * Definitions selected automatically by `configure' * - *****************************************************************************/ - -/* Define to optimize for speed over accuracy. */ -#cmakedefine OPT_SPEED 1 - -/* Define to optimize for accuracy over speed. */ -#cmakedefine OPT_ACCURACY 1 - -/* Define to enable a fast subband synthesis approximation optimization. */ -#cmakedefine OPT_SSO 1 - -/* Define to influence a strict interpretation of the ISO/IEC standards, - even if this is in opposition with best accepted practices. */ -#cmakedefine OPT_STRICT 1 - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#cmakedefine HAVE_MADD_ASM 1 - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#cmakedefine HAVE_MADD16_ASM 1 - -/* Define to enable diagnostic debugging support. */ -#cmakedefine DEBUG 1 - -/* Define to disable debugging assertions. */ -#cmakedefine NDEBUG 1 - -/* Define to enable experimental code. */ -#cmakedefine EXPERIMENTAL 1 - - -/* Define if building universal (internal helper macro) */ -#cmakedefine AC_APPLE_UNIVERSAL_BUILD 1 - -/* Define to enable diagnostic debugging support. */ -#cmakedefine DEBUG 1 - -/* Define to enable experimental code. */ -#cmakedefine EXPERIMENTAL 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_ASSERT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_DLFCN_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_ERRNO_H 1 - -/* Define to 1 if you have the `fcntl' function. */ -#cmakedefine HAVE_FCNTL 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_FCNTL_H 1 - -/* Define to 1 if you have the `fork' function. */ -#cmakedefine HAVE_FORK 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_LIMITS_H 1 - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#cmakedefine HAVE_MADD16_ASM 1 - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#cmakedefine HAVE_MADD_ASM 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_MEMORY_H 1 - -/* Define to 1 if you have the `pipe' function. */ -#cmakedefine HAVE_PIPE 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRING_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have that is POSIX.1 compatible. */ -#cmakedefine HAVE_SYS_WAIT_H 1 - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_UNISTD_H 1 - -/* Define to 1 if you have the `waitpid' function. */ -#cmakedefine HAVE_WAITPID 1 - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#cmakedefine LT_OBJDIR "@LT_OBJDIR@" - -/* Define to disable debugging assertions. */ -#cmakedefine NDEBUG 1 - -/* Define to optimize for accuracy over speed. */ -#cmakedefine OPT_ACCURACY 1 - -/* Define to optimize for speed over accuracy. */ -#cmakedefine OPT_SPEED 1 - -/* Define to enable a fast subband synthesis approximation optimization. */ -#cmakedefine OPT_SSO 1 - -/* Define to influence a strict interpretation of the ISO/IEC standards, even - if this is in opposition with best accepted practices. */ -#cmakedefine OPT_STRICT 1 - -/* Name of package */ -#cmakedefine PACKAGE "@PACKAGES" - -/* Define to the address where bug reports for this package should be sent. */ -#cmakedefine PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@" - -/* Define to the full name of this package. */ -#cmakedefine PACKAGE_NAME "@PACKAGE_NAME@" - -/* Define to the full name and version of this package. */ -#cmakedefine PACKAGE_STRING "@PACKAGE_STRING@" - -/* Define to the one symbol short name of this package. */ -#cmakedefine PACKAGE_TARNAME "@PACKAGE_TARNAME@" - -/* Define to the home page for this package. */ -#cmakedefine PACKAGE_URL "@PACKAGE_URL@" - -/* Define to the version of this package. */ -#cmakedefine PACKAGE_VERSION "@PACKAGE_VERSION@" - -/* The size of `int', as computed by sizeof. */ -#define SIZEOF_INT @SIZEOF_INT@ - -/* The size of `long', as computed by sizeof. */ -#define SIZEOF_LONG @SIZEOF_LONG@ - -/* The size of `long long', as computed by sizeof. */ -#define SIZEOF_LONG_LONG @SIZEOF_LONG_LONG@ - -/* Define to 1 if you have the ANSI C header files. */ -#cmakedefine STDC_HEADERS 1 - -/* Version number of package */ -#cmakedefine VERSION "@VERSION@" - -/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most - significant byte first (like Motorola and SPARC, unlike Intel). */ -#if defined AC_APPLE_UNIVERSAL_BUILD -# if defined __BIG_ENDIAN__ -# define WORDS_BIGENDIAN 1 -# endif -#else -# ifndef WORDS_BIGENDIAN -# cmakedefine WORDS_BIGENDIAN @WORDS_BIGENDIAN@ -# endif -#endif - -/* Define to empty if `const' does not conform to ANSI C. */ -#cmakedefine const @const@ - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#cmakedefine inline @const@ -#endif - -/* Define to `int' if does not define. */ -#cmakedefine pid_t @pid_t@ - -/***************************************************************************** - * End of automatically configured definitions * - *****************************************************************************/ - -# endif diff --git a/cmake-proxies/libmad/mad.h.in b/cmake-proxies/libmad/mad.h.in deleted file mode 100755 index fc5edb5b6..000000000 --- a/cmake-proxies/libmad/mad.h.in +++ /dev/null @@ -1,15 +0,0 @@ -#ifndef _MAD_H_ -#define _MAD_H_ - -#define @FPM@ - -#include "version.h" -#include "fixed.h" -#include "bit.h" -#include "timer.h" -#include "stream.h" -#include "frame.h" -#include "synth.h" -#include "decoder.h" - -#endif diff --git a/cmake-proxies/wxWidgets/CMakeLists.txt b/cmake-proxies/wxWidgets/CMakeLists.txt deleted file mode 100644 index 47b6bd0ee..000000000 --- a/cmake-proxies/wxWidgets/CMakeLists.txt +++ /dev/null @@ -1,287 +0,0 @@ - -add_library( ${TARGET} INTERFACE ) -add_library( wxBase INTERFACE ) -add_library( ${symbol} ALIAS ${TARGET} ) - -def_vars() - -message( STATUS "========== Configuring ${name} ==========" ) - -cmd_option( ${_OPT}use_wxwidgets - "Use ${name} library [system (if available), local]" - "${audacity_lib_preference}" - STRINGS "system" "local" -) - -if( ${_OPT}use_wxwidgets STREQUAL "system" ) - # Make sure shared libs are preferred over static - set( BUILD_SHARED_LIBS YES ) - - # Specify all of the components we'll need since "html" and "qa" aren't - # included in the default list - find_package(wxWidgets REQUIRED COMPONENTS adv base core html net qa xml) - - unset( BUILD_SHARED_LIBS ) -endif() - -if( wxWidgets_FOUND ) - message( STATUS "Using '${name}' system library" ) - - if( wxWidgets_INCLUDE_DIRS_NO_SYSTEM ) - set( INCLUDES - INTERFACE - ${wxWidgets_INCLUDE_DIRS_NO_SYSTEM} - ) - else() - set( INCLUDES - INTERFACE - ${wxWidgets_INCLUDE_DIRS} - ) - endif() - - set( DEFINES - INTERFACE - ${wxWidgets_DEFINITIONS_GENERAL} - $<$: - ${wxWidgets_DEFINITIONS_DEBUG} - > - $<$>: - ${wxWidgets_DEFINITIONS_OPTIMIZED} - > - ) - - set( LINKDIRS - INTERFACE - $<$: - ${wxWidgets_LIB_DIR} - > - ) - - set( LIBRARIES - INTERFACE - ${wxWidgets_LIBRARIES} - $<$>: - z - > - ) - -# set( WXWIN $ENV{WXWIN} CACHE INTERNAL "" ) - if( WXWIN ) - string( APPEND WXWIN "/lib" ) - else() - set( WXWIN "${wxWidgets_LIBRARY_DIRS}" ) - endif() - set( WXWIN "${WXWIN}" CACHE INTERNAL "" ) - - set( toolkit "${wxWidgets_LIBRARIES}" ) -else() - message( STATUS "Using local '${name}' library" ) - - set( WXWIN $ENV{WXWIN} ) - if( "${WXWIN}" STREQUAL "" ) - # XXX: Look into importing instead of adding to this project - set( WXWIN "${_INTDIR}/wxwidgets" ) - endif() - - if( NOT EXISTS "${WXWIN}" ) - if( NOT GIT_FOUND ) - message( FATAL_ERROR "Git is needed to clone wxWidgets" ) - endif() - - execute_process( - COMMAND - ${GIT_EXECUTABLE} clone - --depth 1 - --single-branch - --recurse-submodules - https://github.com/audacity/wxwidgets - "${WXWIN}" - ) - endif() - - if( CMAKE_SYSTEM_NAME MATCHES "Windows" ) - # Want accessibility - set( wxUSE_ACCESSIBILITY YES ) - - # Windows requires it due to missing "#include" directives - set( wxBUILD_PRECOMP YES ) - elseif( CMAKE_SYSTEM_NAME MATCHES "Darwin" ) - # Want accessibility - set( wxUSE_ACCESSIBILITY YES ) - - # Causes problems on OSX, so turn it off - set( wxBUILD_PRECOMP NO ) - elseif( CMAKE_SYSTEM_NAME MATCHES "Linux|FreeBSD" ) - # Doesn't yet have accessbility - set( wxUSE_ACCESSIBILITY NO ) - - # Linux can go either way, so might as well use it - set( wxBUILD_PRECOMP YES ) - endif() - - # Just to be consistent with Audacity - set( wxBUILD_CXX_STANDARD "14" ) - - # Pull in wxWidgets - add_subdirectory( ${WXWIN} ${WXWIN} ) - - # And rearrange the folder structure - set_dir_folder( ${WXWIN} "wxWidgets" ) - - set( INCLUDES - $<$: - ${WXWIN}/src/zlib - > - ) - - set( DEFINES - WXUSINGDLL - ) - - # For all required libs, gather all of the interface target - # properties and merge them into the wxWidgets target - foreach( lib adv base core html net qa xml ) - get_target_property( value ${lib} INTERFACE_INCLUDE_DIRECTORIES ) - if( value ) - list( APPEND INCLUDES ${value} ) - list( REMOVE_DUPLICATES INCLUDES ) - endif() - - get_target_property( value ${lib} INTERFACE_COMPILE_DEFINITIONS ) - if( value ) - list( APPEND DEFINES ${value} ) - list( REMOVE_DUPLICATES DEFINES ) - endif() - - get_target_property( value ${lib} INTERFACE_COMPILE_OPTIONS ) - if( value ) - list( APPEND COPTS ${value} ) - list( REMOVE_DUPLICATES COPTS ) - endif() - - get_target_property( value ${lib} INTERFACE_LINK_LIBRARIES ) - if( value) - list( APPEND LIBRARIES ${lib} ${value} ) - list( REMOVE_DUPLICATES LIBRARIES ) - endif() - endforeach() - - # Do NOT split the generator expressions across multiple lines here. - # CMake appears to have a bug and doesn't seem to handle it correctly - # for target link libraries. - list( APPEND LIBRARIES - $<$:wxexpat> - $<$:wxjpeg> - $<$:wxpng> - $<$:wxtiff> - $<$:wxregex> - $<$:wxzlib> - ) - - if( CMAKE_SYSTEM_NAME MATCHES "Darwin" ) - # When accessibility is enabled, the build will fail in "wx/chkconf.h" - # since wxRegex compile defines do not include __WXOSX_COCOA__. So, - # add it here. - target_compile_definitions( wxregex PRIVATE "__WXOSX_COCOA__" ) - endif() - - set( toolkit "${wxBUILD_TOOLKIT}" ) -endif() - -if( "${toolkit}" MATCHES ".*gtk2.*" ) - set( gtk gtk+-2.0 ) - set( glib glib-2.0 ) - set( wxTOOLKIT "GTK2" CACHE INTERNAL "" ) - set( wxIS_GTK YES CACHE INTERNAL "" ) -elseif( "${toolkit}" MATCHES ".*gtk3.*" ) - set( gtk gtk+-3.0 ) - set( glib glib-2.0 ) - set( wxTOOLKIT "GTK3" CACHE INTERNAL "" ) - set( wxIS_GTK YES CACHE INTERNAL "" ) -elseif( "${toolkit}" MATCHES ".*gtk4.*" ) - set( gtk gtk+-4.0 ) - set( glib glib-2.0 ) - set( wxTOOLKIT "GTK4" CACHE INTERNAL "" ) - set( wxIS_GTK YES CACHE INTERNAL "" ) -elseif( "${toolkit}" MATCHES ".*msw.*" ) - set( wxTOOLKIT "MSW" CACHE INTERNAL "" ) - set( wxIS_WIN YES CACHE INTERNAL "" ) - list( APPEND DEFINES __WXMSW__=1 ) -elseif( "${toolkit}" MATCHES ".*osx.*" ) - set( wxTOOLKIT "MAC" CACHE INTERNAL "" ) - set( wxIS_MAC YES CACHE INTERNAL "" ) -else() - message( FATAL_ERROR "Unrecognized wxWidgets toolkit" ) -endif() - -if( "${wxTOOLKIT}" MATCHES "GTK." ) - pkg_check_modules( GTK REQUIRED IMPORTED_TARGET GLOBAL ${gtk} ) - pkg_check_modules( GLIB REQUIRED IMPORTED_TARGET GLOBAL ${glib} ) -endif() - -find_file( WXVERSION_H - NAMES - wx/version.h - PATHS - ${INCLUDES} - NO_DEFAULT_PATH -) - -if( NOT WXVERSION_H ) - message( FATAL_ERROR "wxWidgets version.h header not found" ) -endif() - -file( - STRINGS - "${WXVERSION_H}" output - REGEX - "^#define +wxVERSION_STRING +" -) - -string( REGEX MATCHALL "\".+(Audacity).+\"" ours "${output}") -if( NOT ours ) - message( FATAL_ERROR - "\n########################################################################\n" - "Audacity version 3.0.0 or higher requires use of a customized version of " - "wxWidgets. For details:\n" - " https://wiki.audacityteam.org/wiki/Building_for_Distros\n" - "########################################################################\n" - ) -endif() - -foreach( target "${TARGET}" wxBase ) - target_include_directories( ${target} INTERFACE ${INCLUDES} ) - target_compile_definitions( ${target} INTERFACE ${DEFINES} ) - target_compile_options( ${target} INTERFACE ${COPTS} ) - target_link_directories( ${target} INTERFACE ${LINKDIRS} ) - target_link_libraries( ${target} INTERFACE ${LIBRARIES} ) -endforeach() - -# wxBase exposes only the GUI-less subset of full wxWidgets -# Also prohibit use of some other headers by pre-defining their include guards -# wxUSE_GUI=0 doesn't exclude all of wxCore dependency, and the application -# object and event loops are in wxBase, but we want to exclude their use too -target_compile_definitions( wxBase INTERFACE - "wxUSE_GUI=0" - - # Don't use app.h - _WX_APP_H_BASE_ - - # Don't use evtloop.h - _WX_EVTLOOP_H_ - - # Don't use image.h - _WX_IMAGE_H - - # Don't use colour.h - _WX_COLOUR_H_BASE_ - - # Don't use brush.h - _WX_BRUSH_H_BASE_ - - # Don't use pen.h - _WX_PEN_H_BASE_ -) - -install( TARGETS ${TARGET} DESTINATION ${_LIBDIR} ) - diff --git a/lib-src/expat/CMake.README b/lib-src/expat/CMake.README deleted file mode 100755 index eda302d91..000000000 --- a/lib-src/expat/CMake.README +++ /dev/null @@ -1,42 +0,0 @@ -== How to build expat with cmake (experimental) == - -The cmake based buildsystem for expat works on Windows (cygwin, mingw, Visual -Studio) and should work on all other platform cmake supports. - -Assuming ~/expat-2.1.0 is the source directory of expat, add a subdirectory -build and change into that directory: -~/expat-2.1.0$ mkdir build && cd build -~/expat-2.1.0/build$ - -From that directory, call cmake first, then call make, make test and -make install in the usual way: -~/expat-2.1.0/build$ cmake .. --- The C compiler identification is GNU --- The CXX compiler identification is GNU -.... --- Configuring done --- Generating done --- Build files have been written to: /home/patrick/expat-2.1.0/build - -If you want to specify the install location for your files, append --DCMAKE_INSTALL_PREFIX=/your/install/path to the cmake call. - -~/expat-2.1.0/build$ make && make test && make install -Scanning dependencies of target expat -[ 5%] Building C object CMakeFiles/expat.dir/lib/xmlparse.c.o -[ 11%] Building C object CMakeFiles/expat.dir/lib/xmlrole.c.o -.... --- Installing: /usr/local/lib/pkgconfig/expat.pc --- Installing: /usr/local/bin/xmlwf --- Installing: /usr/local/share/man/man1/xmlwf.1 - -For Windows builds, you must make sure to call cmake from an environment where -your compiler is reachable, that means either you call it from the -Visual Studio Command Prompt or when using mingw, you must open a cmd.exe and -make sure that gcc can be called. On Windows, you also might want to specify a -special Generator for CMake: -for Visual Studio builds do: -cmake .. -G "Visual Studio 10" && vcexpress expat.sln -for mingw builds do: -cmake .. -G "MinGW Makefiles" -DCMAKE_INSTALL_PREFIX=D:\expat-install - && gmake && gmake install diff --git a/lib-src/expat/CMakeLists.txt b/lib-src/expat/CMakeLists.txt deleted file mode 100755 index c4b8a2338..000000000 --- a/lib-src/expat/CMakeLists.txt +++ /dev/null @@ -1,111 +0,0 @@ -# This file is copyrighted under the BSD-license for buildsystem files of KDE -# copyright 2010, Patrick Spendrin - -project(expat) - -cmake_minimum_required(VERSION 2.6) -set(PACKAGE_BUGREPORT "expat-bugs@libexpat.org") -set(PACKAGE_NAME "expat") -set(PACKAGE_VERSION "2.1.0") -set(PACKAGE_STRING "${PACKAGE_NAME} ${PACKAGE_VERSION}") -set(PACKAGE_TARNAME "${PACKAGE_NAME}") - -option(BUILD_tools "build the xmlwf tool for expat library" ON) -option(BUILD_examples "build the examples for expat library" ON) -option(BUILD_tests "build the tests for expat library" ON) -option(BUILD_shared "build a shared expat library" ON) - -# configuration options -set(XML_CONTEXT_BYTES 1024 CACHE STRING "Define to specify how much context to retain around the current parse point") -option(XML_DTD "Define to make parameter entity parsing functionality available" ON) -option(XML_NS "Define to make XML Namespaces functionality available" ON) - -if(XML_DTD) - set(XML_DTD 1) -else(XML_DTD) - set(XML_DTD 0) -endif(XML_DTD) -if(XML_NS) - set(XML_NS 1) -else(XML_NS) - set(XML_NS 0) -endif(XML_NS) - -if(BUILD_tests) - enable_testing() -endif(BUILD_tests) - -include(ConfigureChecks.cmake) - -include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/lib) -if(MSVC) - add_definitions(-D_CRT_SECURE_NO_WARNINGS -wd4996) -endif(MSVC) - -set(expat_SRCS - lib/xmlparse.c - lib/xmlrole.c - lib/xmltok.c - lib/xmltok_impl.c - lib/xmltok_ns.c -) - -if(WIN32 AND BUILD_shared) - set(expat_SRCS ${expat_SRCS} lib/libexpat.def) -endif(WIN32 AND BUILD_shared) - -if(BUILD_shared) - set(_SHARED SHARED) -else(BUILD_shared) - set(_SHARED STATIC) -endif(BUILD_shared) - -add_library(expat ${_SHARED} ${expat_SRCS}) - -install(TARGETS expat RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib) - -set(prefix ${CMAKE_INSTALL_PREFIX}) -set(exec_prefix "\${prefix}/bin") -set(libdir "\${prefix}/lib") -set(includedir "\${prefix}/include") -configure_file(expat.pc.in ${CMAKE_CURRENT_BINARY_DIR}/expat.pc) - -install(FILES lib/expat.h lib/expat_external.h DESTINATION include) -install(FILES ${CMAKE_CURRENT_BINARY_DIR}/expat.pc DESTINATION lib/pkgconfig) - - - -if(BUILD_tools AND NOT WINCE) - set(xmlwf_SRCS - xmlwf/xmlwf.c - xmlwf/xmlfile.c - xmlwf/codepage.c - xmlwf/readfilemap.c - ) - - add_executable(xmlwf ${xmlwf_SRCS}) - target_link_libraries(xmlwf expat) - install(TARGETS xmlwf DESTINATION bin) - install(FILES doc/xmlwf.1 DESTINATION share/man/man1) -endif(BUILD_tools AND NOT WINCE) - -if(BUILD_examples) - add_executable(elements examples/elements.c) - target_link_libraries(elements expat) - - add_executable(outline examples/outline.c) - target_link_libraries(outline expat) -endif(BUILD_examples) - -if(BUILD_tests) - ## these are unittests that can be run on any platform - add_executable(runtests tests/runtests.c tests/chardata.c tests/minicheck.c) - target_link_libraries(runtests expat) - add_test(runtests runtests) - - add_executable(runtestspp tests/runtestspp.cpp tests/chardata.c tests/minicheck.c) - target_link_libraries(runtestspp expat) - add_test(runtestspp runtestspp) -endif(BUILD_tests) diff --git a/lib-src/expat/COPYING b/lib-src/expat/COPYING deleted file mode 100644 index dcb450642..000000000 --- a/lib-src/expat/COPYING +++ /dev/null @@ -1,22 +0,0 @@ -Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd - and Clark Cooper -Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006 Expat maintainers. - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be included -in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/lib-src/expat/Changes b/lib-src/expat/Changes deleted file mode 100644 index 08897b9f9..000000000 --- a/lib-src/expat/Changes +++ /dev/null @@ -1,205 +0,0 @@ -Release 2.1.0 Sat March 24 2012 - - Bug Fixes: - #1742315: Harmful XML_ParserCreateNS suggestion. - #2895533: CVE-2012-1147 - Resource leak in readfilemap.c. - #1785430: Expat build fails on linux-amd64 with gcc version>=4.1 -O3. - #1983953, 2517952, 2517962, 2649838: - Build modifications using autoreconf instead of buildconf.sh. - #2815947, #2884086: OBJEXT and EXEEXT support while building. - #1990430: CVE-2009-3720 - Parser crash with special UTF-8 sequences. - #2517938: xmlwf should return non-zero exit status if not well-formed. - #2517946: Wrong statement about XMLDecl in xmlwf.1 and xmlwf.sgml. - #2855609: Dangling positionPtr after error. - #2894085: CVE-2009-3560 - Buffer over-read and crash in big2_toUtf8(). - #2958794: CVE-2012-1148 - Memory leak in poolGrow. - #2990652: CMake support. - #3010819: UNEXPECTED_STATE with a trailing "%" in entity value. - #3206497: Unitialized memory returned from XML_Parse. - #3287849: make check fails on mingw-w64. - #3496608: CVE-2012-0876 - Hash DOS attack. - - Patches: - #1749198: pkg-config support. - #3010222: Fix for bug #3010819. - #3312568: CMake support. - #3446384: Report byte offsets for attr names and values. - - New Features / API changes: - Added new API member XML_SetHashSalt() that allows setting an intial - value (salt) for hash calculations. This is part of the fix for - bug #3496608 to randomize hash parameters. - When compiled with XML_ATTR_INFO defined, adds new API member - XML_GetAttributeInfo() that allows retrieving the byte - offsets for attribute names and values (patch #3446384). - Added CMake build system. - See bug #2990652 and patch #3312568. - Added run-benchmark target to Makefile.in - relies on testdata module - present in the same relative location as in the repository. - -Release 2.0.1 Tue June 5 2007 - - Fixed bugs #1515266, #1515600: The character data handler's calling - of XML_StopParser() was not handled properly; if the parser was - stopped and the handler set to NULL, the parser would segfault. - - Fixed bug #1690883: Expat failed on EBCDIC systems as it assumed - some character constants to be ASCII encoded. - - Minor cleanups of the test harness. - - Fixed xmlwf bug #1513566: "out of memory" error on file size zero. - - Fixed outline.c bug #1543233: missing a final XML_ParserFree() call. - - Fixes and improvements for Windows platform: - bugs #1409451, #1476160, #1548182, #1602769, #1717322. - - Build fixes for various platforms: - HP-UX, Tru64, Solaris 9: patch #1437840, bug #1196180. - All Unix: #1554618 (refreshed config.sub/config.guess). - #1490371, #1613457: support both, DESTDIR and INSTALL_ROOT, - without relying on GNU-Make specific features. - #1647805: Patched configure.in to work better with Intel compiler. - - Fixes to Makefile.in to have make check work correctly: - bugs #1408143, #1535603, #1536684. - - Added Open Watcom support: patch #1523242. - -Release 2.0.0 Wed Jan 11 2006 - - We no longer use the "check" library for C unit testing; we - always use the (partial) internal implementation of the API. - - Report XML_NS setting via XML_GetFeatureList(). - - Fixed headers for use from C++. - - XML_GetCurrentLineNumber() and XML_GetCurrentColumnNumber() - now return unsigned integers. - - Added XML_LARGE_SIZE switch to enable 64-bit integers for - byte indexes and line/column numbers. - - Updated to use libtool 1.5.22 (the most recent). - - Added support for AmigaOS. - - Some mostly minor bug fixes. SF issues include: #1006708, - #1021776, #1023646, #1114960, #1156398, #1221160, #1271642. - -Release 1.95.8 Fri Jul 23 2004 - - Major new feature: suspend/resume. Handlers can now request - that a parse be suspended for later resumption or aborted - altogether. See "Temporarily Stopping Parsing" in the - documentation for more details. - - Some mostly minor bug fixes, but compilation should no - longer generate warnings on most platforms. SF issues - include: #827319, #840173, #846309, #888329, #896188, #923913, - #928113, #961698, #985192. - -Release 1.95.7 Mon Oct 20 2003 - - Fixed enum XML_Status issue (reported on SourceForge many - times), so compilers that are properly picky will be happy. - - Introduced an XMLCALL macro to control the calling - convention used by the Expat API; this macro should be used - to annotate prototypes and definitions of callback - implementations in code compiled with a calling convention - other than the default convention for the host platform. - - Improved ability to build without the configure-generated - expat_config.h header. This is useful for applications - which embed Expat rather than linking in the library. - - Fixed a variety of bugs: see SF issues #458907, #609603, - #676844, #679754, #692878, #692964, #695401, #699323, #699487, - #820946. - - Improved hash table lookups. - - Added more regression tests and improved documentation. - -Release 1.95.6 Tue Jan 28 2003 - - Added XML_FreeContentModel(). - - Added XML_MemMalloc(), XML_MemRealloc(), XML_MemFree(). - - Fixed a variety of bugs: see SF issues #615606, #616863, - #618199, #653180, #673791. - - Enhanced the regression test suite. - - Man page improvements: includes SF issue #632146. - -Release 1.95.5 Fri Sep 6 2002 - - Added XML_UseForeignDTD() for improved SAX2 support. - - Added XML_GetFeatureList(). - - Defined XML_Bool type and the values XML_TRUE and XML_FALSE. - - Use an incomplete struct instead of a void* for the parser - (may not retain). - - Fixed UTF-8 decoding bug that caused legal UTF-8 to be rejected. - - Finally fixed bug where default handler would report DTD - events that were already handled by another handler. - Initial patch contributed by Darryl Miles. - - Removed unnecessary DllMain() function that caused static - linking into a DLL to be difficult. - - Added VC++ projects for building static libraries. - - Reduced line-length for all source code and headers to be - no longer than 80 characters, to help with AS/400 support. - - Reduced memory copying during parsing (SF patch #600964). - - Fixed a variety of bugs: see SF issues #580793, #434664, - #483514, #580503, #581069, #584041, #584183, #584832, #585537, - #596555, #596678, #598352, #598944, #599715, #600479, #600971. - -Release 1.95.4 Fri Jul 12 2002 - - Added support for VMS, contributed by Craig Berry. See - vms/README.vms for more information. - - Added Mac OS (classic) support, with a makefile for MPW, - contributed by Thomas Wegner and Daryle Walker. - - Added Borland C++ Builder 5 / BCC 5.5 support, contributed - by Patrick McConnell (SF patch #538032). - - Fixed a variety of bugs: see SF issues #441449, #563184, - #564342, #566334, #566901, #569461, #570263, #575168, #579196. - - Made skippedEntityHandler conform to SAX2 (see source comment) - - Re-implemented WFC: Entity Declared from XML 1.0 spec and - added a new error "entity declared in parameter entity": - see SF bug report #569461 and SF patch #578161 - - Re-implemented section 5.1 from XML 1.0 spec: - see SF bug report #570263 and SF patch #578161 - -Release 1.95.3 Mon Jun 3 2002 - - Added a project to the MSVC workspace to create a wchar_t - version of the library; the DLLs are named libexpatw.dll. - - Changed the name of the Windows DLLs from expat.dll to - libexpat.dll; this fixes SF bug #432456. - - Added the XML_ParserReset() API function. - - Fixed XML_SetReturnNSTriplet() to work for element names. - - Made the XML_UNICODE builds usable (thanks, Karl!). - - Allow xmlwf to read from standard input. - - Install a man page for xmlwf on Unix systems. - - Fixed many bugs; see SF bug reports #231864, #461380, #464837, - #466885, #469226, #477667, #484419, #487840, #494749, #496505, - #547350. Other bugs which we can't test as easily may also - have been fixed, especially in the area of build support. - -Release 1.95.2 Fri Jul 27 2001 - - More changes to make MSVC happy with the build; add a single - workspace to support both the library and xmlwf application. - - Added a Windows installer for Windows users; includes - xmlwf.exe. - - Added compile-time constants that can be used to determine the - Expat version - - Removed a lot of GNU-specific dependencies to aide portability - among the various Unix flavors. - - Fix the UTF-8 BOM bug. - - Cleaned up warning messages for several compilers. - - Added the -Wall, -Wstrict-prototypes options for GCC. - -Release 1.95.1 Sun Oct 22 15:11:36 EDT 2000 - - Changes to get expat to build under Microsoft compiler - - Removed all aborts and instead return an UNEXPECTED_STATE error. - - Fixed a bug where a stray '%' in an entity value would cause an - abort. - - Defined XML_SetEndNamespaceDeclHandler. Thanks to Darryl Miles for - finding this oversight. - - Changed default patterns in lib/Makefile.in to fit non-GNU makes - Thanks to robin@unrated.net for reporting and providing an - account to test on. - - The reference had the wrong label for XML_SetStartNamespaceDecl. - Reported by an anonymous user. - -Release 1.95.0 Fri Sep 29 2000 - - XML_ParserCreate_MM - Allows you to set a memory management suite to replace the - standard malloc,realloc, and free. - - XML_SetReturnNSTriplet - If you turn this feature on when namespace processing is in - effect, then qualified, prefixed element and attribute names - are returned as "uri|name|prefix" where '|' is whatever - separator character is used in namespace processing. - - Merged in features from perl-expat - o XML_SetElementDeclHandler - o XML_SetAttlistDeclHandler - o XML_SetXmlDeclHandler - o XML_SetEntityDeclHandler - o StartDoctypeDeclHandler takes 3 additional parameters: - sysid, pubid, has_internal_subset - o Many paired handler setters (like XML_SetElementHandler) - now have corresponding individual handler setters - o XML_GetInputContext for getting the input context of - the current parse position. - - Added reference material - - Packaged into a distribution that builds a sharable library diff --git a/lib-src/expat/ConfigureChecks.cmake b/lib-src/expat/ConfigureChecks.cmake deleted file mode 100755 index f03faa637..000000000 --- a/lib-src/expat/ConfigureChecks.cmake +++ /dev/null @@ -1,44 +0,0 @@ -include(CheckIncludeFile) -include(CheckIncludeFiles) -include(CheckFunctionExists) -include(CheckSymbolExists) -include(TestBigEndian) - -check_include_file("dlfcn.h" HAVE_DLFCN_H) -check_include_file("fcntl.h" HAVE_FCNTL_H) -check_include_file("inttypes.h" HAVE_INTTYPES_H) -check_include_file("memory.h" HAVE_MEMORY_H) -check_include_file("stdint.h" HAVE_STDINT_H) -check_include_file("stdlib.h" HAVE_STDLIB_H) -check_include_file("strings.h" HAVE_STRINGS_H) -check_include_file("string.h" HAVE_STRING_H) -check_include_file("sys/stat.h" HAVE_SYS_STAT_H) -check_include_file("sys/types.h" HAVE_SYS_TYPES_H) -check_include_file("unistd.h" HAVE_UNISTD_H) - -check_function_exists("getpagesize" HAVE_GETPAGESIZE) -check_function_exists("bcopy" HAVE_BCOPY) -check_symbol_exists("memmove" "string.h" HAVE_MEMMOVE) -check_function_exists("mmap" HAVE_MMAP) - -#/* Define to 1 if you have the ANSI C header files. */ -check_include_files("stdlib.h;stdarg.h;string.h;float.h" STDC_HEADERS) - -test_big_endian(WORDS_BIGENDIAN) -#/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */ -if(WORDS_BIGENDIAN) - set(BYTEORDER 4321) -else(WORDS_BIGENDIAN) - set(BYTEORDER 1234) -endif(WORDS_BIGENDIAN) - -if(HAVE_SYS_TYPES_H) - check_symbol_exists("off_t" "sys/types.h" OFF_T) - check_symbol_exists("size_t" "sys/types.h" SIZE_T) -else(HAVE_SYS_TYPES_H) - set(OFF_T "long") - set(SIZE_T "unsigned") -endif(HAVE_SYS_TYPES_H) - -configure_file(expat_config.h.cmake expat_config.h) -add_definitions(-DHAVE_EXPAT_CONFIG_H) diff --git a/lib-src/expat/MANIFEST b/lib-src/expat/MANIFEST deleted file mode 100644 index 7a020dc05..000000000 --- a/lib-src/expat/MANIFEST +++ /dev/null @@ -1,141 +0,0 @@ -amiga/launch.c -amiga/expat_68k.c -amiga/expat_68k.h -amiga/expat_68k_handler_stubs.c -amiga/expat_base.h -amiga/expat_vectors.c -amiga/expat_lib.c -amiga/expat.xml -amiga/README.txt -amiga/Makefile -amiga/include/proto/expat.h -amiga/include/libraries/expat.h -amiga/include/interfaces/expat.h -amiga/include/inline4/expat.h -bcb5/README.txt -bcb5/all_projects.bpg -bcb5/elements.bpf -bcb5/elements.bpr -bcb5/elements.mak -bcb5/expat.bpf -bcb5/expat.bpr -bcb5/expat.mak -bcb5/expat_static.bpf -bcb5/expat_static.bpr -bcb5/expat_static.mak -bcb5/expatw.bpf -bcb5/expatw.bpr -bcb5/expatw.mak -bcb5/expatw_static.bpf -bcb5/expatw_static.bpr -bcb5/expatw_static.mak -bcb5/libexpat_mtd.def -bcb5/libexpatw_mtd.def -bcb5/makefile.mak -bcb5/outline.bpf -bcb5/outline.bpr -bcb5/outline.mak -bcb5/setup.bat -bcb5/xmlwf.bpf -bcb5/xmlwf.bpr -bcb5/xmlwf.mak -doc/expat.png -doc/reference.html -doc/style.css -doc/valid-xhtml10.png -doc/xmlwf.1 -doc/xmlwf.sgml -CMakeLists.txt -CMake.README -COPYING -Changes -ConfigureChecks.cmake -MANIFEST -Makefile.in -README -configure -configure.in -expat_config.h.in -expat_config.h.cmake -expat.pc.in -expat.dsw -aclocal.m4 -conftools/PrintPath -conftools/ac_c_bigendian_cross.m4 -conftools/expat.m4 -conftools/get-version.sh -conftools/mkinstalldirs -conftools/config.guess -conftools/config.sub -conftools/install-sh -conftools/ltmain.sh -m4/libtool.m4 -m4/ltversion.m4 -m4/ltoptions.m4 -m4/ltsugar.m4 -m4/lt~obsolete.m4 -examples/elements.c -examples/elements.dsp -examples/outline.c -examples/outline.dsp -lib/Makefile.MPW -lib/amigaconfig.h -lib/ascii.h -lib/asciitab.h -lib/expat.dsp -lib/expat.h -lib/expat_external.h -lib/expat_static.dsp -lib/expatw.dsp -lib/expatw_static.dsp -lib/iasciitab.h -lib/internal.h -lib/latin1tab.h -lib/libexpat.def -lib/libexpatw.def -lib/macconfig.h -lib/nametab.h -lib/utf8tab.h -lib/winconfig.h -lib/xmlparse.c -lib/xmlrole.c -lib/xmlrole.h -lib/xmltok.c -lib/xmltok.h -lib/xmltok_impl.c -lib/xmltok_impl.h -lib/xmltok_ns.c -tests/benchmark/README.txt -tests/benchmark/benchmark.c -tests/benchmark/benchmark.dsp -tests/benchmark/benchmark.dsw -tests/README.txt -tests/chardata.c -tests/chardata.h -tests/minicheck.c -tests/minicheck.h -tests/runtests.c -tests/runtestspp.cpp -tests/xmltest.sh -vms/README.vms -vms/descrip.mms -vms/expat_config.h -win32/MANIFEST.txt -win32/README.txt -win32/expat.iss -xmlwf/codepage.c -xmlwf/codepage.h -xmlwf/ct.c -xmlwf/filemap.h -xmlwf/readfilemap.c -xmlwf/unixfilemap.c -xmlwf/win32filemap.c -xmlwf/xmlfile.c -xmlwf/xmlfile.h -xmlwf/xmlmime.c -xmlwf/xmlmime.h -xmlwf/xmltchar.h -xmlwf/xmlurl.h -xmlwf/xmlwf.c -xmlwf/xmlwf.dsp -xmlwf/xmlwin32url.cxx diff --git a/lib-src/expat/Makefile.in b/lib-src/expat/Makefile.in deleted file mode 100644 index 9c0f5d49f..000000000 --- a/lib-src/expat/Makefile.in +++ /dev/null @@ -1,201 +0,0 @@ -################################################################ -# Process this file with top-level configure script to produce Makefile -# -# Copyright 2000 Clark Cooper -# -# This file is part of EXPAT. -# -# EXPAT is free software; you can redistribute it and/or modify it -# under the terms of the License (based on the MIT/X license) contained -# in the file COPYING that comes with this distribution. -# -# EXPAT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -# SOFTWARE OR THE USE OR OTHER DEALINGS IN EXPAT. -# - -SHELL = @SHELL@ - -srcdir = @srcdir@ -top_srcdir = @top_srcdir@ -VPATH = @srcdir@ - -prefix = @prefix@ -exec_prefix = @exec_prefix@ - -bindir = @bindir@ -libdir = @libdir@ -includedir = @includedir@ -man1dir = @mandir@/man1 -pkgconfigdir = $(libdir)/pkgconfig - -top_builddir = . - - -INSTALL = @INSTALL@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_DATA = @INSTALL_DATA@ -mkinstalldirs = $(SHELL) $(top_srcdir)/conftools/mkinstalldirs - -MANFILE = $(srcdir)/doc/xmlwf.1 -APIHEADER = $(srcdir)/lib/expat.h $(srcdir)/lib/expat_external.h -LIBRARY = libexpat.la - -DESTDIR = $(INSTALL_ROOT) - -default: buildlib xmlwf/xmlwf@EXEEXT@ - -buildlib: $(LIBRARY) expat.pc - -all: $(LIBRARY) expat.pc xmlwf/xmlwf@EXEEXT@ examples/elements examples/outline - -clean: - cd lib && rm -f $(LIBRARY) *.@OBJEXT@ *.lo && rm -rf .libs _libs - cd xmlwf && rm -f xmlwf *.@OBJEXT@ *.lo && rm -rf .libs _libs - cd examples && rm -f elements outline *.@OBJEXT@ *.lo && rm -rf .libs _libs - cd tests && rm -rf .libs runtests runtests.@OBJEXT@ runtestspp runtestspp.@OBJEXT@ - cd tests && rm -f chardata.@OBJEXT@ minicheck.@OBJEXT@ - rm -rf .libs libexpat.la - rm -f examples/core tests/core xmlwf/core - -clobber: clean - -distclean: clean - rm -f expat_config.h config.status config.log config.cache libtool - rm -f Makefile expat.pc - -extraclean: distclean - rm -f expat_config.h.in configure - rm -f aclocal.m4 m4/* - rm -f conftools/ltmain.sh conftools/install-sh conftools/config.guess conftools/config.sub - -check: tests/runtests tests/runtestspp - tests/runtests - tests/runtestspp - -install: xmlwf/xmlwf@EXEEXT@ installlib - $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(man1dir) - $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) xmlwf/xmlwf@EXEEXT@ $(DESTDIR)$(bindir)/xmlwf - $(INSTALL_DATA) $(MANFILE) $(DESTDIR)$(man1dir) - -installlib: $(LIBRARY) $(APIHEADER) expat.pc - $(mkinstalldirs) $(DESTDIR)$(libdir) $(DESTDIR)$(includedir) $(DESTDIR)$(pkgconfigdir) - $(LIBTOOL) --mode=install $(INSTALL) $(LIBRARY) $(DESTDIR)$(libdir)/$(LIBRARY) - for FN in $(APIHEADER) ; do $(INSTALL_DATA) $$FN $(DESTDIR)$(includedir) ; done - $(INSTALL_DATA) expat.pc $(DESTDIR)$(pkgconfigdir)/expat.pc - -uninstall: uninstalllib - $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(bindir)/xmlwf@EXEEXT@ - rm -f $(DESTDIR)$(man1dir)/xmlwf.1 - -uninstalllib: - $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(libdir)/$(LIBRARY) - rm -f $(DESTDIR)$(includedir)/expat.h - rm -f $(DESTDIR)$(includedir)/expat_external.h - rm -f $(DESTDIR)$(pkgconfigdir)/expat.pc - -# for VPATH builds (invoked by configure) -mkdir-init: - @for d in lib xmlwf examples tests ; do \ - (mkdir $$d 2> /dev/null || test 1) ; \ - done - -CC = @CC@ -CXX = @CXX@ -LIBTOOL = @LIBTOOL@ - -INCLUDES = -I$(srcdir)/lib -I. -LDFLAGS = @LDFLAGS@ -CPPFLAGS = @CPPFLAGS@ -DHAVE_EXPAT_CONFIG_H -CFLAGS = @CFLAGS@ -CXXFLAGS = @CXXFLAGS@ -VSNFLAG = -version-info @LIBCURRENT@:@LIBREVISION@:@LIBAGE@ - -### autoconf this? -LTFLAGS = --silent - -COMPILE = $(CC) $(INCLUDES) $(CFLAGS) $(DEFS) $(CPPFLAGS) -CXXCOMPILE = $(CXX) $(INCLUDES) $(CXXFLAGS) $(DEFS) $(CPPFLAGS) -LTCOMPILE = $(LIBTOOL) $(LTFLAGS) --mode=compile $(COMPILE) -LINK_LIB = $(LIBTOOL) $(LTFLAGS) --mode=link $(COMPILE) -no-undefined $(VSNFLAG) -rpath $(libdir) $(LDFLAGS) -o $@ -LINK_EXE = $(LIBTOOL) $(LTFLAGS) --mode=link $(COMPILE) $(LDFLAGS) -o $@ -LINK_CXX_EXE = $(LIBTOOL) $(LTFLAGS) --mode=link $(CXXCOMPILE) $(LDFLAGS) -o $@ - -LIB_OBJS = lib/xmlparse.lo lib/xmltok.lo lib/xmlrole.lo -$(LIBRARY): $(LIB_OBJS) - $(LINK_LIB) $(LIB_OBJS) - -expat.pc: $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status $@ - -lib/xmlparse.lo: lib/xmlparse.c lib/expat.h lib/xmlrole.h lib/xmltok.h \ - $(top_builddir)/expat_config.h lib/expat_external.h lib/internal.h - -lib/xmlrole.lo: lib/xmlrole.c lib/ascii.h lib/xmlrole.h \ - $(top_builddir)/expat_config.h lib/expat_external.h lib/internal.h - -lib/xmltok.lo: lib/xmltok.c lib/xmltok_impl.c lib/xmltok_ns.c \ - lib/ascii.h lib/asciitab.h lib/iasciitab.h lib/latin1tab.h \ - lib/nametab.h lib/utf8tab.h lib/xmltok.h lib/xmltok_impl.h \ - $(top_builddir)/expat_config.h lib/expat_external.h lib/internal.h - - -XMLWF_OBJS = xmlwf/xmlwf.@OBJEXT@ xmlwf/xmlfile.@OBJEXT@ xmlwf/codepage.@OBJEXT@ xmlwf/@FILEMAP@.@OBJEXT@ -xmlwf/xmlwf.@OBJEXT@: xmlwf/xmlwf.c -xmlwf/xmlfile.@OBJEXT@: xmlwf/xmlfile.c -xmlwf/codepage.@OBJEXT@: xmlwf/codepage.c -xmlwf/@FILEMAP@.@OBJEXT@: xmlwf/@FILEMAP@.c -xmlwf/xmlwf@EXEEXT@: $(XMLWF_OBJS) $(LIBRARY) - $(LINK_EXE) $(XMLWF_OBJS) $(LIBRARY) - -examples/elements.@OBJEXT@: examples/elements.c -examples/elements: examples/elements.@OBJEXT@ $(LIBRARY) - $(LINK_EXE) $< $(LIBRARY) - -examples/outline.@OBJEXT@: examples/outline.c -examples/outline: examples/outline.@OBJEXT@ $(LIBRARY) - $(LINK_EXE) $< $(LIBRARY) - -tests/chardata.@OBJEXT@: tests/chardata.c tests/chardata.h -tests/minicheck.@OBJEXT@: tests/minicheck.c tests/minicheck.h -tests/runtests.@OBJEXT@: tests/runtests.c tests/chardata.h -tests/runtests: tests/runtests.@OBJEXT@ tests/chardata.@OBJEXT@ tests/minicheck.@OBJEXT@ $(LIBRARY) - $(LINK_EXE) tests/runtests.@OBJEXT@ tests/chardata.@OBJEXT@ tests/minicheck.@OBJEXT@ $(LIBRARY) -tests/runtestspp.@OBJEXT@: tests/runtestspp.cpp tests/runtests.c tests/chardata.h -tests/runtestspp: tests/runtestspp.@OBJEXT@ tests/chardata.@OBJEXT@ tests/minicheck.@OBJEXT@ $(LIBRARY) - $(LINK_CXX_EXE) tests/runtestspp.@OBJEXT@ tests/chardata.@OBJEXT@ tests/minicheck.@OBJEXT@ $(LIBRARY) - -tests/benchmark/benchmark.@OBJEXT@: tests/benchmark/benchmark.c -tests/benchmark/benchmark: tests/benchmark/benchmark.@OBJEXT@ $(LIBRARY) - $(LINK_EXE) tests/benchmark/benchmark.@OBJEXT@ $(LIBRARY) - -run-benchmark: tests/benchmark/benchmark - tests/benchmark/benchmark@EXEEXT@ -n $(top_srcdir)/../testdata/largefiles/recset.xml 65535 3 - -tests/xmlts.zip: - wget --output-document=tests/xmlts.zip \ - http://www.w3.org/XML/Test/xmlts20080827.zip - -tests/XML-Test-Suite: tests/xmlts.zip - cd tests && unzip -q xmlts.zip - -run-xmltest: xmlwf/xmlwf@EXEEXT@ tests/XML-Test-Suite - tests/xmltest.sh - -.SUFFIXES: .c .cpp .lo .@OBJEXT@ - -.cpp.@OBJEXT@: - $(CXXCOMPILE) -o $@ -c $< -.c.@OBJEXT@: - $(COMPILE) -o $@ -c $< -.c.lo: - $(LTCOMPILE) -o $@ -c $< - -.PHONY: buildlib all \ - clean distclean extraclean maintainer-clean \ - dist distdir \ - install uninstall diff --git a/lib-src/expat/README b/lib-src/expat/README deleted file mode 100644 index 1f88467d1..000000000 --- a/lib-src/expat/README +++ /dev/null @@ -1,139 +0,0 @@ - - Expat, Release 2.1.0 - -This is Expat, a C library for parsing XML, written by James Clark. -Expat is a stream-oriented XML parser. This means that you register -handlers with the parser before starting the parse. These handlers -are called when the parser discovers the associated structures in the -document being parsed. A start tag is an example of the kind of -structures for which you may register handlers. - -Windows users should use the expat_win32bin package, which includes -both precompiled libraries and executables, and source code for -developers. - -Expat is free software. You may copy, distribute, and modify it under -the terms of the License contained in the file COPYING distributed -with this package. This license is the same as the MIT/X Consortium -license. - -Versions of Expat that have an odd minor version (the middle number in -the release above), are development releases and should be considered -as beta software. Releases with even minor version numbers are -intended to be production grade software. - -If you are building Expat from a check-out from the CVS repository, -you need to run a script that generates the configure script using the -GNU autoconf and libtool tools. To do this, you need to have -autoconf 2.58 or newer. Run the script like this: - - ./buildconf.sh - -Once this has been done, follow the same instructions as for building -from a source distribution. - -To build Expat from a source distribution, you first run the -configuration shell script in the top level distribution directory: - - ./configure - -There are many options which you may provide to configure (which you -can discover by running configure with the --help option). But the -one of most interest is the one that sets the installation directory. -By default, the configure script will set things up to install -libexpat into /usr/local/lib, expat.h into /usr/local/include, and -xmlwf into /usr/local/bin. If, for example, you'd prefer to install -into /home/me/mystuff/lib, /home/me/mystuff/include, and -/home/me/mystuff/bin, you can tell configure about that with: - - ./configure --prefix=/home/me/mystuff - -Another interesting option is to enable 64-bit integer support for -line and column numbers and the over-all byte index: - - ./configure CPPFLAGS=-DXML_LARGE_SIZE - -However, such a modification would be a breaking change to the ABI -and is therefore not recommended for general use - e.g. as part of -a Linux distribution - but rather for builds with special requirements. - -After running the configure script, the "make" command will build -things and "make install" will install things into their proper -location. Have a look at the "Makefile" to learn about additional -"make" options. Note that you need to have write permission into -the directories into which things will be installed. - -If you are interested in building Expat to provide document -information in UTF-16 encoding rather than the default UTF-8, follow -these instructions (after having run "make distclean"): - - 1. For UTF-16 output as unsigned short (and version/error - strings as char), run: - - ./configure CPPFLAGS=-DXML_UNICODE - - For UTF-16 output as wchar_t (incl. version/error strings), - run: - - ./configure CFLAGS="-g -O2 -fshort-wchar" \ - CPPFLAGS=-DXML_UNICODE_WCHAR_T - - 2. Edit the MakeFile, changing: - - LIBRARY = libexpat.la - - to: - - LIBRARY = libexpatw.la - - (Note the additional "w" in the library name.) - - 3. Run "make buildlib" (which builds the library only). - Or, to save step 2, run "make buildlib LIBRARY=libexpatw.la". - - 4. Run "make installlib" (which installs the library only). - Or, if step 2 was omitted, run "make installlib LIBRARY=libexpatw.la". - -Using DESTDIR or INSTALL_ROOT is enabled, with INSTALL_ROOT being the default -value for DESTDIR, and the rest of the make file using only DESTDIR. -It works as follows: - $ make install DESTDIR=/path/to/image -overrides the in-makefile set DESTDIR, while both - $ INSTALL_ROOT=/path/to/image make install - $ make install INSTALL_ROOT=/path/to/image -use DESTDIR=$(INSTALL_ROOT), even if DESTDIR eventually is defined in the -environment, because variable-setting priority is -1) commandline -2) in-makefile -3) environment - -Note: This only applies to the Expat library itself, building UTF-16 versions -of xmlwf and the tests is currently not supported. - -Note for Solaris users: The "ar" command is usually located in -"/usr/ccs/bin", which is not in the default PATH. You will need to -add this to your path for the "make" command, and probably also switch -to GNU make (the "make" found in /usr/ccs/bin does not seem to work -properly -- appearantly it does not understand .PHONY directives). If -you're using ksh or bash, use this command to build: - - PATH=/usr/ccs/bin:$PATH make - -When using Expat with a project using autoconf for configuration, you -can use the probing macro in conftools/expat.m4 to determine how to -include Expat. See the comments at the top of that file for more -information. - -A reference manual is available in the file doc/reference.html in this -distribution. - -The homepage for this project is http://www.libexpat.org/. There -are links there to connect you to the bug reports page. If you need -to report a bug when you don't have access to a browser, you may also -send a bug report by email to expat-bugs@mail.libexpat.org. - -Discussion related to the direction of future expat development takes -place on expat-discuss@mail.libexpat.org. Archives of this list and -other Expat-related lists may be found at: - - http://mail.libexpat.org/mailman/listinfo/ diff --git a/lib-src/expat/amiga/Makefile b/lib-src/expat/amiga/Makefile deleted file mode 100644 index c6d126199..000000000 --- a/lib-src/expat/amiga/Makefile +++ /dev/null @@ -1,336 +0,0 @@ -# -# Makefile for AmigaOS -# - -.PHONY: help all check clean package -.PHONY: clib2 newlib library so - -vpath %.c ../lib ../examples ../xmlwf ../tests ../tests/benchmark -vpath %.h ../lib ../tests - -############################################################################# - -help: - @echo "Requires:" - @echo " AmigaOS 4.x" - @echo " SDK 53.13" - @echo "" - @echo "Targets:" - @echo " all - make libraries, xmlwf, examples and runs tests" - @echo " install - install expat libraries and tools into SDK" - @echo " clean - clean object files" - @echo " check - run all the tests" - @echo " package - prepare distribution archive" - -all: clib2 newlib library so check - -clib2: clib2/libexpat.a clib2/xmlwf clib2/elements clib2/outline clib2/runtests clib2/benchmark - -newlib: newlib/libexpat.a newlib/xmlwf newlib/elements newlib/outline newlib/runtests newlib/benchmark - -library: libs/expat.library libs/xmlwf libs/elements libs/outline libs/runtests libs/benchmark - -so: so/libexpat.so so/xmlwf so/elements so/outline so/runtests so/benchmark - -check: clib2/runtests newlib/runtests libs/runtests so/runtests - clib2/runtests - newlib/runtests - libs/runtests - so/runtests - -clean: - -delete clib2/#?.o quiet - -delete newlib/#?.o quiet - -delete libs/#?.o quiet - -delete so/#?.o quiet - -package: - $(MAKE) all - -delete T:expat all force quiet - makedir all T:expat/Workbench/Libs - copy clone libs/expat.library T:expat/Workbench/Libs - makedir all T:expat/Workbench/SObjs - copy clone so/libexpat.so T:expat/Workbench/SObjs - makedir all T:expat/SDK/Local/C - copy clone libs/xmlwf T:expat/SDK/Local/C - makedir all T:expat/SDK/Local/clib2/lib - copy clone clib2/libexpat.a T:expat/SDK/Local/clib2/lib - makedir all T:expat/SDK/Local/newlib/lib - copy clone newlib/libexpat.a T:expat/SDK/Local/newlib/lib - makedir all T:expat/SDK/Local/common/include - copy clone /lib/expat.h /lib/expat_external.h T:expat/SDK/Local/common/include - makedir all T:expat/SDK/Include/include_h/inline4 - copy clone include/inline4/expat.h T:expat/SDK/Include/include_h/inline4 - makedir all T:expat/SDK/Include/include_h/interfaces - copy clone include/interfaces/expat.h T:expat/SDK/Include/include_h/interfaces - makedir all T:expat/SDK/Include/include_h/libraries - copy clone include/libraries/expat.h T:expat/SDK/Include/include_h/libraries - makedir all T:expat/SDK/Include/include_h/proto - copy clone include/proto/expat.h T:expat/SDK/Include/include_h/proto - makedir all T:expat/SDK/Documentation/Libs/Expat - copy clone /COPYING T:expat/SDK/Documentation/Libs/Expat - copy clone /README T:expat/SDK/Documentation/Libs/Expat - copy clone README.txt T:expat/SDK/Documentation/Libs/Expat/README.AmigaOS - -delete expat.lha - lha -r a expat.lha T:expat - -############################################################################# - -CC := gcc -LIBTOOL := ar -STRIP := strip - -CFLAGS := -DNDEBUG -O3 -LTFLAGS := -crs -STRIPFLAGS := -R.comment - -############################################################################# - -clib2/libexpat.a: clib2/xmlparse.o clib2/xmltok.o clib2/xmlrole.o - $(LIBTOOL) $(LTFLAGS) $@ $^ - protect $@ -e - -clib2/xmlparse.o: xmlparse.c expat.h xmlrole.h xmltok.h \ - expat_external.h internal.h amigaconfig.h - -clib2/xmlrole.o: xmlrole.c ascii.h xmlrole.h expat_external.h \ - internal.h amigaconfig.h - -clib2/xmltok.o: xmltok.c xmltok_impl.c xmltok_ns.c ascii.h asciitab.h \ - iasciitab.h latin1tab.h nametab.h utf8tab.h xmltok.h xmltok_impl.h \ - expat_external.h internal.h amigaconfig.h - -############################################################################# - -clib2/xmlwf: clib2/xmlwf.o clib2/xmlfile.o clib2/codepage.o clib2/readfilemap.o - $(CC) -mcrt=clib2 $^ -o $@ clib2/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -clib2/xmlwf.o: xmlwf.c - -clib2/xmlfile.o: xmlfile.c - -clib2/codepage.o: codepage.c - -clib2/readfilemap.o: readfilemap.c - -############################################################################# - -clib2/elements: clib2/elements.o - $(CC) -mcrt=clib2 $^ -o $@ clib2/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -clib2/elements.o: elements.c - -############################################################################# - -clib2/outline: clib2/outline.o - $(CC) -mcrt=clib2 $^ -o $@ clib2/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -clib2/outline.o: outline.c - -############################################################################# - -clib2/runtests: clib2/runtests.o clib2/chardata.o clib2/minicheck.o - $(CC) -mcrt=clib2 $^ -o $@ clib2/libexpat.a - -clib2/chardata.o: chardata.c chardata.h - -clib2/minicheck.o: minicheck.c minicheck.h - -clib2/runtests.o: runtests.c chardata.h - -############################################################################# - -clib2/benchmark: clib2/benchmark.o - $(CC) -mcrt=clib2 $^ -o $@ clib2/libexpat.a -lm - -clib2/benchmark.o: benchmark.c - -############################################################################# - -newlib/libexpat.a: newlib/xmlparse.o newlib/xmltok.o newlib/xmlrole.o - $(LIBTOOL) $(LTFLAGS) $@ $^ - protect $@ -e - -newlib/xmlparse.o: xmlparse.c expat.h xmlrole.h xmltok.h \ - expat_external.h internal.h amigaconfig.h - -newlib/xmlrole.o: xmlrole.c ascii.h xmlrole.h expat_external.h \ - internal.h amigaconfig.h - -newlib/xmltok.o: xmltok.c xmltok_impl.c xmltok_ns.c ascii.h asciitab.h \ - iasciitab.h latin1tab.h nametab.h utf8tab.h xmltok.h xmltok_impl.h \ - expat_external.h internal.h amigaconfig.h - -############################################################################# - -newlib/xmlwf: newlib/xmlwf.o newlib/xmlfile.o newlib/codepage.o newlib/readfilemap.o - $(CC) -mcrt=newlib $^ -o $@ newlib/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -newlib/xmlwf.o: xmlwf.c - -newlib/xmlfile.o: xmlfile.c - -newlib/codepage.o: codepage.c - -newlib/readfilemap.o: readfilemap.c - -############################################################################# - -newlib/elements: newlib/elements.o - $(CC) -mcrt=newlib $^ -o $@ newlib/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -newlib/elements.o: elements.c - -############################################################################# - -newlib/outline: newlib/outline.o - $(CC) -mcrt=newlib $^ -o $@ newlib/libexpat.a - $(STRIP) $(STRIPFLAGS) $@ - -newlib/outline.o: outline.c - -############################################################################# - -newlib/runtests: newlib/runtests.o newlib/chardata.o newlib/minicheck.o - $(CC) -mcrt=newlib $^ -o $@ newlib/libexpat.a - -newlib/chardata.o: chardata.c chardata.h - -newlib/minicheck.o: minicheck.c minicheck.h - -newlib/runtests.o: runtests.c chardata.h - -############################################################################# - -newlib/benchmark: newlib/benchmark.o - $(CC) -mcrt=newlib $^ -o $@ newlib/libexpat.a - -newlib/benchmark.o: benchmark.c - -############################################################################# - -libs/expat.library: libs/expat_lib.o libs/expat_68k.o libs/expat_68k_handler_stubs.o libs/expat_vectors.o newlib/libexpat.a - $(CC) -mcrt=newlib -nostartfiles $^ -o $@ newlib/libexpat.a -Wl,--cref,-M,-Map=$@.map - protect $@ -e - $(STRIP) $(STRIPFLAGS) $@ - -libs/expat_lib.o: expat_lib.c expat_base.h - -libs/expat_68k.o: expat_68k.c expat_68k.h expat_base.h - -libs/expat_68k_handler_stubs.o: expat_68k_handler_stubs.c expat_68k.h - -libs/expat_vectors.o: expat_vectors.c - -libs/launch.o: launch.c - -############################################################################# - -libs/xmlwf: libs/xmlwf.o libs/xmlfile.o libs/codepage.o libs/readfilemap.o libs/launch.o - $(CC) -mcrt=newlib $^ -o $@ - $(STRIP) $(STRIPFLAGS) $@ - -libs/xmlwf.o: xmlwf.c - -libs/xmlfile.o: xmlfile.c - -libs/codepage.o: codepage.c - -libs/readfilemap.o: readfilemap.c - -############################################################################# - -libs/elements: libs/elements.o libs/launch.o - $(CC) -mcrt=newlib $^ -o $@ - $(STRIP) $(STRIPFLAGS) $@ - -libs/elements.o: elements.c - -############################################################################# - -libs/outline: libs/outline.o libs/launch.o - $(CC) -mcrt=newlib $^ -o $@ - $(STRIP) $(STRIPFLAGS) $@ - -libs/outline.o: outline.c - -############################################################################# - -libs/runtests: libs/runtests.o libs/chardata.o libs/minicheck.o libs/launch.o - $(CC) -mcrt=newlib $^ -o $@ - -libs/chardata.o: chardata.c chardata.h - -libs/minicheck.o: minicheck.c minicheck.h - -libs/runtests.o: runtests.c chardata.h - -############################################################################# - -libs/benchmark: libs/benchmark.o libs/launch.o - $(CC) -mcrt=newlib $^ -o $@ - -libs/benchmark.o: benchmark.c - -############################################################################# - -so/libexpat.so: so/xmlparse.o so/xmltok.o so/xmlrole.o - $(CC) -mcrt=newlib -shared -o $@ $^ - protect $@ -e - -so/xmlparse.o: xmlparse.c expat.h xmlrole.h xmltok.h \ - expat_external.h internal.h amigaconfig.h - -so/xmlrole.o: xmlrole.c ascii.h xmlrole.h expat_external.h \ - internal.h amigaconfig.h - -so/xmltok.o: xmltok.c xmltok_impl.c xmltok_ns.c ascii.h asciitab.h \ - iasciitab.h latin1tab.h nametab.h utf8tab.h xmltok.h xmltok_impl.h \ - expat_external.h internal.h amigaconfig.h - -############################################################################# - -so/xmlwf: newlib/xmlwf.o newlib/xmlfile.o newlib/codepage.o newlib/readfilemap.o - $(CC) -mcrt=newlib -use-dynld $^ -o $@ -Lso -lexpat - $(STRIP) $(STRIPFLAGS) $@ - -############################################################################# - -so/elements: newlib/elements.o - $(CC) -mcrt=newlib -use-dynld $^ -o $@ -Lso -lexpat - $(STRIP) $(STRIPFLAGS) $@ - -############################################################################# - -so/outline: newlib/outline.o - $(CC) -mcrt=newlib -use-dynld $^ -o $@ -Lso -lexpat - $(STRIP) $(STRIPFLAGS) $@ - -############################################################################# - -so/runtests: newlib/runtests.o newlib/chardata.o newlib/minicheck.o - $(CC) -mcrt=newlib -use-dynld $^ -o $@ -Lso -lexpat - -############################################################################# - -so/benchmark: newlib/benchmark.o - $(CC) -mcrt=newlib -use-dynld $^ -o $@ -Lso -lexpat - -############################################################################# - -clib2/%.o: %.c - $(CC) -mcrt=clib2 $(CFLAGS) -I../lib -c $< -o $@ - -newlib/%.o: %.c - $(CC) -mcrt=newlib $(CFLAGS) -I../lib -c $< -o $@ - -libs/%.o: %.c - $(CC) -mcrt=newlib $(CFLAGS) -D__USE_INLINE__ -I. -Iinclude -Iinclude/libraries -I../lib -c $< -o $@ - -so/%.o: %.c - $(CC) -mcrt=newlib $(CFLAGS) -fPIC -I../lib -c $< -o $@ diff --git a/lib-src/expat/amiga/README.txt b/lib-src/expat/amiga/README.txt deleted file mode 100644 index 3ba9267ef..000000000 --- a/lib-src/expat/amiga/README.txt +++ /dev/null @@ -1,98 +0,0 @@ -SUMMARY -======= -This is a port of expat for AmigaOS 4.x which includes the -SDK, some XML tools and the libraries. - -Four library flavours are supported: -1. static clib2 (libexpat.a) -2. static newlib (libexpat.a) -3. AmigaOS library (expat.library) -4. AmigaOS shared object library (libexpat.so) - -The AmigaOS library version is based on the work of Fredrik Wikstrom. - - -BUILDING -======== -To build all the library flavours, all the tools, examples and run the -test suite, simply type 'make all' in the amiga subdirectory. - - -INSTALLATION -============ -To install expat into the standard AmigaOS SDK type 'make install' -in the amiga subdirectory. - - -CONFIGURATION -============= -You may want to edit the lib/amigaconfig.h file to remove -DTD and/or XML namespace support if they are not required by your -specific application for a smaller and faster implementation. - - -SOURCE CODE -=========== -The source code is actively maintained and merged with the official -Expat repository available at http://expat.sourceforge.net/ - - -HISTORY -======= -53.1 - bumped version to match AmigaOS streaming - - modified to remove all global variables (except INewLib) - - removed replacements for malloc(), etc. which are now - handled by the respective C library - - compiled with the latest binutils which bumps the - AMIGAOS_DYNVERSION to 2 for the libexpat.so target - - now strips the expat.library binary - -5.2 - fixed XML_Parse 68k stub which enables xmlviewer to work - without crashing - - added some new functions to the 68k jump table available - in the latest expat.library for AmigaOS 3.x - - patches provided by Fredrik Wikstrom - -5.1 - fixed package archive which was missing libexpat.so - - fixed library protection bits - - fixed up copyright notices - -5.0 - integrated 68k patches from Fredrik Wikstrom which means - expat.library is now callable from 68k code - - bumped version for the addition of the 68k interface so - executables can explicitly ask for version 5 and know - it includes the 68k interface - - refactored Makefile to avoid recursive make calls and - build all the library flavours - - added static newlib version - - added shared objects version - - added package target to Makefile - - compiled with SDK 53.13 (GCC 4.2.4) at -O3 - -4.2 - updated to correspond to Expat 2.0.1 release - - bumped copyright banners and versions - - simplified amigaconfig.h - - updated include/libraries/expat.h file - - modified launch.c to use contructor/deconstructor - - removed need for amiga_main() from expat utilities - -4.1 - fixed memory freeing bug in shared library version - - now allocates shared memory - -4.0 - updated for corresponding Expat 2.0 release - - some minor CVS related changes - -3.1 - removed obsolete sfd file - - added library description xml file - - refactored Makefile - - removed extraneous VARARGS68K keywords - - reworked default memory handling functions in shared lib - - updated amigaconfig.h - -3.0 - initial release - - based on expat 1.95.8 - - -TO DO -===== -- wide character support (UTF-16) diff --git a/lib-src/expat/amiga/expat.xml b/lib-src/expat/amiga/expat.xml deleted file mode 100644 index d6aeae2e3..000000000 --- a/lib-src/expat/amiga/expat.xml +++ /dev/null @@ -1,264 +0,0 @@ - - - - - libraries/expat.h - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/lib-src/expat/amiga/expat_68k.c b/lib-src/expat/amiga/expat_68k.c deleted file mode 100644 index aa4c6e270..000000000 --- a/lib-src/expat/amiga/expat_68k.c +++ /dev/null @@ -1,939 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -/* -** Note: This file was originally automatically generated by fdtrans. -*/ - -#ifdef __USE_INLINE__ -#undef __USE_INLINE__ -#endif - -#include -#include -#include -#include -#include -#include "expat_68k.h" -#include "expat_base.h" - - -STATIC ULONG stub_OpenPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct LibraryManagerInterface *Self = (struct LibraryManagerInterface *) ExtLib->ILibrary; - - return (ULONG) Self->Open(0); -} -struct EmuTrap stub_Open = { TRAPINST, TRAPTYPE, stub_OpenPPC }; - -STATIC ULONG stub_ClosePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct LibraryManagerInterface *Self = (struct LibraryManagerInterface *) ExtLib->ILibrary; - - return (ULONG) Self->Close(); -} -struct EmuTrap stub_Close = { TRAPINST, TRAPTYPE, stub_ClosePPC }; - -STATIC ULONG stub_ExpungePPC(ULONG *regarray) -{ - return 0UL; -} -struct EmuTrap stub_Expunge = { TRAPINST, TRAPTYPE, stub_ExpungePPC }; - -STATIC ULONG stub_ReservedPPC(ULONG *regarray) -{ - return 0UL; -} -struct EmuTrap stub_Reserved = { TRAPINST, TRAPTYPE, stub_ReservedPPC }; - -static M68kXML_Parser stub_XML_ParserCreatePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - struct ExecIFace *IExec = ((struct ExpatBase *)Self->Data.LibBase)->IExec; - - M68kXML_Parser p; - p = IExec->AllocVec(sizeof(*p), MEMF_SHARED|MEMF_CLEAR); - if (p) { - p->p = Self->XML_ParserCreate((const XML_Char *)regarray[8]); - if (p->p) { - p->IExec = IExec; - Self->XML_SetUserData(p->p, p); - return p; - } - IExec->FreeVec(p); - } - return NULL; -} -struct EmuTrap stub_XML_ParserCreate = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParserCreatePPC }; - -static M68kXML_Parser stub_XML_ParserCreateNSPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - struct ExecIFace *IExec = ((struct ExpatBase *)Self->Data.LibBase)->IExec; - - M68kXML_Parser p; - p = IExec->AllocVec(sizeof(*p), MEMF_SHARED|MEMF_CLEAR); - if (p) { - p->p = Self->XML_ParserCreateNS((const XML_Char *)regarray[8], (XML_Char)regarray[0]); - if (p->p) { - p->IExec = IExec; - Self->XML_SetUserData(p->p, p); - return p; - } - IExec->FreeVec(p); - } - return NULL; -} -struct EmuTrap stub_XML_ParserCreateNS = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParserCreateNSPPC }; - -static M68kXML_Parser stub_XML_ParserCreate_MMPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - struct ExecIFace *IExec = ((struct ExpatBase *)Self->Data.LibBase)->IExec; - - M68kXML_Parser p; - p = IExec->AllocVec(sizeof(*p), MEMF_SHARED|MEMF_CLEAR); - if (p) { - p->p = Self->XML_ParserCreate_MM((const XML_Char *)regarray[8], - (const XML_Memory_Handling_Suite *)regarray[9], - (const XML_Char *)regarray[10]); - if (p->p) { - p->IExec = IExec; - Self->XML_SetUserData(p->p, p); - return p; - } - IExec->FreeVec(p); - } - return NULL; -} -struct EmuTrap stub_XML_ParserCreate_MM = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParserCreate_MMPPC }; - -static M68kXML_Parser stub_XML_ExternalEntityParserCreatePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - struct ExecIFace *IExec = ((struct ExpatBase *)Self->Data.LibBase)->IExec; - - M68kXML_Parser p; - p = IExec->AllocVec(sizeof(*p), MEMF_SHARED|MEMF_CLEAR); - if (p) { - p->p = Self->XML_ExternalEntityParserCreate((XML_Parser)regarray[8], - (const XML_Char *)regarray[9], (const XML_Char *)regarray[10]); - if (p->p) { - p->IExec = IExec; - Self->XML_SetUserData(p->p, p); - return p; - } - IExec->FreeVec(p); - } - return NULL; -} -struct EmuTrap stub_XML_ExternalEntityParserCreate = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ExternalEntityParserCreatePPC }; - -static void stub_XML_ParserFreePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - struct ExecIFace *IExec = ((struct ExpatBase *)Self->Data.LibBase)->IExec; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - if (p) { - Self->XML_ParserFree(p->p); - IExec->FreeVec(p); - } -} -struct EmuTrap stub_XML_ParserFree = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParserFreePPC }; - -static int stub_XML_ParsePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_SetUserData(p->p, p); - return Self->XML_Parse(p->p, (const char *)regarray[9], (int)regarray[0], (int)regarray[1]); -} -struct EmuTrap stub_XML_Parse = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParsePPC }; - -static int stub_XML_ParseBufferPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_ParseBuffer(p->p, (int)regarray[0], (int)regarray[1]); -} -struct EmuTrap stub_XML_ParseBuffer = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParseBufferPPC }; - -static void * stub_XML_GetBufferPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetBuffer(p->p, (int)regarray[0]); -} -struct EmuTrap stub_XML_GetBuffer = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetBufferPPC }; - -static void stub_XML_SetStartElementHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startelementhandler = (void *)regarray[9]; - Self->XML_SetStartElementHandler(p->p, _68k_startelementhandler); -} -struct EmuTrap stub_XML_SetStartElementHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetStartElementHandlerPPC }; - -static void stub_XML_SetEndElementHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->endelementhandler = (void *)regarray[9]; - Self->XML_SetEndElementHandler(p->p, _68k_endelementhandler); -} -struct EmuTrap stub_XML_SetEndElementHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEndElementHandlerPPC }; - -static void stub_XML_SetElementHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startelementhandler = (void *)regarray[9]; - p->endelementhandler = (void *)regarray[10]; - Self->XML_SetElementHandler(p->p, _68k_startelementhandler, _68k_endelementhandler); -} -struct EmuTrap stub_XML_SetElementHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetElementHandlerPPC }; - -static void stub_XML_SetCharacterDataHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->chardatahandler = (void *)regarray[9]; - Self->XML_SetCharacterDataHandler(p->p, _68k_chardatahandler); -} -struct EmuTrap stub_XML_SetCharacterDataHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetCharacterDataHandlerPPC }; - -static void stub_XML_SetProcessingInstructionHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->procinsthandler = (void *)regarray[9]; - Self->XML_SetProcessingInstructionHandler(p->p, _68k_procinsthandler); -} -struct EmuTrap stub_XML_SetProcessingInstructionHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetProcessingInstructionHandlerPPC }; - -static void stub_XML_SetCommentHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->commenthandler = (void *)regarray[9]; - Self->XML_SetCommentHandler(p->p, _68k_commenthandler); -} -struct EmuTrap stub_XML_SetCommentHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetCommentHandlerPPC }; - -static void stub_XML_SetStartCdataSectionHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startcdatahandler = (void *)regarray[9]; - Self->XML_SetStartCdataSectionHandler(p->p, _68k_startcdatahandler); -} -struct EmuTrap stub_XML_SetStartCdataSectionHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetStartCdataSectionHandlerPPC }; - -static void stub_XML_SetEndCdataSectionHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->endcdatahandler = (void *)regarray[9]; - Self->XML_SetEndCdataSectionHandler(p->p, _68k_endcdatahandler); -} -struct EmuTrap stub_XML_SetEndCdataSectionHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEndCdataSectionHandlerPPC }; - -static void stub_XML_SetCdataSectionHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startcdatahandler = (void *)regarray[9]; - p->endcdatahandler = (void *)regarray[10]; - Self->XML_SetCdataSectionHandler(p->p, _68k_startcdatahandler, _68k_endcdatahandler); -} -struct EmuTrap stub_XML_SetCdataSectionHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetCdataSectionHandlerPPC }; - -static void stub_XML_SetDefaultHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->defaulthandler = (void *)regarray[9]; - Self->XML_SetDefaultHandler(p->p, _68k_defaulthandler); -} -struct EmuTrap stub_XML_SetDefaultHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetDefaultHandlerPPC }; - -static void stub_XML_SetDefaultHandlerExpandPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->defaulthandlerexp = (void *)regarray[9]; - Self->XML_SetDefaultHandlerExpand(p->p, _68k_defaulthandlerexp); -} -struct EmuTrap stub_XML_SetDefaultHandlerExpand = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetDefaultHandlerExpandPPC }; - -static void stub_XML_SetExternalEntityRefHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->extentrefhandler = (void *)regarray[9]; - Self->XML_SetExternalEntityRefHandler(p->p, _68k_extentrefhandler); -} -struct EmuTrap stub_XML_SetExternalEntityRefHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetExternalEntityRefHandlerPPC }; - -static void stub_XML_SetExternalEntityRefHandlerArgPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->extenthandlerarg = (void *)regarray[9]; -} -struct EmuTrap stub_XML_SetExternalEntityRefHandlerArg = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetExternalEntityRefHandlerArgPPC }; - -static void stub_XML_SetUnknownEncodingHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->unknownenchandler = (void *)regarray[9]; - p->enchandlerarg = (void *)regarray[10]; - Self->XML_SetUnknownEncodingHandler(p->p, _68k_unknownenchandler, p); -} -struct EmuTrap stub_XML_SetUnknownEncodingHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetUnknownEncodingHandlerPPC }; - -static void stub_XML_SetStartNamespaceDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startnamespacehandler = (void *)regarray[9]; - Self->XML_SetStartNamespaceDeclHandler(p->p, _68k_startnamespacehandler); -} -struct EmuTrap stub_XML_SetStartNamespaceDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetStartNamespaceDeclHandlerPPC }; - -static void stub_XML_SetEndNamespaceDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->endnamespacehandler = (void *)regarray[9]; - Self->XML_SetEndNamespaceDeclHandler(p->p, _68k_endnamespacehandler); -} -struct EmuTrap stub_XML_SetEndNamespaceDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEndNamespaceDeclHandlerPPC }; - -static void stub_XML_SetNamespaceDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startnamespacehandler = (void *)regarray[9]; - p->endnamespacehandler = (void *)regarray[10]; - Self->XML_SetNamespaceDeclHandler(p->p, _68k_startnamespacehandler, _68k_endnamespacehandler); -} -struct EmuTrap stub_XML_SetNamespaceDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetNamespaceDeclHandlerPPC }; - -static void stub_XML_SetXmlDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->xmldeclhandler = (void *)regarray[9]; - Self->XML_SetXmlDeclHandler(p->p, _68k_xmldeclhandler); -} -struct EmuTrap stub_XML_SetXmlDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetXmlDeclHandlerPPC }; - -static void stub_XML_SetStartDoctypeDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startdoctypehandler = (void *)regarray[9]; - Self->XML_SetStartDoctypeDeclHandler(p->p, _68k_startdoctypehandler); -} -struct EmuTrap stub_XML_SetStartDoctypeDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetStartDoctypeDeclHandlerPPC }; - -static void stub_XML_SetEndDoctypeDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->enddoctypehandler = (void *)regarray[9]; - Self->XML_SetEndDoctypeDeclHandler(p->p, _68k_enddoctypehandler); -} -struct EmuTrap stub_XML_SetEndDoctypeDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEndDoctypeDeclHandlerPPC }; - -static void stub_XML_SetDoctypeDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->startdoctypehandler = (void *)regarray[9]; - p->enddoctypehandler = (void *)regarray[10]; - Self->XML_SetDoctypeDeclHandler(p->p, _68k_startdoctypehandler, _68k_enddoctypehandler); -} -struct EmuTrap stub_XML_SetDoctypeDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetDoctypeDeclHandlerPPC }; - -static void stub_XML_SetElementDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->elementdeclhandler = (void *)regarray[9]; - Self->XML_SetElementDeclHandler(p->p, _68k_elementdeclhandler); -} -struct EmuTrap stub_XML_SetElementDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetElementDeclHandlerPPC }; - -static void stub_XML_SetAttlistDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->attlistdeclhandler = (void *)regarray[9]; - Self->XML_SetAttlistDeclHandler(p->p, _68k_attlistdeclhandler); -} -struct EmuTrap stub_XML_SetAttlistDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetAttlistDeclHandlerPPC }; - -static void stub_XML_SetEntityDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->entitydeclhandler = (void *)regarray[9]; - Self->XML_SetEntityDeclHandler(p->p, _68k_entitydeclhandler); -} -struct EmuTrap stub_XML_SetEntityDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEntityDeclHandlerPPC }; - -static void stub_XML_SetUnparsedEntityDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->unparseddeclhandler = (void *)regarray[9]; - Self->XML_SetUnparsedEntityDeclHandler(p->p, _68k_unparseddeclhandler); -} -struct EmuTrap stub_XML_SetUnparsedEntityDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetUnparsedEntityDeclHandlerPPC }; - -static void stub_XML_SetNotationDeclHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->notationdeclhandler = (void *)regarray[9]; - Self->XML_SetNotationDeclHandler(p->p, _68k_notationdeclhandler); -} -struct EmuTrap stub_XML_SetNotationDeclHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetNotationDeclHandlerPPC }; - -static void stub_XML_SetNotStandaloneHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->notstandalonehandler = (void *)regarray[9]; - Self->XML_SetNotStandaloneHandler(p->p, _68k_notstandalonehandler); -} -struct EmuTrap stub_XML_SetNotStandaloneHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetNotStandaloneHandlerPPC }; - -static int stub_XML_GetErrorCodePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetErrorCode(p->p); -} -struct EmuTrap stub_XML_GetErrorCode = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetErrorCodePPC }; - -static const XML_LChar * stub_XML_ErrorStringPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - return Self->XML_ErrorString((int)regarray[0]); -} -struct EmuTrap stub_XML_ErrorString = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ErrorStringPPC }; - -static long stub_XML_GetCurrentByteIndexPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetCurrentByteIndex(p->p); -} -struct EmuTrap stub_XML_GetCurrentByteIndex = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetCurrentByteIndexPPC }; - -static int stub_XML_GetCurrentLineNumberPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetCurrentLineNumber(p->p); -} -struct EmuTrap stub_XML_GetCurrentLineNumber = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetCurrentLineNumberPPC }; - -static int stub_XML_GetCurrentColumnNumberPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetCurrentColumnNumber(p->p); -} -struct EmuTrap stub_XML_GetCurrentColumnNumber = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetCurrentColumnNumberPPC }; - -static int stub_XML_GetCurrentByteCountPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetCurrentByteCount(p->p); -} -struct EmuTrap stub_XML_GetCurrentByteCount = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetCurrentByteCountPPC }; - -static const char * stub_XML_GetInputContextPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetInputContext(p->p, (int *)regarray[9], (int *)regarray[10]); -} -struct EmuTrap stub_XML_GetInputContext = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetInputContextPPC }; - -static void stub_XML_SetUserDataPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->handlerarg = (void *)regarray[9]; -} -struct EmuTrap stub_XML_SetUserData = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetUserDataPPC }; - -static void stub_XML_DefaultCurrentPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_DefaultCurrent(p->p); -} -struct EmuTrap stub_XML_DefaultCurrent = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_DefaultCurrentPPC }; - -static void stub_XML_UseParserAsHandlerArgPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->handlerarg = p; -} -struct EmuTrap stub_XML_UseParserAsHandlerArg = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_UseParserAsHandlerArgPPC }; - -static int stub_XML_SetBasePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_SetBase(p->p, (const XML_Char *)regarray[9]); -} -struct EmuTrap stub_XML_SetBase = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetBasePPC }; - -static const XML_Char * stub_XML_GetBasePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetBase(p->p); -} -struct EmuTrap stub_XML_GetBase = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetBasePPC }; - -static int stub_XML_GetSpecifiedAttributeCountPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetSpecifiedAttributeCount(p->p); -} -struct EmuTrap stub_XML_GetSpecifiedAttributeCount = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetSpecifiedAttributeCountPPC }; - -static int stub_XML_GetIdAttributeIndexPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_GetIdAttributeIndex(p->p); -} -struct EmuTrap stub_XML_GetIdAttributeIndex = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetIdAttributeIndexPPC }; - -static int stub_XML_SetEncodingPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_SetEncoding(p->p, (const XML_Char *)regarray[9]); -} -struct EmuTrap stub_XML_SetEncoding = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetEncodingPPC }; - -static int stub_XML_SetParamEntityParsingPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_SetParamEntityParsing(p->p, (enum XML_ParamEntityParsing)regarray[9]); -} -struct EmuTrap stub_XML_SetParamEntityParsing = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetParamEntityParsingPPC }; - -static void stub_XML_SetReturnNSTripletPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_SetReturnNSTriplet(p->p, (int)regarray[0]); -} -struct EmuTrap stub_XML_SetReturnNSTriplet = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetReturnNSTripletPPC }; - -static const XML_LChar * stub_XML_ExpatVersionPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - return Self->XML_ExpatVersion(); -} -struct EmuTrap stub_XML_ExpatVersion = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ExpatVersionPPC }; - -static XML_Expat_Version stub_XML_ExpatVersionInfoPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - return Self->XML_ExpatVersionInfo(); -} -struct EmuTrap stub_XML_ExpatVersionInfo = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ExpatVersionInfoPPC }; - -static int stub_XML_ParserResetPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_ParserReset(p->p, (const XML_Char *)regarray[9]); -} -struct EmuTrap stub_XML_ParserReset = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ParserResetPPC }; - -static void stub_XML_SetSkippedEntityHandlerPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - p->skippedentityhandler = (void *)regarray[9]; - Self->XML_SetSkippedEntityHandler(p->p, _68k_skippedentityhandler); -} -struct EmuTrap stub_XML_SetSkippedEntityHandler = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_SetSkippedEntityHandlerPPC }; - -static int stub_XML_UseForeignDTDPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_UseForeignDTD(p->p, (XML_Bool)regarray[0]); -} -struct EmuTrap stub_XML_UseForeignDTD = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_UseForeignDTDPPC }; - -static const XML_Feature * stub_XML_GetFeatureListPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - return Self->XML_GetFeatureList(); -} -struct EmuTrap stub_XML_GetFeatureList = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetFeatureListPPC }; - -static int stub_XML_StopParserPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_StopParser(p->p, (XML_Bool)regarray[0]); -} -struct EmuTrap stub_XML_StopParser = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_StopParserPPC }; - -static int stub_XML_ResumeParserPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_ResumeParser(p->p); -} -struct EmuTrap stub_XML_ResumeParser = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_ResumeParserPPC }; - -static void stub_XML_GetParsingStatusPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_GetParsingStatus(p->p, (XML_ParsingStatus *)regarray[9]); -} -struct EmuTrap stub_XML_GetParsingStatus = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_GetParsingStatusPPC }; - -static void stub_XML_FreeContentModelPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_FreeContentModel(p->p, (XML_Content *)regarray[9]); -} -struct EmuTrap stub_XML_FreeContentModel = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_FreeContentModelPPC }; - -static void *stub_XML_MemMallocPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_MemMalloc(p->p, (size_t)regarray[0]); -} -struct EmuTrap stub_XML_MemMalloc = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_MemMallocPPC }; - -static void *stub_XML_MemReallocPPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - return Self->XML_MemRealloc(p->p, (void *)regarray[9], (size_t)regarray[0]); -} -struct EmuTrap stub_XML_MemRealloc = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_MemReallocPPC }; - -static void stub_XML_MemFreePPC(ULONG *regarray) -{ - struct Library *Base = (struct Library *) regarray[REG68K_A6/4]; - struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize); - struct ExpatIFace *Self = (struct ExpatIFace *) ExtLib->MainIFace; - - M68kXML_Parser p = (M68kXML_Parser)regarray[8]; - Self->XML_MemFree(p->p, (void *)regarray[9]); -} -struct EmuTrap stub_XML_MemFree = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_XML_MemFreePPC }; - -ULONG VecTable68K[] = { - (ULONG)&stub_Open, - (ULONG)&stub_Close, - (ULONG)&stub_Expunge, - (ULONG)&stub_Reserved, - (ULONG)&stub_XML_ParserCreate, - (ULONG)&stub_XML_ParserCreateNS, - (ULONG)&stub_XML_ParserCreate_MM, - (ULONG)&stub_XML_ExternalEntityParserCreate, - (ULONG)&stub_XML_ParserFree, - (ULONG)&stub_XML_Parse, - (ULONG)&stub_XML_ParseBuffer, - (ULONG)&stub_XML_GetBuffer, - (ULONG)&stub_XML_SetStartElementHandler, - (ULONG)&stub_XML_SetEndElementHandler, - (ULONG)&stub_XML_SetElementHandler, - (ULONG)&stub_XML_SetCharacterDataHandler, - (ULONG)&stub_XML_SetProcessingInstructionHandler, - (ULONG)&stub_XML_SetCommentHandler, - (ULONG)&stub_XML_SetStartCdataSectionHandler, - (ULONG)&stub_XML_SetEndCdataSectionHandler, - (ULONG)&stub_XML_SetCdataSectionHandler, - (ULONG)&stub_XML_SetDefaultHandler, - (ULONG)&stub_XML_SetDefaultHandlerExpand, - (ULONG)&stub_XML_SetExternalEntityRefHandler, - (ULONG)&stub_XML_SetExternalEntityRefHandlerArg, - (ULONG)&stub_XML_SetUnknownEncodingHandler, - (ULONG)&stub_XML_SetStartNamespaceDeclHandler, - (ULONG)&stub_XML_SetEndNamespaceDeclHandler, - (ULONG)&stub_XML_SetNamespaceDeclHandler, - (ULONG)&stub_XML_SetXmlDeclHandler, - (ULONG)&stub_XML_SetStartDoctypeDeclHandler, - (ULONG)&stub_XML_SetEndDoctypeDeclHandler, - (ULONG)&stub_XML_SetDoctypeDeclHandler, - (ULONG)&stub_XML_SetElementDeclHandler, - (ULONG)&stub_XML_SetAttlistDeclHandler, - (ULONG)&stub_XML_SetEntityDeclHandler, - (ULONG)&stub_XML_SetUnparsedEntityDeclHandler, - (ULONG)&stub_XML_SetNotationDeclHandler, - (ULONG)&stub_XML_SetNotStandaloneHandler, - (ULONG)&stub_XML_GetErrorCode, - (ULONG)&stub_XML_ErrorString, - (ULONG)&stub_XML_GetCurrentByteIndex, - (ULONG)&stub_XML_GetCurrentLineNumber, - (ULONG)&stub_XML_GetCurrentColumnNumber, - (ULONG)&stub_XML_GetCurrentByteCount, - (ULONG)&stub_XML_GetInputContext, - (ULONG)&stub_XML_SetUserData, - (ULONG)&stub_XML_DefaultCurrent, - (ULONG)&stub_XML_UseParserAsHandlerArg, - (ULONG)&stub_XML_SetBase, - (ULONG)&stub_XML_GetBase, - (ULONG)&stub_XML_GetSpecifiedAttributeCount, - (ULONG)&stub_XML_GetIdAttributeIndex, - (ULONG)&stub_XML_SetEncoding, - (ULONG)&stub_XML_SetParamEntityParsing, - (ULONG)&stub_XML_SetReturnNSTriplet, - (ULONG)&stub_XML_ExpatVersion, - (ULONG)&stub_XML_ExpatVersionInfo, - (ULONG)&stub_XML_ParserReset, - (ULONG)&stub_XML_SetSkippedEntityHandler, - (ULONG)&stub_XML_UseForeignDTD, - (ULONG)&stub_XML_GetFeatureList, - (ULONG)&stub_XML_StopParser, - (ULONG)&stub_XML_ResumeParser, - (ULONG)&stub_XML_GetParsingStatus, - (ULONG)&stub_XML_FreeContentModel, - (ULONG)&stub_XML_MemMalloc, - (ULONG)&stub_XML_MemRealloc, - (ULONG)&stub_XML_MemFree, - (ULONG)-1 -}; diff --git a/lib-src/expat/amiga/expat_68k.h b/lib-src/expat/amiga/expat_68k.h deleted file mode 100755 index 6f1aac59b..000000000 --- a/lib-src/expat/amiga/expat_68k.h +++ /dev/null @@ -1,94 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#ifndef EXPAT_68K_H -#define EXPAT_68K_H - -#ifndef LIBRARIES_EXPAT_H -#include -#endif - -typedef struct M68kXML_ParserStruct { - XML_Parser p; - struct ExecIFace *IExec; - void *handlerarg; - void *extenthandlerarg; - void *enchandlerarg; - void *startelementhandler; - void *endelementhandler; - void *chardatahandler; - void *procinsthandler; - void *commenthandler; - void *startcdatahandler; - void *endcdatahandler; - void *defaulthandler; - void *defaulthandlerexp; - void *extentrefhandler; - void *unknownenchandler; - void *startnamespacehandler; - void *endnamespacehandler; - void *xmldeclhandler; - void *startdoctypehandler; - void *enddoctypehandler; - void *elementdeclhandler; - void *attlistdeclhandler; - void *entitydeclhandler; - void *unparseddeclhandler; - void *notationdeclhandler; - void *notstandalonehandler; - void *skippedentityhandler; -} *M68kXML_Parser; - -/* expat_68k_handler_stubs.c */ -void _68k_startelementhandler(void *userdata, const char *name, const char **attrs); -void _68k_endelementhandler(void *userdata, const char *name); -void _68k_chardatahandler(void *userdata, const char *s, int len); -void _68k_procinsthandler(void *userdata, const char *target, const char *data); -void _68k_commenthandler(void *userdata, const char *data); -void _68k_startcdatahandler(void *userdata); -void _68k_endcdatahandler(void *userdata); -void _68k_defaulthandler(void *userdata, const char *s, int len); -void _68k_defaulthandlerexp(void *userdata, const char *s, int len); -int _68k_extentrefhandler(XML_Parser parser, const char *context, const char *base, - const char *sysid, const char *pubid); -int _68k_unknownenchandler(void *enchandlerdata, const char *name, XML_Encoding *info); -void _68k_startnamespacehandler(void *userdata, const char *prefix, const char *uri); -void _68k_endnamespacehandler(void *userdata, const char *prefix); -void _68k_xmldeclhandler(void *userdata, const char *version, const char *encoding, int standalone); -void _68k_startdoctypehandler(void *userdata, const char *doctypename, - const char *sysid, const char *pubid, int has_internal_subset); -void _68k_enddoctypehandler(void *userdata); -void _68k_elementdeclhandler(void *userdata, const char *name, XML_Content *model); -void _68k_attlistdeclhandler(void *userdata, const char *elname, const char *attname, - const char *att_type, const char *dflt, int isrequired); -void _68k_entitydeclhandler(void *userdata, const char *entityname, int is_param_entity, - const char *value, int value_length, const char *base, const char *sysid, const char *pubid, - const char *notationname); -void _68k_unparseddeclhandler(void *userdata, const char *entityname, const char *base, - const char *sysid, const char *pubid, const char *notationname); -void _68k_notationdeclhandler(void *userdata, const char *notationname, const char *base, - const char *sysid, const char *pubid); -int _68k_notstandalonehandler(void *userdata); -void _68k_skippedentityhandler(void *userdata, const char *entityname, int is_param_entity); - -#endif diff --git a/lib-src/expat/amiga/expat_68k_handler_stubs.c b/lib-src/expat/amiga/expat_68k_handler_stubs.c deleted file mode 100755 index aca33c6ec..000000000 --- a/lib-src/expat/amiga/expat_68k_handler_stubs.c +++ /dev/null @@ -1,185 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#ifdef __USE_INLINE__ -#undef __USE_INLINE__ -#endif - -#include "expat_68k.h" -#include -#include -#include - -static uint32 VARARGS68K call_68k_code (struct ExecIFace *IExec, void *code, int num_args, ...) { - uint32 res = 0; - - va_list vargs; - va_startlinear(vargs, num_args); - uint32 *args = va_getlinearva(vargs, uint32 *); - - uint8 *stack = IExec->AllocVec(4096, MEMF_SHARED); - if (stack) { - uint32 *sp = (uint32 *)(stack + 4096); - args += num_args; - while (num_args--) { - *--sp = *--args; - } - - res = IExec->EmulateTags(code, ET_StackPtr, sp, TAG_END); - IExec->FreeVec(stack); - } - - va_end(vargs); - - return res; -} - -void _68k_startelementhandler(void *userdata, const char *name, const char **attrs) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->startelementhandler, 3, p->handlerarg, name, attrs); -} - -void _68k_endelementhandler(void *userdata, const char *name) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->endelementhandler, 2, p->handlerarg, name); -} - -void _68k_chardatahandler(void *userdata, const char *s, int len) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->chardatahandler, 3, p->handlerarg, s, len); -} - -void _68k_procinsthandler(void *userdata, const char *target, const char *data) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->procinsthandler, 3, p->handlerarg, target, data); -} - -void _68k_commenthandler(void *userdata, const char *data) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->commenthandler, 2, p->handlerarg, data); -} - -void _68k_startcdatahandler(void *userdata) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->startcdatahandler, 1, p->handlerarg); -} - -void _68k_endcdatahandler(void *userdata) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->endcdatahandler, 1, p->handlerarg); -} - -void _68k_defaulthandler(void *userdata, const char *s, int len) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->defaulthandler, 3, p->handlerarg, s, len); -} - -void _68k_defaulthandlerexp(void *userdata, const char *s, int len) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->defaulthandlerexp, 3, p->handlerarg, s, len); -} - -int _68k_extentrefhandler(XML_Parser parser, const char *context, const char *base, - const char *sysid, const char *pubid) -{ - M68kXML_Parser p = XML_GetUserData(parser); - void *arg = p->extenthandlerarg; - return (int)call_68k_code(p->IExec, p->extentrefhandler, 5, arg ? arg : p, context, base, sysid, pubid); -} - -int _68k_unknownenchandler(void *enchandlerdata, const char *name, XML_Encoding *info) { - M68kXML_Parser p = enchandlerdata; - return (int)call_68k_code(p->IExec, p->unknownenchandler, 3, p->enchandlerarg, name, info); -} - -void _68k_startnamespacehandler(void *userdata, const char *prefix, const char *uri) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->startnamespacehandler, 3, p->handlerarg, prefix, uri); -} - -void _68k_endnamespacehandler(void *userdata, const char *prefix) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->endnamespacehandler, 2, p->handlerarg, prefix); -} - -void _68k_xmldeclhandler(void *userdata, const char *version, const char *encoding, int standalone) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->xmldeclhandler, 4, p->handlerarg, version, encoding, standalone); -} - -void _68k_startdoctypehandler(void *userdata, const char *doctypename, - const char *sysid, const char *pubid, int has_internal_subset) -{ - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->startdoctypehandler, 5, p->handlerarg, doctypename, sysid, pubid, has_internal_subset); -} - -void _68k_enddoctypehandler(void *userdata) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->enddoctypehandler, 1, p->handlerarg); -} - -void _68k_elementdeclhandler(void *userdata, const char *name, XML_Content *model) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->elementdeclhandler, 3, p->handlerarg, name, model); -} - -void _68k_attlistdeclhandler(void *userdata, const char *elname, const char *attname, - const char *att_type, const char *dflt, int isrequired) -{ - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->attlistdeclhandler, 6, p->handlerarg, elname, attname, att_type, dflt, isrequired); -} - -void _68k_entitydeclhandler(void *userdata, const char *entityname, int is_param_entity, - const char *value, int value_length, const char *base, const char *sysid, const char *pubid, - const char *notationname) -{ - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->entitydeclhandler, 9, p->handlerarg, entityname, is_param_entity, - value, value_length, base, sysid, pubid, notationname); -} - -void _68k_unparseddeclhandler(void *userdata, const char *entityname, const char *base, - const char *sysid, const char *pubid, const char *notationname) -{ - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->unparseddeclhandler, 6, p->handlerarg, entityname, base, sysid, pubid, notationname); -} - -void _68k_notationdeclhandler(void *userdata, const char *notationname, const char *base, - const char *sysid, const char *pubid) -{ - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->notationdeclhandler, 5, p->handlerarg, notationname, base, sysid, pubid); -} - -int _68k_notstandalonehandler(void *userdata) { - M68kXML_Parser p = userdata; - return (int)call_68k_code(p->IExec, p->notstandalonehandler, 1, p->handlerarg); -} - -void _68k_skippedentityhandler(void *userdata, const char *entityname, int is_param_entity) { - M68kXML_Parser p = userdata; - call_68k_code(p->IExec, p->skippedentityhandler, 3, p->handlerarg, entityname, is_param_entity); -} diff --git a/lib-src/expat/amiga/expat_base.h b/lib-src/expat/amiga/expat_base.h deleted file mode 100644 index 266363985..000000000 --- a/lib-src/expat/amiga/expat_base.h +++ /dev/null @@ -1,40 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#ifndef EXPAT_BASE_H -#define EXPAT_BASE_H - -#include -#include -#include -#include - - -struct ExpatBase { - struct Library libNode; - uint16 pad; - BPTR SegList; - struct ExecIFace *IExec; -}; - -#endif diff --git a/lib-src/expat/amiga/expat_lib.c b/lib-src/expat/amiga/expat_lib.c deleted file mode 100755 index 70e91b101..000000000 --- a/lib-src/expat/amiga/expat_lib.c +++ /dev/null @@ -1,247 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#ifdef __USE_INLINE__ -#undef __USE_INLINE__ -#endif - -#define __NOLIBBASE__ -#define __NOGLOBALIFACE__ - -#include -#include - -#include "expat_base.h" - - -#define LIBNAME "expat.library" -#define LIBPRI 0 -#define VERSION 53 -#define REVISION 1 -#define VSTRING "expat.library 53.1 (7.8.2009)" /* dd.mm.yyyy */ - - -static const char* __attribute__((used)) verstag = "\0$VER: " VSTRING; - - -struct Interface *INewlib = 0; - - -struct ExpatBase * libInit(struct ExpatBase *libBase, BPTR seglist, struct ExecIFace *ISys); -uint32 libObtain (struct LibraryManagerInterface *Self); -uint32 libRelease (struct LibraryManagerInterface *Self); -struct ExpatBase *libOpen (struct LibraryManagerInterface *Self, uint32 version); -BPTR libClose (struct LibraryManagerInterface *Self); -BPTR libExpunge (struct LibraryManagerInterface *Self); -struct Interface *openInterface(struct ExecIFace *IExec, CONST_STRPTR libName, uint32 libVer); -void closeInterface(struct ExecIFace *IExec, struct Interface *iface); - - -static APTR lib_manager_vectors[] = { - libObtain, - libRelease, - NULL, - NULL, - libOpen, - libClose, - libExpunge, - NULL, - (APTR)-1, -}; - - -static struct TagItem lib_managerTags[] = { - { MIT_Name, (uint32)"__library" }, - { MIT_VectorTable, (uint32)lib_manager_vectors }, - { MIT_Version, 1 }, - { TAG_END, 0 } -}; - - -extern void *main_vectors[]; - -static struct TagItem lib_mainTags[] = { - { MIT_Name, (uint32)"main" }, - { MIT_VectorTable, (uint32)main_vectors }, - { MIT_Version, 1 }, - { TAG_END, 0 } -}; - - -static APTR libInterfaces[] = { - lib_managerTags, - lib_mainTags, - NULL -}; - - -extern void *VecTable68K[]; - -static struct TagItem libCreateTags[] = { - { CLT_DataSize, sizeof(struct ExpatBase) }, - { CLT_InitFunc, (uint32)libInit }, - { CLT_Interfaces, (uint32)libInterfaces }, - { CLT_Vector68K, (uint32)VecTable68K }, - { TAG_END, 0 } -}; - - -static struct Resident __attribute__((used)) lib_res = { - RTC_MATCHWORD, // rt_MatchWord - &lib_res, // rt_MatchTag - &lib_res+1, // rt_EndSkip - RTF_NATIVE | RTF_AUTOINIT, // rt_Flags - VERSION, // rt_Version - NT_LIBRARY, // rt_Type - LIBPRI, // rt_Pri - LIBNAME, // rt_Name - VSTRING, // rt_IdString - libCreateTags // rt_Init -}; - - -int32 _start() -{ - return RETURN_FAIL; -} - - -struct ExpatBase *libInit(struct ExpatBase *libBase, BPTR seglist, struct ExecIFace *iexec) -{ - libBase->libNode.lib_Node.ln_Type = NT_LIBRARY; - libBase->libNode.lib_Node.ln_Pri = LIBPRI; - libBase->libNode.lib_Node.ln_Name = LIBNAME; - libBase->libNode.lib_Flags = LIBF_SUMUSED|LIBF_CHANGED; - libBase->libNode.lib_Version = VERSION; - libBase->libNode.lib_Revision = REVISION; - libBase->libNode.lib_IdString = VSTRING; - - libBase->SegList = seglist; - - libBase->IExec = iexec; - INewlib = openInterface(iexec, "newlib.library", 0); - - if ( INewlib != 0 ) { - return libBase; - } - - closeInterface(iexec, INewlib); - INewlib = 0; - - iexec->DeleteLibrary(&libBase->libNode); - - return NULL; -} - - -uint32 libObtain( struct LibraryManagerInterface *Self ) -{ - ++Self->Data.RefCount; - return Self->Data.RefCount; -} - - -uint32 libRelease( struct LibraryManagerInterface *Self ) -{ - --Self->Data.RefCount; - return Self->Data.RefCount; -} - - -struct ExpatBase *libOpen( struct LibraryManagerInterface *Self, uint32 version ) -{ - struct ExpatBase *libBase; - - libBase = (struct ExpatBase *)Self->Data.LibBase; - - ++libBase->libNode.lib_OpenCnt; - libBase->libNode.lib_Flags &= ~LIBF_DELEXP; - - return libBase; -} - - -BPTR libClose( struct LibraryManagerInterface *Self ) -{ - struct ExpatBase *libBase; - - libBase = (struct ExpatBase *)Self->Data.LibBase; - - --libBase->libNode.lib_OpenCnt; - if ( libBase->libNode.lib_OpenCnt ) { - return 0; - } - - if ( libBase->libNode.lib_Flags & LIBF_DELEXP ) { - return (BPTR)Self->LibExpunge(); - } - else { - return ZERO; - } -} - - -BPTR libExpunge( struct LibraryManagerInterface *Self ) -{ - struct ExpatBase *libBase = (struct ExpatBase *)Self->Data.LibBase; - BPTR result = ZERO; - - if (libBase->libNode.lib_OpenCnt == 0) { - libBase->IExec->Remove(&libBase->libNode.lib_Node); - - result = libBase->SegList; - - closeInterface(libBase->IExec, INewlib); - INewlib = 0; - - libBase->IExec->DeleteLibrary(&libBase->libNode); - } - else { - libBase->libNode.lib_Flags |= LIBF_DELEXP; - } - - return result; -} - - -struct Interface *openInterface(struct ExecIFace *IExec, CONST_STRPTR libName, uint32 libVer) -{ - struct Library *base = IExec->OpenLibrary(libName, libVer); - struct Interface *iface = IExec->GetInterface(base, "main", 1, 0); - if (iface == 0) { - IExec->CloseLibrary(base); - } - - return iface; -} - - -void closeInterface(struct ExecIFace *IExec, struct Interface *iface) -{ - if (iface != 0) - { - struct Library *base = iface->Data.LibBase; - IExec->DropInterface(iface); - IExec->CloseLibrary(base); - } -} diff --git a/lib-src/expat/amiga/expat_vectors.c b/lib-src/expat/amiga/expat_vectors.c deleted file mode 100644 index cf489509c..000000000 --- a/lib-src/expat/amiga/expat_vectors.c +++ /dev/null @@ -1,505 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#include -#include -#include -#include - -extern uint32 _Expat_Obtain(struct ExpatIFace *); -extern uint32 _Expat_Release(struct ExpatIFace *); -extern XML_Parser _Expat_XML_ParserCreate(struct ExpatIFace *, const XML_Char * encodingName); -extern XML_Parser _Expat_XML_ParserCreateNS(struct ExpatIFace *, const XML_Char * encodingName, XML_Char nsSep); -extern XML_Parser _Expat_XML_ParserCreate_MM(struct ExpatIFace *, const XML_Char * encoding, const XML_Memory_Handling_Suite * memsuite, const XML_Char * namespaceSeparator); -extern XML_Parser _Expat_XML_ExternalEntityParserCreate(struct ExpatIFace *, XML_Parser parser, const XML_Char * context, const XML_Char * encoding); -extern void _Expat_XML_ParserFree(struct ExpatIFace *, XML_Parser parser); -extern enum XML_Status _Expat_XML_Parse(struct ExpatIFace *, XML_Parser parser, const char * s, int len, int isFinal); -extern enum XML_Status _Expat_XML_ParseBuffer(struct ExpatIFace *, XML_Parser parser, int len, int isFinal); -extern void * _Expat_XML_GetBuffer(struct ExpatIFace *, XML_Parser parser, int len); -extern void _Expat_XML_SetStartElementHandler(struct ExpatIFace *, XML_Parser parser, XML_StartElementHandler start); -extern void _Expat_XML_SetEndElementHandler(struct ExpatIFace *, XML_Parser parser, XML_EndElementHandler end); -extern void _Expat_XML_SetElementHandler(struct ExpatIFace *, XML_Parser parser, XML_StartElementHandler start, XML_EndElementHandler end); -extern void _Expat_XML_SetCharacterDataHandler(struct ExpatIFace *, XML_Parser parser, XML_CharacterDataHandler handler); -extern void _Expat_XML_SetProcessingInstructionHandler(struct ExpatIFace *, XML_Parser parser, XML_ProcessingInstructionHandler handler); -extern void _Expat_XML_SetCommentHandler(struct ExpatIFace *, XML_Parser parser, XML_CommentHandler handler); -extern void _Expat_XML_SetStartCdataSectionHandler(struct ExpatIFace *, XML_Parser parser, XML_StartCdataSectionHandler start); -extern void _Expat_XML_SetEndCdataSectionHandler(struct ExpatIFace *, XML_Parser parser, XML_EndCdataSectionHandler end); -extern void _Expat_XML_SetCdataSectionHandler(struct ExpatIFace *, XML_Parser parser, XML_StartCdataSectionHandler start, XML_EndCdataSectionHandler end); -extern void _Expat_XML_SetDefaultHandler(struct ExpatIFace *, XML_Parser parser, XML_DefaultHandler handler); -extern void _Expat_XML_SetDefaultHandlerExpand(struct ExpatIFace *, XML_Parser parser, XML_DefaultHandler handler); -extern void _Expat_XML_SetExternalEntityRefHandler(struct ExpatIFace *, XML_Parser parser, XML_ExternalEntityRefHandler handler); -extern void _Expat_XML_SetExternalEntityRefHandlerArg(struct ExpatIFace *, XML_Parser parser, void * arg); -extern void _Expat_XML_SetUnknownEncodingHandler(struct ExpatIFace *, XML_Parser parser, XML_UnknownEncodingHandler handler, void * data); -extern void _Expat_XML_SetStartNamespaceDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_StartNamespaceDeclHandler start); -extern void _Expat_XML_SetEndNamespaceDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_EndNamespaceDeclHandler end); -extern void _Expat_XML_SetNamespaceDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_StartNamespaceDeclHandler start, XML_EndNamespaceDeclHandler end); -extern void _Expat_XML_SetXmlDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_XmlDeclHandler handler); -extern void _Expat_XML_SetStartDoctypeDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_StartDoctypeDeclHandler start); -extern void _Expat_XML_SetEndDoctypeDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_EndDoctypeDeclHandler end); -extern void _Expat_XML_SetDoctypeDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_StartDoctypeDeclHandler start, XML_EndDoctypeDeclHandler end); -extern void _Expat_XML_SetElementDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_ElementDeclHandler eldecl); -extern void _Expat_XML_SetAttlistDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_AttlistDeclHandler attdecl); -extern void _Expat_XML_SetEntityDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_EntityDeclHandler handler); -extern void _Expat_XML_SetUnparsedEntityDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_UnparsedEntityDeclHandler handler); -extern void _Expat_XML_SetNotationDeclHandler(struct ExpatIFace *, XML_Parser parser, XML_NotationDeclHandler handler); -extern void _Expat_XML_SetNotStandaloneHandler(struct ExpatIFace *, XML_Parser parser, XML_NotStandaloneHandler handler); -extern enum XML_Error _Expat_XML_GetErrorCode(struct ExpatIFace *, XML_Parser parser); -extern const XML_LChar * _Expat_XML_ErrorString(struct ExpatIFace *, enum XML_Error code); -extern long _Expat_XML_GetCurrentByteIndex(struct ExpatIFace *, XML_Parser parser); -extern int _Expat_XML_GetCurrentLineNumber(struct ExpatIFace *, XML_Parser parser); -extern int _Expat_XML_GetCurrentColumnNumber(struct ExpatIFace *, XML_Parser parser); -extern int _Expat_XML_GetCurrentByteCount(struct ExpatIFace *, XML_Parser parser); -extern const char * _Expat_XML_GetInputContext(struct ExpatIFace *, XML_Parser parser, int * offset, int * size); -extern void _Expat_XML_SetUserData(struct ExpatIFace *, XML_Parser parser, void * userData); -extern void _Expat_XML_DefaultCurrent(struct ExpatIFace *, XML_Parser parser); -extern void _Expat_XML_UseParserAsHandlerArg(struct ExpatIFace *, XML_Parser parser); -extern enum XML_Status _Expat_XML_SetBase(struct ExpatIFace *, XML_Parser parser, const XML_Char * base); -extern const XML_Char * _Expat_XML_GetBase(struct ExpatIFace *, XML_Parser parser); -extern int _Expat_XML_GetSpecifiedAttributeCount(struct ExpatIFace *, XML_Parser parser); -extern int _Expat_XML_GetIdAttributeIndex(struct ExpatIFace *, XML_Parser parser); -extern enum XML_Status _Expat_XML_SetEncoding(struct ExpatIFace *, XML_Parser parser, const XML_Char * encoding); -extern int _Expat_XML_SetParamEntityParsing(struct ExpatIFace *, XML_Parser parser, enum XML_ParamEntityParsing parsing); -extern void _Expat_XML_SetReturnNSTriplet(struct ExpatIFace *, XML_Parser parser, int do_nst); -extern const XML_LChar * _Expat_XML_ExpatVersion(struct ExpatIFace *); -extern XML_Expat_Version _Expat_XML_ExpatVersionInfo(struct ExpatIFace *); -extern XML_Bool _Expat_XML_ParserReset(struct ExpatIFace *, XML_Parser parser, const XML_Char * encoding); -extern void _Expat_XML_SetSkippedEntityHandler(struct ExpatIFace *, XML_Parser parser, XML_SkippedEntityHandler handler); -extern enum XML_Error _Expat_XML_UseForeignDTD(struct ExpatIFace *, XML_Parser parser, XML_Bool useDTD); -extern const XML_Feature * _Expat_XML_GetFeatureList(struct ExpatIFace *); -extern enum XML_Status _Expat_XML_StopParser(struct ExpatIFace *, XML_Parser parser, XML_Bool resumable); -extern enum XML_Status _Expat_XML_ResumeParser(struct ExpatIFace *, XML_Parser parser); -extern void _Expat_XML_GetParsingStatus(struct ExpatIFace *, XML_Parser parser, XML_ParsingStatus * status); -extern void _Expat_XML_FreeContentModel(struct ExpatIFace *, XML_Parser parser, XML_Content * model); -extern void * _Expat_XML_MemMalloc(struct ExpatIFace *, XML_Parser parser, size_t size); -extern void * _Expat_XML_MemRealloc(struct ExpatIFace *, XML_Parser parser, void * ptr, size_t size); -extern void _Expat_XML_MemFree(struct ExpatIFace *, XML_Parser parser, void * ptr); - - -CONST APTR main_vectors[] = -{ - _Expat_Obtain, - _Expat_Release, - NULL, - NULL, - _Expat_XML_ParserCreate, - _Expat_XML_ParserCreateNS, - _Expat_XML_ParserCreate_MM, - _Expat_XML_ExternalEntityParserCreate, - _Expat_XML_ParserFree, - _Expat_XML_Parse, - _Expat_XML_ParseBuffer, - _Expat_XML_GetBuffer, - _Expat_XML_SetStartElementHandler, - _Expat_XML_SetEndElementHandler, - _Expat_XML_SetElementHandler, - _Expat_XML_SetCharacterDataHandler, - _Expat_XML_SetProcessingInstructionHandler, - _Expat_XML_SetCommentHandler, - _Expat_XML_SetStartCdataSectionHandler, - _Expat_XML_SetEndCdataSectionHandler, - _Expat_XML_SetCdataSectionHandler, - _Expat_XML_SetDefaultHandler, - _Expat_XML_SetDefaultHandlerExpand, - _Expat_XML_SetExternalEntityRefHandler, - _Expat_XML_SetExternalEntityRefHandlerArg, - _Expat_XML_SetUnknownEncodingHandler, - _Expat_XML_SetStartNamespaceDeclHandler, - _Expat_XML_SetEndNamespaceDeclHandler, - _Expat_XML_SetNamespaceDeclHandler, - _Expat_XML_SetXmlDeclHandler, - _Expat_XML_SetStartDoctypeDeclHandler, - _Expat_XML_SetEndDoctypeDeclHandler, - _Expat_XML_SetDoctypeDeclHandler, - _Expat_XML_SetElementDeclHandler, - _Expat_XML_SetAttlistDeclHandler, - _Expat_XML_SetEntityDeclHandler, - _Expat_XML_SetUnparsedEntityDeclHandler, - _Expat_XML_SetNotationDeclHandler, - _Expat_XML_SetNotStandaloneHandler, - _Expat_XML_GetErrorCode, - _Expat_XML_ErrorString, - _Expat_XML_GetCurrentByteIndex, - _Expat_XML_GetCurrentLineNumber, - _Expat_XML_GetCurrentColumnNumber, - _Expat_XML_GetCurrentByteCount, - _Expat_XML_GetInputContext, - _Expat_XML_SetUserData, - _Expat_XML_DefaultCurrent, - _Expat_XML_UseParserAsHandlerArg, - _Expat_XML_SetBase, - _Expat_XML_GetBase, - _Expat_XML_GetSpecifiedAttributeCount, - _Expat_XML_GetIdAttributeIndex, - _Expat_XML_SetEncoding, - _Expat_XML_SetParamEntityParsing, - _Expat_XML_SetReturnNSTriplet, - _Expat_XML_ExpatVersion, - _Expat_XML_ExpatVersionInfo, - _Expat_XML_ParserReset, - _Expat_XML_SetSkippedEntityHandler, - _Expat_XML_UseForeignDTD, - _Expat_XML_GetFeatureList, - _Expat_XML_StopParser, - _Expat_XML_ResumeParser, - _Expat_XML_GetParsingStatus, - _Expat_XML_FreeContentModel, - _Expat_XML_MemMalloc, - _Expat_XML_MemRealloc, - _Expat_XML_MemFree, - (APTR)-1 -}; - -uint32 _Expat_Obtain(struct ExpatIFace *Self) -{ - return ++Self->Data.RefCount; -} - -uint32 _Expat_Release(struct ExpatIFace *Self) -{ - return --Self->Data.RefCount; -} - -XML_Parser _Expat_XML_ParserCreate(struct ExpatIFace * Self, const XML_Char *encoding) -{ - return XML_ParserCreate(encoding); -} - -XML_Parser _Expat_XML_ParserCreateNS(struct ExpatIFace * Self, const XML_Char *encoding, XML_Char nsSep) -{ - return XML_ParserCreateNS(encoding, nsSep); -} - -XML_Parser _Expat_XML_ParserCreate_MM(struct ExpatIFace * Self, const XML_Char *encoding, const XML_Memory_Handling_Suite *memsuite, const XML_Char *namespaceSeparator) -{ - return XML_ParserCreate_MM(encoding, memsuite, namespaceSeparator); -} - -XML_Parser _Expat_XML_ExternalEntityParserCreate(struct ExpatIFace * Self, XML_Parser parser, const XML_Char *context, const XML_Char *encoding) -{ - return XML_ExternalEntityParserCreate(parser, context, encoding); -} - -void _Expat_XML_ParserFree(struct ExpatIFace *Self, XML_Parser parser) -{ - XML_ParserFree(parser); -} - -enum XML_Status _Expat_XML_Parse(struct ExpatIFace * Self, XML_Parser parser, const char * s, int len, int isFinal) -{ - return XML_Parse(parser, s, len, isFinal); -} - -enum XML_Status _Expat_XML_ParseBuffer(struct ExpatIFace * Self, XML_Parser parser, int len, int isFinal) -{ - return XML_ParseBuffer(parser, len, isFinal); -} - -void * _Expat_XML_GetBuffer(struct ExpatIFace * Self, XML_Parser parser, int len) -{ - return XML_GetBuffer(parser, len); -} - -void _Expat_XML_SetStartElementHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartElementHandler start) -{ - XML_SetStartElementHandler(parser, start); -} - -void _Expat_XML_SetEndElementHandler(struct ExpatIFace * Self, XML_Parser parser, XML_EndElementHandler end) -{ - XML_SetEndElementHandler(parser, end); -} - -void _Expat_XML_SetElementHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartElementHandler start, XML_EndElementHandler end) -{ - XML_SetElementHandler(parser, start, end); -} - -void _Expat_XML_SetCharacterDataHandler(struct ExpatIFace * Self, XML_Parser parser, XML_CharacterDataHandler handler) -{ - XML_SetCharacterDataHandler(parser, handler); -} - -void _Expat_XML_SetProcessingInstructionHandler(struct ExpatIFace * Self, XML_Parser parser, XML_ProcessingInstructionHandler handler) -{ - XML_SetProcessingInstructionHandler(parser, handler); -} - -void _Expat_XML_SetCommentHandler(struct ExpatIFace * Self, XML_Parser parser, XML_CommentHandler handler) -{ - XML_SetCommentHandler(parser, handler); -} - -void _Expat_XML_SetStartCdataSectionHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartCdataSectionHandler start) -{ - XML_SetStartCdataSectionHandler(parser, start); -} - -void _Expat_XML_SetEndCdataSectionHandler(struct ExpatIFace * Self, XML_Parser parser, XML_EndCdataSectionHandler end) -{ - XML_SetEndCdataSectionHandler(parser, end); -} - -void _Expat_XML_SetCdataSectionHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartCdataSectionHandler start, XML_EndCdataSectionHandler end) -{ - XML_SetCdataSectionHandler(parser, start, end); -} - -void _Expat_XML_SetDefaultHandler(struct ExpatIFace * Self, XML_Parser parser, XML_DefaultHandler handler) -{ - XML_SetDefaultHandler(parser, handler); -} - -void _Expat_XML_SetDefaultHandlerExpand(struct ExpatIFace * Self, XML_Parser parser, XML_DefaultHandler handler) -{ - XML_SetDefaultHandlerExpand(parser, handler); -} - -void _Expat_XML_SetExternalEntityRefHandler(struct ExpatIFace * Self, XML_Parser parser, XML_ExternalEntityRefHandler handler) -{ - XML_SetExternalEntityRefHandler(parser, handler); -} - -void _Expat_XML_SetExternalEntityRefHandlerArg(struct ExpatIFace * Self, XML_Parser parser, void * arg) -{ - XML_SetExternalEntityRefHandlerArg(parser, arg); -} - -void _Expat_XML_SetUnknownEncodingHandler(struct ExpatIFace * Self, XML_Parser parser, XML_UnknownEncodingHandler handler, void * data) -{ - XML_SetUnknownEncodingHandler(parser, handler, data); -} - -void _Expat_XML_SetStartNamespaceDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartNamespaceDeclHandler start) -{ - XML_SetStartNamespaceDeclHandler(parser, start); -} - -void _Expat_XML_SetEndNamespaceDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_EndNamespaceDeclHandler end) -{ - XML_SetEndNamespaceDeclHandler(parser, end); -} - -void _Expat_XML_SetNamespaceDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartNamespaceDeclHandler start, XML_EndNamespaceDeclHandler end) -{ - XML_SetNamespaceDeclHandler(parser, start, end); -} - -void _Expat_XML_SetXmlDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_XmlDeclHandler handler) -{ - XML_SetXmlDeclHandler(parser, handler); -} - -void _Expat_XML_SetStartDoctypeDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartDoctypeDeclHandler start) -{ - XML_SetStartDoctypeDeclHandler(parser, start); -} - -void _Expat_XML_SetEndDoctypeDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_EndDoctypeDeclHandler end) -{ - XML_SetEndDoctypeDeclHandler(parser, end); -} - -void _Expat_XML_SetDoctypeDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_StartDoctypeDeclHandler start, XML_EndDoctypeDeclHandler end) -{ - XML_SetDoctypeDeclHandler(parser, start, end); -} - -void _Expat_XML_SetElementDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_ElementDeclHandler eldecl) -{ - XML_SetElementDeclHandler(parser, eldecl); -} - -void _Expat_XML_SetAttlistDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_AttlistDeclHandler attdecl) -{ - XML_SetAttlistDeclHandler(parser, attdecl); -} - -void _Expat_XML_SetEntityDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_EntityDeclHandler handler) -{ - XML_SetEntityDeclHandler(parser, handler); -} - -void _Expat_XML_SetUnparsedEntityDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_UnparsedEntityDeclHandler handler) -{ - XML_SetUnparsedEntityDeclHandler(parser, handler); -} - -void _Expat_XML_SetNotationDeclHandler(struct ExpatIFace * Self, XML_Parser parser, XML_NotationDeclHandler handler) -{ - XML_SetNotationDeclHandler(parser, handler); -} - -void _Expat_XML_SetNotStandaloneHandler(struct ExpatIFace * Self, XML_Parser parser, XML_NotStandaloneHandler handler) -{ - XML_SetNotStandaloneHandler(parser, handler); -} - -enum XML_Error _Expat_XML_GetErrorCode(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetErrorCode(parser); -} - -const XML_LChar * _Expat_XML_ErrorString(struct ExpatIFace * Self, enum XML_Error code) -{ - return XML_ErrorString(code); -} - -long _Expat_XML_GetCurrentByteIndex(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetCurrentByteIndex(parser); -} - -int _Expat_XML_GetCurrentLineNumber(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetCurrentLineNumber(parser); -} - -int _Expat_XML_GetCurrentColumnNumber(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetCurrentColumnNumber(parser); -} - -int _Expat_XML_GetCurrentByteCount(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetCurrentByteCount(parser); -} - -const char * _Expat_XML_GetInputContext(struct ExpatIFace * Self, XML_Parser parser, int * offset, int * size) -{ - return XML_GetInputContext(parser, offset, size); -} - -void _Expat_XML_SetUserData(struct ExpatIFace * Self, XML_Parser parser, void * userData) -{ - XML_SetUserData(parser, userData); -} - -void _Expat_XML_DefaultCurrent(struct ExpatIFace * Self, XML_Parser parser) -{ - XML_DefaultCurrent(parser); -} - -void _Expat_XML_UseParserAsHandlerArg(struct ExpatIFace * Self, XML_Parser parser) -{ - XML_UseParserAsHandlerArg(parser); -} - -enum XML_Status _Expat_XML_SetBase(struct ExpatIFace * Self, XML_Parser parser, const XML_Char *p) -{ - return XML_SetBase(parser, p); -} - -const XML_Char * _Expat_XML_GetBase(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetBase(parser); -} - -int _Expat_XML_GetSpecifiedAttributeCount(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetSpecifiedAttributeCount(parser); -} - -int _Expat_XML_GetIdAttributeIndex(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_GetIdAttributeIndex(parser); -} - -enum XML_Status _Expat_XML_SetEncoding(struct ExpatIFace * Self, XML_Parser parser, const XML_Char *encoding) -{ - return XML_SetEncoding(parser, encoding); -} - -int _Expat_XML_SetParamEntityParsing(struct ExpatIFace * Self, XML_Parser parser, enum XML_ParamEntityParsing parsing) -{ - return XML_SetParamEntityParsing(parser, parsing); -} - -void _Expat_XML_SetReturnNSTriplet(struct ExpatIFace * Self, XML_Parser parser, int do_nst) -{ - XML_SetReturnNSTriplet(parser, do_nst); -} - -const XML_LChar * _Expat_XML_ExpatVersion(struct ExpatIFace * Self) -{ - return XML_ExpatVersion(); -} - -XML_Expat_Version _Expat_XML_ExpatVersionInfo(struct ExpatIFace * Self) -{ - return XML_ExpatVersionInfo(); -} - -XML_Bool _Expat_XML_ParserReset(struct ExpatIFace * Self, XML_Parser parser, const XML_Char *encoding) -{ - return XML_ParserReset(parser, encoding); -} - -void _Expat_XML_SetSkippedEntityHandler(struct ExpatIFace * Self, XML_Parser parser, XML_SkippedEntityHandler handler) -{ - XML_SetSkippedEntityHandler(parser, handler); -} - -enum XML_Error _Expat_XML_UseForeignDTD(struct ExpatIFace * Self, XML_Parser parser, XML_Bool useDTD) -{ - return XML_UseForeignDTD(parser, useDTD); -} - -const XML_Feature * _Expat_XML_GetFeatureList(struct ExpatIFace * Self) -{ - return XML_GetFeatureList(); -} - -enum XML_Status _Expat_XML_StopParser(struct ExpatIFace * Self, XML_Parser parser, XML_Bool resumable) -{ - return XML_StopParser(parser, resumable); -} - -enum XML_Status _Expat_XML_ResumeParser(struct ExpatIFace * Self, XML_Parser parser) -{ - return XML_ResumeParser(parser); -} - -void _Expat_XML_GetParsingStatus(struct ExpatIFace * Self, XML_Parser parser, XML_ParsingStatus * status) -{ - XML_GetParsingStatus(parser, status); -} - -void _Expat_XML_FreeContentModel(struct ExpatIFace * Self, XML_Parser parser, XML_Content * model) -{ - XML_FreeContentModel(parser, model); -} - -void * _Expat_XML_MemMalloc(struct ExpatIFace * Self, XML_Parser parser, size_t size) -{ - return XML_MemMalloc(parser, size); -} - -void * _Expat_XML_MemRealloc(struct ExpatIFace * Self, XML_Parser parser, void * ptr, size_t size) -{ - XML_MemRealloc(parser, ptr, size); -} - -void _Expat_XML_MemFree(struct ExpatIFace * Self, XML_Parser parser, void * ptr) -{ - XML_MemFree(parser, ptr); -} diff --git a/lib-src/expat/amiga/include/inline4/expat.h b/lib-src/expat/amiga/include/inline4/expat.h deleted file mode 100644 index 1e3105d94..000000000 --- a/lib-src/expat/amiga/include/inline4/expat.h +++ /dev/null @@ -1,94 +0,0 @@ -#ifndef INLINE4_EXPAT_H -#define INLINE4_EXPAT_H - -/* -** This file was auto generated by idltool 51.6. -** -** It provides compatibility to OS3 style library -** calls by substituting functions. -** -** Do not edit manually. -*/ - -#ifndef EXEC_TYPES_H -#include -#endif -#ifndef EXEC_EXEC_H -#include -#endif -#ifndef EXEC_INTERFACES_H -#include -#endif - -#ifndef LIBRARIES_EXPAT_H -#include -#endif - -/* Inline macros for Interface "main" */ -#define XML_ParserCreate(encodingName) IExpat->XML_ParserCreate(encodingName) -#define XML_ParserCreateNS(encodingName, nsSep) IExpat->XML_ParserCreateNS(encodingName, nsSep) -#define XML_ParserCreate_MM(encoding, memsuite, namespaceSeparator) IExpat->XML_ParserCreate_MM(encoding, memsuite, namespaceSeparator) -#define XML_ExternalEntityParserCreate(parser, context, encoding) IExpat->XML_ExternalEntityParserCreate(parser, context, encoding) -#define XML_ParserFree(parser) IExpat->XML_ParserFree(parser) -#define XML_Parse(parser, s, len, isFinal) IExpat->XML_Parse(parser, s, len, isFinal) -#define XML_ParseBuffer(parser, len, isFinal) IExpat->XML_ParseBuffer(parser, len, isFinal) -#define XML_GetBuffer(parser, len) IExpat->XML_GetBuffer(parser, len) -#define XML_SetStartElementHandler(parser, start) IExpat->XML_SetStartElementHandler(parser, start) -#define XML_SetEndElementHandler(parser, end) IExpat->XML_SetEndElementHandler(parser, end) -#define XML_SetElementHandler(parser, start, end) IExpat->XML_SetElementHandler(parser, start, end) -#define XML_SetCharacterDataHandler(parser, handler) IExpat->XML_SetCharacterDataHandler(parser, handler) -#define XML_SetProcessingInstructionHandler(parser, handler) IExpat->XML_SetProcessingInstructionHandler(parser, handler) -#define XML_SetCommentHandler(parser, handler) IExpat->XML_SetCommentHandler(parser, handler) -#define XML_SetStartCdataSectionHandler(parser, start) IExpat->XML_SetStartCdataSectionHandler(parser, start) -#define XML_SetEndCdataSectionHandler(parser, end) IExpat->XML_SetEndCdataSectionHandler(parser, end) -#define XML_SetCdataSectionHandler(parser, start, end) IExpat->XML_SetCdataSectionHandler(parser, start, end) -#define XML_SetDefaultHandler(parser, handler) IExpat->XML_SetDefaultHandler(parser, handler) -#define XML_SetDefaultHandlerExpand(parser, handler) IExpat->XML_SetDefaultHandlerExpand(parser, handler) -#define XML_SetExternalEntityRefHandler(parser, handler) IExpat->XML_SetExternalEntityRefHandler(parser, handler) -#define XML_SetExternalEntityRefHandlerArg(parser, arg) IExpat->XML_SetExternalEntityRefHandlerArg(parser, arg) -#define XML_SetUnknownEncodingHandler(parser, handler, data) IExpat->XML_SetUnknownEncodingHandler(parser, handler, data) -#define XML_SetStartNamespaceDeclHandler(parser, start) IExpat->XML_SetStartNamespaceDeclHandler(parser, start) -#define XML_SetEndNamespaceDeclHandler(parser, end) IExpat->XML_SetEndNamespaceDeclHandler(parser, end) -#define XML_SetNamespaceDeclHandler(parser, start, end) IExpat->XML_SetNamespaceDeclHandler(parser, start, end) -#define XML_SetXmlDeclHandler(parser, handler) IExpat->XML_SetXmlDeclHandler(parser, handler) -#define XML_SetStartDoctypeDeclHandler(parser, start) IExpat->XML_SetStartDoctypeDeclHandler(parser, start) -#define XML_SetEndDoctypeDeclHandler(parser, end) IExpat->XML_SetEndDoctypeDeclHandler(parser, end) -#define XML_SetDoctypeDeclHandler(parser, start, end) IExpat->XML_SetDoctypeDeclHandler(parser, start, end) -#define XML_SetElementDeclHandler(parser, eldecl) IExpat->XML_SetElementDeclHandler(parser, eldecl) -#define XML_SetAttlistDeclHandler(parser, attdecl) IExpat->XML_SetAttlistDeclHandler(parser, attdecl) -#define XML_SetEntityDeclHandler(parser, handler) IExpat->XML_SetEntityDeclHandler(parser, handler) -#define XML_SetUnparsedEntityDeclHandler(parser, handler) IExpat->XML_SetUnparsedEntityDeclHandler(parser, handler) -#define XML_SetNotationDeclHandler(parser, handler) IExpat->XML_SetNotationDeclHandler(parser, handler) -#define XML_SetNotStandaloneHandler(parser, handler) IExpat->XML_SetNotStandaloneHandler(parser, handler) -#define XML_GetErrorCode(parser) IExpat->XML_GetErrorCode(parser) -#define XML_ErrorString(code) IExpat->XML_ErrorString(code) -#define XML_GetCurrentByteIndex(parser) IExpat->XML_GetCurrentByteIndex(parser) -#define XML_GetCurrentLineNumber(parser) IExpat->XML_GetCurrentLineNumber(parser) -#define XML_GetCurrentColumnNumber(parser) IExpat->XML_GetCurrentColumnNumber(parser) -#define XML_GetCurrentByteCount(parser) IExpat->XML_GetCurrentByteCount(parser) -#define XML_GetInputContext(parser, offset, size) IExpat->XML_GetInputContext(parser, offset, size) -#define XML_SetUserData(parser, userData) IExpat->XML_SetUserData(parser, userData) -#define XML_DefaultCurrent(parser) IExpat->XML_DefaultCurrent(parser) -#define XML_UseParserAsHandlerArg(parser) IExpat->XML_UseParserAsHandlerArg(parser) -#define XML_SetBase(parser, base) IExpat->XML_SetBase(parser, base) -#define XML_GetBase(parser) IExpat->XML_GetBase(parser) -#define XML_GetSpecifiedAttributeCount(parser) IExpat->XML_GetSpecifiedAttributeCount(parser) -#define XML_GetIdAttributeIndex(parser) IExpat->XML_GetIdAttributeIndex(parser) -#define XML_SetEncoding(parser, encoding) IExpat->XML_SetEncoding(parser, encoding) -#define XML_SetParamEntityParsing(parser, parsing) IExpat->XML_SetParamEntityParsing(parser, parsing) -#define XML_SetReturnNSTriplet(parser, do_nst) IExpat->XML_SetReturnNSTriplet(parser, do_nst) -#define XML_ExpatVersion() IExpat->XML_ExpatVersion() -#define XML_ExpatVersionInfo() IExpat->XML_ExpatVersionInfo() -#define XML_ParserReset(parser, encoding) IExpat->XML_ParserReset(parser, encoding) -#define XML_SetSkippedEntityHandler(parser, handler) IExpat->XML_SetSkippedEntityHandler(parser, handler) -#define XML_UseForeignDTD(parser, useDTD) IExpat->XML_UseForeignDTD(parser, useDTD) -#define XML_GetFeatureList() IExpat->XML_GetFeatureList() -#define XML_StopParser(parser, resumable) IExpat->XML_StopParser(parser, resumable) -#define XML_ResumeParser(parser) IExpat->XML_ResumeParser(parser) -#define XML_GetParsingStatus(parser, status) IExpat->XML_GetParsingStatus(parser, status) -#define XML_FreeContentModel(parser, model) IExpat->XML_FreeContentModel(parser, model) -#define XML_MemMalloc(parser, size) IExpat->XML_MemMalloc(parser, size) -#define XML_MemRealloc(parser, ptr, size) IExpat->XML_MemRealloc(parser, ptr, size) -#define XML_MemFree(parser, ptr) IExpat->XML_MemFree(parser, ptr) - -#endif /* INLINE4_EXPAT_H */ diff --git a/lib-src/expat/amiga/include/interfaces/expat.h b/lib-src/expat/amiga/include/interfaces/expat.h deleted file mode 100644 index e9bdf4aa1..000000000 --- a/lib-src/expat/amiga/include/interfaces/expat.h +++ /dev/null @@ -1,98 +0,0 @@ -#ifndef EXPAT_INTERFACE_DEF_H -#define EXPAT_INTERFACE_DEF_H - -/* -** This file was machine generated by idltool 51.6. -** Do not edit -*/ - -#ifndef EXEC_TYPES_H -#include -#endif -#ifndef EXEC_EXEC_H -#include -#endif -#ifndef EXEC_INTERFACES_H -#include -#endif - -#ifndef LIBRARIES_EXPAT_H -#include -#endif - -struct ExpatIFace -{ - struct InterfaceData Data; - - uint32 APICALL (*Obtain)(struct ExpatIFace *Self); - uint32 APICALL (*Release)(struct ExpatIFace *Self); - void APICALL (*Expunge)(struct ExpatIFace *Self); - struct Interface * APICALL (*Clone)(struct ExpatIFace *Self); - XML_Parser APICALL (*XML_ParserCreate)(struct ExpatIFace *Self, const XML_Char * encodingName); - XML_Parser APICALL (*XML_ParserCreateNS)(struct ExpatIFace *Self, const XML_Char * encodingName, XML_Char nsSep); - XML_Parser APICALL (*XML_ParserCreate_MM)(struct ExpatIFace *Self, const XML_Char * encoding, const XML_Memory_Handling_Suite * memsuite, const XML_Char * namespaceSeparator); - XML_Parser APICALL (*XML_ExternalEntityParserCreate)(struct ExpatIFace *Self, XML_Parser parser, const XML_Char * context, const XML_Char * encoding); - void APICALL (*XML_ParserFree)(struct ExpatIFace *Self, XML_Parser parser); - enum XML_Status APICALL (*XML_Parse)(struct ExpatIFace *Self, XML_Parser parser, const char * s, int len, int isFinal); - enum XML_Status APICALL (*XML_ParseBuffer)(struct ExpatIFace *Self, XML_Parser parser, int len, int isFinal); - void * APICALL (*XML_GetBuffer)(struct ExpatIFace *Self, XML_Parser parser, int len); - void APICALL (*XML_SetStartElementHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartElementHandler start); - void APICALL (*XML_SetEndElementHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_EndElementHandler end); - void APICALL (*XML_SetElementHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartElementHandler start, XML_EndElementHandler end); - void APICALL (*XML_SetCharacterDataHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_CharacterDataHandler handler); - void APICALL (*XML_SetProcessingInstructionHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_ProcessingInstructionHandler handler); - void APICALL (*XML_SetCommentHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_CommentHandler handler); - void APICALL (*XML_SetStartCdataSectionHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartCdataSectionHandler start); - void APICALL (*XML_SetEndCdataSectionHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_EndCdataSectionHandler end); - void APICALL (*XML_SetCdataSectionHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartCdataSectionHandler start, XML_EndCdataSectionHandler end); - void APICALL (*XML_SetDefaultHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_DefaultHandler handler); - void APICALL (*XML_SetDefaultHandlerExpand)(struct ExpatIFace *Self, XML_Parser parser, XML_DefaultHandler handler); - void APICALL (*XML_SetExternalEntityRefHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_ExternalEntityRefHandler handler); - void APICALL (*XML_SetExternalEntityRefHandlerArg)(struct ExpatIFace *Self, XML_Parser parser, void * arg); - void APICALL (*XML_SetUnknownEncodingHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_UnknownEncodingHandler handler, void * data); - void APICALL (*XML_SetStartNamespaceDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartNamespaceDeclHandler start); - void APICALL (*XML_SetEndNamespaceDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_EndNamespaceDeclHandler end); - void APICALL (*XML_SetNamespaceDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartNamespaceDeclHandler start, XML_EndNamespaceDeclHandler end); - void APICALL (*XML_SetXmlDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_XmlDeclHandler handler); - void APICALL (*XML_SetStartDoctypeDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartDoctypeDeclHandler start); - void APICALL (*XML_SetEndDoctypeDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_EndDoctypeDeclHandler end); - void APICALL (*XML_SetDoctypeDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_StartDoctypeDeclHandler start, XML_EndDoctypeDeclHandler end); - void APICALL (*XML_SetElementDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_ElementDeclHandler eldecl); - void APICALL (*XML_SetAttlistDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_AttlistDeclHandler attdecl); - void APICALL (*XML_SetEntityDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_EntityDeclHandler handler); - void APICALL (*XML_SetUnparsedEntityDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_UnparsedEntityDeclHandler handler); - void APICALL (*XML_SetNotationDeclHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_NotationDeclHandler handler); - void APICALL (*XML_SetNotStandaloneHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_NotStandaloneHandler handler); - enum XML_Error APICALL (*XML_GetErrorCode)(struct ExpatIFace *Self, XML_Parser parser); - const XML_LChar * APICALL (*XML_ErrorString)(struct ExpatIFace *Self, enum XML_Error code); - long APICALL (*XML_GetCurrentByteIndex)(struct ExpatIFace *Self, XML_Parser parser); - int APICALL (*XML_GetCurrentLineNumber)(struct ExpatIFace *Self, XML_Parser parser); - int APICALL (*XML_GetCurrentColumnNumber)(struct ExpatIFace *Self, XML_Parser parser); - int APICALL (*XML_GetCurrentByteCount)(struct ExpatIFace *Self, XML_Parser parser); - const char * APICALL (*XML_GetInputContext)(struct ExpatIFace *Self, XML_Parser parser, int * offset, int * size); - void APICALL (*XML_SetUserData)(struct ExpatIFace *Self, XML_Parser parser, void * userData); - void APICALL (*XML_DefaultCurrent)(struct ExpatIFace *Self, XML_Parser parser); - void APICALL (*XML_UseParserAsHandlerArg)(struct ExpatIFace *Self, XML_Parser parser); - enum XML_Status APICALL (*XML_SetBase)(struct ExpatIFace *Self, XML_Parser parser, const XML_Char * base); - const XML_Char * APICALL (*XML_GetBase)(struct ExpatIFace *Self, XML_Parser parser); - int APICALL (*XML_GetSpecifiedAttributeCount)(struct ExpatIFace *Self, XML_Parser parser); - int APICALL (*XML_GetIdAttributeIndex)(struct ExpatIFace *Self, XML_Parser parser); - enum XML_Status APICALL (*XML_SetEncoding)(struct ExpatIFace *Self, XML_Parser parser, const XML_Char * encoding); - int APICALL (*XML_SetParamEntityParsing)(struct ExpatIFace *Self, XML_Parser parser, enum XML_ParamEntityParsing parsing); - void APICALL (*XML_SetReturnNSTriplet)(struct ExpatIFace *Self, XML_Parser parser, int do_nst); - const XML_LChar * APICALL (*XML_ExpatVersion)(struct ExpatIFace *Self); - XML_Expat_Version APICALL (*XML_ExpatVersionInfo)(struct ExpatIFace *Self); - XML_Bool APICALL (*XML_ParserReset)(struct ExpatIFace *Self, XML_Parser parser, const XML_Char * encoding); - void APICALL (*XML_SetSkippedEntityHandler)(struct ExpatIFace *Self, XML_Parser parser, XML_SkippedEntityHandler handler); - enum XML_Error APICALL (*XML_UseForeignDTD)(struct ExpatIFace *Self, XML_Parser parser, XML_Bool useDTD); - const XML_Feature * APICALL (*XML_GetFeatureList)(struct ExpatIFace *Self); - enum XML_Status APICALL (*XML_StopParser)(struct ExpatIFace *Self, XML_Parser parser, XML_Bool resumable); - enum XML_Status APICALL (*XML_ResumeParser)(struct ExpatIFace *Self, XML_Parser parser); - void APICALL (*XML_GetParsingStatus)(struct ExpatIFace *Self, XML_Parser parser, XML_ParsingStatus * status); - void APICALL (*XML_FreeContentModel)(struct ExpatIFace *Self, XML_Parser parser, XML_Content * model); - void * APICALL (*XML_MemMalloc)(struct ExpatIFace *Self, XML_Parser parser, size_t size); - void * APICALL (*XML_MemRealloc)(struct ExpatIFace *Self, XML_Parser parser, void * ptr, size_t size); - void APICALL (*XML_MemFree)(struct ExpatIFace *Self, XML_Parser parser, void * ptr); -}; - -#endif /* EXPAT_INTERFACE_DEF_H */ diff --git a/lib-src/expat/amiga/include/libraries/expat.h b/lib-src/expat/amiga/include/libraries/expat.h deleted file mode 100644 index 1b57387c7..000000000 --- a/lib-src/expat/amiga/include/libraries/expat.h +++ /dev/null @@ -1,566 +0,0 @@ -#ifndef LIBRARIES_EXPAT_H -#define LIBRARIES_EXPAT_H - -/* -** Copyright (c) 2001-2007 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - - -/****************************************************************************/ - -#ifdef __cplusplus -extern "C" { -#endif - -#ifdef __GNUC__ - #ifdef __PPC__ - #pragma pack(2) - #endif -#elif defined(__VBCC__) - #pragma amiga-align -#endif - -/****************************************************************************/ - - -#include - -#ifndef XMLCALL -#define XMLCALL -#endif - -typedef char XML_Char; -typedef char XML_LChar; -typedef long XML_Index; -typedef unsigned long XML_Size; - -struct XML_ParserStruct; -typedef struct XML_ParserStruct *XML_Parser; - -typedef unsigned char XML_Bool; -#define XML_TRUE ((XML_Bool) 1) -#define XML_FALSE ((XML_Bool) 0) - -enum XML_Status { - XML_STATUS_ERROR = 0, -#define XML_STATUS_ERROR XML_STATUS_ERROR - XML_STATUS_OK = 1, -#define XML_STATUS_OK XML_STATUS_OK - XML_STATUS_SUSPENDED = 2, -#define XML_STATUS_SUSPENDED XML_STATUS_SUSPENDED -}; - -enum XML_Error { - XML_ERROR_NONE, - XML_ERROR_NO_MEMORY, - XML_ERROR_SYNTAX, - XML_ERROR_NO_ELEMENTS, - XML_ERROR_INVALID_TOKEN, - XML_ERROR_UNCLOSED_TOKEN, - XML_ERROR_PARTIAL_CHAR, - XML_ERROR_TAG_MISMATCH, - XML_ERROR_DUPLICATE_ATTRIBUTE, - XML_ERROR_JUNK_AFTER_DOC_ELEMENT, - XML_ERROR_PARAM_ENTITY_REF, - XML_ERROR_UNDEFINED_ENTITY, - XML_ERROR_RECURSIVE_ENTITY_REF, - XML_ERROR_ASYNC_ENTITY, - XML_ERROR_BAD_CHAR_REF, - XML_ERROR_BINARY_ENTITY_REF, - XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF, - XML_ERROR_MISPLACED_XML_PI, - XML_ERROR_UNKNOWN_ENCODING, - XML_ERROR_INCORRECT_ENCODING, - XML_ERROR_UNCLOSED_CDATA_SECTION, - XML_ERROR_EXTERNAL_ENTITY_HANDLING, - XML_ERROR_NOT_STANDALONE, - XML_ERROR_UNEXPECTED_STATE, - XML_ERROR_ENTITY_DECLARED_IN_PE, - XML_ERROR_FEATURE_REQUIRES_XML_DTD, - XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING, - XML_ERROR_UNBOUND_PREFIX, - XML_ERROR_UNDECLARING_PREFIX, - XML_ERROR_INCOMPLETE_PE, - XML_ERROR_XML_DECL, - XML_ERROR_TEXT_DECL, - XML_ERROR_PUBLICID, - XML_ERROR_SUSPENDED, - XML_ERROR_NOT_SUSPENDED, - XML_ERROR_ABORTED, - XML_ERROR_FINISHED, - XML_ERROR_SUSPEND_PE, - XML_ERROR_RESERVED_PREFIX_XML, - XML_ERROR_RESERVED_PREFIX_XMLNS, - XML_ERROR_RESERVED_NAMESPACE_URI -}; - -enum XML_Content_Type { - XML_CTYPE_EMPTY = 1, - XML_CTYPE_ANY, - XML_CTYPE_MIXED, - XML_CTYPE_NAME, - XML_CTYPE_CHOICE, - XML_CTYPE_SEQ -}; - -enum XML_Content_Quant { - XML_CQUANT_NONE, - XML_CQUANT_OPT, - XML_CQUANT_REP, - XML_CQUANT_PLUS -}; - -typedef struct XML_cp XML_Content; - -struct XML_cp { - enum XML_Content_Type type; - enum XML_Content_Quant quant; - XML_Char * name; - unsigned int numchildren; - XML_Content * children; -}; - - -typedef void (*XML_ElementDeclHandler) (void *userData, - const XML_Char *name, - XML_Content *model); - -void -XML_SetElementDeclHandler(XML_Parser parser, - XML_ElementDeclHandler eldecl); - -typedef void (*XML_AttlistDeclHandler) ( - void *userData, - const XML_Char *elname, - const XML_Char *attname, - const XML_Char *att_type, - const XML_Char *dflt, - int isrequired); - -void -XML_SetAttlistDeclHandler(XML_Parser parser, - XML_AttlistDeclHandler attdecl); - -typedef void (*XML_XmlDeclHandler) (void *userData, - const XML_Char *version, - const XML_Char *encoding, - int standalone); - -void -XML_SetXmlDeclHandler(XML_Parser parser, - XML_XmlDeclHandler xmldecl); - - -typedef struct { - void *(*malloc_fcn)(size_t size); - void *(*realloc_fcn)(void *ptr, size_t size); - void (*free_fcn)(void *ptr); -} XML_Memory_Handling_Suite; - -XML_Parser -XML_ParserCreate(const XML_Char *encoding); - -XML_Parser -XML_ParserCreateNS(const XML_Char *encoding, XML_Char namespaceSeparator); - - -XML_Parser -XML_ParserCreate_MM(const XML_Char *encoding, - const XML_Memory_Handling_Suite *memsuite, - const XML_Char *namespaceSeparator); - -XML_Bool -XML_ParserReset(XML_Parser parser, const XML_Char *encoding); - -typedef void (*XML_StartElementHandler) (void *userData, - const XML_Char *name, - const XML_Char **atts); - -typedef void (*XML_EndElementHandler) (void *userData, - const XML_Char *name); - - -typedef void (*XML_CharacterDataHandler) (void *userData, - const XML_Char *s, - int len); - -typedef void (*XML_ProcessingInstructionHandler) ( - void *userData, - const XML_Char *target, - const XML_Char *data); - -typedef void (*XML_CommentHandler) (void *userData, - const XML_Char *data); - -typedef void (*XML_StartCdataSectionHandler) (void *userData); -typedef void (*XML_EndCdataSectionHandler) (void *userData); - -typedef void (*XML_DefaultHandler) (void *userData, - const XML_Char *s, - int len); - -typedef void (*XML_StartDoctypeDeclHandler) ( - void *userData, - const XML_Char *doctypeName, - const XML_Char *sysid, - const XML_Char *pubid, - int has_internal_subset); - -typedef void (*XML_EndDoctypeDeclHandler)(void *userData); - -typedef void (*XML_EntityDeclHandler) ( - void *userData, - const XML_Char *entityName, - int is_parameter_entity, - const XML_Char *value, - int value_length, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName); - -void -XML_SetEntityDeclHandler(XML_Parser parser, - XML_EntityDeclHandler handler); - -typedef void (*XML_UnparsedEntityDeclHandler) ( - void *userData, - const XML_Char *entityName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName); - -typedef void (*XML_NotationDeclHandler) ( - void *userData, - const XML_Char *notationName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId); - -typedef void (*XML_StartNamespaceDeclHandler) ( - void *userData, - const XML_Char *prefix, - const XML_Char *uri); - -typedef void (*XML_EndNamespaceDeclHandler) ( - void *userData, - const XML_Char *prefix); - -typedef int (*XML_NotStandaloneHandler) (void *userData); - -typedef int (*XML_ExternalEntityRefHandler) ( - XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId); - -typedef void (*XML_SkippedEntityHandler) ( - void *userData, - const XML_Char *entityName, - int is_parameter_entity); - -typedef struct { - int map[256]; - void *data; - int (*convert)(void *data, const char *s); - void (*release)(void *data); -} XML_Encoding; - -typedef int (*XML_UnknownEncodingHandler) ( - void *encodingHandlerData, - const XML_Char *name, - XML_Encoding *info); - -void -XML_SetElementHandler(XML_Parser parser, - XML_StartElementHandler start, - XML_EndElementHandler end); - -void -XML_SetStartElementHandler(XML_Parser parser, - XML_StartElementHandler handler); - -void -XML_SetEndElementHandler(XML_Parser parser, - XML_EndElementHandler handler); - -void -XML_SetCharacterDataHandler(XML_Parser parser, - XML_CharacterDataHandler handler); - -void -XML_SetProcessingInstructionHandler(XML_Parser parser, - XML_ProcessingInstructionHandler handler); -void -XML_SetCommentHandler(XML_Parser parser, - XML_CommentHandler handler); - -void -XML_SetCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start, - XML_EndCdataSectionHandler end); - -void -XML_SetStartCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start); - -void -XML_SetEndCdataSectionHandler(XML_Parser parser, - XML_EndCdataSectionHandler end); - -void -XML_SetDefaultHandler(XML_Parser parser, - XML_DefaultHandler handler); - -void -XML_SetDefaultHandlerExpand(XML_Parser parser, - XML_DefaultHandler handler); - -void -XML_SetDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start, - XML_EndDoctypeDeclHandler end); - -void -XML_SetStartDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start); - -void -XML_SetEndDoctypeDeclHandler(XML_Parser parser, - XML_EndDoctypeDeclHandler end); - -void -XML_SetUnparsedEntityDeclHandler(XML_Parser parser, - XML_UnparsedEntityDeclHandler handler); - -void -XML_SetNotationDeclHandler(XML_Parser parser, - XML_NotationDeclHandler handler); - -void -XML_SetNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start, - XML_EndNamespaceDeclHandler end); - -void -XML_SetStartNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start); - -void -XML_SetEndNamespaceDeclHandler(XML_Parser parser, - XML_EndNamespaceDeclHandler end); - -void -XML_SetNotStandaloneHandler(XML_Parser parser, - XML_NotStandaloneHandler handler); - -void -XML_SetExternalEntityRefHandler(XML_Parser parser, - XML_ExternalEntityRefHandler handler); - -void -XML_SetExternalEntityRefHandlerArg(XML_Parser parser, - void *arg); - -void -XML_SetSkippedEntityHandler(XML_Parser parser, - XML_SkippedEntityHandler handler); - -void -XML_SetUnknownEncodingHandler(XML_Parser parser, - XML_UnknownEncodingHandler handler, - void *encodingHandlerData); - -void -XML_DefaultCurrent(XML_Parser parser); - -void -XML_SetReturnNSTriplet(XML_Parser parser, int do_nst); - -void -XML_SetUserData(XML_Parser parser, void *userData); - -#define XML_GetUserData(parser) (*(void **)(parser)) - -enum XML_Status -XML_SetEncoding(XML_Parser parser, const XML_Char *encoding); - -void -XML_UseParserAsHandlerArg(XML_Parser parser); - -enum XML_Error -XML_UseForeignDTD(XML_Parser parser, XML_Bool useDTD); - - -enum XML_Status -XML_SetBase(XML_Parser parser, const XML_Char *base); - -const XML_Char * -XML_GetBase(XML_Parser parser); - -int -XML_GetSpecifiedAttributeCount(XML_Parser parser); - -int -XML_GetIdAttributeIndex(XML_Parser parser); - -enum XML_Status -XML_Parse(XML_Parser parser, const char *s, int len, int isFinal); - -void * -XML_GetBuffer(XML_Parser parser, int len); - -enum XML_Status -XML_ParseBuffer(XML_Parser parser, int len, int isFinal); - -enum XML_Status -XML_StopParser(XML_Parser parser, XML_Bool resumable); - -enum XML_Status -XML_ResumeParser(XML_Parser parser); - -enum XML_Parsing { - XML_INITIALIZED, - XML_PARSING, - XML_FINISHED, - XML_SUSPENDED -}; - -typedef struct { - enum XML_Parsing parsing; - XML_Bool finalBuffer; -} XML_ParsingStatus; - -void -XML_GetParsingStatus(XML_Parser parser, XML_ParsingStatus *status); - -XML_Parser -XML_ExternalEntityParserCreate(XML_Parser parser, - const XML_Char *context, - const XML_Char *encoding); - -enum XML_ParamEntityParsing { - XML_PARAM_ENTITY_PARSING_NEVER, - XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE, - XML_PARAM_ENTITY_PARSING_ALWAYS -}; - -int -XML_SetParamEntityParsing(XML_Parser parser, - enum XML_ParamEntityParsing parsing); - -enum XML_Error -XML_GetErrorCode(XML_Parser parser); - -int XML_GetCurrentLineNumber(XML_Parser parser); -int XML_GetCurrentColumnNumber(XML_Parser parser); -long XML_GetCurrentByteIndex(XML_Parser parser); - -int -XML_GetCurrentByteCount(XML_Parser parser); - -const char * -XML_GetInputContext(XML_Parser parser, - int *offset, - int *size); - -#define XML_GetErrorLineNumber XML_GetCurrentLineNumber -#define XML_GetErrorColumnNumber XML_GetCurrentColumnNumber -#define XML_GetErrorByteIndex XML_GetCurrentByteIndex - -void -XML_FreeContentModel(XML_Parser parser, XML_Content *model); - -void * -XML_MemMalloc(XML_Parser parser, size_t size); - -void * -XML_MemRealloc(XML_Parser parser, void *ptr, size_t size); - -void -XML_MemFree(XML_Parser parser, void *ptr); - -void -XML_ParserFree(XML_Parser parser); - -const XML_LChar * -XML_ErrorString(enum XML_Error code); - -const XML_LChar * -XML_ExpatVersion(void); - -typedef struct { - int major; - int minor; - int micro; -} XML_Expat_Version; - -XML_Expat_Version -XML_ExpatVersionInfo(void); - -enum XML_FeatureEnum { - XML_FEATURE_END = 0, - XML_FEATURE_UNICODE, - XML_FEATURE_UNICODE_WCHAR_T, - XML_FEATURE_DTD, - XML_FEATURE_CONTEXT_BYTES, - XML_FEATURE_MIN_SIZE, - XML_FEATURE_SIZEOF_XML_CHAR, - XML_FEATURE_SIZEOF_XML_LCHAR, - XML_FEATURE_NS, - XML_FEATURE_LARGE_SIZE -}; - -typedef struct { - enum XML_FeatureEnum feature; - const XML_LChar *name; - long int value; -} XML_Feature; - -const XML_Feature * -XML_GetFeatureList(void); - - -#define XML_MAJOR_VERSION 2 -#define XML_MINOR_VERSION 0 -#define XML_MICRO_VERSION 1 - - -/****************************************************************************/ - -#ifdef __GNUC__ - #ifdef __PPC__ - #pragma pack() - #endif -#elif defined(__VBCC__) - #pragma default-align -#endif - -#ifdef __cplusplus -} -#endif - -/****************************************************************************/ - -#endif /* EXPAT_EXPAT_H */ diff --git a/lib-src/expat/amiga/include/proto/expat.h b/lib-src/expat/amiga/include/proto/expat.h deleted file mode 100644 index 90bf62c46..000000000 --- a/lib-src/expat/amiga/include/proto/expat.h +++ /dev/null @@ -1,52 +0,0 @@ -#ifndef PROTO_EXPAT_H -#define PROTO_EXPAT_H - -#ifndef LIBRARIES_EXPAT_H -#include -#endif - -/****************************************************************************/ - -#ifndef __NOLIBBASE__ - #ifndef __USE_BASETYPE__ - extern struct Library * ExpatBase; - #else - extern struct Library * ExpatBase; - #endif /* __USE_BASETYPE__ */ -#endif /* __NOLIBBASE__ */ - -/****************************************************************************/ - -#ifdef __amigaos4__ - #include - #ifdef __USE_INLINE__ - #include - #endif /* __USE_INLINE__ */ - #ifndef CLIB_EXPAT_PROTOS_H - #define CLIB_EXPAT_PROTOS_H 1 - #endif /* CLIB_EXPAT_PROTOS_H */ - #ifndef __NOGLOBALIFACE__ - extern struct ExpatIFace *IExpat; - #endif /* __NOGLOBALIFACE__ */ -#else /* __amigaos4__ */ - #ifndef CLIB_EXPAT_PROTOS_H - #include - #endif /* CLIB_EXPAT_PROTOS_H */ - #if defined(__GNUC__) - #ifndef __PPC__ - #include - #else - #include - #endif /* __PPC__ */ - #elif defined(__VBCC__) - #ifndef __PPC__ - #include - #endif /* __PPC__ */ - #else - #include - #endif /* __GNUC__ */ -#endif /* __amigaos4__ */ - -/****************************************************************************/ - -#endif /* PROTO_EXPAT_H */ diff --git a/lib-src/expat/amiga/launch.c b/lib-src/expat/amiga/launch.c deleted file mode 100755 index 20b069c3f..000000000 --- a/lib-src/expat/amiga/launch.c +++ /dev/null @@ -1,57 +0,0 @@ -/* -** Copyright (c) 2001-2009 Expat maintainers. -** -** Permission is hereby granted, free of charge, to any person obtaining -** a copy of this software and associated documentation files (the -** "Software"), to deal in the Software without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Software, and to -** permit persons to whom the Software is furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Software. -** -** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -*/ - -#ifdef __USE_INLINE__ -#undef __USE_INLINE__ -#endif - -#include -#include - -struct Library* ExpatBase = 0; -struct ExpatIFace* IExpat = 0; - - -void setup() __attribute__((constructor)); -void cleanup() __attribute__((destructor)); - - -void setup() -{ - ExpatBase = IExec->OpenLibrary("expat.library", 53); - IExpat = (struct ExpatIFace*)IExec->GetInterface(ExpatBase, "main", 1, NULL); - - if ( IExpat == 0 ) { - IExec->DebugPrintF("Can't open expat.library\n"); - } -} - - -void cleanup() -{ - IExec->DropInterface((struct Interface*)IExpat); - IExpat = 0; - - IExec->CloseLibrary(ExpatBase); - ExpatBase = 0; -} diff --git a/lib-src/expat/bcb5/README.txt b/lib-src/expat/bcb5/README.txt deleted file mode 100644 index 486f1ca85..000000000 --- a/lib-src/expat/bcb5/README.txt +++ /dev/null @@ -1,87 +0,0 @@ - - Using a Borland compiler product - -The files in this directory support using both the free Borland command-line -compiler tools and the Borland C++ Builder IDE. The project files have been -tested with both versions 5 and 6 of the C++ Builder product. - - Using the free BCC32 command line compiler - -After downloading and installing the free C++ Builder commandline version, -perform the following steps (assuming it was installed under C:\Borland\BCC55): - -1) Add "C:\Borland\BCC55\BIN" to your path -2) Set the environment variable BCB to "C:\Borland\BCC55". -3) edit makefile.mak: enable or comment out the appropriate commands under - clean & distclean, depending on whether your OS can use deltree /y or - del /s/f/q. - -After that, you should simply cd to the bcb5 directory in your Expat directory -tree (same structure as CVS) and run "make all" or just "make". - - Naming - -The libraries have the base name "libexpat" followed optionally by an "s" -(static) or a "w" (unicode version), then an underscore and optionally -"mt" (multi-threaded) and "d" (dynamic RTL). - -To change the name of the library a project file produces, edit the project -option source (see step 1 under Unicode below) and change the name contained in -the PROJECT tag. In a make file, change the value assigned to the PROJECT -variable. Also, the LIBRARY entry in the .def file has to be changed to -correspond to the new executable name. - - - Unicode Considerations - -There are no facilities in the BCB 5 GUI to create a unicode-enabled -application. Fortunately, it is not hard to do by hand. - -1. The startup .obj system file must be changed to the unicode version. - Go to Project|Edit Option Source, and scroll down to the ALLOBJ tag. Change - c0x32.obj to c0x32w.obj. Editing this file can be quirky, but usually the - following kludge will make the change stick. Close and save the file - (CTRL-F4) then open the options dialog (CTRL-Shift-F11), then click OK on - the dialog immediately without changing anything in it. If this doesn't work, - you will have to close the project completely and edit the .bpr file by hand. - - If you are using a make file, just change the startup .obj file assigned - to the ALLOBJ variable. - -2. Add the macro define XML_UNICODE_WCHAR_T. In the GUI that goes in the options - dialog, Directories/Conditionals tab, in the Conditional define box. In a - make file, put it in the USERDEFINES variable. - -3. Of course, your code has to be written for unicode. As a start, the "main" - function is called "wmain". The tchar macros are an interesting way to - write code that can easily switch between unicode and utf-8. If these macros - are used, then simply adding the conditional define _UNICODE as well as - XML_UNICODE_WCHAR_T will bring in the unicode versions of the tchar macros. - Otherwise the utf-8 versions are used. xmlwf uses its own versions of the - tchar macros which are switched on and off by the XML_UNICODE macro, which - itself is set by the XML_UNICODE_WCHAR_T define. - - Threading - -The libexpat libraries are all built to link with the multi-threaded dynamic RTL's. -That means they require CC32xxMT.DLL present on the installation target. -To create single-threaded libs, do the following: - -1. The compiler option for multi-threading must be turned off. Following the - instructions above to edit the option source, remove the -tWM option from - the CFLAG1 tag. In a make file, remove it from the CFLAG1 variable. - -2. The single threaded RTL must be called. change the RTL in the ALLLIB tag or - variable (GUI or makefile repectively) to the version without the "mt" in the - name. For example, change cw32mti.lib to cw32i.lib. - - Static RTL's - -To build the libs with static RTL's do the following, - -1. For the static expatlibs, in the Tlib tab on the options dialog, uncheck the - "Use dynamic RTL" box. For the dynamic expatlibs, in the Linker tab on the - options dialog, uncheck "Use dynamic RTL". If you are using a make file, - remove the _RTLDLL assignment to the SYSDEFINES variable, and change the RTL - to the version without an "i" in the ALLLIB variable. For example, - cw32mti.lib would become cw32mt.lib. diff --git a/lib-src/expat/bcb5/all_projects.bpg b/lib-src/expat/bcb5/all_projects.bpg deleted file mode 100644 index 27c9a1cba..000000000 --- a/lib-src/expat/bcb5/all_projects.bpg +++ /dev/null @@ -1,49 +0,0 @@ -#------------------------------------------------------------------------------ -VERSION = BWS.01 -#------------------------------------------------------------------------------ -!ifndef ROOT -ROOT = $(MAKEDIR)\.. -!endif -#------------------------------------------------------------------------------ -MAKE = $(ROOT)\bin\make.exe -$(MAKEFLAGS) -f$** -DCC = $(ROOT)\bin\dcc32.exe $** -BRCC = $(ROOT)\bin\brcc32.exe $** -#------------------------------------------------------------------------------ -PROJECTS = setup libexpat_mtd.dll libexpats_mtd.lib libexpatw_mtd.dll \ - libexpatws_mtd.lib elements.exe outline.exe xmlwf.exe -#------------------------------------------------------------------------------ -default: $(PROJECTS) -#------------------------------------------------------------------------------ - -libexpat_mtd.dll: expat.bpr - $(ROOT)\bin\bpr2mak $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -libexpats_mtd.lib: expat_static.bpr - $(ROOT)\bin\bpr2mak -t$(ROOT)\bin\deflib.bmk $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -libexpatw_mtd.dll: expatw.bpr - $(ROOT)\bin\bpr2mak $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -libexpatws_mtd.lib: expatw_static.bpr - $(ROOT)\bin\bpr2mak -t$(ROOT)\bin\deflib.bmk $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -elements.exe: elements.bpr - $(ROOT)\bin\bpr2mak $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -outline.exe: outline.bpr - $(ROOT)\bin\bpr2mak $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -xmlwf.exe: xmlwf.bpr - $(ROOT)\bin\bpr2mak $** - $(ROOT)\bin\make -$(MAKEFLAGS) -f$*.mak - -setup: setup.bat - call $** - - diff --git a/lib-src/expat/bcb5/elements.bpf b/lib-src/expat/bcb5/elements.bpf deleted file mode 100644 index 5c1e878d6..000000000 --- a/lib-src/expat/bcb5/elements.bpf +++ /dev/null @@ -1,4 +0,0 @@ -USEUNIT("..\examples\elements.c"); -USELIB("Release\libexpats_mtd.lib"); -//--------------------------------------------------------------------------- -main diff --git a/lib-src/expat/bcb5/elements.bpr b/lib-src/expat/bcb5/elements.bpr deleted file mode 100644 index c21c0f59f..000000000 --- a/lib-src/expat/bcb5/elements.bpr +++ /dev/null @@ -1,149 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\examples;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=8 -Item0=..\examples;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\examples;$(BCB)\lib;..\examples\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);..\lib\Release-w_static -Item4=$(BCB)\lib;$(RELEASELIBPATH);..\lib\Release_static -Item5=$(BCB)\lib;$(RELEASELIBPATH);C:\src\expat\lib\Release_static -Item6=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item7=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=17 -Item0=WIN32;NDEBUG;_CONSOLE;XML_STATIC -Item1=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_STATIC -Item2=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE;XML_STATIC -Item3=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE -Item4=WIN32;NDEBUG;_CONSOLE;_DEBUG -Item5=WIN32;NDEBUG;_CONSOLE;XML_STATIC;_DEBUG -Item6=WIN32;NDEBUG;_CONSOLE;XML_STATIC;_DEBUG;_UNICODE -Item7=WIN32;NDEBUG;_CONSOLE;XML_STATIC;_DEBUG;XML_UNICODE_WCHAR_T -Item8=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG;XML_UNICODE_WCHAR_T -Item9=WIN32;NDEBUG;_CONSOLE;_UNICODE;XML_STATIC;_DEBUG;XML_UNICODE_WCHAR_T -Item10=WIN32;NDEBUG;_CONSOLE;_UNICODE;XML_STATIC;_DEBUG;XML_UNICODE -Item11=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG;XML_UNICODE_WCHAR_T;__WCHAR_T -Item12=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE -Item13=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG;XML_UNICODE;_UNICODE -Item14=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG;XML_UNICODE -Item15=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC;_DEBUG -Item16=WIN32;NDEBUG;_CONSOLE;_MBCS;XML_STATIC - -[HistoryLists\hlIntOutputDir] -Count=5 -Item0=Release\obj\examples -Item1=Release\obj\elements -Item2=Release\obj\mts -Item3=..\examples\Release -Item4=Release - -[HistoryLists\hlFinalOutputDir] -Count=1 -Item0=Release\ - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/elements.mak b/lib-src/expat/bcb5/elements.mak deleted file mode 100644 index d4427fd51..000000000 --- a/lib-src/expat/bcb5/elements.mak +++ /dev/null @@ -1,186 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\elements.exe -OBJFILES = Release\obj\examples\elements.obj -RESFILES = -MAINSOURCE = elements.bpf -RESDEPEN = $(RESFILES) -LIBFILES = Release\libexpats_mtd.lib -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi \ - ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi \ - VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi \ - dclocx50.bpi bcb2kaxserver50.bpi dclusr50.bpi -SPARELIBS = -DEFFILE = -# --------------------------------------------------------------------------- -PATHCPP = .;..\examples -PATHASM = .; -PATHPAS = .; -PATHRC = .; -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = WIN32;NDEBUG;_CONSOLE;XML_STATIC -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\examples;$(BCB)\include -LIBPATH = ..\examples;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS= -w-par -w-8027 -w-8026 -# --------------------------------------------------------------------------- -CFLAG1 = -O2 -X- -a8 -b -k- -vi -q -I..\lib -c -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\examples -N0Release\obj\examples -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -IRelease\obj\examples -D"" -ap -Tpe -x -Gn -q -L..\LIB\RELEASE_STATIC -# --------------------------------------------------------------------------- -ALLOBJ = c0x32.obj $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cw32mti.lib -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = ilink32 -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) @&&! - $(LFLAGS) -L$(LIBPATH) + - $(ALLOBJ), + - $(PROJECT),, + - $(ALLLIB), + - $(DEFFILE), + - $(ALLRES) -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/expat.bpf b/lib-src/expat/bcb5/expat.bpf deleted file mode 100644 index 2c423283f..000000000 --- a/lib-src/expat/bcb5/expat.bpf +++ /dev/null @@ -1,6 +0,0 @@ -USEUNIT("..\lib\xmlparse.c"); -USEUNIT("..\lib\xmlrole.c"); -USEUNIT("..\lib\xmltok.c"); -USEDEF("libexpat_mtd.def"); -//--------------------------------------------------------------------------- -#define DllEntryPoint diff --git a/lib-src/expat/bcb5/expat.bpr b/lib-src/expat/bcb5/expat.bpr deleted file mode 100644 index 291b8cafc..000000000 --- a/lib-src/expat/bcb5/expat.bpr +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\lib;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=5 -Item0=..\lib;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\lib;$(BCB)\lib;..\lib\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item4=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=8 -Item0=_WINDOWS;WIN32;NDEBUG;_USRDLL;COMPILED_FROM_DSP;EXPAT_EXPORTS -Item1=_WINDOWS;WIN32;NDEBUG;_DEBUG;_USRDLL;COMPILED_FROM_DSP;EXPAT_EXPORTS -Item2=WIN32;_WINDOWS;NDEBUG;_DEBUG;_USRDLL;COMPILED_FROM_DSP;EXPAT_EXPORTS -Item3=WIN32;_WINDOWS;NDEBUG;_DEBUG;_USRDLL;EXPAT_EXPORTS;COMPILED_FROM_DSP -Item4=NDEBUG;WIN32;_WINDOWS;_USRDLL;_DEBUG;EXPAT_EXPORTS;COMPILED_FROM_DSP -Item5=NDEBUG;WIN32;_WINDOWS;_USRDLL;EXPAT_EXPORTS;COMPILED_FROM_DSP;_DEBUG -Item6=NDEBUG;WIN32;_WINDOWS;_MBCS;_USRDLL;EXPAT_EXPORTS;COMPILED_FROM_DSP;_DEBUG -Item7=NDEBUG;WIN32;_WINDOWS;_MBCS;_USRDLL;EXPAT_EXPORTS;COMPILED_FROM_DSP - -[HistoryLists\hlIntOutputDir] -Count=7 -Item0=Release\obj\libexpat -Item1=Release\obj\libexpat_static -Item2=Release\obj\mtd -Item3=Release\obj\mt -Item4=Release\obj -Item5=Release -Item6=..\lib\Release - -[HistoryLists\hlFinalOutputDir] -Count=1 -Item0=Release\ - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/expat.mak b/lib-src/expat/bcb5/expat.mak deleted file mode 100644 index 7c9c23f52..000000000 --- a/lib-src/expat/bcb5/expat.mak +++ /dev/null @@ -1,187 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\libexpat_mtd.dll -OBJFILES = Release\obj\libexpat\xmlparse.obj Release\obj\libexpat\xmlrole.obj \ - Release\obj\libexpat\xmltok.obj -RESFILES = -MAINSOURCE = expat.bpf -RESDEPEN = $(RESFILES) -LIBFILES = -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi \ - ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi \ - VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi \ - dclocx50.bpi bcb2kaxserver50.bpi dclusr50.bpi -SPARELIBS = -DEFFILE = libexpat_mtd.def -# --------------------------------------------------------------------------- -PATHCPP = .;..\lib -PATHASM = .; -PATHPAS = .; -PATHRC = .; -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = _WINDOWS;WIN32;NDEBUG;_USRDLL;COMPILED_FROM_DSP -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\lib;$(BCB)\include -LIBPATH = ..\lib;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS= -w-rch -w-par -w-8027 -w-8026 -w-ccc -# --------------------------------------------------------------------------- -CFLAG1 = -WD -O2 -X- -a8 -b -k- -vi -q -tWM -c -tWD -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\libexpat -N0Release\obj\libexpat -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -IRelease\obj\libexpat -D"" -aa -Tpd -x -Gn -Gi -q -# --------------------------------------------------------------------------- -ALLOBJ = c0d32.obj $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cw32mti.lib -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = ilink32 -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) @&&! - $(LFLAGS) -L$(LIBPATH) + - $(ALLOBJ), + - $(PROJECT),, + - $(ALLLIB), + - $(DEFFILE), + - $(ALLRES) -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/expat_static.bpf b/lib-src/expat/bcb5/expat_static.bpf deleted file mode 100644 index 5ca458edc..000000000 --- a/lib-src/expat/bcb5/expat_static.bpf +++ /dev/null @@ -1,5 +0,0 @@ -USEUNIT("..\lib\xmlparse.c"); -USEUNIT("..\lib\xmlrole.c"); -USEUNIT("..\lib\xmltok.c"); -//--------------------------------------------------------------------------- -#define Library diff --git a/lib-src/expat/bcb5/expat_static.bpr b/lib-src/expat/bcb5/expat_static.bpr deleted file mode 100644 index 2f6ec4d3b..000000000 --- a/lib-src/expat/bcb5/expat_static.bpr +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\lib;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=5 -Item0=..\lib;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\lib;$(BCB)\lib;..\lib\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item4=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=7 -Item0=_WINDOWS;WIN32;NDEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC -Item1=_WINDOWS;WIN32;NDEBUG;_DEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC -Item2=WIN32;_WINDOWS;NDEBUG;_DEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC -Item3=WIN32;_WINDOWS;NDEBUG;_LIB;COMPILED_FROM_DSP;_DEBUG -Item4=WIN32;_WINDOWS;NDEBUG;_LIB;COMPILED_FROM_DSP -Item5=WIN32;_WINDOWS;NDEBUG;_LIB;COMPILED_FROM_DSP;_MBCS -Item6=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP - -[HistoryLists\hlIntOutputDir] -Count=6 -Item0=Release\obj\libexpat_static -Item1=Release\obj\mts -Item2=Release\obj\mt -Item3=Release -Item4=..\lib\Release_static -Item5=Release_static - -[HistoryLists\hlFinalOutputDir] -Count=3 -Item0=Release\ -Item1=Release -Item2=Release_static\ - -[HistoryLists\hlTlibPageSize] -Count=1 -Item0=0x0010 - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/expat_static.mak b/lib-src/expat/bcb5/expat_static.mak deleted file mode 100644 index 9137d3b53..000000000 --- a/lib-src/expat/bcb5/expat_static.mak +++ /dev/null @@ -1,189 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\libexpats_mtd.lib -OBJFILES = Release\obj\libexpat_static\xmlparse.obj \ - Release\obj\libexpat_static\xmlrole.obj \ - Release\obj\libexpat_static\xmltok.obj -RESFILES = -MAINSOURCE = expat_static.bpf -RESDEPEN = $(RESFILES) -LIBFILES = -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = -SPARELIBS = -DEFFILE = -# --------------------------------------------------------------------------- -PATHCPP = .;..\lib -PATHASM = .; -PATHPAS = .; -PATHRC = .; -LINKER = TLib -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = _WINDOWS;WIN32;NDEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\lib;$(BCB)\include -LIBPATH = ..\lib;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS = -w-rch -w-par -w-8027 -w-8026 -w-ccc -LISTFILE = -# --------------------------------------------------------------------------- -CFLAG1 = -O2 -X- -a8 -b -k- -vi -q -tWM -c -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\libexpat_static -N0Release\obj\libexpat_static -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -# --------------------------------------------------------------------------- -ALLOBJ = $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = TLib -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -!if "$(LISTFILE)" == "" -COMMA = -!else -COMMA = , -!endif - -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) /u $@ @&&! - $(LFLAGS) $? $(COMMA) $(LISTFILE) - -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/expatw.bpf b/lib-src/expat/bcb5/expatw.bpf deleted file mode 100644 index 188a6d54e..000000000 --- a/lib-src/expat/bcb5/expatw.bpf +++ /dev/null @@ -1,6 +0,0 @@ -USEUNIT("..\lib\xmlparse.c"); -USEUNIT("..\lib\xmlrole.c"); -USEUNIT("..\lib\xmltok.c"); -USEDEF("libexpatw_mtd.def"); -//--------------------------------------------------------------------------- -#define DllEntryPoint diff --git a/lib-src/expat/bcb5/expatw.bpr b/lib-src/expat/bcb5/expatw.bpr deleted file mode 100644 index 9ec50010b..000000000 --- a/lib-src/expat/bcb5/expatw.bpr +++ /dev/null @@ -1,146 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\lib;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=5 -Item0=..\lib;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\lib;$(BCB)\lib;..\lib\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item4=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=9 -Item0=_WINDOWS;WIN32;NDEBUG;_USRDLL;COMPILED_FROM_DSP;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T -Item1=_WINDOWS;WIN32;NDEBUG;_DEBUG;_USRDLL;COMPILED_FROM_DSP;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T -Item2=_WINDOWS;WIN32;NDEBUG;_DEBUG;_USRDLL;EXPAT_EXPORTS;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T -Item3=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_USRDLL;EXPAT_EXPORTS;_DEBUG;XML_UNICODE_WCHAR_T -Item4=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_USRDLL;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T;_DEBUG -Item5=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_UNICODE;_USRDLL;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T;_DEBUG -Item6=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_UNICODE;_USRDLL;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T -Item7=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_MBCS;_USRDLL;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T;XML_UNICODE -Item8=NDEBUG;COMPILED_FROM_DSP;WIN32;_WINDOWS;_MBCS;_USRDLL;EXPAT_EXPORTS;XML_UNICODE_WCHAR_T - -[HistoryLists\hlIntOutputDir] -Count=8 -Item0=Release\obj\libexpatw -Item1=Release\obj\libexpat -Item2=Release\obj\mtd -Item3=Release\obj\mt -Item4=Release_w\obj -Item5=Release-w\obj -Item6=Release-w -Item7=..\lib\Release-w - -[HistoryLists\hlFinalOutputDir] -Count=5 -Item0=Release\ -Item1=Release -Item2=Release_w\ -Item3=Release-w\ -Item4=Release-w - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/expatw.mak b/lib-src/expat/bcb5/expatw.mak deleted file mode 100644 index 08e17d003..000000000 --- a/lib-src/expat/bcb5/expatw.mak +++ /dev/null @@ -1,187 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\libexpatw_mtd.dll -OBJFILES = Release\obj\libexpatw\xmlparse.obj Release\obj\libexpatw\xmlrole.obj \ - Release\obj\libexpatw\xmltok.obj -RESFILES = -MAINSOURCE = expatw.bpf -RESDEPEN = $(RESFILES) -LIBFILES = -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi \ - ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi \ - VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi \ - dclocx50.bpi bcb2kaxserver50.bpi dclusr50.bpi -SPARELIBS = -DEFFILE = libexpatw_mtd.def -# --------------------------------------------------------------------------- -PATHCPP = .;..\lib -PATHASM = .; -PATHPAS = .; -PATHRC = .; -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = _WINDOWS;WIN32;NDEBUG;_USRDLL;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\lib;$(BCB)\include -LIBPATH = ..\lib;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS= -w-rch -w-par -w-8027 -w-8026 -w-ccc -# --------------------------------------------------------------------------- -CFLAG1 = -WD -O2 -X- -a8 -b -k- -vi -q -tWM -c -tWD -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\libexpatw -N0Release\obj\libexpatw -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -IRelease\obj\libexpatw -D"" -aa -Tpd -x -Gn -Gi -w -q -# --------------------------------------------------------------------------- -ALLOBJ = c0d32w.obj $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cw32mti.lib -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = ilink32 -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) @&&! - $(LFLAGS) -L$(LIBPATH) + - $(ALLOBJ), + - $(PROJECT),, + - $(ALLLIB), + - $(DEFFILE), + - $(ALLRES) -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/expatw_static.bpf b/lib-src/expat/bcb5/expatw_static.bpf deleted file mode 100644 index 5ca458edc..000000000 --- a/lib-src/expat/bcb5/expatw_static.bpf +++ /dev/null @@ -1,5 +0,0 @@ -USEUNIT("..\lib\xmlparse.c"); -USEUNIT("..\lib\xmlrole.c"); -USEUNIT("..\lib\xmltok.c"); -//--------------------------------------------------------------------------- -#define Library diff --git a/lib-src/expat/bcb5/expatw_static.bpr b/lib-src/expat/bcb5/expatw_static.bpr deleted file mode 100644 index 3f12644b6..000000000 --- a/lib-src/expat/bcb5/expatw_static.bpr +++ /dev/null @@ -1,152 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\lib;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=5 -Item0=..\lib;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\lib;$(BCB)\lib;..\lib\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item4=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=15 -Item0=_WINDOWS;WIN32;NDEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC;XML_UNICODE_WCHAR_T -Item1=_WINDOWS;WIN32;NDEBUG;_DEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC;XML_UNICODE_WCHAR_T -Item2=WIN32;_WINDOWS;NDEBUG;_DEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC;XML_UNICODE_WCHAR_T -Item3=WIN32;_WINDOWS;NDEBUG;_DEBUG;_LIB;XML_STATIC;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T -Item4=WIN32;_WINDOWS;NDEBUG;_LIB;COMPILED_FROM_DSP;_DEBUG;XML_UNICODE_WCHAR_T -Item5=WIN32;_WINDOWS;NDEBUG;_UNICODE;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;_DEBUG -Item6=WIN32;_WINDOWS;NDEBUG;_UNICODE;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;_DEBUG;__cplusplus -Item7=WIN32;_WINDOWS;NDEBUG;_UNICODE;_LIB;COMPILED_FROM_DSP;XML_UNICODE;_DEBUG -Item8=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE;_DEBUG -Item9=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;_DEBUG;__WCHAR_T -Item10=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;_DEBUG;_UNICODE -Item11=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE;_DEBUG;_UNICODE -Item12=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;_DEBUG -Item13=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T -Item14=WIN32;_WINDOWS;NDEBUG;_MBCS;_LIB;COMPILED_FROM_DSP;XML_UNICODE_WCHAR_T;XML_UNICODE - -[HistoryLists\hlIntOutputDir] -Count=6 -Item0=Release\obj\libexpatw_static -Item1=Release\obj\libexpat_static -Item2=Release\obj\mts -Item3=Release\obj\mt -Item4=..\lib\Release-w_static -Item5=Release-w_static - -[HistoryLists\hlFinalOutputDir] -Count=3 -Item0=Release\ -Item1=Release -Item2=Release-w_static\ - -[HistoryLists\hlTlibPageSize] -Count=1 -Item0=0x0010 - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/expatw_static.mak b/lib-src/expat/bcb5/expatw_static.mak deleted file mode 100644 index 16b7e5b90..000000000 --- a/lib-src/expat/bcb5/expatw_static.mak +++ /dev/null @@ -1,190 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\libexpatws_mtd.lib -OBJFILES = Release\obj\libexpatw_static\xmlparse.obj \ - Release\obj\libexpatw_static\xmlrole.obj \ - Release\obj\libexpatw_static\xmltok.obj -RESFILES = -MAINSOURCE = expatw_static.bpf -RESDEPEN = $(RESFILES) -LIBFILES = -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = -SPARELIBS = -DEFFILE = -# --------------------------------------------------------------------------- -PATHCPP = .;..\lib -PATHASM = .; -PATHPAS = .; -PATHRC = .; -LINKER = TLib -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = _WINDOWS;WIN32;NDEBUG;_LIB;COMPILED_FROM_DSP;XML_STATIC;XML_UNICODE_WCHAR_T -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\lib;$(BCB)\include -LIBPATH = ..\lib;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS = -w-rch -w-par -w-8027 -w-8026 -w-ccc -LISTFILE = -# --------------------------------------------------------------------------- -CFLAG1 = -O2 -X- -a8 -b -k- -vi -q -tWM -c -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\libexpatw_static -N0Release\obj\libexpatw_static -$Y- -$L- \ - -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -# --------------------------------------------------------------------------- -ALLOBJ = $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = TLib -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -!if "$(LISTFILE)" == "" -COMMA = -!else -COMMA = , -!endif - -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) /u $@ @&&! - $(LFLAGS) $? $(COMMA) $(LISTFILE) - -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/libexpat_mtd.def b/lib-src/expat/bcb5/libexpat_mtd.def deleted file mode 100644 index fc1cb9554..000000000 --- a/lib-src/expat/bcb5/libexpat_mtd.def +++ /dev/null @@ -1,141 +0,0 @@ -; DEF file for BCB5 -LIBRARY LIBEXPAT_MTD -DESCRIPTION "Implements an XML parser." -EXPORTS - _XML_DefaultCurrent @1 - _XML_ErrorString @2 - _XML_ExpatVersion @3 - _XML_ExpatVersionInfo @4 - _XML_ExternalEntityParserCreate @5 - _XML_GetBase @6 - _XML_GetBuffer @7 - _XML_GetCurrentByteCount @8 - _XML_GetCurrentByteIndex @9 - _XML_GetCurrentColumnNumber @10 - _XML_GetCurrentLineNumber @11 - _XML_GetErrorCode @12 - _XML_GetIdAttributeIndex @13 - _XML_GetInputContext @14 - _XML_GetSpecifiedAttributeCount @15 - _XML_Parse @16 - _XML_ParseBuffer @17 - _XML_ParserCreate @18 - _XML_ParserCreateNS @19 - _XML_ParserCreate_MM @20 - _XML_ParserFree @21 - _XML_SetAttlistDeclHandler @22 - _XML_SetBase @23 - _XML_SetCdataSectionHandler @24 - _XML_SetCharacterDataHandler @25 - _XML_SetCommentHandler @26 - _XML_SetDefaultHandler @27 - _XML_SetDefaultHandlerExpand @28 - _XML_SetDoctypeDeclHandler @29 - _XML_SetElementDeclHandler @30 - _XML_SetElementHandler @31 - _XML_SetEncoding @32 - _XML_SetEndCdataSectionHandler @33 - _XML_SetEndDoctypeDeclHandler @34 - _XML_SetEndElementHandler @35 - _XML_SetEndNamespaceDeclHandler @36 - _XML_SetEntityDeclHandler @37 - _XML_SetExternalEntityRefHandler @38 - _XML_SetExternalEntityRefHandlerArg @39 - _XML_SetNamespaceDeclHandler @40 - _XML_SetNotStandaloneHandler @41 - _XML_SetNotationDeclHandler @42 - _XML_SetParamEntityParsing @43 - _XML_SetProcessingInstructionHandler @44 - _XML_SetReturnNSTriplet @45 - _XML_SetStartCdataSectionHandler @46 - _XML_SetStartDoctypeDeclHandler @47 - _XML_SetStartElementHandler @48 - _XML_SetStartNamespaceDeclHandler @49 - _XML_SetUnknownEncodingHandler @50 - _XML_SetUnparsedEntityDeclHandler @51 - _XML_SetUserData @52 - _XML_SetXmlDeclHandler @53 - _XML_UseParserAsHandlerArg @54 -; added with version 1.95.3 - _XML_ParserReset @55 - _XML_SetSkippedEntityHandler @56 -; added with version 1.95.5 - _XML_GetFeatureList @57 - _XML_UseForeignDTD @58 -; added with version 1.95.6 - _XML_FreeContentModel @59 - _XML_MemMalloc @60 - _XML_MemRealloc @61 - _XML_MemFree @62 -; added with version 1.95.8 - _XML_StopParser @63 - _XML_ResumeParser @64 - _XML_GetParsingStatus @65 - -; Aliases for MS compatible names - XML_DefaultCurrent = _XML_DefaultCurrent - XML_ErrorString = _XML_ErrorString - XML_ExpatVersion = _XML_ExpatVersion - XML_ExpatVersionInfo = _XML_ExpatVersionInfo - XML_ExternalEntityParserCreate = _XML_ExternalEntityParserCreate - XML_GetBase = _XML_GetBase - XML_GetBuffer = _XML_GetBuffer - XML_GetCurrentByteCount = _XML_GetCurrentByteCount - XML_GetCurrentByteIndex = _XML_GetCurrentByteIndex - XML_GetCurrentColumnNumber = _XML_GetCurrentColumnNumber - XML_GetCurrentLineNumber = _XML_GetCurrentLineNumber - XML_GetErrorCode = _XML_GetErrorCode - XML_GetIdAttributeIndex = _XML_GetIdAttributeIndex - XML_GetInputContext = _XML_GetInputContext - XML_GetSpecifiedAttributeCount = _XML_GetSpecifiedAttributeCount - XML_Parse = _XML_Parse - XML_ParseBuffer = _XML_ParseBuffer - XML_ParserCreate = _XML_ParserCreate - XML_ParserCreateNS = _XML_ParserCreateNS - XML_ParserCreate_MM = _XML_ParserCreate_MM - XML_ParserFree = _XML_ParserFree - XML_SetAttlistDeclHandler = _XML_SetAttlistDeclHandler - XML_SetBase = _XML_SetBase - XML_SetCdataSectionHandler = _XML_SetCdataSectionHandler - XML_SetCharacterDataHandler = _XML_SetCharacterDataHandler - XML_SetCommentHandler = _XML_SetCommentHandler - XML_SetDefaultHandler = _XML_SetDefaultHandler - XML_SetDefaultHandlerExpand = _XML_SetDefaultHandlerExpand - XML_SetDoctypeDeclHandler = _XML_SetDoctypeDeclHandler - XML_SetElementDeclHandler = _XML_SetElementDeclHandler - XML_SetElementHandler = _XML_SetElementHandler - XML_SetEncoding = _XML_SetEncoding - XML_SetEndCdataSectionHandler = _XML_SetEndCdataSectionHandler - XML_SetEndDoctypeDeclHandler = _XML_SetEndDoctypeDeclHandler - XML_SetEndElementHandler = _XML_SetEndElementHandler - XML_SetEndNamespaceDeclHandler = _XML_SetEndNamespaceDeclHandler - XML_SetEntityDeclHandler = _XML_SetEntityDeclHandler - XML_SetExternalEntityRefHandler = _XML_SetExternalEntityRefHandler - XML_SetExternalEntityRefHandlerArg = _XML_SetExternalEntityRefHandlerArg - XML_SetNamespaceDeclHandler = _XML_SetNamespaceDeclHandler - XML_SetNotStandaloneHandler = _XML_SetNotStandaloneHandler - XML_SetNotationDeclHandler = _XML_SetNotationDeclHandler - XML_SetParamEntityParsing = _XML_SetParamEntityParsing - XML_SetProcessingInstructionHandler = _XML_SetProcessingInstructionHandler - XML_SetReturnNSTriplet = _XML_SetReturnNSTriplet - XML_SetStartCdataSectionHandler = _XML_SetStartCdataSectionHandler - XML_SetStartDoctypeDeclHandler = _XML_SetStartDoctypeDeclHandler - XML_SetStartElementHandler = _XML_SetStartElementHandler - XML_SetStartNamespaceDeclHandler = _XML_SetStartNamespaceDeclHandler - XML_SetUnknownEncodingHandler = _XML_SetUnknownEncodingHandler - XML_SetUnparsedEntityDeclHandler = _XML_SetUnparsedEntityDeclHandler - XML_SetUserData = _XML_SetUserData - XML_SetXmlDeclHandler = _XML_SetXmlDeclHandler - XML_UseParserAsHandlerArg = _XML_UseParserAsHandlerArg - XML_ParserReset = _XML_ParserReset - XML_SetSkippedEntityHandler = _XML_SetSkippedEntityHandler - XML_GetFeatureList = _XML_GetFeatureList - XML_UseForeignDTD = _XML_UseForeignDTD - XML_FreeContentModel = _XML_FreeContentModel - XML_MemMalloc = _XML_MemMalloc - XML_MemRealloc = _XML_MemRealloc - XML_MemFree = _XML_MemFree - XML_StopParser = _XML_StopParser - XML_ResumeParser = _XML_ResumeParser - XML_GetParsingStatus = _XML_GetParsingStatus - diff --git a/lib-src/expat/bcb5/libexpatw_mtd.def b/lib-src/expat/bcb5/libexpatw_mtd.def deleted file mode 100644 index 418462df5..000000000 --- a/lib-src/expat/bcb5/libexpatw_mtd.def +++ /dev/null @@ -1,140 +0,0 @@ -; DEF file for BCB5 -LIBRARY LIBEXPATW_MTD -DESCRIPTION "Implements an XML parser." -EXPORTS - _XML_DefaultCurrent @1 - _XML_ErrorString @2 - _XML_ExpatVersion @3 - _XML_ExpatVersionInfo @4 - _XML_ExternalEntityParserCreate @5 - _XML_GetBase @6 - _XML_GetBuffer @7 - _XML_GetCurrentByteCount @8 - _XML_GetCurrentByteIndex @9 - _XML_GetCurrentColumnNumber @10 - _XML_GetCurrentLineNumber @11 - _XML_GetErrorCode @12 - _XML_GetIdAttributeIndex @13 - _XML_GetInputContext @14 - _XML_GetSpecifiedAttributeCount @15 - _XML_Parse @16 - _XML_ParseBuffer @17 - _XML_ParserCreate @18 - _XML_ParserCreateNS @19 - _XML_ParserCreate_MM @20 - _XML_ParserFree @21 - _XML_SetAttlistDeclHandler @22 - _XML_SetBase @23 - _XML_SetCdataSectionHandler @24 - _XML_SetCharacterDataHandler @25 - _XML_SetCommentHandler @26 - _XML_SetDefaultHandler @27 - _XML_SetDefaultHandlerExpand @28 - _XML_SetDoctypeDeclHandler @29 - _XML_SetElementDeclHandler @30 - _XML_SetElementHandler @31 - _XML_SetEncoding @32 - _XML_SetEndCdataSectionHandler @33 - _XML_SetEndDoctypeDeclHandler @34 - _XML_SetEndElementHandler @35 - _XML_SetEndNamespaceDeclHandler @36 - _XML_SetEntityDeclHandler @37 - _XML_SetExternalEntityRefHandler @38 - _XML_SetExternalEntityRefHandlerArg @39 - _XML_SetNamespaceDeclHandler @40 - _XML_SetNotStandaloneHandler @41 - _XML_SetNotationDeclHandler @42 - _XML_SetParamEntityParsing @43 - _XML_SetProcessingInstructionHandler @44 - _XML_SetReturnNSTriplet @45 - _XML_SetStartCdataSectionHandler @46 - _XML_SetStartDoctypeDeclHandler @47 - _XML_SetStartElementHandler @48 - _XML_SetStartNamespaceDeclHandler @49 - _XML_SetUnknownEncodingHandler @50 - _XML_SetUnparsedEntityDeclHandler @51 - _XML_SetUserData @52 - _XML_SetXmlDeclHandler @53 - _XML_UseParserAsHandlerArg @54 -; added with version 1.95.3 - _XML_ParserReset @55 - _XML_SetSkippedEntityHandler @56 -; added with version 1.95.5 - _XML_GetFeatureList @57 - _XML_UseForeignDTD @58 -; added with version 1.95.6 - _XML_FreeContentModel @59 - _XML_MemMalloc @60 - _XML_MemRealloc @61 - _XML_MemFree @62 -; added with version 1.95.8 - _XML_StopParser @63 - _XML_ResumeParser @64 - _XML_GetParsingStatus @65 - -; Aliases for MS compatible names - XML_DefaultCurrent = _XML_DefaultCurrent - XML_ErrorString = _XML_ErrorString - XML_ExpatVersion = _XML_ExpatVersion - XML_ExpatVersionInfo = _XML_ExpatVersionInfo - XML_ExternalEntityParserCreate = _XML_ExternalEntityParserCreate - XML_GetBase = _XML_GetBase - XML_GetBuffer = _XML_GetBuffer - XML_GetCurrentByteCount = _XML_GetCurrentByteCount - XML_GetCurrentByteIndex = _XML_GetCurrentByteIndex - XML_GetCurrentColumnNumber = _XML_GetCurrentColumnNumber - XML_GetCurrentLineNumber = _XML_GetCurrentLineNumber - XML_GetErrorCode = _XML_GetErrorCode - XML_GetIdAttributeIndex = _XML_GetIdAttributeIndex - XML_GetInputContext = _XML_GetInputContext - XML_GetSpecifiedAttributeCount = _XML_GetSpecifiedAttributeCount - XML_Parse = _XML_Parse - XML_ParseBuffer = _XML_ParseBuffer - XML_ParserCreate = _XML_ParserCreate - XML_ParserCreateNS = _XML_ParserCreateNS - XML_ParserCreate_MM = _XML_ParserCreate_MM - XML_ParserFree = _XML_ParserFree - XML_SetAttlistDeclHandler = _XML_SetAttlistDeclHandler - XML_SetBase = _XML_SetBase - XML_SetCdataSectionHandler = _XML_SetCdataSectionHandler - XML_SetCharacterDataHandler = _XML_SetCharacterDataHandler - XML_SetCommentHandler = _XML_SetCommentHandler - XML_SetDefaultHandler = _XML_SetDefaultHandler - XML_SetDefaultHandlerExpand = _XML_SetDefaultHandlerExpand - XML_SetDoctypeDeclHandler = _XML_SetDoctypeDeclHandler - XML_SetElementDeclHandler = _XML_SetElementDeclHandler - XML_SetElementHandler = _XML_SetElementHandler - XML_SetEncoding = _XML_SetEncoding - XML_SetEndCdataSectionHandler = _XML_SetEndCdataSectionHandler - XML_SetEndDoctypeDeclHandler = _XML_SetEndDoctypeDeclHandler - XML_SetEndElementHandler = _XML_SetEndElementHandler - XML_SetEndNamespaceDeclHandler = _XML_SetEndNamespaceDeclHandler - XML_SetEntityDeclHandler = _XML_SetEntityDeclHandler - XML_SetExternalEntityRefHandler = _XML_SetExternalEntityRefHandler - XML_SetExternalEntityRefHandlerArg = _XML_SetExternalEntityRefHandlerArg - XML_SetNamespaceDeclHandler = _XML_SetNamespaceDeclHandler - XML_SetNotStandaloneHandler = _XML_SetNotStandaloneHandler - XML_SetNotationDeclHandler = _XML_SetNotationDeclHandler - XML_SetParamEntityParsing = _XML_SetParamEntityParsing - XML_SetProcessingInstructionHandler = _XML_SetProcessingInstructionHandler - XML_SetReturnNSTriplet = _XML_SetReturnNSTriplet - XML_SetStartCdataSectionHandler = _XML_SetStartCdataSectionHandler - XML_SetStartDoctypeDeclHandler = _XML_SetStartDoctypeDeclHandler - XML_SetStartElementHandler = _XML_SetStartElementHandler - XML_SetStartNamespaceDeclHandler = _XML_SetStartNamespaceDeclHandler - XML_SetUnknownEncodingHandler = _XML_SetUnknownEncodingHandler - XML_SetUnparsedEntityDeclHandler = _XML_SetUnparsedEntityDeclHandler - XML_SetUserData = _XML_SetUserData - XML_SetXmlDeclHandler = _XML_SetXmlDeclHandler - XML_UseParserAsHandlerArg = _XML_UseParserAsHandlerArg - XML_ParserReset = _XML_ParserReset - XML_SetSkippedEntityHandler = _XML_SetSkippedEntityHandler - XML_GetFeatureList = _XML_GetFeatureList - XML_UseForeignDTD = _XML_UseForeignDTD - XML_FreeContentModel = _XML_FreeContentModel - XML_MemMalloc = _XML_MemMalloc - XML_MemRealloc = _XML_MemRealloc - XML_MemFree = _XML_MemFree - XML_StopParser = _XML_StopParser - XML_ResumeParser = _XML_ResumeParser - XML_GetParsingStatus = _XML_GetParsingStatus diff --git a/lib-src/expat/bcb5/makefile.mak b/lib-src/expat/bcb5/makefile.mak deleted file mode 100644 index 548815eaf..000000000 --- a/lib-src/expat/bcb5/makefile.mak +++ /dev/null @@ -1,37 +0,0 @@ -all: setup expat expatw expat_static expatw_static elements outline xmlwf - -setup: - setup - -expat: - make -l -fexpat.mak - -expatw: - make -l -fexpatw.mak - -expat_static: - make -l -fexpat_static.mak - -expatw_static: - make -l -fexpatw_static.mak - -elements: - make -l -felements.mak - -outline: - make -l -foutline.mak - -xmlwf: - make -l -fxmlwf.mak - -clean: -# works on Win98/ME -# deltree /y release\obj -# works on WinNT/2000 - del /s/f/q release\obj - -distclean: -# works on Win98/ME -# deltree /y release\*.* -# works on WinNT/2000 - del /s/f/q release\* diff --git a/lib-src/expat/bcb5/outline.bpf b/lib-src/expat/bcb5/outline.bpf deleted file mode 100644 index 52dce8301..000000000 --- a/lib-src/expat/bcb5/outline.bpf +++ /dev/null @@ -1,4 +0,0 @@ -USEUNIT("..\examples\outline.c"); -USELIB("Release\libexpat_mtd.lib"); -//--------------------------------------------------------------------------- -main diff --git a/lib-src/expat/bcb5/outline.bpr b/lib-src/expat/bcb5/outline.bpr deleted file mode 100644 index e0ae5cdee..000000000 --- a/lib-src/expat/bcb5/outline.bpr +++ /dev/null @@ -1,132 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=3 -Item0=..\examples;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=4 -Item0=..\examples;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\examples;$(BCB)\lib;..\examples\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=6 -Item0=WIN32;NDEBUG;_CONSOLE -Item1=WIN32;NDEBUG;_CONSOLE;XML_STATIC -Item2=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_STATIC -Item3=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE;XML_STATIC -Item4=WIN32;NDEBUG;_CONSOLE;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE -Item5=WIN32;NDEBUG;_CONSOLE;_DEBUG - -[HistoryLists\hlIntOutputDir] -Count=4 -Item0=Release\obj\examples -Item1=Release\obj\outline -Item2=..\examples\Release -Item3=Release - -[HistoryLists\hlFinalOutputDir] -Count=1 -Item0=Release\ - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams= -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/outline.mak b/lib-src/expat/bcb5/outline.mak deleted file mode 100644 index 510b541f6..000000000 --- a/lib-src/expat/bcb5/outline.mak +++ /dev/null @@ -1,186 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\outline.exe -OBJFILES = Release\obj\examples\outline.obj -RESFILES = -MAINSOURCE = outline.bpf -RESDEPEN = $(RESFILES) -LIBFILES = Release\libexpat_mtd.lib -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi \ - ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi \ - VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi \ - dclocx50.bpi bcb2kaxserver50.bpi dclusr50.bpi -SPARELIBS = -DEFFILE = -# --------------------------------------------------------------------------- -PATHCPP = .;..\examples -PATHASM = .; -PATHPAS = .; -PATHRC = .; -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = WIN32;NDEBUG;_CONSOLE -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\examples;$(BCB)\include -LIBPATH = ..\examples;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS= -w-par -w-8027 -w-8026 -# --------------------------------------------------------------------------- -CFLAG1 = -O2 -X- -a8 -b -k- -vi -q -tWM -I..\lib -c -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\examples -N0Release\obj\examples -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -IRelease\obj\examples -D"" -ap -Tpe -x -Gn -q -# --------------------------------------------------------------------------- -ALLOBJ = c0x32.obj $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cw32mti.lib -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = ilink32 -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) @&&! - $(LFLAGS) -L$(LIBPATH) + - $(ALLOBJ), + - $(PROJECT),, + - $(ALLLIB), + - $(DEFFILE), + - $(ALLRES) -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/bcb5/setup.bat b/lib-src/expat/bcb5/setup.bat deleted file mode 100644 index 6f4b57317..000000000 --- a/lib-src/expat/bcb5/setup.bat +++ /dev/null @@ -1,9 +0,0 @@ -REM CommandInterpreter: $(COMSPEC) -if not exist .\release\nul mkdir release -if not exist .\release\obj\nul mkdir release\obj -if not exist .\release\obj\libexpat\nul mkdir release\obj\libexpat -if not exist .\release\obj\libexpatw\nul mkdir release\obj\libexpatw -if not exist .\release\obj\libexpat_static\nul mkdir release\obj\libexpat_static -if not exist .\release\obj\libexpatw_static\nul mkdir release\obj\libexpatw_static -if not exist .\release\obj\examples\nul mkdir release\obj\examples -if not exist .\release\obj\xmlwf\nul mkdir release\obj\xmlwf diff --git a/lib-src/expat/bcb5/xmlwf.bpf b/lib-src/expat/bcb5/xmlwf.bpf deleted file mode 100644 index d06208e81..000000000 --- a/lib-src/expat/bcb5/xmlwf.bpf +++ /dev/null @@ -1,7 +0,0 @@ -USEUNIT("..\xmlwf\codepage.c"); -USEUNIT("..\xmlwf\win32filemap.c"); -USEUNIT("..\xmlwf\xmlfile.c"); -USEUNIT("..\xmlwf\xmlwf.c"); -USELIB("Release\libexpat_mtd.lib"); -//--------------------------------------------------------------------------- -main diff --git a/lib-src/expat/bcb5/xmlwf.bpr b/lib-src/expat/bcb5/xmlwf.bpr deleted file mode 100644 index d33a15387..000000000 --- a/lib-src/expat/bcb5/xmlwf.bpr +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 -Locale=1033 -CodePage=1252 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[HistoryLists\hlIncludePath] -Count=4 -Item0=..\xmlwf;$(BCB)\include -Item1=$(BCB)\include -Item2=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl -Item3=$(BCB)\include;$(BCB)\include\mfc;$(BCB)\include\atl; - -[HistoryLists\hlLibraryPath] -Count=5 -Item0=..\xmlwf;$(BCB)\lib;$(RELEASELIBPATH) -Item1=..\xmlwf;$(BCB)\lib;..\xmlwf\$(RELEASELIBPATH) -Item2=$(BCB)\lib;$(RELEASELIBPATH) -Item3=$(BCB)\lib;$(RELEASELIBPATH);$(BCB)\lib\psdk -Item4=$(BCB)\lib;$(RELEASELIBPATH);;$(BCB)\lib\psdk; - -[HistoryLists\hlDebugSourcePath] -Count=1 -Item0=$(BCB)\source\vcl - -[HistoryLists\hlConditionals] -Count=6 -Item0=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP -Item1=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP;_DEBUG;XML_UNICODE_WCHAR_T;_UNICODE -Item2=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP;_DEBUG;XML_UNICODE_WCHAR_T -Item3=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP;_DEBUG -Item4=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP;_DEBUG;_UNICODE;XML_UNICODE_WCHAR_T -Item5=NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP;_DEBUG;_UNICODE - -[HistoryLists\hlIntOutputDir] -Count=3 -Item0=Release\obj\xmlwf -Item1=..\xmlwf\Release -Item2=Release - -[HistoryLists\hlFinalOutputDir] -Count=3 -Item0=Release\ -Item1=Release -Item2=.\Release\ - -[Debugging] -DebugSourceDirs= - -[Parameters] -RunParams=sample.xml -HostApplication= -RemoteHost= -RemotePath= -RemoteDebug=0 - -[Compiler] -ShowInfoMsgs=0 -LinkDebugVcl=0 -LinkCGLIB=0 - -[Language] -ActiveLang= -ProjectLang= -RootDir= - - \ No newline at end of file diff --git a/lib-src/expat/bcb5/xmlwf.mak b/lib-src/expat/bcb5/xmlwf.mak deleted file mode 100644 index f74126e45..000000000 --- a/lib-src/expat/bcb5/xmlwf.mak +++ /dev/null @@ -1,187 +0,0 @@ -# --------------------------------------------------------------------------- -!if !$d(BCB) -BCB = $(MAKEDIR)\.. -!endif - -# --------------------------------------------------------------------------- -# IDE SECTION -# --------------------------------------------------------------------------- -# The following section of the project makefile is managed by the BCB IDE. -# It is recommended to use the IDE to change any of the values in this -# section. -# --------------------------------------------------------------------------- - -VERSION = BCB.05.03 -# --------------------------------------------------------------------------- -PROJECT = Release\xmlwf.exe -OBJFILES = Release\obj\xmlwf\codepage.obj Release\obj\xmlwf\win32filemap.obj \ - Release\obj\xmlwf\xmlfile.obj Release\obj\xmlwf\xmlwf.obj -RESFILES = -MAINSOURCE = xmlwf.bpf -RESDEPEN = $(RESFILES) -LIBFILES = Release\libexpat_mtd.lib -IDLFILES = -IDLGENFILES = -LIBRARIES = -PACKAGES = VCL50.bpi VCLX50.bpi bcbsmp50.bpi QRPT50.bpi VCLDB50.bpi VCLBDE50.bpi \ - ibsmp50.bpi VCLDBX50.bpi TEEUI50.bpi TEEDB50.bpi TEE50.bpi TEEQR50.bpi \ - VCLIB50.bpi bcbie50.bpi VCLIE50.bpi INETDB50.bpi INET50.bpi NMFAST50.bpi \ - dclocx50.bpi bcb2kaxserver50.bpi dclusr50.bpi -SPARELIBS = -DEFFILE = -# --------------------------------------------------------------------------- -PATHCPP = .;..\xmlwf -PATHASM = .; -PATHPAS = .; -PATHRC = .; -DEBUGLIBPATH = $(BCB)\lib\debug -RELEASELIBPATH = $(BCB)\lib\release -USERDEFINES = NDEBUG;WIN32;_CONSOLE;COMPILED_FROM_DSP -SYSDEFINES = _NO_VCL;_ASSERTE;NO_STRICT;_RTLDLL -INCLUDEPATH = ..\xmlwf;$(BCB)\include -LIBPATH = ..\xmlwf;$(BCB)\lib;$(RELEASELIBPATH) -WARNINGS= -w-8065 -w-par -w-8027 -w-8026 -# --------------------------------------------------------------------------- -CFLAG1 = -O2 -X- -a8 -b -k- -vi -q -tWM -I..\lib -c -IDLCFLAGS = -I$(BCB)\include -PFLAGS = -N2Release\obj\xmlwf -N0Release\obj\xmlwf -$Y- -$L- -$D- -RFLAGS = /l 0x409 /d "NDEBUG" /i$(BCB)\include -AFLAGS = /mx /w2 /zn -LFLAGS = -IRelease\obj\xmlwf -D"" -ap -Tpe -x -Gn -q -# --------------------------------------------------------------------------- -ALLOBJ = c0x32.obj $(OBJFILES) -ALLRES = $(RESFILES) -ALLLIB = $(LIBFILES) $(LIBRARIES) import32.lib cw32mti.lib -# --------------------------------------------------------------------------- -!ifdef IDEOPTIONS - -[Version Info] -IncludeVerInfo=0 -AutoIncBuild=0 -MajorVer=1 -MinorVer=0 -Release=0 -Build=0 -Debug=0 -PreRelease=0 -Special=0 -Private=0 -DLL=0 - -[Version Info Keys] -CompanyName= -FileDescription= -FileVersion=1.0.0.0 -InternalName= -LegalCopyright= -LegalTrademarks= -OriginalFilename= -ProductName= -ProductVersion=1.0.0.0 -Comments= - -[Debugging] -DebugSourceDirs=$(BCB)\source\vcl - -!endif - - - - - -# --------------------------------------------------------------------------- -# MAKE SECTION -# --------------------------------------------------------------------------- -# This section of the project file is not used by the BCB IDE. It is for -# the benefit of building from the command-line using the MAKE utility. -# --------------------------------------------------------------------------- - -.autodepend -# --------------------------------------------------------------------------- -!if "$(USERDEFINES)" != "" -AUSERDEFINES = -d$(USERDEFINES:;= -d) -!else -AUSERDEFINES = -!endif - -!if !$d(BCC32) -BCC32 = bcc32 -!endif - -!if !$d(CPP32) -CPP32 = cpp32 -!endif - -!if !$d(DCC32) -DCC32 = dcc32 -!endif - -!if !$d(TASM32) -TASM32 = tasm32 -!endif - -!if !$d(LINKER) -LINKER = ilink32 -!endif - -!if !$d(BRCC32) -BRCC32 = brcc32 -!endif - - -# --------------------------------------------------------------------------- -!if $d(PATHCPP) -.PATH.CPP = $(PATHCPP) -.PATH.C = $(PATHCPP) -!endif - -!if $d(PATHPAS) -.PATH.PAS = $(PATHPAS) -!endif - -!if $d(PATHASM) -.PATH.ASM = $(PATHASM) -!endif - -!if $d(PATHRC) -.PATH.RC = $(PATHRC) -!endif -# --------------------------------------------------------------------------- -$(PROJECT): $(IDLGENFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE) - $(BCB)\BIN\$(LINKER) @&&! - $(LFLAGS) -L$(LIBPATH) + - $(ALLOBJ), + - $(PROJECT),, + - $(ALLLIB), + - $(DEFFILE), + - $(ALLRES) -! -# --------------------------------------------------------------------------- -.pas.hpp: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.pas.obj: - $(BCB)\BIN\$(DCC32) $(PFLAGS) -U$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -O$(INCLUDEPATH) --BCB {$< } - -.cpp.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.obj: - $(BCB)\BIN\$(BCC32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n$(@D) {$< } - -.c.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.cpp.i: - $(BCB)\BIN\$(CPP32) $(CFLAG1) $(WARNINGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -n. {$< } - -.asm.obj: - $(BCB)\BIN\$(TASM32) $(AFLAGS) -i$(INCLUDEPATH:;= -i) $(AUSERDEFINES) -d$(SYSDEFINES:;= -d) $<, $@ - -.rc.res: - $(BCB)\BIN\$(BRCC32) $(RFLAGS) -I$(INCLUDEPATH) -D$(USERDEFINES);$(SYSDEFINES) -fo$@ $< -# --------------------------------------------------------------------------- - - - - diff --git a/lib-src/expat/configure b/lib-src/expat/configure deleted file mode 100755 index d9529b79e..000000000 --- a/lib-src/expat/configure +++ /dev/null @@ -1,18668 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for expat 2.1.0. -# -# Report bugs to . -# -# -# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# Use a proper internal environment variable to ensure we don't fall - # into an infinite loop, continuously re-executing ourselves. - if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then - _as_can_reexec=no; export _as_can_reexec; - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -as_fn_exit 255 - fi - # We don't want this to propagate to other subprocesses. - { _as_can_reexec=; unset _as_can_reexec;} -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : - -else - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1 -test -x / || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 - - test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ - || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" - if (eval "$as_required") 2>/dev/null; then : - as_have_required=yes -else - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : - -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : - CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : - break 2 -fi -fi - done;; - esac - as_found=false -done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } -IFS=$as_save_IFS - - - if test "x$CONFIG_SHELL" != x; then : - export CONFIG_SHELL - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 -fi - - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." - else - $as_echo "$0: Please tell bug-autoconf@gnu.org and -$0: expat-bugs@libexpat.org about your system, including -$0: any error possibly output before this message. Then -$0: install a modern shell, or manually run the script -$0: under such a shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # If we had to re-execute with $CONFIG_SHELL, we're ensured to have - # already done that, so ensure we don't try to do so again and fall - # in an infinite loop. This has already happened in practice. - _as_can_reexec=no; export _as_can_reexec - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - -SHELL=${CONFIG_SHELL-/bin/sh} - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME='expat' -PACKAGE_TARNAME='expat' -PACKAGE_VERSION='2.1.0' -PACKAGE_STRING='expat 2.1.0' -PACKAGE_BUGREPORT='expat-bugs@libexpat.org' -PACKAGE_URL='' - -ac_unique_file="Makefile.in" -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef STDC_HEADERS -# include -# include -#else -# ifdef HAVE_STDLIB_H -# include -# endif -#endif -#ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include -# endif -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_header_list= -ac_subst_vars='LTLIBOBJS -LIBOBJS -FILEMAP -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -CXXCPP -ac_ct_CXX -CXXFLAGS -CXX -LIBAGE -LIBREVISION -LIBCURRENT -CPP -OTOOL64 -OTOOL -LIPO -NMEDIT -DSYMUTIL -MANIFEST_TOOL -AWK -RANLIB -STRIP -ac_ct_AR -AR -LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP -EGREP -GREP -SED -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -LIBTOOL -OBJDUMP -DLLTOOL -AS -host_os -host_vendor -host_cpu -host -build_os -build_vendor -build_cpu -build -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_shared -enable_static -with_pic -enable_fast_install -with_gnu_ld -with_sysroot -enable_libtool_lock -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -CPP -CXX -CXXFLAGS -CCC -CXXCPP' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *=) ac_optarg= ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error $? "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information" - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error $? "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error $? "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error $? "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures expat 2.1.0 to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking ...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/expat] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -System types: - --build=BUILD configure for building on BUILD [guessed] - --host=HOST cross-compile to build programs to run on HOST [BUILD] -_ACEOF -fi - -if test -n "$ac_init_help"; then - case $ac_init_help in - short | recursive ) echo "Configuration of expat 2.1.0:";; - esac - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-shared[=PKGS] build shared libraries [default=yes] - --enable-static[=PKGS] build static libraries [default=yes] - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) - -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use - both] - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-sysroot=DIR Search for dependent libraries within DIR - (or the compiler's sysroot if not specified). - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - CPP C preprocessor - CXX C++ compiler command - CXXFLAGS C++ compiler flags - CXXCPP C++ preprocessor - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to . -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -expat configure 2.1.0 -generated by GNU Autoconf 2.69 - -Copyright (C) 2012 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link - -# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists and can be compiled using the include files in -# INCLUDES, setting the cache variable VAR accordingly. -ac_fn_c_check_header_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_compile - -# ac_fn_c_try_cpp LINENO -# ---------------------- -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_cpp - -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : - ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_run - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_func - -# ac_fn_cxx_try_compile LINENO -# ---------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_cxx_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_compile - -# ac_fn_cxx_try_cpp LINENO -# ------------------------ -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || - test ! -s conftest.err - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_cpp - -# ac_fn_cxx_try_link LINENO -# ------------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_cxx_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_link - -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_type - -# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists, giving a warning if it cannot be compiled using -# the include files in INCLUDES and setting the cache variable VAR -# accordingly. -ac_fn_c_check_header_mongrel () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval \${$3+:} false; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 -$as_echo_n "checking $2 usability... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_header_compiler=yes -else - ac_header_compiler=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } - -# Is the header present? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 -$as_echo_n "checking $2 presence... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <$2> -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - ac_header_preproc=yes -else - ac_header_preproc=no -fi -rm -f conftest.err conftest.i conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( - yes:no: ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} - ;; - no:yes:* ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} -( $as_echo "## -------------------------------------- ## -## Report this to expat-bugs@libexpat.org ## -## -------------------------------------- ##" - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=\$ac_header_compiler" -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_mongrel -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by expat $as_me 2.1.0, which was -generated by GNU Autoconf 2.69. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - $as_echo "## ---------------- ## -## Cache variables. ## -## ---------------- ##" - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - $as_echo "## ----------------- ## -## Output variables. ## -## ----------------- ##" - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - $as_echo "## ------------------- ## -## File substitutions. ## -## ------------------- ##" - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - $as_echo "## ----------- ## -## confdefs.h. ## -## ----------- ##" - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -$as_echo "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE -if test -n "$CONFIG_SITE"; then - # We do not want a PATH search for config.site. - case $CONFIG_SITE in #(( - -*) ac_site_file1=./$CONFIG_SITE;; - */*) ac_site_file1=$CONFIG_SITE;; - *) ac_site_file1=./$CONFIG_SITE;; - esac -elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site -else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site -fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" -do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" \ - || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5; } - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -as_fn_append ac_header_list " stdlib.h" -as_fn_append ac_header_list " unistd.h" -as_fn_append ac_header_list " sys/param.h" -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - - - -ac_aux_dir= -for ac_dir in conftools "$srcdir"/conftools; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - as_fn_error $? "cannot find install-sh, install.sh, or shtool in conftools \"$srcdir\"/conftools" "$LINENO" 5 -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - - - - - -LIBCURRENT=7 -LIBREVISION=0 -LIBAGE=6 - -ac_config_headers="$ac_config_headers expat_config.h" - - - - - -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -$as_echo_n "checking build system type... " >&6; } -if ${ac_cv_build+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 -$as_echo_n "checking host system type... " >&6; } -if ${ac_cv_host+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -$as_echo "$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - -enable_win32_dll=yes - -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. -set dummy ${ac_tool_prefix}as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AS"; then - ac_cv_prog_AS="$AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AS="${ac_tool_prefix}as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AS=$ac_cv_prog_AS -if test -n "$AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 -$as_echo "$AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_AS"; then - ac_ct_AS=$AS - # Extract the first word of "as", so it can be a program name with args. -set dummy as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AS"; then - ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AS="as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AS=$ac_cv_prog_ac_ct_AS -if test -n "$ac_ct_AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 -$as_echo "$ac_ct_AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_AS" = x; then - AS="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AS=$ac_ct_AS - fi -else - AS="$ac_cv_prog_AS" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - - ;; -esac - -test -z "$AS" && AS=as - - - - - -test -z "$DLLTOOL" && DLLTOOL=dlltool - - - - - -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - - -case `pwd` in - *\ * | *\ *) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; -esac - - - -macro_version='2.4.2' -macro_revision='1.3337' - - - - - - - - - - - - - -ltmain="$ac_aux_dir/ltmain.sh" - -# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\(["`$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 -$as_echo_n "checking how to print strings... " >&6; } -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "" -} - -case "$ECHO" in - printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 -$as_echo "printf" >&6; } ;; - print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 -$as_echo "print -r" >&6; } ;; - *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 -$as_echo "cat" >&6; } ;; -esac - - - - - - - - - - - - - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if ${ac_cv_objext+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if ${ac_cv_c_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if ${ac_cv_path_SED+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for ac_i in 1 2 3 4 5 6 7; do - ac_script="$ac_script$as_nl$ac_script" - done - echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed - { ac_script=; unset ac_script;} - if test -z "$SED"; then - ac_path_SED_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_SED" || continue -# Check for GNU ac_path_SED and select it if it is found. - # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in -*GNU*) - ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo '' >> "conftest.nl" - "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_SED="$ac_path_SED" - ac_path_SED_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_SED_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_SED"; then - as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 - fi -else - ac_cv_path_SED=$SED -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -$as_echo "$ac_cv_path_SED" >&6; } - SED="$ac_cv_path_SED" - rm -f conftest.sed - -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if ${ac_cv_path_GREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$GREP"; then - ac_path_GREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_GREP" || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_GREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_GREP=$GREP -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if ${ac_cv_path_EGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_EGREP=$EGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 -$as_echo_n "checking for fgrep... " >&6; } -if ${ac_cv_path_FGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in fgrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_FGREP" || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in -*GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_FGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_FGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_FGREP=$FGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 -$as_echo "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - - - - - -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if ${lt_cv_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$LD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if ${lt_cv_prog_gnu_ld+:} false; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 -$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if ${lt_cv_path_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - if test -n "$ac_tool_prefix"; then - for ac_prog in dumpbin "link -dump" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DUMPBIN=$ac_cv_prog_DUMPBIN -if test -n "$DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 -$as_echo "$DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$DUMPBIN" && break - done -fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in dumpbin "link -dump" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DUMPBIN"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN -if test -n "$ac_ct_DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 -$as_echo "$ac_ct_DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_DUMPBIN" && break -done - - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DUMPBIN=$ac_ct_DUMPBIN - fi -fi - - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols" - ;; - *) - DUMPBIN=: - ;; - esac - fi - - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 -$as_echo_n "checking the name lister ($NM) interface... " >&6; } -if ${lt_cv_nm_interface+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 -$as_echo "$lt_cv_nm_interface" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } -fi - -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if ${lt_cv_sys_max_cmd_len+:} false; then : - $as_echo_n "(cached) " >&6 -else - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac - -fi - -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } -fi -max_cmd_len=$lt_cv_sys_max_cmd_len - - - - - - -: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 -$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 -$as_echo "$xsi_shell" >&6; } - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 -$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } -lt_shell_append=no -( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 -$as_echo "$lt_shell_append" >&6; } - - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi - - - - - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 -$as_echo_n "checking how to convert $build file names to $host format... " >&6; } -if ${lt_cv_to_host_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac - -fi - -to_host_file_cmd=$lt_cv_to_host_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 -$as_echo "$lt_cv_to_host_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 -$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } -if ${lt_cv_to_tool_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - #assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac - -fi - -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 -$as_echo "$lt_cv_to_tool_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if ${lt_cv_ld_reload_flag+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_reload_flag='-r' -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - if test "$GCC" != yes; then - reload_cmds=false - fi - ;; - darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 -$as_echo_n "checking how to recognize dependent libraries... " >&6; } -if ${lt_cv_deplibs_check_method+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[4-9]*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. - if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - 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]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[3-9]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - 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]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - - - - - - - - - - - - - - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" -fi - -test -z "$DLLTOOL" && DLLTOOL=dlltool - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 -$as_echo_n "checking how to associate runtime and link libraries... " >&6; } -if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 -$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - - - - - - - - -if test -n "$ac_tool_prefix"; then - for ac_prog in ar - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AR" && break - done -fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AR="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_AR" && break -done - - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -fi - -: ${AR=ar} -: ${AR_FLAGS=cru} - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 -$as_echo_n "checking for archiver @FILE support... " >&6; } -if ${lt_cv_ar_at_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ar_at_file=no - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -eq 0; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -ne 0; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 -$as_echo "$lt_cv_ar_at_file" >&6; } - -if test "x$lt_cv_ar_at_file" = xno; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -test -z "$STRIP" && STRIP=: - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - -test -z "$RANLIB" && RANLIB=: - - - - - - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac - - - - - - - - - - - - - - - - - - - - - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AWK+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AWK" && break -done - - - - - - - - - - - - - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if ${lt_cv_sys_global_symbol_pipe+:} false; then : - $as_echo_n "(cached) " >&6 -else - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[ABCDGISTW]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris*) - symcode='[BDRT]' - ;; -sco3.2v5*) - symcode='[DT]' - ;; -sysv4.2uw2*) - symcode='[DT]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[ABDT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" -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'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK '"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done - -fi - -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 -$as_echo_n "checking for sysroot... " >&6; } - -# Check whether --with-sysroot was given. -if test "${with_sysroot+set}" = set; then : - withval=$with_sysroot; -else - with_sysroot=no -fi - - -lt_sysroot= -case ${with_sysroot} in #( - yes) - if test "$GCC" = yes; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 -$as_echo "${with_sysroot}" >&6; } - as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 - ;; -esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 -$as_echo "${lt_sysroot:-no}" >&6; } - - - - - -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi - -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line '$LINENO' "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if ${lt_cv_cc_needs_belf+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. -set dummy ${ac_tool_prefix}mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$MANIFEST_TOOL"; then - ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL -if test -n "$MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 -$as_echo "$MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_MANIFEST_TOOL"; then - ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL - # Extract the first word of "mt", so it can be a program name with args. -set dummy mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_MANIFEST_TOOL"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL -if test -n "$ac_ct_MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 -$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_MANIFEST_TOOL" = x; then - MANIFEST_TOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL - fi -else - MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" -fi - -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 -$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } -if ${lt_cv_path_mainfest_tool+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&5 - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 -$as_echo "$lt_cv_path_mainfest_tool" >&6; } -if test "x$lt_cv_path_mainfest_tool" != xyes; then - MANIFEST_TOOL=: -fi - - - - - - - case $host_os in - rhapsody* | darwin*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. -set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DSYMUTIL=$ac_cv_prog_DSYMUTIL -if test -n "$DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 -$as_echo "$DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DSYMUTIL"; then - ac_ct_DSYMUTIL=$DSYMUTIL - # Extract the first word of "dsymutil", so it can be a program name with args. -set dummy dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL -if test -n "$ac_ct_DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 -$as_echo "$ac_ct_DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DSYMUTIL=$ac_ct_DSYMUTIL - fi -else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. -set dummy ${ac_tool_prefix}nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -NMEDIT=$ac_cv_prog_NMEDIT -if test -n "$NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 -$as_echo "$NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NMEDIT"; then - ac_ct_NMEDIT=$NMEDIT - # Extract the first word of "nmedit", so it can be a program name with args. -set dummy nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_NMEDIT"; then - ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_NMEDIT="nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT -if test -n "$ac_ct_NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 -$as_echo "$ac_ct_NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_NMEDIT" = x; then - NMEDIT=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - NMEDIT=$ac_ct_NMEDIT - fi -else - NMEDIT="$ac_cv_prog_NMEDIT" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. -set dummy ${ac_tool_prefix}lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$LIPO"; then - ac_cv_prog_LIPO="$LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_LIPO="${ac_tool_prefix}lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LIPO=$ac_cv_prog_LIPO -if test -n "$LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 -$as_echo "$LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_LIPO"; then - ac_ct_LIPO=$LIPO - # Extract the first word of "lipo", so it can be a program name with args. -set dummy lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_LIPO"; then - ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_LIPO="lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO -if test -n "$ac_ct_LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 -$as_echo "$ac_ct_LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_LIPO" = x; then - LIPO=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - LIPO=$ac_ct_LIPO - fi -else - LIPO="$ac_cv_prog_LIPO" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL"; then - ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL="${ac_tool_prefix}otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL=$ac_cv_prog_OTOOL -if test -n "$OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 -$as_echo "$OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL"; then - ac_ct_OTOOL=$OTOOL - # Extract the first word of "otool", so it can be a program name with args. -set dummy otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL"; then - ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL="otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL -if test -n "$ac_ct_OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 -$as_echo "$ac_ct_OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL" = x; then - OTOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL=$ac_ct_OTOOL - fi -else - OTOOL="$ac_cv_prog_OTOOL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL64"; then - ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL64=$ac_cv_prog_OTOOL64 -if test -n "$OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 -$as_echo "$OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL64"; then - ac_ct_OTOOL64=$OTOOL64 - # Extract the first word of "otool64", so it can be a program name with args. -set dummy otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL64"; then - ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL64="otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 -if test -n "$ac_ct_OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 -$as_echo "$ac_ct_OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL64" = x; then - OTOOL64=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL64=$ac_ct_OTOOL64 - fi -else - OTOOL64="$ac_cv_prog_OTOOL64" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 -$as_echo_n "checking for -single_module linker flag... " >&6; } -if ${lt_cv_apple_cc_single_mod+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&5 - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&5 - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 -$as_echo "$lt_cv_apple_cc_single_mod" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 -$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } -if ${lt_cv_ld_exported_symbols_list+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_ld_exported_symbols_list=yes -else - lt_cv_ld_exported_symbols_list=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 -$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 -$as_echo_n "checking for -force_load linker flag... " >&6; } -if ${lt_cv_ld_force_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 - echo "$AR cru libconftest.a conftest.o" >&5 - $AR cru libconftest.a conftest.o 2>&5 - echo "$RANLIB libconftest.a" >&5 - $RANLIB libconftest.a 2>&5 - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&5 - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&5 - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 -$as_echo "$lt_cv_ld_force_load" >&6; } - case $host_os in - rhapsody* | darwin1.[012]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[91]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[012]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if ${ac_cv_prog_CPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default -" -if test "x$ac_cv_header_dlfcn_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF - -fi - -done - - - - - -# Set options - - - - enable_dlopen=no - - - - # Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_shared=yes -fi - - - - - - - - - - # Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_static=yes -fi - - - - - - - - - - -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for lt_pkg in $withval; do - IFS="$lt_save_ifs" - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - pic_mode=default -fi - - -test -z "$pic_mode" && pic_mode=default - - - - - - - - # Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_fast_install=yes -fi - - - - - - - - - - - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -test -z "$LN_S" && LN_S="ln -s" - - - - - - - - - - - - - - -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if ${lt_cv_objdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - - - - -cat >>confdefs.h <<_ACEOF -#define LT_OBJDIR "$lt_cv_objdir/" -_ACEOF - - - - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` - - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - - - -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - else - MAGIC_CMD=: - fi -fi - - fi - ;; -esac - -# Use C for the default configuration in the libtool script - -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -objext=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - case $cc_basename in - nvcc*) - lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; - *) - lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; - esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi - -fi - - - - - - - lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= - - - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; - - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; - - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - lt_prog_compiler_wl='-Xlinker ' - if test -n "$lt_prog_compiler_pic"; then - lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='--shared' - lt_prog_compiler_static='--static' - ;; - nagfor*) - # NAG Fortran compiler - lt_prog_compiler_wl='-Wl,-Wl,,' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-qpic' - lt_prog_compiler_static='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' - ;; - *Sun\ F* | *Sun*Fortran*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Wl,' - ;; - *Intel*\ [CF]*Compiler*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - *Portland\ Group*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - - rdos*) - lt_prog_compiler_static='-non_shared' - ;; - - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; - - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; - - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; - - *) - lt_prog_compiler_can_build_shared=no - ;; - esac - fi - -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -if ${lt_cv_prog_compiler_pic+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic=$lt_prog_compiler_pic -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 -$as_echo "$lt_cv_prog_compiler_pic" >&6; } -lt_prog_compiler_pic=$lt_cv_prog_compiler_pic - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if ${lt_cv_prog_compiler_pic_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } - -if test x"$lt_cv_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac -else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no -fi - -fi - - - - - - - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if ${lt_cv_prog_compiler_static_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works=yes - fi - else - lt_cv_prog_compiler_static_works=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 -$as_echo "$lt_cv_prog_compiler_static_works" >&6; } - -if test x"$lt_cv_prog_compiler_static_works" = xyes; then - : -else - lt_prog_compiler_static= -fi - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag= - always_export_symbols=no - archive_cmds= - archive_expsym_cmds= - compiler_needs_object=no - enable_shared_with_static_runtimes=no - export_dynamic_flag_spec= - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - hardcode_automatic=no - hardcode_direct=no - hardcode_direct_absolute=no - hardcode_libdir_flag_spec= - hardcode_libdir_separator= - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - inherit_rpath=no - link_all_deplibs=unknown - module_cmds= - module_expsym_cmds= - old_archive_from_new_cmds= - old_archive_from_expsyms_cmds= - thread_safe_flag_spec= - whole_archive_flag_spec= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - linux* | k*bsd*-gnu | gnu*) - link_all_deplibs=no - ;; - esac - - ld_shlibs=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; - *\ \(GNU\ Binutils\)\ [3-9]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test "$lt_use_gnu_ld_interface" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[3-9]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - export_dynamic_flag_spec='${wl}--export-all-symbols' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - 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' - exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs=no - fi - ;; - - haiku*) - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - link_all_deplibs=yes - ;; - - interix[3-9]*) - hardcode_direct=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - 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' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - 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' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - 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' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - whole_archive_flag_spec= - tmp_sharedflag='--shared' ;; - xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - 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' - compiler_needs_object=yes - ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - 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' - compiler_needs_object=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - ld_shlibs=no - fi - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - 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' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - - aix[4-9]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - 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' - else - 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' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds='' - hardcode_direct=yes - hardcode_direct_absolute=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - file_list_spec='${wl}-f,' - - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - link_all_deplibs=no - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - export_dynamic_flag_spec='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - 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" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - 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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec='$convenience' - fi - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - 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' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl*) - # Native MSVC - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - always_export_symbols=yes - file_list_spec='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, )='true' - enable_shared_with_static_runtimes=yes - exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' - # Don't use ranlib - old_postinstall_cmds='chmod 644 $oldlib' - postlink_cmds='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC wrapper - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' - enable_shared_with_static_runtimes=yes - ;; - esac - ;; - - darwin* | rhapsody*) - - - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - 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\"`' - - else - whole_archive_flag_spec='' - fi - link_all_deplibs=yes - allow_undefined_flag="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - 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}" - 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}" - - else - ld_shlibs=no - fi - - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9*) - if test "$GCC" = yes; then - 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' - else - 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' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 -$as_echo_n "checking if $CC understands -b... " >&6; } -if ${lt_cv_prog_compiler__b+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler__b=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -b" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler__b=yes - fi - else - lt_cv_prog_compiler__b=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 -$as_echo "$lt_cv_prog_compiler__b" >&6; } - -if test x"$lt_cv_prog_compiler__b" = xyes; then - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' -else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' -fi - - ;; - esac - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - *) - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - 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' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 -$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } -if ${lt_cv_irix_exported_symbol+:} false; then : - $as_echo_n "(cached) " >&6 -else - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int foo (void) { return 0; } -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_irix_exported_symbol=yes -else - lt_cv_irix_exported_symbol=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 -$as_echo "$lt_cv_irix_exported_symbol" >&6; } - if test "$lt_cv_irix_exported_symbol" = yes; then - 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' - fi - else - 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' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - inherit_rpath=yes - link_all_deplibs=yes - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - - *nto* | *qnx*) - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - hardcode_direct=yes - hardcode_shlibpath_var=no - hardcode_direct_absolute=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - else - ld_shlibs=no - fi - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - 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' - old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - 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~ - $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' - - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - archive_cmds_need_lc='no' - hardcode_libdir_separator=: - ;; - - solaris*) - no_undefined_flag=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' - fi - ;; - esac - link_all_deplibs=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag='${wl}-z,text' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag='${wl}-z,text' - allow_undefined_flag='${wl}-z,nodefs' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-R,$libdir' - hardcode_libdir_separator=':' - link_all_deplibs=yes - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - *) - ld_shlibs=no - ;; - esac - - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - export_dynamic_flag_spec='${wl}-Blargedynsym' - ;; - esac - fi - fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no - -with_gnu_ld=$with_gnu_ld - - - - - - - - - - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } -if ${lt_cv_archive_cmds_need_lc+:} false; then : - $as_echo_n "(cached) " >&6 -else - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - pic_flag=$lt_prog_compiler_pic - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc=no - else - lt_cv_archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 -$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } - archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } - -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[lt_foo]++; } - if (lt_freq[lt_foo] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([A-Za-z]:\),\1,g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if ${lt_cv_shlibpath_overrides_runpath+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || - test -n "$runpath_var" || - test "X$hardcode_automatic" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } - -if test "$hardcode_action" = relink || - test "$inherit_rpath" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - -fi - - ;; - - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if ${ac_cv_lib_dld_shl_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes -else - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if ${ac_cv_lib_svld_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes -else - ac_cv_lib_svld_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if ${ac_cv_lib_dld_dld_link+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); -int -main () -{ -return dld_link (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes -else - ac_cv_lib_dld_dld_link=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = xyes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" -fi - - -fi - - -fi - - -fi - - -fi - - -fi - - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self_static+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi - - - - - - - - - - - - - - - - - -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac -fi - - - - - - - - - - - - - # Report which library types will actually be built - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[4-9]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } - - - - -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" - - - - - - - - - - - - - - - - ac_config_commands="$ac_config_commands libtool" - - - - -# Only expand once: - - - - - - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if ${ac_cv_c_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -if test -z "$CXX"; then - if test -n "$CCC"; then - CXX=$CCC - else - if test -n "$ac_tool_prefix"; then - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CXX"; then - ac_cv_prog_CXX="$CXX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CXX=$ac_cv_prog_CXX -if test -n "$CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 -$as_echo "$CXX" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CXX" && break - done -fi -if test -z "$CXX"; then - ac_ct_CXX=$CXX - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CXX"; then - ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CXX="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CXX=$ac_cv_prog_ac_ct_CXX -if test -n "$ac_ct_CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 -$as_echo "$ac_ct_CXX" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CXX" && break -done - - if test "x$ac_ct_CXX" = x; then - CXX="g++" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CXX=$ac_ct_CXX - fi -fi - - fi -fi -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 -$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } -if ${ac_cv_cxx_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_cxx_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 -$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GXX=yes -else - GXX= -fi -ac_test_CXXFLAGS=${CXXFLAGS+set} -ac_save_CXXFLAGS=$CXXFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 -$as_echo_n "checking whether $CXX accepts -g... " >&6; } -if ${ac_cv_prog_cxx_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_cxx_werror_flag=$ac_cxx_werror_flag - ac_cxx_werror_flag=yes - ac_cv_prog_cxx_g=no - CXXFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - ac_cv_prog_cxx_g=yes -else - CXXFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - -else - ac_cxx_werror_flag=$ac_save_cxx_werror_flag - CXXFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - ac_cv_prog_cxx_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_cxx_werror_flag=$ac_save_cxx_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 -$as_echo "$ac_cv_prog_cxx_g" >&6; } -if test "$ac_test_CXXFLAGS" = set; then - CXXFLAGS=$ac_save_CXXFLAGS -elif test $ac_cv_prog_cxx_g = yes; then - if test "$GXX" = yes; then - CXXFLAGS="-g -O2" - else - CXXFLAGS="-g" - fi -else - if test "$GXX" = yes; then - CXXFLAGS="-O2" - else - CXXFLAGS= - fi -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - -func_stripname_cnf () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname_cnf - - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 -$as_echo_n "checking how to run the C++ preprocessor... " >&6; } -if test -z "$CXXCPP"; then - if ${ac_cv_prog_CXXCPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CXXCPP needs to be expanded - for CXXCPP in "$CXX -E" "/lib/cpp" - do - ac_preproc_ok=false -for ac_cxx_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CXXCPP=$CXXCPP - -fi - CXXCPP=$ac_cv_prog_CXXCPP -else - ac_cv_prog_CXXCPP=$CXXCPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 -$as_echo "$CXXCPP" >&6; } -ac_preproc_ok=false -for ac_cxx_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -else - _lt_caught_CXX_error=yes -fi - -ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu - -archive_cmds_need_lc_CXX=no -allow_undefined_flag_CXX= -always_export_symbols_CXX=no -archive_expsym_cmds_CXX= -compiler_needs_object_CXX=no -export_dynamic_flag_spec_CXX= -hardcode_direct_CXX=no -hardcode_direct_absolute_CXX=no -hardcode_libdir_flag_spec_CXX= -hardcode_libdir_separator_CXX= -hardcode_minus_L_CXX=no -hardcode_shlibpath_var_CXX=unsupported -hardcode_automatic_CXX=no -inherit_rpath_CXX=no -module_cmds_CXX= -module_expsym_cmds_CXX= -link_all_deplibs_CXX=unknown -old_archive_cmds_CXX=$old_archive_cmds -reload_flag_CXX=$reload_flag -reload_cmds_CXX=$reload_cmds -no_undefined_flag_CXX= -whole_archive_flag_spec_CXX= -enable_shared_with_static_runtimes_CXX=no - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -objext_CXX=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - - # save warnings/boilerplate of simple test code - ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - - ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_CFLAGS=$CFLAGS - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - CFLAGS=$CXXFLAGS - compiler=$CC - compiler_CXX=$CC - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` - - - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test "$GXX" = yes; then - lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' - else - lt_prog_compiler_no_builtin_flag_CXX= - fi - - if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - - -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if ${lt_cv_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$LD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if ${lt_cv_prog_gnu_ld+:} false; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - 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' - - hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec_CXX= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - ld_shlibs_CXX=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aix[4-9]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds_CXX='' - hardcode_direct_CXX=yes - hardcode_direct_absolute_CXX=yes - hardcode_libdir_separator_CXX=':' - link_all_deplibs_CXX=yes - file_list_spec_CXX='${wl}-f,' - - if test "$GXX" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct_CXX=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L_CXX=yes - hardcode_libdir_flag_spec_CXX='-L$libdir' - hardcode_libdir_separator_CXX= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - export_dynamic_flag_spec_CXX='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - always_export_symbols_CXX=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag_CXX='-berok' - # Determine the default libpath from the value encoded in an empty - # executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath__CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath__CXX -fi - - hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" - - 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" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag_CXX="-z nodefs" - 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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath__CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath__CXX -fi - - hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag_CXX=' ${wl}-bernotok' - allow_undefined_flag_CXX=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec_CXX='$convenience' - fi - archive_cmds_need_lc_CXX=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - 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' - fi - fi - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag_CXX=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs_CXX=no - fi - ;; - - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - case $GXX,$cc_basename in - ,cl* | no,cl*) - # Native MSVC - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec_CXX=' ' - allow_undefined_flag_CXX=unsupported - always_export_symbols_CXX=yes - file_list_spec_CXX='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' - enable_shared_with_static_runtimes_CXX=yes - # Don't use ranlib - old_postinstall_cmds_CXX='chmod 644 $oldlib' - postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # g++ - # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec_CXX='-L$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' - allow_undefined_flag_CXX=unsupported - always_export_symbols_CXX=no - enable_shared_with_static_runtimes_CXX=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - 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' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $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' - else - ld_shlibs_CXX=no - fi - ;; - esac - ;; - darwin* | rhapsody*) - - - archive_cmds_need_lc_CXX=no - hardcode_direct_CXX=no - hardcode_automatic_CXX=yes - hardcode_shlibpath_var_CXX=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - 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\"`' - - else - whole_archive_flag_spec_CXX='' - fi - link_all_deplibs_CXX=yes - allow_undefined_flag_CXX="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - 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}" - module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - 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}" - 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}" - if test "$lt_cv_apple_cc_single_mod" != "yes"; then - 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}" - 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}" - fi - - else - ld_shlibs_CXX=no - fi - - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - freebsd2.*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - ld_shlibs_CXX=no - ;; - - freebsd-elf*) - archive_cmds_need_lc_CXX=no - ;; - - freebsd* | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - ld_shlibs_CXX=yes - ;; - - haiku*) - archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - link_all_deplibs_CXX=yes - ;; - - hpux9*) - hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_CXX=: - export_dynamic_flag_spec_CXX='${wl}-E' - hardcode_direct_CXX=yes - hardcode_minus_L_CXX=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aCC*) - 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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - 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' - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_CXX=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - export_dynamic_flag_spec_CXX='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct_CXX=no - hardcode_shlibpath_var_CXX=no - ;; - *) - hardcode_direct_CXX=yes - hardcode_direct_absolute_CXX=yes - hardcode_minus_L_CXX=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - 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' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - interix[3-9]*) - hardcode_direct_CXX=no - hardcode_shlibpath_var_CXX=no - hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' - export_dynamic_flag_spec_CXX='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - 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' - 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' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - 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' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - 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' - else - 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' - fi - fi - link_all_deplibs_CXX=yes - ;; - esac - hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_CXX=: - inherit_rpath_CXX=yes - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - 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' - 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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - - hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - 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' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - 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' - ;; - esac - archive_cmds_need_lc_CXX=no - hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-dynamic' - whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [1-5].* | *pgcpp\ [1-5].*) - prelink_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' - old_archive_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' - archive_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - archive_expsym_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $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' - ;; - *) # Version 6 and above use weak symbols - archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - 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' - ;; - esac - - hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-dynamic' - 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' - ;; - cxx*) - # Compaq C++ - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - 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' - - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec_CXX='-rpath $libdir' - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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' - ;; - xl* | mpixl* | bgxl*) - # IBM XL 8.0 on PPC, with GNU ld - hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec_CXX='${wl}--export-dynamic' - archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - no_undefined_flag_CXX=' -zdefs' - archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - 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' - hardcode_libdir_flag_spec_CXX='-R$libdir' - 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' - compiler_needs_object_CXX=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - esac - ;; - - lynxos*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - m88k*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - hardcode_libdir_flag_spec_CXX='-R$libdir' - hardcode_direct_CXX=yes - hardcode_shlibpath_var_CXX=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - - *nto* | *qnx*) - ld_shlibs_CXX=yes - ;; - - openbsd2*) - # C++ shared libraries are fairly broken - ld_shlibs_CXX=no - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - hardcode_direct_CXX=yes - hardcode_shlibpath_var_CXX=no - hardcode_direct_absolute_CXX=yes - archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - export_dynamic_flag_spec_CXX='${wl}-E' - whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd=func_echo_all - else - ld_shlibs_CXX=no - fi - ;; - - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - 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' - - hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' - hardcode_libdir_separator_CXX=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - cxx*) - case $host in - osf3*) - allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' - 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' - hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' - ;; - *) - allow_undefined_flag_CXX=' -expect_unresolved \*' - 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' - archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $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~ - $RM $lib.exp' - hardcode_libdir_flag_spec_CXX='-rpath $libdir' - ;; - esac - - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' - case $host in - osf3*) - 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' - ;; - *) - 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' - ;; - esac - - hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - archive_cmds_need_lc_CXX=yes - no_undefined_flag_CXX=' -zdefs' - archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - - hardcode_libdir_flag_spec_CXX='-R$libdir' - hardcode_shlibpath_var_CXX=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' - ;; - esac - link_all_deplibs_CXX=yes - - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - no_undefined_flag_CXX=' ${wl}-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - fi - - hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag_CXX='${wl}-z,text' - archive_cmds_need_lc_CXX=no - hardcode_shlibpath_var_CXX=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag_CXX='${wl}-z,text' - allow_undefined_flag_CXX='${wl}-z,nodefs' - archive_cmds_need_lc_CXX=no - hardcode_shlibpath_var_CXX=no - hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir' - hardcode_libdir_separator_CXX=':' - link_all_deplibs_CXX=yes - export_dynamic_flag_spec_CXX='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ - '"$old_archive_cmds_CXX" - reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ - '"$reload_cmds_CXX" - ;; - *) - archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 -$as_echo "$ld_shlibs_CXX" >&6; } - test "$ld_shlibs_CXX" = no && can_build_shared=no - - GCC_CXX="$GXX" - LD_CXX="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - # Dependencies to place before and after the object being linked: -predep_objects_CXX= -postdep_objects_CXX= -predeps_CXX= -postdeps_CXX= -compiler_lib_search_path_CXX= - -cat > conftest.$ac_ext <<_LT_EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -_LT_EOF - - -_lt_libdeps_save_CFLAGS=$CFLAGS -case "$CC $CFLAGS " in #( -*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; -*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; -*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; -esac - -if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - for p in `eval "$output_verbose_link_cmd"`; do - case ${prev}${p} in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test $p = "-L" || - test $p = "-R"; then - prev=$p - continue - fi - - # Expand the sysroot to ease extracting the directories later. - if test -z "$prev"; then - case $p in - -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; - -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; - -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; - esac - fi - case $p in - =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; - esac - if test "$pre_test_object_deps_done" = no; then - case ${prev} in - -L | -R) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$compiler_lib_search_path_CXX"; then - compiler_lib_search_path_CXX="${prev}${p}" - else - compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$postdeps_CXX"; then - postdeps_CXX="${prev}${p}" - else - postdeps_CXX="${postdeps_CXX} ${prev}${p}" - fi - fi - prev= - ;; - - *.lto.$objext) ;; # Ignore GCC LTO objects - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test "$pre_test_object_deps_done" = no; then - if test -z "$predep_objects_CXX"; then - predep_objects_CXX="$p" - else - predep_objects_CXX="$predep_objects_CXX $p" - fi - else - if test -z "$postdep_objects_CXX"; then - postdep_objects_CXX="$p" - else - postdep_objects_CXX="$postdep_objects_CXX $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling CXX test program" -fi - -$RM -f confest.$objext -CFLAGS=$_lt_libdeps_save_CFLAGS - -# PORTME: override above test on systems where it is broken -case $host_os in -interix[3-9]*) - # Interix 3.5 installs completely hosed .la files for C++, so rather than - # hack all around it, let's just trust "g++" to DTRT. - predep_objects_CXX= - postdep_objects_CXX= - postdeps_CXX= - ;; - -linux*) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - if test "$solaris_use_stlport4" != yes; then - postdeps_CXX='-library=Cstd -library=Crun' - fi - ;; - esac - ;; - -solaris*) - case $cc_basename in - CC* | sunCC*) - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - # Adding this requires a known-good setup of shared libraries for - # Sun compiler versions before 5.6, else PIC objects from an old - # archive will be linked into the output, leading to subtle bugs. - if test "$solaris_use_stlport4" != yes; then - postdeps_CXX='-library=Cstd -library=Crun' - fi - ;; - esac - ;; -esac - - -case " $postdeps_CXX " in -*" -lc "*) archive_cmds_need_lc_CXX=no ;; -esac - compiler_lib_search_dirs_CXX= -if test -n "${compiler_lib_search_path_CXX}"; then - compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - lt_prog_compiler_wl_CXX= -lt_prog_compiler_pic_CXX= -lt_prog_compiler_static_CXX= - - - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_CXX='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic_CXX='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic_CXX='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic_CXX='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - lt_prog_compiler_pic_CXX= - ;; - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static_CXX= - ;; - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic_CXX=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - lt_prog_compiler_pic_CXX='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic_CXX='-fPIC -shared' - ;; - *) - lt_prog_compiler_pic_CXX='-fPIC' - ;; - esac - else - case $host_os in - aix[4-9]*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_CXX='-Bstatic' - else - lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _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" - ;; - esac - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_CXX='-DDLL_EXPORT' - ;; - dgux*) - case $cc_basename in - ec++*) - lt_prog_compiler_pic_CXX='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - lt_prog_compiler_pic_CXX='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then - lt_prog_compiler_pic_CXX='+Z' - fi - ;; - aCC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_CXX='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - lt_prog_compiler_wl_CXX='--backend -Wl,' - lt_prog_compiler_pic_CXX='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-fPIC' - lt_prog_compiler_static_CXX='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-fpic' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - lt_prog_compiler_pic_CXX= - lt_prog_compiler_static_CXX='-non_shared' - ;; - xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) - # IBM XL 8.0, 9.0 on PPC and BlueGene - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-qpic' - lt_prog_compiler_static_CXX='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - lt_prog_compiler_wl_CXX='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - lt_prog_compiler_pic_CXX='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd* | netbsdelf*-gnu) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic_CXX='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - lt_prog_compiler_wl_CXX='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - lt_prog_compiler_pic_CXX='-pic' - ;; - cxx*) - # Digital/Compaq C++ - lt_prog_compiler_wl_CXX='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - lt_prog_compiler_pic_CXX= - lt_prog_compiler_static_CXX='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - lt_prog_compiler_wl_CXX='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - lt_prog_compiler_pic_CXX='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - lt_prog_compiler_pic_CXX='-pic' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - lcc*) - # Lucid - lt_prog_compiler_pic_CXX='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - lt_prog_compiler_pic_CXX='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - lt_prog_compiler_can_build_shared_CXX=no - ;; - esac - fi - -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic_CXX= - ;; - *) - lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -if ${lt_cv_prog_compiler_pic_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 -$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } -lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic_CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } -if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works_CXX=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works_CXX=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } - -if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then - case $lt_prog_compiler_pic_CXX in - "" | " "*) ;; - *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; - esac -else - lt_prog_compiler_pic_CXX= - lt_prog_compiler_can_build_shared_CXX=no -fi - -fi - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works_CXX=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works_CXX=yes - fi - else - lt_cv_prog_compiler_static_works_CXX=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 -$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } - -if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then - : -else - lt_prog_compiler_static_CXX= -fi - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o_CXX=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_CXX=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 -$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o_CXX=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_CXX=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 -$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } - - - - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - case $host_os in - aix[4-9]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global defined - # symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - 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' - else - 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' - fi - ;; - pw32*) - export_symbols_cmds_CXX="$ltdll_cmds" - ;; - cygwin* | mingw* | cegcc*) - case $cc_basename in - cl*) - exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - ;; - *) - 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' - exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - ;; - esac - ;; - linux* | k*bsd*-gnu | gnu*) - link_all_deplibs_CXX=no - ;; - *) - export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 -$as_echo "$ld_shlibs_CXX" >&6; } -test "$ld_shlibs_CXX" = no && can_build_shared=no - -with_gnu_ld_CXX=$with_gnu_ld - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc_CXX" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc_CXX=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds_CXX in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } -if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl_CXX - pic_flag=$lt_prog_compiler_pic_CXX - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag_CXX - allow_undefined_flag_CXX= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc_CXX=no - else - lt_cv_archive_cmds_need_lc_CXX=yes - fi - allow_undefined_flag_CXX=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 -$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } - archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } - -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if ${lt_cv_shlibpath_overrides_runpath+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action_CXX= -if test -n "$hardcode_libdir_flag_spec_CXX" || - test -n "$runpath_var_CXX" || - test "X$hardcode_automatic_CXX" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$hardcode_direct_CXX" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no && - test "$hardcode_minus_L_CXX" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action_CXX=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action_CXX=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action_CXX=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 -$as_echo "$hardcode_action_CXX" >&6; } - -if test "$hardcode_action_CXX" = relink || - test "$inherit_rpath_CXX" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - - fi # test -n "$compiler" - - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if ${ac_cv_path_install+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - - -if test "$GCC" = yes ; then - OLDCFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wstrict-prototypes" - CFLAGS="$OLDCFLAGS -fexceptions" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -fexceptions" >&5 -$as_echo_n "checking whether $CC accepts -fexceptions... " >&6; } - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; }; CFLAGS="$OLDCFLAGS" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - CXXFLAGS=`echo "$CFLAGS" | sed 's/ -Wmissing-prototypes -Wstrict-prototypes//'` -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 -$as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if ${ac_cv_c_bigendian+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_bigendian=unknown -# See if sys/param.h defines the BYTE_ORDER macro. -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int -main () -{ - -#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN - bogus endian macros -#endif - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - # It does; now see whether it defined to BIG_ENDIAN or not. -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int -main () -{ - -#if BYTE_ORDER != BIG_ENDIAN - not big endian -#endif - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_bigendian=yes -else - ac_cv_c_bigendian=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -if test $ac_cv_c_bigendian = unknown; then -if test "$cross_compiling" = yes; then : - echo $ac_n "cross-compiling... " 2>&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -main () { - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long l; - char c[sizeof (long)]; - } u; - u.l = 1; - exit (u.c[sizeof (long) - 1] == 1); -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - ac_cv_c_bigendian=no -else - ac_cv_c_bigendian=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 -$as_echo "$ac_cv_c_bigendian" >&6; } -if test $ac_cv_c_bigendian = unknown; then -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to probe for byte ordering" >&5 -$as_echo_n "checking to probe for byte ordering... " >&6; } - -cat >conftest.c <&6 - ac_cv_c_bigendian=yes - fi - if test `grep -l LiTTleEnDian conftest.o` ; then - echo $ac_n ' little endian probe OK, ' 1>&6 - if test $ac_cv_c_bigendian = yes ; then - ac_cv_c_bigendian=unknown; - else - ac_cv_c_bigendian=no - fi - fi - echo $ac_n 'guessing bigendian ... ' >&6 - fi - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 -$as_echo "$ac_cv_c_bigendian" >&6; } -fi -if test $ac_cv_c_bigendian = yes; then - -$as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h - - BYTEORDER=4321 -else - BYTEORDER=1234 -fi - -cat >>confdefs.h <<_ACEOF -#define BYTEORDER $BYTEORDER -_ACEOF - -if test $ac_cv_c_bigendian = unknown; then - as_fn_error please pre-set ac_cv_c_bigendian "unknown endianess - sorry" "$LINENO" 5 -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if ${ac_cv_c_const+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - -#ifndef __cplusplus - /* Ultrix mips cc rejects this sort of thing. */ - typedef int charset[2]; - const charset cs = { 0, 0 }; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this sort of thing. */ - char tx; - char *t = &tx; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; } bx; - struct s *b = &bx; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes -else - ac_cv_c_const=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -$as_echo "#define const /**/" >>confdefs.h - -fi - -ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" -if test "x$ac_cv_type_size_t" = xyes; then : - -else - -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int -_ACEOF - -fi - -for ac_func in memmove bcopy -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - -for ac_header in fcntl.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" -if test "x$ac_cv_type_off_t" = xyes; then : - -else - -cat >>confdefs.h <<_ACEOF -#define off_t long int -_ACEOF - -fi - - - - - for ac_header in $ac_header_list -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - - - - - - - -for ac_func in getpagesize -do : - ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" -if test "x$ac_cv_func_getpagesize" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETPAGESIZE 1 -_ACEOF - -fi -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 -$as_echo_n "checking for working mmap... " >&6; } -if ${ac_cv_func_mmap_fixed_mapped+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - ac_cv_func_mmap_fixed_mapped=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -/* malloc might have been renamed as rpl_malloc. */ -#undef malloc - -/* Thanks to Mike Haertel and Jim Avera for this test. - Here is a matrix of mmap possibilities: - mmap private not fixed - mmap private fixed at somewhere currently unmapped - mmap private fixed at somewhere already mapped - mmap shared not fixed - mmap shared fixed at somewhere currently unmapped - mmap shared fixed at somewhere already mapped - For private mappings, we should verify that changes cannot be read() - back from the file, nor mmap's back from the file at a different - address. (There have been systems where private was not correctly - implemented like the infamous i386 svr4.0, and systems where the - VM page cache was not coherent with the file system buffer cache - like early versions of FreeBSD and possibly contemporary NetBSD.) - For shared mappings, we should conversely verify that changes get - propagated back to all the places they're supposed to be. - - Grep wants private fixed already mapped. - The main things grep needs to know about mmap are: - * does it exist and is it safe to write into the mmap'd area - * how to use it (BSD variants) */ - -#include -#include - -#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H -char *malloc (); -#endif - -/* This mess was copied from the GNU getpagesize.h. */ -#ifndef HAVE_GETPAGESIZE -# ifdef _SC_PAGESIZE -# define getpagesize() sysconf(_SC_PAGESIZE) -# else /* no _SC_PAGESIZE */ -# ifdef HAVE_SYS_PARAM_H -# include -# ifdef EXEC_PAGESIZE -# define getpagesize() EXEC_PAGESIZE -# else /* no EXEC_PAGESIZE */ -# ifdef NBPG -# define getpagesize() NBPG * CLSIZE -# ifndef CLSIZE -# define CLSIZE 1 -# endif /* no CLSIZE */ -# else /* no NBPG */ -# ifdef NBPC -# define getpagesize() NBPC -# else /* no NBPC */ -# ifdef PAGESIZE -# define getpagesize() PAGESIZE -# endif /* PAGESIZE */ -# endif /* no NBPC */ -# endif /* no NBPG */ -# endif /* no EXEC_PAGESIZE */ -# else /* no HAVE_SYS_PARAM_H */ -# define getpagesize() 8192 /* punt totally */ -# endif /* no HAVE_SYS_PARAM_H */ -# endif /* no _SC_PAGESIZE */ - -#endif /* no HAVE_GETPAGESIZE */ - -int -main () -{ - char *data, *data2, *data3; - const char *cdata2; - int i, pagesize; - int fd, fd2; - - pagesize = getpagesize (); - - /* First, make a file with some known garbage in it. */ - data = (char *) malloc (pagesize); - if (!data) - return 1; - for (i = 0; i < pagesize; ++i) - *(data + i) = rand (); - umask (0); - fd = creat ("conftest.mmap", 0600); - if (fd < 0) - return 2; - if (write (fd, data, pagesize) != pagesize) - return 3; - close (fd); - - /* Next, check that the tail of a page is zero-filled. File must have - non-zero length, otherwise we risk SIGBUS for entire page. */ - fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); - if (fd2 < 0) - return 4; - cdata2 = ""; - if (write (fd2, cdata2, 1) != 1) - return 5; - data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); - if (data2 == MAP_FAILED) - return 6; - for (i = 0; i < pagesize; ++i) - if (*(data2 + i)) - return 7; - close (fd2); - if (munmap (data2, pagesize)) - return 8; - - /* Next, try to mmap the file at a fixed address which already has - something else allocated at it. If we can, also make sure that - we see the same garbage. */ - fd = open ("conftest.mmap", O_RDWR); - if (fd < 0) - return 9; - if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, - MAP_PRIVATE | MAP_FIXED, fd, 0L)) - return 10; - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data2 + i)) - return 11; - - /* Finally, make sure that changes to the mapped area do not - percolate back to the file as seen by read(). (This is a bug on - some variants of i386 svr4.0.) */ - for (i = 0; i < pagesize; ++i) - *(data2 + i) = *(data2 + i) + 1; - data3 = (char *) malloc (pagesize); - if (!data3) - return 12; - if (read (fd, data3, pagesize) != pagesize) - return 13; - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data3 + i)) - return 14; - close (fd); - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - ac_cv_func_mmap_fixed_mapped=yes -else - ac_cv_func_mmap_fixed_mapped=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 -$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } -if test $ac_cv_func_mmap_fixed_mapped = yes; then - -$as_echo "#define HAVE_MMAP 1" >>confdefs.h - -fi -rm -f conftest.mmap conftest.txt - - -if test "$ac_cv_func_mmap_fixed_mapped" = "yes"; then - FILEMAP=unixfilemap -else - FILEMAP=readfilemap -fi - - - -# AC_CPP_FUNC -# ------------------ # -# Checks to see if ANSI C99 CPP variable __func__ works. -# If not, perhaps __FUNCTION__ works instead. -# If not, we'll just define __func__ to "". -# AC_CPP_FUNC - - case $ac_cv_prog_cc_stdc in #( - no) : - ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #( - *) : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 -$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } -if ${ac_cv_prog_cc_c99+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -#include - -// Check varargs macros. These examples are taken from C99 6.10.3.5. -#define debug(...) fprintf (stderr, __VA_ARGS__) -#define showlist(...) puts (#__VA_ARGS__) -#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) -static void -test_varargs_macros (void) -{ - int x = 1234; - int y = 5678; - debug ("Flag"); - debug ("X = %d\n", x); - showlist (The first, second, and third items.); - report (x>y, "x is %d but y is %d", x, y); -} - -// Check long long types. -#define BIG64 18446744073709551615ull -#define BIG32 4294967295ul -#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) -#if !BIG_OK - your preprocessor is broken; -#endif -#if BIG_OK -#else - your preprocessor is broken; -#endif -static long long int bignum = -9223372036854775807LL; -static unsigned long long int ubignum = BIG64; - -struct incomplete_array -{ - int datasize; - double data[]; -}; - -struct named_init { - int number; - const wchar_t *name; - double average; -}; - -typedef const char *ccp; - -static inline int -test_restrict (ccp restrict text) -{ - // See if C++-style comments work. - // Iterate through items via the restricted pointer. - // Also check for declarations in for loops. - for (unsigned int i = 0; *(text+i) != '\0'; ++i) - continue; - return 0; -} - -// Check varargs and va_copy. -static void -test_varargs (const char *format, ...) -{ - va_list args; - va_start (args, format); - va_list args_copy; - va_copy (args_copy, args); - - const char *str; - int number; - float fnumber; - - while (*format) - { - switch (*format++) - { - case 's': // string - str = va_arg (args_copy, const char *); - break; - case 'd': // int - number = va_arg (args_copy, int); - break; - case 'f': // float - fnumber = va_arg (args_copy, double); - break; - default: - break; - } - } - va_end (args_copy); - va_end (args); -} - -int -main () -{ - - // Check bool. - _Bool success = false; - - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; - - // Check varargs. - test_varargs ("s, d' f .", "string", 65, 34.234); - test_varargs_macros (); - - // Check flexible array members. - struct incomplete_array *ia = - malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); - ia->datasize = 10; - for (int i = 0; i < ia->datasize; ++i) - ia->data[i] = i * 1.234; - - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; - - ni.number = 58; - - int dynamic_array[ni.number]; - dynamic_array[ni.number - 1] = 543; - - // work around unused variable warnings - return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' - || dynamic_array[ni.number - 1] != 543); - - ; - return 0; -} -_ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99 -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c99=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c99" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c99" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c99" != xno; then : - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 -else - ac_cv_prog_cc_stdc=no -fi - -fi - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5 -$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; } - if ${ac_cv_prog_cc_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -fi - - case $ac_cv_prog_cc_stdc in #( - no) : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; #( - '') : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; #( - *) : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5 -$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C99-conforming __func__" >&5 -$as_echo_n "checking for an ANSI C99-conforming __func__... " >&6; } -if ${ac_cv_cpp_func+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -char *foo = __func__; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_cpp_func=yes -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -char *foo = __FUNCTION__; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_cpp_func=__FUNCTION__ -else - ac_cv_cpp_func=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cpp_func" >&5 -$as_echo "$ac_cv_cpp_func" >&6; } -if test $ac_cv_cpp_func = __FUNCTION__; then - -$as_echo "#define __func__ __FUNCTION__" >>confdefs.h - -elif test $ac_cv_cpp_func = no; then - -$as_echo "#define __func__ \"\"" >>confdefs.h - -fi - - - - -$as_echo "#define XML_NS 1" >>confdefs.h - - -$as_echo "#define XML_DTD 1" >>confdefs.h - - -$as_echo "#define XML_CONTEXT_BYTES 1024" >>confdefs.h - - -ac_config_files="$ac_config_files Makefile expat.pc" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -DEFS=-DHAVE_CONFIG_H - -ac_libobjs= -ac_ltlibobjs= -U= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - - -: "${CONFIG_STATUS=./config.status}" -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by expat $as_me 2.1.0, which was -generated by GNU Autoconf 2.69. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE - -Configuration files: -$config_files - -Configuration headers: -$config_headers - -Configuration commands: -$config_commands - -Report bugs to ." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -expat config.status 2.1.0 -configured by $0, generated by GNU Autoconf 2.69, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2012 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=?*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - --*=) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg= - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - '') as_fn_error $? "missing file argument" ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error $? "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error $? "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# - - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' -DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' -OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' -macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' -macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' -enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' -enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' -pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' -enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' -SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' -ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' -PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' -host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' -host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' -host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' -build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' -build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' -build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' -SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' -Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' -GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' -EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' -FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' -LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' -NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' -LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' -max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' -ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' -exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' -lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' -lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' -lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' -lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' -lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' -reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' -reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' -deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' -file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' -file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' -want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' -sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' -AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' -AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' -archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' -STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' -RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' -old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' -old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' -lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' -CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' -CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' -compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' -GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' -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"`' -nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' -lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' -objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' -MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' -need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' -MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' -DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' -NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' -LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' -OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' -OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' -libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' -shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' -extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' -compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' -module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' -with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' -no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' -hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' -hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' -inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' -link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' -always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' -exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' -include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' -prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' -postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' -file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' -variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' -need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' -need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' -version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' -runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' -libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' -library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' -soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' -install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' -postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' -postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' -finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' -hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' -sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' -sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' -hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' -enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' -old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' -striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' -predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' -postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' -predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' -postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' -LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' -reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' -reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' -compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' -GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' -archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' -module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' -with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' -no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' -inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' -link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' -always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' -exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' -include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' -prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' -postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' -file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' -predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' -postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' -predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' -postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' - -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in AS \ -DLLTOOL \ -OBJDUMP \ -SHELL \ -ECHO \ -PATH_SEPARATOR \ -SED \ -GREP \ -EGREP \ -FGREP \ -LD \ -NM \ -LN_S \ -lt_SP2NL \ -lt_NL2SP \ -reload_flag \ -deplibs_check_method \ -file_magic_cmd \ -file_magic_glob \ -want_nocaseglob \ -sharedlib_from_linklib_cmd \ -AR \ -AR_FLAGS \ -archiver_list_spec \ -STRIP \ -RANLIB \ -CC \ -CFLAGS \ -compiler \ -lt_cv_sys_global_symbol_pipe \ -lt_cv_sys_global_symbol_to_cdecl \ -lt_cv_sys_global_symbol_to_c_name_address \ -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ -nm_file_list_spec \ -lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_pic \ -lt_prog_compiler_wl \ -lt_prog_compiler_static \ -lt_cv_prog_compiler_c_o \ -need_locks \ -MANIFEST_TOOL \ -DSYMUTIL \ -NMEDIT \ -LIPO \ -OTOOL \ -OTOOL64 \ -shrext_cmds \ -export_dynamic_flag_spec \ -whole_archive_flag_spec \ -compiler_needs_object \ -with_gnu_ld \ -allow_undefined_flag \ -no_undefined_flag \ -hardcode_libdir_flag_spec \ -hardcode_libdir_separator \ -exclude_expsyms \ -include_expsyms \ -file_list_spec \ -variables_saved_for_relink \ -libname_spec \ -library_names_spec \ -soname_spec \ -install_override_mode \ -finish_eval \ -old_striplib \ -striplib \ -compiler_lib_search_dirs \ -predep_objects \ -postdep_objects \ -predeps \ -postdeps \ -compiler_lib_search_path \ -LD_CXX \ -reload_flag_CXX \ -compiler_CXX \ -lt_prog_compiler_no_builtin_flag_CXX \ -lt_prog_compiler_pic_CXX \ -lt_prog_compiler_wl_CXX \ -lt_prog_compiler_static_CXX \ -lt_cv_prog_compiler_c_o_CXX \ -export_dynamic_flag_spec_CXX \ -whole_archive_flag_spec_CXX \ -compiler_needs_object_CXX \ -with_gnu_ld_CXX \ -allow_undefined_flag_CXX \ -no_undefined_flag_CXX \ -hardcode_libdir_flag_spec_CXX \ -hardcode_libdir_separator_CXX \ -exclude_expsyms_CXX \ -include_expsyms_CXX \ -file_list_spec_CXX \ -compiler_lib_search_dirs_CXX \ -predep_objects_CXX \ -postdep_objects_CXX \ -predeps_CXX \ -postdeps_CXX \ -compiler_lib_search_path_CXX; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in reload_cmds \ -old_postinstall_cmds \ -old_postuninstall_cmds \ -old_archive_cmds \ -extract_expsyms_cmds \ -old_archive_from_new_cmds \ -old_archive_from_expsyms_cmds \ -archive_cmds \ -archive_expsym_cmds \ -module_cmds \ -module_expsym_cmds \ -export_symbols_cmds \ -prelink_cmds \ -postlink_cmds \ -postinstall_cmds \ -postuninstall_cmds \ -finish_cmds \ -sys_lib_search_path_spec \ -sys_lib_dlsearch_path_spec \ -reload_cmds_CXX \ -old_archive_cmds_CXX \ -old_archive_from_new_cmds_CXX \ -old_archive_from_expsyms_cmds_CXX \ -archive_cmds_CXX \ -archive_expsym_cmds_CXX \ -module_cmds_CXX \ -module_expsym_cmds_CXX \ -export_symbols_cmds_CXX \ -prelink_cmds_CXX \ -postlink_cmds_CXX; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -ac_aux_dir='$ac_aux_dir' -xsi_shell='$xsi_shell' -lt_shell_append='$lt_shell_append' - -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - - - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile' - - - - - - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "expat_config.h") CONFIG_HEADERS="$CONFIG_HEADERS expat_config.h" ;; - "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "expat.pc") CONFIG_FILES="$CONFIG_FILES expat.pc" ;; - - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= ac_tmp= - trap 'exit_status=$? - : "${ac_tmp:=$tmp}" - { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 -ac_tmp=$tmp - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$ac_tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ - || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove sole $(srcdir), -# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ -h -s/// -s/^/:/ -s/[ ]*$/:/ -s/:\$(srcdir):/:/g -s/:\${srcdir}:/:/g -s/:@srcdir@:/:/g -s/^:*// -s/:*$// -x -s/\(=[ ]*\).*/\1/ -G -s/\n// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$ac_tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF - -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. - -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_tt=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_tt"; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. - -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" - - -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$ac_tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$ac_tmp/stdin" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ - >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ - "$ac_tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&2;} - - rm -f "$ac_tmp/stdin" - case $ac_file in - -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; - *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; - esac \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" - } >"$ac_tmp/config.h" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$ac_tmp/config.h" "$ac_file" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error $? "could not create -" "$LINENO" 5 - fi - ;; - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "libtool":C) - - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - - -# The names of the tagged configurations supported by this script. -available_tags="CXX " - -# ### BEGIN LIBTOOL CONFIG - -# Assembler program. -AS=$lt_AS - -# DLL creation program. -DLLTOOL=$lt_DLLTOOL - -# Object dumper program. -OBJDUMP=$lt_OBJDUMP - -# Which release of libtool.m4 was used? -macro_version=$macro_version -macro_revision=$macro_revision - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# What type of objects to build. -pic_mode=$pic_mode - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# An echo program that protects backslashes. -ECHO=$lt_ECHO - -# The PATH separator for the build system. -PATH_SEPARATOR=$lt_PATH_SEPARATOR - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="\$SED -e 1s/^X//" - -# A grep program that handles long lines. -GREP=$lt_GREP - -# An ERE matcher. -EGREP=$lt_EGREP - -# A literal string matcher. -FGREP=$lt_FGREP - -# A BSD- or MS-compatible name lister. -NM=$lt_NM - -# Whether we need soft or hard links. -LN_S=$lt_LN_S - -# What is the maximum length of a command? -max_cmd_len=$max_cmd_len - -# Object file suffix (normally "o"). -objext=$ac_objext - -# Executable file suffix (normally ""). -exeext=$exeext - -# whether the shell understands "unset". -lt_unset=$lt_unset - -# turn spaces into newlines. -SP2NL=$lt_lt_SP2NL - -# turn newlines into spaces. -NL2SP=$lt_lt_NL2SP - -# convert \$build file names to \$host format. -to_host_file_cmd=$lt_cv_to_host_file_cmd - -# convert \$build files to toolchain format. -to_tool_file_cmd=$lt_cv_to_tool_file_cmd - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method = "file_magic". -file_magic_cmd=$lt_file_magic_cmd - -# How to find potential files when deplibs_check_method = "file_magic". -file_magic_glob=$lt_file_magic_glob - -# Find potential files using nocaseglob when deplibs_check_method = "file_magic". -want_nocaseglob=$lt_want_nocaseglob - -# Command to associate shared and link libraries. -sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd - -# The archiver. -AR=$lt_AR - -# Flags to create an archive. -AR_FLAGS=$lt_AR_FLAGS - -# How to feed a file listing to the archiver. -archiver_list_spec=$lt_archiver_list_spec - -# A symbol stripping program. -STRIP=$lt_STRIP - -# Commands used to install an old-style archive. -RANLIB=$lt_RANLIB -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Whether to use a lock for old archive extraction. -lock_old_archive_extraction=$lock_old_archive_extraction - -# A C compiler. -LTCC=$lt_CC - -# LTCC compiler flags. -LTCFLAGS=$lt_CFLAGS - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration. -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair. -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# Transform the output of nm in a C name address pair when lib prefix is needed. -global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix - -# Specify filename containing input files for \$NM. -nm_file_list_spec=$lt_nm_file_list_spec - -# The root where to search for dependent libraries,and in which our libraries should be installed. -lt_sysroot=$lt_sysroot - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# Used to examine libraries when file_magic_cmd begins with "file". -MAGIC_CMD=$MAGIC_CMD - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Manifest tool. -MANIFEST_TOOL=$lt_MANIFEST_TOOL - -# Tool to manipulate archived DWARF debug symbol files on Mac OS X. -DSYMUTIL=$lt_DSYMUTIL - -# Tool to change global to local symbols on Mac OS X. -NMEDIT=$lt_NMEDIT - -# Tool to manipulate fat objects and archives on Mac OS X. -LIPO=$lt_LIPO - -# ldd/readelf like tool for Mach-O binaries on Mac OS X. -OTOOL=$lt_OTOOL - -# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. -OTOOL64=$lt_OTOOL64 - -# Old archive suffix (normally "a"). -libext=$libext - -# Shared library suffix (normally ".so"). -shrext_cmds=$lt_shrext_cmds - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at link time. -variables_saved_for_relink=$lt_variables_saved_for_relink - -# Do we need the "lib" prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Library versioning type. -version_type=$version_type - -# Shared library runtime path variable. -runpath_var=$runpath_var - -# Shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Permission mode override for installation of shared libraries. -install_override_mode=$lt_install_override_mode - -# Command to use after installation of a shared archive. -postinstall_cmds=$lt_postinstall_cmds - -# Command to use after uninstallation of a shared archive. -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# As "finish_cmds", except a single script fragment to be evaled but -# not shown. -finish_eval=$lt_finish_eval - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Compile-time system search path for libraries. -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries. -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - - -# The linker used to build libraries. -LD=$lt_LD - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds - -# A language specific compiler. -CC=$lt_compiler - -# Is the compiler the GNU compiler? -with_gcc=$GCC - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \${shlibpath_var} if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action - -# The directories searched by this compiler when creating a shared library. -compiler_lib_search_dirs=$lt_compiler_lib_search_dirs - -# Dependencies to place before and after the objects being linked to -# create a shared library. -predep_objects=$lt_predep_objects -postdep_objects=$lt_postdep_objects -predeps=$lt_predeps -postdeps=$lt_postdeps - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path - -# ### END LIBTOOL CONFIG - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - -ltmain="$ac_aux_dir/ltmain.sh" - - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - if test x"$xsi_shell" = xyes; then - sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ -func_dirname ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_basename ()$/,/^} # func_basename /c\ -func_basename ()\ -{\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ -func_dirname_and_basename ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ -func_stripname ()\ -{\ -\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ -\ # positional parameters, so assign one to ordinary parameter first.\ -\ func_stripname_result=${3}\ -\ func_stripname_result=${func_stripname_result#"${1}"}\ -\ func_stripname_result=${func_stripname_result%"${2}"}\ -} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ -func_split_long_opt ()\ -{\ -\ func_split_long_opt_name=${1%%=*}\ -\ func_split_long_opt_arg=${1#*=}\ -} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ -func_split_short_opt ()\ -{\ -\ func_split_short_opt_arg=${1#??}\ -\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ -} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ -func_lo2o ()\ -{\ -\ case ${1} in\ -\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ -\ *) func_lo2o_result=${1} ;;\ -\ esac\ -} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_xform ()$/,/^} # func_xform /c\ -func_xform ()\ -{\ - func_xform_result=${1%.*}.lo\ -} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_arith ()$/,/^} # func_arith /c\ -func_arith ()\ -{\ - func_arith_result=$(( $* ))\ -} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_len ()$/,/^} # func_len /c\ -func_len ()\ -{\ - func_len_result=${#1}\ -} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - -fi - -if test x"$lt_shell_append" = xyes; then - sed -e '/^func_append ()$/,/^} # func_append /c\ -func_append ()\ -{\ - eval "${1}+=\\${2}"\ -} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ -func_append_quoted ()\ -{\ -\ func_quote_for_eval "${2}"\ -\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ -} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 -$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} -fi - - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - - - cat <<_LT_EOF >> "$ofile" - -# ### BEGIN LIBTOOL TAG CONFIG: CXX - -# The linker used to build libraries. -LD=$lt_LD_CXX - -# How to create reloadable object files. -reload_flag=$lt_reload_flag_CXX -reload_cmds=$lt_reload_cmds_CXX - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds_CXX - -# A language specific compiler. -CC=$lt_compiler_CXX - -# Is the compiler the GNU compiler? -with_gcc=$GCC_CXX - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_CXX - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_CXX - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_CXX - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_CXX - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object_CXX - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds_CXX -archive_expsym_cmds=$lt_archive_expsym_cmds_CXX - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds_CXX -module_expsym_cmds=$lt_module_expsym_cmds_CXX - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld_CXX - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_CXX - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_CXX - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct_CXX - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \${shlibpath_var} if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute_CXX - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L_CXX - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic_CXX - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath_CXX - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_CXX - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols_CXX - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_CXX - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_CXX - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_CXX - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds_CXX - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds_CXX - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec_CXX - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_CXX - -# The directories searched by this compiler when creating a shared library. -compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX - -# Dependencies to place before and after the objects being linked to -# create a shared library. -predep_objects=$lt_predep_objects_CXX -postdep_objects=$lt_postdep_objects_CXX -predeps=$lt_predeps_CXX -postdeps=$lt_postdeps_CXX - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_CXX - -# ### END LIBTOOL TAG CONFIG: CXX -_LT_EOF - - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit 1 -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - - -abs_srcdir="`cd $srcdir && pwd`" -abs_builddir="`pwd`" -if test "$abs_srcdir" != "$abs_builddir"; then - make mkdir-init -fi diff --git a/lib-src/expat/configure.in b/lib-src/expat/configure.in deleted file mode 100644 index 7e968c46d..000000000 --- a/lib-src/expat/configure.in +++ /dev/null @@ -1,155 +0,0 @@ -dnl configuration script for expat -dnl Process this file with autoconf to produce a configure script. -dnl -dnl Copyright 2000 Clark Cooper -dnl -dnl This file is part of EXPAT. -dnl -dnl EXPAT is free software; you can redistribute it and/or modify it -dnl under the terms of the License (based on the MIT/X license) contained -dnl in the file COPYING that comes with this distribution. -dnl - -dnl Ensure that Expat is configured with autoconf 2.58 or newer -AC_PREREQ(2.58) - -dnl Get the version number of Expat, using m4's esyscmd() command to run -dnl the command at m4-generation time. This allows us to create an m4 -dnl symbol holding the correct version number. AC_INIT() requires the -dnl version number at m4-time, rather than when ./configure is run, so -dnl all this must happen as part of m4, not as part of the shell code -dnl contained in ./configure. -dnl -dnl NOTE: esyscmd() is a GNU M4 extension. Thus, we wrap it in an appropriate -dnl test. I believe this test will work, but I don't have a place with non- -dnl GNU M4 to test it right now. -define([expat_version], ifdef([__gnu__], - [esyscmd(conftools/get-version.sh lib/expat.h)], - [2.1.x])) -AC_INIT(expat, expat_version, expat-bugs@libexpat.org) -undefine([expat_version]) - -AC_CONFIG_SRCDIR(Makefile.in) -AC_CONFIG_AUX_DIR(conftools) -AC_CONFIG_MACRO_DIR([m4]) - - -dnl -dnl Increment LIBREVISION if source code has changed at all -dnl -dnl If the API has changed, increment LIBCURRENT and set LIBREVISION to 0 -dnl -dnl If the API changes compatibly (i.e. simply adding a new function -dnl without changing or removing earlier interfaces), then increment LIBAGE. -dnl -dnl If the API changes incompatibly set LIBAGE back to 0 -dnl - -LIBCURRENT=7 -LIBREVISION=0 -LIBAGE=6 - -AC_CONFIG_HEADER(expat_config.h) - -sinclude(conftools/ac_c_bigendian_cross.m4) - -AC_LIBTOOL_WIN32_DLL -AC_PROG_LIBTOOL - -AC_SUBST(LIBCURRENT) -AC_SUBST(LIBREVISION) -AC_SUBST(LIBAGE) - -dnl Checks for programs. -AC_PROG_CC -AC_PROG_CXX -AC_PROG_INSTALL - -if test "$GCC" = yes ; then - dnl - dnl Be careful about adding the -fexceptions option; some versions of - dnl GCC don't support it and it causes extra warnings that are only - dnl distracting; avoid. - dnl - OLDCFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wstrict-prototypes" - CFLAGS="$OLDCFLAGS -fexceptions" - AC_MSG_CHECKING(whether $CC accepts -fexceptions) - AC_TRY_LINK( , , - AC_MSG_RESULT(yes), - AC_MSG_RESULT(no); CFLAGS="$OLDCFLAGS") - CXXFLAGS=`echo "$CFLAGS" | sed 's/ -Wmissing-prototypes -Wstrict-prototypes//'` -fi - -dnl Checks for header files. -AC_HEADER_STDC - -dnl Checks for typedefs, structures, and compiler characteristics. - -dnl Note: Avoid using AC_C_BIGENDIAN because it does not -dnl work in a cross compile. -AC_C_BIGENDIAN_CROSS - -AC_C_CONST -AC_TYPE_SIZE_T -AC_CHECK_FUNCS(memmove bcopy) - -dnl Only needed for xmlwf: -AC_CHECK_HEADERS(fcntl.h unistd.h) -AC_TYPE_OFF_T -AC_FUNC_MMAP - -if test "$ac_cv_func_mmap_fixed_mapped" = "yes"; then - FILEMAP=unixfilemap -else - FILEMAP=readfilemap -fi -AC_SUBST(FILEMAP) - -dnl Needed for the test support code; this was found at -dnl http://lists.gnu.org/archive/html/bug-autoconf/2002-07/msg00028.html - -# AC_CPP_FUNC -# ------------------ # -# Checks to see if ANSI C99 CPP variable __func__ works. -# If not, perhaps __FUNCTION__ works instead. -# If not, we'll just define __func__ to "". -AC_DEFUN([AC_CPP_FUNC], -[AC_REQUIRE([AC_PROG_CC_STDC])dnl -AC_CACHE_CHECK([for an ANSI C99-conforming __func__], ac_cv_cpp_func, -[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], -[[char *foo = __func__;]])], - [ac_cv_cpp_func=yes], - [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], -[[char *foo = __FUNCTION__;]])], - [ac_cv_cpp_func=__FUNCTION__], - [ac_cv_cpp_func=no])])]) -if test $ac_cv_cpp_func = __FUNCTION__; then - AC_DEFINE(__func__,__FUNCTION__, - [Define to __FUNCTION__ or "" if `__func__' does not conform to -ANSI C.]) -elif test $ac_cv_cpp_func = no; then - AC_DEFINE(__func__,"", - [Define to __FUNCTION__ or "" if `__func__' does not conform to -ANSI C.]) -fi -])# AC_CPP_FUNC - -AC_CPP_FUNC - - -dnl Some basic configuration: -AC_DEFINE([XML_NS], 1, - [Define to make XML Namespaces functionality available.]) -AC_DEFINE([XML_DTD], 1, - [Define to make parameter entity parsing functionality available.]) -AC_DEFINE([XML_CONTEXT_BYTES], 1024, - [Define to specify how much context to retain around the current parse point.]) - -AC_CONFIG_FILES([Makefile expat.pc]) -AC_OUTPUT - -abs_srcdir="`cd $srcdir && pwd`" -abs_builddir="`pwd`" -if test "$abs_srcdir" != "$abs_builddir"; then - make mkdir-init -fi diff --git a/lib-src/expat/conftools/PrintPath b/lib-src/expat/conftools/PrintPath deleted file mode 100755 index e8559a3d6..000000000 --- a/lib-src/expat/conftools/PrintPath +++ /dev/null @@ -1,116 +0,0 @@ -#!/bin/sh -# Look for program[s] somewhere in $PATH. -# -# Options: -# -s -# Do not print out full pathname. (silent) -# -pPATHNAME -# Look in PATHNAME instead of $PATH -# -# Usage: -# PrintPath [-s] [-pPATHNAME] program [program ...] -# -# Initially written by Jim Jagielski for the Apache configuration mechanism -# (with kudos to Kernighan/Pike) -# -# This script falls under the Apache License. -# See http://www.apache.org/licenses/LICENSE - -## -# Some "constants" -## -pathname=$PATH -echo="yes" - -## -# Find out what OS we are running for later on -## -os=`(uname) 2>/dev/null` - -## -# Parse command line -## -for args in $* -do - case $args in - -s ) echo="no" ;; - -p* ) pathname="`echo $args | sed 's/^..//'`" ;; - * ) programs="$programs $args" ;; - esac -done - -## -# Now we make the adjustments required for OS/2 and everyone -# else :) -# -# First of all, all OS/2 programs have the '.exe' extension. -# Next, we adjust PATH (or what was given to us as PATH) to -# be whitespace separated directories. -# Finally, we try to determine the best flag to use for -# test/[] to look for an executable file. OS/2 just has '-r' -# but with other OSs, we do some funny stuff to check to see -# if test/[] knows about -x, which is the preferred flag. -## - -if [ "x$os" = "xOS/2" ] -then - ext=".exe" - pathname=`echo -E $pathname | - sed 's/^;/.;/ - s/;;/;.;/g - s/;$/;./ - s/;/ /g - s/\\\\/\\//g' ` - test_exec_flag="-r" -else - ext="" # No default extensions - pathname=`echo $pathname | - sed 's/^:/.:/ - s/::/:.:/g - s/:$/:./ - s/:/ /g' ` - # Here is how we test to see if test/[] can handle -x - testfile="pp.t.$$" - - cat > $testfile </dev/null`; then - test_exec_flag="-x" - else - test_exec_flag="-r" - fi - rm -f $testfile -fi - -for program in $programs -do - for path in $pathname - do - if [ $test_exec_flag $path/${program}${ext} ] && \ - [ ! -d $path/${program}${ext} ]; then - if [ "x$echo" = "xyes" ]; then - echo $path/${program}${ext} - fi - exit 0 - fi - -# Next try without extension (if one was used above) - if [ "x$ext" != "x" ]; then - if [ $test_exec_flag $path/${program} ] && \ - [ ! -d $path/${program} ]; then - if [ "x$echo" = "xyes" ]; then - echo $path/${program} - fi - exit 0 - fi - fi - done -done -exit 1 - diff --git a/lib-src/expat/conftools/ac_c_bigendian_cross.m4 b/lib-src/expat/conftools/ac_c_bigendian_cross.m4 deleted file mode 100644 index 8ed3edb24..000000000 --- a/lib-src/expat/conftools/ac_c_bigendian_cross.m4 +++ /dev/null @@ -1,81 +0,0 @@ -dnl @synopsis AC_C_BIGENDIAN_CROSS -dnl -dnl Check endianess even when crosscompiling -dnl (partially based on the original AC_C_BIGENDIAN). -dnl -dnl The implementation will create a binary, and instead of running -dnl the binary it will be grep'ed for some symbols that will look -dnl different for different endianess of the binary. -dnl -dnl @version $Id: ac_c_bigendian_cross.m4,v 1.2 2001/10/01 20:03:13 fdrake Exp $ -dnl @author Guido Draheim -dnl -AC_DEFUN([AC_C_BIGENDIAN_CROSS], -[AC_CACHE_CHECK(whether byte ordering is bigendian, ac_cv_c_bigendian, -[ac_cv_c_bigendian=unknown -# See if sys/param.h defines the BYTE_ORDER macro. -AC_TRY_COMPILE([#include -#include ], [ -#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN - bogus endian macros -#endif], [# It does; now see whether it defined to BIG_ENDIAN or not. -AC_TRY_COMPILE([#include -#include ], [ -#if BYTE_ORDER != BIG_ENDIAN - not big endian -#endif], ac_cv_c_bigendian=yes, ac_cv_c_bigendian=no)]) -if test $ac_cv_c_bigendian = unknown; then -AC_TRY_RUN([main () { - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long l; - char c[sizeof (long)]; - } u; - u.l = 1; - exit (u.c[sizeof (long) - 1] == 1); -}], ac_cv_c_bigendian=no, ac_cv_c_bigendian=yes, -[ echo $ac_n "cross-compiling... " 2>&AC_FD_MSG ]) -fi]) -if test $ac_cv_c_bigendian = unknown; then -AC_MSG_CHECKING(to probe for byte ordering) -[ -cat >conftest.c <&AC_FD_MSG - ac_cv_c_bigendian=yes - fi - if test `grep -l LiTTleEnDian conftest.o` ; then - echo $ac_n ' little endian probe OK, ' 1>&AC_FD_MSG - if test $ac_cv_c_bigendian = yes ; then - ac_cv_c_bigendian=unknown; - else - ac_cv_c_bigendian=no - fi - fi - echo $ac_n 'guessing bigendian ... ' >&AC_FD_MSG - fi - fi -AC_MSG_RESULT($ac_cv_c_bigendian) -fi -if test $ac_cv_c_bigendian = yes; then - AC_DEFINE(WORDS_BIGENDIAN, 1, [whether byteorder is bigendian]) - BYTEORDER=4321 -else - BYTEORDER=1234 -fi -AC_DEFINE_UNQUOTED(BYTEORDER, $BYTEORDER, [1234 = LIL_ENDIAN, 4321 = BIGENDIAN]) -if test $ac_cv_c_bigendian = unknown; then - AC_MSG_ERROR(unknown endianess - sorry, please pre-set ac_cv_c_bigendian) -fi -]) diff --git a/lib-src/expat/conftools/config.guess b/lib-src/expat/conftools/config.guess deleted file mode 100755 index 40eaed482..000000000 --- a/lib-src/expat/conftools/config.guess +++ /dev/null @@ -1,1517 +0,0 @@ -#! /bin/sh -# Attempt to guess a canonical system name. -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, -# 2011 Free Software Foundation, Inc. - -timestamp='2011-05-11' - -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - - -# Originally written by Per Bothner. Please send patches (context -# diff format) to and include a ChangeLog -# entry. -# -# This script attempts to guess a canonical system name similar to -# config.sub. If it succeeds, it prints the system name on stdout, and -# exits with 0. Otherwise, it exits with 1. -# -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] - -Output the configuration name of the system \`$me' is run on. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.guess ($timestamp) - -Originally written by Per Bothner. -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free -Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" >&2 - exit 1 ;; - * ) - break ;; - esac -done - -if test $# != 0; then - echo "$me: too many arguments$help" >&2 - exit 1 -fi - -trap 'exit 1' 1 2 15 - -# CC_FOR_BUILD -- compiler used by this script. Note that the use of a -# compiler to aid in system detection is discouraged as it requires -# temporary files to be created and, as you can see below, it is a -# headache to deal with in a portable fashion. - -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. - -# Portable tmp directory creation inspired by the Autoconf team. - -set_cc_for_build=' -trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; -trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; -: ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || - { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || - { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || - { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; -dummy=$tmp/dummy ; -tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; -case $CC_FOR_BUILD,$HOST_CC,$CC in - ,,) echo "int x;" > $dummy.c ; - for c in cc gcc c89 c99 ; do - if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then - CC_FOR_BUILD="$c"; break ; - fi ; - done ; - if test x"$CC_FOR_BUILD" = x ; then - CC_FOR_BUILD=no_compiler_found ; - fi - ;; - ,,*) CC_FOR_BUILD=$CC ;; - ,*,*) CC_FOR_BUILD=$HOST_CC ;; -esac ; set_cc_for_build= ;' - -# This is needed to find uname on a Pyramid OSx when run in the BSD universe. -# (ghazi@noc.rutgers.edu 1994-08-24) -if (test -f /.attbin/uname) >/dev/null 2>&1 ; then - PATH=$PATH:/.attbin ; export PATH -fi - -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown - -# Note: order is significant - the case branches are not exclusive. - -case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in - *:NetBSD:*:*) - # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, - # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently - # switched to ELF, *-*-netbsd* would select the old - # object file format. This provides both forward - # compatibility and a consistent mechanism for selecting the - # object file format. - # - # Note: NetBSD doesn't particularly care about the vendor - # portion of the name. We always set it to "unknown". - sysctl="sysctl -n hw.machine_arch" - UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ - /usr/sbin/$sysctl 2>/dev/null || echo unknown)` - case "${UNAME_MACHINE_ARCH}" in - armeb) machine=armeb-unknown ;; - arm*) machine=arm-unknown ;; - sh3el) machine=shl-unknown ;; - sh3eb) machine=sh-unknown ;; - sh5el) machine=sh5le-unknown ;; - *) machine=${UNAME_MACHINE_ARCH}-unknown ;; - esac - # The Operating System including object format, if it has switched - # to ELF recently, or will in the future. - case "${UNAME_MACHINE_ARCH}" in - arm*|i386|m68k|ns32k|sh3*|sparc|vax) - eval $set_cc_for_build - if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ELF__ - then - # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). - # Return netbsd for either. FIX? - os=netbsd - else - os=netbsdelf - fi - ;; - *) - os=netbsd - ;; - esac - # The OS release - # Debian GNU/NetBSD machines have a different userland, and - # thus, need a distinct triplet. However, they do not need - # kernel version information, so it can be replaced with a - # suitable tag, in the style of linux-gnu. - case "${UNAME_VERSION}" in - Debian*) - release='-gnu' - ;; - *) - release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` - ;; - esac - # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: - # contains redundant information, the shorter form: - # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "${machine}-${os}${release}" - exit ;; - *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} - exit ;; - *:ekkoBSD:*:*) - echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} - exit ;; - *:SolidBSD:*:*) - echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} - exit ;; - macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd${UNAME_RELEASE} - exit ;; - *:MirBSD:*:*) - echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} - exit ;; - alpha:OSF1:*:*) - case $UNAME_RELEASE in - *4.0) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` - ;; - *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` - ;; - esac - # According to Compaq, /usr/sbin/psrinfo has been available on - # OSF/1 and Tru64 systems produced since 1995. I hope that - # covers most systems running today. This code pipes the CPU - # types through head -n 1, so we only detect the type of CPU 0. - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` - case "$ALPHA_CPU_TYPE" in - "EV4 (21064)") - UNAME_MACHINE="alpha" ;; - "EV4.5 (21064)") - UNAME_MACHINE="alpha" ;; - "LCA4 (21066/21068)") - UNAME_MACHINE="alpha" ;; - "EV5 (21164)") - UNAME_MACHINE="alphaev5" ;; - "EV5.6 (21164A)") - UNAME_MACHINE="alphaev56" ;; - "EV5.6 (21164PC)") - UNAME_MACHINE="alphapca56" ;; - "EV5.7 (21164PC)") - UNAME_MACHINE="alphapca57" ;; - "EV6 (21264)") - UNAME_MACHINE="alphaev6" ;; - "EV6.7 (21264A)") - UNAME_MACHINE="alphaev67" ;; - "EV6.8CB (21264C)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8AL (21264B)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8CX (21264D)") - UNAME_MACHINE="alphaev68" ;; - "EV6.9A (21264/EV69A)") - UNAME_MACHINE="alphaev69" ;; - "EV7 (21364)") - UNAME_MACHINE="alphaev7" ;; - "EV7.9 (21364A)") - UNAME_MACHINE="alphaev79" ;; - esac - # A Pn.n version is a patched version. - # A Vn.n version is a released version. - # A Tn.n version is a released field test version. - # A Xn.n version is an unreleased experimental baselevel. - # 1.2 uses "1.2" for uname -r. - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; - Alpha\ *:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # Should we change UNAME_MACHINE based on the output of uname instead - # of the specific Alpha model? - echo alpha-pc-interix - exit ;; - 21064:Windows_NT:50:3) - echo alpha-dec-winnt3.5 - exit ;; - Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; - *:[Aa]miga[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-amigaos - exit ;; - *:[Mm]orph[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-morphos - exit ;; - *:OS/390:*:*) - echo i370-ibm-openedition - exit ;; - *:z/VM:*:*) - echo s390-ibm-zvmoe - exit ;; - *:OS400:*:*) - echo powerpc-ibm-os400 - exit ;; - arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix${UNAME_RELEASE} - exit ;; - arm:riscos:*:*|arm:RISCOS:*:*) - echo arm-unknown-riscos - exit ;; - SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - echo hppa1.1-hitachi-hiuxmpp - exit ;; - Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) - # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - if test "`(/bin/universe) 2>/dev/null`" = att ; then - echo pyramid-pyramid-sysv3 - else - echo pyramid-pyramid-bsd - fi - exit ;; - NILE*:*:*:dcosx) - echo pyramid-pyramid-svr4 - exit ;; - DRS?6000:unix:4.0:6*) - echo sparc-icl-nx6 - exit ;; - DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) - case `/usr/bin/uname -p` in - sparc) echo sparc-icl-nx7; exit ;; - esac ;; - s390x:SunOS:*:*) - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux${UNAME_RELEASE} - exit ;; - i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - eval $set_cc_for_build - SUN_ARCH="i386" - # If there is a compiler, see if it is configured for 64-bit objects. - # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. - # This test works for both compilers. - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - SUN_ARCH="x86_64" - fi - fi - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:6*:*) - # According to config.sub, this is the proper way to canonicalize - # SunOS6. Hard to guess exactly what SunOS6 will be like, but - # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:*:*) - case "`/usr/bin/arch -k`" in - Series*|S4*) - UNAME_RELEASE=`uname -v` - ;; - esac - # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` - exit ;; - sun3*:SunOS:*:*) - echo m68k-sun-sunos${UNAME_RELEASE} - exit ;; - sun*:*:4.2BSD:*) - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 - case "`/bin/arch`" in - sun3) - echo m68k-sun-sunos${UNAME_RELEASE} - ;; - sun4) - echo sparc-sun-sunos${UNAME_RELEASE} - ;; - esac - exit ;; - aushp:SunOS:*:*) - echo sparc-auspex-sunos${UNAME_RELEASE} - exit ;; - # The situation for MiNT is a little confusing. The machine name - # can be virtually everything (everything which is not - # "atarist" or "atariste" at least should have a processor - # > m68000). The system name ranges from "MiNT" over "FreeMiNT" - # to the lowercase version "mint" (or "freemint"). Finally - # the system name "TOS" denotes a system which is actually not - # MiNT. But MiNT is downward compatible to TOS, so this should - # be no problem. - atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; - hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; - *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; - m68k:machten:*:*) - echo m68k-apple-machten${UNAME_RELEASE} - exit ;; - powerpc:machten:*:*) - echo powerpc-apple-machten${UNAME_RELEASE} - exit ;; - RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; - RISC*:ULTRIX:*:*) - echo mips-dec-ultrix${UNAME_RELEASE} - exit ;; - VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix${UNAME_RELEASE} - exit ;; - 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix${UNAME_RELEASE} - exit ;; - mips:*:*:UMIPS | mips:*:*:RISCos) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c -#ifdef __cplusplus -#include /* for printf() prototype */ - int main (int argc, char *argv[]) { -#else - int main (argc, argv) int argc; char *argv[]; { -#endif - #if defined (host_mips) && defined (MIPSEB) - #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); - #endif - #endif - exit (-1); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && - dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`$dummy $dummyarg` && - { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos${UNAME_RELEASE} - exit ;; - Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax - exit ;; - Motorola:*:4.3:PL8-*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:Power_UNIX:*:*) - echo powerpc-harris-powerunix - exit ;; - m88k:CX/UX:7*:*) - echo m88k-harris-cxux7 - exit ;; - m88k:*:4*:R4*) - echo m88k-motorola-sysv4 - exit ;; - m88k:*:3*:R3*) - echo m88k-motorola-sysv3 - exit ;; - AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] - then - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ - [ ${TARGET_BINARY_INTERFACE}x = x ] - then - echo m88k-dg-dgux${UNAME_RELEASE} - else - echo m88k-dg-dguxbcs${UNAME_RELEASE} - fi - else - echo i586-dg-dgux${UNAME_RELEASE} - fi - exit ;; - M88*:DolphinOS:*:*) # DolphinOS (SVR3) - echo m88k-dolphin-sysv3 - exit ;; - M88*:*:R3*:*) - # Delta 88k system running SVR3 - echo m88k-motorola-sysv3 - exit ;; - XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - echo m88k-tektronix-sysv3 - exit ;; - Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - echo m68k-tektronix-bsd - exit ;; - *:IRIX*:*:*) - echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` - exit ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' - i*86:AIX:*:*) - echo i386-ibm-aix - exit ;; - ia64:AIX:*:*) - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} - exit ;; - *:AIX:2:3) - if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - - main() - { - if (!__power_pc()) - exit(1); - puts("powerpc-ibm-aix3.2.5"); - exit(0); - } -EOF - if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` - then - echo "$SYSTEM_NAME" - else - echo rs6000-ibm-aix3.2.5 - fi - elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - echo rs6000-ibm-aix3.2.4 - else - echo rs6000-ibm-aix3.2 - fi - exit ;; - *:AIX:*:[4567]) - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then - IBM_ARCH=rs6000 - else - IBM_ARCH=powerpc - fi - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${IBM_ARCH}-ibm-aix${IBM_REV} - exit ;; - *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; - ibmrt:4.4BSD:*|romp-ibm:BSD:*) - echo romp-ibm-bsd4.4 - exit ;; - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 - *:BOSX:*:*) - echo rs6000-bull-bosx - exit ;; - DPX/2?00:B.O.S.:*:*) - echo m68k-bull-sysv3 - exit ;; - 9000/[34]??:4.3bsd:1.*:*) - echo m68k-hp-bsd - exit ;; - hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - echo m68k-hp-bsd4.4 - exit ;; - 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - case "${UNAME_MACHINE}" in - 9000/31? ) HP_ARCH=m68000 ;; - 9000/[34]?? ) HP_ARCH=m68k ;; - 9000/[678][0-9][0-9]) - if [ -x /usr/bin/getconf ]; then - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; - '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac - fi - if [ "${HP_ARCH}" = "" ]; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - - #define _HPUX_SOURCE - #include - #include - - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); - - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } -EOF - (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` - test -z "$HP_ARCH" && HP_ARCH=hppa - fi ;; - esac - if [ ${HP_ARCH} = "hppa2.0w" ] - then - eval $set_cc_for_build - - # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating - # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler - # generating 64-bit code. GNU and HP use different nomenclature: - # - # $ CC_FOR_BUILD=cc ./config.guess - # => hppa2.0w-hp-hpux11.23 - # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess - # => hppa64-hp-hpux11.23 - - if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep -q __LP64__ - then - HP_ARCH="hppa2.0w" - else - HP_ARCH="hppa64" - fi - fi - echo ${HP_ARCH}-hp-hpux${HPUX_REV} - exit ;; - ia64:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux${HPUX_REV} - exit ;; - 3050*:HI-UX:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - int - main () - { - long cpu = sysconf (_SC_CPU_VERSION); - /* The order matters, because CPU_IS_HP_MC68K erroneously returns - true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct - results, however. */ - if (CPU_IS_PA_RISC (cpu)) - { - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; - case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; - default: puts ("hppa-hitachi-hiuxwe2"); break; - } - } - else if (CPU_IS_HP_MC68K (cpu)) - puts ("m68k-hitachi-hiuxwe2"); - else puts ("unknown-hitachi-hiuxwe2"); - exit (0); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) - echo hppa1.1-hp-bsd - exit ;; - 9000/8??:4.3bsd:*:*) - echo hppa1.0-hp-bsd - exit ;; - *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) - echo hppa1.1-hp-osf - exit ;; - hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; - i*86:OSF1:*:*) - if [ -x /usr/sbin/sysversion ] ; then - echo ${UNAME_MACHINE}-unknown-osf1mk - else - echo ${UNAME_MACHINE}-unknown-osf1 - fi - exit ;; - parisc*:Lites*:*:*) - echo hppa1.1-hp-lites - exit ;; - C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - echo c1-convex-bsd - exit ;; - C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - echo c34-convex-bsd - exit ;; - C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - echo c38-convex-bsd - exit ;; - C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - echo c4-convex-bsd - exit ;; - CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*[A-Z]90:*:*:*) - echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ - | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ - -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ - -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*TS:*:*:*) - echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*SV1:*:*:*) - echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) - FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} - exit ;; - sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:BSD/OS:*:*) - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:FreeBSD:*:*) - case ${UNAME_MACHINE} in - pc98) - echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - amd64) - echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - *) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - esac - exit ;; - i*:CYGWIN*:*) - echo ${UNAME_MACHINE}-pc-cygwin - exit ;; - *:MINGW*:*) - echo ${UNAME_MACHINE}-pc-mingw32 - exit ;; - i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 - exit ;; - i*:PW*:*) - echo ${UNAME_MACHINE}-pc-pw32 - exit ;; - *:Interix*:*) - case ${UNAME_MACHINE} in - x86) - echo i586-pc-interix${UNAME_RELEASE} - exit ;; - authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix${UNAME_RELEASE} - exit ;; - IA64) - echo ia64-unknown-interix${UNAME_RELEASE} - exit ;; - esac ;; - [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) - echo i${UNAME_MACHINE}-pc-mks - exit ;; - 8664:Windows_NT:*) - echo x86_64-pc-mks - exit ;; - i*:Windows_NT*:* | Pentium*:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we - # UNAME_MACHINE based on the output of uname instead of i386? - echo i586-pc-interix - exit ;; - i*:UWIN*:*) - echo ${UNAME_MACHINE}-pc-uwin - exit ;; - amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - echo x86_64-unknown-cygwin - exit ;; - p*:CYGWIN*:*) - echo powerpcle-unknown-cygwin - exit ;; - prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - *:GNU:*:*) - # the GNU system - echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` - exit ;; - *:GNU/*:*:*) - # other systems with GNU libc and userland - echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu - exit ;; - i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix - exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep -q ld.so.1 - if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} - exit ;; - arm*:Linux:*:*) - eval $set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_EABI__ - then - echo ${UNAME_MACHINE}-unknown-linux-gnu - else - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - echo ${UNAME_MACHINE}-unknown-linux-gnueabi - else - echo ${UNAME_MACHINE}-unknown-linux-gnueabihf - fi - fi - exit ;; - avr32*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - cris:Linux:*:*) - echo cris-axis-linux-gnu - exit ;; - crisv32:Linux:*:*) - echo crisv32-axis-linux-gnu - exit ;; - frv:Linux:*:*) - echo frv-unknown-linux-gnu - exit ;; - i*86:Linux:*:*) - LIBC=gnu - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #ifdef __dietlibc__ - LIBC=dietlibc - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` - echo "${UNAME_MACHINE}-pc-linux-${LIBC}" - exit ;; - ia64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - m32r*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - m68*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - mips:Linux:*:* | mips64:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef ${UNAME_MACHINE} - #undef ${UNAME_MACHINE}el - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=${UNAME_MACHINE}el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=${UNAME_MACHINE} - #else - CPU= - #endif - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } - ;; - or32:Linux:*:*) - echo or32-unknown-linux-gnu - exit ;; - padre:Linux:*:*) - echo sparc-unknown-linux-gnu - exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-gnu - exit ;; - parisc:Linux:*:* | hppa:Linux:*:*) - # Look for CPU level - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-gnu ;; - PA8*) echo hppa2.0-unknown-linux-gnu ;; - *) echo hppa-unknown-linux-gnu ;; - esac - exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu - exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu - exit ;; - s390:Linux:*:* | s390x:Linux:*:*) - echo ${UNAME_MACHINE}-ibm-linux - exit ;; - sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - sh*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - sparc:Linux:*:* | sparc64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - tile*:Linux:*:*) - echo ${UNAME_MACHINE}-tilera-linux-gnu - exit ;; - vax:Linux:*:*) - echo ${UNAME_MACHINE}-dec-linux-gnu - exit ;; - x86_64:Linux:*:*) - echo x86_64-unknown-linux-gnu - exit ;; - xtensa*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu - exit ;; - i*86:DYNIX/ptx:4*:*) - # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. - # earlier versions are messed up and put the nodename in both - # sysname and nodename. - echo i386-sequent-sysv4 - exit ;; - i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, - # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. - echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} - exit ;; - i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility - # is probably installed. - echo ${UNAME_MACHINE}-pc-os2-emx - exit ;; - i*86:XTS-300:*:STOP) - echo ${UNAME_MACHINE}-unknown-stop - exit ;; - i*86:atheos:*:*) - echo ${UNAME_MACHINE}-unknown-atheos - exit ;; - i*86:syllable:*:*) - echo ${UNAME_MACHINE}-pc-syllable - exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos${UNAME_RELEASE} - exit ;; - i*86:*DOS:*:*) - echo ${UNAME_MACHINE}-pc-msdosdjgpp - exit ;; - i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) - UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` - if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} - else - echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} - fi - exit ;; - i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. - case `/bin/uname -X | grep "^Machine"` in - *486*) UNAME_MACHINE=i486 ;; - *Pentium) UNAME_MACHINE=i586 ;; - *Pent*|*Celeron) UNAME_MACHINE=i686 ;; - esac - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} - exit ;; - i*86:*:3.2:*) - if test -f /usr/options/cb.name; then - UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` - (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 - (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ - && UNAME_MACHINE=i586 - (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ - && UNAME_MACHINE=i686 - (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ - && UNAME_MACHINE=i686 - echo ${UNAME_MACHINE}-pc-sco$UNAME_REL - else - echo ${UNAME_MACHINE}-pc-sysv32 - fi - exit ;; - pc:*:*:*) - # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i586. - # Note: whatever this is, it MUST be the same as what config.sub - # prints for the "djgpp" host, or else GDB configury will decide that - # this is a cross-build. - echo i586-pc-msdosdjgpp - exit ;; - Intel:Mach:3*:*) - echo i386-pc-mach3 - exit ;; - paragon:*:*:*) - echo i860-intel-osf1 - exit ;; - i860:*:4.*:*) # i860-SVR4 - if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 - else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 - fi - exit ;; - mini*:CTIX:SYS*5:*) - # "miniframe" - echo m68010-convergent-sysv - exit ;; - mc68k:UNIX:SYSTEM5:3.51m) - echo m68k-convergent-sysv - exit ;; - M680?0:D-NIX:5.3:*) - echo m68k-diab-dnix - exit ;; - M68*:*:R3V[5678]*:*) - test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; - 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) - OS_REL='' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; - NCR*:*:4.2:* | MPRAS*:*:4.2:*) - OS_REL='.3' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos${UNAME_RELEASE} - exit ;; - mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; - TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos${UNAME_RELEASE} - exit ;; - rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos${UNAME_RELEASE} - exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos${UNAME_RELEASE} - exit ;; - SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv${UNAME_RELEASE} - exit ;; - RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - RM*:SINIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - *:SINIX-*:*:*) - if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo ${UNAME_MACHINE}-sni-sysv4 - else - echo ns32k-sni-sysv - fi - exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; - *:UNIX_System_V:4*:FTX*) - # From Gerald Hewes . - # How about differentiating between stratus architectures? -djm - echo hppa1.1-stratus-sysv4 - exit ;; - *:*:*:FTX*) - # From seanf@swdc.stratus.com. - echo i860-stratus-sysv4 - exit ;; - i*86:VOS:*:*) - # From Paul.Green@stratus.com. - echo ${UNAME_MACHINE}-stratus-vos - exit ;; - *:VOS:*:*) - # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; - mc68*:A/UX:*:*) - echo m68k-apple-aux${UNAME_RELEASE} - exit ;; - news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; - R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) - if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} - else - echo mips-unknown-sysv${UNAME_RELEASE} - fi - exit ;; - BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - echo powerpc-be-beos - exit ;; - BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - echo powerpc-apple-beos - exit ;; - BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - echo i586-pc-beos - exit ;; - BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; - SX-4:SUPER-UX:*:*) - echo sx4-nec-superux${UNAME_RELEASE} - exit ;; - SX-5:SUPER-UX:*:*) - echo sx5-nec-superux${UNAME_RELEASE} - exit ;; - SX-6:SUPER-UX:*:*) - echo sx6-nec-superux${UNAME_RELEASE} - exit ;; - SX-7:SUPER-UX:*:*) - echo sx7-nec-superux${UNAME_RELEASE} - exit ;; - SX-8:SUPER-UX:*:*) - echo sx8-nec-superux${UNAME_RELEASE} - exit ;; - SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux${UNAME_RELEASE} - exit ;; - Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Rhapsody:*:*) - echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Darwin:*:*) - UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown - case $UNAME_PROCESSOR in - i386) - eval $set_cc_for_build - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - UNAME_PROCESSOR="x86_64" - fi - fi ;; - unknown) UNAME_PROCESSOR=powerpc ;; - esac - echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} - exit ;; - *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=`uname -p` - if test "$UNAME_PROCESSOR" = "x86"; then - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc - fi - echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} - exit ;; - *:QNX:*:4*) - echo i386-pc-qnx - exit ;; - NEO-?:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk${UNAME_RELEASE} - exit ;; - NSE-?:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk${UNAME_RELEASE} - exit ;; - NSR-?:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk${UNAME_RELEASE} - exit ;; - *:NonStop-UX:*:*) - echo mips-compaq-nonstopux - exit ;; - BS2000:POSIX*:*:*) - echo bs2000-siemens-sysv - exit ;; - DS/*:UNIX_System_V:*:*) - echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} - exit ;; - *:Plan9:*:*) - # "uname -m" is not consistent, so use $cputype instead. 386 - # is converted to i386 for consistency with other x86 - # operating systems. - if test "$cputype" = "386"; then - UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" - fi - echo ${UNAME_MACHINE}-unknown-plan9 - exit ;; - *:TOPS-10:*:*) - echo pdp10-unknown-tops10 - exit ;; - *:TENEX:*:*) - echo pdp10-unknown-tenex - exit ;; - KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - echo pdp10-dec-tops20 - exit ;; - XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - echo pdp10-xkl-tops20 - exit ;; - *:TOPS-20:*:*) - echo pdp10-unknown-tops20 - exit ;; - *:ITS:*:*) - echo pdp10-unknown-its - exit ;; - SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} - exit ;; - *:DragonFly:*:*) - echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` - exit ;; - *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "${UNAME_MACHINE}" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; - esac ;; - *:XENIX:*:SysV) - echo i386-pc-xenix - exit ;; - i*86:skyos:*:*) - echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' - exit ;; - i*86:rdos:*:*) - echo ${UNAME_MACHINE}-pc-rdos - exit ;; - i*86:AROS:*:*) - echo ${UNAME_MACHINE}-pc-aros - exit ;; -esac - -#echo '(No uname command or uname output not recognized.)' 1>&2 -#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 - -eval $set_cc_for_build -cat >$dummy.c < -# include -#endif -main () -{ -#if defined (sony) -#if defined (MIPSEB) - /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, - I don't know.... */ - printf ("mips-sony-bsd\n"); exit (0); -#else -#include - printf ("m68k-sony-newsos%s\n", -#ifdef NEWSOS4 - "4" -#else - "" -#endif - ); exit (0); -#endif -#endif - -#if defined (__arm) && defined (__acorn) && defined (__unix) - printf ("arm-acorn-riscix\n"); exit (0); -#endif - -#if defined (hp300) && !defined (hpux) - printf ("m68k-hp-bsd\n"); exit (0); -#endif - -#if defined (NeXT) -#if !defined (__ARCHITECTURE__) -#define __ARCHITECTURE__ "m68k" -#endif - int version; - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; - if (version < 4) - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); - else - printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); - exit (0); -#endif - -#if defined (MULTIMAX) || defined (n16) -#if defined (UMAXV) - printf ("ns32k-encore-sysv\n"); exit (0); -#else -#if defined (CMU) - printf ("ns32k-encore-mach\n"); exit (0); -#else - printf ("ns32k-encore-bsd\n"); exit (0); -#endif -#endif -#endif - -#if defined (__386BSD__) - printf ("i386-pc-bsd\n"); exit (0); -#endif - -#if defined (sequent) -#if defined (i386) - printf ("i386-sequent-dynix\n"); exit (0); -#endif -#if defined (ns32000) - printf ("ns32k-sequent-dynix\n"); exit (0); -#endif -#endif - -#if defined (_SEQUENT_) - struct utsname un; - - uname(&un); - - if (strncmp(un.version, "V2", 2) == 0) { - printf ("i386-sequent-ptx2\n"); exit (0); - } - if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ - printf ("i386-sequent-ptx1\n"); exit (0); - } - printf ("i386-sequent-ptx\n"); exit (0); - -#endif - -#if defined (vax) -# if !defined (ultrix) -# include -# if defined (BSD) -# if BSD == 43 - printf ("vax-dec-bsd4.3\n"); exit (0); -# else -# if BSD == 199006 - printf ("vax-dec-bsd4.3reno\n"); exit (0); -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# endif -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# else - printf ("vax-dec-ultrix\n"); exit (0); -# endif -#endif - -#if defined (alliant) && defined (i860) - printf ("i860-alliant-bsd\n"); exit (0); -#endif - - exit (1); -} -EOF - -$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - -# Apollos put the system type in the environment. - -test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } - -# Convex versions that predate uname can use getsysinfo(1) - -if [ -x /usr/convex/getsysinfo ] -then - case `getsysinfo -f cpu_type` in - c1*) - echo c1-convex-bsd - exit ;; - c2*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - c34*) - echo c34-convex-bsd - exit ;; - c38*) - echo c38-convex-bsd - exit ;; - c4*) - echo c4-convex-bsd - exit ;; - esac -fi - -cat >&2 < in order to provide the needed -information to handle your system. - -config.guess timestamp = $timestamp - -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null` - -hostinfo = `(hostinfo) 2>/dev/null` -/bin/universe = `(/bin/universe) 2>/dev/null` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` -/bin/arch = `(/bin/arch) 2>/dev/null` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` - -UNAME_MACHINE = ${UNAME_MACHINE} -UNAME_RELEASE = ${UNAME_RELEASE} -UNAME_SYSTEM = ${UNAME_SYSTEM} -UNAME_VERSION = ${UNAME_VERSION} -EOF - -exit 1 - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/expat/conftools/config.sub b/lib-src/expat/conftools/config.sub deleted file mode 100755 index 30fdca812..000000000 --- a/lib-src/expat/conftools/config.sub +++ /dev/null @@ -1,1760 +0,0 @@ -#! /bin/sh -# Configuration validation subroutine script. -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, -# 2011 Free Software Foundation, Inc. - -timestamp='2011-03-23' - -# This file is (in principle) common to ALL GNU software. -# The presence of a machine in this file suggests that SOME GNU software -# can handle that machine. It does not imply ALL GNU software can. -# -# This file is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - - -# Please send patches to . Submit a context -# diff and a properly formatted GNU ChangeLog entry. -# -# Configuration subroutine to validate and canonicalize a configuration type. -# Supply the specified configuration type as an argument. -# If it is invalid, we print an error message on stderr and exit with code 1. -# Otherwise, we print the canonical config type on stdout and succeed. - -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD - -# This file is supposed to be the same for all GNU packages -# and recognize all the CPU types, system types and aliases -# that are meaningful with *any* GNU software. -# Each package is responsible for reporting which valid configurations -# it does not support. The user should be able to distinguish -# a failure to support a valid configuration from a meaningless -# configuration. - -# The goal of this file is to map all the various variations of a given -# machine specification into a single specification in the form: -# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM -# or in some cases, the newer four-part form: -# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM -# It is wrong to echo any other type of specification. - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] CPU-MFR-OPSYS - $0 [OPTION] ALIAS - -Canonicalize a configuration name. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.sub ($timestamp) - -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free -Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" - exit 1 ;; - - *local*) - # First pass through any local machine types. - echo $1 - exit ;; - - * ) - break ;; - esac -done - -case $# in - 0) echo "$me: missing argument$help" >&2 - exit 1;; - 1) ;; - *) echo "$me: too many arguments$help" >&2 - exit 1;; -esac - -# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). -# Here we must recognize all the valid KERNEL-OS combinations. -maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` -case $maybe_os in - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ - linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ - knetbsd*-gnu* | netbsd*-gnu* | \ - kopensolaris*-gnu* | \ - storm-chaos* | os2-emx* | rtmk-nova*) - os=-$maybe_os - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` - ;; - *) - basic_machine=`echo $1 | sed 's/-[^-]*$//'` - if [ $basic_machine != $1 ] - then os=`echo $1 | sed 's/.*-/-/'` - else os=; fi - ;; -esac - -### Let's recognize common machines as not being operating systems so -### that things like config.sub decstation-3100 work. We also -### recognize some manufacturers as not being operating systems, so we -### can provide default operating systems below. -case $os in - -sun*os*) - # Prevent following clause from handling this invalid input. - ;; - -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ - -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ - -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ - -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ - -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ - -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray | -microblaze) - os= - basic_machine=$1 - ;; - -bluegene*) - os=-cnk - ;; - -sim | -cisco | -oki | -wec | -winbond) - os= - basic_machine=$1 - ;; - -scout) - ;; - -wrs) - os=-vxworks - basic_machine=$1 - ;; - -chorusos*) - os=-chorusos - basic_machine=$1 - ;; - -chorusrdb) - os=-chorusrdb - basic_machine=$1 - ;; - -hiux*) - os=-hiuxwe2 - ;; - -sco6) - os=-sco5v6 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5) - os=-sco3.2v5 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco4) - os=-sco3.2v4 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2.[4-9]*) - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2v[4-9]*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5v6*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco*) - os=-sco3.2v2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -udk*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -isc) - os=-isc2.2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -clix*) - basic_machine=clipper-intergraph - ;; - -isc*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -lynx*) - os=-lynxos - ;; - -ptx*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` - ;; - -windowsnt*) - os=`echo $os | sed -e 's/windowsnt/winnt/'` - ;; - -psos*) - os=-psos - ;; - -mint | -mint[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; -esac - -# Decode aliases for certain CPU-COMPANY combinations. -case $basic_machine in - # Recognize the basic CPU types without company name. - # Some are omitted here because they have special meanings below. - 1750a | 580 \ - | a29k \ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ - | am33_2.0 \ - | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ - | bfin \ - | c4x | clipper \ - | d10v | d30v | dlx | dsp16xx \ - | fido | fr30 | frv \ - | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ - | i370 | i860 | i960 | ia64 \ - | ip2k | iq2000 \ - | lm32 \ - | m32c | m32r | m32rle | m68000 | m68k | m88k \ - | maxq | mb | microblaze | mcore | mep | metag \ - | mips | mipsbe | mipseb | mipsel | mipsle \ - | mips16 \ - | mips64 | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ - | mips64vr | mips64vrel \ - | mips64vr4100 | mips64vr4100el \ - | mips64vr4300 | mips64vr4300el \ - | mips64vr5000 | mips64vr5000el \ - | mips64vr5900 | mips64vr5900el \ - | mipsisa32 | mipsisa32el \ - | mipsisa32r2 | mipsisa32r2el \ - | mipsisa64 | mipsisa64el \ - | mipsisa64r2 | mipsisa64r2el \ - | mipsisa64sb1 | mipsisa64sb1el \ - | mipsisa64sr71k | mipsisa64sr71kel \ - | mipstx39 | mipstx39el \ - | mn10200 | mn10300 \ - | moxie \ - | mt \ - | msp430 \ - | nds32 | nds32le | nds32be \ - | nios | nios2 \ - | ns16k | ns32k \ - | open8 \ - | or32 \ - | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle \ - | pyramid \ - | rx \ - | score \ - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ - | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ - | spu \ - | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ - | ubicom32 \ - | v850 | v850e \ - | we32k \ - | x86 | xc16x | xstormy16 | xtensa \ - | z8k | z80) - basic_machine=$basic_machine-unknown - ;; - c54x) - basic_machine=tic54x-unknown - ;; - c55x) - basic_machine=tic55x-unknown - ;; - c6x) - basic_machine=tic6x-unknown - ;; - m6811 | m68hc11 | m6812 | m68hc12 | picochip) - # Motorola 68HC11/12. - basic_machine=$basic_machine-unknown - os=-none - ;; - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) - ;; - ms1) - basic_machine=mt-unknown - ;; - - strongarm | thumb | xscale) - basic_machine=arm-unknown - ;; - - xscaleeb) - basic_machine=armeb-unknown - ;; - - xscaleel) - basic_machine=armel-unknown - ;; - - # We use `pc' rather than `unknown' - # because (1) that's what they normally are, and - # (2) the word "unknown" tends to confuse beginning users. - i*86 | x86_64) - basic_machine=$basic_machine-pc - ;; - # Object if more than one company name word. - *-*-*) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; - # Recognize the basic CPU types with company name. - 580-* \ - | a29k-* \ - | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ - | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ - | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ - | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* | avr32-* \ - | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* \ - | clipper-* | craynv-* | cydra-* \ - | d10v-* | d30v-* | dlx-* \ - | elxsi-* \ - | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ - | h8300-* | h8500-* \ - | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ - | i*86-* | i860-* | i960-* | ia64-* \ - | ip2k-* | iq2000-* \ - | lm32-* \ - | m32c-* | m32r-* | m32rle-* \ - | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \ - | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ - | mips16-* \ - | mips64-* | mips64el-* \ - | mips64octeon-* | mips64octeonel-* \ - | mips64orion-* | mips64orionel-* \ - | mips64r5900-* | mips64r5900el-* \ - | mips64vr-* | mips64vrel-* \ - | mips64vr4100-* | mips64vr4100el-* \ - | mips64vr4300-* | mips64vr4300el-* \ - | mips64vr5000-* | mips64vr5000el-* \ - | mips64vr5900-* | mips64vr5900el-* \ - | mipsisa32-* | mipsisa32el-* \ - | mipsisa32r2-* | mipsisa32r2el-* \ - | mipsisa64-* | mipsisa64el-* \ - | mipsisa64r2-* | mipsisa64r2el-* \ - | mipsisa64sb1-* | mipsisa64sb1el-* \ - | mipsisa64sr71k-* | mipsisa64sr71kel-* \ - | mipstx39-* | mipstx39el-* \ - | mmix-* \ - | mt-* \ - | msp430-* \ - | nds32-* | nds32le-* | nds32be-* \ - | nios-* | nios2-* \ - | none-* | np1-* | ns16k-* | ns32k-* \ - | open8-* \ - | orion-* \ - | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ - | pyramid-* \ - | romp-* | rs6000-* | rx-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ - | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ - | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ - | tahoe-* \ - | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ - | tile-* | tilegx-* \ - | tron-* \ - | ubicom32-* \ - | v850-* | v850e-* | vax-* \ - | we32k-* \ - | x86-* | x86_64-* | xc16x-* | xps100-* \ - | xstormy16-* | xtensa*-* \ - | ymp-* \ - | z8k-* | z80-*) - ;; - # Recognize the basic CPU types without company name, with glob match. - xtensa*) - basic_machine=$basic_machine-unknown - ;; - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. - 386bsd) - basic_machine=i386-unknown - os=-bsd - ;; - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) - basic_machine=m68000-att - ;; - 3b*) - basic_machine=we32k-att - ;; - a29khif) - basic_machine=a29k-amd - os=-udi - ;; - abacus) - basic_machine=abacus-unknown - ;; - adobe68k) - basic_machine=m68010-adobe - os=-scout - ;; - alliant | fx80) - basic_machine=fx80-alliant - ;; - altos | altos3068) - basic_machine=m68k-altos - ;; - am29k) - basic_machine=a29k-none - os=-bsd - ;; - amd64) - basic_machine=x86_64-pc - ;; - amd64-*) - basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - amdahl) - basic_machine=580-amdahl - os=-sysv - ;; - amiga | amiga-*) - basic_machine=m68k-unknown - ;; - amigaos | amigados) - basic_machine=m68k-unknown - os=-amigaos - ;; - amigaunix | amix) - basic_machine=m68k-unknown - os=-sysv4 - ;; - apollo68) - basic_machine=m68k-apollo - os=-sysv - ;; - apollo68bsd) - basic_machine=m68k-apollo - os=-bsd - ;; - aros) - basic_machine=i386-pc - os=-aros - ;; - aux) - basic_machine=m68k-apple - os=-aux - ;; - balance) - basic_machine=ns32k-sequent - os=-dynix - ;; - blackfin) - basic_machine=bfin-unknown - os=-linux - ;; - blackfin-*) - basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - bluegene*) - basic_machine=powerpc-ibm - os=-cnk - ;; - c54x-*) - basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c55x-*) - basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c6x-*) - basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c90) - basic_machine=c90-cray - os=-unicos - ;; - cegcc) - basic_machine=arm-unknown - os=-cegcc - ;; - convex-c1) - basic_machine=c1-convex - os=-bsd - ;; - convex-c2) - basic_machine=c2-convex - os=-bsd - ;; - convex-c32) - basic_machine=c32-convex - os=-bsd - ;; - convex-c34) - basic_machine=c34-convex - os=-bsd - ;; - convex-c38) - basic_machine=c38-convex - os=-bsd - ;; - cray | j90) - basic_machine=j90-cray - os=-unicos - ;; - craynv) - basic_machine=craynv-cray - os=-unicosmp - ;; - cr16 | cr16-*) - basic_machine=cr16-unknown - os=-elf - ;; - crds | unos) - basic_machine=m68k-crds - ;; - crisv32 | crisv32-* | etraxfs*) - basic_machine=crisv32-axis - ;; - cris | cris-* | etrax*) - basic_machine=cris-axis - ;; - crx) - basic_machine=crx-unknown - os=-elf - ;; - da30 | da30-*) - basic_machine=m68k-da30 - ;; - decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) - basic_machine=mips-dec - ;; - decsystem10* | dec10*) - basic_machine=pdp10-dec - os=-tops10 - ;; - decsystem20* | dec20*) - basic_machine=pdp10-dec - os=-tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) - basic_machine=m68k-motorola - ;; - delta88) - basic_machine=m88k-motorola - os=-sysv3 - ;; - dicos) - basic_machine=i686-pc - os=-dicos - ;; - djgpp) - basic_machine=i586-pc - os=-msdosdjgpp - ;; - dpx20 | dpx20-*) - basic_machine=rs6000-bull - os=-bosx - ;; - dpx2* | dpx2*-bull) - basic_machine=m68k-bull - os=-sysv3 - ;; - ebmon29k) - basic_machine=a29k-amd - os=-ebmon - ;; - elxsi) - basic_machine=elxsi-elxsi - os=-bsd - ;; - encore | umax | mmax) - basic_machine=ns32k-encore - ;; - es1800 | OSE68k | ose68k | ose | OSE) - basic_machine=m68k-ericsson - os=-ose - ;; - fx2800) - basic_machine=i860-alliant - ;; - genix) - basic_machine=ns32k-ns - ;; - gmicro) - basic_machine=tron-gmicro - os=-sysv - ;; - go32) - basic_machine=i386-pc - os=-go32 - ;; - h3050r* | hiux*) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - h8300hms) - basic_machine=h8300-hitachi - os=-hms - ;; - h8300xray) - basic_machine=h8300-hitachi - os=-xray - ;; - h8500hms) - basic_machine=h8500-hitachi - os=-hms - ;; - harris) - basic_machine=m88k-harris - os=-sysv3 - ;; - hp300-*) - basic_machine=m68k-hp - ;; - hp300bsd) - basic_machine=m68k-hp - os=-bsd - ;; - hp300hpux) - basic_machine=m68k-hp - os=-hpux - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) - basic_machine=m68000-hp - ;; - hp9k3[2-9][0-9]) - basic_machine=m68k-hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) - basic_machine=hppa1.1-hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hppa-next) - os=-nextstep3 - ;; - hppaosf) - basic_machine=hppa1.1-hp - os=-osf - ;; - hppro) - basic_machine=hppa1.1-hp - os=-proelf - ;; - i370-ibm* | ibm*) - basic_machine=i370-ibm - ;; -# I'm not sure what "Sysv32" means. Should this be sysv3.2? - i*86v32) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv32 - ;; - i*86v4*) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv4 - ;; - i*86v) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv - ;; - i*86sol2) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-solaris2 - ;; - i386mach) - basic_machine=i386-mach - os=-mach - ;; - i386-vsta | vsta) - basic_machine=i386-unknown - os=-vsta - ;; - iris | iris4d) - basic_machine=mips-sgi - case $os in - -irix*) - ;; - *) - os=-irix4 - ;; - esac - ;; - isi68 | isi) - basic_machine=m68k-isi - os=-sysv - ;; - m68knommu) - basic_machine=m68k-unknown - os=-linux - ;; - m68knommu-*) - basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - m88k-omron*) - basic_machine=m88k-omron - ;; - magnum | m3230) - basic_machine=mips-mips - os=-sysv - ;; - merlin) - basic_machine=ns32k-utek - os=-sysv - ;; - microblaze) - basic_machine=microblaze-xilinx - ;; - mingw32) - basic_machine=i386-pc - os=-mingw32 - ;; - mingw32ce) - basic_machine=arm-unknown - os=-mingw32ce - ;; - miniframe) - basic_machine=m68000-convergent - ;; - *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; - mips3*-*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` - ;; - mips3*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown - ;; - monitor) - basic_machine=m68k-rom68k - os=-coff - ;; - morphos) - basic_machine=powerpc-unknown - os=-morphos - ;; - msdos) - basic_machine=i386-pc - os=-msdos - ;; - ms1-*) - basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` - ;; - mvs) - basic_machine=i370-ibm - os=-mvs - ;; - ncr3000) - basic_machine=i486-ncr - os=-sysv4 - ;; - netbsd386) - basic_machine=i386-unknown - os=-netbsd - ;; - netwinder) - basic_machine=armv4l-rebel - os=-linux - ;; - news | news700 | news800 | news900) - basic_machine=m68k-sony - os=-newsos - ;; - news1000) - basic_machine=m68030-sony - os=-newsos - ;; - news-3600 | risc-news) - basic_machine=mips-sony - os=-newsos - ;; - necv70) - basic_machine=v70-nec - os=-sysv - ;; - next | m*-next ) - basic_machine=m68k-next - case $os in - -nextstep* ) - ;; - -ns2*) - os=-nextstep2 - ;; - *) - os=-nextstep3 - ;; - esac - ;; - nh3000) - basic_machine=m68k-harris - os=-cxux - ;; - nh[45]000) - basic_machine=m88k-harris - os=-cxux - ;; - nindy960) - basic_machine=i960-intel - os=-nindy - ;; - mon960) - basic_machine=i960-intel - os=-mon960 - ;; - nonstopux) - basic_machine=mips-compaq - os=-nonstopux - ;; - np1) - basic_machine=np1-gould - ;; - neo-tandem) - basic_machine=neo-tandem - ;; - nse-tandem) - basic_machine=nse-tandem - ;; - nsr-tandem) - basic_machine=nsr-tandem - ;; - op50n-* | op60c-*) - basic_machine=hppa1.1-oki - os=-proelf - ;; - openrisc | openrisc-*) - basic_machine=or32-unknown - ;; - os400) - basic_machine=powerpc-ibm - os=-os400 - ;; - OSE68000 | ose68000) - basic_machine=m68000-ericsson - os=-ose - ;; - os68k) - basic_machine=m68k-none - os=-os68k - ;; - pa-hitachi) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - paragon) - basic_machine=i860-intel - os=-osf - ;; - parisc) - basic_machine=hppa-unknown - os=-linux - ;; - parisc-*) - basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - pbd) - basic_machine=sparc-tti - ;; - pbb) - basic_machine=m68k-tti - ;; - pc532 | pc532-*) - basic_machine=ns32k-pc532 - ;; - pc98) - basic_machine=i386-pc - ;; - pc98-*) - basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium | p5 | k5 | k6 | nexgen | viac3) - basic_machine=i586-pc - ;; - pentiumpro | p6 | 6x86 | athlon | athlon_*) - basic_machine=i686-pc - ;; - pentiumii | pentium2 | pentiumiii | pentium3) - basic_machine=i686-pc - ;; - pentium4) - basic_machine=i786-pc - ;; - pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) - basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumpro-* | p6-* | 6x86-* | athlon-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium4-*) - basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pn) - basic_machine=pn-gould - ;; - power) basic_machine=power-ibm - ;; - ppc | ppcbe) basic_machine=powerpc-unknown - ;; - ppc-* | ppcbe-*) - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppcle | powerpclittle | ppc-le | powerpc-little) - basic_machine=powerpcle-unknown - ;; - ppcle-* | powerpclittle-*) - basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64) basic_machine=powerpc64-unknown - ;; - ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64le | powerpc64little | ppc64-le | powerpc64-little) - basic_machine=powerpc64le-unknown - ;; - ppc64le-* | powerpc64little-*) - basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ps2) - basic_machine=i386-ibm - ;; - pw32) - basic_machine=i586-unknown - os=-pw32 - ;; - rdos) - basic_machine=i386-pc - os=-rdos - ;; - rom68k) - basic_machine=m68k-rom68k - os=-coff - ;; - rm[46]00) - basic_machine=mips-siemens - ;; - rtpc | rtpc-*) - basic_machine=romp-ibm - ;; - s390 | s390-*) - basic_machine=s390-ibm - ;; - s390x | s390x-*) - basic_machine=s390x-ibm - ;; - sa29200) - basic_machine=a29k-amd - os=-udi - ;; - sb1) - basic_machine=mipsisa64sb1-unknown - ;; - sb1el) - basic_machine=mipsisa64sb1el-unknown - ;; - sde) - basic_machine=mipsisa32-sde - os=-elf - ;; - sei) - basic_machine=mips-sei - os=-seiux - ;; - sequent) - basic_machine=i386-sequent - ;; - sh) - basic_machine=sh-hitachi - os=-hms - ;; - sh5el) - basic_machine=sh5le-unknown - ;; - sh64) - basic_machine=sh64-unknown - ;; - sparclite-wrs | simso-wrs) - basic_machine=sparclite-wrs - os=-vxworks - ;; - sps7) - basic_machine=m68k-bull - os=-sysv2 - ;; - spur) - basic_machine=spur-unknown - ;; - st2000) - basic_machine=m68k-tandem - ;; - stratus) - basic_machine=i860-stratus - os=-sysv4 - ;; - strongarm-* | thumb-*) - basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - sun2) - basic_machine=m68000-sun - ;; - sun2os3) - basic_machine=m68000-sun - os=-sunos3 - ;; - sun2os4) - basic_machine=m68000-sun - os=-sunos4 - ;; - sun3os3) - basic_machine=m68k-sun - os=-sunos3 - ;; - sun3os4) - basic_machine=m68k-sun - os=-sunos4 - ;; - sun4os3) - basic_machine=sparc-sun - os=-sunos3 - ;; - sun4os4) - basic_machine=sparc-sun - os=-sunos4 - ;; - sun4sol2) - basic_machine=sparc-sun - os=-solaris2 - ;; - sun3 | sun3-*) - basic_machine=m68k-sun - ;; - sun4) - basic_machine=sparc-sun - ;; - sun386 | sun386i | roadrunner) - basic_machine=i386-sun - ;; - sv1) - basic_machine=sv1-cray - os=-unicos - ;; - symmetry) - basic_machine=i386-sequent - os=-dynix - ;; - t3e) - basic_machine=alphaev5-cray - os=-unicos - ;; - t90) - basic_machine=t90-cray - os=-unicos - ;; - # This must be matched before tile*. - tilegx*) - basic_machine=tilegx-unknown - os=-linux-gnu - ;; - tile*) - basic_machine=tile-unknown - os=-linux-gnu - ;; - tx39) - basic_machine=mipstx39-unknown - ;; - tx39el) - basic_machine=mipstx39el-unknown - ;; - toad1) - basic_machine=pdp10-xkl - os=-tops20 - ;; - tower | tower-32) - basic_machine=m68k-ncr - ;; - tpf) - basic_machine=s390x-ibm - os=-tpf - ;; - udi29k) - basic_machine=a29k-amd - os=-udi - ;; - ultra3) - basic_machine=a29k-nyu - os=-sym1 - ;; - v810 | necv810) - basic_machine=v810-nec - os=-none - ;; - vaxv) - basic_machine=vax-dec - os=-sysv - ;; - vms) - basic_machine=vax-dec - os=-vms - ;; - vpp*|vx|vx-*) - basic_machine=f301-fujitsu - ;; - vxworks960) - basic_machine=i960-wrs - os=-vxworks - ;; - vxworks68) - basic_machine=m68k-wrs - os=-vxworks - ;; - vxworks29k) - basic_machine=a29k-wrs - os=-vxworks - ;; - w65*) - basic_machine=w65-wdc - os=-none - ;; - w89k-*) - basic_machine=hppa1.1-winbond - os=-proelf - ;; - xbox) - basic_machine=i686-pc - os=-mingw32 - ;; - xps | xps100) - basic_machine=xps100-honeywell - ;; - xscale-* | xscalee[bl]-*) - basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` - ;; - ymp) - basic_machine=ymp-cray - os=-unicos - ;; - z8k-*-coff) - basic_machine=z8k-unknown - os=-sim - ;; - z80-*-coff) - basic_machine=z80-unknown - os=-sim - ;; - none) - basic_machine=none-none - os=-none - ;; - -# Here we handle the default manufacturer of certain CPU types. It is in -# some cases the only manufacturer, in others, it is the most popular. - w89k) - basic_machine=hppa1.1-winbond - ;; - op50n) - basic_machine=hppa1.1-oki - ;; - op60c) - basic_machine=hppa1.1-oki - ;; - romp) - basic_machine=romp-ibm - ;; - mmix) - basic_machine=mmix-knuth - ;; - rs6000) - basic_machine=rs6000-ibm - ;; - vax) - basic_machine=vax-dec - ;; - pdp10) - # there are many clones, so DEC is not a safe bet - basic_machine=pdp10-unknown - ;; - pdp11) - basic_machine=pdp11-dec - ;; - we32k) - basic_machine=we32k-att - ;; - sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) - basic_machine=sh-unknown - ;; - sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) - basic_machine=sparc-sun - ;; - cydra) - basic_machine=cydra-cydrome - ;; - orion) - basic_machine=orion-highlevel - ;; - orion105) - basic_machine=clipper-highlevel - ;; - mac | mpw | mac-mpw) - basic_machine=m68k-apple - ;; - pmac | pmac-mpw) - basic_machine=powerpc-apple - ;; - *-unknown) - # Make sure to match an already-canonicalized machine name. - ;; - *) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; -esac - -# Here we canonicalize certain aliases for manufacturers. -case $basic_machine in - *-digital*) - basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` - ;; - *-commodore*) - basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` - ;; - *) - ;; -esac - -# Decode manufacturer-specific aliases for certain operating systems. - -if [ x"$os" != x"" ] -then -case $os in - # First match some system type aliases - # that might get confused with valid system types. - # -solaris* is a basic system type, with this one exception. - -auroraux) - os=-auroraux - ;; - -solaris1 | -solaris1.*) - os=`echo $os | sed -e 's|solaris1|sunos4|'` - ;; - -solaris) - os=-solaris2 - ;; - -svr4*) - os=-sysv4 - ;; - -unixware*) - os=-sysv4.2uw - ;; - -gnu/linux*) - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` - ;; - # First accept the basic system types. - # The portable systems comes first. - # Each alternative MUST END IN A *, to match a version number. - # -sysv* is not here because it comes later, after sysvr4. - -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ - | -sym* | -kopensolaris* \ - | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* | -aros* \ - | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ - | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ - | -openbsd* | -solidbsd* \ - | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ - | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ - | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ - | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* | -cegcc* \ - | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-android* \ - | -linux-newlib* | -linux-uclibc* \ - | -uxpv* | -beos* | -mpeix* | -udk* \ - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ - | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ - | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ - | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ - | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) - # Remember, each alternative MUST END IN *, to match a version number. - ;; - -qnx*) - case $basic_machine in - x86-* | i*86-*) - ;; - *) - os=-nto$os - ;; - esac - ;; - -nto-qnx*) - ;; - -nto*) - os=`echo $os | sed -e 's|nto|nto-qnx|'` - ;; - -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ - | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ - | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) - ;; - -mac*) - os=`echo $os | sed -e 's|mac|macos|'` - ;; - -linux-dietlibc) - os=-linux-dietlibc - ;; - -linux*) - os=`echo $os | sed -e 's|linux|linux-gnu|'` - ;; - -sunos5*) - os=`echo $os | sed -e 's|sunos5|solaris2|'` - ;; - -sunos6*) - os=`echo $os | sed -e 's|sunos6|solaris3|'` - ;; - -opened*) - os=-openedition - ;; - -os400*) - os=-os400 - ;; - -wince*) - os=-wince - ;; - -osfrose*) - os=-osfrose - ;; - -osf*) - os=-osf - ;; - -utek*) - os=-bsd - ;; - -dynix*) - os=-bsd - ;; - -acis*) - os=-aos - ;; - -atheos*) - os=-atheos - ;; - -syllable*) - os=-syllable - ;; - -386bsd) - os=-bsd - ;; - -ctix* | -uts*) - os=-sysv - ;; - -nova*) - os=-rtmk-nova - ;; - -ns2 ) - os=-nextstep2 - ;; - -nsk*) - os=-nsk - ;; - # Preserve the version number of sinix5. - -sinix5.*) - os=`echo $os | sed -e 's|sinix|sysv|'` - ;; - -sinix*) - os=-sysv4 - ;; - -tpf*) - os=-tpf - ;; - -triton*) - os=-sysv3 - ;; - -oss*) - os=-sysv3 - ;; - -svr4) - os=-sysv4 - ;; - -svr3) - os=-sysv3 - ;; - -sysvr4) - os=-sysv4 - ;; - # This must come after -sysvr4. - -sysv*) - ;; - -ose*) - os=-ose - ;; - -es1800*) - os=-ose - ;; - -xenix) - os=-xenix - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - os=-mint - ;; - -aros*) - os=-aros - ;; - -kaos*) - os=-kaos - ;; - -zvmoe) - os=-zvmoe - ;; - -dicos*) - os=-dicos - ;; - -nacl*) - ;; - -none) - ;; - *) - # Get rid of the `-' at the beginning of $os. - os=`echo $os | sed 's/[^-]*-//'` - echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 - exit 1 - ;; -esac -else - -# Here we handle the default operating systems that come with various machines. -# The value should be what the vendor currently ships out the door with their -# machine or put another way, the most popular os provided with the machine. - -# Note that if you're going to try to match "-MANUFACTURER" here (say, -# "-sun"), then you have to tell the case statement up towards the top -# that MANUFACTURER isn't an operating system. Otherwise, code above -# will signal an error saying that MANUFACTURER isn't an operating -# system, and we'll never get to this point. - -case $basic_machine in - score-*) - os=-elf - ;; - spu-*) - os=-elf - ;; - *-acorn) - os=-riscix1.2 - ;; - arm*-rebel) - os=-linux - ;; - arm*-semi) - os=-aout - ;; - c4x-* | tic4x-*) - os=-coff - ;; - tic54x-*) - os=-coff - ;; - tic55x-*) - os=-coff - ;; - tic6x-*) - os=-coff - ;; - # This must come before the *-dec entry. - pdp10-*) - os=-tops20 - ;; - pdp11-*) - os=-none - ;; - *-dec | vax-*) - os=-ultrix4.2 - ;; - m68*-apollo) - os=-domain - ;; - i386-sun) - os=-sunos4.0.2 - ;; - m68000-sun) - os=-sunos3 - # This also exists in the configure program, but was not the - # default. - # os=-sunos4 - ;; - m68*-cisco) - os=-aout - ;; - mep-*) - os=-elf - ;; - mips*-cisco) - os=-elf - ;; - mips*-*) - os=-elf - ;; - or32-*) - os=-coff - ;; - *-tti) # must be before sparc entry or we get the wrong os. - os=-sysv3 - ;; - sparc-* | *-sun) - os=-sunos4.1.1 - ;; - *-be) - os=-beos - ;; - *-haiku) - os=-haiku - ;; - *-ibm) - os=-aix - ;; - *-knuth) - os=-mmixware - ;; - *-wec) - os=-proelf - ;; - *-winbond) - os=-proelf - ;; - *-oki) - os=-proelf - ;; - *-hp) - os=-hpux - ;; - *-hitachi) - os=-hiux - ;; - i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) - os=-sysv - ;; - *-cbm) - os=-amigaos - ;; - *-dg) - os=-dgux - ;; - *-dolphin) - os=-sysv3 - ;; - m68k-ccur) - os=-rtu - ;; - m88k-omron*) - os=-luna - ;; - *-next ) - os=-nextstep - ;; - *-sequent) - os=-ptx - ;; - *-crds) - os=-unos - ;; - *-ns) - os=-genix - ;; - i370-*) - os=-mvs - ;; - *-next) - os=-nextstep3 - ;; - *-gould) - os=-sysv - ;; - *-highlevel) - os=-bsd - ;; - *-encore) - os=-bsd - ;; - *-sgi) - os=-irix - ;; - *-siemens) - os=-sysv4 - ;; - *-masscomp) - os=-rtu - ;; - f30[01]-fujitsu | f700-fujitsu) - os=-uxpv - ;; - *-rom68k) - os=-coff - ;; - *-*bug) - os=-coff - ;; - *-apple) - os=-macos - ;; - *-atari*) - os=-mint - ;; - *) - os=-none - ;; -esac -fi - -# Here we handle the case where we know the os, and the CPU type, but not the -# manufacturer. We pick the logical manufacturer. -vendor=unknown -case $basic_machine in - *-unknown) - case $os in - -riscix*) - vendor=acorn - ;; - -sunos*) - vendor=sun - ;; - -cnk*|-aix*) - vendor=ibm - ;; - -beos*) - vendor=be - ;; - -hpux*) - vendor=hp - ;; - -mpeix*) - vendor=hp - ;; - -hiux*) - vendor=hitachi - ;; - -unos*) - vendor=crds - ;; - -dgux*) - vendor=dg - ;; - -luna*) - vendor=omron - ;; - -genix*) - vendor=ns - ;; - -mvs* | -opened*) - vendor=ibm - ;; - -os400*) - vendor=ibm - ;; - -ptx*) - vendor=sequent - ;; - -tpf*) - vendor=ibm - ;; - -vxsim* | -vxworks* | -windiss*) - vendor=wrs - ;; - -aux*) - vendor=apple - ;; - -hms*) - vendor=hitachi - ;; - -mpw* | -macos*) - vendor=apple - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - vendor=atari - ;; - -vos*) - vendor=stratus - ;; - esac - basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` - ;; -esac - -echo $basic_machine$os -exit - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/expat/conftools/expat.m4 b/lib-src/expat/conftools/expat.m4 deleted file mode 100644 index 57e579b30..000000000 --- a/lib-src/expat/conftools/expat.m4 +++ /dev/null @@ -1,43 +0,0 @@ -dnl Check if --with-expat[=PREFIX] is specified and -dnl Expat >= 1.95.0 is installed in the system. -dnl If yes, substitute EXPAT_CFLAGS, EXPAT_LIBS with regard to -dnl the specified PREFIX and set with_expat to PREFIX, or 'yes' if PREFIX -dnl has not been specified. Also HAVE_LIBEXPAT, HAVE_EXPAT_H are defined. -dnl If --with-expat has not been specified, set with_expat to 'no'. -dnl In addition, an Automake conditional EXPAT_INSTALLED is set accordingly. -dnl This is necessary to adapt a whole lot of packages that have expat -dnl bundled as a static library. -AC_DEFUN([AM_WITH_EXPAT], -[ AC_ARG_WITH(expat, - [ --with-expat=PREFIX Use system Expat library], - , with_expat=no) - - AM_CONDITIONAL(EXPAT_INSTALLED, test $with_expat != no) - - EXPAT_CFLAGS= - EXPAT_LIBS= - if test $with_expat != no; then - if test $with_expat != yes; then - EXPAT_CFLAGS="-I$with_expat/include" - EXPAT_LIBS="-L$with_expat/lib" - fi - AC_CHECK_LIB(expat, XML_ParserCreate, - [ EXPAT_LIBS="$EXPAT_LIBS -lexpat" - expat_found=yes ], - [ expat_found=no ], - "$EXPAT_LIBS") - if test $expat_found = no; then - AC_MSG_ERROR([Could not find the Expat library]) - fi - expat_save_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS $EXPAT_CFLAGS" - AC_CHECK_HEADERS(expat.h, , expat_found=no) - if test $expat_found = no; then - AC_MSG_ERROR([Could not find expat.h]) - fi - CFLAGS="$expat_save_CFLAGS" - fi - - AC_SUBST(EXPAT_CFLAGS) - AC_SUBST(EXPAT_LIBS) -]) diff --git a/lib-src/expat/conftools/get-version.sh b/lib-src/expat/conftools/get-version.sh deleted file mode 100755 index a70e0fb47..000000000 --- a/lib-src/expat/conftools/get-version.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/sh -# -# USAGE: get-version.sh path/to/expat.h -# -# This script will print Expat's version number on stdout. For example: -# -# $ ./conftools/get-version.sh ./lib/expat.h -# 1.95.3 -# $ -# - -if test $# = 0; then - echo "ERROR: pathname for expat.h was not provided." - echo "" - echo "USAGE: $0 path/to/expat.h" - exit 1 -fi -if test $# != 1; then - echo "ERROR: too many arguments were provided." - echo "" - echo "USAGE: $0 path/to/expat.h" - exit 1 -fi - -hdr="$1" -if test ! -r "$hdr"; then - echo "ERROR: '$hdr' does not exist, or is not readable." - exit 1 -fi - -MAJOR_VERSION="`sed -n -e '/MAJOR_VERSION/s/[^0-9]*//gp' $hdr`" -MINOR_VERSION="`sed -n -e '/MINOR_VERSION/s/[^0-9]*//gp' $hdr`" -MICRO_VERSION="`sed -n -e '/MICRO_VERSION/s/[^0-9]*//gp' $hdr`" - -# Determine how to tell echo not to print the trailing \n. This is -# similar to Autoconf's @ECHO_C@ and @ECHO_N@; however, we don't -# generate this file via autoconf (in fact, get-version.sh is used -# to *create* ./configure), so we just do something similar inline. -case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in - *c*,-n*) ECHO_N= ECHO_C=' -' ;; - *c*,* ) ECHO_N=-n ECHO_C= ;; - *) ECHO_N= ECHO_C='\c' ;; -esac - -echo $ECHO_N "$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$ECHO_C" diff --git a/lib-src/expat/conftools/install-sh b/lib-src/expat/conftools/install-sh deleted file mode 100755 index 6781b987b..000000000 --- a/lib-src/expat/conftools/install-sh +++ /dev/null @@ -1,520 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2009-04-28.21; # UTC - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# `make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. - -nl=' -' -IFS=" "" $nl" - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit=${DOITPROG-} -if test -z "$doit"; then - doit_exec=exec -else - doit_exec=$doit -fi - -# Put in absolute file names if you don't have them in your path; -# or use environment vars. - -chgrpprog=${CHGRPPROG-chgrp} -chmodprog=${CHMODPROG-chmod} -chownprog=${CHOWNPROG-chown} -cmpprog=${CMPPROG-cmp} -cpprog=${CPPROG-cp} -mkdirprog=${MKDIRPROG-mkdir} -mvprog=${MVPROG-mv} -rmprog=${RMPROG-rm} -stripprog=${STRIPPROG-strip} - -posix_glob='?' -initialize_posix_glob=' - test "$posix_glob" != "?" || { - if (set -f) 2>/dev/null; then - posix_glob= - else - posix_glob=: - fi - } -' - -posix_mkdir= - -# Desired mode of installed file. -mode=0755 - -chgrpcmd= -chmodcmd=$chmodprog -chowncmd= -mvcmd=$mvprog -rmcmd="$rmprog -f" -stripcmd= - -src= -dst= -dir_arg= -dst_arg= - -copy_on_change=false -no_target_directory= - -usage="\ -Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: - --help display this help and exit. - --version display version info and exit. - - -c (ignored) - -C install only if different (preserve the last data modification time) - -d create directories instead of installing files. - -g GROUP $chgrpprog installed files to GROUP. - -m MODE $chmodprog installed files to MODE. - -o USER $chownprog installed files to USER. - -s $stripprog installed files. - -t DIRECTORY install into DIRECTORY. - -T report an error if DSTFILE is a directory. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG - RMPROG STRIPPROG -" - -while test $# -ne 0; do - case $1 in - -c) ;; - - -C) copy_on_change=true;; - - -d) dir_arg=true;; - - -g) chgrpcmd="$chgrpprog $2" - shift;; - - --help) echo "$usage"; exit $?;; - - -m) mode=$2 - case $mode in - *' '* | *' '* | *' -'* | *'*'* | *'?'* | *'['*) - echo "$0: invalid mode: $mode" >&2 - exit 1;; - esac - shift;; - - -o) chowncmd="$chownprog $2" - shift;; - - -s) stripcmd=$stripprog;; - - -t) dst_arg=$2 - shift;; - - -T) no_target_directory=true;; - - --version) echo "$0 $scriptversion"; exit $?;; - - --) shift - break;; - - -*) echo "$0: invalid option: $1" >&2 - exit 1;; - - *) break;; - esac - shift -done - -if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then - # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dst_arg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dst_arg" - shift # fnord - fi - shift # arg - dst_arg=$arg - done -fi - -if test $# -eq 0; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call `install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -if test -z "$dir_arg"; then - trap '(exit $?); exit' 1 2 13 15 - - # Set umask so as not to create temps with too-generous modes. - # However, 'strip' requires both read and write access to temps. - case $mode in - # Optimize common cases. - *644) cp_umask=133;; - *755) cp_umask=22;; - - *[0-7]) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw='% 200' - fi - cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; - *) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw=,u+rw - fi - cp_umask=$mode$u_plus_rw;; - esac -fi - -for src -do - # Protect names starting with `-'. - case $src in - -*) src=./$src;; - esac - - if test -n "$dir_arg"; then - dst=$src - dstdir=$dst - test -d "$dstdir" - dstdir_status=$? - else - - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dst_arg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - - dst=$dst_arg - # Protect names starting with `-'. - case $dst in - -*) dst=./$dst;; - esac - - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. - if test -d "$dst"; then - if test -n "$no_target_directory"; then - echo "$0: $dst_arg: Is a directory" >&2 - exit 1 - fi - dstdir=$dst - dst=$dstdir/`basename "$src"` - dstdir_status=0 - else - # Prefer dirname, but fall back on a substitute if dirname fails. - dstdir=` - (dirname "$dst") 2>/dev/null || - expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$dst" : 'X\(//\)[^/]' \| \ - X"$dst" : 'X\(//\)$' \| \ - X"$dst" : 'X\(/\)' \| . 2>/dev/null || - echo X"$dst" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q' - ` - - test -d "$dstdir" - dstdir_status=$? - fi - fi - - obsolete_mkdir_used=false - - if test $dstdir_status != 0; then - case $posix_mkdir in - '') - # Create intermediate dirs using mode 755 as modified by the umask. - # This is like FreeBSD 'install' as of 1997-10-28. - umask=`umask` - case $stripcmd.$umask in - # Optimize common cases. - *[2367][2367]) mkdir_umask=$umask;; - .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; - - *[0-7]) - mkdir_umask=`expr $umask + 22 \ - - $umask % 100 % 40 + $umask % 20 \ - - $umask % 10 % 4 + $umask % 2 - `;; - *) mkdir_umask=$umask,go-w;; - esac - - # With -d, create the new directory with the user-specified mode. - # Otherwise, rely on $mkdir_umask. - if test -n "$dir_arg"; then - mkdir_mode=-m$mode - else - mkdir_mode= - fi - - posix_mkdir=false - case $umask in - *[123567][0-7][0-7]) - # POSIX mkdir -p sets u+wx bits regardless of umask, which - # is incompatible with FreeBSD 'install' when (umask & 300) != 0. - ;; - *) - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 - - if (umask $mkdir_umask && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 - then - if test -z "$dir_arg" || { - # Check for POSIX incompatibilities with -m. - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or - # other-writeable bit of parent directory when it shouldn't. - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. - ls_ld_tmpdir=`ls -ld "$tmpdir"` - case $ls_ld_tmpdir in - d????-?r-*) different_mode=700;; - d????-?--*) different_mode=755;; - *) false;; - esac && - $mkdirprog -m$different_mode -p -- "$tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$tmpdir"` - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" - } - } - then posix_mkdir=: - fi - rmdir "$tmpdir/d" "$tmpdir" - else - # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null - fi - trap '' 0;; - esac;; - esac - - if - $posix_mkdir && ( - umask $mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" - ) - then : - else - - # The umask is ridiculous, or mkdir does not conform to POSIX, - # or it failed possibly due to a race condition. Create the - # directory the slow way, step by step, checking for races as we go. - - case $dstdir in - /*) prefix='/';; - -*) prefix='./';; - *) prefix='';; - esac - - eval "$initialize_posix_glob" - - oIFS=$IFS - IFS=/ - $posix_glob set -f - set fnord $dstdir - shift - $posix_glob set +f - IFS=$oIFS - - prefixes= - - for d - do - test -z "$d" && continue - - prefix=$prefix$d - if test -d "$prefix"; then - prefixes= - else - if $posix_mkdir; then - (umask=$mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break - # Don't fail if two instances are running concurrently. - test -d "$prefix" || exit 1 - else - case $prefix in - *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; - *) qprefix=$prefix;; - esac - prefixes="$prefixes '$qprefix'" - fi - fi - prefix=$prefix/ - done - - if test -n "$prefixes"; then - # Don't fail if two instances are running concurrently. - (umask $mkdir_umask && - eval "\$doit_exec \$mkdirprog $prefixes") || - test -d "$dstdir" || exit 1 - obsolete_mkdir_used=true - fi - fi - fi - - if test -n "$dir_arg"; then - { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && - { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || - test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 - else - - # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - - # Copy the file name to the temp name. - (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && - { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && - { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && - - # If -C, don't bother to copy if it wouldn't change the file. - if $copy_on_change && - old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && - new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && - - eval "$initialize_posix_glob" && - $posix_glob set -f && - set X $old && old=:$2:$4:$5:$6 && - set X $new && new=:$2:$4:$5:$6 && - $posix_glob set +f && - - test "$old" = "$new" && - $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 - then - rm -f "$dsttmp" - else - # Rename the file to the real destination. - $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || - - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - { - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - test ! -f "$dst" || - $doit $rmcmd -f "$dst" 2>/dev/null || - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && - { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } - } || - { echo "$0: cannot unlink or rename $dst" >&2 - (exit 1); exit 1 - } - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dst" - } - fi || exit 1 - - trap '' 0 - fi -done - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/expat/conftools/ltmain.sh b/lib-src/expat/conftools/ltmain.sh deleted file mode 100755 index a356acafa..000000000 --- a/lib-src/expat/conftools/ltmain.sh +++ /dev/null @@ -1,9661 +0,0 @@ - -# libtool (GNU libtool) 2.4.2 -# Written by Gordon Matzigkeit , 1996 - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, -# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, -# or obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - -# Usage: $progname [OPTION]... [MODE-ARG]... -# -# Provide generalized library-building support services. -# -# --config show all configuration variables -# --debug enable verbose shell tracing -# -n, --dry-run display commands without modifying any files -# --features display basic configuration information and exit -# --mode=MODE use operation mode MODE -# --preserve-dup-deps don't remove duplicate dependency libraries -# --quiet, --silent don't print informational messages -# --no-quiet, --no-silent -# print informational messages (default) -# --no-warn don't display warning messages -# --tag=TAG use configuration variables from tag TAG -# -v, --verbose print more informational messages than default -# --no-verbose don't print the extra informational messages -# --version print version information -# -h, --help, --help-all print short, long, or detailed help message -# -# MODE must be one of the following: -# -# clean remove files from the build directory -# compile compile a source file into a libtool object -# execute automatically set library path, then run a program -# finish complete the installation of libtool libraries -# install install libraries or executables -# link create a library or an executable -# uninstall remove libraries from an installed directory -# -# MODE-ARGS vary depending on the MODE. When passed as first option, -# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. -# Try `$progname --help --mode=MODE' for a more detailed description of MODE. -# -# When reporting a bug, please describe a test case to reproduce it and -# include the following information: -# -# host-triplet: $host -# shell: $SHELL -# compiler: $LTCC -# compiler flags: $LTCFLAGS -# linker: $LD (gnu? $with_gnu_ld) -# $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.7ubuntu1 -# automake: $automake_version -# autoconf: $autoconf_version -# -# Report bugs to . -# GNU libtool home page: . -# General help using GNU software: . - -PROGRAM=libtool -PACKAGE=libtool -VERSION="2.4.2 Debian-2.4.2-1.7ubuntu1" -TIMESTAMP="" -package_revision=1.3337 - -# Be Bourne compatible -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' -} - -# NLS nuisances: We save the old values to restore during execute mode. -lt_user_locale= -lt_safe_locale= -for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES -do - eval "if test \"\${$lt_var+set}\" = set; then - save_$lt_var=\$$lt_var - $lt_var=C - export $lt_var - lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" - lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" - fi" -done -LC_ALL=C -LANGUAGE=C -export LANGUAGE LC_ALL - -$lt_unset CDPATH - - -# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh -# is ksh but when the shell is invoked as "sh" and the current value of -# the _XPG environment variable is not equal to 1 (one), the special -# positional parameter $0, within a function call, is the name of the -# function. -progpath="$0" - - - -: ${CP="cp -f"} -test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} -: ${MAKE="make"} -: ${MKDIR="mkdir"} -: ${MV="mv -f"} -: ${RM="rm -f"} -: ${SHELL="${CONFIG_SHELL-/bin/sh}"} -: ${Xsed="$SED -e 1s/^X//"} - -# Global variables: -EXIT_SUCCESS=0 -EXIT_FAILURE=1 -EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. -EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. - -exit_status=$EXIT_SUCCESS - -# Make sure IFS has a sensible default -lt_nl=' -' -IFS=" $lt_nl" - -dirname="s,/[^/]*$,," -basename="s,^.*/,," - -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi -} # func_dirname may be replaced by extended shell implementation - - -# func_basename file -func_basename () -{ - func_basename_result=`$ECHO "${1}" | $SED "$basename"` -} # func_basename may be replaced by extended shell implementation - - -# func_dirname_and_basename file append nondir_replacement -# perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# Implementation must be kept synchronized with func_dirname -# and func_basename. For efficiency, we do not delegate to -# those functions but instead duplicate the functionality here. -func_dirname_and_basename () -{ - # Extract subdirectory from the argument. - func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi - func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` -} # func_dirname_and_basename may be replaced by extended shell implementation - - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# func_strip_suffix prefix name -func_stripname () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname may be replaced by extended shell implementation - - -# These SED scripts presuppose an absolute path with a trailing slash. -pathcar='s,^/\([^/]*\).*$,\1,' -pathcdr='s,^/[^/]*,,' -removedotparts=':dotsl - s@/\./@/@g - t dotsl - s,/\.$,/,' -collapseslashes='s@/\{1,\}@/@g' -finalslash='s,/*$,/,' - -# func_normal_abspath PATH -# Remove doubled-up and trailing slashes, "." path components, -# and cancel out any ".." path components in PATH after making -# it an absolute path. -# value returned in "$func_normal_abspath_result" -func_normal_abspath () -{ - # Start from root dir and reassemble the path. - func_normal_abspath_result= - func_normal_abspath_tpath=$1 - func_normal_abspath_altnamespace= - case $func_normal_abspath_tpath in - "") - # Empty path, that just means $cwd. - func_stripname '' '/' "`pwd`" - func_normal_abspath_result=$func_stripname_result - return - ;; - # The next three entries are used to spot a run of precisely - # two leading slashes without using negated character classes; - # we take advantage of case's first-match behaviour. - ///*) - # Unusual form of absolute path, do nothing. - ;; - //*) - # Not necessarily an ordinary path; POSIX reserves leading '//' - # and for example Cygwin uses it to access remote file shares - # over CIFS/SMB, so we conserve a leading double slash if found. - func_normal_abspath_altnamespace=/ - ;; - /*) - # Absolute path, do nothing. - ;; - *) - # Relative path, prepend $cwd. - func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath - ;; - esac - # Cancel out all the simple stuff to save iterations. We also want - # the path to end with a slash for ease of parsing, so make sure - # there is one (and only one) here. - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` - while :; do - # Processed it all yet? - if test "$func_normal_abspath_tpath" = / ; then - # If we ascended to the root using ".." the result may be empty now. - if test -z "$func_normal_abspath_result" ; then - func_normal_abspath_result=/ - fi - break - fi - func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcar"` - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcdr"` - # Figure out what to do with it - case $func_normal_abspath_tcomponent in - "") - # Trailing empty path component, ignore it. - ;; - ..) - # Parent dir; strip last assembled component from result. - func_dirname "$func_normal_abspath_result" - func_normal_abspath_result=$func_dirname_result - ;; - *) - # Actual path component, append it. - func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent - ;; - esac - done - # Restore leading double-slash if one was found on entry. - func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result -} - -# func_relative_path SRCDIR DSTDIR -# generates a relative path from SRCDIR to DSTDIR, with a trailing -# slash if non-empty, suitable for immediately appending a filename -# without needing to append a separator. -# value returned in "$func_relative_path_result" -func_relative_path () -{ - func_relative_path_result= - func_normal_abspath "$1" - func_relative_path_tlibdir=$func_normal_abspath_result - func_normal_abspath "$2" - func_relative_path_tbindir=$func_normal_abspath_result - - # Ascend the tree starting from libdir - while :; do - # check if we have found a prefix of bindir - case $func_relative_path_tbindir in - $func_relative_path_tlibdir) - # found an exact match - func_relative_path_tcancelled= - break - ;; - $func_relative_path_tlibdir*) - # found a matching prefix - func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" - func_relative_path_tcancelled=$func_stripname_result - if test -z "$func_relative_path_result"; then - func_relative_path_result=. - fi - break - ;; - *) - func_dirname $func_relative_path_tlibdir - func_relative_path_tlibdir=${func_dirname_result} - if test "x$func_relative_path_tlibdir" = x ; then - # Have to descend all the way to the root! - func_relative_path_result=../$func_relative_path_result - func_relative_path_tcancelled=$func_relative_path_tbindir - break - fi - func_relative_path_result=../$func_relative_path_result - ;; - esac - done - - # Now calculate path; take care to avoid doubling-up slashes. - func_stripname '' '/' "$func_relative_path_result" - func_relative_path_result=$func_stripname_result - func_stripname '/' '/' "$func_relative_path_tcancelled" - if test "x$func_stripname_result" != x ; then - func_relative_path_result=${func_relative_path_result}/${func_stripname_result} - fi - - # Normalisation. If bindir is libdir, return empty string, - # else relative path ending with a slash; either way, target - # file name can be directly appended. - if test ! -z "$func_relative_path_result"; then - func_stripname './' '' "$func_relative_path_result/" - func_relative_path_result=$func_stripname_result - fi -} - -# The name of this program: -func_dirname_and_basename "$progpath" -progname=$func_basename_result - -# Make sure we have an absolute path for reexecution: -case $progpath in - [\\/]*|[A-Za-z]:\\*) ;; - *[\\/]*) - progdir=$func_dirname_result - progdir=`cd "$progdir" && pwd` - progpath="$progdir/$progname" - ;; - *) - save_IFS="$IFS" - IFS=${PATH_SEPARATOR-:} - for progdir in $PATH; do - IFS="$save_IFS" - test -x "$progdir/$progname" && break - done - IFS="$save_IFS" - test -n "$progdir" || progdir=`pwd` - progpath="$progdir/$progname" - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed="${SED}"' -e 1s/^X//' -sed_quote_subst='s/\([`"$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution that turns a string into a regex matching for the -# string literally. -sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' - -# Sed substitution that converts a w32 file name or path -# which contains forward slashes, into one that contains -# (escaped) backslashes. A very naive implementation. -lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - -# Re-`\' parameter expansions in output of double_quote_subst that were -# `\'-ed in input to the same. If an odd number of `\' preceded a '$' -# in input to double_quote_subst, that '$' was protected from expansion. -# Since each input `\' is now two `\'s, look for any number of runs of -# four `\'s followed by two `\'s and then a '$'. `\' that '$'. -bs='\\' -bs2='\\\\' -bs4='\\\\\\\\' -dollar='\$' -sed_double_backslash="\ - s/$bs4/&\\ -/g - s/^$bs2$dollar/$bs&/ - s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g - s/\n//g" - -# Standard options: -opt_dry_run=false -opt_help=false -opt_quiet=false -opt_verbose=false -opt_warning=: - -# func_echo arg... -# Echo program name prefixed message, along with the current mode -# name if it has been set yet. -func_echo () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }$*" -} - -# func_verbose arg... -# Echo program name prefixed message in verbose mode only. -func_verbose () -{ - $opt_verbose && func_echo ${1+"$@"} - - # A bug in bash halts the script if the last line of a function - # fails when set -e is in force, so we need another command to - # work around that: - : -} - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -# func_error arg... -# Echo program name prefixed message to standard error. -func_error () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 -} - -# func_warning arg... -# Echo program name prefixed warning message to standard error. -func_warning () -{ - $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 - - # bash bug again: - : -} - -# func_fatal_error arg... -# Echo program name prefixed message to standard error, and exit. -func_fatal_error () -{ - func_error ${1+"$@"} - exit $EXIT_FAILURE -} - -# func_fatal_help arg... -# Echo program name prefixed message to standard error, followed by -# a help hint, and exit. -func_fatal_help () -{ - func_error ${1+"$@"} - func_fatal_error "$help" -} -help="Try \`$progname --help' for more information." ## default - - -# func_grep expression filename -# Check whether EXPRESSION matches any line of FILENAME, without output. -func_grep () -{ - $GREP "$1" "$2" >/dev/null 2>&1 -} - - -# func_mkdir_p directory-path -# Make sure the entire path to DIRECTORY-PATH is available. -func_mkdir_p () -{ - my_directory_path="$1" - my_dir_list= - - if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then - - # Protect directory names starting with `-' - case $my_directory_path in - -*) my_directory_path="./$my_directory_path" ;; - esac - - # While some portion of DIR does not yet exist... - while test ! -d "$my_directory_path"; do - # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. - my_dir_list="$my_directory_path:$my_dir_list" - - # If the last portion added has no slash in it, the list is done - case $my_directory_path in */*) ;; *) break ;; esac - - # ...otherwise throw away the child directory and loop - my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` - done - my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` - - save_mkdir_p_IFS="$IFS"; IFS=':' - for my_dir in $my_dir_list; do - IFS="$save_mkdir_p_IFS" - # mkdir can fail with a `File exist' error if two processes - # try to create one of the directories concurrently. Don't - # stop in that case! - $MKDIR "$my_dir" 2>/dev/null || : - done - IFS="$save_mkdir_p_IFS" - - # Bail out if we (or some other process) failed to create a directory. - test -d "$my_directory_path" || \ - func_fatal_error "Failed to create \`$1'" - fi -} - - -# func_mktempdir [string] -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, STRING is the basename for that directory. -func_mktempdir () -{ - my_template="${TMPDIR-/tmp}/${1-$progname}" - - if test "$opt_dry_run" = ":"; then - # Return a directory name, but don't create it in dry-run mode - my_tmpdir="${my_template}-$$" - else - - # If mktemp works, use that first and foremost - my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` - - if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" - - save_mktempdir_umask=`umask` - umask 0077 - $MKDIR "$my_tmpdir" - umask $save_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || \ - func_fatal_error "cannot create temporary directory \`$my_tmpdir'" - fi - - $ECHO "$my_tmpdir" -} - - -# func_quote_for_eval arg -# Aesthetically quote ARG to be evaled later. -# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT -# is double-quoted, suitable for a subsequent eval, whereas -# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters -# which are still active within double quotes backslashified. -func_quote_for_eval () -{ - case $1 in - *[\\\`\"\$]*) - func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; - *) - func_quote_for_eval_unquoted_result="$1" ;; - esac - - case $func_quote_for_eval_unquoted_result in - # Double-quote args containing shell metacharacters to delay - # word splitting, command substitution and and variable - # expansion for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" - ;; - *) - func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" - esac -} - - -# func_quote_for_expand arg -# Aesthetically quote ARG to be evaled later; same as above, -# but do not quote variable references. -func_quote_for_expand () -{ - case $1 in - *[\\\`\"]*) - my_arg=`$ECHO "$1" | $SED \ - -e "$double_quote_subst" -e "$sed_double_backslash"` ;; - *) - my_arg="$1" ;; - esac - - case $my_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting and command substitution for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - my_arg="\"$my_arg\"" - ;; - esac - - func_quote_for_expand_result="$my_arg" -} - - -# func_show_eval cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. -func_show_eval () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$my_cmd" - my_status=$? - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - - -# func_show_eval_locale cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. Use the saved locale for evaluation. -func_show_eval_locale () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$lt_user_locale - $my_cmd" - my_status=$? - eval "$lt_safe_locale" - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - -# func_tr_sh -# Turn $1 into a string suitable for a shell variable name. -# Result is stored in $func_tr_sh_result. All characters -# not in the set a-zA-Z0-9_ are replaced with '_'. Further, -# if $1 begins with a digit, a '_' is prepended as well. -func_tr_sh () -{ - case $1 in - [0-9]* | *[!a-zA-Z0-9_]*) - func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` - ;; - * ) - func_tr_sh_result=$1 - ;; - esac -} - - -# func_version -# Echo version message to standard output and exit. -func_version () -{ - $opt_debug - - $SED -n '/(C)/!b go - :more - /\./!{ - N - s/\n# / / - b more - } - :go - /^# '$PROGRAM' (GNU /,/# warranty; / { - s/^# // - s/^# *$// - s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ - p - }' < "$progpath" - exit $? -} - -# func_usage -# Echo short help message to standard output and exit. -func_usage () -{ - $opt_debug - - $SED -n '/^# Usage:/,/^# *.*--help/ { - s/^# // - s/^# *$// - s/\$progname/'$progname'/ - p - }' < "$progpath" - echo - $ECHO "run \`$progname --help | more' for full usage" - exit $? -} - -# func_help [NOEXIT] -# Echo long help message to standard output and exit, -# unless 'noexit' is passed as argument. -func_help () -{ - $opt_debug - - $SED -n '/^# Usage:/,/# Report bugs to/ { - :print - s/^# // - s/^# *$// - s*\$progname*'$progname'* - s*\$host*'"$host"'* - s*\$SHELL*'"$SHELL"'* - s*\$LTCC*'"$LTCC"'* - s*\$LTCFLAGS*'"$LTCFLAGS"'* - s*\$LD*'"$LD"'* - s/\$with_gnu_ld/'"$with_gnu_ld"'/ - s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/ - s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/ - p - d - } - /^# .* home page:/b print - /^# General help using/b print - ' < "$progpath" - ret=$? - if test -z "$1"; then - exit $ret - fi -} - -# func_missing_arg argname -# Echo program name prefixed message to standard error and set global -# exit_cmd. -func_missing_arg () -{ - $opt_debug - - func_error "missing argument for $1." - exit_cmd=exit -} - - -# func_split_short_opt shortopt -# Set func_split_short_opt_name and func_split_short_opt_arg shell -# variables after splitting SHORTOPT after the 2nd character. -func_split_short_opt () -{ - my_sed_short_opt='1s/^\(..\).*$/\1/;q' - my_sed_short_rest='1s/^..\(.*\)$/\1/;q' - - func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` - func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` -} # func_split_short_opt may be replaced by extended shell implementation - - -# func_split_long_opt longopt -# Set func_split_long_opt_name and func_split_long_opt_arg shell -# variables after splitting LONGOPT at the `=' sign. -func_split_long_opt () -{ - my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' - my_sed_long_arg='1s/^--[^=]*=//' - - func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` - func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` -} # func_split_long_opt may be replaced by extended shell implementation - -exit_cmd=: - - - - - -magic="%%%MAGIC variable%%%" -magic_exe="%%%MAGIC EXE variable%%%" - -# Global variables. -nonopt= -preserve_args= -lo2o="s/\\.lo\$/.${objext}/" -o2lo="s/\\.${objext}\$/.lo/" -extracted_archives= -extracted_serial=0 - -# If this variable is set in any of the actions, the command in it -# will be execed at the end. This prevents here-documents from being -# left over by shells. -exec_cmd= - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "${1}=\$${1}\${2}" -} # func_append may be replaced by extended shell implementation - -# func_append_quoted var value -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -func_append_quoted () -{ - func_quote_for_eval "${2}" - eval "${1}=\$${1}\\ \$func_quote_for_eval_result" -} # func_append_quoted may be replaced by extended shell implementation - - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "${@}"` -} # func_arith may be replaced by extended shell implementation - - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` -} # func_len may be replaced by extended shell implementation - - -# func_lo2o object -func_lo2o () -{ - func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` -} # func_lo2o may be replaced by extended shell implementation - - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` -} # func_xform may be replaced by extended shell implementation - - -# func_fatal_configuration arg... -# Echo program name prefixed message to standard error, followed by -# a configuration failure hint, and exit. -func_fatal_configuration () -{ - func_error ${1+"$@"} - func_error "See the $PACKAGE documentation for more information." - func_fatal_error "Fatal configuration error." -} - - -# func_config -# Display the configuration for all the tags in this script. -func_config () -{ - re_begincf='^# ### BEGIN LIBTOOL' - re_endcf='^# ### END LIBTOOL' - - # Default configuration. - $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" - - # Now print the configurations for the tags. - for tagname in $taglist; do - $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" - done - - exit $? -} - -# func_features -# Display the features supported by this script. -func_features () -{ - echo "host: $host" - if test "$build_libtool_libs" = yes; then - echo "enable shared libraries" - else - echo "disable shared libraries" - fi - if test "$build_old_libs" = yes; then - echo "enable static libraries" - else - echo "disable static libraries" - fi - - exit $? -} - -# func_enable_tag tagname -# Verify that TAGNAME is valid, and either flag an error and exit, or -# enable the TAGNAME tag. We also add TAGNAME to the global $taglist -# variable here. -func_enable_tag () -{ - # Global variable: - tagname="$1" - - re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" - re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" - sed_extractcf="/$re_begincf/,/$re_endcf/p" - - # Validate tagname. - case $tagname in - *[!-_A-Za-z0-9,/]*) - func_fatal_error "invalid tag name: $tagname" - ;; - esac - - # Don't test for the "default" C tag, as we know it's - # there but not specially marked. - case $tagname in - CC) ;; - *) - if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then - taglist="$taglist $tagname" - - # Evaluate the configuration. Be careful to quote the path - # and the sed script, to avoid splitting on whitespace, but - # also don't use non-portable quotes within backquotes within - # quotes we have to do it in 2 steps: - extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` - eval "$extractedcf" - else - func_error "ignoring unknown tag $tagname" - fi - ;; - esac -} - -# func_check_version_match -# Ensure that we are using m4 macros, and libtool script from the same -# release of libtool. -func_check_version_match () -{ - if test "$package_revision" != "$macro_revision"; then - if test "$VERSION" != "$macro_version"; then - if test -z "$macro_version"; then - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from an older release. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - fi - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, -$progname: but the definition of this LT_INIT comes from revision $macro_revision. -$progname: You should recreate aclocal.m4 with macros from revision $package_revision -$progname: of $PACKAGE $VERSION and run autoconf again. -_LT_EOF - fi - - exit $EXIT_MISMATCH - fi -} - - -# Shorthand for --mode=foo, only valid as the first argument -case $1 in -clean|clea|cle|cl) - shift; set dummy --mode clean ${1+"$@"}; shift - ;; -compile|compil|compi|comp|com|co|c) - shift; set dummy --mode compile ${1+"$@"}; shift - ;; -execute|execut|execu|exec|exe|ex|e) - shift; set dummy --mode execute ${1+"$@"}; shift - ;; -finish|finis|fini|fin|fi|f) - shift; set dummy --mode finish ${1+"$@"}; shift - ;; -install|instal|insta|inst|ins|in|i) - shift; set dummy --mode install ${1+"$@"}; shift - ;; -link|lin|li|l) - shift; set dummy --mode link ${1+"$@"}; shift - ;; -uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) - shift; set dummy --mode uninstall ${1+"$@"}; shift - ;; -esac - - - -# Option defaults: -opt_debug=: -opt_dry_run=false -opt_config=false -opt_preserve_dup_deps=false -opt_features=false -opt_finish=false -opt_help=false -opt_help_all=false -opt_silent=: -opt_warning=: -opt_verbose=: -opt_silent=false -opt_verbose=false - - -# Parse options once, thoroughly. This comes as soon as possible in the -# script to make things like `--version' happen as quickly as we can. -{ - # this just eases exit handling - while test $# -gt 0; do - opt="$1" - shift - case $opt in - --debug|-x) opt_debug='set -x' - func_echo "enabling shell trace mode" - $opt_debug - ;; - --dry-run|--dryrun|-n) - opt_dry_run=: - ;; - --config) - opt_config=: -func_config - ;; - --dlopen|-dlopen) - optarg="$1" - opt_dlopen="${opt_dlopen+$opt_dlopen -}$optarg" - shift - ;; - --preserve-dup-deps) - opt_preserve_dup_deps=: - ;; - --features) - opt_features=: -func_features - ;; - --finish) - opt_finish=: -set dummy --mode finish ${1+"$@"}; shift - ;; - --help) - opt_help=: - ;; - --help-all) - opt_help_all=: -opt_help=': help-all' - ;; - --mode) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_mode="$optarg" -case $optarg in - # Valid mode arguments: - clean|compile|execute|finish|install|link|relink|uninstall) ;; - - # Catch anything else as an error - *) func_error "invalid argument for $opt" - exit_cmd=exit - break - ;; -esac - shift - ;; - --no-silent|--no-quiet) - opt_silent=false -func_append preserve_args " $opt" - ;; - --no-warning|--no-warn) - opt_warning=false -func_append preserve_args " $opt" - ;; - --no-verbose) - opt_verbose=false -func_append preserve_args " $opt" - ;; - --silent|--quiet) - opt_silent=: -func_append preserve_args " $opt" - opt_verbose=false - ;; - --verbose|-v) - opt_verbose=: -func_append preserve_args " $opt" -opt_silent=false - ;; - --tag) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_tag="$optarg" -func_append preserve_args " $opt $optarg" -func_enable_tag "$optarg" - shift - ;; - - -\?|-h) func_usage ;; - --help) func_help ;; - --version) func_version ;; - - # Separate optargs to long options: - --*=*) - func_split_long_opt "$opt" - set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} - shift - ;; - - # Separate non-argument short options: - -\?*|-h*|-n*|-v*) - func_split_short_opt "$opt" - set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - - --) break ;; - -*) func_fatal_help "unrecognized option \`$opt'" ;; - *) set dummy "$opt" ${1+"$@"}; shift; break ;; - esac - done - - # Validate options: - - # save first non-option argument - if test "$#" -gt 0; then - nonopt="$opt" - shift - fi - - # preserve --debug - test "$opt_debug" = : || func_append preserve_args " --debug" - - case $host in - *cygwin* | *mingw* | *pw32* | *cegcc*) - # don't eliminate duplications in $postdeps and $predeps - opt_duplicate_compiler_generated_deps=: - ;; - *) - opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps - ;; - esac - - $opt_help || { - # Sanity checks first: - func_check_version_match - - if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then - func_fatal_configuration "not configured to build any kind of library" - fi - - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" - - # Only execute mode is allowed to have -dlopen flags. - if test -n "$opt_dlopen" && test "$opt_mode" != execute; then - func_error "unrecognized option \`-dlopen'" - $ECHO "$help" 1>&2 - exit $EXIT_FAILURE - fi - - # Change the help message to a mode-specific one. - generic_help="$help" - help="Try \`$progname --help --mode=$opt_mode' for more information." - } - - - # Bail if the options were screwed - $exit_cmd $EXIT_FAILURE -} - - - - -## ----------- ## -## Main. ## -## ----------- ## - -# func_lalib_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_lalib_p () -{ - test -f "$1" && - $SED -e 4q "$1" 2>/dev/null \ - | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 -} - -# func_lalib_unsafe_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function implements the same check as func_lalib_p without -# resorting to external programs. To this end, it redirects stdin and -# closes it afterwards, without saving the original file descriptor. -# As a safety measure, use it only where a negative result would be -# fatal anyway. Works if `file' does not exist. -func_lalib_unsafe_p () -{ - lalib_p=no - if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then - for lalib_p_l in 1 2 3 4 - do - read lalib_p_line - case "$lalib_p_line" in - \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; - esac - done - exec 0<&5 5<&- - fi - test "$lalib_p" = yes -} - -# func_ltwrapper_script_p file -# True iff FILE is a libtool wrapper script -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_script_p () -{ - func_lalib_p "$1" -} - -# func_ltwrapper_executable_p file -# True iff FILE is a libtool wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_executable_p () -{ - func_ltwrapper_exec_suffix= - case $1 in - *.exe) ;; - *) func_ltwrapper_exec_suffix=.exe ;; - esac - $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 -} - -# func_ltwrapper_scriptname file -# Assumes file is an ltwrapper_executable -# uses $file to determine the appropriate filename for a -# temporary ltwrapper_script. -func_ltwrapper_scriptname () -{ - func_dirname_and_basename "$1" "" "." - func_stripname '' '.exe' "$func_basename_result" - func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" -} - -# func_ltwrapper_p file -# True iff FILE is a libtool wrapper script or wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_p () -{ - func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" -} - - -# func_execute_cmds commands fail_cmd -# Execute tilde-delimited COMMANDS. -# If FAIL_CMD is given, eval that upon failure. -# FAIL_CMD may read-access the current command in variable CMD! -func_execute_cmds () -{ - $opt_debug - save_ifs=$IFS; IFS='~' - for cmd in $1; do - IFS=$save_ifs - eval cmd=\"$cmd\" - func_show_eval "$cmd" "${2-:}" - done - IFS=$save_ifs -} - - -# func_source file -# Source FILE, adding directory component if necessary. -# Note that it is not necessary on cygwin/mingw to append a dot to -# FILE even if both FILE and FILE.exe exist: automatic-append-.exe -# behavior happens only for exec(3), not for open(2)! Also, sourcing -# `FILE.' does not work on cygwin managed mounts. -func_source () -{ - $opt_debug - case $1 in - */* | *\\*) . "$1" ;; - *) . "./$1" ;; - esac -} - - -# func_resolve_sysroot PATH -# Replace a leading = in PATH with a sysroot. Store the result into -# func_resolve_sysroot_result -func_resolve_sysroot () -{ - func_resolve_sysroot_result=$1 - case $func_resolve_sysroot_result in - =*) - func_stripname '=' '' "$func_resolve_sysroot_result" - func_resolve_sysroot_result=$lt_sysroot$func_stripname_result - ;; - esac -} - -# func_replace_sysroot PATH -# If PATH begins with the sysroot, replace it with = and -# store the result into func_replace_sysroot_result. -func_replace_sysroot () -{ - case "$lt_sysroot:$1" in - ?*:"$lt_sysroot"*) - func_stripname "$lt_sysroot" '' "$1" - func_replace_sysroot_result="=$func_stripname_result" - ;; - *) - # Including no sysroot. - func_replace_sysroot_result=$1 - ;; - esac -} - -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () -{ - $opt_debug - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. - *) - for z in $available_tags; do - if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case "$@ " in - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - func_echo "unable to infer tagged configuration" - func_fatal_error "specify a tag with \`--tag'" -# else -# func_verbose "using $tagname tagged configuration" - fi - ;; - esac - fi -} - - - -# func_write_libtool_object output_name pic_name nonpic_name -# Create a libtool object file (analogous to a ".la" file), -# but don't create it if we're doing a dry run. -func_write_libtool_object () -{ - write_libobj=${1} - if test "$build_libtool_libs" = yes; then - write_lobj=\'${2}\' - else - write_lobj=none - fi - - if test "$build_old_libs" = yes; then - write_oldobj=\'${3}\' - else - write_oldobj=none - fi - - $opt_dry_run || { - cat >${write_libobj}T </dev/null` - if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then - func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | - $SED -e "$lt_sed_naive_backslashify"` - else - func_convert_core_file_wine_to_w32_result= - fi - fi -} -# end: func_convert_core_file_wine_to_w32 - - -# func_convert_core_path_wine_to_w32 ARG -# Helper function used by path conversion functions when $build is *nix, and -# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly -# configured wine environment available, with the winepath program in $build's -# $PATH. Assumes ARG has no leading or trailing path separator characters. -# -# ARG is path to be converted from $build format to win32. -# Result is available in $func_convert_core_path_wine_to_w32_result. -# Unconvertible file (directory) names in ARG are skipped; if no directory names -# are convertible, then the result may be empty. -func_convert_core_path_wine_to_w32 () -{ - $opt_debug - # unfortunately, winepath doesn't convert paths, only file names - func_convert_core_path_wine_to_w32_result="" - if test -n "$1"; then - oldIFS=$IFS - IFS=: - for func_convert_core_path_wine_to_w32_f in $1; do - IFS=$oldIFS - func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" - if test -n "$func_convert_core_file_wine_to_w32_result" ; then - if test -z "$func_convert_core_path_wine_to_w32_result"; then - func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" - else - func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" - fi - fi - done - IFS=$oldIFS - fi -} -# end: func_convert_core_path_wine_to_w32 - - -# func_cygpath ARGS... -# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when -# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) -# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or -# (2), returns the Cygwin file name or path in func_cygpath_result (input -# file name or path is assumed to be in w32 format, as previously converted -# from $build's *nix or MSYS format). In case (3), returns the w32 file name -# or path in func_cygpath_result (input file name or path is assumed to be in -# Cygwin format). Returns an empty string on error. -# -# ARGS are passed to cygpath, with the last one being the file name or path to -# be converted. -# -# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH -# environment variable; do not put it in $PATH. -func_cygpath () -{ - $opt_debug - if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then - func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` - if test "$?" -ne 0; then - # on failure, ensure result is empty - func_cygpath_result= - fi - else - func_cygpath_result= - func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" - fi -} -#end: func_cygpath - - -# func_convert_core_msys_to_w32 ARG -# Convert file name or path ARG from MSYS format to w32 format. Return -# result in func_convert_core_msys_to_w32_result. -func_convert_core_msys_to_w32 () -{ - $opt_debug - # awkward: cmd appends spaces to result - func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | - $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` -} -#end: func_convert_core_msys_to_w32 - - -# func_convert_file_check ARG1 ARG2 -# Verify that ARG1 (a file name in $build format) was converted to $host -# format in ARG2. Otherwise, emit an error message, but continue (resetting -# func_to_host_file_result to ARG1). -func_convert_file_check () -{ - $opt_debug - if test -z "$2" && test -n "$1" ; then - func_error "Could not determine host file name corresponding to" - func_error " \`$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback: - func_to_host_file_result="$1" - fi -} -# end func_convert_file_check - - -# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH -# Verify that FROM_PATH (a path in $build format) was converted to $host -# format in TO_PATH. Otherwise, emit an error message, but continue, resetting -# func_to_host_file_result to a simplistic fallback value (see below). -func_convert_path_check () -{ - $opt_debug - if test -z "$4" && test -n "$3"; then - func_error "Could not determine the host path corresponding to" - func_error " \`$3'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback. This is a deliberately simplistic "conversion" and - # should not be "improved". See libtool.info. - if test "x$1" != "x$2"; then - lt_replace_pathsep_chars="s|$1|$2|g" - func_to_host_path_result=`echo "$3" | - $SED -e "$lt_replace_pathsep_chars"` - else - func_to_host_path_result="$3" - fi - fi -} -# end func_convert_path_check - - -# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG -# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT -# and appending REPL if ORIG matches BACKPAT. -func_convert_path_front_back_pathsep () -{ - $opt_debug - case $4 in - $1 ) func_to_host_path_result="$3$func_to_host_path_result" - ;; - esac - case $4 in - $2 ) func_append func_to_host_path_result "$3" - ;; - esac -} -# end func_convert_path_front_back_pathsep - - -################################################## -# $build to $host FILE NAME CONVERSION FUNCTIONS # -################################################## -# invoked via `$to_host_file_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# Result will be available in $func_to_host_file_result. - - -# func_to_host_file ARG -# Converts the file name ARG from $build format to $host format. Return result -# in func_to_host_file_result. -func_to_host_file () -{ - $opt_debug - $to_host_file_cmd "$1" -} -# end func_to_host_file - - -# func_to_tool_file ARG LAZY -# converts the file name ARG from $build format to toolchain format. Return -# result in func_to_tool_file_result. If the conversion in use is listed -# in (the comma separated) LAZY, no conversion takes place. -func_to_tool_file () -{ - $opt_debug - case ,$2, in - *,"$to_tool_file_cmd",*) - func_to_tool_file_result=$1 - ;; - *) - $to_tool_file_cmd "$1" - func_to_tool_file_result=$func_to_host_file_result - ;; - esac -} -# end func_to_tool_file - - -# func_convert_file_noop ARG -# Copy ARG to func_to_host_file_result. -func_convert_file_noop () -{ - func_to_host_file_result="$1" -} -# end func_convert_file_noop - - -# func_convert_file_msys_to_w32 ARG -# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_file_result. -func_convert_file_msys_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_to_host_file_result="$func_convert_core_msys_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_w32 - - -# func_convert_file_cygwin_to_w32 ARG -# Convert file name ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_file_cygwin_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # because $build is cygwin, we call "the" cygpath in $PATH; no need to use - # LT_CYGPATH in this case. - func_to_host_file_result=`cygpath -m "$1"` - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_cygwin_to_w32 - - -# func_convert_file_nix_to_w32 ARG -# Convert file name ARG from *nix to w32 format. Requires a wine environment -# and a working winepath. Returns result in func_to_host_file_result. -func_convert_file_nix_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_file_wine_to_w32 "$1" - func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_w32 - - -# func_convert_file_msys_to_cygwin ARG -# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_file_msys_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_cygpath -u "$func_convert_core_msys_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_cygwin - - -# func_convert_file_nix_to_cygwin ARG -# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed -# in a wine environment, working winepath, and LT_CYGPATH set. Returns result -# in func_to_host_file_result. -func_convert_file_nix_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. - func_convert_core_file_wine_to_w32 "$1" - func_cygpath -u "$func_convert_core_file_wine_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_cygwin - - -############################################# -# $build to $host PATH CONVERSION FUNCTIONS # -############################################# -# invoked via `$to_host_path_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# The result will be available in $func_to_host_path_result. -# -# Path separators are also converted from $build format to $host format. If -# ARG begins or ends with a path separator character, it is preserved (but -# converted to $host format) on output. -# -# All path conversion functions are named using the following convention: -# file name conversion function : func_convert_file_X_to_Y () -# path conversion function : func_convert_path_X_to_Y () -# where, for any given $build/$host combination the 'X_to_Y' value is the -# same. If conversion functions are added for new $build/$host combinations, -# the two new functions must follow this pattern, or func_init_to_host_path_cmd -# will break. - - -# func_init_to_host_path_cmd -# Ensures that function "pointer" variable $to_host_path_cmd is set to the -# appropriate value, based on the value of $to_host_file_cmd. -to_host_path_cmd= -func_init_to_host_path_cmd () -{ - $opt_debug - if test -z "$to_host_path_cmd"; then - func_stripname 'func_convert_file_' '' "$to_host_file_cmd" - to_host_path_cmd="func_convert_path_${func_stripname_result}" - fi -} - - -# func_to_host_path ARG -# Converts the path ARG from $build format to $host format. Return result -# in func_to_host_path_result. -func_to_host_path () -{ - $opt_debug - func_init_to_host_path_cmd - $to_host_path_cmd "$1" -} -# end func_to_host_path - - -# func_convert_path_noop ARG -# Copy ARG to func_to_host_path_result. -func_convert_path_noop () -{ - func_to_host_path_result="$1" -} -# end func_convert_path_noop - - -# func_convert_path_msys_to_w32 ARG -# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_path_result. -func_convert_path_msys_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from ARG. MSYS - # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; - # and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_msys_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_msys_to_w32 - - -# func_convert_path_cygwin_to_w32 ARG -# Convert path ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_path_cygwin_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_cygwin_to_w32 - - -# func_convert_path_nix_to_w32 ARG -# Convert path ARG from *nix to w32 format. Requires a wine environment and -# a working winepath. Returns result in func_to_host_file_result. -func_convert_path_nix_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_nix_to_w32 - - -# func_convert_path_msys_to_cygwin ARG -# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_path_msys_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_msys_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_msys_to_cygwin - - -# func_convert_path_nix_to_cygwin ARG -# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a -# a wine environment, working winepath, and LT_CYGPATH set. Returns result in -# func_to_host_file_result. -func_convert_path_nix_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from - # ARG. msys behavior is inconsistent here, cygpath turns them - # into '.;' and ';.', and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_nix_to_cygwin - - -# func_mode_compile arg... -func_mode_compile () -{ - $opt_debug - # Get the compilation command and the source file. - base_compile= - srcfile="$nonopt" # always keep a non-empty value in "srcfile" - suppress_opt=yes - suppress_output= - arg_mode=normal - libobj= - later= - pie_flag= - - for arg - do - case $arg_mode in - arg ) - # do not "continue". Instead, add this to base_compile - lastarg="$arg" - arg_mode=normal - ;; - - target ) - libobj="$arg" - arg_mode=normal - continue - ;; - - normal ) - # Accept any command-line options. - case $arg in - -o) - test -n "$libobj" && \ - func_fatal_error "you cannot specify \`-o' more than once" - arg_mode=target - continue - ;; - - -pie | -fpie | -fPIE) - func_append pie_flag " $arg" - continue - ;; - - -shared | -static | -prefer-pic | -prefer-non-pic) - func_append later " $arg" - continue - ;; - - -no-suppress) - suppress_opt=no - continue - ;; - - -Xcompiler) - arg_mode=arg # the next one goes into the "base_compile" arg list - continue # The current "srcfile" will either be retained or - ;; # replaced later. I would guess that would be a bug. - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - lastarg= - save_ifs="$IFS"; IFS=',' - for arg in $args; do - IFS="$save_ifs" - func_append_quoted lastarg "$arg" - done - IFS="$save_ifs" - func_stripname ' ' '' "$lastarg" - lastarg=$func_stripname_result - - # Add the arguments to base_compile. - func_append base_compile " $lastarg" - continue - ;; - - *) - # Accept the current argument as the source file. - # The previous "srcfile" becomes the current argument. - # - lastarg="$srcfile" - srcfile="$arg" - ;; - esac # case $arg - ;; - esac # case $arg_mode - - # Aesthetically quote the previous argument. - func_append_quoted base_compile "$lastarg" - done # for arg - - case $arg_mode in - arg) - func_fatal_error "you must specify an argument for -Xcompile" - ;; - target) - func_fatal_error "you must specify a target with \`-o'" - ;; - *) - # Get the name of the library object. - test -z "$libobj" && { - func_basename "$srcfile" - libobj="$func_basename_result" - } - ;; - esac - - # Recognize several different file suffixes. - # If the user specifies -o file.o, it is replaced with file.lo - case $libobj in - *.[cCFSifmso] | \ - *.ada | *.adb | *.ads | *.asm | \ - *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ - *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) - func_xform "$libobj" - libobj=$func_xform_result - ;; - esac - - case $libobj in - *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; - *) - func_fatal_error "cannot determine name of library object from \`$libobj'" - ;; - esac - - func_infer_tag $base_compile - - for arg in $later; do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - continue - ;; - - -static) - build_libtool_libs=no - build_old_libs=yes - continue - ;; - - -prefer-pic) - pic_mode=yes - continue - ;; - - -prefer-non-pic) - pic_mode=no - continue - ;; - esac - done - - func_quote_for_eval "$libobj" - test "X$libobj" != "X$func_quote_for_eval_result" \ - && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && func_warning "libobj name \`$libobj' may not contain shell special characters." - func_dirname_and_basename "$obj" "/" "" - objname="$func_basename_result" - xdir="$func_dirname_result" - lobj=${xdir}$objdir/$objname - - test -z "$base_compile" && \ - func_fatal_help "you must specify a compilation command" - - # Delete any leftover library objects. - if test "$build_old_libs" = yes; then - removelist="$obj $lobj $libobj ${libobj}T" - else - removelist="$lobj $libobj ${libobj}T" - fi - - # On Cygwin there's no "real" PIC flag so we must build both object types - case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) - pic_mode=default - ;; - esac - if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then - # non-PIC code in shared libraries is not supported - pic_mode=default - fi - - # Calculate the filename of the output object if compiler does - # not support -o with -c - if test "$compiler_c_o" = no; then - output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} - lockfile="$output_obj.lock" - else - output_obj= - need_locks=no - lockfile= - fi - - # Lock this critical section if it is needed - # We use this script file to make the link, it avoids creating a new file - if test "$need_locks" = yes; then - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - elif test "$need_locks" = warn; then - if test -f "$lockfile"; then - $ECHO "\ -*** ERROR, $lockfile exists and contains: -`cat $lockfile 2>/dev/null` - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - func_append removelist " $output_obj" - $ECHO "$srcfile" > "$lockfile" - fi - - $opt_dry_run || $RM $removelist - func_append removelist " $lockfile" - trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - - func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 - srcfile=$func_to_tool_file_result - func_quote_for_eval "$srcfile" - qsrcfile=$func_quote_for_eval_result - - # Only build a PIC object if we are building libtool libraries. - if test "$build_libtool_libs" = yes; then - # Without this assignment, base_compile gets emptied. - fbsd_hideous_sh_bug=$base_compile - - if test "$pic_mode" != no; then - command="$base_compile $qsrcfile $pic_flag" - else - # Don't build PIC code - command="$base_compile $qsrcfile" - fi - - func_mkdir_p "$xdir$objdir" - - if test -z "$output_obj"; then - # Place PIC objects in $objdir - func_append command " -o $lobj" - fi - - func_show_eval_locale "$command" \ - 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed, then go on to compile the next one - if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - func_show_eval '$MV "$output_obj" "$lobj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - - # Allow error messages only from the first compilation. - if test "$suppress_opt" = yes; then - suppress_output=' >/dev/null 2>&1' - fi - fi - - # Only build a position-dependent object if we build old libraries. - if test "$build_old_libs" = yes; then - if test "$pic_mode" != yes; then - # Don't build PIC code - command="$base_compile $qsrcfile$pie_flag" - else - command="$base_compile $qsrcfile $pic_flag" - fi - if test "$compiler_c_o" = yes; then - func_append command " -o $obj" - fi - - # Suppress compiler output if we already did a PIC compilation. - func_append command "$suppress_output" - func_show_eval_locale "$command" \ - '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed - if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - func_show_eval '$MV "$output_obj" "$obj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - fi - - $opt_dry_run || { - func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" - - # Unlock the critical section if it was locked - if test "$need_locks" != no; then - removelist=$lockfile - $RM "$lockfile" - fi - } - - exit $EXIT_SUCCESS -} - -$opt_help || { - test "$opt_mode" = compile && func_mode_compile ${1+"$@"} -} - -func_mode_help () -{ - # We need to display help for each of the modes. - case $opt_mode in - "") - # Generic help is extracted from the usage comments - # at the start of this file. - func_help - ;; - - clean) - $ECHO \ -"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - -Remove files from the build directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, object or program, all the files associated -with it are deleted. Otherwise, only FILE itself is deleted using RM." - ;; - - compile) - $ECHO \ -"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - -Compile a source file into a libtool library object. - -This mode accepts the following additional options: - - -o OUTPUT-FILE set the output file name to OUTPUT-FILE - -no-suppress do not suppress compiler output for multiple passes - -prefer-pic try to build PIC objects only - -prefer-non-pic try to build non-PIC objects only - -shared do not build a \`.o' file suitable for static linking - -static only build a \`.o' file suitable for static linking - -Wc,FLAG pass FLAG directly to the compiler - -COMPILE-COMMAND is a command to be used in creating a \`standard' object file -from the given SOURCEFILE. - -The output file name is determined by removing the directory component from -SOURCEFILE, then substituting the C source code suffix \`.c' with the -library object suffix, \`.lo'." - ;; - - execute) - $ECHO \ -"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... - -Automatically set library path, then run a program. - -This mode accepts the following additional options: - - -dlopen FILE add the directory containing FILE to the library path - -This mode sets the library path environment variable according to \`-dlopen' -flags. - -If any of the ARGS are libtool executable wrappers, then they are translated -into their corresponding uninstalled binary, and any of their required library -directories are added to the library path. - -Then, COMMAND is executed, with ARGS as arguments." - ;; - - finish) - $ECHO \ -"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... - -Complete the installation of libtool libraries. - -Each LIBDIR is a directory that contains libtool libraries. - -The commands that this mode executes may require superuser privileges. Use -the \`--dry-run' option if you just want to see what would be executed." - ;; - - install) - $ECHO \ -"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... - -Install executables or libraries. - -INSTALL-COMMAND is the installation command. The first component should be -either the \`install' or \`cp' program. - -The following components of INSTALL-COMMAND are treated specially: - - -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation - -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; - - link) - $ECHO \ -"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... - -Link object files or libraries together to form another library, or to -create an executable program. - -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. - -The following components of LINK-COMMAND are treated specially: - - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -bindir BINDIR specify path to binaries directory (for systems where - libraries must be found in the PATH setting at runtime) - -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE Use a list of object files found in FILE to specify objects - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -shared only do dynamic linking of libtool libraries - -shrext SUFFIX override the standard shared library file extension - -static do not do any dynamic linking of uninstalled libtool libraries - -static-libtool-libs - do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -weak LIBNAME declare that the target provides the LIBNAME interface - -Wc,FLAG - -Xcompiler FLAG pass linker-specific FLAG directly to the compiler - -Wl,FLAG - -Xlinker FLAG pass linker-specific FLAG directly to the linker - -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) - -All other options (arguments beginning with \`-') are ignored. - -Every other argument is treated as a filename. Files ending in \`.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in \`.la', then a libtool library is created, -only library objects (\`.lo' files) may be specified, and \`-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created -using \`ar' and \`ranlib', or on Windows using \`lib'. - -If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file -is created, otherwise an executable program is created." - ;; - - uninstall) - $ECHO \ -"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... - -Remove libraries from an installation directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; - - *) - func_fatal_help "invalid operation mode \`$opt_mode'" - ;; - esac - - echo - $ECHO "Try \`$progname --help' for more information about other modes." -} - -# Now that we've collected a possible --mode arg, show help if necessary -if $opt_help; then - if test "$opt_help" = :; then - func_mode_help - else - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - func_mode_help - done - } | sed -n '1p; 2,$s/^Usage:/ or: /p' - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - echo - func_mode_help - done - } | - sed '1d - /^When reporting/,/^Report/{ - H - d - } - $x - /information about other modes/d - /more detailed .*MODE/d - s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' - fi - exit $? -fi - - -# func_mode_execute arg... -func_mode_execute () -{ - $opt_debug - # The first argument is the command name. - cmd="$nonopt" - test -z "$cmd" && \ - func_fatal_help "you must specify a COMMAND" - - # Handle -dlopen flags immediately. - for file in $opt_dlopen; do - test -f "$file" \ - || func_fatal_help "\`$file' is not a file" - - dir= - case $file in - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$lib' is not a valid libtool archive" - - # Read the libtool library. - dlname= - library_names= - func_source "$file" - - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && \ - func_warning "\`$file' was not linked with \`-export-dynamic'" - continue - fi - - func_dirname "$file" "" "." - dir="$func_dirname_result" - - if test -f "$dir/$objdir/$dlname"; then - func_append dir "/$objdir" - else - if test ! -f "$dir/$dlname"; then - func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" - fi - fi - ;; - - *.lo) - # Just add the directory containing the .lo file. - func_dirname "$file" "" "." - dir="$func_dirname_result" - ;; - - *) - func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" - continue - ;; - esac - - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir="$absdir" - - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done - - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic="$magic" - - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -* | *.la | *.lo ) ;; - *) - # Do a test to see if this is really a libtool program. - if func_ltwrapper_script_p "$file"; then - func_source "$file" - # Transform arg to wrapped name. - file="$progdir/$program" - elif func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - func_source "$func_ltwrapper_scriptname_result" - # Transform arg to wrapped name. - file="$progdir/$program" - fi - ;; - esac - # Quote arguments (to preserve shell metacharacters). - func_append_quoted args "$file" - done - - if test "X$opt_dry_run" = Xfalse; then - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi - - # Restore saved environment variables - for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES - do - eval "if test \"\${save_$lt_var+set}\" = set; then - $lt_var=\$save_$lt_var; export $lt_var - else - $lt_unset $lt_var - fi" - done - - # Now prepare to actually exec the command. - exec_cmd="\$cmd$args" - else - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - echo "export $shlibpath_var" - fi - $ECHO "$cmd$args" - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = execute && func_mode_execute ${1+"$@"} - - -# func_mode_finish arg... -func_mode_finish () -{ - $opt_debug - libs= - libdirs= - admincmds= - - for opt in "$nonopt" ${1+"$@"} - do - if test -d "$opt"; then - func_append libdirs " $opt" - - elif test -f "$opt"; then - if func_lalib_unsafe_p "$opt"; then - func_append libs " $opt" - else - func_warning "\`$opt' is not a valid libtool archive" - fi - - else - func_fatal_error "invalid argument \`$opt'" - fi - done - - if test -n "$libs"; then - if test -n "$lt_sysroot"; then - sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` - sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" - else - sysroot_cmd= - fi - - # Remove sysroot references - if $opt_dry_run; then - for lib in $libs; do - echo "removing references to $lt_sysroot and \`=' prefixes from $lib" - done - else - tmpdir=`func_mktempdir` - for lib in $libs; do - sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ - > $tmpdir/tmp-la - mv -f $tmpdir/tmp-la $lib - done - ${RM}r "$tmpdir" - fi - fi - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - func_execute_cmds "$finish_cmds" 'admincmds="$admincmds -'"$cmd"'"' - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || func_append admincmds " - $cmds" - fi - done - fi - - # Exit here if they wanted silent mode. - $opt_silent && exit $EXIT_SUCCESS - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - echo "----------------------------------------------------------------------" - echo "Libraries have been installed in:" - for libdir in $libdirs; do - $ECHO " $libdir" - done - echo - echo "If you ever happen to want to link against installed libraries" - echo "in a given directory, LIBDIR, you must either use libtool, and" - echo "specify the full pathname of the library, or use the \`-LLIBDIR'" - echo "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - echo " - add LIBDIR to the \`$shlibpath_var' environment variable" - echo " during execution" - fi - if test -n "$runpath_var"; then - echo " - add LIBDIR to the \`$runpath_var' environment variable" - echo " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" - - $ECHO " - use the \`$flag' linker flag" - fi - if test -n "$admincmds"; then - $ECHO " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" - fi - echo - - echo "See any operating system documentation about shared libraries for" - case $host in - solaris2.[6789]|solaris2.1[0-9]) - echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" - echo "pages." - ;; - *) - echo "more information, such as the ld(1) and ld.so(8) manual pages." - ;; - esac - echo "----------------------------------------------------------------------" - fi - exit $EXIT_SUCCESS -} - -test "$opt_mode" = finish && func_mode_finish ${1+"$@"} - - -# func_mode_install arg... -func_mode_install () -{ - $opt_debug - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || - # Allow the use of GNU shtool's install command. - case $nonopt in *shtool*) :;; *) false;; esac; then - # Aesthetically quote it. - func_quote_for_eval "$nonopt" - install_prog="$func_quote_for_eval_result " - arg=$1 - shift - else - install_prog= - arg=$nonopt - fi - - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - func_quote_for_eval "$arg" - func_append install_prog "$func_quote_for_eval_result" - install_shared_prog=$install_prog - case " $install_prog " in - *[\\\ /]cp\ *) install_cp=: ;; - *) install_cp=false ;; - esac - - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=no - stripme= - no_mode=: - for arg - do - arg2= - if test -n "$dest"; then - func_append files " $dest" - dest=$arg - continue - fi - - case $arg in - -d) isdir=yes ;; - -f) - if $install_cp; then :; else - prev=$arg - fi - ;; - -g | -m | -o) - prev=$arg - ;; - -s) - stripme=" -s" - continue - ;; - -*) - ;; - *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - if test "x$prev" = x-m && test -n "$install_override_mode"; then - arg2=$install_override_mode - no_mode=false - fi - prev= - else - dest=$arg - continue - fi - ;; - esac - - # Aesthetically quote the argument. - func_quote_for_eval "$arg" - func_append install_prog " $func_quote_for_eval_result" - if test -n "$arg2"; then - func_quote_for_eval "$arg2" - fi - func_append install_shared_prog " $func_quote_for_eval_result" - done - - test -z "$install_prog" && \ - func_fatal_help "you must specify an install program" - - test -n "$prev" && \ - func_fatal_help "the \`$prev' option requires an argument" - - if test -n "$install_override_mode" && $no_mode; then - if $install_cp; then :; else - func_quote_for_eval "$install_override_mode" - func_append install_shared_prog " -m $func_quote_for_eval_result" - fi - fi - - if test -z "$files"; then - if test -z "$dest"; then - func_fatal_help "no file or destination specified" - else - func_fatal_help "you must specify a destination" - fi - fi - - # Strip any trailing slash from the destination. - func_stripname '' '/' "$dest" - dest=$func_stripname_result - - # Check to see that the destination is a directory. - test -d "$dest" && isdir=yes - if test "$isdir" = yes; then - destdir="$dest" - destname= - else - func_dirname_and_basename "$dest" "" "." - destdir="$func_dirname_result" - destname="$func_basename_result" - - # Not a directory, so check to see that there is only one file specified. - set dummy $files; shift - test "$#" -gt 1 && \ - func_fatal_help "\`$dest' is not a directory" - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - func_fatal_help "\`$destdir' must be an absolute directory name" - ;; - esac - done - ;; - esac - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do - - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - func_append staticlibs " $file" - ;; - - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$file' is not a valid libtool archive" - - library_names= - old_library= - relink_command= - func_source "$file" - - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in - *" $libdir "*) ;; - *) func_append current_libdirs " $libdir" ;; - esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in - *" $libdir "*) ;; - *) func_append future_libdirs " $libdir" ;; - esac - fi - - func_dirname "$file" "/" "" - dir="$func_dirname_result" - func_append dir "$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` - - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - test "$inst_prefix_dir" = "$destdir" && \ - func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" - - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` - fi - - func_warning "relinking \`$file'" - func_show_eval "$relink_command" \ - 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' - fi - - # See the names of the shared library. - set dummy $library_names; shift - if test -n "$1"; then - realname="$1" - shift - - srcname="$realname" - test -n "$relink_command" && srcname="$realname"T - - # Install the shared library and build the symlinks. - func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ - 'exit $?' - tstripme="$stripme" - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - case $realname in - *.dll.a) - tstripme="" - ;; - esac - ;; - esac - if test -n "$tstripme" && test -n "$striplib"; then - func_show_eval "$striplib $destdir/$realname" 'exit $?' - fi - - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try `ln -sf' first, because the `ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - test "$linkname" != "$realname" \ - && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" - done - fi - - # Do each command in the postinstall commands. - lib="$destdir/$realname" - func_execute_cmds "$postinstall_cmds" 'exit $?' - fi - - # Install the pseudo-library for information purposes. - func_basename "$file" - name="$func_basename_result" - instname="$dir/$name"i - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' - - # Maybe install the static library, too. - test -n "$old_library" && func_append staticlibs " $dir/$old_library" - ;; - - *.lo) - # Install (i.e. copy) a libtool object. - - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - func_lo2o "$destfile" - staticdest=$func_lo2o_result - ;; - *.$objext) - staticdest="$destfile" - destfile= - ;; - *) - func_fatal_help "cannot copy a libtool object to \`$destfile'" - ;; - esac - - # Install the libtool object if requested. - test -n "$destfile" && \ - func_show_eval "$install_prog $file $destfile" 'exit $?' - - # Install the old object if enabled. - if test "$build_old_libs" = yes; then - # Deduce the name of the old-style object file. - func_lo2o "$file" - staticobj=$func_lo2o_result - func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' - fi - exit $EXIT_SUCCESS - ;; - - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext="" - case $file in - *.exe) - if test ! -f "$file"; then - func_stripname '' '.exe' "$file" - file=$func_stripname_result - stripped_ext=".exe" - fi - ;; - esac - - # Do a test to see if this is really a libtool program. - case $host in - *cygwin* | *mingw*) - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - wrapper=$func_ltwrapper_scriptname_result - else - func_stripname '' '.exe' "$file" - wrapper=$func_stripname_result - fi - ;; - *) - wrapper=$file - ;; - esac - if func_ltwrapper_script_p "$wrapper"; then - notinst_deplibs= - relink_command= - - func_source "$wrapper" - - # Check the variables that should have been set. - test -z "$generated_by_libtool_version" && \ - func_fatal_error "invalid libtool wrapper script \`$wrapper'" - - finalize=yes - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - func_source "$lib" - fi - libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test - if test -n "$libdir" && test ! -f "$libfile"; then - func_warning "\`$lib' has not been installed in \`$libdir'" - finalize=no - fi - done - - relink_command= - func_source "$wrapper" - - outputname= - if test "$fast_install" = no && test -n "$relink_command"; then - $opt_dry_run || { - if test "$finalize" = yes; then - tmpdir=`func_mktempdir` - func_basename "$file$stripped_ext" - file="$func_basename_result" - outputname="$tmpdir/$file" - # Replace the output file specification. - relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` - - $opt_silent || { - func_quote_for_expand "$relink_command" - eval "func_echo $func_quote_for_expand_result" - } - if eval "$relink_command"; then : - else - func_error "error: relink \`$file' with the above command before installing it" - $opt_dry_run || ${RM}r "$tmpdir" - continue - fi - file="$outputname" - else - func_warning "cannot relink \`$file'" - fi - } - else - # Install the binary that we compiled earlier. - file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` - fi - fi - - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - func_stripname '' '.exe' "$destfile" - destfile=$func_stripname_result - ;; - esac - ;; - esac - func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' - $opt_dry_run || if test -n "$outputname"; then - ${RM}r "$tmpdir" - fi - ;; - esac - done - - for file in $staticlibs; do - func_basename "$file" - name="$func_basename_result" - - # Set up the ranlib parameters. - oldlib="$destdir/$name" - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - - func_show_eval "$install_prog \$file \$oldlib" 'exit $?' - - if test -n "$stripme" && test -n "$old_striplib"; then - func_show_eval "$old_striplib $tool_oldlib" 'exit $?' - fi - - # Do each command in the postinstall commands. - func_execute_cmds "$old_postinstall_cmds" 'exit $?' - done - - test -n "$future_libdirs" && \ - func_warning "remember to run \`$progname --finish$future_libdirs'" - - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - $opt_dry_run && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' - else - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = install && func_mode_install ${1+"$@"} - - -# func_generate_dlsyms outputname originator pic_p -# Extract symbols from dlprefiles and create ${outputname}S.o with -# a dlpreopen symbol table. -func_generate_dlsyms () -{ - $opt_debug - my_outputname="$1" - my_originator="$2" - my_pic_p="${3-no}" - my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` - my_dlsyms= - - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - my_dlsyms="${my_outputname}S.c" - else - func_error "not configured to extract global symbols from dlpreopened files" - fi - fi - - if test -n "$my_dlsyms"; then - case $my_dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist="$output_objdir/${my_outputname}.nm" - - func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - - # Parse the name list into a source file. - func_verbose "creating $output_objdir/$my_dlsyms" - - $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ -/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ -/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ - -#ifdef __cplusplus -extern \"C\" { -#endif - -#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) -#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" -#endif - -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -/* External symbol declarations for the compiler. */\ -" - - if test "$dlself" = yes; then - func_verbose "generating symbol list for \`$output'" - - $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` - for progfile in $progfiles; do - func_to_tool_file "$progfile" func_convert_file_msys_to_w32 - func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" - $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $opt_dry_run || { - eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - if test -n "$export_symbols_regex"; then - $opt_dry_run || { - eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols="$output_objdir/$outputname.exp" - $opt_dry_run || { - $RM $export_symbols - eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - } - else - $opt_dry_run || { - eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - } - fi - fi - - for dlprefile in $dlprefiles; do - func_verbose "extracting global C symbols from \`$dlprefile'" - func_basename "$dlprefile" - name="$func_basename_result" - case $host in - *cygwin* | *mingw* | *cegcc* ) - # if an import library, we need to obtain dlname - if func_win32_import_lib_p "$dlprefile"; then - func_tr_sh "$dlprefile" - eval "curr_lafile=\$libfile_$func_tr_sh_result" - dlprefile_dlbasename="" - if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then - # Use subshell, to avoid clobbering current variable values - dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` - if test -n "$dlprefile_dlname" ; then - func_basename "$dlprefile_dlname" - dlprefile_dlbasename="$func_basename_result" - else - # no lafile. user explicitly requested -dlpreopen . - $sharedlib_from_linklib_cmd "$dlprefile" - dlprefile_dlbasename=$sharedlib_from_linklib_result - fi - fi - $opt_dry_run || { - if test -n "$dlprefile_dlbasename" ; then - eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' - else - func_warning "Could not compute DLL name from $name" - eval '$ECHO ": $name " >> "$nlist"' - fi - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | - $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" - } - else # not an import lib - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - fi - ;; - *) - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - ;; - esac - done - - $opt_dry_run || { - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $MV "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if $GREP -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - $GREP -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' - else - echo '/* NONE */' >> "$output_objdir/$my_dlsyms" - fi - - echo >> "$output_objdir/$my_dlsyms" "\ - -/* The mapping between symbol names and symbols. */ -typedef struct { - const char *name; - void *address; -} lt_dlsymlist; -extern LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[]; -LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[] = -{\ - { \"$my_originator\", (void *) 0 }," - - case $need_lib_prefix in - no) - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - *) - eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - esac - echo >> "$output_objdir/$my_dlsyms" "\ - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_${my_prefix}_LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif\ -" - } # !$opt_dry_run - - pic_flag_for_symtable= - case "$compile_command " in - *" -static "*) ;; - *) - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; - *-*-hpux*) - pic_flag_for_symtable=" $pic_flag" ;; - *) - if test "X$my_pic_p" != Xno; then - pic_flag_for_symtable=" $pic_flag" - fi - ;; - esac - ;; - esac - symtab_cflags= - for arg in $LTCFLAGS; do - case $arg in - -pie | -fpie | -fPIE) ;; - *) func_append symtab_cflags " $arg" ;; - esac - done - - # Now compile the dynamic symbol file. - func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - - # Clean up the generated files. - func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' - - # Transform the symbol file into the correct name. - symfileobj="$output_objdir/${my_outputname}S.$objext" - case $host in - *cygwin* | *mingw* | *cegcc* ) - if test -f "$output_objdir/$my_outputname.def"; then - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - else - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - fi - ;; - *) - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - ;; - esac - ;; - *) - func_fatal_error "unknown suffix for \`$my_dlsyms'" - ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. - - # Nullify the symbol file. - compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` - fi -} - -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -# Despite the name, also deal with 64 bit binaries. -func_win32_libid () -{ - $opt_debug - win32_libid_type="unknown" - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then - func_to_tool_file "$1" func_convert_file_msys_to_w32 - win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | - $SED -n -e ' - 1,100{ - / I /{ - s,.*,import, - p - q - } - }'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; - esac - ;; - esac - $ECHO "$win32_libid_type" -} - -# func_cygming_dll_for_implib ARG -# -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib () -{ - $opt_debug - sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` -} - -# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs -# -# The is the core of a fallback implementation of a -# platform-specific function to extract the name of the -# DLL associated with the specified import library LIBNAME. -# -# SECTION_NAME is either .idata$6 or .idata$7, depending -# on the platform and compiler that created the implib. -# -# Echos the name of the DLL associated with the -# specified import library. -func_cygming_dll_for_implib_fallback_core () -{ - $opt_debug - match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` - $OBJDUMP -s --section "$1" "$2" 2>/dev/null | - $SED '/^Contents of section '"$match_literal"':/{ - # Place marker at beginning of archive member dllname section - s/.*/====MARK====/ - p - d - } - # These lines can sometimes be longer than 43 characters, but - # are always uninteresting - /:[ ]*file format pe[i]\{,1\}-/d - /^In archive [^:]*:/d - # Ensure marker is printed - /^====MARK====/p - # Remove all lines with less than 43 characters - /^.\{43\}/!d - # From remaining lines, remove first 43 characters - s/^.\{43\}//' | - $SED -n ' - # Join marker and all lines until next marker into a single line - /^====MARK====/ b para - H - $ b para - b - :para - x - s/\n//g - # Remove the marker - s/^====MARK====// - # Remove trailing dots and whitespace - s/[\. \t]*$// - # Print - /./p' | - # we now have a list, one entry per line, of the stringified - # contents of the appropriate section of all members of the - # archive which possess that section. Heuristic: eliminate - # all those which have a first or second character that is - # a '.' (that is, objdump's representation of an unprintable - # character.) This should work for all archives with less than - # 0x302f exports -- but will fail for DLLs whose name actually - # begins with a literal '.' or a single character followed by - # a '.'. - # - # Of those that remain, print the first one. - $SED -e '/^\./d;/^.\./d;q' -} - -# func_cygming_gnu_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is a GNU/binutils-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_gnu_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - 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)$'` - test -n "$func_cygming_gnu_implib_tmp" -} - -# func_cygming_ms_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is an MS-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_ms_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` - test -n "$func_cygming_ms_implib_tmp" -} - -# func_cygming_dll_for_implib_fallback ARG -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# -# This fallback implementation is for use when $DLLTOOL -# does not support the --identify-strict option. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib_fallback () -{ - $opt_debug - if func_cygming_gnu_implib_p "$1" ; then - # binutils import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` - elif func_cygming_ms_implib_p "$1" ; then - # ms-generated import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` - else - # unknown - sharedlib_from_linklib_result="" - fi -} - - -# func_extract_an_archive dir oldlib -func_extract_an_archive () -{ - $opt_debug - f_ex_an_ar_dir="$1"; shift - f_ex_an_ar_oldlib="$1" - if test "$lock_old_archive_extraction" = yes; then - lockfile=$f_ex_an_ar_oldlib.lock - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - fi - func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ - 'stat=$?; rm -f "$lockfile"; exit $stat' - if test "$lock_old_archive_extraction" = yes; then - $opt_dry_run || rm -f "$lockfile" - fi - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" - fi -} - - -# func_extract_archives gentop oldlib ... -func_extract_archives () -{ - $opt_debug - my_gentop="$1"; shift - my_oldlibs=${1+"$@"} - my_oldobjs="" - my_xlib="" - my_xabs="" - my_xdir="" - - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - func_basename "$my_xlib" - my_xlib="$func_basename_result" - my_xlib_u=$my_xlib - while :; do - case " $extracted_archives " in - *" $my_xlib_u "*) - func_arith $extracted_serial + 1 - extracted_serial=$func_arith_result - my_xlib_u=lt$extracted_serial-$my_xlib ;; - *) break ;; - esac - done - extracted_archives="$extracted_archives $my_xlib_u" - my_xdir="$my_gentop/$my_xlib_u" - - func_mkdir_p "$my_xdir" - - case $host in - *-darwin*) - func_verbose "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - $opt_dry_run || { - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - darwin_base_archive=`basename "$darwin_archive"` - darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` - if test -n "$darwin_arches"; then - darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches ; do - func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" - $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" - cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" - func_extract_an_archive "`pwd`" "${darwin_base_archive}" - cd "$darwin_curdir" - $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" - done # $darwin_arches - ## Okay now we've a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` - $LIPO -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - $RM -rf unfat-$$ - cd "$darwin_orig_dir" - else - cd $darwin_orig_dir - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - } # !$opt_dry_run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` - done - - func_extract_archives_result="$my_oldobjs" -} - - -# func_emit_wrapper [arg=no] -# -# Emit a libtool wrapper script on stdout. -# Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw -# wrapper executable. Must ONLY be called from within -# func_mode_link because it depends on a number of variables -# set therein. -# -# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR -# variable will take. If 'yes', then the emitted script -# will assume that the directory in which it is stored is -# the $objdir directory. This is a cygwin/mingw-specific -# behavior. -func_emit_wrapper () -{ - func_emit_wrapper_arg1=${1-no} - - $ECHO "\ -#! $SHELL - -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='$sed_quote_subst' - -# Be Bourne compatible -if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -relink_command=\"$relink_command\" - -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variables: - generated_by_libtool_version='$macro_version' - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$ECHO are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - file=\"\$0\"" - - qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` - $ECHO "\ - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - ECHO=\"$qECHO\" - fi - -# Very basic option parsing. These options are (a) specific to -# the libtool wrapper, (b) are identical between the wrapper -# /script/ and the wrapper /executable/ which is used only on -# windows platforms, and (c) all begin with the string "--lt-" -# (application programs are unlikely to have options which match -# this pattern). -# -# There are only two supported options: --lt-debug and -# --lt-dump-script. There is, deliberately, no --lt-help. -# -# The first argument to this parsing function should be the -# script's $0 value, followed by "$@". -lt_option_debug= -func_parse_lt_options () -{ - lt_script_arg0=\$0 - shift - for lt_opt - do - case \"\$lt_opt\" in - --lt-debug) lt_option_debug=1 ;; - --lt-dump-script) - lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` - test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. - lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` - cat \"\$lt_dump_D/\$lt_dump_F\" - exit 0 - ;; - --lt-*) - \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 - exit 1 - ;; - esac - done - - # Print the debug banner immediately: - if test -n \"\$lt_option_debug\"; then - echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 - fi -} - -# Used when --lt-debug. Prints its arguments to stdout -# (redirection is the responsibility of the caller) -func_lt_dump_args () -{ - lt_dump_args_N=1; - for lt_arg - do - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" - lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` - done -} - -# Core function for launching the target application -func_exec_program_core () -{ -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" - ;; - esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 -} - -# A function to encapsulate launching the target application -# Strips options in the --lt-* namespace from \$@ and -# launches target application with the remaining arguments. -func_exec_program () -{ - case \" \$* \" in - *\\ --lt-*) - for lt_wr_arg - do - case \$lt_wr_arg in - --lt-*) ;; - *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; - esac - shift - done ;; - esac - func_exec_program_core \${1+\"\$@\"} -} - - # Parse options - func_parse_lt_options \"\$0\" \${1+\"\$@\"} - - # Find the directory that this script lives in. - thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. - - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` - - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi - - file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` - done - - # Usually 'no', except on cygwin/mingw when embedded into - # the cwrapper. - WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 - if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then - # special case for '.' - if test \"\$thisdir\" = \".\"; then - thisdir=\`pwd\` - fi - # remove .libs from thisdir - case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; - $objdir ) thisdir=. ;; - esac - fi - - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" - - if test "$fast_install" = yes; then - $ECHO "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" - - if test ! -f \"\$progdir/\$program\" || - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then - - file=\"\$\$-\$program\" - - if test ! -d \"\$progdir\"; then - $MKDIR \"\$progdir\" - else - $RM \"\$progdir/\$file\" - fi" - - $ECHO "\ - - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - $ECHO \"\$relink_command_output\" >&2 - $RM \"\$progdir/\$file\" - exit 1 - fi - fi - - $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $RM \"\$progdir/\$program\"; - $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $RM \"\$progdir/\$file\" - fi" - else - $ECHO "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" - fi - - $ECHO "\ - - if test -f \"\$progdir/\$program\"; then" - - # fixup the dll searchpath if we need to. - # - # Fix the DLL searchpath if we need to. Do this before prepending - # to shlibpath, because on Windows, both are PATH and uninstalled - # libraries must come first. - if test -n "$dllsearchpath"; then - $ECHO "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" - fi - - # Export our shlibpath_var if we have one. - if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $ECHO "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` - - export $shlibpath_var -" - fi - - $ECHO "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. - func_exec_program \${1+\"\$@\"} - fi - else - # The program doesn't exist. - \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 - \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 - \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 - exit 1 - fi -fi\ -" -} - - -# func_emit_cwrapperexe_src -# emit the source code for a wrapper executable on stdout -# Must ONLY be called from within func_mode_link because -# it depends on a number of variable set therein. -func_emit_cwrapperexe_src () -{ - cat < -#include -#ifdef _MSC_VER -# include -# include -# include -#else -# include -# include -# ifdef __CYGWIN__ -# include -# endif -#endif -#include -#include -#include -#include -#include -#include -#include -#include - -/* declarations of non-ANSI functions */ -#if defined(__MINGW32__) -# ifdef __STRICT_ANSI__ -int _putenv (const char *); -# endif -#elif defined(__CYGWIN__) -# ifdef __STRICT_ANSI__ -char *realpath (const char *, char *); -int putenv (char *); -int setenv (const char *, const char *, int); -# endif -/* #elif defined (other platforms) ... */ -#endif - -/* portability defines, excluding path handling macros */ -#if defined(_MSC_VER) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -# define S_IXUSR _S_IEXEC -# ifndef _INTPTR_T_DEFINED -# define _INTPTR_T_DEFINED -# define intptr_t int -# endif -#elif defined(__MINGW32__) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -#elif defined(__CYGWIN__) -# define HAVE_SETENV -# define FOPEN_WB "wb" -/* #elif defined (other platforms) ... */ -#endif - -#if defined(PATH_MAX) -# define LT_PATHMAX PATH_MAX -#elif defined(MAXPATHLEN) -# define LT_PATHMAX MAXPATHLEN -#else -# define LT_PATHMAX 1024 -#endif - -#ifndef S_IXOTH -# define S_IXOTH 0 -#endif -#ifndef S_IXGRP -# define S_IXGRP 0 -#endif - -/* path handling portability macros */ -#ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' -#endif - -#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ - defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# define FOPEN_WB "wb" -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif -#endif - -#ifndef DIR_SEPARATOR_2 -# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) -#else /* DIR_SEPARATOR_2 */ -# define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) -#endif /* DIR_SEPARATOR_2 */ - -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - -#ifndef FOPEN_WB -# define FOPEN_WB "w" -#endif -#ifndef _O_BINARY -# define _O_BINARY 0 -#endif - -#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) -#define XFREE(stale) do { \ - if (stale) { free ((void *) stale); stale = 0; } \ -} while (0) - -#if defined(LT_DEBUGWRAPPER) -static int lt_debug = 1; -#else -static int lt_debug = 0; -#endif - -const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ - -void *xmalloc (size_t num); -char *xstrdup (const char *string); -const char *base_name (const char *name); -char *find_executable (const char *wrapper); -char *chase_symlinks (const char *pathspec); -int make_executable (const char *path); -int check_executable (const char *path); -char *strendzap (char *str, const char *pat); -void lt_debugprintf (const char *file, int line, const char *fmt, ...); -void lt_fatal (const char *file, int line, const char *message, ...); -static const char *nonnull (const char *s); -static const char *nonempty (const char *s); -void lt_setenv (const char *name, const char *value); -char *lt_extend_str (const char *orig_value, const char *add, int to_end); -void lt_update_exe_path (const char *name, const char *value); -void lt_update_lib_path (const char *name, const char *value); -char **prepare_spawn (char **argv); -void lt_dump_script (FILE *f); -EOF - - cat <= 0) - && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) - return 1; - else - return 0; -} - -int -make_executable (const char *path) -{ - int rval = 0; - struct stat st; - - lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", - nonempty (path)); - if ((!path) || (!*path)) - return 0; - - if (stat (path, &st) >= 0) - { - rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); - } - return rval; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise - Does not chase symlinks, even on platforms that support them. -*/ -char * -find_executable (const char *wrapper) -{ - int has_slash = 0; - const char *p; - const char *p_next; - /* static buffer for getcwd */ - char tmp[LT_PATHMAX + 1]; - int tmp_len; - char *concat_name; - - lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", - nonempty (wrapper)); - - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; - - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } -#endif - - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char *path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char *q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR (*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = - XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = - XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - return NULL; -} - -char * -chase_symlinks (const char *pathspec) -{ -#ifndef S_ISLNK - return xstrdup (pathspec); -#else - char buf[LT_PATHMAX]; - struct stat s; - char *tmp_pathspec = xstrdup (pathspec); - char *p; - int has_symlinks = 0; - while (strlen (tmp_pathspec) && !has_symlinks) - { - lt_debugprintf (__FILE__, __LINE__, - "checking path component for symlinks: %s\n", - tmp_pathspec); - if (lstat (tmp_pathspec, &s) == 0) - { - if (S_ISLNK (s.st_mode) != 0) - { - has_symlinks = 1; - break; - } - - /* search backwards for last DIR_SEPARATOR */ - p = tmp_pathspec + strlen (tmp_pathspec) - 1; - while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - p--; - if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - { - /* no more DIR_SEPARATORS left */ - break; - } - *p = '\0'; - } - else - { - lt_fatal (__FILE__, __LINE__, - "error accessing file \"%s\": %s", - tmp_pathspec, nonnull (strerror (errno))); - } - } - XFREE (tmp_pathspec); - - if (!has_symlinks) - { - return xstrdup (pathspec); - } - - tmp_pathspec = realpath (pathspec, buf); - if (tmp_pathspec == 0) - { - lt_fatal (__FILE__, __LINE__, - "could not follow symlinks for %s", pathspec); - } - return xstrdup (tmp_pathspec); -#endif -} - -char * -strendzap (char *str, const char *pat) -{ - size_t len, patlen; - - assert (str != NULL); - assert (pat != NULL); - - len = strlen (str); - patlen = strlen (pat); - - if (patlen <= len) - { - str += len - patlen; - if (strcmp (str, pat) == 0) - *str = '\0'; - } - return str; -} - -void -lt_debugprintf (const char *file, int line, const char *fmt, ...) -{ - va_list args; - if (lt_debug) - { - (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); - va_start (args, fmt); - (void) vfprintf (stderr, fmt, args); - va_end (args); - } -} - -static void -lt_error_core (int exit_status, const char *file, - int line, const char *mode, - const char *message, va_list ap) -{ - fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); - vfprintf (stderr, message, ap); - fprintf (stderr, ".\n"); - - if (exit_status >= 0) - exit (exit_status); -} - -void -lt_fatal (const char *file, int line, const char *message, ...) -{ - va_list ap; - va_start (ap, message); - lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); - va_end (ap); -} - -static const char * -nonnull (const char *s) -{ - return s ? s : "(null)"; -} - -static const char * -nonempty (const char *s) -{ - return (s && !*s) ? "(empty)" : nonnull (s); -} - -void -lt_setenv (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_setenv) setting '%s' to '%s'\n", - nonnull (name), nonnull (value)); - { -#ifdef HAVE_SETENV - /* always make a copy, for consistency with !HAVE_SETENV */ - char *str = xstrdup (value); - setenv (name, str, 1); -#else - int len = strlen (name) + 1 + strlen (value) + 1; - char *str = XMALLOC (char, len); - sprintf (str, "%s=%s", name, value); - if (putenv (str) != EXIT_SUCCESS) - { - XFREE (str); - } -#endif - } -} - -char * -lt_extend_str (const char *orig_value, const char *add, int to_end) -{ - char *new_value; - if (orig_value && *orig_value) - { - int orig_value_len = strlen (orig_value); - int add_len = strlen (add); - new_value = XMALLOC (char, add_len + orig_value_len + 1); - if (to_end) - { - strcpy (new_value, orig_value); - strcpy (new_value + orig_value_len, add); - } - else - { - strcpy (new_value, add); - strcpy (new_value + add_len, orig_value); - } - } - else - { - new_value = xstrdup (add); - } - return new_value; -} - -void -lt_update_exe_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - /* some systems can't cope with a ':'-terminated path #' */ - int len = strlen (new_value); - while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) - { - new_value[len-1] = '\0'; - } - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -void -lt_update_lib_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -EOF - case $host_os in - mingw*) - cat <<"EOF" - -/* Prepares an argument vector before calling spawn(). - Note that spawn() does not by itself call the command interpreter - (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : - ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); - GetVersionEx(&v); - v.dwPlatformId == VER_PLATFORM_WIN32_NT; - }) ? "cmd.exe" : "command.com"). - Instead it simply concatenates the arguments, separated by ' ', and calls - CreateProcess(). We must quote the arguments since Win32 CreateProcess() - interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a - special way: - - Space and tab are interpreted as delimiters. They are not treated as - delimiters if they are surrounded by double quotes: "...". - - Unescaped double quotes are removed from the input. Their only effect is - that within double quotes, space and tab are treated like normal - characters. - - Backslashes not followed by double quotes are not special. - - But 2*n+1 backslashes followed by a double quote become - n backslashes followed by a double quote (n >= 0): - \" -> " - \\\" -> \" - \\\\\" -> \\" - */ -#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" -#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" -char ** -prepare_spawn (char **argv) -{ - size_t argc; - char **new_argv; - size_t i; - - /* Count number of arguments. */ - for (argc = 0; argv[argc] != NULL; argc++) - ; - - /* Allocate new argument vector. */ - new_argv = XMALLOC (char *, argc + 1); - - /* Put quoted arguments into the new argument vector. */ - for (i = 0; i < argc; i++) - { - const char *string = argv[i]; - - if (string[0] == '\0') - new_argv[i] = xstrdup ("\"\""); - else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) - { - int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); - size_t length; - unsigned int backslashes; - const char *s; - char *quoted_string; - char *p; - - length = 0; - backslashes = 0; - if (quote_around) - length++; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - length += backslashes + 1; - length++; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - length += backslashes + 1; - - quoted_string = XMALLOC (char, length + 1); - - p = quoted_string; - backslashes = 0; - if (quote_around) - *p++ = '"'; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - { - unsigned int j; - for (j = backslashes + 1; j > 0; j--) - *p++ = '\\'; - } - *p++ = c; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - { - unsigned int j; - for (j = backslashes; j > 0; j--) - *p++ = '\\'; - *p++ = '"'; - } - *p = '\0'; - - new_argv[i] = quoted_string; - } - else - new_argv[i] = (char *) string; - } - new_argv[argc] = NULL; - - return new_argv; -} -EOF - ;; - esac - - cat <<"EOF" -void lt_dump_script (FILE* f) -{ -EOF - func_emit_wrapper yes | - $SED -n -e ' -s/^\(.\{79\}\)\(..*\)/\1\ -\2/ -h -s/\([\\"]\)/\\\1/g -s/$/\\n/ -s/\([^\n]*\).*/ fputs ("\1", f);/p -g -D' - cat <<"EOF" -} -EOF -} -# end: func_emit_cwrapperexe_src - -# func_win32_import_lib_p ARG -# True if ARG is an import lib, as indicated by $file_magic_cmd -func_win32_import_lib_p () -{ - $opt_debug - case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in - *import*) : ;; - *) false ;; - esac -} - -# func_mode_link arg... -func_mode_link () -{ - $opt_debug - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - # It is impossible to link a dll without this setting, and - # we shouldn't force the makefile maintainer to figure out - # which system we are compiling for in order to pass an extra - # flag for every libtool invocation. - # allow_undefined=no - - # FIXME: Unfortunately, there are problems with the above when trying - # to make a dll which has undefined symbols, in which case not - # even a static library is built. For now, we need to specify - # -no-undefined on the libtool link line when we can be certain - # that all symbols are satisfied, otherwise we get a static library. - allow_undefined=yes - ;; - *) - allow_undefined=yes - ;; - esac - libtool_args=$nonopt - base_compile="$nonopt $@" - compile_command=$nonopt - finalize_command=$nonopt - - compile_rpath= - finalize_rpath= - compile_shlibpath= - finalize_shlibpath= - convenience= - old_convenience= - deplibs= - old_deplibs= - compiler_flags= - linker_flags= - dllsearchpath= - lib_search_path=`pwd` - inst_prefix_dir= - new_inherited_linker_flags= - - avoid_version=no - bindir= - dlfiles= - dlprefiles= - dlself=no - export_dynamic=no - export_symbols= - export_symbols_regex= - generated= - libobjs= - ltlibs= - module=no - no_install=no - objs= - non_pic_objects= - precious_files_regex= - prefer_static_libs=no - preload=no - prev= - prevarg= - release= - rpath= - xrpath= - perm_rpath= - temp_rpath= - thread_safe=no - vinfo= - vinfo_number=no - weak_libs= - single_module="${wl}-single_module" - func_infer_tag $base_compile - - # We need to know -static, to get the right output filenames. - for arg - do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - break - ;; - -all-static | -static | -static-libtool-libs) - case $arg in - -all-static) - if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then - func_warning "complete static linking is impossible in this configuration" - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - -static) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=built - ;; - -static-libtool-libs) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - esac - build_libtool_libs=no - build_old_libs=yes - break - ;; - esac - done - - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes - - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg="$1" - shift - func_quote_for_eval "$arg" - qarg=$func_quote_for_eval_unquoted_result - func_append libtool_args " $func_quote_for_eval_result" - - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - func_append compile_command " @OUTPUT@" - func_append finalize_command " @OUTPUT@" - ;; - esac - - case $prev in - bindir) - bindir="$arg" - prev= - continue - ;; - dlfiles|dlprefiles) - if test "$preload" = no; then - # Add the symbol object into the linking commands. - func_append compile_command " @SYMFILE@" - func_append finalize_command " @SYMFILE@" - preload=yes - fi - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test "$dlself" = no; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test "$prev" = dlprefiles; then - dlself=yes - elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test "$prev" = dlfiles; then - func_append dlfiles " $arg" - else - func_append dlprefiles " $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols="$arg" - test -f "$arg" \ - || func_fatal_error "symbol file \`$arg' does not exist" - prev= - continue - ;; - expsyms_regex) - export_symbols_regex="$arg" - prev= - continue - ;; - framework) - case $host in - *-*-darwin*) - case "$deplibs " in - *" $qarg.ltframework "*) ;; - *) func_append deplibs " $qarg.ltframework" # this is fixed later - ;; - esac - ;; - esac - prev= - continue - ;; - inst_prefix) - inst_prefix_dir="$arg" - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat "$save_arg"` - do -# func_append moreargs " $fil" - arg=$fil - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - done - else - func_fatal_error "link input file \`$arg' does not exist" - fi - arg=$save_arg - prev= - continue - ;; - precious_regex) - precious_files_regex="$arg" - prev= - continue - ;; - release) - release="-$arg" - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - if test "$prev" = rpath; then - case "$rpath " in - *" $arg "*) ;; - *) func_append rpath " $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) func_append xrpath " $arg" ;; - esac - fi - prev= - continue - ;; - shrext) - shrext_cmds="$arg" - prev= - continue - ;; - weak) - func_append weak_libs " $arg" - prev= - continue - ;; - xcclinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xcompiler) - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xlinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $wl$qarg" - prev= - func_append compile_command " $wl$qarg" - func_append finalize_command " $wl$qarg" - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" - - prevarg="$arg" - - case $arg in - -all-static) - if test -n "$link_static_flag"; then - # See comment for -static flag below, for more details. - func_append compile_command " $link_static_flag" - func_append finalize_command " $link_static_flag" - fi - continue - ;; - - -allow-undefined) - # FIXME: remove this flag sometime in the future. - func_fatal_error "\`-allow-undefined' must not be used because it is the default" - ;; - - -avoid-version) - avoid_version=yes - continue - ;; - - -bindir) - prev=bindir - continue - ;; - - -dlopen) - prev=dlfiles - continue - ;; - - -dlpreopen) - prev=dlprefiles - continue - ;; - - -export-dynamic) - export_dynamic=yes - continue - ;; - - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - func_fatal_error "more than one -exported-symbols argument is not allowed" - fi - if test "X$arg" = "X-export-symbols"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; - - -framework) - prev=framework - continue - ;; - - -inst-prefix-dir) - prev=inst_prefix - continue - ;; - - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - func_append compile_command " $arg" - func_append finalize_command " $arg" - ;; - esac - continue - ;; - - -L*) - func_stripname "-L" '' "$arg" - if test -z "$func_stripname_result"; then - if test "$#" -gt 0; then - func_fatal_error "require no space between \`-L' and \`$1'" - else - func_fatal_error "need path for \`-L' option" - fi - fi - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - test -z "$absdir" && \ - func_fatal_error "cannot determine absolute directory name of \`$dir'" - dir="$absdir" - ;; - esac - case "$deplibs " in - *" -L$dir "* | *" $arg "*) - # Will only happen for absolute or sysroot arguments - ;; - *) - # Preserve sysroot, but never include relative directories - case $dir in - [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; - *) func_append deplibs " -L$dir" ;; - esac - func_append lib_search_path " $dir" - ;; - esac - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$dir:"*) ;; - ::) dllsearchpath=$dir;; - *) func_append dllsearchpath ":$dir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - continue - ;; - - -l*) - if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test "X$arg" = "X-lc" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - test "X$arg" = "X-lc" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - func_append deplibs " System.ltframework" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; - esac - elif test "X$arg" = "X-lc_r"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac - fi - func_append deplibs " $arg" - continue - ;; - - -module) - module=yes - continue - ;; - - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot|--sysroot) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - prev=xcompiler - continue - ;; - - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) func_append new_inherited_linker_flags " $arg" ;; - esac - continue - ;; - - -multi_module) - single_module="${wl}-multi_module" - continue - ;; - - -no-fast-install) - fast_install=no - continue - ;; - - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) - # The PATH hackery in wrapper scripts is required on Windows - # and Darwin in order for the loader to find any dlls it needs. - func_warning "\`-no-install' is ignored for $host" - func_warning "assuming \`-no-fast-install' instead" - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; - - -no-undefined) - allow_undefined=no - continue - ;; - - -objectlist) - prev=objectlist - continue - ;; - - -o) prev=output ;; - - -precious-files-regex) - prev=precious_regex - continue - ;; - - -release) - prev=release - continue - ;; - - -rpath) - prev=rpath - continue - ;; - - -R) - prev=xrpath - continue - ;; - - -R*) - func_stripname '-R' '' "$arg" - dir=$func_stripname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - =*) - func_stripname '=' '' "$dir" - dir=$lt_sysroot$func_stripname_result - ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - continue - ;; - - -shared) - # The effects of -shared are defined in a previous loop. - continue - ;; - - -shrext) - prev=shrext - continue - ;; - - -static | -static-libtool-libs) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; - - -thread-safe) - thread_safe=yes - continue - ;; - - -version-info) - prev=vinfo - continue - ;; - - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; - - -weak) - prev=weak - continue - ;; - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $func_quote_for_eval_result" - func_append compiler_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Wl,*) - func_stripname '-Wl,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $wl$func_quote_for_eval_result" - func_append compiler_flags " $wl$func_quote_for_eval_result" - func_append linker_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Xcompiler) - prev=xcompiler - continue - ;; - - -Xlinker) - prev=xlinker - continue - ;; - - -XCClinker) - prev=xcclinker - continue - ;; - - # -msg_* for osf cc - -msg_*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - # Flags to be passed through unchanged, with rationale: - # -64, -mips[0-9] enable 64-bit mode for the SGI compiler - # -r[0-9][0-9]* specify processor for the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler - # +DA*, +DD* enable 64-bit mode for the HP compiler - # -q* compiler args for the IBM compiler - # -m*, -t[45]*, -txscale* architecture-specific flags for GCC - # -F/path path to uninstalled frameworks, gcc on darwin - # -p, -pg, --coverage, -fprofile-* profiling flags for GCC - # @file GCC response files - # -tp=* Portland pgcc target processor selection - # --sysroot=* for sysroot support - # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ - -O*|-flto*|-fwhopr*|-fuse-linker-plugin) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - func_append compile_command " $arg" - func_append finalize_command " $arg" - func_append compiler_flags " $arg" - continue - ;; - - # Some other compiler flag. - -* | +*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - *.$objext) - # A standard object. - func_append objs " $arg" - ;; - - *.lo) - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - ;; - - *.$libext) - # An archive. - func_append deplibs " $arg" - func_append old_deplibs " $arg" - continue - ;; - - *.la) - # A libtool-controlled library. - - func_resolve_sysroot "$arg" - if test "$prev" = dlfiles; then - # This library was specified with -dlopen. - func_append dlfiles " $func_resolve_sysroot_result" - prev= - elif test "$prev" = dlprefiles; then - # The library was specified with -dlpreopen. - func_append dlprefiles " $func_resolve_sysroot_result" - prev= - else - func_append deplibs " $func_resolve_sysroot_result" - fi - continue - ;; - - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - esac # arg - - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - done # argument parsing loop - - test -n "$prev" && \ - func_fatal_help "the \`$prevarg' option requires an argument" - - if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - - oldlibs= - # calculate the name of the file, without its directory - func_basename "$output" - outputname="$func_basename_result" - libobjs_save="$libobjs" - - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - - func_dirname "$output" "/" "" - output_objdir="$func_dirname_result$objdir" - func_to_tool_file "$output_objdir/" - tool_output_objdir=$func_to_tool_file_result - # Create the object directory. - func_mkdir_p "$output_objdir" - - # Determine the type of output - case $output in - "") - func_fatal_help "you must specify an output file" - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac - - specialdeplibs= - - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if $opt_preserve_dup_deps ; then - case "$libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append libs " $deplib" - done - - if test "$linkmode" = lib; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" - - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if $opt_duplicate_compiler_generated_deps; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; - esac - func_append pre_post_deps " $pre_post_dep" - done - fi - pre_post_deps= - fi - - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - notinst_path= # paths that contain not-installed libtool libraries - - case $linkmode in - lib) - passes="conv dlpreopen link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=no - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac - - for pass in $passes; do - # The preopen pass in lib mode reverses $deplibs; put it back here - # so that -L comes before libs that need it for instance... - if test "$linkmode,$pass" = "lib,link"; then - ## FIXME: Find the place where the list is rebuilt in the wrong - ## order, and fix it there properly - tmp_deplibs= - for deplib in $deplibs; do - tmp_deplibs="$deplib $tmp_deplibs" - done - deplibs="$tmp_deplibs" - fi - - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan"; then - libs="$deplibs" - deplibs= - fi - if test "$linkmode" = prog; then - case $pass in - dlopen) libs="$dlfiles" ;; - dlpreopen) libs="$dlprefiles" ;; - link) - libs="$deplibs %DEPLIBS%" - test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" - ;; - esac - fi - if test "$linkmode,$pass" = "lib,dlpreopen"; then - # Collect and forward deplibs of preopened libtool libs - for lib in $dlprefiles; do - # Ignore non-libtool-libs - dependency_libs= - func_resolve_sysroot "$lib" - case $lib in - *.la) func_source "$func_resolve_sysroot_result" ;; - esac - - # Collect preopened libtool deplibs, except any this library - # has declared as weak libs - for deplib in $dependency_libs; do - func_basename "$deplib" - deplib_base=$func_basename_result - case " $weak_libs " in - *" $deplib_base "*) ;; - *) func_append deplibs " $deplib" ;; - esac - done - done - libs="$dlprefiles" - fi - if test "$pass" = dlopen; then - # Collect dlpreopened libraries - save_deplibs="$deplibs" - deplibs= - fi - - for deplib in $libs; do - lib= - found=no - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append compiler_flags " $deplib" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -l*) - if test "$linkmode" != lib && test "$linkmode" != prog; then - func_warning "\`-l' is ignored for archives/objects" - continue - fi - func_stripname '-l' '' "$deplib" - name=$func_stripname_result - if test "$linkmode" = lib; then - searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" - else - searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" - fi - for searchdir in $searchdirs; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib="$searchdir/lib${name}${search_ext}" - if test -f "$lib"; then - if test "$search_ext" = ".la"; then - found=yes - else - found=no - fi - break 2 - fi - done - done - if test "$found" != yes; then - # deplib doesn't seem to be a libtool library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - else # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $deplib "*) - if func_lalib_p "$lib"; then - library_names= - old_library= - func_source "$lib" - for l in $old_library $library_names; do - ll="$l" - done - if test "X$ll" = "X$old_library" ; then # only static version available - found=no - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - lib=$ladir/$old_library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - fi - ;; # -l - *.ltframework) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test "$pass" = conv && continue - newdependency_libs="$deplib $newdependency_libs" - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - prog) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - if test "$pass" = scan; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - *) - func_warning "\`-L' is ignored for archives/objects" - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test "$pass" = link; then - func_stripname '-R' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) - func_resolve_sysroot "$deplib" - lib=$func_resolve_sysroot_result - ;; - *.$libext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - # Linking convenience modules into shared libraries is allowed, - # but linking other static libraries is non-portable. - case " $dlpreconveniencelibs " in - *" $deplib "*) ;; - *) - valid_a_lib=no - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=yes - fi - ;; - pass_all) - valid_a_lib=yes - ;; - esac - if test "$valid_a_lib" != yes; then - echo - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because the file extensions .$libext of this argument makes me believe" - echo "*** that it is just a static archive that I should not use here." - else - echo - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - fi - ;; - esac - continue - ;; - prog) - if test "$pass" != link; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - elif test "$linkmode" = prog; then - if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - func_append newdlprefiles " $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append newdlfiles " $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=yes - continue - ;; - esac # case $deplib - - if test "$found" = yes || test -f "$lib"; then : - else - func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" - fi - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$lib" \ - || func_fatal_error "\`$lib' is not a valid libtool archive" - - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - - dlname= - dlopen= - dlpreopen= - libdir= - library_names= - old_library= - inherited_linker_flags= - # If the library was installed with an old release of libtool, - # it will not redefine variables installed, or shouldnotlink - installed=yes - shouldnotlink=no - avoidtemprpath= - - - # Read the .la file - func_source "$lib" - - # Convert "-framework foo" to "foo.ltframework" - if test -n "$inherited_linker_flags"; then - tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` - for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do - case " $new_inherited_linker_flags " in - *" $tmp_inherited_linker_flag "*) ;; - *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; - esac - done - fi - dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan" || - { test "$linkmode" != prog && test "$linkmode" != lib; }; then - test -n "$dlopen" && func_append dlfiles " $dlopen" - test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" - fi - - if test "$pass" = conv; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - # It is a libtool convenience library, so add in its objects. - func_append convenience " $ladir/$objdir/$old_library" - func_append old_convenience " $ladir/$objdir/$old_library" - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done - elif test "$linkmode" != prog && test "$linkmode" != lib; then - func_fatal_error "\`$lib' is not a convenience library" - fi - continue - fi # $pass = conv - - - # Get the name of the library we link against. - linklib= - if test -n "$old_library" && - { test "$prefer_static_libs" = yes || - test "$prefer_static_libs,$installed" = "built,no"; }; then - linklib=$old_library - else - for l in $old_library $library_names; do - linklib="$l" - done - fi - if test -z "$linklib"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - - # This library was specified with -dlopen. - if test "$pass" = dlopen; then - if test -z "$libdir"; then - func_fatal_error "cannot -dlopen a convenience library: \`$lib'" - fi - if test -z "$dlname" || - test "$dlopen_support" != yes || - test "$build_libtool_libs" = no; then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - func_append dlprefiles " $lib $dependency_libs" - else - func_append newdlfiles " $lib" - fi - continue - fi # $pass = dlopen - - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - func_warning "cannot determine absolute directory name of \`$ladir'" - func_warning "passing it literally to the linker, although it might fail" - abs_ladir="$ladir" - fi - ;; - esac - func_basename "$lib" - laname="$func_basename_result" - - # Find the relevant object directory and library name. - if test "X$installed" = Xyes; then - if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - func_warning "library \`$lib' was moved." - dir="$ladir" - absdir="$abs_ladir" - libdir="$abs_ladir" - else - dir="$lt_sysroot$libdir" - absdir="$lt_sysroot$libdir" - fi - test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir="$ladir" - absdir="$abs_ladir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - else - dir="$ladir/$objdir" - absdir="$abs_ladir/$objdir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - fi - fi # $installed = yes - func_stripname 'lib' '.la' "$laname" - name=$func_stripname_result - - # This library was specified with -dlpreopen. - if test "$pass" = dlpreopen; then - if test -z "$libdir" && test "$linkmode" = prog; then - func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" - fi - case "$host" in - # special handling for platforms with PE-DLLs. - *cygwin* | *mingw* | *cegcc* ) - # Linker will automatically link against shared library if both - # static and shared are present. Therefore, ensure we extract - # symbols from the import library if a shared library is present - # (otherwise, the dlopen module name will be incorrect). We do - # this by putting the import library name into $newdlprefiles. - # We recover the dlopen module name by 'saving' the la file - # name in a special purpose variable, and (later) extracting the - # dlname from the la file. - if test -n "$dlname"; then - func_tr_sh "$dir/$linklib" - eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" - func_append newdlprefiles " $dir/$linklib" - else - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - fi - ;; - * ) - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - func_append newdlprefiles " $dir/$dlname" - else - func_append newdlprefiles " $dir/$linklib" - fi - ;; - esac - fi # $pass = dlpreopen - - if test -z "$libdir"; then - # Link the convenience library - if test "$linkmode" = lib; then - deplibs="$dir/$old_library $deplibs" - elif test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi - - - if test "$linkmode" = prog && test "$pass" != link; then - func_append newlib_search_path " $ladir" - deplibs="$lib $deplibs" - - linkalldeplibs=no - if test "$link_all_deplibs" != no || test -z "$library_names" || - test "$build_libtool_libs" = no; then - linkalldeplibs=yes - fi - - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - esac - # Need to link against all dependency_libs? - if test "$linkalldeplibs" = yes; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done # for deplib - continue - fi # $linkmode = prog... - - if test "$linkmode,$pass" = "prog,link"; then - if test -n "$library_names" && - { { test "$prefer_static_libs" = no || - test "$prefer_static_libs,$installed" = "built,yes"; } || - test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then - # Make sure the rpath contains only unique directories. - case "$temp_rpath:" in - *"$absdir:"*) ;; - *) func_append temp_rpath "$absdir:" ;; - esac - fi - - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi # $linkmode,$pass = prog,link... - - if test "$alldeplibs" = yes && - { test "$deplibs_check_method" = pass_all || - { test "$build_libtool_libs" = yes && - test -n "$library_names"; }; }; then - # We only need to search for static libraries - continue - fi - fi - - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes; then - use_static_libs=no - fi - if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc*) - # No point in relinking DLLs because paths are not encoded - func_append notinst_deplibs " $lib" - need_relink=no - ;; - *) - if test "$installed" = no; then - func_append notinst_deplibs " $lib" - need_relink=yes - fi - ;; - esac - # This is a shared library - - # Warn about portability, can't link against -module's on some - # systems (darwin). Don't bleat about dlopened modules though! - dlopenmodule="" - for dlpremoduletest in $dlprefiles; do - if test "X$dlpremoduletest" = "X$lib"; then - dlopenmodule="$dlpremoduletest" - break - fi - done - if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then - echo - if test "$linkmode" = prog; then - $ECHO "*** Warning: Linking the executable $output against the loadable module" - else - $ECHO "*** Warning: Linking the shared library $output against the loadable module" - fi - $ECHO "*** $linklib is not portable!" - fi - if test "$linkmode" = lib && - test "$hardcode_into_libs" = yes; then - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi - - if test -n "$old_archive_from_expsyms_cmds"; then - # figure out the soname - set dummy $library_names - shift - realname="$1" - shift - libname=`eval "\\$ECHO \"$libname_spec\""` - # use dlname if we got it. it's perfectly good, no? - if test -n "$dlname"; then - soname="$dlname" - elif test -n "$soname_spec"; then - # bleh windows - case $host in - *cygwin* | mingw* | *cegcc*) - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - esac - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - - # Make a new name for the extract_expsyms_cmds to use - soroot="$soname" - func_basename "$soroot" - soname="$func_basename_result" - func_stripname 'lib' '.dll' "$soname" - newlib=libimp-$func_stripname_result.a - - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - func_verbose "extracting exported symbol list from \`$soname'" - func_execute_cmds "$extract_expsyms_cmds" 'exit $?' - fi - - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - func_verbose "generating import library for \`$soname'" - func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" - - if test "$linkmode" = prog || test "$opt_mode" != relink; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test "$hardcode_direct" = no; then - add="$dir/$linklib" - case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; - *-*-darwin* ) - # if the lib is a (non-dlopened) module then we can not - # link against it, someone is ignoring the earlier warnings - if /usr/bin/file -L $add 2> /dev/null | - $GREP ": [^:]* bundle" >/dev/null ; then - if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" - if test -z "$old_library" ; then - echo - echo "*** And there doesn't seem to be a static archive available" - echo "*** The link will probably fail, sorry" - else - add="$dir/$old_library" - fi - elif test -n "$old_library"; then - add="$dir/$old_library" - fi - fi - esac - elif test "$hardcode_minus_L" = no; then - case $host in - *-*-sunos*) add_shlibpath="$dir" ;; - esac - add_dir="-L$dir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = no; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - relink) - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$dir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$absdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac - - if test "$lib_linked" != yes; then - func_fatal_configuration "unsupported hardcode properties" - fi - - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) func_append compile_shlibpath "$add_shlibpath:" ;; - esac - fi - if test "$linkmode" = prog; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test "$hardcode_direct" != yes && - test "$hardcode_minus_L" != yes && - test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - fi - fi - fi - - if test "$linkmode" = prog || test "$opt_mode" = relink; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$libdir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$libdir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - add="-l$name" - elif test "$hardcode_automatic" = yes; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib" ; then - add="$inst_prefix_dir$libdir/$linklib" - else - add="$libdir/$linklib" - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir="-L$libdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - fi - - if test "$linkmode" = prog; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test "$linkmode" = prog; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test "$hardcode_direct" != unsupported; then - test -n "$old_library" && linklib="$old_library" - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test "$build_libtool_libs" = yes; then - # Not a shared library - if test "$deplibs_check_method" != pass_all; then - # We're trying link a shared library against a static one - # but the system doesn't support it. - - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - echo - $ECHO "*** Warning: This system can not link to static lib archive $lib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have." - if test "$module" = yes; then - echo "*** But as you try to build a module library, libtool will still create " - echo "*** a static module, that should work as long as the dlopening application" - echo "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? - - if test "$linkmode" = lib; then - if test -n "$dependency_libs" && - { test "$hardcode_into_libs" != yes || - test "$build_old_libs" = yes || - test "$link_static" = yes; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) func_stripname '-R' '' "$libdir" - temp_xrpath=$func_stripname_result - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) func_append xrpath " $temp_xrpath";; - esac;; - *) func_append temp_deplibs " $libdir";; - esac - done - dependency_libs="$temp_deplibs" - fi - - func_append newlib_search_path " $absdir" - # Link against this library - test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result";; - *) func_resolve_sysroot "$deplib" ;; - esac - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $func_resolve_sysroot_result "*) - func_append specialdeplibs " $func_resolve_sysroot_result" ;; - esac - fi - func_append tmp_libs " $func_resolve_sysroot_result" - done - - if test "$link_all_deplibs" != no; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - path= - case $deplib in - -L*) path="$deplib" ;; - *.la) - func_resolve_sysroot "$deplib" - deplib=$func_resolve_sysroot_result - func_dirname "$deplib" "" "." - dir=$func_dirname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - func_warning "cannot determine absolute directory name of \`$dir'" - absdir="$dir" - fi - ;; - esac - if $GREP "^installed=no" $deplib > /dev/null; then - case $host in - *-*-darwin*) - depdepl= - eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names" ; then - for tmp in $deplibrary_names ; do - depdepl=$tmp - done - if test -f "$absdir/$objdir/$depdepl" ; then - depdepl="$absdir/$objdir/$depdepl" - darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - if test -z "$darwin_install_name"; then - darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - fi - func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" - func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" - path= - fi - fi - ;; - *) - path="-L$absdir/$objdir" - ;; - esac - else - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - test "$absdir" != "$libdir" && \ - func_warning "\`$deplib' seems to be moved" - - path="-L$absdir" - fi - ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - if test "$pass" = link; then - if test "$linkmode" = "prog"; then - compile_deplibs="$new_inherited_linker_flags $compile_deplibs" - finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" - else - compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - fi - fi - dependency_libs="$newdependency_libs" - if test "$pass" = dlpreopen; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test "$pass" != dlopen; then - if test "$pass" != conv; then - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) func_append lib_search_path " $dir" ;; - esac - done - newlib_search_path= - fi - - if test "$linkmode,$pass" != "prog,link"; then - vars="deplibs" - else - vars="compile_deplibs finalize_deplibs" - fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) func_append tmp_libs " $deplib" ;; - esac - ;; - *) func_append tmp_libs " $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs ; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i="" - ;; - esac - if test -n "$i" ; then - func_append tmp_libs " $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test "$linkmode" = prog; then - dlfiles="$newdlfiles" - fi - if test "$linkmode" = prog || test "$linkmode" = lib; then - dlprefiles="$newdlprefiles" - fi - - case $linkmode in - oldlib) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for archives" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for archives" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for archives" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for archives" - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for archives" - - test -n "$release" && \ - func_warning "\`-release' is ignored for archives" - - test -n "$export_symbols$export_symbols_regex" && \ - func_warning "\`-export-symbols' is ignored for archives" - - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs="$output" - func_append objs "$old_deplibs" - ;; - - lib) - # Make sure we only generate libraries of the form `libNAME.la'. - case $outputname in - lib*) - func_stripname 'lib' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - test "$module" = no && \ - func_fatal_help "libtool library \`$output' must begin with \`lib'" - - if test "$need_lib_prefix" != no; then - # Add the "lib" prefix for modules if required - func_stripname '' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - func_stripname '' '.la' "$outputname" - libname=$func_stripname_result - fi - ;; - esac - - if test -n "$objs"; then - if test "$deplibs_check_method" != pass_all; then - func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" - else - echo - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" - func_append libobjs " $objs" - fi - fi - - test "$dlself" != no && \ - func_warning "\`-dlopen self' is ignored for libtool libraries" - - set dummy $rpath - shift - test "$#" -gt 1 && \ - func_warning "ignoring multiple \`-rpath's for a libtool library" - - install_libdir="$1" - - oldlibs= - if test -z "$rpath"; then - if test "$build_libtool_libs" = yes; then - # Building a libtool convenience library. - # Some compilers have problems with a `.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for convenience libraries" - - test -n "$release" && \ - func_warning "\`-release' is ignored for convenience libraries" - else - - # Parse the version information argument. - save_ifs="$IFS"; IFS=':' - set dummy $vinfo 0 0 0 - shift - IFS="$save_ifs" - - test -n "$7" && \ - func_fatal_help "too many parameters to \`-version-info'" - - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible - - case $vinfo_number in - yes) - number_major="$1" - number_minor="$2" - number_revision="$3" - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # which has an extra 1 added just for fun - # - case $version_type in - # correct linux to gnu/linux during the next big refactor - darwin|linux|osf|windows|none) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_revision" - ;; - freebsd-aout|freebsd-elf|qnx|sunos) - current="$number_major" - revision="$number_minor" - age="0" - ;; - irix|nonstopux) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_minor" - lt_irix_increment=no - ;; - *) - func_fatal_configuration "$modename: unknown library version type \`$version_type'" - ;; - esac - ;; - no) - current="$1" - revision="$2" - age="$3" - ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 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]) ;; - *) - func_error "CURRENT \`$current' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $revision in - 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]) ;; - *) - func_error "REVISION \`$revision' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $age in - 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]) ;; - *) - func_error "AGE \`$age' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - if test "$age" -gt "$current"; then - func_error "AGE \`$age' is greater than the current interface number \`$current'" - func_fatal_error "\`$vinfo' is not valid version information" - fi - - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; - - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - # Darwin ld doesn't like 0 for these options... - func_arith $current + 1 - minor_current=$func_arith_result - xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - ;; - - freebsd-aout) - major=".$current" - versuffix=".$current.$revision"; - ;; - - freebsd-elf) - major=".$current" - versuffix=".$current" - ;; - - irix | nonstopux) - if test "X$lt_irix_increment" = "Xno"; then - func_arith $current - $age - else - func_arith $current - $age + 1 - fi - major=$func_arith_result - - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring="$verstring_prefix$major.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$revision - while test "$loop" -ne 0; do - func_arith $revision - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring_prefix$major.$iface:$verstring" - done - - # Before this point, $major must not contain `.'. - major=.$major - versuffix="$major.$revision" - ;; - - linux) # correct to gnu/linux during the next big refactor - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - ;; - - osf) - func_arith $current - $age - major=.$func_arith_result - versuffix=".$current.$age.$revision" - verstring="$current.$age.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$age - while test "$loop" -ne 0; do - func_arith $current - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring:${iface}.0" - done - - # Make executables depend on our current version. - func_append verstring ":${current}.0" - ;; - - qnx) - major=".$current" - versuffix=".$current" - ;; - - sunos) - major=".$current" - versuffix=".$current.$revision" - ;; - - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 filesystems. - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - - *) - func_fatal_configuration "unknown library version type \`$version_type'" - ;; - esac - - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring="0.0" - ;; - esac - if test "$need_version" = no; then - versuffix= - else - versuffix=".0.0" - fi - fi - - # Remove version info from name if versioning should be avoided - if test "$avoid_version" = yes && test "$need_version" = no; then - major= - versuffix= - verstring="" - fi - - # Check to see if the archive will have undefined symbols. - if test "$allow_undefined" = yes; then - if test "$allow_undefined_flag" = unsupported; then - func_warning "undefined symbols not allowed in $host shared libraries" - build_libtool_libs=no - build_old_libs=yes - fi - else - # Don't allow undefined symbols. - allow_undefined_flag="$no_undefined_flag" - fi - - fi - - func_generate_dlsyms "$libname" "$libname" "yes" - func_append libobjs " $symfileobj" - test "X$libobjs" = "X " && libobjs= - - if test "$opt_mode" != relink; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$ECHO "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext | *.gcno) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) - if test "X$precious_files_regex" != "X"; then - if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - func_append removelist " $p" - ;; - *) ;; - esac - done - test -n "$removelist" && \ - func_show_eval "${RM}r \$removelist" - fi - - # Now set the variables for building old libraries. - if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then - func_append oldlibs " $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` - fi - - # Eliminate all temporary directories. - #for path in $notinst_path; do - # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` - # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` - # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` - #done - - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - func_replace_sysroot "$libdir" - func_append temp_xrpath " -R$func_replace_sysroot_result" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then - dependency_libs="$temp_xrpath $dependency_libs" - fi - fi - - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles="$dlfiles" - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) func_append dlfiles " $lib" ;; - esac - done - - # Make sure dlprefiles contains only unique files - old_dlprefiles="$dlprefiles" - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) func_append dlprefiles " $lib" ;; - esac - done - - if test "$build_libtool_libs" = yes; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - func_append deplibs " System.ltframework" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test "$build_libtool_need_lc" = "yes"; then - func_append deplibs " -lc" - fi - ;; - esac - fi - - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release="" - versuffix="" - major="" - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c </dev/null` - $nocaseglob - else - potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` - fi - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null | - $GREP " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib="$potent_lib" - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | - $SED -e 10q | - $EGREP "$file_magic_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - for a_deplib in $deplibs; do - case $a_deplib in - -l*) - func_stripname -l '' "$a_deplib" - name=$func_stripname_result - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $a_deplib "*) - func_append newdeplibs " $a_deplib" - a_deplib="" - ;; - esac - fi - if test -n "$a_deplib" ; then - libname=`eval "\\$ECHO \"$libname_spec\""` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib="$potent_lib" # see symlink-check above in file_magic test - if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ - $EGREP "$match_pattern_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs="" - tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - for i in $predeps $postdeps ; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` - done - fi - case $tmp_deplibs in - *[!\ \ ]*) - echo - if test "X$deplibs_check_method" = "Xnone"; then - echo "*** Warning: inter-library dependencies are not supported in this platform." - else - echo "*** Warning: inter-library dependencies are not known to be supported." - fi - echo "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes - ;; - esac - ;; - esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library with the System framework - newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - if test "$droppeddeps" = yes; then - if test "$module" = yes; then - echo - echo "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - echo "*** a static module, that should work as long as the dlopening" - echo "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - echo "*** The inter-library dependencies that have been dropped here will be" - echo "*** automatically added whenever a program is linked with this library" - echo "*** or is declared to -dlopen it." - - if test "$allow_undefined" = no; then - echo - echo "*** Since this library must not contain undefined symbols," - echo "*** because either the platform does not support them or" - echo "*** it was explicitly requested with -no-undefined," - echo "*** libtool will only create a static version of it." - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - case $host in - *-*-darwin*) - newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - deplibs="$new_libs" - - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= - - # Test again, we may have decided not to build it any more - if test "$build_libtool_libs" = yes; then - # Remove ${wl} instances when linking with ld. - # FIXME: should test the right _cmds variable. - case $archive_cmds in - *\$LD\ *) wl= ;; - esac - if test "$hardcode_into_libs" = yes; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath="$finalize_rpath" - test "$opt_mode" != relink && rpath="$compile_rpath$rpath" - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - func_replace_sysroot "$libdir" - libdir=$func_replace_sysroot_result - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append dep_rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi - - shlibpath="$finalize_shlibpath" - test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi - - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - shift - realname="$1" - shift - - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - if test -z "$dlname"; then - dlname=$soname - fi - - lib="$output_objdir/$realname" - linknames= - for link - do - func_append linknames " $link" - done - - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` - test "X$libobjs" = "X " && libobjs= - - delfiles= - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" - export_symbols="$output_objdir/$libname.uexp" - func_append delfiles " $export_symbols" - fi - - orig_export_symbols= - case $host_os in - cygwin* | mingw* | cegcc*) - if test -n "$export_symbols" && test -z "$export_symbols_regex"; then - # exporting using user supplied symfile - if test "x`$SED 1q $export_symbols`" != xEXPORTS; then - # and it's NOT already a .def file. Must figure out - # which of the given symbols are data symbols and tag - # them as such. So, trigger use of export_symbols_cmds. - # export_symbols gets reassigned inside the "prepare - # the list of exported symbols" if statement, so the - # include_expsyms logic still works. - orig_export_symbols="$export_symbols" - export_symbols= - always_export_symbols=yes - fi - fi - ;; - esac - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - cmds=$export_symbols_cmds - save_ifs="$IFS"; IFS='~' - for cmd1 in $cmds; do - IFS="$save_ifs" - # Take the normal branch if the nm_file_list_spec branch - # doesn't work or if tool conversion is not needed. - case $nm_file_list_spec~$to_tool_file_cmd in - *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) - try_normal_branch=yes - eval cmd=\"$cmd1\" - func_len " $cmd" - len=$func_len_result - ;; - *) - try_normal_branch=no - ;; - esac - if test "$try_normal_branch" = yes \ - && { test "$len" -lt "$max_cmd_len" \ - || test "$max_cmd_len" -le -1; } - then - func_show_eval "$cmd" 'exit $?' - skipped_export=false - elif test -n "$nm_file_list_spec"; then - func_basename "$output" - output_la=$func_basename_result - save_libobjs=$libobjs - save_output=$output - output=${output_objdir}/${output_la}.nm - func_to_tool_file "$output" - libobjs=$nm_file_list_spec$func_to_tool_file_result - func_append delfiles " $output" - func_verbose "creating $NM input file list: $output" - for obj in $save_libobjs; do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > "$output" - eval cmd=\"$cmd1\" - func_show_eval "$cmd" 'exit $?' - output=$save_output - libobjs=$save_libobjs - skipped_export=false - else - # The command line is too long to execute in one step. - func_verbose "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS="$save_ifs" - if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - fi - - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - func_append tmp_deplibs " $test_deplib" - ;; - esac - done - deplibs="$tmp_deplibs" - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec" && - test "$compiler_needs_object" = yes && - test -z "$libobjs"; then - # extract the archives, so we have objects to list. - # TODO: could optimize this to just extract one archive. - whole_archive_flag_spec= - fi - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - else - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - fi - - if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - func_append linker_flags " $flag" - fi - - # Make a backup of the uninstalled library when relinking - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? - fi - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi - - if test "X$skipped_export" != "X:" && - func_len " $test_cmds" && - len=$func_len_result && - test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise - # or, if using GNU ld and skipped_export is not :, use a linker - # script. - - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - func_basename "$output" - output_la=$func_basename_result - - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - last_robj= - k=1 - - if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then - output=${output_objdir}/${output_la}.lnkscript - func_verbose "creating GNU ld script: $output" - echo 'INPUT (' > $output - for obj in $save_libobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - echo ')' >> $output - func_append delfiles " $output" - func_to_tool_file "$output" - output=$func_to_tool_file_result - elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then - output=${output_objdir}/${output_la}.lnk - func_verbose "creating linker input file list: $output" - : > $output - set x $save_libobjs - shift - firstobj= - if test "$compiler_needs_object" = yes; then - firstobj="$1 " - shift - fi - for obj - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - func_append delfiles " $output" - func_to_tool_file "$output" - output=$firstobj\"$file_list_spec$func_to_tool_file_result\" - else - if test -n "$save_libobjs"; then - func_verbose "creating reloadable object files..." - output=$output_objdir/$output_la-${k}.$objext - eval test_cmds=\"$reload_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - if test "X$objlist" = X || - test "$len" -lt "$max_cmd_len"; then - func_append objlist " $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test "$k" -eq 1 ; then - # The first file doesn't have a previous command to add. - reload_objs=$objlist - eval concat_cmds=\"$reload_cmds\" - else - # All subsequent reloadable object files will link in - # the last one created. - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" - fi - last_robj=$output_objdir/$output_la-${k}.$objext - func_arith $k + 1 - k=$func_arith_result - output=$output_objdir/$output_la-${k}.$objext - objlist=" $obj" - func_len " $last_robj" - func_arith $len0 + $func_len_result - len=$func_arith_result - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\${concat_cmds}$reload_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" - fi - func_append delfiles " $output" - - else - output= - fi - - if ${skipped_export-false}; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - libobjs=$output - # Append the command to create the export file. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - fi - - test -n "$save_libobjs" && - func_verbose "creating a temporary reloadable object file: $output" - - # Loop through the commands generated above and execute them. - save_ifs="$IFS"; IFS='~' - for cmd in $concat_cmds; do - IFS="$save_ifs" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - if test -n "$export_symbols_regex" && ${skipped_export-false}; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - - if ${skipped_export-false}; then - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - fi - - libobjs=$output - # Restore the value of output. - output=$save_output - - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds - else - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds - else - cmds=$archive_cmds - fi - fi - fi - - if test -n "$delfiles"; then - # Append the command to remove temporary files to $cmds. - eval cmds=\"\$cmds~\$RM $delfiles\" - fi - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? - - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - func_show_eval '${RM}r "$gentop"' - fi - fi - - exit $EXIT_SUCCESS - fi - - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' - fi - done - - # If -module or -export-dynamic was specified, set the dlname. - if test "$module" = yes || test "$export_dynamic" = yes; then - # On all known operating systems, these are identical. - dlname="$soname" - fi - fi - ;; - - obj) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for objects" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for objects" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for objects" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for objects" - - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for objects" - - test -n "$release" && \ - func_warning "\`-release' is ignored for objects" - - case $output in - *.lo) - test -n "$objs$old_deplibs" && \ - func_fatal_error "cannot build library object \`$output' from non-libtool objects" - - libobj=$output - func_lo2o "$libobj" - obj=$func_lo2o_result - ;; - *) - libobj= - obj="$output" - ;; - esac - - # Delete the old objects. - $opt_dry_run || $RM $obj $libobj - - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # reload_cmds runs $LD directly, so let us get rid of - # -Wl from whole_archive_flag_spec and hope we can get by with - # turning comma into space.. - wl= - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" - reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` - else - gentop="$output_objdir/${obj}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi - - # If we're not building shared, we need to use non_pic_objs - test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" - - # Create the old-style object. - reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test - - output="$obj" - func_execute_cmds "$reload_cmds" 'exit $?' - - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - fi - - if test "$build_libtool_libs" != yes; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - fi - - if test -n "$pic_flag" || test "$pic_mode" != default; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output="$libobj" - func_execute_cmds "$reload_cmds" 'exit $?' - fi - - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - ;; - - prog) - case $host in - *cygwin*) func_stripname '' '.exe' "$output" - output=$func_stripname_result.exe;; - esac - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for programs" - - test -n "$release" && \ - func_warning "\`-release' is ignored for programs" - - test "$preload" = yes \ - && test "$dlopen_support" = unknown \ - && test "$dlopen_self" = unknown \ - && test "$dlopen_self_static" = unknown && \ - func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - case $host in - *-*-darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - # But is supposedly fixed on 10.4 or later (yay!). - if test "$tagname" = CXX ; then - case ${MACOSX_DEPLOYMENT_TARGET-10.0} in - 10.[0123]) - func_append compile_command " ${wl}-bind_at_load" - func_append finalize_command " ${wl}-bind_at_load" - ;; - esac - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - compile_deplibs="$new_libs" - - - func_append compile_command " $compile_deplibs" - func_append finalize_command " $finalize_deplibs" - - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - fi - - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - ::) dllsearchpath=$libdir;; - *) func_append dllsearchpath ":$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath="$rpath" - - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) func_append finalize_perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath="$rpath" - - if test -n "$libobjs" && test "$build_old_libs" = yes; then - # Transform all the library objects into standard objects. - compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - fi - - func_generate_dlsyms "$outputname" "@PROGRAM@" "no" - - # template prelinking step - if test -n "$prelink_cmds"; then - func_execute_cmds "$prelink_cmds" 'exit $?' - fi - - wrappers_required=yes - case $host in - *cegcc* | *mingw32ce*) - # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. - wrappers_required=no - ;; - *cygwin* | *mingw* ) - if test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - *) - if test "$need_relink" = no || test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - esac - if test "$wrappers_required" = no; then - # Replace the output file specification. - compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - link_command="$compile_command$compile_rpath" - - # We have no uninstalled library dependencies, so finalize right now. - exit_status=0 - func_show_eval "$link_command" 'exit_status=$?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Delete the generated files. - if test -f "$output_objdir/${outputname}S.${objext}"; then - func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' - fi - - exit $exit_status - fi - - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi - - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - func_append rpath "$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - fi - - if test "$no_install" = yes; then - # We don't need to create a wrapper script. - link_command="$compile_var$compile_command$compile_rpath" - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $opt_dry_run || $RM $output - # Link the executable and exit - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - exit $EXIT_SUCCESS - fi - - if test "$hardcode_action" = relink; then - # Fast installation is not supported - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - - func_warning "this platform does not like uninstalled shared libraries" - func_warning "\`$output' will be relinked during installation" - else - if test "$fast_install" != no; then - link_command="$finalize_var$compile_command$finalize_rpath" - if test "$fast_install" = yes; then - relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` - else - # fast_install is set to needless - relink_command= - fi - else - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - fi - fi - - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - - # Delete the old output files. - $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname - - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output_objdir/$outputname" - 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'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Now create the wrapper script. - func_verbose "creating $output" - - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - fi - - # Only actually do things if not in dry run mode. - $opt_dry_run || { - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) func_stripname '' '.exe' "$output" - output=$func_stripname_result ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - func_stripname '' '.exe' "$outputname" - outputname=$func_stripname_result ;; - *) exeext= ;; - esac - case $host in - *cygwin* | *mingw* ) - func_dirname_and_basename "$output" "" "." - output_name=$func_basename_result - output_path=$func_dirname_result - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $RM $cwrappersource $cwrapper - trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - - func_emit_cwrapperexe_src > $cwrappersource - - # The wrapper executable is built using the $host compiler, - # because it contains $host paths and files. If cross- - # compiling, it, like the target executable, must be - # executed on the $host or under an emulation environment. - $opt_dry_run || { - $LTCC $LTCFLAGS -o $cwrapper $cwrappersource - $STRIP $cwrapper - } - - # Now, create the wrapper script for func_source use: - func_ltwrapper_scriptname $cwrapper - $RM $func_ltwrapper_scriptname_result - trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 - $opt_dry_run || { - # note: this script will not be executed, so do not chmod. - if test "x$build" = "x$host" ; then - $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result - else - func_emit_wrapper no > $func_ltwrapper_scriptname_result - fi - } - ;; - * ) - $RM $output - trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 - - func_emit_wrapper no > $output - chmod +x $output - ;; - esac - } - exit $EXIT_SUCCESS - ;; - esac - - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do - - if test "$build_libtool_libs" = convenience; then - oldobjs="$libobjs_save $symfileobj" - addlibs="$convenience" - build_libtool_libs=no - else - if test "$build_libtool_libs" = module; then - oldobjs="$libobjs_save" - build_libtool_libs=no - else - oldobjs="$old_deplibs $non_pic_objects" - if test "$preload" = yes && test -f "$symfileobj"; then - func_append oldobjs " $symfileobj" - fi - fi - addlibs="$old_convenience" - fi - - if test -n "$addlibs"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $addlibs - func_append oldobjs " $func_extract_archives_result" - fi - - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then - cmds=$old_archive_from_new_cmds - else - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append oldobjs " $func_extract_archives_result" - fi - - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - func_basename "$obj" - $ECHO "$func_basename_result" - done | sort | sort -uc >/dev/null 2>&1); then - : - else - echo "copying selected object files to avoid basename conflicts..." - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - func_mkdir_p "$gentop" - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - func_basename "$obj" - objbase="$func_basename_result" - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - func_arith $counter + 1 - counter=$func_arith_result - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - func_append oldobjs " $gentop/$newobj" - ;; - *) func_append oldobjs " $obj" ;; - esac - done - fi - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - eval cmds=\"$old_archive_cmds\" - - func_len " $cmds" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds - elif test -n "$archiver_list_spec"; then - func_verbose "using command file archive linking..." - for obj in $oldobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > $output_objdir/$libname.libcmd - func_to_tool_file "$output_objdir/$libname.libcmd" - oldobjs=" $archiver_list_spec$func_to_tool_file_result" - cmds=$old_archive_cmds - else - # the command line is too long to link in one step, link in parts - func_verbose "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - oldobjs= - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - eval test_cmds=\"$old_archive_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - for obj in $save_oldobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - func_append objlist " $obj" - if test "$len" -lt "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj" ; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" - objlist= - len=$len0 - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test "X$oldobjs" = "X" ; then - eval cmds=\"\$concat_cmds\" - else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" - fi - fi - fi - func_execute_cmds "$cmds" 'exit $?' - done - - test -n "$generated" && \ - func_show_eval "${RM}r$generated" - - # Now create the libtool archive. - case $output in - *.la) - old_library= - test "$build_old_libs" = yes && old_library="$libname.$libext" - func_verbose "creating $output" - - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - if test "$hardcode_automatic" = yes ; then - relink_command= - fi - - # Only create the output if not a dry run. - $opt_dry_run || { - for installed in no yes; do - if test "$installed" = yes; then - if test -z "$install_libdir"; then - break - fi - output="$output_objdir/$outputname"i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - func_basename "$deplib" - name="$func_basename_result" - func_resolve_sysroot "$deplib" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" - ;; - -L*) - func_stripname -L '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -L$func_replace_sysroot_result" - ;; - -R*) - func_stripname -R '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -R$func_replace_sysroot_result" - ;; - *) func_append newdependency_libs " $deplib" ;; - esac - done - dependency_libs="$newdependency_libs" - newdlfiles= - - for lib in $dlfiles; do - case $lib in - *.la) - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" - ;; - *) func_append newdlfiles " $lib" ;; - esac - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - *.la) - # Only pass preopened files to the pseudo-archive (for - # eventual linking with the app. that links it) if we - # didn't already link the preopened objects directly into - # the library: - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" - ;; - esac - done - dlprefiles="$newdlprefiles" - else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlfiles " $abs" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlprefiles " $abs" - done - dlprefiles="$newdlprefiles" - fi - $RM $output - # place dlname in correct position for cygwin - # In fact, it would be nice if we could use this code for all target - # systems that can't hard-code library paths into their executables - # and that have no shared library path variable independent of PATH, - # but it turns out we can't easily determine that from inspecting - # libtool variables, so we have to hard-code the OSs to which it - # applies here; at the moment, that means platforms that use the PE - # object format with DLL files. See the long comment at the top of - # tests/bindir.at for full details. - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) - # If a -bindir argument was supplied, place the dll there. - if test "x$bindir" != x ; - then - func_relative_path "$install_libdir" "$bindir" - tdlname=$func_relative_path_result$dlname - else - # Otherwise fall back on heuristic. - tdlname=../bin/$dlname - fi - ;; - esac - $ECHO > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# Please DO NOT delete this file! -# It is necessary for linking the library. - -# The name that we can dlopen(3). -dlname='$tdlname' - -# Names of this library. -library_names='$library_names' - -# The name of the static archive. -old_library='$old_library' - -# Linker flags that can not go in dependency_libs. -inherited_linker_flags='$new_inherited_linker_flags' - -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' - -# Names of additional weak libraries provided by this library -weak_library_names='$weak_libs' - -# Version information for $libname. -current=$current -age=$age -revision=$revision - -# Is this an already installed library? -installed=$installed - -# Should we warn about portability when linking against -modules? -shouldnotlink=$module - -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' - -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test "$installed" = no && test "$need_relink" = yes; then - $ECHO >> $output "\ -relink_command=\"$relink_command\"" - fi - done - } - - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' - ;; - esac - exit $EXIT_SUCCESS -} - -{ test "$opt_mode" = link || test "$opt_mode" = relink; } && - func_mode_link ${1+"$@"} - - -# func_mode_uninstall arg... -func_mode_uninstall () -{ - $opt_debug - RM="$nonopt" - files= - rmforce= - exit_status=0 - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - for arg - do - case $arg in - -f) func_append RM " $arg"; rmforce=yes ;; - -*) func_append RM " $arg" ;; - *) func_append files " $arg" ;; - esac - done - - test -z "$RM" && \ - func_fatal_help "you must specify an RM program" - - rmdirs= - - for file in $files; do - func_dirname "$file" "" "." - dir="$func_dirname_result" - if test "X$dir" = X.; then - odir="$objdir" - else - odir="$dir/$objdir" - fi - func_basename "$file" - name="$func_basename_result" - test "$opt_mode" = uninstall && odir="$dir" - - # Remember odir for removal later, being careful to avoid duplicates - if test "$opt_mode" = clean; then - case " $rmdirs " in - *" $odir "*) ;; - *) func_append rmdirs " $odir" ;; - esac - fi - - # Don't error if the file doesn't exist and rm -f was used. - if { test -L "$file"; } >/dev/null 2>&1 || - { test -h "$file"; } >/dev/null 2>&1 || - test -f "$file"; then - : - elif test -d "$file"; then - exit_status=1 - continue - elif test "$rmforce" = yes; then - continue - fi - - rmfiles="$file" - - case $name in - *.la) - # Possibly a libtool archive, so verify it. - if func_lalib_p "$file"; then - func_source $dir/$name - - # Delete the libtool libraries and symlinks. - for n in $library_names; do - func_append rmfiles " $odir/$n" - done - test -n "$old_library" && func_append rmfiles " $odir/$old_library" - - case "$opt_mode" in - clean) - case " $library_names " in - *" $dlname "*) ;; - *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; - esac - test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" - ;; - uninstall) - if test -n "$library_names"; then - # Do each command in the postuninstall commands. - func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - - if test -n "$old_library"; then - # Do each command in the old_postuninstall commands. - func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - # FIXME: should reinstall the best remaining shared library. - ;; - esac - fi - ;; - - *.lo) - # Possibly a libtool object, so verify it. - if func_lalib_p "$file"; then - - # Read the .lo file - func_source $dir/$name - - # Add PIC object to the list of files to remove. - if test -n "$pic_object" && - test "$pic_object" != none; then - func_append rmfiles " $dir/$pic_object" - fi - - # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" && - test "$non_pic_object" != none; then - func_append rmfiles " $dir/$non_pic_object" - fi - fi - ;; - - *) - if test "$opt_mode" = clean ; then - noexename=$name - case $file in - *.exe) - func_stripname '' '.exe' "$file" - file=$func_stripname_result - func_stripname '' '.exe' "$name" - noexename=$func_stripname_result - # $file with .exe has already been added to rmfiles, - # add $file without .exe - func_append rmfiles " $file" - ;; - esac - # Do a test to see if this is a libtool program. - if func_ltwrapper_p "$file"; then - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - relink_command= - func_source $func_ltwrapper_scriptname_result - func_append rmfiles " $func_ltwrapper_scriptname_result" - else - relink_command= - func_source $dir/$noexename - fi - - # note $name still contains .exe if it was in $file originally - # as does the version of $file that was added into $rmfiles - func_append rmfiles " $odir/$name $odir/${name}S.${objext}" - if test "$fast_install" = yes && test -n "$relink_command"; then - func_append rmfiles " $odir/lt-$name" - fi - if test "X$noexename" != "X$name" ; then - func_append rmfiles " $odir/lt-${noexename}.c" - fi - fi - fi - ;; - esac - func_show_eval "$RM $rmfiles" 'exit_status=1' - done - - # Try to remove the ${objdir}s in the directories where we deleted files - for dir in $rmdirs; do - if test -d "$dir"; then - func_show_eval "rmdir $dir >/dev/null 2>&1" - fi - done - - exit $exit_status -} - -{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && - func_mode_uninstall ${1+"$@"} - -test -z "$opt_mode" && { - help="$generic_help" - func_fatal_help "you must specify a MODE" -} - -test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode \`$opt_mode'" - -if test -n "$exec_cmd"; then - eval exec "$exec_cmd" - exit $EXIT_FAILURE -fi - -exit $exit_status - - -# The TAGs below are defined such that we never get into a situation -# in which we disable both kinds of libraries. Given conflicting -# choices, we go for a static library, that is the most portable, -# since we can't tell whether shared libraries were disabled because -# the user asked for that or because the platform doesn't support -# them. This is particularly important on AIX, because we don't -# support having both static and shared libraries enabled at the same -# time on that platform, so we default to a shared-only configuration. -# If a disable-shared tag is given, we'll fallback to a static-only -# configuration. But we'll never go from static-only to shared-only. - -# ### BEGIN LIBTOOL TAG CONFIG: disable-shared -build_libtool_libs=no -build_old_libs=yes -# ### END LIBTOOL TAG CONFIG: disable-shared - -# ### BEGIN LIBTOOL TAG CONFIG: disable-static -build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` -# ### END LIBTOOL TAG CONFIG: disable-static - -# Local Variables: -# mode:shell-script -# sh-indentation:2 -# End: -# vi:sw=2 - diff --git a/lib-src/expat/conftools/mkinstalldirs b/lib-src/expat/conftools/mkinstalldirs deleted file mode 100755 index c5291db03..000000000 --- a/lib-src/expat/conftools/mkinstalldirs +++ /dev/null @@ -1,40 +0,0 @@ -#! /bin/sh -# mkinstalldirs --- make directory hierarchy -# Author: Noah Friedman -# Created: 1993-05-16 -# Public domain - -# $Id: mkinstalldirs,v 1.1 2000/09/18 16:26:21 coopercc Exp $ - -errstatus=0 - -for file -do - set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` - shift - - pathcomp= - for d - do - pathcomp="$pathcomp$d" - case "$pathcomp" in - -* ) pathcomp=./$pathcomp ;; - esac - - if test ! -d "$pathcomp"; then - echo "mkdir $pathcomp" - - mkdir "$pathcomp" || lasterr=$? - - if test ! -d "$pathcomp"; then - errstatus=$lasterr - fi - fi - - pathcomp="$pathcomp/" - done -done - -exit $errstatus - -# mkinstalldirs ends here diff --git a/lib-src/expat/doc/expat.png b/lib-src/expat/doc/expat.png deleted file mode 100644 index 5bc0726cfd8508d0aa53cf53486b0330780b5f21..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1027 zcmV+e1pNDnP)=T+4e4Js00002VoOIv z0RM-N%)bBt1B6LLK~!ko?U>t@>mUq8)d+=9h#H{~3Q;2}M1^oacv#|LJI>6kWL^9- zPA0}%;&3E@^wk$^{EffyH~z-o_#1!YZ~TqF@i+dTUID;=F}?$c-;2)xAis?t0001j zNt%-%z{k7Vc?VxI{*k8u0Q6v>*t5c2?Yt$PXw%PjDsGSBpo5^>+Idg=&ZOT1xQ8it zs-5@nP5R^goLSTX|Gswa;GZ!0BmMHiOV9CN(9ShJdpvizl70_>=|}LJc3hA*@uO2z zLWqbY!`nd;DbHjK5iuo30Ps=$p3nn;LpsB6(+B{8pW{n(01aP?QUJX4<{6R$U_JW) zX;SU{%D(ckm??#nEW+ z3XW&yX|=z!mNR^r^i4H@$tv#fdGSjnZ?aNtwTnA^*7%yJESEWc9BQ!gKqH75e#shWuW7Wm8RR|3FG{7K8MEuu4uR_# zIO{m=qZz|-nH=gjrMh+%n?(}|gI&XArp#V9+VyqWuwC@~LFu(Nx`=H{PAXZfYFBIY zQ3qA-5y2@Xwk09?Ct)b{@%e5`!m-=JzG#W*bQEdEk6k^Jw%aL2m93!;i=%cfH!C;x zy3t|V1A - - - - - Expat XML Parser - - - - - - - - - - - - - - -
(Expat logo)
Release 2.0.1
-
- -

Expat is a library, written in C, for parsing XML documents. It's -the underlying XML parser for the open source Mozilla project, Perl's -XML::Parser, Python's xml.parsers.expat, and -other open-source XML parsers.

- -

This library is the creation of James Clark, who's also given us -groff (an nroff look-alike), Jade (an implemention of ISO's DSSSL -stylesheet language for SGML), XP (a Java XML parser package), XT (a -Java XSL engine). James was also the technical lead on the XML -Working Group at W3C that produced the XML specification.

- -

This is free software, licensed under the MIT/X Consortium license. You may download it -from the Expat home page. -

- -

The bulk of this document was originally commissioned as an article -by XML.com. They graciously allowed -Clark Cooper to retain copyright and to distribute it with Expat. -This version has been substantially extended to include documentation -on features which have been added since the original article was -published, and additional information on using the original -interface.

- -
-

Table of Contents

- - -
-

Overview

- -

Expat is a stream-oriented parser. You register callback (or -handler) functions with the parser and then start feeding it the -document. As the parser recognizes parts of the document, it will -call the appropriate handler for that part (if you've registered one.) -The document is fed to the parser in pieces, so you can start parsing -before you have all the document. This also allows you to parse really -huge documents that won't fit into memory.

- -

Expat can be intimidating due to the many kinds of handlers and -options you can set. But you only need to learn four functions in -order to do 90% of what you'll want to do with it:

- -
- -
XML_ParserCreate
-
Create a new parser object.
- -
XML_SetElementHandler
-
Set handlers for start and end tags.
- -
XML_SetCharacterDataHandler
-
Set handler for text.
- -
XML_Parse
-
Pass a buffer full of document to the parser
-
- -

These functions and others are described in the reference part of this document. The reference -section also describes in detail the parameters passed to the -different types of handlers.

- -

Let's look at a very simple example program that only uses 3 of the -above functions (it doesn't need to set a character handler.) The -program outline.c prints an -element outline, indenting child elements to distinguish them from the -parent element that contains them. The start handler does all the -work. It prints two indenting spaces for every level of ancestor -elements, then it prints the element and attribute -information. Finally it increments the global Depth -variable.

- -
-int Depth;
-
-void XMLCALL
-start(void *data, const char *el, const char **attr) {
-  int i;
-
-  for (i = 0; i < Depth; i++)
-    printf("  ");
-
-  printf("%s", el);
-
-  for (i = 0; attr[i]; i += 2) {
-    printf(" %s='%s'", attr[i], attr[i + 1]);
-  }
-
-  printf("\n");
-  Depth++;
-}  /* End of start handler */
-
- -

The end tag simply does the bookkeeping work of decrementing -Depth.

-
-void XMLCALL
-end(void *data, const char *el) {
-  Depth--;
-}  /* End of end handler */
-
- -

Note the XMLCALL annotation used for the callbacks. -This is used to ensure that the Expat and the callbacks are using the -same calling convention in case the compiler options used for Expat -itself and the client code are different. Expat tries not to care -what the default calling convention is, though it may require that it -be compiled with a default convention of "cdecl" on some platforms. -For code which uses Expat, however, the calling convention is -specified by the XMLCALL annotation on most platforms; -callbacks should be defined using this annotation.

- -

The XMLCALL annotation was added in Expat 1.95.7, but -existing working Expat applications don't need to add it (since they -are already using the "cdecl" calling convention, or they wouldn't be -working). The annotation is only needed if the default calling -convention may be something other than "cdecl". To use the annotation -safely with older versions of Expat, you can conditionally define it -after including Expat's header file:

- -
-#include <expat.h>
-
-#ifndef XMLCALL
-#if defined(_MSC_EXTENSIONS) && !defined(__BEOS__) && !defined(__CYGWIN__)
-#define XMLCALL __cdecl
-#elif defined(__GNUC__)
-#define XMLCALL __attribute__((cdecl))
-#else
-#define XMLCALL
-#endif
-#endif
-
- -

After creating the parser, the main program just has the job of -shoveling the document to the parser so that it can do its work.

- -
-

Building and Installing Expat

- -

The Expat distribution comes as a compressed (with GNU gzip) tar -file. You may download the latest version from Source Forge. After -unpacking this, cd into the directory. Then follow either the Win32 -directions or Unix directions below.

- -

Building under Win32

- -

If you're using the GNU compiler under cygwin, follow the Unix -directions in the next section. Otherwise if you have Microsoft's -Developer Studio installed, then from Windows Explorer double-click on -"expat.dsp" in the lib directory and build and install in the usual -manner.

- -

Alternatively, you may download the Win32 binary package that -contains the "expat.h" include file and a pre-built DLL.

- -

Building under Unix (or GNU)

- -

First you'll need to run the configure shell script in order to -configure the Makefiles and headers for your system.

- -

If you're happy with all the defaults that configure picks for you, -and you have permission on your system to install into /usr/local, you -can install Expat with this sequence of commands:

- -
-./configure
-make
-make install
-
- -

There are some options that you can provide to this script, but the -only one we'll mention here is the --prefix option. You -can find out all the options available by running configure with just -the --help option.

- -

By default, the configure script sets things up so that the library -gets installed in /usr/local/lib and the associated -header file in /usr/local/include. But if you were to -give the option, --prefix=/home/me/mystuff, then the -library and header would get installed in -/home/me/mystuff/lib and -/home/me/mystuff/include respectively.

- -

Configuring Expat Using the Pre-Processor

- -

Expat's feature set can be configured using a small number of -pre-processor definitions. The definition of this symbols does not -affect the set of entry points for Expat, only the behavior of the API -and the definition of character types in the case of -XML_UNICODE_WCHAR_T. The symbols are:

- -
-
XML_DTD
-
Include support for using and reporting DTD-based content. If -this is defined, default attribute values from an external DTD subset -are reported and attribute value normalization occurs based on the -type of attributes defined in the external subset. Without -this, Expat has a smaller memory footprint and can be faster, but will -not load external entities or process conditional sections. This does -not affect the set of functions available in the API.
- -
XML_NS
-
When defined, support for the Namespaces in XML -specification is included.
- -
XML_UNICODE
-
When defined, character data reported to the application is -encoded in UTF-16 using wide characters of the type -XML_Char. This is implied if -XML_UNICODE_WCHAR_T is defined.
- -
XML_UNICODE_WCHAR_T
-
If defined, causes the XML_Char character type to be -defined using the wchar_t type; otherwise, unsigned -short is used. Defining this implies -XML_UNICODE.
- -
XML_LARGE_SIZE
-
If defined, causes the XML_Size and XML_Index -integer types to be at least 64 bits in size. This is intended to support -processing of very large input streams, where the return values of -XML_GetCurrentByteIndex, -XML_GetCurrentLineNumber and -XML_GetCurrentColumnNumber -could overflow. It may not be supported by all compilers, and is turned -off by default.
- -
XML_CONTEXT_BYTES
-
The number of input bytes of markup context which the parser will -ensure are available for reporting via XML_GetInputContext. This is -normally set to 1024, and must be set to a positive interger. If this -is not defined, the input context will not be available and XML_GetInputContext will -always report NULL. Without this, Expat has a smaller memory -footprint and can be faster.
- -
XML_STATIC
-
On Windows, this should be set if Expat is going to be linked -statically with the code that calls it; this is required to get all -the right MSVC magic annotations correct. This is ignored on other -platforms.
- -
XML_ATTR_INFO
-
If defined, makes the the additional function XML_GetAttributeInfo available -for reporting attribute byte offsets.
-
- -
-

Using Expat

- -

Compiling and Linking Against Expat

- -

Unless you installed Expat in a location not expected by your -compiler and linker, all you have to do to use Expat in your programs -is to include the Expat header (#include <expat.h>) -in your files that make calls to it and to tell the linker that it -needs to link against the Expat library. On Unix systems, this would -usually be done with the -lexpat argument. Otherwise, -you'll need to tell the compiler where to look for the Expat header -and the linker where to find the Expat library. You may also need to -take steps to tell the operating system where to find this library at -run time.

- -

On a Unix-based system, here's what a Makefile might look like when -Expat is installed in a standard location:

- -
-CC=cc
-LDFLAGS=
-LIBS= -lexpat
-xmlapp: xmlapp.o
-        $(CC) $(LDFLAGS) -o xmlapp xmlapp.o $(LIBS)
-
- -

If you installed Expat in, say, /home/me/mystuff, then -the Makefile would look like this:

- -
-CC=cc
-CFLAGS= -I/home/me/mystuff/include
-LDFLAGS=
-LIBS= -L/home/me/mystuff/lib -lexpat
-xmlapp: xmlapp.o
-        $(CC) $(LDFLAGS) -o xmlapp xmlapp.o $(LIBS)
-
- -

You'd also have to set the environment variable -LD_LIBRARY_PATH to /home/me/mystuff/lib (or -to ${LD_LIBRARY_PATH}:/home/me/mystuff/lib if -LD_LIBRARY_PATH already has some directories in it) in order to run -your application.

- -

Expat Basics

- -

As we saw in the example in the overview, the first step in parsing -an XML document with Expat is to create a parser object. There are three functions in the Expat API for creating a -parser object. However, only two of these (XML_ParserCreate and XML_ParserCreateNS) can be used for -constructing a parser for a top-level document. The object returned -by these functions is an opaque pointer (i.e. "expat.h" declares it as -void *) to data with further internal structure. In order to free the -memory associated with this object you must call XML_ParserFree. Note that if you have -provided any user data that gets stored in the -parser, then your application is responsible for freeing it prior to -calling XML_ParserFree.

- -

The objects returned by the parser creation functions are good for -parsing only one XML document or external parsed entity. If your -application needs to parse many XML documents, then it needs to create -a parser object for each one. The best way to deal with this is to -create a higher level object that contains all the default -initialization you want for your parser objects.

- -

Walking through a document hierarchy with a stream oriented parser -will require a good stack mechanism in order to keep track of current -context. For instance, to answer the simple question, "What element -does this text belong to?" requires a stack, since the parser may have -descended into other elements that are children of the current one and -has encountered this text on the way out.

- -

The things you're likely to want to keep on a stack are the -currently opened element and it's attributes. You push this -information onto the stack in the start handler and you pop it off in -the end handler.

- -

For some tasks, it is sufficient to just keep information on what -the depth of the stack is (or would be if you had one.) The outline -program shown above presents one example. Another such task would be -skipping over a complete element. When you see the start tag for the -element you want to skip, you set a skip flag and record the depth at -which the element started. When the end tag handler encounters the -same depth, the skipped element has ended and the flag may be -cleared. If you follow the convention that the root element starts at -1, then you can use the same variable for skip flag and skip -depth.

- -
-void
-init_info(Parseinfo *info) {
-  info->skip = 0;
-  info->depth = 1;
-  /* Other initializations here */
-}  /* End of init_info */
-
-void XMLCALL
-rawstart(void *data, const char *el, const char **attr) {
-  Parseinfo *inf = (Parseinfo *) data;
-
-  if (! inf->skip) {
-    if (should_skip(inf, el, attr)) {
-      inf->skip = inf->depth;
-    }
-    else
-      start(inf, el, attr);     /* This does rest of start handling */
-  }
-
-  inf->depth++;
-}  /* End of rawstart */
-
-void XMLCALL
-rawend(void *data, const char *el) {
-  Parseinfo *inf = (Parseinfo *) data;
-
-  inf->depth--;
-
-  if (! inf->skip)
-    end(inf, el);              /* This does rest of end handling */
-
-  if (inf->skip == inf->depth)
-    inf->skip = 0;
-}  /* End rawend */
-
- -

Notice in the above example the difference in how depth is -manipulated in the start and end handlers. The end tag handler should -be the mirror image of the start tag handler. This is necessary to -properly model containment. Since, in the start tag handler, we -incremented depth after the main body of start tag code, then -in the end handler, we need to manipulate it before the main -body. If we'd decided to increment it first thing in the start -handler, then we'd have had to decrement it last thing in the end -handler.

- -

Communicating between handlers

- -

In order to be able to pass information between different handlers -without using globals, you'll need to define a data structure to hold -the shared variables. You can then tell Expat (with the XML_SetUserData function) to pass a -pointer to this structure to the handlers. This is the first -argument received by most handlers. In the reference section, an argument to a callback function is named -userData and have type void * if the user -data is passed; it will have the type XML_Parser if the -parser itself is passed. When the parser is passed, the user data may -be retrieved using XML_GetUserData.

- -

One common case where multiple calls to a single handler may need -to communicate using an application data structure is the case when -content passed to the character data handler (set by XML_SetCharacterDataHandler) needs to be accumulated. A -common first-time mistake with any of the event-oriented interfaces to -an XML parser is to expect all the text contained in an element to be -reported by a single call to the character data handler. Expat, like -many other XML parsers, reports such data as a sequence of calls; -there's no way to know when the end of the sequence is reached until a -different callback is made. A buffer referenced by the user data -structure proves both an effective and convenient place to accumulate -character data.

- - - - -

XML Version

- -

Expat is an XML 1.0 parser, and as such never complains based on -the value of the version pseudo-attribute in the XML -declaration, if present.

- -

If an application needs to check the version number (to support -alternate processing), it should use the XML_SetXmlDeclHandler function to -set a handler that uses the information in the XML declaration to -determine what to do. This example shows how to check that only a -version number of "1.0" is accepted:

- -
-static int wrong_version;
-static XML_Parser parser;
-
-static void XMLCALL
-xmldecl_handler(void            *userData,
-                const XML_Char  *version,
-                const XML_Char  *encoding,
-                int              standalone)
-{
-  static const XML_Char Version_1_0[] = {'1', '.', '0', 0};
-
-  int i;
-
-  for (i = 0; i < (sizeof(Version_1_0) / sizeof(Version_1_0[0])); ++i) {
-    if (version[i] != Version_1_0[i]) {
-      wrong_version = 1;
-      /* also clear all other handlers: */
-      XML_SetCharacterDataHandler(parser, NULL);
-      ...
-      return;
-    }
-  }
-  ...
-}
-
- -

Namespace Processing

- -

When the parser is created using the XML_ParserCreateNS, function, Expat -performs namespace processing. Under namespace processing, Expat -consumes xmlns and xmlns:... attributes, -which declare namespaces for the scope of the element in which they -occur. This means that your start handler will not see these -attributes. Your application can still be informed of these -declarations by setting namespace declaration handlers with XML_SetNamespaceDeclHandler.

- -

Element type and attribute names that belong to a given namespace -are passed to the appropriate handler in expanded form. By default -this expanded form is a concatenation of the namespace URI, the -separator character (which is the 2nd argument to XML_ParserCreateNS), and the local -name (i.e. the part after the colon). Names with undeclared prefixes -are not well-formed when namespace processing is enabled, and will -trigger an error. Unprefixed attribute names are never expanded, -and unprefixed element names are only expanded when they are in the -scope of a default namespace.

- -

However if XML_SetReturnNSTriplet has been called with a non-zero -do_nst parameter, then the expanded form for names with -an explicit prefix is a concatenation of: URI, separator, local name, -separator, prefix.

- -

You can set handlers for the start of a namespace declaration and -for the end of a scope of a declaration with the XML_SetNamespaceDeclHandler -function. The StartNamespaceDeclHandler is called prior to the start -tag handler and the EndNamespaceDeclHandler is called after the -corresponding end tag that ends the namespace's scope. The namespace -start handler gets passed the prefix and URI for the namespace. For a -default namespace declaration (xmlns='...'), the prefix will be null. -The URI will be null for the case where the default namespace is being -unset. The namespace end handler just gets the prefix for the closing -scope.

- -

These handlers are called for each declaration. So if, for -instance, a start tag had three namespace declarations, then the -StartNamespaceDeclHandler would be called three times before the start -tag handler is called, once for each declaration.

- -

Character Encodings

- -

While XML is based on Unicode, and every XML processor is required -to recognized UTF-8 and UTF-16 (1 and 2 byte encodings of Unicode), -other encodings may be declared in XML documents or entities. For the -main document, an XML declaration may contain an encoding -declaration:

-
-<?xml version="1.0" encoding="ISO-8859-2"?>
-
- -

External parsed entities may begin with a text declaration, which -looks like an XML declaration with just an encoding declaration:

-
-<?xml encoding="Big5"?>
-
- -

With Expat, you may also specify an encoding at the time of -creating a parser. This is useful when the encoding information may -come from a source outside the document itself (like a higher level -protocol.)

- -

There are four built-in encodings -in Expat:

-
    -
  • UTF-8
  • -
  • UTF-16
  • -
  • ISO-8859-1
  • -
  • US-ASCII
  • -
- -

Anything else discovered in an encoding declaration or in the -protocol encoding specified in the parser constructor, triggers a call -to the UnknownEncodingHandler. This handler gets passed -the encoding name and a pointer to an XML_Encoding data -structure. Your handler must fill in this structure and return -XML_STATUS_OK if it knows how to deal with the -encoding. Otherwise the handler should return -XML_STATUS_ERROR. The handler also gets passed a pointer -to an optional application data structure that you may indicate when -you set the handler.

- -

Expat places restrictions on character encodings that it can -support by filling in the XML_Encoding structure. -include file:

-
    -
  1. Every ASCII character that can appear in a well-formed XML document -must be represented by a single byte, and that byte must correspond to -it's ASCII encoding (except for the characters $@\^'{}~)
  2. -
  3. Characters must be encoded in 4 bytes or less.
  4. -
  5. All characters encoded must have Unicode scalar values less than or -equal to 65535 (0xFFFF)This does not apply to the built-in support -for UTF-16 and UTF-8
  6. -
  7. No character may be encoded by more that one distinct sequence of -bytes
  8. -
- -

XML_Encoding contains an array of integers that -correspond to the 1st byte of an encoding sequence. If the value in -the array for a byte is zero or positive, then the byte is a single -byte encoding that encodes the Unicode scalar value contained in the -array. A -1 in this array indicates a malformed byte. If the value is --2, -3, or -4, then the byte is the beginning of a 2, 3, or 4 byte -sequence respectively. Multi-byte sequences are sent to the convert -function pointed at in the XML_Encoding structure. This -function should return the Unicode scalar value for the sequence or -1 -if the sequence is malformed.

- -

One pitfall that novice Expat users are likely to fall into is that -although Expat may accept input in various encodings, the strings that -it passes to the handlers are always encoded in UTF-8 or UTF-16 -(depending on how Expat was compiled). Your application is responsible -for any translation of these strings into other encodings.

- -

Handling External Entity References

- -

Expat does not read or parse external entities directly. Note that -any external DTD is a special case of an external entity. If you've -set no ExternalEntityRefHandler, then external entity -references are silently ignored. Otherwise, it calls your handler with -the information needed to read and parse the external entity.

- -

Your handler isn't actually responsible for parsing the entity, but -it is responsible for creating a subsidiary parser with XML_ExternalEntityParserCreate that will do the job. This -returns an instance of XML_Parser that has handlers and -other data structures initialized from the parent parser. You may then -use XML_Parse or XML_ParseBuffer calls against this -parser. Since external entities my refer to other external entities, -your handler should be prepared to be called recursively.

- -

Parsing DTDs

- -

In order to parse parameter entities, before starting the parse, -you must call XML_SetParamEntityParsing with one of the following -arguments:

-
-
XML_PARAM_ENTITY_PARSING_NEVER
-
Don't parse parameter entities or the external subset
-
XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE
-
Parse parameter entites and the external subset unless -standalone was set to "yes" in the XML declaration.
-
XML_PARAM_ENTITY_PARSING_ALWAYS
-
Always parse parameter entities and the external subset
-
- -

In order to read an external DTD, you also have to set an external -entity reference handler as described above.

- -

Temporarily Stopping Parsing

- -

Expat 1.95.8 introduces a new feature: its now possible to stop -parsing temporarily from within a handler function, even if more data -has already been passed into the parser. Applications for this -include

- -
    -
  • Supporting the XInclude specification.
  • - -
  • Delaying further processing until additional information is - available from some other source.
  • - -
  • Adjusting processor load as task priorities shift within an - application.
  • - -
  • Stopping parsing completely (simply free or reset the parser - instead of resuming in the outer parsing loop). This can be useful - if a application-domain error is found in the XML being parsed or if - the result of the parse is determined not to be useful after - all.
  • -
- -

To take advantage of this feature, the main parsing loop of an -application needs to support this specifically. It cannot be -supported with a parsing loop compatible with Expat 1.95.7 or -earlier (though existing loops will continue to work without -supporting the stop/resume feature).

- -

An application that uses this feature for a single parser will have -the rough structure (in pseudo-code):

- -
-fd = open_input()
-p = create_parser()
-
-if parse_xml(p, fd) {
-  /* suspended */
-
-  int suspended = 1;
-
-  while (suspended) {
-    do_something_else()
-    if ready_to_resume() {
-      suspended = continue_parsing(p, fd);
-    }
-  }
-}
-
- -

An application that may resume any of several parsers based on -input (either from the XML being parsed or some other source) will -certainly have more interesting control structures.

- -

This C function could be used for the parse_xml -function mentioned in the pseudo-code above:

- -
-#define BUFF_SIZE 10240
-
-/* Parse a document from the open file descriptor 'fd' until the parse
-   is complete (the document has been completely parsed, or there's
-   been an error), or the parse is stopped.  Return non-zero when
-   the parse is merely suspended.
-*/
-int
-parse_xml(XML_Parser p, int fd)
-{
-  for (;;) {
-    int last_chunk;
-    int bytes_read;
-    enum XML_Status status;
-
-    void *buff = XML_GetBuffer(p, BUFF_SIZE);
-    if (buff == NULL) {
-      /* handle error... */
-      return 0;
-    }
-    bytes_read = read(fd, buff, BUFF_SIZE);
-    if (bytes_read < 0) {
-      /* handle error... */
-      return 0;
-    }
-    status = XML_ParseBuffer(p, bytes_read, bytes_read == 0);
-    switch (status) {
-      case XML_STATUS_ERROR:
-        /* handle error... */
-        return 0;
-      case XML_STATUS_SUSPENDED:
-        return 1;
-    }
-    if (bytes_read == 0)
-      return 0;
-  }
-}
-
- -

The corresponding continue_parsing function is -somewhat simpler, since it only need deal with the return code from -XML_ResumeParser; it can -delegate the input handling to the parse_xml -function:

- -
-/* Continue parsing a document which had been suspended.  The 'p' and
-   'fd' arguments are the same as passed to parse_xml().  Return
-   non-zero when the parse is suspended.
-*/
-int
-continue_parsing(XML_Parser p, int fd)
-{
-  enum XML_Status status = XML_ResumeParser(p);
-  switch (status) {
-    case XML_STATUS_ERROR:
-      /* handle error... */
-      return 0;
-    case XML_ERROR_NOT_SUSPENDED:
-      /* handle error... */
-      return 0;.
-    case XML_STATUS_SUSPENDED:
-      return 1;
-  }
-  return parse_xml(p, fd);
-}
-
- -

Now that we've seen what a mess the top-level parsing loop can -become, what have we gained? Very simply, we can now use the XML_StopParser function to stop -parsing, without having to go to great lengths to avoid additional -processing that we're expecting to ignore. As a bonus, we get to stop -parsing temporarily, and come back to it when we're -ready.

- -

To stop parsing from a handler function, use the XML_StopParser function. This function -takes two arguments; the parser being stopped and a flag indicating -whether the parse can be resumed in the future.

- - - - -
- - -

Expat Reference

- -

Parser Creation

- -
-XML_Parser XMLCALL
-XML_ParserCreate(const XML_Char *encoding);
-
-
-Construct a new parser. If encoding is non-null, it specifies a -character encoding to use for the document. This overrides the document -encoding declaration. There are four built-in encodings: -
    -
  • US-ASCII
  • -
  • UTF-8
  • -
  • UTF-16
  • -
  • ISO-8859-1
  • -
-Any other value will invoke a call to the UnknownEncodingHandler. -
- -
-XML_Parser XMLCALL
-XML_ParserCreateNS(const XML_Char *encoding,
-                   XML_Char sep);
-
-
-Constructs a new parser that has namespace processing in effect. Namespace -expanded element names and attribute names are returned as a concatenation -of the namespace URI, sep, and the local part of the name. This -means that you should pick a character for sep that can't be part -of an URI. Since Expat does not check namespace URIs for conformance, the -only safe choice for a namespace separator is a character that is illegal -in XML. For instance, '\xFF' is not legal in UTF-8, and -'\xFFFF' is not legal in UTF-16. There is a special case when -sep is the null character '\0': the namespace URI and -the local part will be concatenated without any separator - this is intended -to support RDF processors. It is a programming error to use the null separator -with namespace triplets.
- -
-XML_Parser XMLCALL
-XML_ParserCreate_MM(const XML_Char *encoding,
-                    const XML_Memory_Handling_Suite *ms,
-		    const XML_Char *sep);
-
-
-typedef struct {
-  void *(XMLCALL *malloc_fcn)(size_t size);
-  void *(XMLCALL *realloc_fcn)(void *ptr, size_t size);
-  void (XMLCALL *free_fcn)(void *ptr);
-} XML_Memory_Handling_Suite;
-
-
-

Construct a new parser using the suite of memory handling functions -specified in ms. If ms is NULL, then use the -standard set of memory management functions. If sep is -non NULL, then namespace processing is enabled in the created parser -and the character pointed at by sep is used as the separator between -the namespace URI and the local part of the name.

-
- -
-XML_Parser XMLCALL
-XML_ExternalEntityParserCreate(XML_Parser p,
-                               const XML_Char *context,
-                               const XML_Char *encoding);
-
-
-Construct a new XML_Parser object for parsing an external -general entity. Context is the context argument passed in a call to a -ExternalEntityRefHandler. Other state information such as handlers, -user data, namespace processing is inherited from the parser passed as -the 1st argument. So you shouldn't need to call any of the behavior -changing functions on this parser (unless you want it to act -differently than the parent parser). -
- -
-void XMLCALL
-XML_ParserFree(XML_Parser p);
-
-
-Free memory used by the parser. Your application is responsible for -freeing any memory associated with user data. -
- -
-XML_Bool XMLCALL
-XML_ParserReset(XML_Parser p,
-                const XML_Char *encoding);
-
-
-Clean up the memory structures maintained by the parser so that it may -be used again. After this has been called, parser is -ready to start parsing a new document. All handlers are cleared from -the parser, except for the unknownEncodingHandler. The parser's external -state is re-initialized except for the values of ns and ns_triplets. -This function may not be used on a parser created using XML_ExternalEntityParserCreate; it will return XML_FALSE in that case. Returns -XML_TRUE on success. Your application is responsible for -dealing with any memory associated with user data. -
- -

Parsing

- -

To state the obvious: the three parsing functions XML_Parse, -XML_ParseBuffer and -XML_GetBuffer must not be called from within a handler -unless they operate on a separate parser instance, that is, one that -did not call the handler. For example, it is OK to call the parsing -functions from within an XML_ExternalEntityRefHandler, -if they apply to the parser created by -XML_ExternalEntityParserCreate.

- -

Note: the len argument passed to these functions -should be considerably less than the maximum value for an integer, -as it could create an integer overflow situation if the added -lengths of a buffer and the unprocessed portion of the previous buffer -exceed the maximum integer value. Input data at the end of a buffer -will remain unprocessed if it is part of an XML token for which the -end is not part of that buffer.

- -
-enum XML_Status XMLCALL
-XML_Parse(XML_Parser p,
-          const char *s,
-          int len,
-          int isFinal);
-
-
-enum XML_Status {
-  XML_STATUS_ERROR = 0,
-  XML_STATUS_OK = 1
-};
-
-
-Parse some more of the document. The string s is a buffer -containing part (or perhaps all) of the document. The number of bytes of s -that are part of the document is indicated by len. This means -that s doesn't have to be null terminated. It also means that -if len is larger than the number of bytes in the block of -memory that s points at, then a memory fault is likely. The -isFinal parameter informs the parser that this is the last -piece of the document. Frequently, the last piece is empty (i.e. -len is zero.) -If a parse error occurred, it returns XML_STATUS_ERROR. -Otherwise it returns XML_STATUS_OK value. -
- -
-enum XML_Status XMLCALL
-XML_ParseBuffer(XML_Parser p,
-                int len,
-                int isFinal);
-
-
-This is just like XML_Parse, -except in this case Expat provides the buffer. By obtaining the -buffer from Expat with the XML_GetBuffer function, the application can avoid double -copying of the input. -
- -
-void * XMLCALL
-XML_GetBuffer(XML_Parser p,
-              int len);
-
-
-Obtain a buffer of size len to read a piece of the document -into. A NULL value is returned if Expat can't allocate enough memory for -this buffer. This has to be called prior to every call to -XML_ParseBuffer. A -typical use would look like this: - -
-for (;;) {
-  int bytes_read;
-  void *buff = XML_GetBuffer(p, BUFF_SIZE);
-  if (buff == NULL) {
-    /* handle error */
-  }
-
-  bytes_read = read(docfd, buff, BUFF_SIZE);
-  if (bytes_read < 0) {
-    /* handle error */
-  }
-
-  if (! XML_ParseBuffer(p, bytes_read, bytes_read == 0)) {
-    /* handle parse error */
-  }
-
-  if (bytes_read == 0)
-    break;
-}
-
-
- -
-enum XML_Status XMLCALL
-XML_StopParser(XML_Parser p,
-               XML_Bool resumable);
-
-
- -

Stops parsing, causing XML_Parse or XML_ParseBuffer to return. Must be called from within a -call-back handler, except when aborting (when resumable -is XML_FALSE) an already suspended parser. Some -call-backs may still follow because they would otherwise get -lost, including -

    -
  • the end element handler for empty elements when stopped in the - start element handler,
  • -
  • the end namespace declaration handler when stopped in the end - element handler,
  • -
  • the character data handler when stopped in the character data handler - while making multiple call-backs on a contiguous chunk of characters,
  • -
-and possibly others.

- -

This can be called from most handlers, including DTD related -call-backs, except when parsing an external parameter entity and -resumable is XML_TRUE. Returns -XML_STATUS_OK when successful, -XML_STATUS_ERROR otherwise. The possible error codes -are:

-
-
XML_ERROR_SUSPENDED
-
when suspending an already suspended parser.
-
XML_ERROR_FINISHED
-
when the parser has already finished.
-
XML_ERROR_SUSPEND_PE
-
when suspending while parsing an external PE.
-
- -

Since the stop/resume feature requires application support in the -outer parsing loop, it is an error to call this function for a parser -not being handled appropriately; see Temporarily Stopping Parsing for more information.

- -

When resumable is XML_TRUE then parsing -is suspended, that is, XML_Parse and XML_ParseBuffer return XML_STATUS_SUSPENDED. -Otherwise, parsing is aborted, that is, XML_Parse and XML_ParseBuffer return -XML_STATUS_ERROR with error code -XML_ERROR_ABORTED.

- -

Note: -This will be applied to the current parser instance only, that is, if -there is a parent parser then it will continue parsing when the -external entity reference handler returns. It is up to the -implementation of that handler to call XML_StopParser on the parent parser -(recursively), if one wants to stop parsing altogether.

- -

When suspended, parsing can be resumed by calling XML_ResumeParser.

- -

New in Expat 1.95.8.

-
- -
-enum XML_Status XMLCALL
-XML_ResumeParser(XML_Parser p);
-
-
-

Resumes parsing after it has been suspended with XML_StopParser. Must not be called from -within a handler call-back. Returns same status codes as XML_Parse or XML_ParseBuffer. An additional error -code, XML_ERROR_NOT_SUSPENDED, will be returned if the -parser was not currently suspended.

- -

Note: -This must be called on the most deeply nested child parser instance -first, and on its parent parser only after the child parser has -finished, to be applied recursively until the document entity's parser -is restarted. That is, the parent parser will not resume by itself -and it is up to the application to call XML_ResumeParser on it at the -appropriate moment.

- -

New in Expat 1.95.8.

-
- -
-void XMLCALL
-XML_GetParsingStatus(XML_Parser p,
-                     XML_ParsingStatus *status);
-
-
-enum XML_Parsing {
-  XML_INITIALIZED,
-  XML_PARSING,
-  XML_FINISHED,
-  XML_SUSPENDED
-};
-
-typedef struct {
-  enum XML_Parsing parsing;
-  XML_Bool finalBuffer;
-} XML_ParsingStatus;
-
-
-

Returns status of parser with respect to being initialized, -parsing, finished, or suspended, and whether the final buffer is being -processed. The status parameter must not be -NULL.

- -

New in Expat 1.95.8.

-
- - -

Handler Setting

- -

Although handlers are typically set prior to parsing and left alone, an -application may choose to set or change the handler for a parsing event -while the parse is in progress. For instance, your application may choose -to ignore all text not descended from a para element. One -way it could do this is to set the character handler when a para start tag -is seen, and unset it for the corresponding end tag.

- -

A handler may be unset by providing a NULL pointer to the -appropriate handler setter. None of the handler setting functions have -a return value.

- -

Your handlers will be receiving strings in arrays of type -XML_Char. This type is conditionally defined in expat.h as -either char, wchar_t or unsigned short. -The former implies UTF-8 encoding, the latter two imply UTF-16 encoding. -Note that you'll receive them in this form independent of the original -encoding of the document.

- -
-
-void XMLCALL
-XML_SetStartElementHandler(XML_Parser p,
-                           XML_StartElementHandler start);
-
-
-typedef void
-(XMLCALL *XML_StartElementHandler)(void *userData,
-                                   const XML_Char *name,
-                                   const XML_Char **atts);
-
-

Set handler for start (and empty) tags. Attributes are passed to the start -handler as a pointer to a vector of char pointers. Each attribute seen in -a start (or empty) tag occupies 2 consecutive places in this vector: the -attribute name followed by the attribute value. These pairs are terminated -by a null pointer.

-

Note that an empty tag generates a call to both start and end handlers -(in that order).

-
- -
-
-void XMLCALL
-XML_SetEndElementHandler(XML_Parser p,
-                         XML_EndElementHandler);
-
-
-typedef void
-(XMLCALL *XML_EndElementHandler)(void *userData,
-                                 const XML_Char *name);
-
-

Set handler for end (and empty) tags. As noted above, an empty tag -generates a call to both start and end handlers.

-
- -
-
-void XMLCALL
-XML_SetElementHandler(XML_Parser p,
-                      XML_StartElementHandler start,
-                      XML_EndElementHandler end);
-
-

Set handlers for start and end tags with one call.

-
- -
-
-void XMLCALL
-XML_SetCharacterDataHandler(XML_Parser p,
-                            XML_CharacterDataHandler charhndl)
-
-
-typedef void
-(XMLCALL *XML_CharacterDataHandler)(void *userData,
-                                    const XML_Char *s,
-                                    int len);
-
-

Set a text handler. The string your handler receives -is NOT nul-terminated. You have to use the length argument -to deal with the end of the string. A single block of contiguous text -free of markup may still result in a sequence of calls to this handler. -In other words, if you're searching for a pattern in the text, it may -be split across calls to this handler. Note: Setting this handler to NULL -may NOT immediately terminate call-backs if the parser is currently -processing such a single block of contiguous markup-free text, as the parser -will continue calling back until the end of the block is reached.

-
- -
-
-void XMLCALL
-XML_SetProcessingInstructionHandler(XML_Parser p,
-                                    XML_ProcessingInstructionHandler proc)
-
-
-typedef void
-(XMLCALL *XML_ProcessingInstructionHandler)(void *userData,
-                                            const XML_Char *target,
-                                            const XML_Char *data);
-
-
-

Set a handler for processing instructions. The target is the first word -in the processing instruction. The data is the rest of the characters in -it after skipping all whitespace after the initial word.

-
- -
-
-void XMLCALL
-XML_SetCommentHandler(XML_Parser p,
-                      XML_CommentHandler cmnt)
-
-
-typedef void
-(XMLCALL *XML_CommentHandler)(void *userData,
-                              const XML_Char *data);
-
-

Set a handler for comments. The data is all text inside the comment -delimiters.

-
- -
-
-void XMLCALL
-XML_SetStartCdataSectionHandler(XML_Parser p,
-                                XML_StartCdataSectionHandler start);
-
-
-typedef void
-(XMLCALL *XML_StartCdataSectionHandler)(void *userData);
-
-

Set a handler that gets called at the beginning of a CDATA section.

-
- -
-
-void XMLCALL
-XML_SetEndCdataSectionHandler(XML_Parser p,
-                              XML_EndCdataSectionHandler end);
-
-
-typedef void
-(XMLCALL *XML_EndCdataSectionHandler)(void *userData);
-
-

Set a handler that gets called at the end of a CDATA section.

-
- -
-
-void XMLCALL
-XML_SetCdataSectionHandler(XML_Parser p,
-                           XML_StartCdataSectionHandler start,
-                           XML_EndCdataSectionHandler end)
-
-

Sets both CDATA section handlers with one call.

-
- -
-
-void XMLCALL
-XML_SetDefaultHandler(XML_Parser p,
-                      XML_DefaultHandler hndl)
-
-
-typedef void
-(XMLCALL *XML_DefaultHandler)(void *userData,
-                              const XML_Char *s,
-                              int len);
-
- -

Sets a handler for any characters in the document which wouldn't -otherwise be handled. This includes both data for which no handlers -can be set (like some kinds of DTD declarations) and data which could -be reported but which currently has no handler set. The characters -are passed exactly as they were present in the XML document except -that they will be encoded in UTF-8 or UTF-16. Line boundaries are not -normalized. Note that a byte order mark character is not passed to the -default handler. There are no guarantees about how characters are -divided between calls to the default handler: for example, a comment -might be split between multiple calls. Setting the handler with -this call has the side effect of turning off expansion of references -to internally defined general entities. Instead these references are -passed to the default handler.

- -

See also XML_DefaultCurrent.

-
- -
-
-void XMLCALL
-XML_SetDefaultHandlerExpand(XML_Parser p,
-                            XML_DefaultHandler hndl)
-
-
-typedef void
-(XMLCALL *XML_DefaultHandler)(void *userData,
-                              const XML_Char *s,
-                              int len);
-
-

This sets a default handler, but doesn't inhibit the expansion of -internal entity references. The entity reference will not be passed -to the default handler.

- -

See also XML_DefaultCurrent.

-
- -
-
-void XMLCALL
-XML_SetExternalEntityRefHandler(XML_Parser p,
-                                XML_ExternalEntityRefHandler hndl)
-
-
-typedef int
-(XMLCALL *XML_ExternalEntityRefHandler)(XML_Parser p,
-                                        const XML_Char *context,
-                                        const XML_Char *base,
-                                        const XML_Char *systemId,
-                                        const XML_Char *publicId);
-
-

Set an external entity reference handler. This handler is also -called for processing an external DTD subset if parameter entity parsing -is in effect. (See -XML_SetParamEntityParsing.)

- -

The context parameter specifies the parsing context in -the format expected by the context argument to XML_ExternalEntityParserCreate. code is -valid only until the handler returns, so if the referenced entity is -to be parsed later, it must be copied. context is NULL -only when the entity is a parameter entity, which is how one can -differentiate between general and parameter entities.

- -

The base parameter is the base to use for relative -system identifiers. It is set by XML_SetBase and may be NULL. The -publicId parameter is the public id given in the entity -declaration and may be NULL. systemId is the system -identifier specified in the entity declaration and is never NULL.

- -

There are a couple of ways in which this handler differs from -others. First, this handler returns a status indicator (an -integer). XML_STATUS_OK should be returned for successful -handling of the external entity reference. Returning -XML_STATUS_ERROR indicates failure, and causes the -calling parser to return an -XML_ERROR_EXTERNAL_ENTITY_HANDLING error.

- -

Second, instead of having the user data as its first argument, it -receives the parser that encountered the entity reference. This, along -with the context parameter, may be used as arguments to a call to -XML_ExternalEntityParserCreate. Using the returned -parser, the body of the external entity can be recursively parsed.

- -

Since this handler may be called recursively, it should not be saving -information into global or static variables.

-
- -
-void XMLCALL
-XML_SetExternalEntityRefHandlerArg(XML_Parser p,
-                                   void *arg)
-
-
-

Set the argument passed to the ExternalEntityRefHandler. If -arg is not NULL, it is the new value passed to the -handler set using XML_SetExternalEntityRefHandler; if arg is -NULL, the argument passed to the handler function will be the parser -object itself.

- -

Note: -The type of arg and the type of the first argument to the -ExternalEntityRefHandler do not match. This function takes a -void * to be passed to the handler, while the handler -accepts an XML_Parser. This is a historical accident, -but will not be corrected before Expat 2.0 (at the earliest) to avoid -causing compiler warnings for code that's known to work with this -API. It is the responsibility of the application code to know the -actual type of the argument passed to the handler and to manage it -properly.

-
- -
-
-void XMLCALL
-XML_SetSkippedEntityHandler(XML_Parser p,
-                            XML_SkippedEntityHandler handler)
-
-
-typedef void
-(XMLCALL *XML_SkippedEntityHandler)(void *userData,
-                                    const XML_Char *entityName,
-                                    int is_parameter_entity);
-
-

Set a skipped entity handler. This is called in two situations:

-
    -
  1. An entity reference is encountered for which no declaration - has been read and this is not an error.
  2. -
  3. An internal entity reference is read, but not expanded, because - XML_SetDefaultHandler - has been called.
  4. -
-

The is_parameter_entity argument will be non-zero for -a parameter entity and zero for a general entity.

Note: skipped -parameter entities in declarations and skipped general entities in -attribute values cannot be reported, because the event would be out of -sync with the reporting of the declarations or attribute values

-
- -
-
-void XMLCALL
-XML_SetUnknownEncodingHandler(XML_Parser p,
-                              XML_UnknownEncodingHandler enchandler,
-			      void *encodingHandlerData)
-
-
-typedef int
-(XMLCALL *XML_UnknownEncodingHandler)(void *encodingHandlerData,
-                                      const XML_Char *name,
-                                      XML_Encoding *info);
-
-typedef struct {
-  int map[256];
-  void *data;
-  int (XMLCALL *convert)(void *data, const char *s);
-  void (XMLCALL *release)(void *data);
-} XML_Encoding;
-
-

Set a handler to deal with encodings other than the built in set. This should be done before -XML_Parse or XML_ParseBuffer have been called on the -given parser.

If the handler knows how to deal with an encoding -with the given name, it should fill in the info data -structure and return XML_STATUS_OK. Otherwise it -should return XML_STATUS_ERROR. The handler will be called -at most once per parsed (external) entity. The optional application -data pointer encodingHandlerData will be passed back to -the handler.

- -

The map array contains information for every possible possible leading -byte in a byte sequence. If the corresponding value is >= 0, then it's -a single byte sequence and the byte encodes that Unicode value. If the -value is -1, then that byte is invalid as the initial byte in a sequence. -If the value is -n, where n is an integer > 1, then n is the number of -bytes in the sequence and the actual conversion is accomplished by a -call to the function pointed at by convert. This function may return -1 -if the sequence itself is invalid. The convert pointer may be null if -there are only single byte codes. The data parameter passed to the convert -function is the data pointer from XML_Encoding. The -string s is NOT nul-terminated and points at the sequence of -bytes to be converted.

- -

The function pointed at by release is called by the -parser when it is finished with the encoding. It may be NULL.

-
- -
-
-void XMLCALL
-XML_SetStartNamespaceDeclHandler(XML_Parser p,
-			         XML_StartNamespaceDeclHandler start);
-
-
-typedef void
-(XMLCALL *XML_StartNamespaceDeclHandler)(void *userData,
-                                         const XML_Char *prefix,
-                                         const XML_Char *uri);
-
-

Set a handler to be called when a namespace is declared. Namespace -declarations occur inside start tags. But the namespace declaration start -handler is called before the start tag handler for each namespace declared -in that start tag.

-
- -
-
-void XMLCALL
-XML_SetEndNamespaceDeclHandler(XML_Parser p,
-			       XML_EndNamespaceDeclHandler end);
-
-
-typedef void
-(XMLCALL *XML_EndNamespaceDeclHandler)(void *userData,
-                                       const XML_Char *prefix);
-
-

Set a handler to be called when leaving the scope of a namespace -declaration. This will be called, for each namespace declaration, -after the handler for the end tag of the element in which the -namespace was declared.

-
- -
-
-void XMLCALL
-XML_SetNamespaceDeclHandler(XML_Parser p,
-                            XML_StartNamespaceDeclHandler start,
-                            XML_EndNamespaceDeclHandler end)
-
-

Sets both namespace declaration handlers with a single call.

-
- -
-
-void XMLCALL
-XML_SetXmlDeclHandler(XML_Parser p,
-		      XML_XmlDeclHandler xmldecl);
-
-
-typedef void
-(XMLCALL *XML_XmlDeclHandler)(void            *userData,
-                              const XML_Char  *version,
-                              const XML_Char  *encoding,
-                              int             standalone);
-
-

Sets a handler that is called for XML declarations and also for -text declarations discovered in external entities. The way to -distinguish is that the version parameter will be NULL -for text declarations. The encoding parameter may be NULL -for an XML declaration. The standalone argument will -contain -1, 0, or 1 indicating respectively that there was no -standalone parameter in the declaration, that it was given as no, or -that it was given as yes.

-
- -
-
-void XMLCALL
-XML_SetStartDoctypeDeclHandler(XML_Parser p,
-			       XML_StartDoctypeDeclHandler start);
-
-
-typedef void
-(XMLCALL *XML_StartDoctypeDeclHandler)(void           *userData,
-                                       const XML_Char *doctypeName,
-                                       const XML_Char *sysid,
-                                       const XML_Char *pubid,
-                                       int            has_internal_subset);
-
-

Set a handler that is called at the start of a DOCTYPE declaration, -before any external or internal subset is parsed. Both sysid -and pubid may be NULL. The has_internal_subset -will be non-zero if the DOCTYPE declaration has an internal subset.

-
- -
-
-void XMLCALL
-XML_SetEndDoctypeDeclHandler(XML_Parser p,
-			     XML_EndDoctypeDeclHandler end);
-
-
-typedef void
-(XMLCALL *XML_EndDoctypeDeclHandler)(void *userData);
-
-

Set a handler that is called at the end of a DOCTYPE declaration, -after parsing any external subset.

-
- -
-
-void XMLCALL
-XML_SetDoctypeDeclHandler(XML_Parser p,
-			  XML_StartDoctypeDeclHandler start,
-			  XML_EndDoctypeDeclHandler end);
-
-

Set both doctype handlers with one call.

-
- -
-
-void XMLCALL
-XML_SetElementDeclHandler(XML_Parser p,
-			  XML_ElementDeclHandler eldecl);
-
-
-typedef void
-(XMLCALL *XML_ElementDeclHandler)(void *userData,
-                                  const XML_Char *name,
-                                  XML_Content *model);
-
-
-enum XML_Content_Type {
-  XML_CTYPE_EMPTY = 1,
-  XML_CTYPE_ANY,
-  XML_CTYPE_MIXED,
-  XML_CTYPE_NAME,
-  XML_CTYPE_CHOICE,
-  XML_CTYPE_SEQ
-};
-
-enum XML_Content_Quant {
-  XML_CQUANT_NONE,
-  XML_CQUANT_OPT,
-  XML_CQUANT_REP,
-  XML_CQUANT_PLUS
-};
-
-typedef struct XML_cp XML_Content;
-
-struct XML_cp {
-  enum XML_Content_Type		type;
-  enum XML_Content_Quant	quant;
-  const XML_Char *		name;
-  unsigned int			numchildren;
-  XML_Content *			children;
-};
-
-

Sets a handler for element declarations in a DTD. The handler gets -called with the name of the element in the declaration and a pointer -to a structure that contains the element model. It is the -application's responsibility to free this data structure using -XML_FreeContentModel.

- -

The model argument is the root of a tree of -XML_Content nodes. If type equals -XML_CTYPE_EMPTY or XML_CTYPE_ANY, then -quant will be XML_CQUANT_NONE, and the other -fields will be zero or NULL. If type is -XML_CTYPE_MIXED, then quant will be -XML_CQUANT_NONE or XML_CQUANT_REP and -numchildren will contain the number of elements that are -allowed to be mixed in and children points to an array of -XML_Content structures that will all have type -XML_CTYPE_NAME with no quantification. Only the root node can be type -XML_CTYPE_EMPTY, XML_CTYPE_ANY, or -XML_CTYPE_MIXED.

- -

For type XML_CTYPE_NAME, the name field -points to the name and the numchildren and -children fields will be zero and NULL. The -quant field will indicate any quantifiers placed on the -name.

- -

Types XML_CTYPE_CHOICE and XML_CTYPE_SEQ -indicate a choice or sequence respectively. The -numchildren field indicates how many nodes in the choice -or sequence and children points to the nodes.

-
- -
-
-void XMLCALL
-XML_SetAttlistDeclHandler(XML_Parser p,
-                          XML_AttlistDeclHandler attdecl);
-
-
-typedef void
-(XMLCALL *XML_AttlistDeclHandler)(void           *userData,
-                                  const XML_Char *elname,
-                                  const XML_Char *attname,
-                                  const XML_Char *att_type,
-                                  const XML_Char *dflt,
-                                  int            isrequired);
-
-

Set a handler for attlist declarations in the DTD. This handler is -called for each attribute. So a single attlist declaration -with multiple attributes declared will generate multiple calls to this -handler. The elname parameter returns the name of the -element for which the attribute is being declared. The attribute name -is in the attname parameter. The attribute type is in the -att_type parameter. It is the string representing the -type in the declaration with whitespace removed.

- -

The dflt parameter holds the default value. It will be -NULL in the case of "#IMPLIED" or "#REQUIRED" attributes. You can -distinguish these two cases by checking the isrequired -parameter, which will be true in the case of "#REQUIRED" attributes. -Attributes which are "#FIXED" will have also have a true -isrequired, but they will have the non-NULL fixed value -in the dflt parameter.

-
- -
-
-void XMLCALL
-XML_SetEntityDeclHandler(XML_Parser p,
-			 XML_EntityDeclHandler handler);
-
-
-typedef void
-(XMLCALL *XML_EntityDeclHandler)(void           *userData,
-                                 const XML_Char *entityName,
-                                 int            is_parameter_entity,
-                                 const XML_Char *value,
-                                 int            value_length, 
-                                 const XML_Char *base,
-                                 const XML_Char *systemId,
-                                 const XML_Char *publicId,
-                                 const XML_Char *notationName);
-
-

Sets a handler that will be called for all entity declarations. -The is_parameter_entity argument will be non-zero in the -case of parameter entities and zero otherwise.

- -

For internal entities (<!ENTITY foo "bar">), -value will be non-NULL and systemId, -publicId, and notationName will all be NULL. -The value string is not NULL terminated; the length is -provided in the value_length parameter. Do not use -value_length to test for internal entities, since it is -legal to have zero-length values. Instead check for whether or not -value is NULL.

The notationName -argument will have a non-NULL value only for unparsed entity -declarations.

-
- -
-
-void XMLCALL
-XML_SetUnparsedEntityDeclHandler(XML_Parser p,
-                                 XML_UnparsedEntityDeclHandler h)
-
-
-typedef void
-(XMLCALL *XML_UnparsedEntityDeclHandler)(void *userData,
-                                         const XML_Char *entityName, 
-                                         const XML_Char *base,
-                                         const XML_Char *systemId,
-                                         const XML_Char *publicId,
-                                         const XML_Char *notationName);
-
-

Set a handler that receives declarations of unparsed entities. These -are entity declarations that have a notation (NDATA) field:

- -
-<!ENTITY logo SYSTEM "images/logo.gif" NDATA gif>
-
-

This handler is obsolete and is provided for backwards -compatibility. Use instead XML_SetEntityDeclHandler.

-
- -
-
-void XMLCALL
-XML_SetNotationDeclHandler(XML_Parser p,
-                           XML_NotationDeclHandler h)
-
-
-typedef void
-(XMLCALL *XML_NotationDeclHandler)(void *userData, 
-                                   const XML_Char *notationName,
-                                   const XML_Char *base,
-                                   const XML_Char *systemId,
-                                   const XML_Char *publicId);
-
-

Set a handler that receives notation declarations.

-
- -
-
-void XMLCALL
-XML_SetNotStandaloneHandler(XML_Parser p,
-                            XML_NotStandaloneHandler h)
-
-
-typedef int 
-(XMLCALL *XML_NotStandaloneHandler)(void *userData);
-
-

Set a handler that is called if the document is not "standalone". -This happens when there is an external subset or a reference to a -parameter entity, but does not have standalone set to "yes" in an XML -declaration. If this handler returns XML_STATUS_ERROR, -then the parser will throw an XML_ERROR_NOT_STANDALONE -error.

-
- -

Parse position and error reporting functions

- -

These are the functions you'll want to call when the parse -functions return XML_STATUS_ERROR (a parse error has -occurred), although the position reporting functions are useful outside -of errors. The position reported is the byte position (in the original -document or entity encoding) of the first of the sequence of -characters that generated the current event (or the error that caused -the parse functions to return XML_STATUS_ERROR.) The -exceptions are callbacks trigged by declarations in the document -prologue, in which case they exact position reported is somewhere in the -relevant markup, but not necessarily as meaningful as for other -events.

- -

The position reporting functions are accurate only outside of the -DTD. In other words, they usually return bogus information when -called from within a DTD declaration handler.

- -
-enum XML_Error XMLCALL
-XML_GetErrorCode(XML_Parser p);
-
-
-Return what type of error has occurred. -
- -
-const XML_LChar * XMLCALL
-XML_ErrorString(enum XML_Error code);
-
-
-Return a string describing the error corresponding to code. -The code should be one of the enums that can be returned from -XML_GetErrorCode. -
- -
-XML_Index XMLCALL
-XML_GetCurrentByteIndex(XML_Parser p);
-
-
-Return the byte offset of the position. This always corresponds to -the values returned by XML_GetCurrentLineNumber and XML_GetCurrentColumnNumber. -
- -
-XML_Size XMLCALL
-XML_GetCurrentLineNumber(XML_Parser p);
-
-
-Return the line number of the position. The first line is reported as -1. -
- -
-XML_Size XMLCALL
-XML_GetCurrentColumnNumber(XML_Parser p);
-
-
-Return the offset, from the beginning of the current line, of -the position. -
- -
-int XMLCALL
-XML_GetCurrentByteCount(XML_Parser p);
-
-
-Return the number of bytes in the current event. Returns -0 if the event is inside a reference to an internal -entity and for the end-tag event for empty element tags (the later can -be used to distinguish empty-element tags from empty elements using -separate start and end tags). -
- -
-const char * XMLCALL
-XML_GetInputContext(XML_Parser p,
-                    int *offset,
-                    int *size);
-
-
- -

Returns the parser's input buffer, sets the integer pointed at by -offset to the offset within this buffer of the current -parse position, and set the integer pointed at by size to -the size of the returned buffer.

- -

This should only be called from within a handler during an active -parse and the returned buffer should only be referred to from within -the handler that made the call. This input buffer contains the -untranslated bytes of the input.

- -

Only a limited amount of context is kept, so if the event -triggering a call spans over a very large amount of input, the actual -parse position may be before the beginning of the buffer.

- -

If XML_CONTEXT_BYTES is not defined, this will always -return NULL.

-
- -

Miscellaneous functions

- -

The functions in this section either obtain state information from -the parser or can be used to dynamicly set parser options.

- -
-void XMLCALL
-XML_SetUserData(XML_Parser p,
-                void *userData);
-
-
-This sets the user data pointer that gets passed to handlers. It -overwrites any previous value for this pointer. Note that the -application is responsible for freeing the memory associated with -userData when it is finished with the parser. So if you -call this when there's already a pointer there, and you haven't freed -the memory associated with it, then you've probably just leaked -memory. -
- -
-void * XMLCALL
-XML_GetUserData(XML_Parser p);
-
-
-This returns the user data pointer that gets passed to handlers. -It is actually implemented as a macro. -
- -
-void XMLCALL
-XML_UseParserAsHandlerArg(XML_Parser p);
-
-
-After this is called, handlers receive the parser in their -userData arguments. The user data can still be obtained -using the XML_GetUserData function. -
- -
-enum XML_Status XMLCALL
-XML_SetBase(XML_Parser p,
-            const XML_Char *base);
-
-
-Set the base to be used for resolving relative URIs in system -identifiers. The return value is XML_STATUS_ERROR if -there's no memory to store base, otherwise it's -XML_STATUS_OK. -
- -
-const XML_Char * XMLCALL
-XML_GetBase(XML_Parser p);
-
-
-Return the base for resolving relative URIs. -
- -
-int XMLCALL
-XML_GetSpecifiedAttributeCount(XML_Parser p);
-
-
-When attributes are reported to the start handler in the atts vector, -attributes that were explicitly set in the element occur before any -attributes that receive their value from default information in an -ATTLIST declaration. This function returns the number of attributes -that were explicitly set times two, thus giving the offset in the -atts array passed to the start tag handler of the first -attribute set due to defaults. It supplies information for the last -call to a start handler. If called inside a start handler, then that -means the current call. -
- -
-int XMLCALL
-XML_GetIdAttributeIndex(XML_Parser p);
-
-
-Returns the index of the ID attribute passed in the atts array in the -last call to XML_StartElementHandler, or -1 if there is no ID -attribute. If called inside a start handler, then that means the -current call. -
- -
-const XML_AttrInfo * XMLCALL
-XML_GetAttributeInfo(XML_Parser parser);
-
-
-typedef struct {
-  XML_Index  nameStart;  /* Offset to beginning of the attribute name. */
-  XML_Index  nameEnd;    /* Offset after the attribute name's last byte. */
-  XML_Index  valueStart; /* Offset to beginning of the attribute value. */
-  XML_Index  valueEnd;   /* Offset after the attribute value's last byte. */
-} XML_AttrInfo;
-
-
-Returns an array of XML_AttrInfo structures for the -attribute/value pairs passed in the last call to the -XML_StartElementHandler that were specified -in the start-tag rather than defaulted. Each attribute/value pair counts -as 1; thus the number of entries in the array is -XML_GetSpecifiedAttributeCount(parser) / 2. -
- -
-enum XML_Status XMLCALL
-XML_SetEncoding(XML_Parser p,
-                const XML_Char *encoding);
-
-
-Set the encoding to be used by the parser. It is equivalent to -passing a non-null encoding argument to the parser creation functions. -It must not be called after XML_Parse or XML_ParseBuffer have been called on the given parser. -Returns XML_STATUS_OK on success or -XML_STATUS_ERROR on error. -
- -
-int XMLCALL
-XML_SetParamEntityParsing(XML_Parser p,
-                          enum XML_ParamEntityParsing code);
-
-
-This enables parsing of parameter entities, including the external -parameter entity that is the external DTD subset, according to -code. -The choices for code are: -
    -
  • XML_PARAM_ENTITY_PARSING_NEVER
  • -
  • XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE
  • -
  • XML_PARAM_ENTITY_PARSING_ALWAYS
  • -
-Note: If XML_SetParamEntityParsing is called after -XML_Parse or XML_ParseBuffer, then it has -no effect and will always return 0. -
- -
-int XMLCALL
-XML_SetHashSalt(XML_Parser p,
-                unsigned long hash_salt);
-
-
-Sets the hash salt to use for internal hash calculations. -Helps in preventing DoS attacks based on predicting hash -function behavior. In order to have an effect this must be called -before parsing has started. Returns 1 if successful, 0 when called -after XML_Parse or XML_ParseBuffer. -

Note: This call is optional, as the parser will auto-generate a new -random salt value if no value has been set at the start of parsing.

-
- -
-enum XML_Error XMLCALL
-XML_UseForeignDTD(XML_Parser parser, XML_Bool useDTD);
-
-
-

This function allows an application to provide an external subset -for the document type declaration for documents which do not specify -an external subset of their own. For documents which specify an -external subset in their DOCTYPE declaration, the application-provided -subset will be ignored. If the document does not contain a DOCTYPE -declaration at all and useDTD is true, the -application-provided subset will be parsed, but the -startDoctypeDeclHandler and -endDoctypeDeclHandler functions, if set, will not be -called. The setting of parameter entity parsing, controlled using -XML_SetParamEntityParsing, will be honored.

- -

The application-provided external subset is read by calling the -external entity reference handler set via XML_SetExternalEntityRefHandler with both -publicId and systemId set to NULL.

- -

If this function is called after parsing has begun, it returns -XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING and ignores -useDTD. If called when Expat has been compiled without -DTD support, it returns -XML_ERROR_FEATURE_REQUIRES_XML_DTD. Otherwise, it -returns XML_ERROR_NONE.

- -

Note: For the purpose of checking WFC: Entity Declared, passing -useDTD == XML_TRUE will make the parser behave as if -the document had a DTD with an external subset. This holds true even if -the external entity reference handler returns without action.

-
- -
-void XMLCALL
-XML_SetReturnNSTriplet(XML_Parser parser,
-                       int        do_nst);
-
-
-

-This function only has an effect when using a parser created with -XML_ParserCreateNS, -i.e. when namespace processing is in effect. The do_nst -sets whether or not prefixes are returned with names qualified with a -namespace prefix. If this function is called with do_nst -non-zero, then afterwards namespace qualified names (that is qualified -with a prefix as opposed to belonging to a default namespace) are -returned as a triplet with the three parts separated by the namespace -separator specified when the parser was created. The order of -returned parts is URI, local name, and prefix.

If -do_nst is zero, then namespaces are reported in the -default manner, URI then local_name separated by the namespace -separator.

-
- -
-void XMLCALL
-XML_DefaultCurrent(XML_Parser parser);
-
-
-This can be called within a handler for a start element, end element, -processing instruction or character data. It causes the corresponding -markup to be passed to the default handler set by XML_SetDefaultHandler or -XML_SetDefaultHandlerExpand. It does nothing if there is -not a default handler. -
- -
-XML_LChar * XMLCALL
-XML_ExpatVersion();
-
-
-Return the library version as a string (e.g. "expat_1.95.1"). -
- -
-struct XML_Expat_Version XMLCALL
-XML_ExpatVersionInfo();
-
-
-typedef struct {
-  int major;
-  int minor;
-  int micro;
-} XML_Expat_Version;
-
-
-Return the library version information as a structure. -Some macros are also defined that support compile-time tests of the -library version: -
    -
  • XML_MAJOR_VERSION
  • -
  • XML_MINOR_VERSION
  • -
  • XML_MICRO_VERSION
  • -
-Testing these constants is currently the best way to determine if -particular parts of the Expat API are available. -
- -
-const XML_Feature * XMLCALL
-XML_GetFeatureList();
-
-
-enum XML_FeatureEnum {
-  XML_FEATURE_END = 0,
-  XML_FEATURE_UNICODE,
-  XML_FEATURE_UNICODE_WCHAR_T,
-  XML_FEATURE_DTD,
-  XML_FEATURE_CONTEXT_BYTES,
-  XML_FEATURE_MIN_SIZE,
-  XML_FEATURE_SIZEOF_XML_CHAR,
-  XML_FEATURE_SIZEOF_XML_LCHAR,
-  XML_FEATURE_NS,
-  XML_FEATURE_LARGE_SIZE
-};
-
-typedef struct {
-  enum XML_FeatureEnum  feature;
-  XML_LChar            *name;
-  long int              value;
-} XML_Feature;
-
-
-

Returns a list of "feature" records, providing details on how -Expat was configured at compile time. Most applications should not -need to worry about this, but this information is otherwise not -available from Expat. This function allows code that does need to -check these features to do so at runtime.

- -

The return value is an array of XML_Feature, -terminated by a record with a feature of -XML_FEATURE_END and name of NULL, -identifying the feature-test macros Expat was compiled with. Since an -application that requires this kind of information needs to determine -the type of character the name points to, records for the -XML_FEATURE_SIZEOF_XML_CHAR and -XML_FEATURE_SIZEOF_XML_LCHAR will be located at the -beginning of the list, followed by XML_FEATURE_UNICODE -and XML_FEATURE_UNICODE_WCHAR_T, if they are present at -all.

- -

Some features have an associated value. If there isn't an -associated value, the value field is set to 0. At this -time, the following features have been defined to have values:

- -
-
XML_FEATURE_SIZEOF_XML_CHAR
-
The number of bytes occupied by one XML_Char - character.
-
XML_FEATURE_SIZEOF_XML_LCHAR
-
The number of bytes occupied by one XML_LChar - character.
-
XML_FEATURE_CONTEXT_BYTES
-
The maximum number of characters of context which can be - reported by XML_GetInputContext.
-
-
- -
-void XMLCALL
-XML_FreeContentModel(XML_Parser parser, XML_Content *model);
-
-
-Function to deallocate the model argument passed to the -XML_ElementDeclHandler callback set using XML_ElementDeclHandler. -This function should not be used for any other purpose. -
- -

The following functions allow external code to share the memory -allocator an XML_Parser has been configured to use. This -is especially useful for third-party libraries that interact with a -parser object created by application code, or heavily layered -applications. This can be essential when using dynamically loaded -libraries which use different C standard libraries (this can happen on -Windows, at least).

- -
-void * XMLCALL
-XML_MemMalloc(XML_Parser parser, size_t size);
-
-
-Allocate size bytes of memory using the allocator the -parser object has been configured to use. Returns a -pointer to the memory or NULL on failure. Memory allocated in this -way must be freed using XML_MemFree. -
- -
-void * XMLCALL
-XML_MemRealloc(XML_Parser parser, void *ptr, size_t size);
-
-
-Allocate size bytes of memory using the allocator the -parser object has been configured to use. -ptr must point to a block of memory allocated by XML_MemMalloc or -XML_MemRealloc, or be NULL. This function tries to -expand the block pointed to by ptr if possible. Returns -a pointer to the memory or NULL on failure. On success, the original -block has either been expanded or freed. On failure, the original -block has not been freed; the caller is responsible for freeing the -original block. Memory allocated in this way must be freed using -XML_MemFree. -
- -
-void XMLCALL
-XML_MemFree(XML_Parser parser, void *ptr);
-
-
-Free a block of memory pointed to by ptr. The block must -have been allocated by XML_MemMalloc or XML_MemRealloc, or be NULL. -
- -
-

Valid XHTML 1.0!

-
- - diff --git a/lib-src/expat/doc/style.css b/lib-src/expat/doc/style.css deleted file mode 100644 index 69df30bce..000000000 --- a/lib-src/expat/doc/style.css +++ /dev/null @@ -1,101 +0,0 @@ -body { - background-color: white; - border: 0px; - margin: 0px; - padding: 0px; -} - -.corner { - width: 200px; - height: 80px; - text-align: center; -} - -.banner { - background-color: rgb(110,139,61); - color: rgb(255,236,176); - padding-left: 2em; -} - -.banner h1 { - font-size: 200%; -} - -.content { - padding: 0em 2em 1em 2em; -} - -.releaseno { - background-color: rgb(110,139,61); - color: rgb(255,236,176); - padding-bottom: 0.3em; - padding-top: 0.5em; - text-align: center; - font-weight: bold; -} - -.noborder { - border-width: 0px; -} - -.eg { - padding-left: 1em; - padding-top: .5em; - padding-bottom: .5em; - border: solid thin; - margin: 1em 0; - background-color: tan; - margin-left: 2em; - margin-right: 10%; -} - -.pseudocode { - padding-left: 1em; - padding-top: .5em; - padding-bottom: .5em; - border: solid thin; - margin: 1em 0; - background-color: rgb(250,220,180); - margin-left: 2em; - margin-right: 10%; -} - -.handler { - width: 100%; - border-top-width: thin; - margin-bottom: 1em; -} - -.handler p { - margin-left: 2em; -} - -.setter { - font-weight: bold; -} - -.signature { - color: navy; -} - -.fcndec { - width: 100%; - border-top-width: thin; - font-weight: bold; -} - -.fcndef { - margin-left: 2em; - margin-bottom: 2em; -} - -dd { - margin-bottom: 2em; -} - -.cpp-symbols dt { - font-family: monospace; -} -.cpp-symbols dd { - margin-bottom: 1em; -} diff --git a/lib-src/expat/doc/valid-xhtml10.png b/lib-src/expat/doc/valid-xhtml10.png deleted file mode 100644 index 4c23f48fe02a58fbb3d1088e6a7d372568830b53..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2368 zcmbVNX;2f{7H-8QAWIODU~n{oVqipj2Gj;zXrn-jfGsLCqYzsnPDF&p1zT|;Y|_rS zG$U$6T%rydH;kg#qJRP9(E@6_VH9x;sL%+GanDQ5do}fb&5w6(-TKbG-???Zuj*9Y zyvXoiJDXuP007v9hR9G0MqBm>ffWGsad*5W1AxA{kzr9YEtdwPktHFmR%@VOjSA)& zoWU@I3T8>tpwXyl(x5~21YyvkYJtGSU^GS0B#P4v2q8Gd&;Y=2MoP=_T2#YuoPk$q z^sK?iaz>G*Rw`f+2}zO|h6sfMihzU&g`o&R5IPzW2mqB5l!z<{sBloJRB9=hBOtvR zG4ni*7aZszoQI$?fGZ2KRb(~rN=#@$}0O&Ostz&hN2!bFDDiw(YGzpP7C=v>2 z0s=vhQ6pN3&|okCAj!~(PykR$5Rj5msZ>K@9LMP>m}OZbZ_?}aj0RIdQYo$`)C{9j zV=5i1!OSMk(%j5*I4Z>vDFCT>Jq~~>H3_Lz7)^j$8Y2mdY>cL9t=?cVn@uJ&Oln~S zVf1=Jt>=t9OlT>Jf?=WC}BuMC{d|INMN9uQ^KH#u(V^9Mg~J+ z39CUZq)~^NSX@P*COwW}m_-@{BYI4#qcH(OqbRCl4H8TZAe8y90F@eADFt8(A+-pC zkQNO(++gH!3^n}~oEC>+*r3%K8Jy>N2oxDD1v-ln6qE{SnnWNGsYF4Ekfulsk#Jgz zLIHtEdCO$L5;KQ$8k8a}I&rfeSE3S?mKBLaW}dLP6=Jm6NHA(lh|)SlA`}W4*1#|f zL}&yEg`x4lr}-7+3wMlqyF={n!T4V9EeMwS$Ii;hQ-5s#b|B-& z^0k*l@0<7rwu{X$l~;V6qOf-+-Z)Obd4U}D_8z_2@7au-G3OHKvyQVoL<7(6Uzppk z&GDM}&q#-oZcXiiH?z__HO>^+cSHCYkr=Oj&KaDoWCQW3U`x!sK~)9g$gdf2c4&Ni z?6=WkP3)S+*n-#grETtop`{*2LPpDF8)Qz_c*KyCEn~xuQKh&4dZx!4%?5Owj^wrHZNb`-KoZWZr0n-NbZyfPpZP1Pz?!j)p zA#oS|y0+~LvYk?~u6l_hboP3aXoT0Hw7?UOS4@4m` zla;1?MUFD#{O8zftHeEci3}{h+c~lNmhggf`n3v&y@|`E=jTjwLd9e9YqP9EV)CU) zn@SJ+9>=t`+i@5$X& zOBeezmLz^$vA#foB1=_E@Ao0R%F|+I8Gov(yZ3Q&SW#lM(4RXnpD#9yYOsxaJxM$y z!78@1s^M0))$*){Wwl6sfVzb#J$3rbsg#S$j!*Irnj5h`wOj1E^@G#F_+K+86-CPL z%Uc~9oW5ksb3cT&ZZGOL?COAJw|(2MPM^B7%KG!lfXg}Od>zV$*0=3@{poe$n^>oZ zH7nwKpNQl2p5eCpI?G<#NJPyiteboLKe@fVcwt0+AknetuD;JtT+6%#w>HfU{m$*$7tbeM1BWUc?BhDKavT?o_Xm$VDzO{fhUl-g4+v}5J?CesCp7o}6bHRC@XBLld<~&;{ zY{J|{xm6nB^Wdszc1HftOZyrR(@Pf>h7I=V*!!$-#`B8rd*^lCZw{ypv>cHaiN!w>szMg{>z%h_f_Id>mx^<^GRN#Xz zCqC>xeER9jv|qL-R{9b4JLfIx#IJOt(M<|J`QG|Uz9BR{&|p2tcDuvG#-?KT)_rZa zgRl!rLYIhNJ)ip0)hqc{Q&z$L;7##mN4{QF@IUf40qL1fh9Zpi|Xcd6q+U5hJ@_A^g(aNKfk|iGsv=R1`YZs oi4;OEvV%bfcgjD_ar)+RxUQtjXTTPP<@*6bXNJp8!|_}H4I+HVz5oCK diff --git a/lib-src/expat/doc/xmlwf.1 b/lib-src/expat/doc/xmlwf.1 deleted file mode 100644 index 174719a70..000000000 --- a/lib-src/expat/doc/xmlwf.1 +++ /dev/null @@ -1,251 +0,0 @@ -.\" This manpage has been automatically generated by docbook2man -.\" from a DocBook document. This tool can be found at: -.\" -.\" Please send any bug reports, improvements, comments, patches, -.\" etc. to Steve Cheng . -.TH "XMLWF" "1" "24 January 2003" "" "" -.SH NAME -xmlwf \- Determines if an XML document is well-formed -.SH SYNOPSIS - -\fBxmlwf\fR [ \fB-s\fR] [ \fB-n\fR] [ \fB-p\fR] [ \fB-x\fR] [ \fB-e \fIencoding\fB\fR] [ \fB-w\fR] [ \fB-d \fIoutput-dir\fB\fR] [ \fB-c\fR] [ \fB-m\fR] [ \fB-r\fR] [ \fB-t\fR] [ \fB-v\fR] [ \fBfile ...\fR] - -.SH "DESCRIPTION" -.PP -\fBxmlwf\fR uses the Expat library to -determine if an XML document is well-formed. It is -non-validating. -.PP -If you do not specify any files on the command-line, and you -have a recent version of \fBxmlwf\fR, the -input file will be read from standard input. -.SH "WELL-FORMED DOCUMENTS" -.PP -A well-formed document must adhere to the -following rules: -.TP 0.2i -\(bu -The file begins with an XML declaration. For instance, -. -\fBNOTE:\fR -\fBxmlwf\fR does not currently -check for a valid XML declaration. -.TP 0.2i -\(bu -Every start tag is either empty () -or has a corresponding end tag. -.TP 0.2i -\(bu -There is exactly one root element. This element must contain -all other elements in the document. Only comments, white -space, and processing instructions may come after the close -of the root element. -.TP 0.2i -\(bu -All elements nest properly. -.TP 0.2i -\(bu -All attribute values are enclosed in quotes (either single -or double). -.PP -If the document has a DTD, and it strictly complies with that -DTD, then the document is also considered \fBvalid\fR. -\fBxmlwf\fR is a non-validating parser -- -it does not check the DTD. However, it does support -external entities (see the \fB-x\fR option). -.SH "OPTIONS" -.PP -When an option includes an argument, you may specify the argument either -separately ("\fB-d\fR output") or concatenated with the -option ("\fB-d\fRoutput"). \fBxmlwf\fR -supports both. -.TP -\fB-c\fR -If the input file is well-formed and \fBxmlwf\fR -doesn't encounter any errors, the input file is simply copied to -the output directory unchanged. -This implies no namespaces (turns off \fB-n\fR) and -requires \fB-d\fR to specify an output file. -.TP -\fB-d output-dir\fR -Specifies a directory to contain transformed -representations of the input files. -By default, \fB-d\fR outputs a canonical representation -(described below). -You can select different output formats using \fB-c\fR -and \fB-m\fR. - -The output filenames will -be exactly the same as the input filenames or "STDIN" if the input is -coming from standard input. Therefore, you must be careful that the -output file does not go into the same directory as the input -file. Otherwise, \fBxmlwf\fR will delete the -input file before it generates the output file (just like running -cat < file > file in most shells). - -Two structurally equivalent XML documents have a byte-for-byte -identical canonical XML representation. -Note that ignorable white space is considered significant and -is treated equivalently to data. -More on canonical XML can be found at -http://www.jclark.com/xml/canonxml.html . -.TP -\fB-e encoding\fR -Specifies the character encoding for the document, overriding -any document encoding declaration. \fBxmlwf\fR -supports four built-in encodings: -US-ASCII, -UTF-8, -UTF-16, and -ISO-8859-1. -Also see the \fB-w\fR option. -.TP -\fB-m\fR -Outputs some strange sort of XML file that completely -describes the input file, including character positions. -Requires \fB-d\fR to specify an output file. -.TP -\fB-n\fR -Turns on namespace processing. (describe namespaces) -\fB-c\fR disables namespaces. -.TP -\fB-p\fR -Tells xmlwf to process external DTDs and parameter -entities. - -Normally \fBxmlwf\fR never parses parameter -entities. \fB-p\fR tells it to always parse them. -\fB-p\fR implies \fB-x\fR. -.TP -\fB-r\fR -Normally \fBxmlwf\fR memory-maps the XML file -before parsing; this can result in faster parsing on many -platforms. -\fB-r\fR turns off memory-mapping and uses normal file -IO calls instead. -Of course, memory-mapping is automatically turned off -when reading from standard input. - -Use of memory-mapping can cause some platforms to report -substantially higher memory usage for -\fBxmlwf\fR, but this appears to be a matter of -the operating system reporting memory in a strange way; there is -not a leak in \fBxmlwf\fR. -.TP -\fB-s\fR -Prints an error if the document is not standalone. -A document is standalone if it has no external subset and no -references to parameter entities. -.TP -\fB-t\fR -Turns on timings. This tells Expat to parse the entire file, -but not perform any processing. -This gives a fairly accurate idea of the raw speed of Expat itself -without client overhead. -\fB-t\fR turns off most of the output options -(\fB-d\fR, \fB-m\fR, \fB-c\fR, -\&...). -.TP -\fB-v\fR -Prints the version of the Expat library being used, including some -information on the compile-time configuration of the library, and -then exits. -.TP -\fB-w\fR -Enables support for Windows code pages. -Normally, \fBxmlwf\fR will throw an error if it -runs across an encoding that it is not equipped to handle itself. With -\fB-w\fR, xmlwf will try to use a Windows code -page. See also \fB-e\fR. -.TP -\fB-x\fR -Turns on parsing external entities. - -Non-validating parsers are not required to resolve external -entities, or even expand entities at all. -Expat always expands internal entities (?), -but external entity parsing must be enabled explicitly. - -External entities are simply entities that obtain their -data from outside the XML file currently being parsed. - -This is an example of an internal entity: - -.nf - -.fi - -And here are some examples of external entities: - -.nf - (parsed) - (unparsed) -.fi -.TP -\fB--\fR -(Two hyphens.) -Terminates the list of options. This is only needed if a filename -starts with a hyphen. For example: - -.nf -xmlwf -- -myfile.xml -.fi - -will run \fBxmlwf\fR on the file -\fI-myfile.xml\fR. -.PP -Older versions of \fBxmlwf\fR do not support -reading from standard input. -.SH "OUTPUT" -.PP -If an input file is not well-formed, -\fBxmlwf\fR prints a single line describing -the problem to standard output. If a file is well formed, -\fBxmlwf\fR outputs nothing. -Note that the result code is \fBnot\fR set. -.SH "BUGS" -.PP -According to the W3C standard, an XML file without a -declaration at the beginning is not considered well-formed. -However, \fBxmlwf\fR allows this to pass. -.PP -\fBxmlwf\fR returns a 0 - noerr result, -even if the file is not well-formed. There is no good way for -a program to use \fBxmlwf\fR to quickly -check a file -- it must parse \fBxmlwf\fR's -standard output. -.PP -The errors should go to standard error, not standard output. -.PP -There should be a way to get \fB-d\fR to send its -output to standard output rather than forcing the user to send -it to a file. -.PP -I have no idea why anyone would want to use the -\fB-d\fR, \fB-c\fR, and -\fB-m\fR options. If someone could explain it to -me, I'd like to add this information to this manpage. -.SH "ALTERNATIVES" -.PP -Here are some XML validators on the web: - -.nf -http://www.hcrc.ed.ac.uk/~richard/xml-check.html -http://www.stg.brown.edu/service/xmlvalid/ -http://www.scripting.com/frontier5/xml/code/xmlValidator.html -http://www.xml.com/pub/a/tools/ruwf/check.html -.fi -.SH "SEE ALSO" -.PP - -.nf -The Expat home page: http://www.libexpat.org/ -The W3 XML specification: http://www.w3.org/TR/REC-xml -.fi -.SH "AUTHOR" -.PP -This manual page was written by Scott Bronson for -the Debian GNU/Linux system (but may be used by others). Permission is -granted to copy, distribute and/or modify this document under -the terms of the GNU Free Documentation -License, Version 1.1. diff --git a/lib-src/expat/doc/xmlwf.sgml b/lib-src/expat/doc/xmlwf.sgml deleted file mode 100644 index 313cfbcb2..000000000 --- a/lib-src/expat/doc/xmlwf.sgml +++ /dev/null @@ -1,468 +0,0 @@ - manpage.1'. You may view - the manual page with: `docbook-to-man manpage.sgml | nroff -man | - less'. A typical entry in a Makefile or Makefile.am is: - -manpage.1: manpage.sgml - docbook-to-man $< > $@ - --> - - - Scott"> - Bronson"> - - December 5, 2001"> - - 1"> - bronson@rinspin.com"> - - XMLWF"> - - - Debian GNU/Linux"> - GNU"> -]> - - - -
- &dhemail; -
- - &dhfirstname; - &dhsurname; - - - 2001 - &dhusername; - - &dhdate; -
- - &dhucpackage; - - &dhsection; - - - &dhpackage; - - Determines if an XML document is well-formed - - - - &dhpackage; - - - - - - - - - - - - - - - - - - file ... - - - - - DESCRIPTION - - - &dhpackage; uses the Expat library to - determine if an XML document is well-formed. It is - non-validating. - - - - If you do not specify any files on the command-line, and you - have a recent version of &dhpackage;, the - input file will be read from standard input. - - - - - - WELL-FORMED DOCUMENTS - - - A well-formed document must adhere to the - following rules: - - - - - The file begins with an XML declaration. For instance, - <?xml version="1.0" standalone="yes"?>. - NOTE: - &dhpackage; does not currently - check for a valid XML declaration. - - - Every start tag is either empty (<tag/>) - or has a corresponding end tag. - - - There is exactly one root element. This element must contain - all other elements in the document. Only comments, white - space, and processing instructions may come after the close - of the root element. - - - All elements nest properly. - - - All attribute values are enclosed in quotes (either single - or double). - - - - - If the document has a DTD, and it strictly complies with that - DTD, then the document is also considered valid. - &dhpackage; is a non-validating parser -- - it does not check the DTD. However, it does support - external entities (see the option). - - - - - OPTIONS - - -When an option includes an argument, you may specify the argument either -separately (" output") or concatenated with the -option ("output"). &dhpackage; -supports both. - - - - - - - - - If the input file is well-formed and &dhpackage; - doesn't encounter any errors, the input file is simply copied to - the output directory unchanged. - This implies no namespaces (turns off ) and - requires to specify an output file. - - - - - - - - - Specifies a directory to contain transformed - representations of the input files. - By default, outputs a canonical representation - (described below). - You can select different output formats using - and . - - - The output filenames will - be exactly the same as the input filenames or "STDIN" if the input is - coming from standard input. Therefore, you must be careful that the - output file does not go into the same directory as the input - file. Otherwise, &dhpackage; will delete the - input file before it generates the output file (just like running - cat < file > file in most shells). - - - Two structurally equivalent XML documents have a byte-for-byte - identical canonical XML representation. - Note that ignorable white space is considered significant and - is treated equivalently to data. - More on canonical XML can be found at - http://www.jclark.com/xml/canonxml.html . - - - - - - - - - Specifies the character encoding for the document, overriding - any document encoding declaration. &dhpackage; - supports four built-in encodings: - US-ASCII, - UTF-8, - UTF-16, and - ISO-8859-1. - Also see the option. - - - - - - - - - Outputs some strange sort of XML file that completely - describes the the input file, including character postitions. - Requires to specify an output file. - - - - - - - - - Turns on namespace processing. (describe namespaces) - disables namespaces. - - - - - - - - - Tells xmlwf to process external DTDs and parameter - entities. - - - Normally &dhpackage; never parses parameter - entities. tells it to always parse them. - implies . - - - - - - - - - Normally &dhpackage; memory-maps the XML file - before parsing; this can result in faster parsing on many - platforms. - turns off memory-mapping and uses normal file - IO calls instead. - Of course, memory-mapping is automatically turned off - when reading from standard input. - - - Use of memory-mapping can cause some platforms to report - substantially higher memory usage for - &dhpackage;, but this appears to be a matter of - the operating system reporting memory in a strange way; there is - not a leak in &dhpackage;. - - - - - - - - - Prints an error if the document is not standalone. - A document is standalone if it has no external subset and no - references to parameter entities. - - - - - - - - - Turns on timings. This tells Expat to parse the entire file, - but not perform any processing. - This gives a fairly accurate idea of the raw speed of Expat itself - without client overhead. - turns off most of the output options - (, , , - ...). - - - - - - - - - Prints the version of the Expat library being used, including some - information on the compile-time configuration of the library, and - then exits. - - - - - - - - - Enables support for Windows code pages. - Normally, &dhpackage; will throw an error if it - runs across an encoding that it is not equipped to handle itself. With - , &dhpackage; will try to use a Windows code - page. See also . - - - - - - - - - Turns on parsing external entities. - - - Non-validating parsers are not required to resolve external - entities, or even expand entities at all. - Expat always expands internal entities (?), - but external entity parsing must be enabled explicitly. - - - External entities are simply entities that obtain their - data from outside the XML file currently being parsed. - - - This is an example of an internal entity: - -<!ENTITY vers '1.0.2'> - - - - And here are some examples of external entities: - - -<!ENTITY header SYSTEM "header-&vers;.xml"> (parsed) -<!ENTITY logo SYSTEM "logo.png" PNG> (unparsed) - - - - - - - - - - - (Two hyphens.) - Terminates the list of options. This is only needed if a filename - starts with a hyphen. For example: - - -&dhpackage; -- -myfile.xml - - - will run &dhpackage; on the file - -myfile.xml. - - - - - - - Older versions of &dhpackage; do not support - reading from standard input. - - - - - OUTPUT - - If an input file is not well-formed, - &dhpackage; prints a single line describing - the problem to standard output. If a file is well formed, - &dhpackage; outputs nothing. - Note that the result code is not set. - - - - - BUGS - - &dhpackage; returns a 0 - noerr result, - even if the file is not well-formed. There is no good way for - a program to use &dhpackage; to quickly - check a file -- it must parse &dhpackage;'s - standard output. - - - The errors should go to standard error, not standard output. - - - There should be a way to get to send its - output to standard output rather than forcing the user to send - it to a file. - - - I have no idea why anyone would want to use the - , , and - options. If someone could explain it to - me, I'd like to add this information to this manpage. - - - - - ALTERNATIVES - - Here are some XML validators on the web: - - -http://www.hcrc.ed.ac.uk/~richard/xml-check.html -http://www.stg.brown.edu/service/xmlvalid/ -http://www.scripting.com/frontier5/xml/code/xmlValidator.html -http://www.xml.com/pub/a/tools/ruwf/check.html - - - - - - - SEE ALSO - - - -The Expat home page: http://www.libexpat.org/ -The W3 XML specification: http://www.w3.org/TR/REC-xml - - - - - - - AUTHOR - - This manual page was written by &dhusername; &dhemail; for - the &debian; system (but may be used by others). Permission is - granted to copy, distribute and/or modify this document under - the terms of the GNU Free Documentation - License, Version 1.1. - - -
- - diff --git a/lib-src/expat/examples/elements.c b/lib-src/expat/examples/elements.c deleted file mode 100644 index 6b8f85501..000000000 --- a/lib-src/expat/examples/elements.c +++ /dev/null @@ -1,65 +0,0 @@ -/* This is simple demonstration of how to use expat. This program - reads an XML document from standard input and writes a line with - the name of each element to standard output indenting child - elements by one tab stop more than their parent element. - It must be used with Expat compiled for UTF-8 output. -*/ - -#include -#include "expat.h" - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -#ifdef XML_LARGE_SIZE -#if defined(XML_USE_MSC_EXTENSIONS) && _MSC_VER < 1400 -#define XML_FMT_INT_MOD "I64" -#else -#define XML_FMT_INT_MOD "ll" -#endif -#else -#define XML_FMT_INT_MOD "l" -#endif - -static void XMLCALL -startElement(void *userData, const char *name, const char **atts) -{ - int i; - int *depthPtr = (int *)userData; - for (i = 0; i < *depthPtr; i++) - putchar('\t'); - puts(name); - *depthPtr += 1; -} - -static void XMLCALL -endElement(void *userData, const char *name) -{ - int *depthPtr = (int *)userData; - *depthPtr -= 1; -} - -int -main(int argc, char *argv[]) -{ - char buf[BUFSIZ]; - XML_Parser parser = XML_ParserCreate(NULL); - int done; - int depth = 0; - XML_SetUserData(parser, &depth); - XML_SetElementHandler(parser, startElement, endElement); - do { - int len = (int)fread(buf, 1, sizeof(buf), stdin); - done = len < sizeof(buf); - if (XML_Parse(parser, buf, len, done) == XML_STATUS_ERROR) { - fprintf(stderr, - "%s at line %" XML_FMT_INT_MOD "u\n", - XML_ErrorString(XML_GetErrorCode(parser)), - XML_GetCurrentLineNumber(parser)); - return 1; - } - } while (!done); - XML_ParserFree(parser); - return 0; -} diff --git a/lib-src/expat/examples/elements.dsp b/lib-src/expat/examples/elements.dsp deleted file mode 100644 index 5e750c4f6..000000000 --- a/lib-src/expat/examples/elements.dsp +++ /dev/null @@ -1,103 +0,0 @@ -# Microsoft Developer Studio Project File - Name="elements" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=elements - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "elements.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "elements.mak" CFG="elements - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "elements - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "elements - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "elements - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release-elements" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\lib" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /D "XML_STATIC" /FD /c -# SUBTRACT CPP /X /YX -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /machine:I386 -# ADD LINK32 libexpatMT.lib /nologo /subsystem:console /pdb:none /machine:I386 /libpath:"..\win32\bin\Release" /out:"..\win32\bin\Release\elements.exe" - -!ELSEIF "$(CFG)" == "elements - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug-elements" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /I "..\lib" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /D "XML_STATIC" /FR /FD /GZ /c -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 libexpatMT.lib /nologo /subsystem:console /pdb:none /debug /machine:I386 /libpath:"..\win32\bin\Debug" /out:"..\win32\bin\Debug\elements.exe" - -!ENDIF - -# Begin Target - -# Name "elements - Win32 Release" -# Name "elements - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\elements.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/lib-src/expat/examples/outline.c b/lib-src/expat/examples/outline.c deleted file mode 100644 index 3a3c83855..000000000 --- a/lib-src/expat/examples/outline.c +++ /dev/null @@ -1,106 +0,0 @@ -/***************************************************************** - * outline.c - * - * Copyright 1999, Clark Cooper - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the license contained in the - * COPYING file that comes with the expat distribution. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, - * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. - * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY - * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - * - * Read an XML document from standard input and print an element - * outline on standard output. - * Must be used with Expat compiled for UTF-8 output. - */ - - -#include -#include - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -#ifdef XML_LARGE_SIZE -#if defined(XML_USE_MSC_EXTENSIONS) && _MSC_VER < 1400 -#define XML_FMT_INT_MOD "I64" -#else -#define XML_FMT_INT_MOD "ll" -#endif -#else -#define XML_FMT_INT_MOD "l" -#endif - -#define BUFFSIZE 8192 - -char Buff[BUFFSIZE]; - -int Depth; - -static void XMLCALL -start(void *data, const char *el, const char **attr) -{ - int i; - - for (i = 0; i < Depth; i++) - printf(" "); - - printf("%s", el); - - for (i = 0; attr[i]; i += 2) { - printf(" %s='%s'", attr[i], attr[i + 1]); - } - - printf("\n"); - Depth++; -} - -static void XMLCALL -end(void *data, const char *el) -{ - Depth--; -} - -int -main(int argc, char *argv[]) -{ - XML_Parser p = XML_ParserCreate(NULL); - if (! p) { - fprintf(stderr, "Couldn't allocate memory for parser\n"); - exit(-1); - } - - XML_SetElementHandler(p, start, end); - - for (;;) { - int done; - int len; - - len = (int)fread(Buff, 1, BUFFSIZE, stdin); - if (ferror(stdin)) { - fprintf(stderr, "Read error\n"); - exit(-1); - } - done = feof(stdin); - - if (XML_Parse(p, Buff, len, done) == XML_STATUS_ERROR) { - fprintf(stderr, "Parse error at line %" XML_FMT_INT_MOD "u:\n%s\n", - XML_GetCurrentLineNumber(p), - XML_ErrorString(XML_GetErrorCode(p))); - exit(-1); - } - - if (done) - break; - } - XML_ParserFree(p); - return 0; -} diff --git a/lib-src/expat/examples/outline.dsp b/lib-src/expat/examples/outline.dsp deleted file mode 100644 index acadf4bd7..000000000 --- a/lib-src/expat/examples/outline.dsp +++ /dev/null @@ -1,103 +0,0 @@ -# Microsoft Developer Studio Project File - Name="outline" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=outline - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "outline.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "outline.mak" CFG="outline - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "outline - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "outline - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "outline - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release-outline" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\lib" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c -# SUBTRACT CPP /X /YX -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /machine:I386 -# ADD LINK32 libexpat.lib /nologo /subsystem:console /pdb:none /machine:I386 /libpath:"..\win32\bin\Release" /out:"..\win32\bin\Release\outline.exe" - -!ELSEIF "$(CFG)" == "outline - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug-outline" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\lib" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 libexpat.lib /nologo /subsystem:console /pdb:none /debug /machine:I386 /libpath:"..\win32\bin\Debug" /out:"..\win32\bin\Debug\outline.exe" - -!ENDIF - -# Begin Target - -# Name "outline - Win32 Release" -# Name "outline - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\outline.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/lib-src/expat/expat.dsw b/lib-src/expat/expat.dsw deleted file mode 100755 index 2d62eec5f..000000000 --- a/lib-src/expat/expat.dsw +++ /dev/null @@ -1,110 +0,0 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "elements"=.\examples\elements.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name expat_static - End Project Dependency -}}} - -############################################################################### - -Project: "expat"=.\lib\expat.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Project: "expat_static"=.\lib\expat_static.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Project: "expatw"=.\lib\expatw.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Project: "expatw_static"=.\lib\expatw_static.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Project: "outline"=.\examples\outline.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name expat - End Project Dependency -}}} - -############################################################################### - -Project: "xmlwf"=.\xmlwf\xmlwf.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name expat - End Project Dependency -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - diff --git a/lib-src/expat/expat.pc.in b/lib-src/expat/expat.pc.in deleted file mode 100644 index 5207e3e1b..000000000 --- a/lib-src/expat/expat.pc.in +++ /dev/null @@ -1,11 +0,0 @@ -prefix=@prefix@ -exec_prefix=@exec_prefix@ -libdir=@libdir@ -includedir=@includedir@ - -Name: expat -Version: @PACKAGE_VERSION@ -Description: expat XML parser -URL: http://www.libexpat.org -Libs: -L${libdir} -lexpat -Cflags: -I${includedir} diff --git a/lib-src/expat/expat_config.h.cmake b/lib-src/expat/expat_config.h.cmake deleted file mode 100755 index 25d79a6d5..000000000 --- a/lib-src/expat/expat_config.h.cmake +++ /dev/null @@ -1,91 +0,0 @@ -/* expat_config.h.in. Generated from configure.in by autoheader. */ - -/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */ -#cmakedefine BYTEORDER @BYTEORDER@ - -/* Define to 1 if you have the `bcopy' function. */ -#cmakedefine HAVE_BCOPY - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_DLFCN_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_FCNTL_H - -/* Define to 1 if you have the `getpagesize' function. */ -#cmakedefine HAVE_GETPAGESIZE - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_INTTYPES_H - -/* Define to 1 if you have the `memmove' function. */ -#cmakedefine HAVE_MEMMOVE - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_MEMORY_H - -/* Define to 1 if you have a working `mmap' system call. */ -#cmakedefine HAVE_MMAP - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STDLIB_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_STRING_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_UNISTD_H - -/* Define to the address where bug reports for this package should be sent. */ -#cmakedefine PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#cmakedefine PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#cmakedefine PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#cmakedefine PACKAGE_TARNAME - -/* Define to the version of this package. */ -#cmakedefine PACKAGE_VERSION - -/* Define to 1 if you have the ANSI C header files. */ -#cmakedefine STDC_HEADERS - -/* whether byteorder is bigendian */ -#cmakedefine WORDS_BIGENDIAN - -/* Define to specify how much context to retain around the current parse - point. */ -#cmakedefine XML_CONTEXT_BYTES @XML_CONTEXT_BYTES@ - -/* Define to make parameter entity parsing functionality available. */ -#cmakedefine XML_DTD - -/* Define to make XML Namespaces functionality available. */ -#cmakedefine XML_NS - -/* Define to __FUNCTION__ or "" if `__func__' does not conform to ANSI C. */ -#ifdef _MSC_VER -# define __func__ __FUNCTION__ -#endif - -/* Define to `long' if does not define. */ -#cmakedefine off_t @OFF_T@ - -/* Define to `unsigned' if does not define. */ -#cmakedefine size_t @SIZE_T@ diff --git a/lib-src/expat/expat_config.h.in b/lib-src/expat/expat_config.h.in deleted file mode 100644 index 8c6e51409..000000000 --- a/lib-src/expat/expat_config.h.in +++ /dev/null @@ -1,102 +0,0 @@ -/* expat_config.h.in. Generated from configure.in by autoheader. */ - -/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */ -#undef BYTEORDER - -/* Define to 1 if you have the `bcopy' function. */ -#undef HAVE_BCOPY - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_FCNTL_H - -/* Define to 1 if you have the `getpagesize' function. */ -#undef HAVE_GETPAGESIZE - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* Define to 1 if you have the `memmove' function. */ -#undef HAVE_MEMMOVE - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have a working `mmap' system call. */ -#undef HAVE_MMAP - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_PARAM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#undef LT_OBJDIR - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* whether byteorder is bigendian */ -#undef WORDS_BIGENDIAN - -/* Define to specify how much context to retain around the current parse - point. */ -#undef XML_CONTEXT_BYTES - -/* Define to make parameter entity parsing functionality available. */ -#undef XML_DTD - -/* Define to make XML Namespaces functionality available. */ -#undef XML_NS - -/* Define to __FUNCTION__ or "" if `__func__' does not conform to ANSI C. */ -#undef __func__ - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define to `long int' if does not define. */ -#undef off_t - -/* Define to `unsigned int' if does not define. */ -#undef size_t diff --git a/lib-src/expat/lib/Makefile.MPW b/lib-src/expat/lib/Makefile.MPW deleted file mode 100644 index 046af0051..000000000 --- a/lib-src/expat/lib/Makefile.MPW +++ /dev/null @@ -1,206 +0,0 @@ -# File: Makefile.MPW -# Targets: All, Dynamic, Static (and Clean, Clean-All) -# Created: Tuesday, July 02, 2002 -# -# MPW Makefile for building expat under the "classic" (i.e. pre-X) Mac OS -# Copyright © 2002 Daryle Walker -# Portions Copyright © 2002 Thomas Wegner -# See the COPYING file for distribution information -# -# Description: -# This Makefile lets you build static, dynamic (i.e. shared) and stub -# versions of the expat library as well as the elements.c and outline.c -# examples (built as tools for MPW). This is for PPC only; it should be -# no problem to build a 68K version of the expat library, though. -# -# Usage: -# Buildprogram All -# or Buildprogram Dynamic -# or Buildprogram Static -# -# Note: You first have to rename this file to "Makefile", or the Buildprogram -# commando will not recognize it. -# - -MAKEFILE = Makefile -¥MondoBuild¥ = {MAKEFILE} # Make blank to avoid rebuilds when makefile is modified - -ObjDir = : -SrcDir = : -HdrDir = : - -ToolDir = ::examples: - -Includes = -i {HdrDir} - -Sym-PPC = -sym off - -Defines = -d MACOS_CLASSIC - -PPCCOptions = {Includes} {Sym-PPC} -w 35 {Defines} - -FragName = libexpat - - -### Source Files ### - -SrcFiles = ¶ - "{SrcDir}xmlparse.c" ¶ - "{SrcDir}xmlrole.c" ¶ - "{SrcDir}xmltok.c" - -ToolSrcFiles = ¶ - "{ToolDir}elements.c" ¶ - "{ToolDir}outline.c" - - -### Object Files ### - -ObjFiles-PPC = ¶ - "{ObjDir}xmlparse.c.o" ¶ - "{ObjDir}xmlrole.c.o" ¶ - "{ObjDir}xmltok.c.o" - -ElementToolObjFile = "{ObjDir}elements.c.o" - -OutlineToolObjFile = "{ObjDir}outline.c.o" - - -### Libraries ### - -StLibFiles-PPC = ¶ - "{PPCLibraries}StdCRuntime.o" ¶ - "{PPCLibraries}PPCCRuntime.o" ¶ - "{PPCLibraries}PPCToolLibs.o" - -ShLibFiles-PPC = ¶ - "{SharedLibraries}InterfaceLib" ¶ - "{SharedLibraries}StdCLib" ¶ - "{SharedLibraries}MathLib" - -LibFiles-PPC = ¶ - {StLibFiles-PPC} ¶ - {ShLibFiles-PPC} - - -### Special Files ### - -ExportFile = "{ObjDir}{FragName}.exp" - -StLibFile = "{ObjDir}{FragName}.MrC.o" - -ShLibFile = "{ObjDir}{FragName}" - -StubFile = "{ObjDir}{FragName}.stub" - -ElementsTool = "{ToolDir}elements" - -OutlineTool = "{ToolDir}outline" - - -### Default Rules ### - -.c.o Ä .c {¥MondoBuild¥} - {PPCC} {depDir}{default}.c -o {targDir}{default}.c.o {PPCCOptions} - - -### Build Rules ### - -All Ä Dynamic {ElementsTool} {OutlineTool} - -Static Ä {StLibFile} - -Dynamic Ä Static {ShLibFile} {StubFile} - -{StLibFile} ÄÄ {ObjFiles-PPC} {StLibFiles-PPC} {¥MondoBuild¥} - PPCLink ¶ - -o {Targ} ¶ - {ObjFiles-PPC} ¶ - {StLibFiles-PPC} ¶ - {Sym-PPC} ¶ - -mf -d ¶ - -t 'XCOF' ¶ - -c 'MPS ' ¶ - -xm l - -{ShLibFile} ÄÄ {StLibFile} {ShLibFiles-PPC} {ExportFile} {¥MondoBuild¥} - PPCLink ¶ - -o {Targ} ¶ - {StLibFile} ¶ - {ShLibFiles-PPC} ¶ - {Sym-PPC} ¶ - -@export {ExportFile} ¶ - -fragname {FragName} ¶ - -mf -d ¶ - -t 'shlb' ¶ - -c '????' ¶ - -xm s - -{StubFile} ÄÄ {ShLibFile} {¥MondoBuild¥} - shlb2stub -o {Targ} {ShLibFile} - -{ElementsTool} ÄÄ {ElementToolObjFile} {StubFile} {LibFiles-PPC} {¥MondoBuild¥} - PPCLink ¶ - -o {Targ} ¶ - {ElementToolObjFile} ¶ - {StLibFile} ¶ - {LibFiles-PPC} ¶ - {Sym-PPC} ¶ - -mf -d ¶ - -t 'MPST' ¶ - -c 'MPS ' - -{OutlineTool} ÄÄ {OutlineToolObjFile} {StubFile} {LibFiles-PPC} {¥MondoBuild¥} - PPCLink ¶ - -o {Targ} ¶ - {OutlineToolObjFile} ¶ - {StLibFile} ¶ - {LibFiles-PPC} ¶ - {Sym-PPC} ¶ - -mf -d ¶ - -t 'MPST' ¶ - -c 'MPS ' - - -### Special Rules ### - -{ExportFile} ÄÄ "{HdrDir}expat.h" {¥MondoBuild¥} - StreamEdit -d ¶ - -e "/¥('XMLPARSEAPI('Å') ')Ç0,1È'XML_'([A-Za-z0-9_]+)¨1'('/ Print 'XML_' ¨1" ¶ - "{HdrDir}expat.h" > {Targ} - - -### Required Dependencies ### - -"{ObjDir}xmlparse.c.o" Ä "{SrcDir}xmlparse.c" -"{ObjDir}xmlrole.c.o" Ä "{SrcDir}xmlrole.c" -"{ObjDir}xmltok.c.o" Ä "{SrcDir}xmltok.c" - -"{ObjDir}elements.c.o" Ä "{ToolDir}elements.c" -"{ObjDir}outline.c.o" Ä "{ToolDir}outline.c" - - -### Optional Dependencies ### -### Build this target to clean out generated intermediate files. ### - -Clean Ä - Delete {ObjFiles-PPC} {ExportFile} {ElementToolObjFile} {OutlineToolObjFile} - -### Build this target to clean out all generated files. ### - -Clean-All Ä Clean - Delete {StLibFile} {ShLibFile} {StubFile} {ElementsTool} {OutlineTool} - -### Build this target to generate "include file" dependencies. ### - -Dependencies Ä $OutOfDate - MakeDepend ¶ - -append {MAKEFILE} ¶ - -ignore "{CIncludes}" ¶ - -objdir "{ObjDir}" ¶ - -objext .o ¶ - {Defines} ¶ - {Includes} ¶ - {SrcFiles} - - diff --git a/lib-src/expat/lib/amigaconfig.h b/lib-src/expat/lib/amigaconfig.h deleted file mode 100644 index 86c611504..000000000 --- a/lib-src/expat/lib/amigaconfig.h +++ /dev/null @@ -1,32 +0,0 @@ -#ifndef AMIGACONFIG_H -#define AMIGACONFIG_H - -/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */ -#define BYTEORDER 4321 - -/* Define to 1 if you have the `bcopy' function. */ -#define HAVE_BCOPY 1 - -/* Define to 1 if you have the header file. */ -#undef HAVE_CHECK_H - -/* Define to 1 if you have the `memmove' function. */ -#define HAVE_MEMMOVE 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - -/* whether byteorder is bigendian */ -#define WORDS_BIGENDIAN - -/* Define to specify how much context to retain around the current parse - point. */ -#define XML_CONTEXT_BYTES 1024 - -/* Define to make parameter entity parsing functionality available. */ -#define XML_DTD - -/* Define to make XML Namespaces functionality available. */ -#define XML_NS - -#endif /* AMIGACONFIG_H */ diff --git a/lib-src/expat/lib/ascii.h b/lib-src/expat/lib/ascii.h deleted file mode 100644 index d10530b09..000000000 --- a/lib-src/expat/lib/ascii.h +++ /dev/null @@ -1,92 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#define ASCII_A 0x41 -#define ASCII_B 0x42 -#define ASCII_C 0x43 -#define ASCII_D 0x44 -#define ASCII_E 0x45 -#define ASCII_F 0x46 -#define ASCII_G 0x47 -#define ASCII_H 0x48 -#define ASCII_I 0x49 -#define ASCII_J 0x4A -#define ASCII_K 0x4B -#define ASCII_L 0x4C -#define ASCII_M 0x4D -#define ASCII_N 0x4E -#define ASCII_O 0x4F -#define ASCII_P 0x50 -#define ASCII_Q 0x51 -#define ASCII_R 0x52 -#define ASCII_S 0x53 -#define ASCII_T 0x54 -#define ASCII_U 0x55 -#define ASCII_V 0x56 -#define ASCII_W 0x57 -#define ASCII_X 0x58 -#define ASCII_Y 0x59 -#define ASCII_Z 0x5A - -#define ASCII_a 0x61 -#define ASCII_b 0x62 -#define ASCII_c 0x63 -#define ASCII_d 0x64 -#define ASCII_e 0x65 -#define ASCII_f 0x66 -#define ASCII_g 0x67 -#define ASCII_h 0x68 -#define ASCII_i 0x69 -#define ASCII_j 0x6A -#define ASCII_k 0x6B -#define ASCII_l 0x6C -#define ASCII_m 0x6D -#define ASCII_n 0x6E -#define ASCII_o 0x6F -#define ASCII_p 0x70 -#define ASCII_q 0x71 -#define ASCII_r 0x72 -#define ASCII_s 0x73 -#define ASCII_t 0x74 -#define ASCII_u 0x75 -#define ASCII_v 0x76 -#define ASCII_w 0x77 -#define ASCII_x 0x78 -#define ASCII_y 0x79 -#define ASCII_z 0x7A - -#define ASCII_0 0x30 -#define ASCII_1 0x31 -#define ASCII_2 0x32 -#define ASCII_3 0x33 -#define ASCII_4 0x34 -#define ASCII_5 0x35 -#define ASCII_6 0x36 -#define ASCII_7 0x37 -#define ASCII_8 0x38 -#define ASCII_9 0x39 - -#define ASCII_TAB 0x09 -#define ASCII_SPACE 0x20 -#define ASCII_EXCL 0x21 -#define ASCII_QUOT 0x22 -#define ASCII_AMP 0x26 -#define ASCII_APOS 0x27 -#define ASCII_MINUS 0x2D -#define ASCII_PERIOD 0x2E -#define ASCII_COLON 0x3A -#define ASCII_SEMI 0x3B -#define ASCII_LT 0x3C -#define ASCII_EQUALS 0x3D -#define ASCII_GT 0x3E -#define ASCII_LSQB 0x5B -#define ASCII_RSQB 0x5D -#define ASCII_UNDERSCORE 0x5F -#define ASCII_LPAREN 0x28 -#define ASCII_RPAREN 0x29 -#define ASCII_FF 0x0C -#define ASCII_SLASH 0x2F -#define ASCII_HASH 0x23 -#define ASCII_PIPE 0x7C -#define ASCII_COMMA 0x2C diff --git a/lib-src/expat/lib/asciitab.h b/lib-src/expat/lib/asciitab.h deleted file mode 100644 index 79a15c28c..000000000 --- a/lib-src/expat/lib/asciitab.h +++ /dev/null @@ -1,36 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -/* 0x00 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x04 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x08 */ BT_NONXML, BT_S, BT_LF, BT_NONXML, -/* 0x0C */ BT_NONXML, BT_CR, BT_NONXML, BT_NONXML, -/* 0x10 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x14 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x18 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x1C */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x20 */ BT_S, BT_EXCL, BT_QUOT, BT_NUM, -/* 0x24 */ BT_OTHER, BT_PERCNT, BT_AMP, BT_APOS, -/* 0x28 */ BT_LPAR, BT_RPAR, BT_AST, BT_PLUS, -/* 0x2C */ BT_COMMA, BT_MINUS, BT_NAME, BT_SOL, -/* 0x30 */ BT_DIGIT, BT_DIGIT, BT_DIGIT, BT_DIGIT, -/* 0x34 */ BT_DIGIT, BT_DIGIT, BT_DIGIT, BT_DIGIT, -/* 0x38 */ BT_DIGIT, BT_DIGIT, BT_COLON, BT_SEMI, -/* 0x3C */ BT_LT, BT_EQUALS, BT_GT, BT_QUEST, -/* 0x40 */ BT_OTHER, BT_HEX, BT_HEX, BT_HEX, -/* 0x44 */ BT_HEX, BT_HEX, BT_HEX, BT_NMSTRT, -/* 0x48 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x4C */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x50 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x54 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x58 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_LSQB, -/* 0x5C */ BT_OTHER, BT_RSQB, BT_OTHER, BT_NMSTRT, -/* 0x60 */ BT_OTHER, BT_HEX, BT_HEX, BT_HEX, -/* 0x64 */ BT_HEX, BT_HEX, BT_HEX, BT_NMSTRT, -/* 0x68 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x6C */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x70 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x74 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x78 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_OTHER, -/* 0x7C */ BT_VERBAR, BT_OTHER, BT_OTHER, BT_OTHER, diff --git a/lib-src/expat/lib/expat.dsp b/lib-src/expat/lib/expat.dsp deleted file mode 100644 index bf728da05..000000000 --- a/lib-src/expat/lib/expat.dsp +++ /dev/null @@ -1,185 +0,0 @@ -# Microsoft Developer Studio Project File - Name="expat" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 - -CFG=expat - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "expat.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "expat.mak" CFG="expat - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "expat - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE "expat - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "expat - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXPAT_EXPORTS" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILED_FROM_DSP" /FD /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /dll /machine:I386 -# ADD LINK32 /nologo /dll /pdb:none /machine:I386 /out:"..\win32\bin\Release\libexpat.dll" - -!ELSEIF "$(CFG)" == "expat - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXPAT_EXPORTS" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /D "_DEBUG" /D "COMPILED_FROM_DSP" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /FR /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 /nologo /dll /pdb:none /debug /machine:I386 /out:"..\win32\bin\Debug\libexpat.dll" - -!ENDIF - -# Begin Target - -# Name "expat - Win32 Release" -# Name "expat - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\libexpat.def -# End Source File -# Begin Source File - -SOURCE=.\xmlparse.c - -!IF "$(CFG)" == "expat - Win32 Release" - -!ELSEIF "$(CFG)" == "expat - Win32 Debug" - -# ADD CPP /GX- /Od - -!ENDIF - -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_ns.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\ascii.h -# End Source File -# Begin Source File - -SOURCE=.\asciitab.h -# End Source File -# Begin Source File - -SOURCE=.\expat.h -# End Source File -# Begin Source File - -SOURCE=.\expat_external.h -# End Source File -# Begin Source File - -SOURCE=.\iasciitab.h -# End Source File -# Begin Source File - -SOURCE=.\internal.h -# End Source File -# Begin Source File - -SOURCE=.\latin1tab.h -# End Source File -# Begin Source File - -SOURCE=.\nametab.h -# End Source File -# Begin Source File - -SOURCE=.\utf8tab.h -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/lib-src/expat/lib/expat.h b/lib-src/expat/lib/expat.h deleted file mode 100644 index 9a21680be..000000000 --- a/lib-src/expat/lib/expat.h +++ /dev/null @@ -1,1047 +0,0 @@ -/* Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#ifndef Expat_INCLUDED -#define Expat_INCLUDED 1 - -#ifdef __VMS -/* 0 1 2 3 0 1 2 3 - 1234567890123456789012345678901 1234567890123456789012345678901 */ -#define XML_SetProcessingInstructionHandler XML_SetProcessingInstrHandler -#define XML_SetUnparsedEntityDeclHandler XML_SetUnparsedEntDeclHandler -#define XML_SetStartNamespaceDeclHandler XML_SetStartNamespcDeclHandler -#define XML_SetExternalEntityRefHandlerArg XML_SetExternalEntRefHandlerArg -#endif - -#include -#include "expat_external.h" - -#ifdef __cplusplus -extern "C" { -#endif - -struct XML_ParserStruct; -typedef struct XML_ParserStruct *XML_Parser; - -/* Should this be defined using stdbool.h when C99 is available? */ -typedef unsigned char XML_Bool; -#define XML_TRUE ((XML_Bool) 1) -#define XML_FALSE ((XML_Bool) 0) - -/* The XML_Status enum gives the possible return values for several - API functions. The preprocessor #defines are included so this - stanza can be added to code that still needs to support older - versions of Expat 1.95.x: - - #ifndef XML_STATUS_OK - #define XML_STATUS_OK 1 - #define XML_STATUS_ERROR 0 - #endif - - Otherwise, the #define hackery is quite ugly and would have been - dropped. -*/ -enum XML_Status { - XML_STATUS_ERROR = 0, -#define XML_STATUS_ERROR XML_STATUS_ERROR - XML_STATUS_OK = 1, -#define XML_STATUS_OK XML_STATUS_OK - XML_STATUS_SUSPENDED = 2 -#define XML_STATUS_SUSPENDED XML_STATUS_SUSPENDED -}; - -enum XML_Error { - XML_ERROR_NONE, - XML_ERROR_NO_MEMORY, - XML_ERROR_SYNTAX, - XML_ERROR_NO_ELEMENTS, - XML_ERROR_INVALID_TOKEN, - XML_ERROR_UNCLOSED_TOKEN, - XML_ERROR_PARTIAL_CHAR, - XML_ERROR_TAG_MISMATCH, - XML_ERROR_DUPLICATE_ATTRIBUTE, - XML_ERROR_JUNK_AFTER_DOC_ELEMENT, - XML_ERROR_PARAM_ENTITY_REF, - XML_ERROR_UNDEFINED_ENTITY, - XML_ERROR_RECURSIVE_ENTITY_REF, - XML_ERROR_ASYNC_ENTITY, - XML_ERROR_BAD_CHAR_REF, - XML_ERROR_BINARY_ENTITY_REF, - XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF, - XML_ERROR_MISPLACED_XML_PI, - XML_ERROR_UNKNOWN_ENCODING, - XML_ERROR_INCORRECT_ENCODING, - XML_ERROR_UNCLOSED_CDATA_SECTION, - XML_ERROR_EXTERNAL_ENTITY_HANDLING, - XML_ERROR_NOT_STANDALONE, - XML_ERROR_UNEXPECTED_STATE, - XML_ERROR_ENTITY_DECLARED_IN_PE, - XML_ERROR_FEATURE_REQUIRES_XML_DTD, - XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING, - /* Added in 1.95.7. */ - XML_ERROR_UNBOUND_PREFIX, - /* Added in 1.95.8. */ - XML_ERROR_UNDECLARING_PREFIX, - XML_ERROR_INCOMPLETE_PE, - XML_ERROR_XML_DECL, - XML_ERROR_TEXT_DECL, - XML_ERROR_PUBLICID, - XML_ERROR_SUSPENDED, - XML_ERROR_NOT_SUSPENDED, - XML_ERROR_ABORTED, - XML_ERROR_FINISHED, - XML_ERROR_SUSPEND_PE, - /* Added in 2.0. */ - XML_ERROR_RESERVED_PREFIX_XML, - XML_ERROR_RESERVED_PREFIX_XMLNS, - XML_ERROR_RESERVED_NAMESPACE_URI -}; - -enum XML_Content_Type { - XML_CTYPE_EMPTY = 1, - XML_CTYPE_ANY, - XML_CTYPE_MIXED, - XML_CTYPE_NAME, - XML_CTYPE_CHOICE, - XML_CTYPE_SEQ -}; - -enum XML_Content_Quant { - XML_CQUANT_NONE, - XML_CQUANT_OPT, - XML_CQUANT_REP, - XML_CQUANT_PLUS -}; - -/* If type == XML_CTYPE_EMPTY or XML_CTYPE_ANY, then quant will be - XML_CQUANT_NONE, and the other fields will be zero or NULL. - If type == XML_CTYPE_MIXED, then quant will be NONE or REP and - numchildren will contain number of elements that may be mixed in - and children point to an array of XML_Content cells that will be - all of XML_CTYPE_NAME type with no quantification. - - If type == XML_CTYPE_NAME, then the name points to the name, and - the numchildren field will be zero and children will be NULL. The - quant fields indicates any quantifiers placed on the name. - - CHOICE and SEQ will have name NULL, the number of children in - numchildren and children will point, recursively, to an array - of XML_Content cells. - - The EMPTY, ANY, and MIXED types will only occur at top level. -*/ - -typedef struct XML_cp XML_Content; - -struct XML_cp { - enum XML_Content_Type type; - enum XML_Content_Quant quant; - XML_Char * name; - unsigned int numchildren; - XML_Content * children; -}; - - -/* This is called for an element declaration. See above for - description of the model argument. It's the caller's responsibility - to free model when finished with it. -*/ -typedef void (XMLCALL *XML_ElementDeclHandler) (void *userData, - const XML_Char *name, - XML_Content *model); - -XMLPARSEAPI(void) -XML_SetElementDeclHandler(XML_Parser parser, - XML_ElementDeclHandler eldecl); - -/* The Attlist declaration handler is called for *each* attribute. So - a single Attlist declaration with multiple attributes declared will - generate multiple calls to this handler. The "default" parameter - may be NULL in the case of the "#IMPLIED" or "#REQUIRED" - keyword. The "isrequired" parameter will be true and the default - value will be NULL in the case of "#REQUIRED". If "isrequired" is - true and default is non-NULL, then this is a "#FIXED" default. -*/ -typedef void (XMLCALL *XML_AttlistDeclHandler) ( - void *userData, - const XML_Char *elname, - const XML_Char *attname, - const XML_Char *att_type, - const XML_Char *dflt, - int isrequired); - -XMLPARSEAPI(void) -XML_SetAttlistDeclHandler(XML_Parser parser, - XML_AttlistDeclHandler attdecl); - -/* The XML declaration handler is called for *both* XML declarations - and text declarations. The way to distinguish is that the version - parameter will be NULL for text declarations. The encoding - parameter may be NULL for XML declarations. The standalone - parameter will be -1, 0, or 1 indicating respectively that there - was no standalone parameter in the declaration, that it was given - as no, or that it was given as yes. -*/ -typedef void (XMLCALL *XML_XmlDeclHandler) (void *userData, - const XML_Char *version, - const XML_Char *encoding, - int standalone); - -XMLPARSEAPI(void) -XML_SetXmlDeclHandler(XML_Parser parser, - XML_XmlDeclHandler xmldecl); - - -typedef struct { - void *(*malloc_fcn)(size_t size); - void *(*realloc_fcn)(void *ptr, size_t size); - void (*free_fcn)(void *ptr); -} XML_Memory_Handling_Suite; - -/* Constructs a new parser; encoding is the encoding specified by the - external protocol or NULL if there is none specified. -*/ -XMLPARSEAPI(XML_Parser) -XML_ParserCreate(const XML_Char *encoding); - -/* Constructs a new parser and namespace processor. Element type - names and attribute names that belong to a namespace will be - expanded; unprefixed attribute names are never expanded; unprefixed - element type names are expanded only if there is a default - namespace. The expanded name is the concatenation of the namespace - URI, the namespace separator character, and the local part of the - name. If the namespace separator is '\0' then the namespace URI - and the local part will be concatenated without any separator. - It is a programming error to use the separator '\0' with namespace - triplets (see XML_SetReturnNSTriplet). -*/ -XMLPARSEAPI(XML_Parser) -XML_ParserCreateNS(const XML_Char *encoding, XML_Char namespaceSeparator); - - -/* Constructs a new parser using the memory management suite referred to - by memsuite. If memsuite is NULL, then use the standard library memory - suite. If namespaceSeparator is non-NULL it creates a parser with - namespace processing as described above. The character pointed at - will serve as the namespace separator. - - All further memory operations used for the created parser will come from - the given suite. -*/ -XMLPARSEAPI(XML_Parser) -XML_ParserCreate_MM(const XML_Char *encoding, - const XML_Memory_Handling_Suite *memsuite, - const XML_Char *namespaceSeparator); - -/* Prepare a parser object to be re-used. This is particularly - valuable when memory allocation overhead is disproportionatly high, - such as when a large number of small documnents need to be parsed. - All handlers are cleared from the parser, except for the - unknownEncodingHandler. The parser's external state is re-initialized - except for the values of ns and ns_triplets. - - Added in Expat 1.95.3. -*/ -XMLPARSEAPI(XML_Bool) -XML_ParserReset(XML_Parser parser, const XML_Char *encoding); - -/* atts is array of name/value pairs, terminated by 0; - names and values are 0 terminated. -*/ -typedef void (XMLCALL *XML_StartElementHandler) (void *userData, - const XML_Char *name, - const XML_Char **atts); - -typedef void (XMLCALL *XML_EndElementHandler) (void *userData, - const XML_Char *name); - - -/* s is not 0 terminated. */ -typedef void (XMLCALL *XML_CharacterDataHandler) (void *userData, - const XML_Char *s, - int len); - -/* target and data are 0 terminated */ -typedef void (XMLCALL *XML_ProcessingInstructionHandler) ( - void *userData, - const XML_Char *target, - const XML_Char *data); - -/* data is 0 terminated */ -typedef void (XMLCALL *XML_CommentHandler) (void *userData, - const XML_Char *data); - -typedef void (XMLCALL *XML_StartCdataSectionHandler) (void *userData); -typedef void (XMLCALL *XML_EndCdataSectionHandler) (void *userData); - -/* This is called for any characters in the XML document for which - there is no applicable handler. This includes both characters that - are part of markup which is of a kind that is not reported - (comments, markup declarations), or characters that are part of a - construct which could be reported but for which no handler has been - supplied. The characters are passed exactly as they were in the XML - document except that they will be encoded in UTF-8 or UTF-16. - Line boundaries are not normalized. Note that a byte order mark - character is not passed to the default handler. There are no - guarantees about how characters are divided between calls to the - default handler: for example, a comment might be split between - multiple calls. -*/ -typedef void (XMLCALL *XML_DefaultHandler) (void *userData, - const XML_Char *s, - int len); - -/* This is called for the start of the DOCTYPE declaration, before - any DTD or internal subset is parsed. -*/ -typedef void (XMLCALL *XML_StartDoctypeDeclHandler) ( - void *userData, - const XML_Char *doctypeName, - const XML_Char *sysid, - const XML_Char *pubid, - int has_internal_subset); - -/* This is called for the start of the DOCTYPE declaration when the - closing > is encountered, but after processing any external - subset. -*/ -typedef void (XMLCALL *XML_EndDoctypeDeclHandler)(void *userData); - -/* This is called for entity declarations. The is_parameter_entity - argument will be non-zero if the entity is a parameter entity, zero - otherwise. - - For internal entities (), value will - be non-NULL and systemId, publicID, and notationName will be NULL. - The value string is NOT nul-terminated; the length is provided in - the value_length argument. Since it is legal to have zero-length - values, do not use this argument to test for internal entities. - - For external entities, value will be NULL and systemId will be - non-NULL. The publicId argument will be NULL unless a public - identifier was provided. The notationName argument will have a - non-NULL value only for unparsed entity declarations. - - Note that is_parameter_entity can't be changed to XML_Bool, since - that would break binary compatibility. -*/ -typedef void (XMLCALL *XML_EntityDeclHandler) ( - void *userData, - const XML_Char *entityName, - int is_parameter_entity, - const XML_Char *value, - int value_length, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName); - -XMLPARSEAPI(void) -XML_SetEntityDeclHandler(XML_Parser parser, - XML_EntityDeclHandler handler); - -/* OBSOLETE -- OBSOLETE -- OBSOLETE - This handler has been superceded by the EntityDeclHandler above. - It is provided here for backward compatibility. - - This is called for a declaration of an unparsed (NDATA) entity. - The base argument is whatever was set by XML_SetBase. The - entityName, systemId and notationName arguments will never be - NULL. The other arguments may be. -*/ -typedef void (XMLCALL *XML_UnparsedEntityDeclHandler) ( - void *userData, - const XML_Char *entityName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName); - -/* This is called for a declaration of notation. The base argument is - whatever was set by XML_SetBase. The notationName will never be - NULL. The other arguments can be. -*/ -typedef void (XMLCALL *XML_NotationDeclHandler) ( - void *userData, - const XML_Char *notationName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId); - -/* When namespace processing is enabled, these are called once for - each namespace declaration. The call to the start and end element - handlers occur between the calls to the start and end namespace - declaration handlers. For an xmlns attribute, prefix will be - NULL. For an xmlns="" attribute, uri will be NULL. -*/ -typedef void (XMLCALL *XML_StartNamespaceDeclHandler) ( - void *userData, - const XML_Char *prefix, - const XML_Char *uri); - -typedef void (XMLCALL *XML_EndNamespaceDeclHandler) ( - void *userData, - const XML_Char *prefix); - -/* This is called if the document is not standalone, that is, it has an - external subset or a reference to a parameter entity, but does not - have standalone="yes". If this handler returns XML_STATUS_ERROR, - then processing will not continue, and the parser will return a - XML_ERROR_NOT_STANDALONE error. - If parameter entity parsing is enabled, then in addition to the - conditions above this handler will only be called if the referenced - entity was actually read. -*/ -typedef int (XMLCALL *XML_NotStandaloneHandler) (void *userData); - -/* This is called for a reference to an external parsed general - entity. The referenced entity is not automatically parsed. The - application can parse it immediately or later using - XML_ExternalEntityParserCreate. - - The parser argument is the parser parsing the entity containing the - reference; it can be passed as the parser argument to - XML_ExternalEntityParserCreate. The systemId argument is the - system identifier as specified in the entity declaration; it will - not be NULL. - - The base argument is the system identifier that should be used as - the base for resolving systemId if systemId was relative; this is - set by XML_SetBase; it may be NULL. - - The publicId argument is the public identifier as specified in the - entity declaration, or NULL if none was specified; the whitespace - in the public identifier will have been normalized as required by - the XML spec. - - The context argument specifies the parsing context in the format - expected by the context argument to XML_ExternalEntityParserCreate; - context is valid only until the handler returns, so if the - referenced entity is to be parsed later, it must be copied. - context is NULL only when the entity is a parameter entity. - - The handler should return XML_STATUS_ERROR if processing should not - continue because of a fatal error in the handling of the external - entity. In this case the calling parser will return an - XML_ERROR_EXTERNAL_ENTITY_HANDLING error. - - Note that unlike other handlers the first argument is the parser, - not userData. -*/ -typedef int (XMLCALL *XML_ExternalEntityRefHandler) ( - XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId); - -/* This is called in two situations: - 1) An entity reference is encountered for which no declaration - has been read *and* this is not an error. - 2) An internal entity reference is read, but not expanded, because - XML_SetDefaultHandler has been called. - Note: skipped parameter entities in declarations and skipped general - entities in attribute values cannot be reported, because - the event would be out of sync with the reporting of the - declarations or attribute values -*/ -typedef void (XMLCALL *XML_SkippedEntityHandler) ( - void *userData, - const XML_Char *entityName, - int is_parameter_entity); - -/* This structure is filled in by the XML_UnknownEncodingHandler to - provide information to the parser about encodings that are unknown - to the parser. - - The map[b] member gives information about byte sequences whose - first byte is b. - - If map[b] is c where c is >= 0, then b by itself encodes the - Unicode scalar value c. - - If map[b] is -1, then the byte sequence is malformed. - - If map[b] is -n, where n >= 2, then b is the first byte of an - n-byte sequence that encodes a single Unicode scalar value. - - The data member will be passed as the first argument to the convert - function. - - The convert function is used to convert multibyte sequences; s will - point to a n-byte sequence where map[(unsigned char)*s] == -n. The - convert function must return the Unicode scalar value represented - by this byte sequence or -1 if the byte sequence is malformed. - - The convert function may be NULL if the encoding is a single-byte - encoding, that is if map[b] >= -1 for all bytes b. - - When the parser is finished with the encoding, then if release is - not NULL, it will call release passing it the data member; once - release has been called, the convert function will not be called - again. - - Expat places certain restrictions on the encodings that are supported - using this mechanism. - - 1. Every ASCII character that can appear in a well-formed XML document, - other than the characters - - $@\^`{}~ - - must be represented by a single byte, and that byte must be the - same byte that represents that character in ASCII. - - 2. No character may require more than 4 bytes to encode. - - 3. All characters encoded must have Unicode scalar values <= - 0xFFFF, (i.e., characters that would be encoded by surrogates in - UTF-16 are not allowed). Note that this restriction doesn't - apply to the built-in support for UTF-8 and UTF-16. - - 4. No Unicode character may be encoded by more than one distinct - sequence of bytes. -*/ -typedef struct { - int map[256]; - void *data; - int (XMLCALL *convert)(void *data, const char *s); - void (XMLCALL *release)(void *data); -} XML_Encoding; - -/* This is called for an encoding that is unknown to the parser. - - The encodingHandlerData argument is that which was passed as the - second argument to XML_SetUnknownEncodingHandler. - - The name argument gives the name of the encoding as specified in - the encoding declaration. - - If the callback can provide information about the encoding, it must - fill in the XML_Encoding structure, and return XML_STATUS_OK. - Otherwise it must return XML_STATUS_ERROR. - - If info does not describe a suitable encoding, then the parser will - return an XML_UNKNOWN_ENCODING error. -*/ -typedef int (XMLCALL *XML_UnknownEncodingHandler) ( - void *encodingHandlerData, - const XML_Char *name, - XML_Encoding *info); - -XMLPARSEAPI(void) -XML_SetElementHandler(XML_Parser parser, - XML_StartElementHandler start, - XML_EndElementHandler end); - -XMLPARSEAPI(void) -XML_SetStartElementHandler(XML_Parser parser, - XML_StartElementHandler handler); - -XMLPARSEAPI(void) -XML_SetEndElementHandler(XML_Parser parser, - XML_EndElementHandler handler); - -XMLPARSEAPI(void) -XML_SetCharacterDataHandler(XML_Parser parser, - XML_CharacterDataHandler handler); - -XMLPARSEAPI(void) -XML_SetProcessingInstructionHandler(XML_Parser parser, - XML_ProcessingInstructionHandler handler); -XMLPARSEAPI(void) -XML_SetCommentHandler(XML_Parser parser, - XML_CommentHandler handler); - -XMLPARSEAPI(void) -XML_SetCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start, - XML_EndCdataSectionHandler end); - -XMLPARSEAPI(void) -XML_SetStartCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start); - -XMLPARSEAPI(void) -XML_SetEndCdataSectionHandler(XML_Parser parser, - XML_EndCdataSectionHandler end); - -/* This sets the default handler and also inhibits expansion of - internal entities. These entity references will be passed to the - default handler, or to the skipped entity handler, if one is set. -*/ -XMLPARSEAPI(void) -XML_SetDefaultHandler(XML_Parser parser, - XML_DefaultHandler handler); - -/* This sets the default handler but does not inhibit expansion of - internal entities. The entity reference will not be passed to the - default handler. -*/ -XMLPARSEAPI(void) -XML_SetDefaultHandlerExpand(XML_Parser parser, - XML_DefaultHandler handler); - -XMLPARSEAPI(void) -XML_SetDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start, - XML_EndDoctypeDeclHandler end); - -XMLPARSEAPI(void) -XML_SetStartDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start); - -XMLPARSEAPI(void) -XML_SetEndDoctypeDeclHandler(XML_Parser parser, - XML_EndDoctypeDeclHandler end); - -XMLPARSEAPI(void) -XML_SetUnparsedEntityDeclHandler(XML_Parser parser, - XML_UnparsedEntityDeclHandler handler); - -XMLPARSEAPI(void) -XML_SetNotationDeclHandler(XML_Parser parser, - XML_NotationDeclHandler handler); - -XMLPARSEAPI(void) -XML_SetNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start, - XML_EndNamespaceDeclHandler end); - -XMLPARSEAPI(void) -XML_SetStartNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start); - -XMLPARSEAPI(void) -XML_SetEndNamespaceDeclHandler(XML_Parser parser, - XML_EndNamespaceDeclHandler end); - -XMLPARSEAPI(void) -XML_SetNotStandaloneHandler(XML_Parser parser, - XML_NotStandaloneHandler handler); - -XMLPARSEAPI(void) -XML_SetExternalEntityRefHandler(XML_Parser parser, - XML_ExternalEntityRefHandler handler); - -/* If a non-NULL value for arg is specified here, then it will be - passed as the first argument to the external entity ref handler - instead of the parser object. -*/ -XMLPARSEAPI(void) -XML_SetExternalEntityRefHandlerArg(XML_Parser parser, - void *arg); - -XMLPARSEAPI(void) -XML_SetSkippedEntityHandler(XML_Parser parser, - XML_SkippedEntityHandler handler); - -XMLPARSEAPI(void) -XML_SetUnknownEncodingHandler(XML_Parser parser, - XML_UnknownEncodingHandler handler, - void *encodingHandlerData); - -/* This can be called within a handler for a start element, end - element, processing instruction or character data. It causes the - corresponding markup to be passed to the default handler. -*/ -XMLPARSEAPI(void) -XML_DefaultCurrent(XML_Parser parser); - -/* If do_nst is non-zero, and namespace processing is in effect, and - a name has a prefix (i.e. an explicit namespace qualifier) then - that name is returned as a triplet in a single string separated by - the separator character specified when the parser was created: URI - + sep + local_name + sep + prefix. - - If do_nst is zero, then namespace information is returned in the - default manner (URI + sep + local_name) whether or not the name - has a prefix. - - Note: Calling XML_SetReturnNSTriplet after XML_Parse or - XML_ParseBuffer has no effect. -*/ - -XMLPARSEAPI(void) -XML_SetReturnNSTriplet(XML_Parser parser, int do_nst); - -/* This value is passed as the userData argument to callbacks. */ -XMLPARSEAPI(void) -XML_SetUserData(XML_Parser parser, void *userData); - -/* Returns the last value set by XML_SetUserData or NULL. */ -#define XML_GetUserData(parser) (*(void **)(parser)) - -/* This is equivalent to supplying an encoding argument to - XML_ParserCreate. On success XML_SetEncoding returns non-zero, - zero otherwise. - Note: Calling XML_SetEncoding after XML_Parse or XML_ParseBuffer - has no effect and returns XML_STATUS_ERROR. -*/ -XMLPARSEAPI(enum XML_Status) -XML_SetEncoding(XML_Parser parser, const XML_Char *encoding); - -/* If this function is called, then the parser will be passed as the - first argument to callbacks instead of userData. The userData will - still be accessible using XML_GetUserData. -*/ -XMLPARSEAPI(void) -XML_UseParserAsHandlerArg(XML_Parser parser); - -/* If useDTD == XML_TRUE is passed to this function, then the parser - will assume that there is an external subset, even if none is - specified in the document. In such a case the parser will call the - externalEntityRefHandler with a value of NULL for the systemId - argument (the publicId and context arguments will be NULL as well). - Note: For the purpose of checking WFC: Entity Declared, passing - useDTD == XML_TRUE will make the parser behave as if the document - had a DTD with an external subset. - Note: If this function is called, then this must be done before - the first call to XML_Parse or XML_ParseBuffer, since it will - have no effect after that. Returns - XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING. - Note: If the document does not have a DOCTYPE declaration at all, - then startDoctypeDeclHandler and endDoctypeDeclHandler will not - be called, despite an external subset being parsed. - Note: If XML_DTD is not defined when Expat is compiled, returns - XML_ERROR_FEATURE_REQUIRES_XML_DTD. -*/ -XMLPARSEAPI(enum XML_Error) -XML_UseForeignDTD(XML_Parser parser, XML_Bool useDTD); - - -/* Sets the base to be used for resolving relative URIs in system - identifiers in declarations. Resolving relative identifiers is - left to the application: this value will be passed through as the - base argument to the XML_ExternalEntityRefHandler, - XML_NotationDeclHandler and XML_UnparsedEntityDeclHandler. The base - argument will be copied. Returns XML_STATUS_ERROR if out of memory, - XML_STATUS_OK otherwise. -*/ -XMLPARSEAPI(enum XML_Status) -XML_SetBase(XML_Parser parser, const XML_Char *base); - -XMLPARSEAPI(const XML_Char *) -XML_GetBase(XML_Parser parser); - -/* Returns the number of the attribute/value pairs passed in last call - to the XML_StartElementHandler that were specified in the start-tag - rather than defaulted. Each attribute/value pair counts as 2; thus - this correspondds to an index into the atts array passed to the - XML_StartElementHandler. -*/ -XMLPARSEAPI(int) -XML_GetSpecifiedAttributeCount(XML_Parser parser); - -/* Returns the index of the ID attribute passed in the last call to - XML_StartElementHandler, or -1 if there is no ID attribute. Each - attribute/value pair counts as 2; thus this correspondds to an - index into the atts array passed to the XML_StartElementHandler. -*/ -XMLPARSEAPI(int) -XML_GetIdAttributeIndex(XML_Parser parser); - -#ifdef XML_ATTR_INFO -/* Source file byte offsets for the start and end of attribute names and values. - The value indices are exclusive of surrounding quotes; thus in a UTF-8 source - file an attribute value of "blah" will yield: - info->valueEnd - info->valueStart = 4 bytes. -*/ -typedef struct { - XML_Index nameStart; /* Offset to beginning of the attribute name. */ - XML_Index nameEnd; /* Offset after the attribute name's last byte. */ - XML_Index valueStart; /* Offset to beginning of the attribute value. */ - XML_Index valueEnd; /* Offset after the attribute value's last byte. */ -} XML_AttrInfo; - -/* Returns an array of XML_AttrInfo structures for the attribute/value pairs - passed in last call to the XML_StartElementHandler that were specified - in the start-tag rather than defaulted. Each attribute/value pair counts - as 1; thus the number of entries in the array is - XML_GetSpecifiedAttributeCount(parser) / 2. -*/ -XMLPARSEAPI(const XML_AttrInfo *) -XML_GetAttributeInfo(XML_Parser parser); -#endif - -/* Parses some input. Returns XML_STATUS_ERROR if a fatal error is - detected. The last call to XML_Parse must have isFinal true; len - may be zero for this call (or any other). - - Though the return values for these functions has always been - described as a Boolean value, the implementation, at least for the - 1.95.x series, has always returned exactly one of the XML_Status - values. -*/ -XMLPARSEAPI(enum XML_Status) -XML_Parse(XML_Parser parser, const char *s, int len, int isFinal); - -XMLPARSEAPI(void *) -XML_GetBuffer(XML_Parser parser, int len); - -XMLPARSEAPI(enum XML_Status) -XML_ParseBuffer(XML_Parser parser, int len, int isFinal); - -/* Stops parsing, causing XML_Parse() or XML_ParseBuffer() to return. - Must be called from within a call-back handler, except when aborting - (resumable = 0) an already suspended parser. Some call-backs may - still follow because they would otherwise get lost. Examples: - - endElementHandler() for empty elements when stopped in - startElementHandler(), - - endNameSpaceDeclHandler() when stopped in endElementHandler(), - and possibly others. - - Can be called from most handlers, including DTD related call-backs, - except when parsing an external parameter entity and resumable != 0. - Returns XML_STATUS_OK when successful, XML_STATUS_ERROR otherwise. - Possible error codes: - - XML_ERROR_SUSPENDED: when suspending an already suspended parser. - - XML_ERROR_FINISHED: when the parser has already finished. - - XML_ERROR_SUSPEND_PE: when suspending while parsing an external PE. - - When resumable != 0 (true) then parsing is suspended, that is, - XML_Parse() and XML_ParseBuffer() return XML_STATUS_SUSPENDED. - Otherwise, parsing is aborted, that is, XML_Parse() and XML_ParseBuffer() - return XML_STATUS_ERROR with error code XML_ERROR_ABORTED. - - *Note*: - This will be applied to the current parser instance only, that is, if - there is a parent parser then it will continue parsing when the - externalEntityRefHandler() returns. It is up to the implementation of - the externalEntityRefHandler() to call XML_StopParser() on the parent - parser (recursively), if one wants to stop parsing altogether. - - When suspended, parsing can be resumed by calling XML_ResumeParser(). -*/ -XMLPARSEAPI(enum XML_Status) -XML_StopParser(XML_Parser parser, XML_Bool resumable); - -/* Resumes parsing after it has been suspended with XML_StopParser(). - Must not be called from within a handler call-back. Returns same - status codes as XML_Parse() or XML_ParseBuffer(). - Additional error code XML_ERROR_NOT_SUSPENDED possible. - - *Note*: - This must be called on the most deeply nested child parser instance - first, and on its parent parser only after the child parser has finished, - to be applied recursively until the document entity's parser is restarted. - That is, the parent parser will not resume by itself and it is up to the - application to call XML_ResumeParser() on it at the appropriate moment. -*/ -XMLPARSEAPI(enum XML_Status) -XML_ResumeParser(XML_Parser parser); - -enum XML_Parsing { - XML_INITIALIZED, - XML_PARSING, - XML_FINISHED, - XML_SUSPENDED -}; - -typedef struct { - enum XML_Parsing parsing; - XML_Bool finalBuffer; -} XML_ParsingStatus; - -/* Returns status of parser with respect to being initialized, parsing, - finished, or suspended and processing the final buffer. - XXX XML_Parse() and XML_ParseBuffer() should return XML_ParsingStatus, - XXX with XML_FINISHED_OK or XML_FINISHED_ERROR replacing XML_FINISHED -*/ -XMLPARSEAPI(void) -XML_GetParsingStatus(XML_Parser parser, XML_ParsingStatus *status); - -/* Creates an XML_Parser object that can parse an external general - entity; context is a '\0'-terminated string specifying the parse - context; encoding is a '\0'-terminated string giving the name of - the externally specified encoding, or NULL if there is no - externally specified encoding. The context string consists of a - sequence of tokens separated by formfeeds (\f); a token consisting - of a name specifies that the general entity of the name is open; a - token of the form prefix=uri specifies the namespace for a - particular prefix; a token of the form =uri specifies the default - namespace. This can be called at any point after the first call to - an ExternalEntityRefHandler so longer as the parser has not yet - been freed. The new parser is completely independent and may - safely be used in a separate thread. The handlers and userData are - initialized from the parser argument. Returns NULL if out of memory. - Otherwise returns a new XML_Parser object. -*/ -XMLPARSEAPI(XML_Parser) -XML_ExternalEntityParserCreate(XML_Parser parser, - const XML_Char *context, - const XML_Char *encoding); - -enum XML_ParamEntityParsing { - XML_PARAM_ENTITY_PARSING_NEVER, - XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE, - XML_PARAM_ENTITY_PARSING_ALWAYS -}; - -/* Controls parsing of parameter entities (including the external DTD - subset). If parsing of parameter entities is enabled, then - references to external parameter entities (including the external - DTD subset) will be passed to the handler set with - XML_SetExternalEntityRefHandler. The context passed will be 0. - - Unlike external general entities, external parameter entities can - only be parsed synchronously. If the external parameter entity is - to be parsed, it must be parsed during the call to the external - entity ref handler: the complete sequence of - XML_ExternalEntityParserCreate, XML_Parse/XML_ParseBuffer and - XML_ParserFree calls must be made during this call. After - XML_ExternalEntityParserCreate has been called to create the parser - for the external parameter entity (context must be 0 for this - call), it is illegal to make any calls on the old parser until - XML_ParserFree has been called on the newly created parser. - If the library has been compiled without support for parameter - entity parsing (ie without XML_DTD being defined), then - XML_SetParamEntityParsing will return 0 if parsing of parameter - entities is requested; otherwise it will return non-zero. - Note: If XML_SetParamEntityParsing is called after XML_Parse or - XML_ParseBuffer, then it has no effect and will always return 0. -*/ -XMLPARSEAPI(int) -XML_SetParamEntityParsing(XML_Parser parser, - enum XML_ParamEntityParsing parsing); - -/* Sets the hash salt to use for internal hash calculations. - Helps in preventing DoS attacks based on predicting hash - function behavior. This must be called before parsing is started. - Returns 1 if successful, 0 when called after parsing has started. -*/ -XMLPARSEAPI(int) -XML_SetHashSalt(XML_Parser parser, - unsigned long hash_salt); - -/* If XML_Parse or XML_ParseBuffer have returned XML_STATUS_ERROR, then - XML_GetErrorCode returns information about the error. -*/ -XMLPARSEAPI(enum XML_Error) -XML_GetErrorCode(XML_Parser parser); - -/* These functions return information about the current parse - location. They may be called from any callback called to report - some parse event; in this case the location is the location of the - first of the sequence of characters that generated the event. When - called from callbacks generated by declarations in the document - prologue, the location identified isn't as neatly defined, but will - be within the relevant markup. When called outside of the callback - functions, the position indicated will be just past the last parse - event (regardless of whether there was an associated callback). - - They may also be called after returning from a call to XML_Parse - or XML_ParseBuffer. If the return value is XML_STATUS_ERROR then - the location is the location of the character at which the error - was detected; otherwise the location is the location of the last - parse event, as described above. -*/ -XMLPARSEAPI(XML_Size) XML_GetCurrentLineNumber(XML_Parser parser); -XMLPARSEAPI(XML_Size) XML_GetCurrentColumnNumber(XML_Parser parser); -XMLPARSEAPI(XML_Index) XML_GetCurrentByteIndex(XML_Parser parser); - -/* Return the number of bytes in the current event. - Returns 0 if the event is in an internal entity. -*/ -XMLPARSEAPI(int) -XML_GetCurrentByteCount(XML_Parser parser); - -/* If XML_CONTEXT_BYTES is defined, returns the input buffer, sets - the integer pointed to by offset to the offset within this buffer - of the current parse position, and sets the integer pointed to by size - to the size of this buffer (the number of input bytes). Otherwise - returns a NULL pointer. Also returns a NULL pointer if a parse isn't - active. - - NOTE: The character pointer returned should not be used outside - the handler that makes the call. -*/ -XMLPARSEAPI(const char *) -XML_GetInputContext(XML_Parser parser, - int *offset, - int *size); - -/* For backwards compatibility with previous versions. */ -#define XML_GetErrorLineNumber XML_GetCurrentLineNumber -#define XML_GetErrorColumnNumber XML_GetCurrentColumnNumber -#define XML_GetErrorByteIndex XML_GetCurrentByteIndex - -/* Frees the content model passed to the element declaration handler */ -XMLPARSEAPI(void) -XML_FreeContentModel(XML_Parser parser, XML_Content *model); - -/* Exposing the memory handling functions used in Expat */ -XMLPARSEAPI(void *) -XML_MemMalloc(XML_Parser parser, size_t size); - -XMLPARSEAPI(void *) -XML_MemRealloc(XML_Parser parser, void *ptr, size_t size); - -XMLPARSEAPI(void) -XML_MemFree(XML_Parser parser, void *ptr); - -/* Frees memory used by the parser. */ -XMLPARSEAPI(void) -XML_ParserFree(XML_Parser parser); - -/* Returns a string describing the error. */ -XMLPARSEAPI(const XML_LChar *) -XML_ErrorString(enum XML_Error code); - -/* Return a string containing the version number of this expat */ -XMLPARSEAPI(const XML_LChar *) -XML_ExpatVersion(void); - -typedef struct { - int major; - int minor; - int micro; -} XML_Expat_Version; - -/* Return an XML_Expat_Version structure containing numeric version - number information for this version of expat. -*/ -XMLPARSEAPI(XML_Expat_Version) -XML_ExpatVersionInfo(void); - -/* Added in Expat 1.95.5. */ -enum XML_FeatureEnum { - XML_FEATURE_END = 0, - XML_FEATURE_UNICODE, - XML_FEATURE_UNICODE_WCHAR_T, - XML_FEATURE_DTD, - XML_FEATURE_CONTEXT_BYTES, - XML_FEATURE_MIN_SIZE, - XML_FEATURE_SIZEOF_XML_CHAR, - XML_FEATURE_SIZEOF_XML_LCHAR, - XML_FEATURE_NS, - XML_FEATURE_LARGE_SIZE, - XML_FEATURE_ATTR_INFO - /* Additional features must be added to the end of this enum. */ -}; - -typedef struct { - enum XML_FeatureEnum feature; - const XML_LChar *name; - long int value; -} XML_Feature; - -XMLPARSEAPI(const XML_Feature *) -XML_GetFeatureList(void); - - -/* Expat follows the GNU/Linux convention of odd number minor version for - beta/development releases and even number minor version for stable - releases. Micro is bumped with each release, and set to 0 with each - change to major or minor version. -*/ -#define XML_MAJOR_VERSION 2 -#define XML_MINOR_VERSION 1 -#define XML_MICRO_VERSION 0 - -#ifdef __cplusplus -} -#endif - -#endif /* not Expat_INCLUDED */ diff --git a/lib-src/expat/lib/expat_external.h b/lib-src/expat/lib/expat_external.h deleted file mode 100644 index 2c03284ea..000000000 --- a/lib-src/expat/lib/expat_external.h +++ /dev/null @@ -1,115 +0,0 @@ -/* Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#ifndef Expat_External_INCLUDED -#define Expat_External_INCLUDED 1 - -/* External API definitions */ - -#if defined(_MSC_EXTENSIONS) && !defined(__BEOS__) && !defined(__CYGWIN__) -#define XML_USE_MSC_EXTENSIONS 1 -#endif - -/* Expat tries very hard to make the API boundary very specifically - defined. There are two macros defined to control this boundary; - each of these can be defined before including this header to - achieve some different behavior, but doing so it not recommended or - tested frequently. - - XMLCALL - The calling convention to use for all calls across the - "library boundary." This will default to cdecl, and - try really hard to tell the compiler that's what we - want. - - XMLIMPORT - Whatever magic is needed to note that a function is - to be imported from a dynamically loaded library - (.dll, .so, or .sl, depending on your platform). - - The XMLCALL macro was added in Expat 1.95.7. The only one which is - expected to be directly useful in client code is XMLCALL. - - Note that on at least some Unix versions, the Expat library must be - compiled with the cdecl calling convention as the default since - system headers may assume the cdecl convention. -*/ -#ifndef XMLCALL -#if defined(_MSC_VER) -#define XMLCALL __cdecl -#elif defined(__GNUC__) && defined(__i386) && !defined(__INTEL_COMPILER) -#define XMLCALL __attribute__((cdecl)) -#else -/* For any platform which uses this definition and supports more than - one calling convention, we need to extend this definition to - declare the convention used on that platform, if it's possible to - do so. - - If this is the case for your platform, please file a bug report - with information on how to identify your platform via the C - pre-processor and how to specify the same calling convention as the - platform's malloc() implementation. -*/ -#define XMLCALL -#endif -#endif /* not defined XMLCALL */ - - -#if !defined(XML_STATIC) && !defined(XMLIMPORT) -#ifndef XML_BUILDING_EXPAT -/* using Expat from an application */ - -#ifdef XML_USE_MSC_EXTENSIONS -#define XMLIMPORT __declspec(dllimport) -#endif - -#endif -#endif /* not defined XML_STATIC */ - - -/* If we didn't define it above, define it away: */ -#ifndef XMLIMPORT -#define XMLIMPORT -#endif - - -#define XMLPARSEAPI(type) XMLIMPORT type XMLCALL - -#ifdef __cplusplus -extern "C" { -#endif - -#ifdef XML_UNICODE_WCHAR_T -#define XML_UNICODE -#endif - -#ifdef XML_UNICODE /* Information is UTF-16 encoded. */ -#ifdef XML_UNICODE_WCHAR_T -typedef wchar_t XML_Char; -typedef wchar_t XML_LChar; -#else -typedef unsigned short XML_Char; -typedef char XML_LChar; -#endif /* XML_UNICODE_WCHAR_T */ -#else /* Information is UTF-8 encoded. */ -typedef char XML_Char; -typedef char XML_LChar; -#endif /* XML_UNICODE */ - -#ifdef XML_LARGE_SIZE /* Use large integers for file/stream positions. */ -#if defined(XML_USE_MSC_EXTENSIONS) && _MSC_VER < 1400 -typedef __int64 XML_Index; -typedef unsigned __int64 XML_Size; -#else -typedef long long XML_Index; -typedef unsigned long long XML_Size; -#endif -#else -typedef long XML_Index; -typedef unsigned long XML_Size; -#endif /* XML_LARGE_SIZE */ - -#ifdef __cplusplus -} -#endif - -#endif /* not Expat_External_INCLUDED */ diff --git a/lib-src/expat/lib/expat_static.dsp b/lib-src/expat/lib/expat_static.dsp deleted file mode 100644 index 180f0dc6c..000000000 --- a/lib-src/expat/lib/expat_static.dsp +++ /dev/null @@ -1,162 +0,0 @@ -# Microsoft Developer Studio Project File - Name="expat_static" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Static Library" 0x0104 - -CFG=expat_static - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "expat_static.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "expat_static.mak" CFG="expat_static - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "expat_static - Win32 Release" (based on "Win32 (x86) Static Library") -!MESSAGE "expat_static - Win32 Debug" (based on "Win32 (x86) Static Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "expat_static - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "expat_static___Win32_Release" -# PROP BASE Intermediate_Dir "expat_static___Win32_Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release_static" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "_WINDOWS" /D "NDEBUG" /D "_MBCS" /D "_LIB" /D "COMPILED_FROM_DSP" /FD /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x1009 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo /out:"..\win32\bin\Release\libexpatMT.lib" - -!ELSEIF "$(CFG)" == "expat_static - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "expat_static___Win32_Debug" -# PROP BASE Intermediate_Dir "expat_static___Win32_Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug_static" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "COMPILED_FROM_DSP" /D "_MBCS" /D "_LIB" /FR /FD /GZ /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x1009 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo /out:"..\win32\bin\Debug\libexpatMT.lib" - -!ENDIF - -# Begin Target - -# Name "expat_static - Win32 Release" -# Name "expat_static - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\xmlparse.c -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_ns.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\ascii.h -# End Source File -# Begin Source File - -SOURCE=.\asciitab.h -# End Source File -# Begin Source File - -SOURCE=.\expat.h -# End Source File -# Begin Source File - -SOURCE=.\expat_external.h -# End Source File -# Begin Source File - -SOURCE=.\iasciitab.h -# End Source File -# Begin Source File - -SOURCE=.\internal.h -# End Source File -# Begin Source File - -SOURCE=.\latin1tab.h -# End Source File -# Begin Source File - -SOURCE=.\nametab.h -# End Source File -# Begin Source File - -SOURCE=.\utf8tab.h -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.h -# End Source File -# End Group -# End Target -# End Project diff --git a/lib-src/expat/lib/expatw.dsp b/lib-src/expat/lib/expatw.dsp deleted file mode 100644 index b91a117cc..000000000 --- a/lib-src/expat/lib/expatw.dsp +++ /dev/null @@ -1,185 +0,0 @@ -# Microsoft Developer Studio Project File - Name="expatw" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 - -CFG=expatw - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "expatw.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "expatw.mak" CFG="expatw - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "expatw - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE "expatw - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "expatw - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release-w" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXPAT_EXPORTS" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /D "NDEBUG" /D "COMPILED_FROM_DSP" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XML_UNICODE_WCHAR_T" /FD /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /dll /machine:I386 -# ADD LINK32 /nologo /dll /pdb:none /machine:I386 /out:"..\win32\bin\Release\libexpatw.dll" - -!ELSEIF "$(CFG)" == "expatw - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug-w" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXPAT_EXPORTS" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /D "_DEBUG" /D "COMPILED_FROM_DSP" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XML_UNICODE_WCHAR_T" /FR /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 /nologo /dll /pdb:none /debug /machine:I386 /out:"..\win32\bin\Debug\libexpatw.dll" - -!ENDIF - -# Begin Target - -# Name "expatw - Win32 Release" -# Name "expatw - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\libexpatw.def -# End Source File -# Begin Source File - -SOURCE=.\xmlparse.c - -!IF "$(CFG)" == "expatw - Win32 Release" - -!ELSEIF "$(CFG)" == "expatw - Win32 Debug" - -# ADD CPP /GX- /Od - -!ENDIF - -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_ns.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\ascii.h -# End Source File -# Begin Source File - -SOURCE=.\asciitab.h -# End Source File -# Begin Source File - -SOURCE=.\expat.h -# End Source File -# Begin Source File - -SOURCE=.\expat_external.h -# End Source File -# Begin Source File - -SOURCE=.\iasciitab.h -# End Source File -# Begin Source File - -SOURCE=.\internal.h -# End Source File -# Begin Source File - -SOURCE=.\latin1tab.h -# End Source File -# Begin Source File - -SOURCE=.\nametab.h -# End Source File -# Begin Source File - -SOURCE=.\utf8tab.h -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/lib-src/expat/lib/expatw_static.dsp b/lib-src/expat/lib/expatw_static.dsp deleted file mode 100644 index d28632cf4..000000000 --- a/lib-src/expat/lib/expatw_static.dsp +++ /dev/null @@ -1,162 +0,0 @@ -# Microsoft Developer Studio Project File - Name="expatw_static" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Static Library" 0x0104 - -CFG=expatw_static - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "expatw_static.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "expatw_static.mak" CFG="expatw_static - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "expatw_static - Win32 Release" (based on "Win32 (x86) Static Library") -!MESSAGE "expatw_static - Win32 Debug" (based on "Win32 (x86) Static Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "expatw_static - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "expatw_static___Win32_Release" -# PROP BASE Intermediate_Dir "expatw_static___Win32_Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release-w_static" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "_WINDOWS" /D "NDEBUG" /D "_MBCS" /D "_LIB" /D "COMPILED_FROM_DSP" /D "XML_UNICODE_WCHAR_T" /FD /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x1009 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo /out:"..\win32\bin\Release\libexpatwMT.lib" - -!ELSEIF "$(CFG)" == "expatw_static - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "expatw_static___Win32_Debug" -# PROP BASE Intermediate_Dir "expatw_static___Win32_Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug-w_static" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_LIB" /D "COMPILED_FROM_DSP" /D "XML_UNICODE_WCHAR_T" /FR /FD /GZ /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x1009 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo /out:"..\win32\bin\Debug\libexpatwMT.lib" - -!ENDIF - -# Begin Target - -# Name "expatw_static - Win32 Release" -# Name "expatw_static - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\xmlparse.c -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.c -# End Source File -# Begin Source File - -SOURCE=.\xmltok_ns.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\ascii.h -# End Source File -# Begin Source File - -SOURCE=.\asciitab.h -# End Source File -# Begin Source File - -SOURCE=.\expat.h -# End Source File -# Begin Source File - -SOURCE=.\expat_external.h -# End Source File -# Begin Source File - -SOURCE=.\iasciitab.h -# End Source File -# Begin Source File - -SOURCE=.\internal.h -# End Source File -# Begin Source File - -SOURCE=.\latin1tab.h -# End Source File -# Begin Source File - -SOURCE=.\nametab.h -# End Source File -# Begin Source File - -SOURCE=.\utf8tab.h -# End Source File -# Begin Source File - -SOURCE=.\xmlrole.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok.h -# End Source File -# Begin Source File - -SOURCE=.\xmltok_impl.h -# End Source File -# End Group -# End Target -# End Project diff --git a/lib-src/expat/lib/iasciitab.h b/lib-src/expat/lib/iasciitab.h deleted file mode 100644 index 24a1d5ccc..000000000 --- a/lib-src/expat/lib/iasciitab.h +++ /dev/null @@ -1,37 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -/* Like asciitab.h, except that 0xD has code BT_S rather than BT_CR */ -/* 0x00 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x04 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x08 */ BT_NONXML, BT_S, BT_LF, BT_NONXML, -/* 0x0C */ BT_NONXML, BT_S, BT_NONXML, BT_NONXML, -/* 0x10 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x14 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x18 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x1C */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0x20 */ BT_S, BT_EXCL, BT_QUOT, BT_NUM, -/* 0x24 */ BT_OTHER, BT_PERCNT, BT_AMP, BT_APOS, -/* 0x28 */ BT_LPAR, BT_RPAR, BT_AST, BT_PLUS, -/* 0x2C */ BT_COMMA, BT_MINUS, BT_NAME, BT_SOL, -/* 0x30 */ BT_DIGIT, BT_DIGIT, BT_DIGIT, BT_DIGIT, -/* 0x34 */ BT_DIGIT, BT_DIGIT, BT_DIGIT, BT_DIGIT, -/* 0x38 */ BT_DIGIT, BT_DIGIT, BT_COLON, BT_SEMI, -/* 0x3C */ BT_LT, BT_EQUALS, BT_GT, BT_QUEST, -/* 0x40 */ BT_OTHER, BT_HEX, BT_HEX, BT_HEX, -/* 0x44 */ BT_HEX, BT_HEX, BT_HEX, BT_NMSTRT, -/* 0x48 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x4C */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x50 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x54 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x58 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_LSQB, -/* 0x5C */ BT_OTHER, BT_RSQB, BT_OTHER, BT_NMSTRT, -/* 0x60 */ BT_OTHER, BT_HEX, BT_HEX, BT_HEX, -/* 0x64 */ BT_HEX, BT_HEX, BT_HEX, BT_NMSTRT, -/* 0x68 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x6C */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x70 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x74 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0x78 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_OTHER, -/* 0x7C */ BT_VERBAR, BT_OTHER, BT_OTHER, BT_OTHER, diff --git a/lib-src/expat/lib/internal.h b/lib-src/expat/lib/internal.h deleted file mode 100644 index dd5454831..000000000 --- a/lib-src/expat/lib/internal.h +++ /dev/null @@ -1,73 +0,0 @@ -/* internal.h - - Internal definitions used by Expat. This is not needed to compile - client code. - - The following calling convention macros are defined for frequently - called functions: - - FASTCALL - Used for those internal functions that have a simple - body and a low number of arguments and local variables. - - PTRCALL - Used for functions called though function pointers. - - PTRFASTCALL - Like PTRCALL, but for low number of arguments. - - inline - Used for selected internal functions for which inlining - may improve performance on some platforms. - - Note: Use of these macros is based on judgement, not hard rules, - and therefore subject to change. -*/ - -#if defined(__GNUC__) && defined(__i386__) && !defined(__MINGW32__) -/* We'll use this version by default only where we know it helps. - - regparm() generates warnings on Solaris boxes. See SF bug #692878. - - Instability reported with egcs on a RedHat Linux 7.3. - Let's comment out: - #define FASTCALL __attribute__((stdcall, regparm(3))) - and let's try this: -*/ -#define FASTCALL __attribute__((regparm(3))) -#define PTRFASTCALL __attribute__((regparm(3))) -#endif - -/* Using __fastcall seems to have an unexpected negative effect under - MS VC++, especially for function pointers, so we won't use it for - now on that platform. It may be reconsidered for a future release - if it can be made more effective. - Likely reason: __fastcall on Windows is like stdcall, therefore - the compiler cannot perform stack optimizations for call clusters. -*/ - -/* Make sure all of these are defined if they aren't already. */ - -#ifndef FASTCALL -#define FASTCALL -#endif - -#ifndef PTRCALL -#define PTRCALL -#endif - -#ifndef PTRFASTCALL -#define PTRFASTCALL -#endif - -#ifndef XML_MIN_SIZE -#if !defined(__cplusplus) && !defined(inline) -#ifdef __GNUC__ -#define inline __inline -#endif /* __GNUC__ */ -#endif -#endif /* XML_MIN_SIZE */ - -#ifdef __cplusplus -#define inline inline -#else -#ifndef inline -#define inline -#endif -#endif diff --git a/lib-src/expat/lib/latin1tab.h b/lib-src/expat/lib/latin1tab.h deleted file mode 100644 index 53c25d76b..000000000 --- a/lib-src/expat/lib/latin1tab.h +++ /dev/null @@ -1,36 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -/* 0x80 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x84 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x88 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x8C */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x90 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x94 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x98 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0x9C */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xA0 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xA4 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xA8 */ BT_OTHER, BT_OTHER, BT_NMSTRT, BT_OTHER, -/* 0xAC */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xB0 */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xB4 */ BT_OTHER, BT_NMSTRT, BT_OTHER, BT_NAME, -/* 0xB8 */ BT_OTHER, BT_OTHER, BT_NMSTRT, BT_OTHER, -/* 0xBC */ BT_OTHER, BT_OTHER, BT_OTHER, BT_OTHER, -/* 0xC0 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xC4 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xC8 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xCC */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xD0 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xD4 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_OTHER, -/* 0xD8 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xDC */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xE0 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xE4 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xE8 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xEC */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xF0 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xF4 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_OTHER, -/* 0xF8 */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, -/* 0xFC */ BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, BT_NMSTRT, diff --git a/lib-src/expat/lib/libexpat.def b/lib-src/expat/lib/libexpat.def deleted file mode 100644 index 3920bbcf9..000000000 --- a/lib-src/expat/lib/libexpat.def +++ /dev/null @@ -1,73 +0,0 @@ -; DEF file for MS VC++ - -LIBRARY -EXPORTS - XML_DefaultCurrent @1 - XML_ErrorString @2 - XML_ExpatVersion @3 - XML_ExpatVersionInfo @4 - XML_ExternalEntityParserCreate @5 - XML_GetBase @6 - XML_GetBuffer @7 - XML_GetCurrentByteCount @8 - XML_GetCurrentByteIndex @9 - XML_GetCurrentColumnNumber @10 - XML_GetCurrentLineNumber @11 - XML_GetErrorCode @12 - XML_GetIdAttributeIndex @13 - XML_GetInputContext @14 - XML_GetSpecifiedAttributeCount @15 - XML_Parse @16 - XML_ParseBuffer @17 - XML_ParserCreate @18 - XML_ParserCreateNS @19 - XML_ParserCreate_MM @20 - XML_ParserFree @21 - XML_SetAttlistDeclHandler @22 - XML_SetBase @23 - XML_SetCdataSectionHandler @24 - XML_SetCharacterDataHandler @25 - XML_SetCommentHandler @26 - XML_SetDefaultHandler @27 - XML_SetDefaultHandlerExpand @28 - XML_SetDoctypeDeclHandler @29 - XML_SetElementDeclHandler @30 - XML_SetElementHandler @31 - XML_SetEncoding @32 - XML_SetEndCdataSectionHandler @33 - XML_SetEndDoctypeDeclHandler @34 - XML_SetEndElementHandler @35 - XML_SetEndNamespaceDeclHandler @36 - XML_SetEntityDeclHandler @37 - XML_SetExternalEntityRefHandler @38 - XML_SetExternalEntityRefHandlerArg @39 - XML_SetNamespaceDeclHandler @40 - XML_SetNotStandaloneHandler @41 - XML_SetNotationDeclHandler @42 - XML_SetParamEntityParsing @43 - XML_SetProcessingInstructionHandler @44 - XML_SetReturnNSTriplet @45 - XML_SetStartCdataSectionHandler @46 - XML_SetStartDoctypeDeclHandler @47 - XML_SetStartElementHandler @48 - XML_SetStartNamespaceDeclHandler @49 - XML_SetUnknownEncodingHandler @50 - XML_SetUnparsedEntityDeclHandler @51 - XML_SetUserData @52 - XML_SetXmlDeclHandler @53 - XML_UseParserAsHandlerArg @54 -; added with version 1.95.3 - XML_ParserReset @55 - XML_SetSkippedEntityHandler @56 -; added with version 1.95.5 - XML_GetFeatureList @57 - XML_UseForeignDTD @58 -; added with version 1.95.6 - XML_FreeContentModel @59 - XML_MemMalloc @60 - XML_MemRealloc @61 - XML_MemFree @62 -; added with version 1.95.8 - XML_StopParser @63 - XML_ResumeParser @64 - XML_GetParsingStatus @65 diff --git a/lib-src/expat/lib/libexpatw.def b/lib-src/expat/lib/libexpatw.def deleted file mode 100644 index 3920bbcf9..000000000 --- a/lib-src/expat/lib/libexpatw.def +++ /dev/null @@ -1,73 +0,0 @@ -; DEF file for MS VC++ - -LIBRARY -EXPORTS - XML_DefaultCurrent @1 - XML_ErrorString @2 - XML_ExpatVersion @3 - XML_ExpatVersionInfo @4 - XML_ExternalEntityParserCreate @5 - XML_GetBase @6 - XML_GetBuffer @7 - XML_GetCurrentByteCount @8 - XML_GetCurrentByteIndex @9 - XML_GetCurrentColumnNumber @10 - XML_GetCurrentLineNumber @11 - XML_GetErrorCode @12 - XML_GetIdAttributeIndex @13 - XML_GetInputContext @14 - XML_GetSpecifiedAttributeCount @15 - XML_Parse @16 - XML_ParseBuffer @17 - XML_ParserCreate @18 - XML_ParserCreateNS @19 - XML_ParserCreate_MM @20 - XML_ParserFree @21 - XML_SetAttlistDeclHandler @22 - XML_SetBase @23 - XML_SetCdataSectionHandler @24 - XML_SetCharacterDataHandler @25 - XML_SetCommentHandler @26 - XML_SetDefaultHandler @27 - XML_SetDefaultHandlerExpand @28 - XML_SetDoctypeDeclHandler @29 - XML_SetElementDeclHandler @30 - XML_SetElementHandler @31 - XML_SetEncoding @32 - XML_SetEndCdataSectionHandler @33 - XML_SetEndDoctypeDeclHandler @34 - XML_SetEndElementHandler @35 - XML_SetEndNamespaceDeclHandler @36 - XML_SetEntityDeclHandler @37 - XML_SetExternalEntityRefHandler @38 - XML_SetExternalEntityRefHandlerArg @39 - XML_SetNamespaceDeclHandler @40 - XML_SetNotStandaloneHandler @41 - XML_SetNotationDeclHandler @42 - XML_SetParamEntityParsing @43 - XML_SetProcessingInstructionHandler @44 - XML_SetReturnNSTriplet @45 - XML_SetStartCdataSectionHandler @46 - XML_SetStartDoctypeDeclHandler @47 - XML_SetStartElementHandler @48 - XML_SetStartNamespaceDeclHandler @49 - XML_SetUnknownEncodingHandler @50 - XML_SetUnparsedEntityDeclHandler @51 - XML_SetUserData @52 - XML_SetXmlDeclHandler @53 - XML_UseParserAsHandlerArg @54 -; added with version 1.95.3 - XML_ParserReset @55 - XML_SetSkippedEntityHandler @56 -; added with version 1.95.5 - XML_GetFeatureList @57 - XML_UseForeignDTD @58 -; added with version 1.95.6 - XML_FreeContentModel @59 - XML_MemMalloc @60 - XML_MemRealloc @61 - XML_MemFree @62 -; added with version 1.95.8 - XML_StopParser @63 - XML_ResumeParser @64 - XML_GetParsingStatus @65 diff --git a/lib-src/expat/lib/macconfig.h b/lib-src/expat/lib/macconfig.h deleted file mode 100644 index 2725caaf5..000000000 --- a/lib-src/expat/lib/macconfig.h +++ /dev/null @@ -1,53 +0,0 @@ -/*================================================================ -** Copyright 2000, Clark Cooper -** All rights reserved. -** -** This is free software. You are permitted to copy, distribute, or modify -** it under the terms of the MIT/X license (contained in the COPYING file -** with this distribution.) -** -*/ - -#ifndef MACCONFIG_H -#define MACCONFIG_H - - -/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */ -#define BYTEORDER 4321 - -/* Define to 1 if you have the `bcopy' function. */ -#undef HAVE_BCOPY - -/* Define to 1 if you have the `memmove' function. */ -#define HAVE_MEMMOVE - -/* Define to 1 if you have a working `mmap' system call. */ -#undef HAVE_MMAP - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* whether byteorder is bigendian */ -#define WORDS_BIGENDIAN - -/* Define to specify how much context to retain around the current parse - point. */ -#undef XML_CONTEXT_BYTES - -/* Define to make parameter entity parsing functionality available. */ -#define XML_DTD - -/* Define to make XML Namespaces functionality available. */ -#define XML_NS - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define to `long' if does not define. */ -#define off_t long - -/* Define to `unsigned' if does not define. */ -#undef size_t - - -#endif /* ifndef MACCONFIG_H */ diff --git a/lib-src/expat/lib/nametab.h b/lib-src/expat/lib/nametab.h deleted file mode 100644 index b05e62c77..000000000 --- a/lib-src/expat/lib/nametab.h +++ /dev/null @@ -1,150 +0,0 @@ -static const unsigned namingBitmap[] = { -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, -0x00000000, 0x04000000, 0x87FFFFFE, 0x07FFFFFE, -0x00000000, 0x00000000, 0xFF7FFFFF, 0xFF7FFFFF, -0xFFFFFFFF, 0x7FF3FFFF, 0xFFFFFDFE, 0x7FFFFFFF, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFE00F, 0xFC31FFFF, -0x00FFFFFF, 0x00000000, 0xFFFF0000, 0xFFFFFFFF, -0xFFFFFFFF, 0xF80001FF, 0x00000003, 0x00000000, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0xFFFFD740, 0xFFFFFFFB, 0x547F7FFF, 0x000FFFFD, -0xFFFFDFFE, 0xFFFFFFFF, 0xDFFEFFFF, 0xFFFFFFFF, -0xFFFF0003, 0xFFFFFFFF, 0xFFFF199F, 0x033FCFFF, -0x00000000, 0xFFFE0000, 0x027FFFFF, 0xFFFFFFFE, -0x0000007F, 0x00000000, 0xFFFF0000, 0x000707FF, -0x00000000, 0x07FFFFFE, 0x000007FE, 0xFFFE0000, -0xFFFFFFFF, 0x7CFFFFFF, 0x002F7FFF, 0x00000060, -0xFFFFFFE0, 0x23FFFFFF, 0xFF000000, 0x00000003, -0xFFF99FE0, 0x03C5FDFF, 0xB0000000, 0x00030003, -0xFFF987E0, 0x036DFDFF, 0x5E000000, 0x001C0000, -0xFFFBAFE0, 0x23EDFDFF, 0x00000000, 0x00000001, -0xFFF99FE0, 0x23CDFDFF, 0xB0000000, 0x00000003, -0xD63DC7E0, 0x03BFC718, 0x00000000, 0x00000000, -0xFFFDDFE0, 0x03EFFDFF, 0x00000000, 0x00000003, -0xFFFDDFE0, 0x03EFFDFF, 0x40000000, 0x00000003, -0xFFFDDFE0, 0x03FFFDFF, 0x00000000, 0x00000003, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0xFFFFFFFE, 0x000D7FFF, 0x0000003F, 0x00000000, -0xFEF02596, 0x200D6CAE, 0x0000001F, 0x00000000, -0x00000000, 0x00000000, 0xFFFFFEFF, 0x000003FF, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0x00000000, 0xFFFFFFFF, 0xFFFF003F, 0x007FFFFF, -0x0007DAED, 0x50000000, 0x82315001, 0x002C62AB, -0x40000000, 0xF580C900, 0x00000007, 0x02010800, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, -0x0FFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0x03FFFFFF, -0x3F3FFFFF, 0xFFFFFFFF, 0xAAFF3F3F, 0x3FFFFFFF, -0xFFFFFFFF, 0x5FDFFFFF, 0x0FCF1FDC, 0x1FDC1FFF, -0x00000000, 0x00004C40, 0x00000000, 0x00000000, -0x00000007, 0x00000000, 0x00000000, 0x00000000, -0x00000080, 0x000003FE, 0xFFFFFFFE, 0xFFFFFFFF, -0x001FFFFF, 0xFFFFFFFE, 0xFFFFFFFF, 0x07FFFFFF, -0xFFFFFFE0, 0x00001FFF, 0x00000000, 0x00000000, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, -0xFFFFFFFF, 0x0000003F, 0x00000000, 0x00000000, -0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, -0xFFFFFFFF, 0x0000000F, 0x00000000, 0x00000000, -0x00000000, 0x07FF6000, 0x87FFFFFE, 0x07FFFFFE, -0x00000000, 0x00800000, 0xFF7FFFFF, 0xFF7FFFFF, -0x00FFFFFF, 0x00000000, 0xFFFF0000, 0xFFFFFFFF, -0xFFFFFFFF, 0xF80001FF, 0x00030003, 0x00000000, -0xFFFFFFFF, 0xFFFFFFFF, 0x0000003F, 0x00000003, -0xFFFFD7C0, 0xFFFFFFFB, 0x547F7FFF, 0x000FFFFD, -0xFFFFDFFE, 0xFFFFFFFF, 0xDFFEFFFF, 0xFFFFFFFF, -0xFFFF007B, 0xFFFFFFFF, 0xFFFF199F, 0x033FCFFF, -0x00000000, 0xFFFE0000, 0x027FFFFF, 0xFFFFFFFE, -0xFFFE007F, 0xBBFFFFFB, 0xFFFF0016, 0x000707FF, -0x00000000, 0x07FFFFFE, 0x0007FFFF, 0xFFFF03FF, -0xFFFFFFFF, 0x7CFFFFFF, 0xFFEF7FFF, 0x03FF3DFF, -0xFFFFFFEE, 0xF3FFFFFF, 0xFF1E3FFF, 0x0000FFCF, -0xFFF99FEE, 0xD3C5FDFF, 0xB080399F, 0x0003FFCF, -0xFFF987E4, 0xD36DFDFF, 0x5E003987, 0x001FFFC0, -0xFFFBAFEE, 0xF3EDFDFF, 0x00003BBF, 0x0000FFC1, -0xFFF99FEE, 0xF3CDFDFF, 0xB0C0398F, 0x0000FFC3, -0xD63DC7EC, 0xC3BFC718, 0x00803DC7, 0x0000FF80, -0xFFFDDFEE, 0xC3EFFDFF, 0x00603DDF, 0x0000FFC3, -0xFFFDDFEC, 0xC3EFFDFF, 0x40603DDF, 0x0000FFC3, -0xFFFDDFEC, 0xC3FFFDFF, 0x00803DCF, 0x0000FFC3, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0xFFFFFFFE, 0x07FF7FFF, 0x03FF7FFF, 0x00000000, -0xFEF02596, 0x3BFF6CAE, 0x03FF3F5F, 0x00000000, -0x03000000, 0xC2A003FF, 0xFFFFFEFF, 0xFFFE03FF, -0xFEBF0FDF, 0x02FE3FFF, 0x00000000, 0x00000000, -0x00000000, 0x00000000, 0x00000000, 0x00000000, -0x00000000, 0x00000000, 0x1FFF0000, 0x00000002, -0x000000A0, 0x003EFFFE, 0xFFFFFFFE, 0xFFFFFFFF, -0x661FFFFF, 0xFFFFFFFE, 0xFFFFFFFF, 0x77FFFFFF, -}; -static const unsigned char nmstrtPages[] = { -0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x00, -0x00, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F, -0x10, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x13, -0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x15, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x17, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x18, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -}; -static const unsigned char namePages[] = { -0x19, 0x03, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x00, -0x00, 0x1F, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, -0x10, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x13, -0x26, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x27, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x17, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x18, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -}; diff --git a/lib-src/expat/lib/utf8tab.h b/lib-src/expat/lib/utf8tab.h deleted file mode 100644 index 7bb3e7760..000000000 --- a/lib-src/expat/lib/utf8tab.h +++ /dev/null @@ -1,37 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - - -/* 0x80 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x84 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x88 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x8C */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x90 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x94 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x98 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0x9C */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xA0 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xA4 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xA8 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xAC */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xB0 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xB4 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xB8 */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xBC */ BT_TRAIL, BT_TRAIL, BT_TRAIL, BT_TRAIL, -/* 0xC0 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xC4 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xC8 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xCC */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xD0 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xD4 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xD8 */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xDC */ BT_LEAD2, BT_LEAD2, BT_LEAD2, BT_LEAD2, -/* 0xE0 */ BT_LEAD3, BT_LEAD3, BT_LEAD3, BT_LEAD3, -/* 0xE4 */ BT_LEAD3, BT_LEAD3, BT_LEAD3, BT_LEAD3, -/* 0xE8 */ BT_LEAD3, BT_LEAD3, BT_LEAD3, BT_LEAD3, -/* 0xEC */ BT_LEAD3, BT_LEAD3, BT_LEAD3, BT_LEAD3, -/* 0xF0 */ BT_LEAD4, BT_LEAD4, BT_LEAD4, BT_LEAD4, -/* 0xF4 */ BT_LEAD4, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0xF8 */ BT_NONXML, BT_NONXML, BT_NONXML, BT_NONXML, -/* 0xFC */ BT_NONXML, BT_NONXML, BT_MALFORM, BT_MALFORM, diff --git a/lib-src/expat/lib/winconfig.h b/lib-src/expat/lib/winconfig.h deleted file mode 100644 index c1b791d62..000000000 --- a/lib-src/expat/lib/winconfig.h +++ /dev/null @@ -1,30 +0,0 @@ -/*================================================================ -** Copyright 2000, Clark Cooper -** All rights reserved. -** -** This is free software. You are permitted to copy, distribute, or modify -** it under the terms of the MIT/X license (contained in the COPYING file -** with this distribution.) -*/ - -#ifndef WINCONFIG_H -#define WINCONFIG_H - -#define WIN32_LEAN_AND_MEAN -#include -#undef WIN32_LEAN_AND_MEAN - -#include -#include - -#define XML_NS 1 -#define XML_DTD 1 -#define XML_CONTEXT_BYTES 1024 - -/* we will assume all Windows platforms are little endian */ -#define BYTEORDER 1234 - -/* Windows has memmove() available. */ -#define HAVE_MEMMOVE - -#endif /* ndef WINCONFIG_H */ diff --git a/lib-src/expat/lib/xmlparse.c b/lib-src/expat/lib/xmlparse.c deleted file mode 100644 index f35aa36ba..000000000 --- a/lib-src/expat/lib/xmlparse.c +++ /dev/null @@ -1,6403 +0,0 @@ -/* Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include -#include /* memset(), memcpy() */ -#include -#include /* UINT_MAX */ -#include /* time() */ - -#define XML_BUILDING_EXPAT 1 - -#ifdef COMPILED_FROM_DSP -#include "winconfig.h" -#elif defined(MACOS_CLASSIC) -#include "macconfig.h" -#elif defined(__amigaos__) -#include "amigaconfig.h" -#elif defined(__WATCOMC__) -#include "watcomconfig.h" -#elif defined(HAVE_EXPAT_CONFIG_H) -#include -#endif /* ndef COMPILED_FROM_DSP */ - -#include "ascii.h" -#include "expat.h" - -#ifdef XML_UNICODE -#define XML_ENCODE_MAX XML_UTF16_ENCODE_MAX -#define XmlConvert XmlUtf16Convert -#define XmlGetInternalEncoding XmlGetUtf16InternalEncoding -#define XmlGetInternalEncodingNS XmlGetUtf16InternalEncodingNS -#define XmlEncode XmlUtf16Encode -/* Using pointer subtraction to convert to integer type. */ -#define MUST_CONVERT(enc, s) (!(enc)->isUtf16 || (((char *)(s) - (char *)NULL) & 1)) -typedef unsigned short ICHAR; -#else -#define XML_ENCODE_MAX XML_UTF8_ENCODE_MAX -#define XmlConvert XmlUtf8Convert -#define XmlGetInternalEncoding XmlGetUtf8InternalEncoding -#define XmlGetInternalEncodingNS XmlGetUtf8InternalEncodingNS -#define XmlEncode XmlUtf8Encode -#define MUST_CONVERT(enc, s) (!(enc)->isUtf8) -typedef char ICHAR; -#endif - - -#ifndef XML_NS - -#define XmlInitEncodingNS XmlInitEncoding -#define XmlInitUnknownEncodingNS XmlInitUnknownEncoding -#undef XmlGetInternalEncodingNS -#define XmlGetInternalEncodingNS XmlGetInternalEncoding -#define XmlParseXmlDeclNS XmlParseXmlDecl - -#endif - -#ifdef XML_UNICODE - -#ifdef XML_UNICODE_WCHAR_T -#define XML_T(x) (const wchar_t)x -#define XML_L(x) L ## x -#else -#define XML_T(x) (const unsigned short)x -#define XML_L(x) x -#endif - -#else - -#define XML_T(x) x -#define XML_L(x) x - -#endif - -/* Round up n to be a multiple of sz, where sz is a power of 2. */ -#define ROUND_UP(n, sz) (((n) + ((sz) - 1)) & ~((sz) - 1)) - -/* Handle the case where memmove() doesn't exist. */ -#ifndef HAVE_MEMMOVE -#ifdef HAVE_BCOPY -#define memmove(d,s,l) bcopy((s),(d),(l)) -#else -#error memmove does not exist on this platform, nor is a substitute available -#endif /* HAVE_BCOPY */ -#endif /* HAVE_MEMMOVE */ - -#include "internal.h" -#include "xmltok.h" -#include "xmlrole.h" - -typedef const XML_Char *KEY; - -typedef struct { - KEY name; -} NAMED; - -typedef struct { - NAMED **v; - unsigned char power; - size_t size; - size_t used; - const XML_Memory_Handling_Suite *mem; -} HASH_TABLE; - -/* Basic character hash algorithm, taken from Python's string hash: - h = h * 1000003 ^ character, the constant being a prime number. - -*/ -#ifdef XML_UNICODE -#define CHAR_HASH(h, c) \ - (((h) * 0xF4243) ^ (unsigned short)(c)) -#else -#define CHAR_HASH(h, c) \ - (((h) * 0xF4243) ^ (unsigned char)(c)) -#endif - -/* For probing (after a collision) we need a step size relative prime - to the hash table size, which is a power of 2. We use double-hashing, - since we can calculate a second hash value cheaply by taking those bits - of the first hash value that were discarded (masked out) when the table - index was calculated: index = hash & mask, where mask = table->size - 1. - We limit the maximum step size to table->size / 4 (mask >> 2) and make - it odd, since odd numbers are always relative prime to a power of 2. -*/ -#define SECOND_HASH(hash, mask, power) \ - ((((hash) & ~(mask)) >> ((power) - 1)) & ((mask) >> 2)) -#define PROBE_STEP(hash, mask, power) \ - ((unsigned char)((SECOND_HASH(hash, mask, power)) | 1)) - -typedef struct { - NAMED **p; - NAMED **end; -} HASH_TABLE_ITER; - -#define INIT_TAG_BUF_SIZE 32 /* must be a multiple of sizeof(XML_Char) */ -#define INIT_DATA_BUF_SIZE 1024 -#define INIT_ATTS_SIZE 16 -#define INIT_ATTS_VERSION 0xFFFFFFFF -#define INIT_BLOCK_SIZE 1024 -#define INIT_BUFFER_SIZE 1024 - -#define EXPAND_SPARE 24 - -typedef struct binding { - struct prefix *prefix; - struct binding *nextTagBinding; - struct binding *prevPrefixBinding; - const struct attribute_id *attId; - XML_Char *uri; - int uriLen; - int uriAlloc; -} BINDING; - -typedef struct prefix { - const XML_Char *name; - BINDING *binding; -} PREFIX; - -typedef struct { - const XML_Char *str; - const XML_Char *localPart; - const XML_Char *prefix; - int strLen; - int uriLen; - int prefixLen; -} TAG_NAME; - -/* TAG represents an open element. - The name of the element is stored in both the document and API - encodings. The memory buffer 'buf' is a separately-allocated - memory area which stores the name. During the XML_Parse()/ - XMLParseBuffer() when the element is open, the memory for the 'raw' - version of the name (in the document encoding) is shared with the - document buffer. If the element is open across calls to - XML_Parse()/XML_ParseBuffer(), the buffer is re-allocated to - contain the 'raw' name as well. - - A parser re-uses these structures, maintaining a list of allocated - TAG objects in a free list. -*/ -typedef struct tag { - struct tag *parent; /* parent of this element */ - const char *rawName; /* tagName in the original encoding */ - int rawNameLength; - TAG_NAME name; /* tagName in the API encoding */ - char *buf; /* buffer for name components */ - char *bufEnd; /* end of the buffer */ - BINDING *bindings; -} TAG; - -typedef struct { - const XML_Char *name; - const XML_Char *textPtr; - int textLen; /* length in XML_Chars */ - int processed; /* # of processed bytes - when suspended */ - const XML_Char *systemId; - const XML_Char *base; - const XML_Char *publicId; - const XML_Char *notation; - XML_Bool open; - XML_Bool is_param; - XML_Bool is_internal; /* true if declared in internal subset outside PE */ -} ENTITY; - -typedef struct { - enum XML_Content_Type type; - enum XML_Content_Quant quant; - const XML_Char * name; - int firstchild; - int lastchild; - int childcnt; - int nextsib; -} CONTENT_SCAFFOLD; - -#define INIT_SCAFFOLD_ELEMENTS 32 - -typedef struct block { - struct block *next; - int size; - XML_Char s[1]; -} BLOCK; - -typedef struct { - BLOCK *blocks; - BLOCK *freeBlocks; - const XML_Char *end; - XML_Char *ptr; - XML_Char *start; - const XML_Memory_Handling_Suite *mem; -} STRING_POOL; - -/* The XML_Char before the name is used to determine whether - an attribute has been specified. */ -typedef struct attribute_id { - XML_Char *name; - PREFIX *prefix; - XML_Bool maybeTokenized; - XML_Bool xmlns; -} ATTRIBUTE_ID; - -typedef struct { - const ATTRIBUTE_ID *id; - XML_Bool isCdata; - const XML_Char *value; -} DEFAULT_ATTRIBUTE; - -typedef struct { - unsigned long version; - unsigned long hash; - const XML_Char *uriName; -} NS_ATT; - -typedef struct { - const XML_Char *name; - PREFIX *prefix; - const ATTRIBUTE_ID *idAtt; - int nDefaultAtts; - int allocDefaultAtts; - DEFAULT_ATTRIBUTE *defaultAtts; -} ELEMENT_TYPE; - -typedef struct { - HASH_TABLE generalEntities; - HASH_TABLE elementTypes; - HASH_TABLE attributeIds; - HASH_TABLE prefixes; - STRING_POOL pool; - STRING_POOL entityValuePool; - /* false once a parameter entity reference has been skipped */ - XML_Bool keepProcessing; - /* true once an internal or external PE reference has been encountered; - this includes the reference to an external subset */ - XML_Bool hasParamEntityRefs; - XML_Bool standalone; -#ifdef XML_DTD - /* indicates if external PE has been read */ - XML_Bool paramEntityRead; - HASH_TABLE paramEntities; -#endif /* XML_DTD */ - PREFIX defaultPrefix; - /* === scaffolding for building content model === */ - XML_Bool in_eldecl; - CONTENT_SCAFFOLD *scaffold; - unsigned contentStringLen; - unsigned scaffSize; - unsigned scaffCount; - int scaffLevel; - int *scaffIndex; -} DTD; - -typedef struct open_internal_entity { - const char *internalEventPtr; - const char *internalEventEndPtr; - struct open_internal_entity *next; - ENTITY *entity; - int startTagLevel; - XML_Bool betweenDecl; /* WFC: PE Between Declarations */ -} OPEN_INTERNAL_ENTITY; - -typedef enum XML_Error PTRCALL Processor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr); - -static Processor prologProcessor; -static Processor prologInitProcessor; -static Processor contentProcessor; -static Processor cdataSectionProcessor; -#ifdef XML_DTD -static Processor ignoreSectionProcessor; -static Processor externalParEntProcessor; -static Processor externalParEntInitProcessor; -static Processor entityValueProcessor; -static Processor entityValueInitProcessor; -#endif /* XML_DTD */ -static Processor epilogProcessor; -static Processor errorProcessor; -static Processor externalEntityInitProcessor; -static Processor externalEntityInitProcessor2; -static Processor externalEntityInitProcessor3; -static Processor externalEntityContentProcessor; -static Processor internalEntityProcessor; - -static enum XML_Error -handleUnknownEncoding(XML_Parser parser, const XML_Char *encodingName); -static enum XML_Error -processXmlDecl(XML_Parser parser, int isGeneralTextEntity, - const char *s, const char *next); -static enum XML_Error -initializeEncoding(XML_Parser parser); -static enum XML_Error -doProlog(XML_Parser parser, const ENCODING *enc, const char *s, - const char *end, int tok, const char *next, const char **nextPtr, - XML_Bool haveMore); -static enum XML_Error -processInternalEntity(XML_Parser parser, ENTITY *entity, - XML_Bool betweenDecl); -static enum XML_Error -doContent(XML_Parser parser, int startTagLevel, const ENCODING *enc, - const char *start, const char *end, const char **endPtr, - XML_Bool haveMore); -static enum XML_Error -doCdataSection(XML_Parser parser, const ENCODING *, const char **startPtr, - const char *end, const char **nextPtr, XML_Bool haveMore); -#ifdef XML_DTD -static enum XML_Error -doIgnoreSection(XML_Parser parser, const ENCODING *, const char **startPtr, - const char *end, const char **nextPtr, XML_Bool haveMore); -#endif /* XML_DTD */ - -static enum XML_Error -storeAtts(XML_Parser parser, const ENCODING *, const char *s, - TAG_NAME *tagNamePtr, BINDING **bindingsPtr); -static enum XML_Error -addBinding(XML_Parser parser, PREFIX *prefix, const ATTRIBUTE_ID *attId, - const XML_Char *uri, BINDING **bindingsPtr); -static int -defineAttribute(ELEMENT_TYPE *type, ATTRIBUTE_ID *, XML_Bool isCdata, - XML_Bool isId, const XML_Char *dfltValue, XML_Parser parser); -static enum XML_Error -storeAttributeValue(XML_Parser parser, const ENCODING *, XML_Bool isCdata, - const char *, const char *, STRING_POOL *); -static enum XML_Error -appendAttributeValue(XML_Parser parser, const ENCODING *, XML_Bool isCdata, - const char *, const char *, STRING_POOL *); -static ATTRIBUTE_ID * -getAttributeId(XML_Parser parser, const ENCODING *enc, const char *start, - const char *end); -static int -setElementTypePrefix(XML_Parser parser, ELEMENT_TYPE *); -static enum XML_Error -storeEntityValue(XML_Parser parser, const ENCODING *enc, const char *start, - const char *end); -static int -reportProcessingInstruction(XML_Parser parser, const ENCODING *enc, - const char *start, const char *end); -static int -reportComment(XML_Parser parser, const ENCODING *enc, const char *start, - const char *end); -static void -reportDefault(XML_Parser parser, const ENCODING *enc, const char *start, - const char *end); - -static const XML_Char * getContext(XML_Parser parser); -static XML_Bool -setContext(XML_Parser parser, const XML_Char *context); - -static void FASTCALL normalizePublicId(XML_Char *s); - -static DTD * dtdCreate(const XML_Memory_Handling_Suite *ms); -/* do not call if parentParser != NULL */ -static void dtdReset(DTD *p, const XML_Memory_Handling_Suite *ms); -static void -dtdDestroy(DTD *p, XML_Bool isDocEntity, const XML_Memory_Handling_Suite *ms); -static int -dtdCopy(XML_Parser oldParser, - DTD *newDtd, const DTD *oldDtd, const XML_Memory_Handling_Suite *ms); -static int -copyEntityTable(XML_Parser oldParser, - HASH_TABLE *, STRING_POOL *, const HASH_TABLE *); -static NAMED * -lookup(XML_Parser parser, HASH_TABLE *table, KEY name, size_t createSize); -static void FASTCALL -hashTableInit(HASH_TABLE *, const XML_Memory_Handling_Suite *ms); -static void FASTCALL hashTableClear(HASH_TABLE *); -static void FASTCALL hashTableDestroy(HASH_TABLE *); -static void FASTCALL -hashTableIterInit(HASH_TABLE_ITER *, const HASH_TABLE *); -static NAMED * FASTCALL hashTableIterNext(HASH_TABLE_ITER *); - -static void FASTCALL -poolInit(STRING_POOL *, const XML_Memory_Handling_Suite *ms); -static void FASTCALL poolClear(STRING_POOL *); -static void FASTCALL poolDestroy(STRING_POOL *); -static XML_Char * -poolAppend(STRING_POOL *pool, const ENCODING *enc, - const char *ptr, const char *end); -static XML_Char * -poolStoreString(STRING_POOL *pool, const ENCODING *enc, - const char *ptr, const char *end); -static XML_Bool FASTCALL poolGrow(STRING_POOL *pool); -static const XML_Char * FASTCALL -poolCopyString(STRING_POOL *pool, const XML_Char *s); -static const XML_Char * -poolCopyStringN(STRING_POOL *pool, const XML_Char *s, int n); -static const XML_Char * FASTCALL -poolAppendString(STRING_POOL *pool, const XML_Char *s); - -static int FASTCALL nextScaffoldPart(XML_Parser parser); -static XML_Content * build_model(XML_Parser parser); -static ELEMENT_TYPE * -getElementType(XML_Parser parser, const ENCODING *enc, - const char *ptr, const char *end); - -static unsigned long generate_hash_secret_salt(void); -static XML_Bool startParsing(XML_Parser parser); - -static XML_Parser -parserCreate(const XML_Char *encodingName, - const XML_Memory_Handling_Suite *memsuite, - const XML_Char *nameSep, - DTD *dtd); - -static void -parserInit(XML_Parser parser, const XML_Char *encodingName); - -#define poolStart(pool) ((pool)->start) -#define poolEnd(pool) ((pool)->ptr) -#define poolLength(pool) ((pool)->ptr - (pool)->start) -#define poolChop(pool) ((void)--(pool->ptr)) -#define poolLastChar(pool) (((pool)->ptr)[-1]) -#define poolDiscard(pool) ((pool)->ptr = (pool)->start) -#define poolFinish(pool) ((pool)->start = (pool)->ptr) -#define poolAppendChar(pool, c) \ - (((pool)->ptr == (pool)->end && !poolGrow(pool)) \ - ? 0 \ - : ((*((pool)->ptr)++ = c), 1)) - -struct XML_ParserStruct { - /* The first member must be userData so that the XML_GetUserData - macro works. */ - void *m_userData; - void *m_handlerArg; - char *m_buffer; - const XML_Memory_Handling_Suite m_mem; - /* first character to be parsed */ - const char *m_bufferPtr; - /* past last character to be parsed */ - char *m_bufferEnd; - /* allocated end of buffer */ - const char *m_bufferLim; - XML_Index m_parseEndByteIndex; - const char *m_parseEndPtr; - XML_Char *m_dataBuf; - XML_Char *m_dataBufEnd; - XML_StartElementHandler m_startElementHandler; - XML_EndElementHandler m_endElementHandler; - XML_CharacterDataHandler m_characterDataHandler; - XML_ProcessingInstructionHandler m_processingInstructionHandler; - XML_CommentHandler m_commentHandler; - XML_StartCdataSectionHandler m_startCdataSectionHandler; - XML_EndCdataSectionHandler m_endCdataSectionHandler; - XML_DefaultHandler m_defaultHandler; - XML_StartDoctypeDeclHandler m_startDoctypeDeclHandler; - XML_EndDoctypeDeclHandler m_endDoctypeDeclHandler; - XML_UnparsedEntityDeclHandler m_unparsedEntityDeclHandler; - XML_NotationDeclHandler m_notationDeclHandler; - XML_StartNamespaceDeclHandler m_startNamespaceDeclHandler; - XML_EndNamespaceDeclHandler m_endNamespaceDeclHandler; - XML_NotStandaloneHandler m_notStandaloneHandler; - XML_ExternalEntityRefHandler m_externalEntityRefHandler; - XML_Parser m_externalEntityRefHandlerArg; - XML_SkippedEntityHandler m_skippedEntityHandler; - XML_UnknownEncodingHandler m_unknownEncodingHandler; - XML_ElementDeclHandler m_elementDeclHandler; - XML_AttlistDeclHandler m_attlistDeclHandler; - XML_EntityDeclHandler m_entityDeclHandler; - XML_XmlDeclHandler m_xmlDeclHandler; - const ENCODING *m_encoding; - INIT_ENCODING m_initEncoding; - const ENCODING *m_internalEncoding; - const XML_Char *m_protocolEncodingName; - XML_Bool m_ns; - XML_Bool m_ns_triplets; - void *m_unknownEncodingMem; - void *m_unknownEncodingData; - void *m_unknownEncodingHandlerData; - void (XMLCALL *m_unknownEncodingRelease)(void *); - PROLOG_STATE m_prologState; - Processor *m_processor; - enum XML_Error m_errorCode; - const char *m_eventPtr; - const char *m_eventEndPtr; - const char *m_positionPtr; - OPEN_INTERNAL_ENTITY *m_openInternalEntities; - OPEN_INTERNAL_ENTITY *m_freeInternalEntities; - XML_Bool m_defaultExpandInternalEntities; - int m_tagLevel; - ENTITY *m_declEntity; - const XML_Char *m_doctypeName; - const XML_Char *m_doctypeSysid; - const XML_Char *m_doctypePubid; - const XML_Char *m_declAttributeType; - const XML_Char *m_declNotationName; - const XML_Char *m_declNotationPublicId; - ELEMENT_TYPE *m_declElementType; - ATTRIBUTE_ID *m_declAttributeId; - XML_Bool m_declAttributeIsCdata; - XML_Bool m_declAttributeIsId; - DTD *m_dtd; - const XML_Char *m_curBase; - TAG *m_tagStack; - TAG *m_freeTagList; - BINDING *m_inheritedBindings; - BINDING *m_freeBindingList; - int m_attsSize; - int m_nSpecifiedAtts; - int m_idAttIndex; - ATTRIBUTE *m_atts; - NS_ATT *m_nsAtts; - unsigned long m_nsAttsVersion; - unsigned char m_nsAttsPower; -#ifdef XML_ATTR_INFO - XML_AttrInfo *m_attInfo; -#endif - POSITION m_position; - STRING_POOL m_tempPool; - STRING_POOL m_temp2Pool; - char *m_groupConnector; - unsigned int m_groupSize; - XML_Char m_namespaceSeparator; - XML_Parser m_parentParser; - XML_ParsingStatus m_parsingStatus; -#ifdef XML_DTD - XML_Bool m_isParamEntity; - XML_Bool m_useForeignDTD; - enum XML_ParamEntityParsing m_paramEntityParsing; -#endif - unsigned long m_hash_secret_salt; -}; - -#define MALLOC(s) (parser->m_mem.malloc_fcn((s))) -#define REALLOC(p,s) (parser->m_mem.realloc_fcn((p),(s))) -#define FREE(p) (parser->m_mem.free_fcn((p))) - -#define userData (parser->m_userData) -#define handlerArg (parser->m_handlerArg) -#define startElementHandler (parser->m_startElementHandler) -#define endElementHandler (parser->m_endElementHandler) -#define characterDataHandler (parser->m_characterDataHandler) -#define processingInstructionHandler \ - (parser->m_processingInstructionHandler) -#define commentHandler (parser->m_commentHandler) -#define startCdataSectionHandler \ - (parser->m_startCdataSectionHandler) -#define endCdataSectionHandler (parser->m_endCdataSectionHandler) -#define defaultHandler (parser->m_defaultHandler) -#define startDoctypeDeclHandler (parser->m_startDoctypeDeclHandler) -#define endDoctypeDeclHandler (parser->m_endDoctypeDeclHandler) -#define unparsedEntityDeclHandler \ - (parser->m_unparsedEntityDeclHandler) -#define notationDeclHandler (parser->m_notationDeclHandler) -#define startNamespaceDeclHandler \ - (parser->m_startNamespaceDeclHandler) -#define endNamespaceDeclHandler (parser->m_endNamespaceDeclHandler) -#define notStandaloneHandler (parser->m_notStandaloneHandler) -#define externalEntityRefHandler \ - (parser->m_externalEntityRefHandler) -#define externalEntityRefHandlerArg \ - (parser->m_externalEntityRefHandlerArg) -#define internalEntityRefHandler \ - (parser->m_internalEntityRefHandler) -#define skippedEntityHandler (parser->m_skippedEntityHandler) -#define unknownEncodingHandler (parser->m_unknownEncodingHandler) -#define elementDeclHandler (parser->m_elementDeclHandler) -#define attlistDeclHandler (parser->m_attlistDeclHandler) -#define entityDeclHandler (parser->m_entityDeclHandler) -#define xmlDeclHandler (parser->m_xmlDeclHandler) -#define encoding (parser->m_encoding) -#define initEncoding (parser->m_initEncoding) -#define internalEncoding (parser->m_internalEncoding) -#define unknownEncodingMem (parser->m_unknownEncodingMem) -#define unknownEncodingData (parser->m_unknownEncodingData) -#define unknownEncodingHandlerData \ - (parser->m_unknownEncodingHandlerData) -#define unknownEncodingRelease (parser->m_unknownEncodingRelease) -#define protocolEncodingName (parser->m_protocolEncodingName) -#define ns (parser->m_ns) -#define ns_triplets (parser->m_ns_triplets) -#define prologState (parser->m_prologState) -#define processor (parser->m_processor) -#define errorCode (parser->m_errorCode) -#define eventPtr (parser->m_eventPtr) -#define eventEndPtr (parser->m_eventEndPtr) -#define positionPtr (parser->m_positionPtr) -#define position (parser->m_position) -#define openInternalEntities (parser->m_openInternalEntities) -#define freeInternalEntities (parser->m_freeInternalEntities) -#define defaultExpandInternalEntities \ - (parser->m_defaultExpandInternalEntities) -#define tagLevel (parser->m_tagLevel) -#define buffer (parser->m_buffer) -#define bufferPtr (parser->m_bufferPtr) -#define bufferEnd (parser->m_bufferEnd) -#define parseEndByteIndex (parser->m_parseEndByteIndex) -#define parseEndPtr (parser->m_parseEndPtr) -#define bufferLim (parser->m_bufferLim) -#define dataBuf (parser->m_dataBuf) -#define dataBufEnd (parser->m_dataBufEnd) -#define _dtd (parser->m_dtd) -#define curBase (parser->m_curBase) -#define declEntity (parser->m_declEntity) -#define doctypeName (parser->m_doctypeName) -#define doctypeSysid (parser->m_doctypeSysid) -#define doctypePubid (parser->m_doctypePubid) -#define declAttributeType (parser->m_declAttributeType) -#define declNotationName (parser->m_declNotationName) -#define declNotationPublicId (parser->m_declNotationPublicId) -#define declElementType (parser->m_declElementType) -#define declAttributeId (parser->m_declAttributeId) -#define declAttributeIsCdata (parser->m_declAttributeIsCdata) -#define declAttributeIsId (parser->m_declAttributeIsId) -#define freeTagList (parser->m_freeTagList) -#define freeBindingList (parser->m_freeBindingList) -#define inheritedBindings (parser->m_inheritedBindings) -#define tagStack (parser->m_tagStack) -#define atts (parser->m_atts) -#define attsSize (parser->m_attsSize) -#define nSpecifiedAtts (parser->m_nSpecifiedAtts) -#define idAttIndex (parser->m_idAttIndex) -#define nsAtts (parser->m_nsAtts) -#define nsAttsVersion (parser->m_nsAttsVersion) -#define nsAttsPower (parser->m_nsAttsPower) -#define attInfo (parser->m_attInfo) -#define tempPool (parser->m_tempPool) -#define temp2Pool (parser->m_temp2Pool) -#define groupConnector (parser->m_groupConnector) -#define groupSize (parser->m_groupSize) -#define namespaceSeparator (parser->m_namespaceSeparator) -#define parentParser (parser->m_parentParser) -#define ps_parsing (parser->m_parsingStatus.parsing) -#define ps_finalBuffer (parser->m_parsingStatus.finalBuffer) -#ifdef XML_DTD -#define isParamEntity (parser->m_isParamEntity) -#define useForeignDTD (parser->m_useForeignDTD) -#define paramEntityParsing (parser->m_paramEntityParsing) -#endif /* XML_DTD */ -#define hash_secret_salt (parser->m_hash_secret_salt) - -XML_Parser XMLCALL -XML_ParserCreate(const XML_Char *encodingName) -{ - return XML_ParserCreate_MM(encodingName, NULL, NULL); -} - -XML_Parser XMLCALL -XML_ParserCreateNS(const XML_Char *encodingName, XML_Char nsSep) -{ - XML_Char tmp[2]; - *tmp = nsSep; - return XML_ParserCreate_MM(encodingName, NULL, tmp); -} - -static const XML_Char implicitContext[] = { - ASCII_x, ASCII_m, ASCII_l, ASCII_EQUALS, ASCII_h, ASCII_t, ASCII_t, ASCII_p, - ASCII_COLON, ASCII_SLASH, ASCII_SLASH, ASCII_w, ASCII_w, ASCII_w, - ASCII_PERIOD, ASCII_w, ASCII_3, ASCII_PERIOD, ASCII_o, ASCII_r, ASCII_g, - ASCII_SLASH, ASCII_X, ASCII_M, ASCII_L, ASCII_SLASH, ASCII_1, ASCII_9, - ASCII_9, ASCII_8, ASCII_SLASH, ASCII_n, ASCII_a, ASCII_m, ASCII_e, - ASCII_s, ASCII_p, ASCII_a, ASCII_c, ASCII_e, '\0' -}; - -static unsigned long -generate_hash_secret_salt(void) -{ - unsigned int seed = time(NULL) % UINT_MAX; - srand(seed); - return rand(); -} - -static XML_Bool /* only valid for root parser */ -startParsing(XML_Parser parser) -{ - /* hash functions must be initialized before setContext() is called */ - if (hash_secret_salt == 0) - hash_secret_salt = generate_hash_secret_salt(); - if (ns) { - /* implicit context only set for root parser, since child - parsers (i.e. external entity parsers) will inherit it - */ - return setContext(parser, implicitContext); - } - return XML_TRUE; -} - -XML_Parser XMLCALL -XML_ParserCreate_MM(const XML_Char *encodingName, - const XML_Memory_Handling_Suite *memsuite, - const XML_Char *nameSep) -{ - return parserCreate(encodingName, memsuite, nameSep, NULL); -} - -static XML_Parser -parserCreate(const XML_Char *encodingName, - const XML_Memory_Handling_Suite *memsuite, - const XML_Char *nameSep, - DTD *dtd) -{ - XML_Parser parser; - - if (memsuite) { - XML_Memory_Handling_Suite *mtemp; - parser = (XML_Parser) - memsuite->malloc_fcn(sizeof(struct XML_ParserStruct)); - if (parser != NULL) { - mtemp = (XML_Memory_Handling_Suite *)&(parser->m_mem); - mtemp->malloc_fcn = memsuite->malloc_fcn; - mtemp->realloc_fcn = memsuite->realloc_fcn; - mtemp->free_fcn = memsuite->free_fcn; - } - } - else { - XML_Memory_Handling_Suite *mtemp; - parser = (XML_Parser)malloc(sizeof(struct XML_ParserStruct)); - if (parser != NULL) { - mtemp = (XML_Memory_Handling_Suite *)&(parser->m_mem); - mtemp->malloc_fcn = malloc; - mtemp->realloc_fcn = realloc; - mtemp->free_fcn = free; - } - } - - if (!parser) - return parser; - - buffer = NULL; - bufferLim = NULL; - - attsSize = INIT_ATTS_SIZE; - atts = (ATTRIBUTE *)MALLOC(attsSize * sizeof(ATTRIBUTE)); - if (atts == NULL) { - FREE(parser); - return NULL; - } -#ifdef XML_ATTR_INFO - attInfo = (XML_AttrInfo*)MALLOC(attsSize * sizeof(XML_AttrInfo)); - if (attInfo == NULL) { - FREE(atts); - FREE(parser); - return NULL; - } -#endif - dataBuf = (XML_Char *)MALLOC(INIT_DATA_BUF_SIZE * sizeof(XML_Char)); - if (dataBuf == NULL) { - FREE(atts); -#ifdef XML_ATTR_INFO - FREE(attInfo); -#endif - FREE(parser); - return NULL; - } - dataBufEnd = dataBuf + INIT_DATA_BUF_SIZE; - - if (dtd) - _dtd = dtd; - else { - _dtd = dtdCreate(&parser->m_mem); - if (_dtd == NULL) { - FREE(dataBuf); - FREE(atts); -#ifdef XML_ATTR_INFO - FREE(attInfo); -#endif - FREE(parser); - return NULL; - } - } - - freeBindingList = NULL; - freeTagList = NULL; - freeInternalEntities = NULL; - - groupSize = 0; - groupConnector = NULL; - - unknownEncodingHandler = NULL; - unknownEncodingHandlerData = NULL; - - namespaceSeparator = ASCII_EXCL; - ns = XML_FALSE; - ns_triplets = XML_FALSE; - - nsAtts = NULL; - nsAttsVersion = 0; - nsAttsPower = 0; - - poolInit(&tempPool, &(parser->m_mem)); - poolInit(&temp2Pool, &(parser->m_mem)); - parserInit(parser, encodingName); - - if (encodingName && !protocolEncodingName) { - XML_ParserFree(parser); - return NULL; - } - - if (nameSep) { - ns = XML_TRUE; - internalEncoding = XmlGetInternalEncodingNS(); - namespaceSeparator = *nameSep; - } - else { - internalEncoding = XmlGetInternalEncoding(); - } - - return parser; -} - -static void -parserInit(XML_Parser parser, const XML_Char *encodingName) -{ - processor = prologInitProcessor; - XmlPrologStateInit(&prologState); - protocolEncodingName = (encodingName != NULL - ? poolCopyString(&tempPool, encodingName) - : NULL); - curBase = NULL; - XmlInitEncoding(&initEncoding, &encoding, 0); - userData = NULL; - handlerArg = NULL; - startElementHandler = NULL; - endElementHandler = NULL; - characterDataHandler = NULL; - processingInstructionHandler = NULL; - commentHandler = NULL; - startCdataSectionHandler = NULL; - endCdataSectionHandler = NULL; - defaultHandler = NULL; - startDoctypeDeclHandler = NULL; - endDoctypeDeclHandler = NULL; - unparsedEntityDeclHandler = NULL; - notationDeclHandler = NULL; - startNamespaceDeclHandler = NULL; - endNamespaceDeclHandler = NULL; - notStandaloneHandler = NULL; - externalEntityRefHandler = NULL; - externalEntityRefHandlerArg = parser; - skippedEntityHandler = NULL; - elementDeclHandler = NULL; - attlistDeclHandler = NULL; - entityDeclHandler = NULL; - xmlDeclHandler = NULL; - bufferPtr = buffer; - bufferEnd = buffer; - parseEndByteIndex = 0; - parseEndPtr = NULL; - declElementType = NULL; - declAttributeId = NULL; - declEntity = NULL; - doctypeName = NULL; - doctypeSysid = NULL; - doctypePubid = NULL; - declAttributeType = NULL; - declNotationName = NULL; - declNotationPublicId = NULL; - declAttributeIsCdata = XML_FALSE; - declAttributeIsId = XML_FALSE; - memset(&position, 0, sizeof(POSITION)); - errorCode = XML_ERROR_NONE; - eventPtr = NULL; - eventEndPtr = NULL; - positionPtr = NULL; - openInternalEntities = NULL; - defaultExpandInternalEntities = XML_TRUE; - tagLevel = 0; - tagStack = NULL; - inheritedBindings = NULL; - nSpecifiedAtts = 0; - unknownEncodingMem = NULL; - unknownEncodingRelease = NULL; - unknownEncodingData = NULL; - parentParser = NULL; - ps_parsing = XML_INITIALIZED; -#ifdef XML_DTD - isParamEntity = XML_FALSE; - useForeignDTD = XML_FALSE; - paramEntityParsing = XML_PARAM_ENTITY_PARSING_NEVER; -#endif - hash_secret_salt = 0; -} - -/* moves list of bindings to freeBindingList */ -static void FASTCALL -moveToFreeBindingList(XML_Parser parser, BINDING *bindings) -{ - while (bindings) { - BINDING *b = bindings; - bindings = bindings->nextTagBinding; - b->nextTagBinding = freeBindingList; - freeBindingList = b; - } -} - -XML_Bool XMLCALL -XML_ParserReset(XML_Parser parser, const XML_Char *encodingName) -{ - TAG *tStk; - OPEN_INTERNAL_ENTITY *openEntityList; - if (parentParser) - return XML_FALSE; - /* move tagStack to freeTagList */ - tStk = tagStack; - while (tStk) { - TAG *tag = tStk; - tStk = tStk->parent; - tag->parent = freeTagList; - moveToFreeBindingList(parser, tag->bindings); - tag->bindings = NULL; - freeTagList = tag; - } - /* move openInternalEntities to freeInternalEntities */ - openEntityList = openInternalEntities; - while (openEntityList) { - OPEN_INTERNAL_ENTITY *openEntity = openEntityList; - openEntityList = openEntity->next; - openEntity->next = freeInternalEntities; - freeInternalEntities = openEntity; - } - moveToFreeBindingList(parser, inheritedBindings); - FREE(unknownEncodingMem); - if (unknownEncodingRelease) - unknownEncodingRelease(unknownEncodingData); - poolClear(&tempPool); - poolClear(&temp2Pool); - parserInit(parser, encodingName); - dtdReset(_dtd, &parser->m_mem); - return XML_TRUE; -} - -enum XML_Status XMLCALL -XML_SetEncoding(XML_Parser parser, const XML_Char *encodingName) -{ - /* Block after XML_Parse()/XML_ParseBuffer() has been called. - XXX There's no way for the caller to determine which of the - XXX possible error cases caused the XML_STATUS_ERROR return. - */ - if (ps_parsing == XML_PARSING || ps_parsing == XML_SUSPENDED) - return XML_STATUS_ERROR; - if (encodingName == NULL) - protocolEncodingName = NULL; - else { - protocolEncodingName = poolCopyString(&tempPool, encodingName); - if (!protocolEncodingName) - return XML_STATUS_ERROR; - } - return XML_STATUS_OK; -} - -XML_Parser XMLCALL -XML_ExternalEntityParserCreate(XML_Parser oldParser, - const XML_Char *context, - const XML_Char *encodingName) -{ - XML_Parser parser = oldParser; - DTD *newDtd = NULL; - DTD *oldDtd = _dtd; - XML_StartElementHandler oldStartElementHandler = startElementHandler; - XML_EndElementHandler oldEndElementHandler = endElementHandler; - XML_CharacterDataHandler oldCharacterDataHandler = characterDataHandler; - XML_ProcessingInstructionHandler oldProcessingInstructionHandler - = processingInstructionHandler; - XML_CommentHandler oldCommentHandler = commentHandler; - XML_StartCdataSectionHandler oldStartCdataSectionHandler - = startCdataSectionHandler; - XML_EndCdataSectionHandler oldEndCdataSectionHandler - = endCdataSectionHandler; - XML_DefaultHandler oldDefaultHandler = defaultHandler; - XML_UnparsedEntityDeclHandler oldUnparsedEntityDeclHandler - = unparsedEntityDeclHandler; - XML_NotationDeclHandler oldNotationDeclHandler = notationDeclHandler; - XML_StartNamespaceDeclHandler oldStartNamespaceDeclHandler - = startNamespaceDeclHandler; - XML_EndNamespaceDeclHandler oldEndNamespaceDeclHandler - = endNamespaceDeclHandler; - XML_NotStandaloneHandler oldNotStandaloneHandler = notStandaloneHandler; - XML_ExternalEntityRefHandler oldExternalEntityRefHandler - = externalEntityRefHandler; - XML_SkippedEntityHandler oldSkippedEntityHandler = skippedEntityHandler; - XML_UnknownEncodingHandler oldUnknownEncodingHandler - = unknownEncodingHandler; - XML_ElementDeclHandler oldElementDeclHandler = elementDeclHandler; - XML_AttlistDeclHandler oldAttlistDeclHandler = attlistDeclHandler; - XML_EntityDeclHandler oldEntityDeclHandler = entityDeclHandler; - XML_XmlDeclHandler oldXmlDeclHandler = xmlDeclHandler; - ELEMENT_TYPE * oldDeclElementType = declElementType; - - void *oldUserData = userData; - void *oldHandlerArg = handlerArg; - XML_Bool oldDefaultExpandInternalEntities = defaultExpandInternalEntities; - XML_Parser oldExternalEntityRefHandlerArg = externalEntityRefHandlerArg; -#ifdef XML_DTD - enum XML_ParamEntityParsing oldParamEntityParsing = paramEntityParsing; - int oldInEntityValue = prologState.inEntityValue; -#endif - XML_Bool oldns_triplets = ns_triplets; - /* Note that the new parser shares the same hash secret as the old - parser, so that dtdCopy and copyEntityTable can lookup values - from hash tables associated with either parser without us having - to worry which hash secrets each table has. - */ - unsigned long oldhash_secret_salt = hash_secret_salt; - -#ifdef XML_DTD - if (!context) - newDtd = oldDtd; -#endif /* XML_DTD */ - - /* Note that the magical uses of the pre-processor to make field - access look more like C++ require that `parser' be overwritten - here. This makes this function more painful to follow than it - would be otherwise. - */ - if (ns) { - XML_Char tmp[2]; - *tmp = namespaceSeparator; - parser = parserCreate(encodingName, &parser->m_mem, tmp, newDtd); - } - else { - parser = parserCreate(encodingName, &parser->m_mem, NULL, newDtd); - } - - if (!parser) - return NULL; - - startElementHandler = oldStartElementHandler; - endElementHandler = oldEndElementHandler; - characterDataHandler = oldCharacterDataHandler; - processingInstructionHandler = oldProcessingInstructionHandler; - commentHandler = oldCommentHandler; - startCdataSectionHandler = oldStartCdataSectionHandler; - endCdataSectionHandler = oldEndCdataSectionHandler; - defaultHandler = oldDefaultHandler; - unparsedEntityDeclHandler = oldUnparsedEntityDeclHandler; - notationDeclHandler = oldNotationDeclHandler; - startNamespaceDeclHandler = oldStartNamespaceDeclHandler; - endNamespaceDeclHandler = oldEndNamespaceDeclHandler; - notStandaloneHandler = oldNotStandaloneHandler; - externalEntityRefHandler = oldExternalEntityRefHandler; - skippedEntityHandler = oldSkippedEntityHandler; - unknownEncodingHandler = oldUnknownEncodingHandler; - elementDeclHandler = oldElementDeclHandler; - attlistDeclHandler = oldAttlistDeclHandler; - entityDeclHandler = oldEntityDeclHandler; - xmlDeclHandler = oldXmlDeclHandler; - declElementType = oldDeclElementType; - userData = oldUserData; - if (oldUserData == oldHandlerArg) - handlerArg = userData; - else - handlerArg = parser; - if (oldExternalEntityRefHandlerArg != oldParser) - externalEntityRefHandlerArg = oldExternalEntityRefHandlerArg; - defaultExpandInternalEntities = oldDefaultExpandInternalEntities; - ns_triplets = oldns_triplets; - hash_secret_salt = oldhash_secret_salt; - parentParser = oldParser; -#ifdef XML_DTD - paramEntityParsing = oldParamEntityParsing; - prologState.inEntityValue = oldInEntityValue; - if (context) { -#endif /* XML_DTD */ - if (!dtdCopy(oldParser, _dtd, oldDtd, &parser->m_mem) - || !setContext(parser, context)) { - XML_ParserFree(parser); - return NULL; - } - processor = externalEntityInitProcessor; -#ifdef XML_DTD - } - else { - /* The DTD instance referenced by _dtd is shared between the document's - root parser and external PE parsers, therefore one does not need to - call setContext. In addition, one also *must* not call setContext, - because this would overwrite existing prefix->binding pointers in - _dtd with ones that get destroyed with the external PE parser. - This would leave those prefixes with dangling pointers. - */ - isParamEntity = XML_TRUE; - XmlPrologStateInitExternalEntity(&prologState); - processor = externalParEntInitProcessor; - } -#endif /* XML_DTD */ - return parser; -} - -static void FASTCALL -destroyBindings(BINDING *bindings, XML_Parser parser) -{ - for (;;) { - BINDING *b = bindings; - if (!b) - break; - bindings = b->nextTagBinding; - FREE(b->uri); - FREE(b); - } -} - -void XMLCALL -XML_ParserFree(XML_Parser parser) -{ - TAG *tagList; - OPEN_INTERNAL_ENTITY *entityList; - if (parser == NULL) - return; - /* free tagStack and freeTagList */ - tagList = tagStack; - for (;;) { - TAG *p; - if (tagList == NULL) { - if (freeTagList == NULL) - break; - tagList = freeTagList; - freeTagList = NULL; - } - p = tagList; - tagList = tagList->parent; - FREE(p->buf); - destroyBindings(p->bindings, parser); - FREE(p); - } - /* free openInternalEntities and freeInternalEntities */ - entityList = openInternalEntities; - for (;;) { - OPEN_INTERNAL_ENTITY *openEntity; - if (entityList == NULL) { - if (freeInternalEntities == NULL) - break; - entityList = freeInternalEntities; - freeInternalEntities = NULL; - } - openEntity = entityList; - entityList = entityList->next; - FREE(openEntity); - } - - destroyBindings(freeBindingList, parser); - destroyBindings(inheritedBindings, parser); - poolDestroy(&tempPool); - poolDestroy(&temp2Pool); -#ifdef XML_DTD - /* external parameter entity parsers share the DTD structure - parser->m_dtd with the root parser, so we must not destroy it - */ - if (!isParamEntity && _dtd) -#else - if (_dtd) -#endif /* XML_DTD */ - dtdDestroy(_dtd, (XML_Bool)!parentParser, &parser->m_mem); - FREE((void *)atts); -#ifdef XML_ATTR_INFO - FREE((void *)attInfo); -#endif - FREE(groupConnector); - FREE(buffer); - FREE(dataBuf); - FREE(nsAtts); - FREE(unknownEncodingMem); - if (unknownEncodingRelease) - unknownEncodingRelease(unknownEncodingData); - FREE(parser); -} - -void XMLCALL -XML_UseParserAsHandlerArg(XML_Parser parser) -{ - handlerArg = parser; -} - -enum XML_Error XMLCALL -XML_UseForeignDTD(XML_Parser parser, XML_Bool useDTD) -{ -#ifdef XML_DTD - /* block after XML_Parse()/XML_ParseBuffer() has been called */ - if (ps_parsing == XML_PARSING || ps_parsing == XML_SUSPENDED) - return XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING; - useForeignDTD = useDTD; - return XML_ERROR_NONE; -#else - return XML_ERROR_FEATURE_REQUIRES_XML_DTD; -#endif -} - -void XMLCALL -XML_SetReturnNSTriplet(XML_Parser parser, int do_nst) -{ - /* block after XML_Parse()/XML_ParseBuffer() has been called */ - if (ps_parsing == XML_PARSING || ps_parsing == XML_SUSPENDED) - return; - ns_triplets = do_nst ? XML_TRUE : XML_FALSE; -} - -void XMLCALL -XML_SetUserData(XML_Parser parser, void *p) -{ - if (handlerArg == userData) - handlerArg = userData = p; - else - userData = p; -} - -enum XML_Status XMLCALL -XML_SetBase(XML_Parser parser, const XML_Char *p) -{ - if (p) { - p = poolCopyString(&_dtd->pool, p); - if (!p) - return XML_STATUS_ERROR; - curBase = p; - } - else - curBase = NULL; - return XML_STATUS_OK; -} - -const XML_Char * XMLCALL -XML_GetBase(XML_Parser parser) -{ - return curBase; -} - -int XMLCALL -XML_GetSpecifiedAttributeCount(XML_Parser parser) -{ - return nSpecifiedAtts; -} - -int XMLCALL -XML_GetIdAttributeIndex(XML_Parser parser) -{ - return idAttIndex; -} - -#ifdef XML_ATTR_INFO -const XML_AttrInfo * XMLCALL -XML_GetAttributeInfo(XML_Parser parser) -{ - return attInfo; -} -#endif - -void XMLCALL -XML_SetElementHandler(XML_Parser parser, - XML_StartElementHandler start, - XML_EndElementHandler end) -{ - startElementHandler = start; - endElementHandler = end; -} - -void XMLCALL -XML_SetStartElementHandler(XML_Parser parser, - XML_StartElementHandler start) { - startElementHandler = start; -} - -void XMLCALL -XML_SetEndElementHandler(XML_Parser parser, - XML_EndElementHandler end) { - endElementHandler = end; -} - -void XMLCALL -XML_SetCharacterDataHandler(XML_Parser parser, - XML_CharacterDataHandler handler) -{ - characterDataHandler = handler; -} - -void XMLCALL -XML_SetProcessingInstructionHandler(XML_Parser parser, - XML_ProcessingInstructionHandler handler) -{ - processingInstructionHandler = handler; -} - -void XMLCALL -XML_SetCommentHandler(XML_Parser parser, - XML_CommentHandler handler) -{ - commentHandler = handler; -} - -void XMLCALL -XML_SetCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start, - XML_EndCdataSectionHandler end) -{ - startCdataSectionHandler = start; - endCdataSectionHandler = end; -} - -void XMLCALL -XML_SetStartCdataSectionHandler(XML_Parser parser, - XML_StartCdataSectionHandler start) { - startCdataSectionHandler = start; -} - -void XMLCALL -XML_SetEndCdataSectionHandler(XML_Parser parser, - XML_EndCdataSectionHandler end) { - endCdataSectionHandler = end; -} - -void XMLCALL -XML_SetDefaultHandler(XML_Parser parser, - XML_DefaultHandler handler) -{ - defaultHandler = handler; - defaultExpandInternalEntities = XML_FALSE; -} - -void XMLCALL -XML_SetDefaultHandlerExpand(XML_Parser parser, - XML_DefaultHandler handler) -{ - defaultHandler = handler; - defaultExpandInternalEntities = XML_TRUE; -} - -void XMLCALL -XML_SetDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start, - XML_EndDoctypeDeclHandler end) -{ - startDoctypeDeclHandler = start; - endDoctypeDeclHandler = end; -} - -void XMLCALL -XML_SetStartDoctypeDeclHandler(XML_Parser parser, - XML_StartDoctypeDeclHandler start) { - startDoctypeDeclHandler = start; -} - -void XMLCALL -XML_SetEndDoctypeDeclHandler(XML_Parser parser, - XML_EndDoctypeDeclHandler end) { - endDoctypeDeclHandler = end; -} - -void XMLCALL -XML_SetUnparsedEntityDeclHandler(XML_Parser parser, - XML_UnparsedEntityDeclHandler handler) -{ - unparsedEntityDeclHandler = handler; -} - -void XMLCALL -XML_SetNotationDeclHandler(XML_Parser parser, - XML_NotationDeclHandler handler) -{ - notationDeclHandler = handler; -} - -void XMLCALL -XML_SetNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start, - XML_EndNamespaceDeclHandler end) -{ - startNamespaceDeclHandler = start; - endNamespaceDeclHandler = end; -} - -void XMLCALL -XML_SetStartNamespaceDeclHandler(XML_Parser parser, - XML_StartNamespaceDeclHandler start) { - startNamespaceDeclHandler = start; -} - -void XMLCALL -XML_SetEndNamespaceDeclHandler(XML_Parser parser, - XML_EndNamespaceDeclHandler end) { - endNamespaceDeclHandler = end; -} - -void XMLCALL -XML_SetNotStandaloneHandler(XML_Parser parser, - XML_NotStandaloneHandler handler) -{ - notStandaloneHandler = handler; -} - -void XMLCALL -XML_SetExternalEntityRefHandler(XML_Parser parser, - XML_ExternalEntityRefHandler handler) -{ - externalEntityRefHandler = handler; -} - -void XMLCALL -XML_SetExternalEntityRefHandlerArg(XML_Parser parser, void *arg) -{ - if (arg) - externalEntityRefHandlerArg = (XML_Parser)arg; - else - externalEntityRefHandlerArg = parser; -} - -void XMLCALL -XML_SetSkippedEntityHandler(XML_Parser parser, - XML_SkippedEntityHandler handler) -{ - skippedEntityHandler = handler; -} - -void XMLCALL -XML_SetUnknownEncodingHandler(XML_Parser parser, - XML_UnknownEncodingHandler handler, - void *data) -{ - unknownEncodingHandler = handler; - unknownEncodingHandlerData = data; -} - -void XMLCALL -XML_SetElementDeclHandler(XML_Parser parser, - XML_ElementDeclHandler eldecl) -{ - elementDeclHandler = eldecl; -} - -void XMLCALL -XML_SetAttlistDeclHandler(XML_Parser parser, - XML_AttlistDeclHandler attdecl) -{ - attlistDeclHandler = attdecl; -} - -void XMLCALL -XML_SetEntityDeclHandler(XML_Parser parser, - XML_EntityDeclHandler handler) -{ - entityDeclHandler = handler; -} - -void XMLCALL -XML_SetXmlDeclHandler(XML_Parser parser, - XML_XmlDeclHandler handler) { - xmlDeclHandler = handler; -} - -int XMLCALL -XML_SetParamEntityParsing(XML_Parser parser, - enum XML_ParamEntityParsing peParsing) -{ - /* block after XML_Parse()/XML_ParseBuffer() has been called */ - if (ps_parsing == XML_PARSING || ps_parsing == XML_SUSPENDED) - return 0; -#ifdef XML_DTD - paramEntityParsing = peParsing; - return 1; -#else - return peParsing == XML_PARAM_ENTITY_PARSING_NEVER; -#endif -} - -int XMLCALL -XML_SetHashSalt(XML_Parser parser, - unsigned long hash_salt) -{ - /* block after XML_Parse()/XML_ParseBuffer() has been called */ - if (ps_parsing == XML_PARSING || ps_parsing == XML_SUSPENDED) - return 0; - hash_secret_salt = hash_salt; - return 1; -} - -enum XML_Status XMLCALL -XML_Parse(XML_Parser parser, const char *s, int len, int isFinal) -{ - switch (ps_parsing) { - case XML_SUSPENDED: - errorCode = XML_ERROR_SUSPENDED; - return XML_STATUS_ERROR; - case XML_FINISHED: - errorCode = XML_ERROR_FINISHED; - return XML_STATUS_ERROR; - case XML_INITIALIZED: - if (parentParser == NULL && !startParsing(parser)) { - errorCode = XML_ERROR_NO_MEMORY; - return XML_STATUS_ERROR; - } - default: - ps_parsing = XML_PARSING; - } - - if (len == 0) { - ps_finalBuffer = (XML_Bool)isFinal; - if (!isFinal) - return XML_STATUS_OK; - positionPtr = bufferPtr; - parseEndPtr = bufferEnd; - - /* If data are left over from last buffer, and we now know that these - data are the final chunk of input, then we have to check them again - to detect errors based on that fact. - */ - errorCode = processor(parser, bufferPtr, parseEndPtr, &bufferPtr); - - if (errorCode == XML_ERROR_NONE) { - switch (ps_parsing) { - case XML_SUSPENDED: - XmlUpdatePosition(encoding, positionPtr, bufferPtr, &position); - positionPtr = bufferPtr; - return XML_STATUS_SUSPENDED; - case XML_INITIALIZED: - case XML_PARSING: - ps_parsing = XML_FINISHED; - /* fall through */ - default: - return XML_STATUS_OK; - } - } - eventEndPtr = eventPtr; - processor = errorProcessor; - return XML_STATUS_ERROR; - } -#ifndef XML_CONTEXT_BYTES - else if (bufferPtr == bufferEnd) { - const char *end; - int nLeftOver; - enum XML_Error result; - parseEndByteIndex += len; - positionPtr = s; - ps_finalBuffer = (XML_Bool)isFinal; - - errorCode = processor(parser, s, parseEndPtr = s + len, &end); - - if (errorCode != XML_ERROR_NONE) { - eventEndPtr = eventPtr; - processor = errorProcessor; - return XML_STATUS_ERROR; - } - else { - switch (ps_parsing) { - case XML_SUSPENDED: - result = XML_STATUS_SUSPENDED; - break; - case XML_INITIALIZED: - case XML_PARSING: - if (isFinal) { - ps_parsing = XML_FINISHED; - return XML_STATUS_OK; - } - /* fall through */ - default: - result = XML_STATUS_OK; - } - } - - XmlUpdatePosition(encoding, positionPtr, end, &position); - nLeftOver = s + len - end; - if (nLeftOver) { - if (buffer == NULL || nLeftOver > bufferLim - buffer) { - /* FIXME avoid integer overflow */ - char *temp; - temp = (buffer == NULL - ? (char *)MALLOC(len * 2) - : (char *)REALLOC(buffer, len * 2)); - if (temp == NULL) { - errorCode = XML_ERROR_NO_MEMORY; - eventPtr = eventEndPtr = NULL; - processor = errorProcessor; - return XML_STATUS_ERROR; - } - buffer = temp; - bufferLim = buffer + len * 2; - } - memcpy(buffer, end, nLeftOver); - } - bufferPtr = buffer; - bufferEnd = buffer + nLeftOver; - positionPtr = bufferPtr; - parseEndPtr = bufferEnd; - eventPtr = bufferPtr; - eventEndPtr = bufferPtr; - return result; - } -#endif /* not defined XML_CONTEXT_BYTES */ - else { - void *buff = XML_GetBuffer(parser, len); - if (buff == NULL) - return XML_STATUS_ERROR; - else { - memcpy(buff, s, len); - return XML_ParseBuffer(parser, len, isFinal); - } - } -} - -enum XML_Status XMLCALL -XML_ParseBuffer(XML_Parser parser, int len, int isFinal) -{ - const char *start; - enum XML_Status result = XML_STATUS_OK; - - switch (ps_parsing) { - case XML_SUSPENDED: - errorCode = XML_ERROR_SUSPENDED; - return XML_STATUS_ERROR; - case XML_FINISHED: - errorCode = XML_ERROR_FINISHED; - return XML_STATUS_ERROR; - case XML_INITIALIZED: - if (parentParser == NULL && !startParsing(parser)) { - errorCode = XML_ERROR_NO_MEMORY; - return XML_STATUS_ERROR; - } - default: - ps_parsing = XML_PARSING; - } - - start = bufferPtr; - positionPtr = start; - bufferEnd += len; - parseEndPtr = bufferEnd; - parseEndByteIndex += len; - ps_finalBuffer = (XML_Bool)isFinal; - - errorCode = processor(parser, start, parseEndPtr, &bufferPtr); - - if (errorCode != XML_ERROR_NONE) { - eventEndPtr = eventPtr; - processor = errorProcessor; - return XML_STATUS_ERROR; - } - else { - switch (ps_parsing) { - case XML_SUSPENDED: - result = XML_STATUS_SUSPENDED; - break; - case XML_INITIALIZED: - case XML_PARSING: - if (isFinal) { - ps_parsing = XML_FINISHED; - return result; - } - default: ; /* should not happen */ - } - } - - XmlUpdatePosition(encoding, positionPtr, bufferPtr, &position); - positionPtr = bufferPtr; - return result; -} - -void * XMLCALL -XML_GetBuffer(XML_Parser parser, int len) -{ - switch (ps_parsing) { - case XML_SUSPENDED: - errorCode = XML_ERROR_SUSPENDED; - return NULL; - case XML_FINISHED: - errorCode = XML_ERROR_FINISHED; - return NULL; - default: ; - } - - if (len > bufferLim - bufferEnd) { - /* FIXME avoid integer overflow */ - int neededSize = len + (int)(bufferEnd - bufferPtr); -#ifdef XML_CONTEXT_BYTES - int keep = (int)(bufferPtr - buffer); - - if (keep > XML_CONTEXT_BYTES) - keep = XML_CONTEXT_BYTES; - neededSize += keep; -#endif /* defined XML_CONTEXT_BYTES */ - if (neededSize <= bufferLim - buffer) { -#ifdef XML_CONTEXT_BYTES - if (keep < bufferPtr - buffer) { - int offset = (int)(bufferPtr - buffer) - keep; - memmove(buffer, &buffer[offset], bufferEnd - bufferPtr + keep); - bufferEnd -= offset; - bufferPtr -= offset; - } -#else - memmove(buffer, bufferPtr, bufferEnd - bufferPtr); - bufferEnd = buffer + (bufferEnd - bufferPtr); - bufferPtr = buffer; -#endif /* not defined XML_CONTEXT_BYTES */ - } - else { - char *newBuf; - int bufferSize = (int)(bufferLim - bufferPtr); - if (bufferSize == 0) - bufferSize = INIT_BUFFER_SIZE; - do { - bufferSize *= 2; - } while (bufferSize < neededSize); - newBuf = (char *)MALLOC(bufferSize); - if (newBuf == 0) { - errorCode = XML_ERROR_NO_MEMORY; - return NULL; - } - bufferLim = newBuf + bufferSize; -#ifdef XML_CONTEXT_BYTES - if (bufferPtr) { - int keep = (int)(bufferPtr - buffer); - if (keep > XML_CONTEXT_BYTES) - keep = XML_CONTEXT_BYTES; - memcpy(newBuf, &bufferPtr[-keep], bufferEnd - bufferPtr + keep); - FREE(buffer); - buffer = newBuf; - bufferEnd = buffer + (bufferEnd - bufferPtr) + keep; - bufferPtr = buffer + keep; - } - else { - bufferEnd = newBuf + (bufferEnd - bufferPtr); - bufferPtr = buffer = newBuf; - } -#else - if (bufferPtr) { - memcpy(newBuf, bufferPtr, bufferEnd - bufferPtr); - FREE(buffer); - } - bufferEnd = newBuf + (bufferEnd - bufferPtr); - bufferPtr = buffer = newBuf; -#endif /* not defined XML_CONTEXT_BYTES */ - } - eventPtr = eventEndPtr = NULL; - positionPtr = NULL; - } - return bufferEnd; -} - -enum XML_Status XMLCALL -XML_StopParser(XML_Parser parser, XML_Bool resumable) -{ - switch (ps_parsing) { - case XML_SUSPENDED: - if (resumable) { - errorCode = XML_ERROR_SUSPENDED; - return XML_STATUS_ERROR; - } - ps_parsing = XML_FINISHED; - break; - case XML_FINISHED: - errorCode = XML_ERROR_FINISHED; - return XML_STATUS_ERROR; - default: - if (resumable) { -#ifdef XML_DTD - if (isParamEntity) { - errorCode = XML_ERROR_SUSPEND_PE; - return XML_STATUS_ERROR; - } -#endif - ps_parsing = XML_SUSPENDED; - } - else - ps_parsing = XML_FINISHED; - } - return XML_STATUS_OK; -} - -enum XML_Status XMLCALL -XML_ResumeParser(XML_Parser parser) -{ - enum XML_Status result = XML_STATUS_OK; - - if (ps_parsing != XML_SUSPENDED) { - errorCode = XML_ERROR_NOT_SUSPENDED; - return XML_STATUS_ERROR; - } - ps_parsing = XML_PARSING; - - errorCode = processor(parser, bufferPtr, parseEndPtr, &bufferPtr); - - if (errorCode != XML_ERROR_NONE) { - eventEndPtr = eventPtr; - processor = errorProcessor; - return XML_STATUS_ERROR; - } - else { - switch (ps_parsing) { - case XML_SUSPENDED: - result = XML_STATUS_SUSPENDED; - break; - case XML_INITIALIZED: - case XML_PARSING: - if (ps_finalBuffer) { - ps_parsing = XML_FINISHED; - return result; - } - default: ; - } - } - - XmlUpdatePosition(encoding, positionPtr, bufferPtr, &position); - positionPtr = bufferPtr; - return result; -} - -void XMLCALL -XML_GetParsingStatus(XML_Parser parser, XML_ParsingStatus *status) -{ - assert(status != NULL); - *status = parser->m_parsingStatus; -} - -enum XML_Error XMLCALL -XML_GetErrorCode(XML_Parser parser) -{ - return errorCode; -} - -XML_Index XMLCALL -XML_GetCurrentByteIndex(XML_Parser parser) -{ - if (eventPtr) - return parseEndByteIndex - (parseEndPtr - eventPtr); - return -1; -} - -int XMLCALL -XML_GetCurrentByteCount(XML_Parser parser) -{ - if (eventEndPtr && eventPtr) - return (int)(eventEndPtr - eventPtr); - return 0; -} - -const char * XMLCALL -XML_GetInputContext(XML_Parser parser, int *offset, int *size) -{ -#ifdef XML_CONTEXT_BYTES - if (eventPtr && buffer) { - *offset = (int)(eventPtr - buffer); - *size = (int)(bufferEnd - buffer); - return buffer; - } -#endif /* defined XML_CONTEXT_BYTES */ - return (char *) 0; -} - -XML_Size XMLCALL -XML_GetCurrentLineNumber(XML_Parser parser) -{ - if (eventPtr && eventPtr >= positionPtr) { - XmlUpdatePosition(encoding, positionPtr, eventPtr, &position); - positionPtr = eventPtr; - } - return position.lineNumber + 1; -} - -XML_Size XMLCALL -XML_GetCurrentColumnNumber(XML_Parser parser) -{ - if (eventPtr && eventPtr >= positionPtr) { - XmlUpdatePosition(encoding, positionPtr, eventPtr, &position); - positionPtr = eventPtr; - } - return position.columnNumber; -} - -void XMLCALL -XML_FreeContentModel(XML_Parser parser, XML_Content *model) -{ - FREE(model); -} - -void * XMLCALL -XML_MemMalloc(XML_Parser parser, size_t size) -{ - return MALLOC(size); -} - -void * XMLCALL -XML_MemRealloc(XML_Parser parser, void *ptr, size_t size) -{ - return REALLOC(ptr, size); -} - -void XMLCALL -XML_MemFree(XML_Parser parser, void *ptr) -{ - FREE(ptr); -} - -void XMLCALL -XML_DefaultCurrent(XML_Parser parser) -{ - if (defaultHandler) { - if (openInternalEntities) - reportDefault(parser, - internalEncoding, - openInternalEntities->internalEventPtr, - openInternalEntities->internalEventEndPtr); - else - reportDefault(parser, encoding, eventPtr, eventEndPtr); - } -} - -const XML_LChar * XMLCALL -XML_ErrorString(enum XML_Error code) -{ - static const XML_LChar* const message[] = { - 0, - XML_L("out of memory"), - XML_L("syntax error"), - XML_L("no element found"), - XML_L("not well-formed (invalid token)"), - XML_L("unclosed token"), - XML_L("partial character"), - XML_L("mismatched tag"), - XML_L("duplicate attribute"), - XML_L("junk after document element"), - XML_L("illegal parameter entity reference"), - XML_L("undefined entity"), - XML_L("recursive entity reference"), - XML_L("asynchronous entity"), - XML_L("reference to invalid character number"), - XML_L("reference to binary entity"), - XML_L("reference to external entity in attribute"), - XML_L("XML or text declaration not at start of entity"), - XML_L("unknown encoding"), - XML_L("encoding specified in XML declaration is incorrect"), - XML_L("unclosed CDATA section"), - XML_L("error in processing external entity reference"), - XML_L("document is not standalone"), - XML_L("unexpected parser state - please send a bug report"), - XML_L("entity declared in parameter entity"), - XML_L("requested feature requires XML_DTD support in Expat"), - XML_L("cannot change setting once parsing has begun"), - XML_L("unbound prefix"), - XML_L("must not undeclare prefix"), - XML_L("incomplete markup in parameter entity"), - XML_L("XML declaration not well-formed"), - XML_L("text declaration not well-formed"), - XML_L("illegal character(s) in public id"), - XML_L("parser suspended"), - XML_L("parser not suspended"), - XML_L("parsing aborted"), - XML_L("parsing finished"), - XML_L("cannot suspend in external parameter entity"), - XML_L("reserved prefix (xml) must not be undeclared or bound to another namespace name"), - XML_L("reserved prefix (xmlns) must not be declared or undeclared"), - XML_L("prefix must not be bound to one of the reserved namespace names") - }; - if (code > 0 && code < sizeof(message)/sizeof(message[0])) - return message[code]; - return NULL; -} - -const XML_LChar * XMLCALL -XML_ExpatVersion(void) { - - /* V1 is used to string-ize the version number. However, it would - string-ize the actual version macro *names* unless we get them - substituted before being passed to V1. CPP is defined to expand - a macro, then rescan for more expansions. Thus, we use V2 to expand - the version macros, then CPP will expand the resulting V1() macro - with the correct numerals. */ - /* ### I'm assuming cpp is portable in this respect... */ - -#define V1(a,b,c) XML_L(#a)XML_L(".")XML_L(#b)XML_L(".")XML_L(#c) -#define V2(a,b,c) XML_L("expat_")V1(a,b,c) - - return V2(XML_MAJOR_VERSION, XML_MINOR_VERSION, XML_MICRO_VERSION); - -#undef V1 -#undef V2 -} - -XML_Expat_Version XMLCALL -XML_ExpatVersionInfo(void) -{ - XML_Expat_Version version; - - version.major = XML_MAJOR_VERSION; - version.minor = XML_MINOR_VERSION; - version.micro = XML_MICRO_VERSION; - - return version; -} - -const XML_Feature * XMLCALL -XML_GetFeatureList(void) -{ - static const XML_Feature features[] = { - {XML_FEATURE_SIZEOF_XML_CHAR, XML_L("sizeof(XML_Char)"), - sizeof(XML_Char)}, - {XML_FEATURE_SIZEOF_XML_LCHAR, XML_L("sizeof(XML_LChar)"), - sizeof(XML_LChar)}, -#ifdef XML_UNICODE - {XML_FEATURE_UNICODE, XML_L("XML_UNICODE"), 0}, -#endif -#ifdef XML_UNICODE_WCHAR_T - {XML_FEATURE_UNICODE_WCHAR_T, XML_L("XML_UNICODE_WCHAR_T"), 0}, -#endif -#ifdef XML_DTD - {XML_FEATURE_DTD, XML_L("XML_DTD"), 0}, -#endif -#ifdef XML_CONTEXT_BYTES - {XML_FEATURE_CONTEXT_BYTES, XML_L("XML_CONTEXT_BYTES"), - XML_CONTEXT_BYTES}, -#endif -#ifdef XML_MIN_SIZE - {XML_FEATURE_MIN_SIZE, XML_L("XML_MIN_SIZE"), 0}, -#endif -#ifdef XML_NS - {XML_FEATURE_NS, XML_L("XML_NS"), 0}, -#endif -#ifdef XML_LARGE_SIZE - {XML_FEATURE_LARGE_SIZE, XML_L("XML_LARGE_SIZE"), 0}, -#endif -#ifdef XML_ATTR_INFO - {XML_FEATURE_ATTR_INFO, XML_L("XML_ATTR_INFO"), 0}, -#endif - {XML_FEATURE_END, NULL, 0} - }; - - return features; -} - -/* Initially tag->rawName always points into the parse buffer; - for those TAG instances opened while the current parse buffer was - processed, and not yet closed, we need to store tag->rawName in a more - permanent location, since the parse buffer is about to be discarded. -*/ -static XML_Bool -storeRawNames(XML_Parser parser) -{ - TAG *tag = tagStack; - while (tag) { - int bufSize; - int nameLen = sizeof(XML_Char) * (tag->name.strLen + 1); - char *rawNameBuf = tag->buf + nameLen; - /* Stop if already stored. Since tagStack is a stack, we can stop - at the first entry that has already been copied; everything - below it in the stack is already been accounted for in a - previous call to this function. - */ - if (tag->rawName == rawNameBuf) - break; - /* For re-use purposes we need to ensure that the - size of tag->buf is a multiple of sizeof(XML_Char). - */ - bufSize = nameLen + ROUND_UP(tag->rawNameLength, sizeof(XML_Char)); - if (bufSize > tag->bufEnd - tag->buf) { - char *temp = (char *)REALLOC(tag->buf, bufSize); - if (temp == NULL) - return XML_FALSE; - /* if tag->name.str points to tag->buf (only when namespace - processing is off) then we have to update it - */ - if (tag->name.str == (XML_Char *)tag->buf) - tag->name.str = (XML_Char *)temp; - /* if tag->name.localPart is set (when namespace processing is on) - then update it as well, since it will always point into tag->buf - */ - if (tag->name.localPart) - tag->name.localPart = (XML_Char *)temp + (tag->name.localPart - - (XML_Char *)tag->buf); - tag->buf = temp; - tag->bufEnd = temp + bufSize; - rawNameBuf = temp + nameLen; - } - memcpy(rawNameBuf, tag->rawName, tag->rawNameLength); - tag->rawName = rawNameBuf; - tag = tag->parent; - } - return XML_TRUE; -} - -static enum XML_Error PTRCALL -contentProcessor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - enum XML_Error result = doContent(parser, 0, encoding, start, end, - endPtr, (XML_Bool)!ps_finalBuffer); - if (result == XML_ERROR_NONE) { - if (!storeRawNames(parser)) - return XML_ERROR_NO_MEMORY; - } - return result; -} - -static enum XML_Error PTRCALL -externalEntityInitProcessor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - enum XML_Error result = initializeEncoding(parser); - if (result != XML_ERROR_NONE) - return result; - processor = externalEntityInitProcessor2; - return externalEntityInitProcessor2(parser, start, end, endPtr); -} - -static enum XML_Error PTRCALL -externalEntityInitProcessor2(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - const char *next = start; /* XmlContentTok doesn't always set the last arg */ - int tok = XmlContentTok(encoding, start, end, &next); - switch (tok) { - case XML_TOK_BOM: - /* If we are at the end of the buffer, this would cause the next stage, - i.e. externalEntityInitProcessor3, to pass control directly to - doContent (by detecting XML_TOK_NONE) without processing any xml text - declaration - causing the error XML_ERROR_MISPLACED_XML_PI in doContent. - */ - if (next == end && !ps_finalBuffer) { - *endPtr = next; - return XML_ERROR_NONE; - } - start = next; - break; - case XML_TOK_PARTIAL: - if (!ps_finalBuffer) { - *endPtr = start; - return XML_ERROR_NONE; - } - eventPtr = start; - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (!ps_finalBuffer) { - *endPtr = start; - return XML_ERROR_NONE; - } - eventPtr = start; - return XML_ERROR_PARTIAL_CHAR; - } - processor = externalEntityInitProcessor3; - return externalEntityInitProcessor3(parser, start, end, endPtr); -} - -static enum XML_Error PTRCALL -externalEntityInitProcessor3(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - int tok; - const char *next = start; /* XmlContentTok doesn't always set the last arg */ - eventPtr = start; - tok = XmlContentTok(encoding, start, end, &next); - eventEndPtr = next; - - switch (tok) { - case XML_TOK_XML_DECL: - { - enum XML_Error result; - result = processXmlDecl(parser, 1, start, next); - if (result != XML_ERROR_NONE) - return result; - switch (ps_parsing) { - case XML_SUSPENDED: - *endPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: - start = next; - } - } - break; - case XML_TOK_PARTIAL: - if (!ps_finalBuffer) { - *endPtr = start; - return XML_ERROR_NONE; - } - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (!ps_finalBuffer) { - *endPtr = start; - return XML_ERROR_NONE; - } - return XML_ERROR_PARTIAL_CHAR; - } - processor = externalEntityContentProcessor; - tagLevel = 1; - return externalEntityContentProcessor(parser, start, end, endPtr); -} - -static enum XML_Error PTRCALL -externalEntityContentProcessor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - enum XML_Error result = doContent(parser, 1, encoding, start, end, - endPtr, (XML_Bool)!ps_finalBuffer); - if (result == XML_ERROR_NONE) { - if (!storeRawNames(parser)) - return XML_ERROR_NO_MEMORY; - } - return result; -} - -static enum XML_Error -doContent(XML_Parser parser, - int startTagLevel, - const ENCODING *enc, - const char *s, - const char *end, - const char **nextPtr, - XML_Bool haveMore) -{ - /* save one level of indirection */ - DTD * const dtd = _dtd; - - const char **eventPP; - const char **eventEndPP; - if (enc == encoding) { - eventPP = &eventPtr; - eventEndPP = &eventEndPtr; - } - else { - eventPP = &(openInternalEntities->internalEventPtr); - eventEndPP = &(openInternalEntities->internalEventEndPtr); - } - *eventPP = s; - - for (;;) { - const char *next = s; /* XmlContentTok doesn't always set the last arg */ - int tok = XmlContentTok(enc, s, end, &next); - *eventEndPP = next; - switch (tok) { - case XML_TOK_TRAILING_CR: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - *eventEndPP = end; - if (characterDataHandler) { - XML_Char c = 0xA; - characterDataHandler(handlerArg, &c, 1); - } - else if (defaultHandler) - reportDefault(parser, enc, s, end); - /* We are at the end of the final buffer, should we check for - XML_SUSPENDED, XML_FINISHED? - */ - if (startTagLevel == 0) - return XML_ERROR_NO_ELEMENTS; - if (tagLevel != startTagLevel) - return XML_ERROR_ASYNC_ENTITY; - *nextPtr = end; - return XML_ERROR_NONE; - case XML_TOK_NONE: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - if (startTagLevel > 0) { - if (tagLevel != startTagLevel) - return XML_ERROR_ASYNC_ENTITY; - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_NO_ELEMENTS; - case XML_TOK_INVALID: - *eventPP = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_ENTITY_REF: - { - const XML_Char *name; - ENTITY *entity; - XML_Char ch = (XML_Char) XmlPredefinedEntityName(enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (ch) { - if (characterDataHandler) - characterDataHandler(handlerArg, &ch, 1); - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - } - name = poolStoreString(&dtd->pool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!name) - return XML_ERROR_NO_MEMORY; - entity = (ENTITY *)lookup(parser, &dtd->generalEntities, name, 0); - poolDiscard(&dtd->pool); - /* First, determine if a check for an existing declaration is needed; - if yes, check that the entity exists, and that it is internal, - otherwise call the skipped entity or default handler. - */ - if (!dtd->hasParamEntityRefs || dtd->standalone) { - if (!entity) - return XML_ERROR_UNDEFINED_ENTITY; - else if (!entity->is_internal) - return XML_ERROR_ENTITY_DECLARED_IN_PE; - } - else if (!entity) { - if (skippedEntityHandler) - skippedEntityHandler(handlerArg, name, 0); - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - } - if (entity->open) - return XML_ERROR_RECURSIVE_ENTITY_REF; - if (entity->notation) - return XML_ERROR_BINARY_ENTITY_REF; - if (entity->textPtr) { - enum XML_Error result; - if (!defaultExpandInternalEntities) { - if (skippedEntityHandler) - skippedEntityHandler(handlerArg, entity->name, 0); - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - } - result = processInternalEntity(parser, entity, XML_FALSE); - if (result != XML_ERROR_NONE) - return result; - } - else if (externalEntityRefHandler) { - const XML_Char *context; - entity->open = XML_TRUE; - context = getContext(parser); - entity->open = XML_FALSE; - if (!context) - return XML_ERROR_NO_MEMORY; - if (!externalEntityRefHandler(externalEntityRefHandlerArg, - context, - entity->base, - entity->systemId, - entity->publicId)) - return XML_ERROR_EXTERNAL_ENTITY_HANDLING; - poolDiscard(&tempPool); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - } - case XML_TOK_START_TAG_NO_ATTS: - /* fall through */ - case XML_TOK_START_TAG_WITH_ATTS: - { - TAG *tag; - enum XML_Error result; - XML_Char *toPtr; - if (freeTagList) { - tag = freeTagList; - freeTagList = freeTagList->parent; - } - else { - tag = (TAG *)MALLOC(sizeof(TAG)); - if (!tag) - return XML_ERROR_NO_MEMORY; - tag->buf = (char *)MALLOC(INIT_TAG_BUF_SIZE); - if (!tag->buf) { - FREE(tag); - return XML_ERROR_NO_MEMORY; - } - tag->bufEnd = tag->buf + INIT_TAG_BUF_SIZE; - } - tag->bindings = NULL; - tag->parent = tagStack; - tagStack = tag; - tag->name.localPart = NULL; - tag->name.prefix = NULL; - tag->rawName = s + enc->minBytesPerChar; - tag->rawNameLength = XmlNameLength(enc, tag->rawName); - ++tagLevel; - { - const char *rawNameEnd = tag->rawName + tag->rawNameLength; - const char *fromPtr = tag->rawName; - toPtr = (XML_Char *)tag->buf; - for (;;) { - int bufSize; - int convLen; - XmlConvert(enc, - &fromPtr, rawNameEnd, - (ICHAR **)&toPtr, (ICHAR *)tag->bufEnd - 1); - convLen = (int)(toPtr - (XML_Char *)tag->buf); - if (fromPtr == rawNameEnd) { - tag->name.strLen = convLen; - break; - } - bufSize = (int)(tag->bufEnd - tag->buf) << 1; - { - char *temp = (char *)REALLOC(tag->buf, bufSize); - if (temp == NULL) - return XML_ERROR_NO_MEMORY; - tag->buf = temp; - tag->bufEnd = temp + bufSize; - toPtr = (XML_Char *)temp + convLen; - } - } - } - tag->name.str = (XML_Char *)tag->buf; - *toPtr = XML_T('\0'); - result = storeAtts(parser, enc, s, &(tag->name), &(tag->bindings)); - if (result) - return result; - if (startElementHandler) - startElementHandler(handlerArg, tag->name.str, - (const XML_Char **)atts); - else if (defaultHandler) - reportDefault(parser, enc, s, next); - poolClear(&tempPool); - break; - } - case XML_TOK_EMPTY_ELEMENT_NO_ATTS: - /* fall through */ - case XML_TOK_EMPTY_ELEMENT_WITH_ATTS: - { - const char *rawName = s + enc->minBytesPerChar; - enum XML_Error result; - BINDING *bindings = NULL; - XML_Bool noElmHandlers = XML_TRUE; - TAG_NAME name; - name.str = poolStoreString(&tempPool, enc, rawName, - rawName + XmlNameLength(enc, rawName)); - if (!name.str) - return XML_ERROR_NO_MEMORY; - poolFinish(&tempPool); - result = storeAtts(parser, enc, s, &name, &bindings); - if (result) - return result; - poolFinish(&tempPool); - if (startElementHandler) { - startElementHandler(handlerArg, name.str, (const XML_Char **)atts); - noElmHandlers = XML_FALSE; - } - if (endElementHandler) { - if (startElementHandler) - *eventPP = *eventEndPP; - endElementHandler(handlerArg, name.str); - noElmHandlers = XML_FALSE; - } - if (noElmHandlers && defaultHandler) - reportDefault(parser, enc, s, next); - poolClear(&tempPool); - while (bindings) { - BINDING *b = bindings; - if (endNamespaceDeclHandler) - endNamespaceDeclHandler(handlerArg, b->prefix->name); - bindings = bindings->nextTagBinding; - b->nextTagBinding = freeBindingList; - freeBindingList = b; - b->prefix->binding = b->prevPrefixBinding; - } - } - if (tagLevel == 0) - return epilogProcessor(parser, next, end, nextPtr); - break; - case XML_TOK_END_TAG: - if (tagLevel == startTagLevel) - return XML_ERROR_ASYNC_ENTITY; - else { - int len; - const char *rawName; - TAG *tag = tagStack; - tagStack = tag->parent; - tag->parent = freeTagList; - freeTagList = tag; - rawName = s + enc->minBytesPerChar*2; - len = XmlNameLength(enc, rawName); - if (len != tag->rawNameLength - || memcmp(tag->rawName, rawName, len) != 0) { - *eventPP = rawName; - return XML_ERROR_TAG_MISMATCH; - } - --tagLevel; - if (endElementHandler) { - const XML_Char *localPart; - const XML_Char *prefix; - XML_Char *uri; - localPart = tag->name.localPart; - if (ns && localPart) { - /* localPart and prefix may have been overwritten in - tag->name.str, since this points to the binding->uri - buffer which gets re-used; so we have to add them again - */ - uri = (XML_Char *)tag->name.str + tag->name.uriLen; - /* don't need to check for space - already done in storeAtts() */ - while (*localPart) *uri++ = *localPart++; - prefix = (XML_Char *)tag->name.prefix; - if (ns_triplets && prefix) { - *uri++ = namespaceSeparator; - while (*prefix) *uri++ = *prefix++; - } - *uri = XML_T('\0'); - } - endElementHandler(handlerArg, tag->name.str); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - while (tag->bindings) { - BINDING *b = tag->bindings; - if (endNamespaceDeclHandler) - endNamespaceDeclHandler(handlerArg, b->prefix->name); - tag->bindings = tag->bindings->nextTagBinding; - b->nextTagBinding = freeBindingList; - freeBindingList = b; - b->prefix->binding = b->prevPrefixBinding; - } - if (tagLevel == 0) - return epilogProcessor(parser, next, end, nextPtr); - } - break; - case XML_TOK_CHAR_REF: - { - int n = XmlCharRefNumber(enc, s); - if (n < 0) - return XML_ERROR_BAD_CHAR_REF; - if (characterDataHandler) { - XML_Char buf[XML_ENCODE_MAX]; - characterDataHandler(handlerArg, buf, XmlEncode(n, (ICHAR *)buf)); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - } - break; - case XML_TOK_XML_DECL: - return XML_ERROR_MISPLACED_XML_PI; - case XML_TOK_DATA_NEWLINE: - if (characterDataHandler) { - XML_Char c = 0xA; - characterDataHandler(handlerArg, &c, 1); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - case XML_TOK_CDATA_SECT_OPEN: - { - enum XML_Error result; - if (startCdataSectionHandler) - startCdataSectionHandler(handlerArg); -#if 0 - /* Suppose you doing a transformation on a document that involves - changing only the character data. You set up a defaultHandler - and a characterDataHandler. The defaultHandler simply copies - characters through. The characterDataHandler does the - transformation and writes the characters out escaping them as - necessary. This case will fail to work if we leave out the - following two lines (because & and < inside CDATA sections will - be incorrectly escaped). - - However, now we have a start/endCdataSectionHandler, so it seems - easier to let the user deal with this. - */ - else if (characterDataHandler) - characterDataHandler(handlerArg, dataBuf, 0); -#endif - else if (defaultHandler) - reportDefault(parser, enc, s, next); - result = doCdataSection(parser, enc, &next, end, nextPtr, haveMore); - if (result != XML_ERROR_NONE) - return result; - else if (!next) { - processor = cdataSectionProcessor; - return result; - } - } - break; - case XML_TOK_TRAILING_RSQB: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - if (characterDataHandler) { - if (MUST_CONVERT(enc, s)) { - ICHAR *dataPtr = (ICHAR *)dataBuf; - XmlConvert(enc, &s, end, &dataPtr, (ICHAR *)dataBufEnd); - characterDataHandler(handlerArg, dataBuf, - (int)(dataPtr - (ICHAR *)dataBuf)); - } - else - characterDataHandler(handlerArg, - (XML_Char *)s, - (int)((XML_Char *)end - (XML_Char *)s)); - } - else if (defaultHandler) - reportDefault(parser, enc, s, end); - /* We are at the end of the final buffer, should we check for - XML_SUSPENDED, XML_FINISHED? - */ - if (startTagLevel == 0) { - *eventPP = end; - return XML_ERROR_NO_ELEMENTS; - } - if (tagLevel != startTagLevel) { - *eventPP = end; - return XML_ERROR_ASYNC_ENTITY; - } - *nextPtr = end; - return XML_ERROR_NONE; - case XML_TOK_DATA_CHARS: - { - XML_CharacterDataHandler charDataHandler = characterDataHandler; - if (charDataHandler) { - if (MUST_CONVERT(enc, s)) { - for (;;) { - ICHAR *dataPtr = (ICHAR *)dataBuf; - XmlConvert(enc, &s, next, &dataPtr, (ICHAR *)dataBufEnd); - *eventEndPP = s; - charDataHandler(handlerArg, dataBuf, - (int)(dataPtr - (ICHAR *)dataBuf)); - if (s == next) - break; - *eventPP = s; - } - } - else - charDataHandler(handlerArg, - (XML_Char *)s, - (int)((XML_Char *)next - (XML_Char *)s)); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - } - break; - case XML_TOK_PI: - if (!reportProcessingInstruction(parser, enc, s, next)) - return XML_ERROR_NO_MEMORY; - break; - case XML_TOK_COMMENT: - if (!reportComment(parser, enc, s, next)) - return XML_ERROR_NO_MEMORY; - break; - default: - if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - } - *eventPP = s = next; - switch (ps_parsing) { - case XML_SUSPENDED: - *nextPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: ; - } - } - /* not reached */ -} - -/* Precondition: all arguments must be non-NULL; - Purpose: - - normalize attributes - - check attributes for well-formedness - - generate namespace aware attribute names (URI, prefix) - - build list of attributes for startElementHandler - - default attributes - - process namespace declarations (check and report them) - - generate namespace aware element name (URI, prefix) -*/ -static enum XML_Error -storeAtts(XML_Parser parser, const ENCODING *enc, - const char *attStr, TAG_NAME *tagNamePtr, - BINDING **bindingsPtr) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - ELEMENT_TYPE *elementType; - int nDefaultAtts; - const XML_Char **appAtts; /* the attribute list for the application */ - int attIndex = 0; - int prefixLen; - int i; - int n; - XML_Char *uri; - int nPrefixes = 0; - BINDING *binding; - const XML_Char *localPart; - - /* lookup the element type name */ - elementType = (ELEMENT_TYPE *)lookup(parser, &dtd->elementTypes, tagNamePtr->str,0); - if (!elementType) { - const XML_Char *name = poolCopyString(&dtd->pool, tagNamePtr->str); - if (!name) - return XML_ERROR_NO_MEMORY; - elementType = (ELEMENT_TYPE *)lookup(parser, &dtd->elementTypes, name, - sizeof(ELEMENT_TYPE)); - if (!elementType) - return XML_ERROR_NO_MEMORY; - if (ns && !setElementTypePrefix(parser, elementType)) - return XML_ERROR_NO_MEMORY; - } - nDefaultAtts = elementType->nDefaultAtts; - - /* get the attributes from the tokenizer */ - n = XmlGetAttributes(enc, attStr, attsSize, atts); - if (n + nDefaultAtts > attsSize) { - int oldAttsSize = attsSize; - ATTRIBUTE *temp; -#ifdef XML_ATTR_INFO - XML_AttrInfo *temp2; -#endif - attsSize = n + nDefaultAtts + INIT_ATTS_SIZE; - temp = (ATTRIBUTE *)REALLOC((void *)atts, attsSize * sizeof(ATTRIBUTE)); - if (temp == NULL) - return XML_ERROR_NO_MEMORY; - atts = temp; -#ifdef XML_ATTR_INFO - temp2 = (XML_AttrInfo *)REALLOC((void *)attInfo, attsSize * sizeof(XML_AttrInfo)); - if (temp2 == NULL) - return XML_ERROR_NO_MEMORY; - attInfo = temp2; -#endif - if (n > oldAttsSize) - XmlGetAttributes(enc, attStr, n, atts); - } - - appAtts = (const XML_Char **)atts; - for (i = 0; i < n; i++) { - ATTRIBUTE *currAtt = &atts[i]; -#ifdef XML_ATTR_INFO - XML_AttrInfo *currAttInfo = &attInfo[i]; -#endif - /* add the name and value to the attribute list */ - ATTRIBUTE_ID *attId = getAttributeId(parser, enc, currAtt->name, - currAtt->name - + XmlNameLength(enc, currAtt->name)); - if (!attId) - return XML_ERROR_NO_MEMORY; -#ifdef XML_ATTR_INFO - currAttInfo->nameStart = parseEndByteIndex - (parseEndPtr - currAtt->name); - currAttInfo->nameEnd = currAttInfo->nameStart + - XmlNameLength(enc, currAtt->name); - currAttInfo->valueStart = parseEndByteIndex - - (parseEndPtr - currAtt->valuePtr); - currAttInfo->valueEnd = parseEndByteIndex - (parseEndPtr - currAtt->valueEnd); -#endif - /* Detect duplicate attributes by their QNames. This does not work when - namespace processing is turned on and different prefixes for the same - namespace are used. For this case we have a check further down. - */ - if ((attId->name)[-1]) { - if (enc == encoding) - eventPtr = atts[i].name; - return XML_ERROR_DUPLICATE_ATTRIBUTE; - } - (attId->name)[-1] = 1; - appAtts[attIndex++] = attId->name; - if (!atts[i].normalized) { - enum XML_Error result; - XML_Bool isCdata = XML_TRUE; - - /* figure out whether declared as other than CDATA */ - if (attId->maybeTokenized) { - int j; - for (j = 0; j < nDefaultAtts; j++) { - if (attId == elementType->defaultAtts[j].id) { - isCdata = elementType->defaultAtts[j].isCdata; - break; - } - } - } - - /* normalize the attribute value */ - result = storeAttributeValue(parser, enc, isCdata, - atts[i].valuePtr, atts[i].valueEnd, - &tempPool); - if (result) - return result; - appAtts[attIndex] = poolStart(&tempPool); - poolFinish(&tempPool); - } - else { - /* the value did not need normalizing */ - appAtts[attIndex] = poolStoreString(&tempPool, enc, atts[i].valuePtr, - atts[i].valueEnd); - if (appAtts[attIndex] == 0) - return XML_ERROR_NO_MEMORY; - poolFinish(&tempPool); - } - /* handle prefixed attribute names */ - if (attId->prefix) { - if (attId->xmlns) { - /* deal with namespace declarations here */ - enum XML_Error result = addBinding(parser, attId->prefix, attId, - appAtts[attIndex], bindingsPtr); - if (result) - return result; - --attIndex; - } - else { - /* deal with other prefixed names later */ - attIndex++; - nPrefixes++; - (attId->name)[-1] = 2; - } - } - else - attIndex++; - } - - /* set-up for XML_GetSpecifiedAttributeCount and XML_GetIdAttributeIndex */ - nSpecifiedAtts = attIndex; - if (elementType->idAtt && (elementType->idAtt->name)[-1]) { - for (i = 0; i < attIndex; i += 2) - if (appAtts[i] == elementType->idAtt->name) { - idAttIndex = i; - break; - } - } - else - idAttIndex = -1; - - /* do attribute defaulting */ - for (i = 0; i < nDefaultAtts; i++) { - const DEFAULT_ATTRIBUTE *da = elementType->defaultAtts + i; - if (!(da->id->name)[-1] && da->value) { - if (da->id->prefix) { - if (da->id->xmlns) { - enum XML_Error result = addBinding(parser, da->id->prefix, da->id, - da->value, bindingsPtr); - if (result) - return result; - } - else { - (da->id->name)[-1] = 2; - nPrefixes++; - appAtts[attIndex++] = da->id->name; - appAtts[attIndex++] = da->value; - } - } - else { - (da->id->name)[-1] = 1; - appAtts[attIndex++] = da->id->name; - appAtts[attIndex++] = da->value; - } - } - } - appAtts[attIndex] = 0; - - /* expand prefixed attribute names, check for duplicates, - and clear flags that say whether attributes were specified */ - i = 0; - if (nPrefixes) { - int j; /* hash table index */ - unsigned long version = nsAttsVersion; - int nsAttsSize = (int)1 << nsAttsPower; - /* size of hash table must be at least 2 * (# of prefixed attributes) */ - if ((nPrefixes << 1) >> nsAttsPower) { /* true for nsAttsPower = 0 */ - NS_ATT *temp; - /* hash table size must also be a power of 2 and >= 8 */ - while (nPrefixes >> nsAttsPower++); - if (nsAttsPower < 3) - nsAttsPower = 3; - nsAttsSize = (int)1 << nsAttsPower; - temp = (NS_ATT *)REALLOC(nsAtts, nsAttsSize * sizeof(NS_ATT)); - if (!temp) - return XML_ERROR_NO_MEMORY; - nsAtts = temp; - version = 0; /* force re-initialization of nsAtts hash table */ - } - /* using a version flag saves us from initializing nsAtts every time */ - if (!version) { /* initialize version flags when version wraps around */ - version = INIT_ATTS_VERSION; - for (j = nsAttsSize; j != 0; ) - nsAtts[--j].version = version; - } - nsAttsVersion = --version; - - /* expand prefixed names and check for duplicates */ - for (; i < attIndex; i += 2) { - const XML_Char *s = appAtts[i]; - if (s[-1] == 2) { /* prefixed */ - ATTRIBUTE_ID *id; - const BINDING *b; - unsigned long uriHash = hash_secret_salt; - ((XML_Char *)s)[-1] = 0; /* clear flag */ - id = (ATTRIBUTE_ID *)lookup(parser, &dtd->attributeIds, s, 0); - b = id->prefix->binding; - if (!b) - return XML_ERROR_UNBOUND_PREFIX; - - /* as we expand the name we also calculate its hash value */ - for (j = 0; j < b->uriLen; j++) { - const XML_Char c = b->uri[j]; - if (!poolAppendChar(&tempPool, c)) - return XML_ERROR_NO_MEMORY; - uriHash = CHAR_HASH(uriHash, c); - } - while (*s++ != XML_T(ASCII_COLON)) - ; - do { /* copies null terminator */ - const XML_Char c = *s; - if (!poolAppendChar(&tempPool, *s)) - return XML_ERROR_NO_MEMORY; - uriHash = CHAR_HASH(uriHash, c); - } while (*s++); - - { /* Check hash table for duplicate of expanded name (uriName). - Derived from code in lookup(parser, HASH_TABLE *table, ...). - */ - unsigned char step = 0; - unsigned long mask = nsAttsSize - 1; - j = uriHash & mask; /* index into hash table */ - while (nsAtts[j].version == version) { - /* for speed we compare stored hash values first */ - if (uriHash == nsAtts[j].hash) { - const XML_Char *s1 = poolStart(&tempPool); - const XML_Char *s2 = nsAtts[j].uriName; - /* s1 is null terminated, but not s2 */ - for (; *s1 == *s2 && *s1 != 0; s1++, s2++); - if (*s1 == 0) - return XML_ERROR_DUPLICATE_ATTRIBUTE; - } - if (!step) - step = PROBE_STEP(uriHash, mask, nsAttsPower); - j < step ? (j += nsAttsSize - step) : (j -= step); - } - } - - if (ns_triplets) { /* append namespace separator and prefix */ - tempPool.ptr[-1] = namespaceSeparator; - s = b->prefix->name; - do { - if (!poolAppendChar(&tempPool, *s)) - return XML_ERROR_NO_MEMORY; - } while (*s++); - } - - /* store expanded name in attribute list */ - s = poolStart(&tempPool); - poolFinish(&tempPool); - appAtts[i] = s; - - /* fill empty slot with new version, uriName and hash value */ - nsAtts[j].version = version; - nsAtts[j].hash = uriHash; - nsAtts[j].uriName = s; - - if (!--nPrefixes) { - i += 2; - break; - } - } - else /* not prefixed */ - ((XML_Char *)s)[-1] = 0; /* clear flag */ - } - } - /* clear flags for the remaining attributes */ - for (; i < attIndex; i += 2) - ((XML_Char *)(appAtts[i]))[-1] = 0; - for (binding = *bindingsPtr; binding; binding = binding->nextTagBinding) - binding->attId->name[-1] = 0; - - if (!ns) - return XML_ERROR_NONE; - - /* expand the element type name */ - if (elementType->prefix) { - binding = elementType->prefix->binding; - if (!binding) - return XML_ERROR_UNBOUND_PREFIX; - localPart = tagNamePtr->str; - while (*localPart++ != XML_T(ASCII_COLON)) - ; - } - else if (dtd->defaultPrefix.binding) { - binding = dtd->defaultPrefix.binding; - localPart = tagNamePtr->str; - } - else - return XML_ERROR_NONE; - prefixLen = 0; - if (ns_triplets && binding->prefix->name) { - for (; binding->prefix->name[prefixLen++];) - ; /* prefixLen includes null terminator */ - } - tagNamePtr->localPart = localPart; - tagNamePtr->uriLen = binding->uriLen; - tagNamePtr->prefix = binding->prefix->name; - tagNamePtr->prefixLen = prefixLen; - for (i = 0; localPart[i++];) - ; /* i includes null terminator */ - n = i + binding->uriLen + prefixLen; - if (n > binding->uriAlloc) { - TAG *p; - uri = (XML_Char *)MALLOC((n + EXPAND_SPARE) * sizeof(XML_Char)); - if (!uri) - return XML_ERROR_NO_MEMORY; - binding->uriAlloc = n + EXPAND_SPARE; - memcpy(uri, binding->uri, binding->uriLen * sizeof(XML_Char)); - for (p = tagStack; p; p = p->parent) - if (p->name.str == binding->uri) - p->name.str = uri; - FREE(binding->uri); - binding->uri = uri; - } - /* if namespaceSeparator != '\0' then uri includes it already */ - uri = binding->uri + binding->uriLen; - memcpy(uri, localPart, i * sizeof(XML_Char)); - /* we always have a namespace separator between localPart and prefix */ - if (prefixLen) { - uri += i - 1; - *uri = namespaceSeparator; /* replace null terminator */ - memcpy(uri + 1, binding->prefix->name, prefixLen * sizeof(XML_Char)); - } - tagNamePtr->str = binding->uri; - return XML_ERROR_NONE; -} - -/* addBinding() overwrites the value of prefix->binding without checking. - Therefore one must keep track of the old value outside of addBinding(). -*/ -static enum XML_Error -addBinding(XML_Parser parser, PREFIX *prefix, const ATTRIBUTE_ID *attId, - const XML_Char *uri, BINDING **bindingsPtr) -{ - static const XML_Char xmlNamespace[] = { - ASCII_h, ASCII_t, ASCII_t, ASCII_p, ASCII_COLON, ASCII_SLASH, ASCII_SLASH, - ASCII_w, ASCII_w, ASCII_w, ASCII_PERIOD, ASCII_w, ASCII_3, ASCII_PERIOD, - ASCII_o, ASCII_r, ASCII_g, ASCII_SLASH, ASCII_X, ASCII_M, ASCII_L, - ASCII_SLASH, ASCII_1, ASCII_9, ASCII_9, ASCII_8, ASCII_SLASH, - ASCII_n, ASCII_a, ASCII_m, ASCII_e, ASCII_s, ASCII_p, ASCII_a, ASCII_c, - ASCII_e, '\0' - }; - static const int xmlLen = - (int)sizeof(xmlNamespace)/sizeof(XML_Char) - 1; - static const XML_Char xmlnsNamespace[] = { - ASCII_h, ASCII_t, ASCII_t, ASCII_p, ASCII_COLON, ASCII_SLASH, ASCII_SLASH, - ASCII_w, ASCII_w, ASCII_w, ASCII_PERIOD, ASCII_w, ASCII_3, ASCII_PERIOD, - ASCII_o, ASCII_r, ASCII_g, ASCII_SLASH, ASCII_2, ASCII_0, ASCII_0, - ASCII_0, ASCII_SLASH, ASCII_x, ASCII_m, ASCII_l, ASCII_n, ASCII_s, - ASCII_SLASH, '\0' - }; - static const int xmlnsLen = - (int)sizeof(xmlnsNamespace)/sizeof(XML_Char) - 1; - - XML_Bool mustBeXML = XML_FALSE; - XML_Bool isXML = XML_TRUE; - XML_Bool isXMLNS = XML_TRUE; - - BINDING *b; - int len; - - /* empty URI is only valid for default namespace per XML NS 1.0 (not 1.1) */ - if (*uri == XML_T('\0') && prefix->name) - return XML_ERROR_UNDECLARING_PREFIX; - - if (prefix->name - && prefix->name[0] == XML_T(ASCII_x) - && prefix->name[1] == XML_T(ASCII_m) - && prefix->name[2] == XML_T(ASCII_l)) { - - /* Not allowed to bind xmlns */ - if (prefix->name[3] == XML_T(ASCII_n) - && prefix->name[4] == XML_T(ASCII_s) - && prefix->name[5] == XML_T('\0')) - return XML_ERROR_RESERVED_PREFIX_XMLNS; - - if (prefix->name[3] == XML_T('\0')) - mustBeXML = XML_TRUE; - } - - for (len = 0; uri[len]; len++) { - if (isXML && (len > xmlLen || uri[len] != xmlNamespace[len])) - isXML = XML_FALSE; - - if (!mustBeXML && isXMLNS - && (len > xmlnsLen || uri[len] != xmlnsNamespace[len])) - isXMLNS = XML_FALSE; - } - isXML = isXML && len == xmlLen; - isXMLNS = isXMLNS && len == xmlnsLen; - - if (mustBeXML != isXML) - return mustBeXML ? XML_ERROR_RESERVED_PREFIX_XML - : XML_ERROR_RESERVED_NAMESPACE_URI; - - if (isXMLNS) - return XML_ERROR_RESERVED_NAMESPACE_URI; - - if (namespaceSeparator) - len++; - if (freeBindingList) { - b = freeBindingList; - if (len > b->uriAlloc) { - XML_Char *temp = (XML_Char *)REALLOC(b->uri, - sizeof(XML_Char) * (len + EXPAND_SPARE)); - if (temp == NULL) - return XML_ERROR_NO_MEMORY; - b->uri = temp; - b->uriAlloc = len + EXPAND_SPARE; - } - freeBindingList = b->nextTagBinding; - } - else { - b = (BINDING *)MALLOC(sizeof(BINDING)); - if (!b) - return XML_ERROR_NO_MEMORY; - b->uri = (XML_Char *)MALLOC(sizeof(XML_Char) * (len + EXPAND_SPARE)); - if (!b->uri) { - FREE(b); - return XML_ERROR_NO_MEMORY; - } - b->uriAlloc = len + EXPAND_SPARE; - } - b->uriLen = len; - memcpy(b->uri, uri, len * sizeof(XML_Char)); - if (namespaceSeparator) - b->uri[len - 1] = namespaceSeparator; - b->prefix = prefix; - b->attId = attId; - b->prevPrefixBinding = prefix->binding; - /* NULL binding when default namespace undeclared */ - if (*uri == XML_T('\0') && prefix == &_dtd->defaultPrefix) - prefix->binding = NULL; - else - prefix->binding = b; - b->nextTagBinding = *bindingsPtr; - *bindingsPtr = b; - /* if attId == NULL then we are not starting a namespace scope */ - if (attId && startNamespaceDeclHandler) - startNamespaceDeclHandler(handlerArg, prefix->name, - prefix->binding ? uri : 0); - return XML_ERROR_NONE; -} - -/* The idea here is to avoid using stack for each CDATA section when - the whole file is parsed with one call. -*/ -static enum XML_Error PTRCALL -cdataSectionProcessor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - enum XML_Error result = doCdataSection(parser, encoding, &start, end, - endPtr, (XML_Bool)!ps_finalBuffer); - if (result != XML_ERROR_NONE) - return result; - if (start) { - if (parentParser) { /* we are parsing an external entity */ - processor = externalEntityContentProcessor; - return externalEntityContentProcessor(parser, start, end, endPtr); - } - else { - processor = contentProcessor; - return contentProcessor(parser, start, end, endPtr); - } - } - return result; -} - -/* startPtr gets set to non-null if the section is closed, and to null if - the section is not yet closed. -*/ -static enum XML_Error -doCdataSection(XML_Parser parser, - const ENCODING *enc, - const char **startPtr, - const char *end, - const char **nextPtr, - XML_Bool haveMore) -{ - const char *s = *startPtr; - const char **eventPP; - const char **eventEndPP; - if (enc == encoding) { - eventPP = &eventPtr; - *eventPP = s; - eventEndPP = &eventEndPtr; - } - else { - eventPP = &(openInternalEntities->internalEventPtr); - eventEndPP = &(openInternalEntities->internalEventEndPtr); - } - *eventPP = s; - *startPtr = NULL; - - for (;;) { - const char *next; - int tok = XmlCdataSectionTok(enc, s, end, &next); - *eventEndPP = next; - switch (tok) { - case XML_TOK_CDATA_SECT_CLOSE: - if (endCdataSectionHandler) - endCdataSectionHandler(handlerArg); -#if 0 - /* see comment under XML_TOK_CDATA_SECT_OPEN */ - else if (characterDataHandler) - characterDataHandler(handlerArg, dataBuf, 0); -#endif - else if (defaultHandler) - reportDefault(parser, enc, s, next); - *startPtr = next; - *nextPtr = next; - if (ps_parsing == XML_FINISHED) - return XML_ERROR_ABORTED; - else - return XML_ERROR_NONE; - case XML_TOK_DATA_NEWLINE: - if (characterDataHandler) { - XML_Char c = 0xA; - characterDataHandler(handlerArg, &c, 1); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - break; - case XML_TOK_DATA_CHARS: - { - XML_CharacterDataHandler charDataHandler = characterDataHandler; - if (charDataHandler) { - if (MUST_CONVERT(enc, s)) { - for (;;) { - ICHAR *dataPtr = (ICHAR *)dataBuf; - XmlConvert(enc, &s, next, &dataPtr, (ICHAR *)dataBufEnd); - *eventEndPP = next; - charDataHandler(handlerArg, dataBuf, - (int)(dataPtr - (ICHAR *)dataBuf)); - if (s == next) - break; - *eventPP = s; - } - } - else - charDataHandler(handlerArg, - (XML_Char *)s, - (int)((XML_Char *)next - (XML_Char *)s)); - } - else if (defaultHandler) - reportDefault(parser, enc, s, next); - } - break; - case XML_TOK_INVALID: - *eventPP = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_PARTIAL: - case XML_TOK_NONE: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_UNCLOSED_CDATA_SECTION; - default: - *eventPP = next; - return XML_ERROR_UNEXPECTED_STATE; - } - - *eventPP = s = next; - switch (ps_parsing) { - case XML_SUSPENDED: - *nextPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: ; - } - } - /* not reached */ -} - -#ifdef XML_DTD - -/* The idea here is to avoid using stack for each IGNORE section when - the whole file is parsed with one call. -*/ -static enum XML_Error PTRCALL -ignoreSectionProcessor(XML_Parser parser, - const char *start, - const char *end, - const char **endPtr) -{ - enum XML_Error result = doIgnoreSection(parser, encoding, &start, end, - endPtr, (XML_Bool)!ps_finalBuffer); - if (result != XML_ERROR_NONE) - return result; - if (start) { - processor = prologProcessor; - return prologProcessor(parser, start, end, endPtr); - } - return result; -} - -/* startPtr gets set to non-null is the section is closed, and to null - if the section is not yet closed. -*/ -static enum XML_Error -doIgnoreSection(XML_Parser parser, - const ENCODING *enc, - const char **startPtr, - const char *end, - const char **nextPtr, - XML_Bool haveMore) -{ - const char *next; - int tok; - const char *s = *startPtr; - const char **eventPP; - const char **eventEndPP; - if (enc == encoding) { - eventPP = &eventPtr; - *eventPP = s; - eventEndPP = &eventEndPtr; - } - else { - eventPP = &(openInternalEntities->internalEventPtr); - eventEndPP = &(openInternalEntities->internalEventEndPtr); - } - *eventPP = s; - *startPtr = NULL; - tok = XmlIgnoreSectionTok(enc, s, end, &next); - *eventEndPP = next; - switch (tok) { - case XML_TOK_IGNORE_SECT: - if (defaultHandler) - reportDefault(parser, enc, s, next); - *startPtr = next; - *nextPtr = next; - if (ps_parsing == XML_FINISHED) - return XML_ERROR_ABORTED; - else - return XML_ERROR_NONE; - case XML_TOK_INVALID: - *eventPP = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_PARTIAL: - case XML_TOK_NONE: - if (haveMore) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_SYNTAX; /* XML_ERROR_UNCLOSED_IGNORE_SECTION */ - default: - *eventPP = next; - return XML_ERROR_UNEXPECTED_STATE; - } - /* not reached */ -} - -#endif /* XML_DTD */ - -static enum XML_Error -initializeEncoding(XML_Parser parser) -{ - const char *s; -#ifdef XML_UNICODE - char encodingBuf[128]; - if (!protocolEncodingName) - s = NULL; - else { - int i; - for (i = 0; protocolEncodingName[i]; i++) { - if (i == sizeof(encodingBuf) - 1 - || (protocolEncodingName[i] & ~0x7f) != 0) { - encodingBuf[0] = '\0'; - break; - } - encodingBuf[i] = (char)protocolEncodingName[i]; - } - encodingBuf[i] = '\0'; - s = encodingBuf; - } -#else - s = protocolEncodingName; -#endif - if ((ns ? XmlInitEncodingNS : XmlInitEncoding)(&initEncoding, &encoding, s)) - return XML_ERROR_NONE; - return handleUnknownEncoding(parser, protocolEncodingName); -} - -static enum XML_Error -processXmlDecl(XML_Parser parser, int isGeneralTextEntity, - const char *s, const char *next) -{ - const char *encodingName = NULL; - const XML_Char *storedEncName = NULL; - const ENCODING *newEncoding = NULL; - const char *version = NULL; - const char *versionend; - const XML_Char *storedversion = NULL; - int standalone = -1; - if (!(ns - ? XmlParseXmlDeclNS - : XmlParseXmlDecl)(isGeneralTextEntity, - encoding, - s, - next, - &eventPtr, - &version, - &versionend, - &encodingName, - &newEncoding, - &standalone)) { - if (isGeneralTextEntity) - return XML_ERROR_TEXT_DECL; - else - return XML_ERROR_XML_DECL; - } - if (!isGeneralTextEntity && standalone == 1) { - _dtd->standalone = XML_TRUE; -#ifdef XML_DTD - if (paramEntityParsing == XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE) - paramEntityParsing = XML_PARAM_ENTITY_PARSING_NEVER; -#endif /* XML_DTD */ - } - if (xmlDeclHandler) { - if (encodingName != NULL) { - storedEncName = poolStoreString(&temp2Pool, - encoding, - encodingName, - encodingName - + XmlNameLength(encoding, encodingName)); - if (!storedEncName) - return XML_ERROR_NO_MEMORY; - poolFinish(&temp2Pool); - } - if (version) { - storedversion = poolStoreString(&temp2Pool, - encoding, - version, - versionend - encoding->minBytesPerChar); - if (!storedversion) - return XML_ERROR_NO_MEMORY; - } - xmlDeclHandler(handlerArg, storedversion, storedEncName, standalone); - } - else if (defaultHandler) - reportDefault(parser, encoding, s, next); - if (protocolEncodingName == NULL) { - if (newEncoding) { - if (newEncoding->minBytesPerChar != encoding->minBytesPerChar) { - eventPtr = encodingName; - return XML_ERROR_INCORRECT_ENCODING; - } - encoding = newEncoding; - } - else if (encodingName) { - enum XML_Error result; - if (!storedEncName) { - storedEncName = poolStoreString( - &temp2Pool, encoding, encodingName, - encodingName + XmlNameLength(encoding, encodingName)); - if (!storedEncName) - return XML_ERROR_NO_MEMORY; - } - result = handleUnknownEncoding(parser, storedEncName); - poolClear(&temp2Pool); - if (result == XML_ERROR_UNKNOWN_ENCODING) - eventPtr = encodingName; - return result; - } - } - - if (storedEncName || storedversion) - poolClear(&temp2Pool); - - return XML_ERROR_NONE; -} - -static enum XML_Error -handleUnknownEncoding(XML_Parser parser, const XML_Char *encodingName) -{ - if (unknownEncodingHandler) { - XML_Encoding info; - int i; - for (i = 0; i < 256; i++) - info.map[i] = -1; - info.convert = NULL; - info.data = NULL; - info.release = NULL; - if (unknownEncodingHandler(unknownEncodingHandlerData, encodingName, - &info)) { - ENCODING *enc; - unknownEncodingMem = MALLOC(XmlSizeOfUnknownEncoding()); - if (!unknownEncodingMem) { - if (info.release) - info.release(info.data); - return XML_ERROR_NO_MEMORY; - } - enc = (ns - ? XmlInitUnknownEncodingNS - : XmlInitUnknownEncoding)(unknownEncodingMem, - info.map, - info.convert, - info.data); - if (enc) { - unknownEncodingData = info.data; - unknownEncodingRelease = info.release; - encoding = enc; - return XML_ERROR_NONE; - } - } - if (info.release != NULL) - info.release(info.data); - } - return XML_ERROR_UNKNOWN_ENCODING; -} - -static enum XML_Error PTRCALL -prologInitProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - enum XML_Error result = initializeEncoding(parser); - if (result != XML_ERROR_NONE) - return result; - processor = prologProcessor; - return prologProcessor(parser, s, end, nextPtr); -} - -#ifdef XML_DTD - -static enum XML_Error PTRCALL -externalParEntInitProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - enum XML_Error result = initializeEncoding(parser); - if (result != XML_ERROR_NONE) - return result; - - /* we know now that XML_Parse(Buffer) has been called, - so we consider the external parameter entity read */ - _dtd->paramEntityRead = XML_TRUE; - - if (prologState.inEntityValue) { - processor = entityValueInitProcessor; - return entityValueInitProcessor(parser, s, end, nextPtr); - } - else { - processor = externalParEntProcessor; - return externalParEntProcessor(parser, s, end, nextPtr); - } -} - -static enum XML_Error PTRCALL -entityValueInitProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - int tok; - const char *start = s; - const char *next = start; - eventPtr = start; - - for (;;) { - tok = XmlPrologTok(encoding, start, end, &next); - eventEndPtr = next; - if (tok <= 0) { - if (!ps_finalBuffer && tok != XML_TOK_INVALID) { - *nextPtr = s; - return XML_ERROR_NONE; - } - switch (tok) { - case XML_TOK_INVALID: - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_NONE: /* start == end */ - default: - break; - } - /* found end of entity value - can store it now */ - return storeEntityValue(parser, encoding, s, end); - } - else if (tok == XML_TOK_XML_DECL) { - enum XML_Error result; - result = processXmlDecl(parser, 0, start, next); - if (result != XML_ERROR_NONE) - return result; - switch (ps_parsing) { - case XML_SUSPENDED: - *nextPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: - *nextPtr = next; - } - /* stop scanning for text declaration - we found one */ - processor = entityValueProcessor; - return entityValueProcessor(parser, next, end, nextPtr); - } - /* If we are at the end of the buffer, this would cause XmlPrologTok to - return XML_TOK_NONE on the next call, which would then cause the - function to exit with *nextPtr set to s - that is what we want for other - tokens, but not for the BOM - we would rather like to skip it; - then, when this routine is entered the next time, XmlPrologTok will - return XML_TOK_INVALID, since the BOM is still in the buffer - */ - else if (tok == XML_TOK_BOM && next == end && !ps_finalBuffer) { - *nextPtr = next; - return XML_ERROR_NONE; - } - start = next; - eventPtr = start; - } -} - -static enum XML_Error PTRCALL -externalParEntProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - const char *next = s; - int tok; - - tok = XmlPrologTok(encoding, s, end, &next); - if (tok <= 0) { - if (!ps_finalBuffer && tok != XML_TOK_INVALID) { - *nextPtr = s; - return XML_ERROR_NONE; - } - switch (tok) { - case XML_TOK_INVALID: - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_NONE: /* start == end */ - default: - break; - } - } - /* This would cause the next stage, i.e. doProlog to be passed XML_TOK_BOM. - However, when parsing an external subset, doProlog will not accept a BOM - as valid, and report a syntax error, so we have to skip the BOM - */ - else if (tok == XML_TOK_BOM) { - s = next; - tok = XmlPrologTok(encoding, s, end, &next); - } - - processor = prologProcessor; - return doProlog(parser, encoding, s, end, tok, next, - nextPtr, (XML_Bool)!ps_finalBuffer); -} - -static enum XML_Error PTRCALL -entityValueProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - const char *start = s; - const char *next = s; - const ENCODING *enc = encoding; - int tok; - - for (;;) { - tok = XmlPrologTok(enc, start, end, &next); - if (tok <= 0) { - if (!ps_finalBuffer && tok != XML_TOK_INVALID) { - *nextPtr = s; - return XML_ERROR_NONE; - } - switch (tok) { - case XML_TOK_INVALID: - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - return XML_ERROR_PARTIAL_CHAR; - case XML_TOK_NONE: /* start == end */ - default: - break; - } - /* found end of entity value - can store it now */ - return storeEntityValue(parser, enc, s, end); - } - start = next; - } -} - -#endif /* XML_DTD */ - -static enum XML_Error PTRCALL -prologProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - const char *next = s; - int tok = XmlPrologTok(encoding, s, end, &next); - return doProlog(parser, encoding, s, end, tok, next, - nextPtr, (XML_Bool)!ps_finalBuffer); -} - -static enum XML_Error -doProlog(XML_Parser parser, - const ENCODING *enc, - const char *s, - const char *end, - int tok, - const char *next, - const char **nextPtr, - XML_Bool haveMore) -{ -#ifdef XML_DTD - static const XML_Char externalSubsetName[] = { ASCII_HASH , '\0' }; -#endif /* XML_DTD */ - static const XML_Char atypeCDATA[] = - { ASCII_C, ASCII_D, ASCII_A, ASCII_T, ASCII_A, '\0' }; - static const XML_Char atypeID[] = { ASCII_I, ASCII_D, '\0' }; - static const XML_Char atypeIDREF[] = - { ASCII_I, ASCII_D, ASCII_R, ASCII_E, ASCII_F, '\0' }; - static const XML_Char atypeIDREFS[] = - { ASCII_I, ASCII_D, ASCII_R, ASCII_E, ASCII_F, ASCII_S, '\0' }; - static const XML_Char atypeENTITY[] = - { ASCII_E, ASCII_N, ASCII_T, ASCII_I, ASCII_T, ASCII_Y, '\0' }; - static const XML_Char atypeENTITIES[] = { ASCII_E, ASCII_N, - ASCII_T, ASCII_I, ASCII_T, ASCII_I, ASCII_E, ASCII_S, '\0' }; - static const XML_Char atypeNMTOKEN[] = { - ASCII_N, ASCII_M, ASCII_T, ASCII_O, ASCII_K, ASCII_E, ASCII_N, '\0' }; - static const XML_Char atypeNMTOKENS[] = { ASCII_N, ASCII_M, ASCII_T, - ASCII_O, ASCII_K, ASCII_E, ASCII_N, ASCII_S, '\0' }; - static const XML_Char notationPrefix[] = { ASCII_N, ASCII_O, ASCII_T, - ASCII_A, ASCII_T, ASCII_I, ASCII_O, ASCII_N, ASCII_LPAREN, '\0' }; - static const XML_Char enumValueSep[] = { ASCII_PIPE, '\0' }; - static const XML_Char enumValueStart[] = { ASCII_LPAREN, '\0' }; - - /* save one level of indirection */ - DTD * const dtd = _dtd; - - const char **eventPP; - const char **eventEndPP; - enum XML_Content_Quant quant; - - if (enc == encoding) { - eventPP = &eventPtr; - eventEndPP = &eventEndPtr; - } - else { - eventPP = &(openInternalEntities->internalEventPtr); - eventEndPP = &(openInternalEntities->internalEventEndPtr); - } - - for (;;) { - int role; - XML_Bool handleDefault = XML_TRUE; - *eventPP = s; - *eventEndPP = next; - if (tok <= 0) { - if (haveMore && tok != XML_TOK_INVALID) { - *nextPtr = s; - return XML_ERROR_NONE; - } - switch (tok) { - case XML_TOK_INVALID: - *eventPP = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - return XML_ERROR_PARTIAL_CHAR; - case -XML_TOK_PROLOG_S: - tok = -tok; - break; - case XML_TOK_NONE: -#ifdef XML_DTD - /* for internal PE NOT referenced between declarations */ - if (enc != encoding && !openInternalEntities->betweenDecl) { - *nextPtr = s; - return XML_ERROR_NONE; - } - /* WFC: PE Between Declarations - must check that PE contains - complete markup, not only for external PEs, but also for - internal PEs if the reference occurs between declarations. - */ - if (isParamEntity || enc != encoding) { - if (XmlTokenRole(&prologState, XML_TOK_NONE, end, end, enc) - == XML_ROLE_ERROR) - return XML_ERROR_INCOMPLETE_PE; - *nextPtr = s; - return XML_ERROR_NONE; - } -#endif /* XML_DTD */ - return XML_ERROR_NO_ELEMENTS; - default: - tok = -tok; - next = end; - break; - } - } - role = XmlTokenRole(&prologState, tok, s, next, enc); - switch (role) { - case XML_ROLE_XML_DECL: - { - enum XML_Error result = processXmlDecl(parser, 0, s, next); - if (result != XML_ERROR_NONE) - return result; - enc = encoding; - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_DOCTYPE_NAME: - if (startDoctypeDeclHandler) { - doctypeName = poolStoreString(&tempPool, enc, s, next); - if (!doctypeName) - return XML_ERROR_NO_MEMORY; - poolFinish(&tempPool); - doctypePubid = NULL; - handleDefault = XML_FALSE; - } - doctypeSysid = NULL; /* always initialize to NULL */ - break; - case XML_ROLE_DOCTYPE_INTERNAL_SUBSET: - if (startDoctypeDeclHandler) { - startDoctypeDeclHandler(handlerArg, doctypeName, doctypeSysid, - doctypePubid, 1); - doctypeName = NULL; - poolClear(&tempPool); - handleDefault = XML_FALSE; - } - break; -#ifdef XML_DTD - case XML_ROLE_TEXT_DECL: - { - enum XML_Error result = processXmlDecl(parser, 1, s, next); - if (result != XML_ERROR_NONE) - return result; - enc = encoding; - handleDefault = XML_FALSE; - } - break; -#endif /* XML_DTD */ - case XML_ROLE_DOCTYPE_PUBLIC_ID: -#ifdef XML_DTD - useForeignDTD = XML_FALSE; - declEntity = (ENTITY *)lookup(parser, - &dtd->paramEntities, - externalSubsetName, - sizeof(ENTITY)); - if (!declEntity) - return XML_ERROR_NO_MEMORY; -#endif /* XML_DTD */ - dtd->hasParamEntityRefs = XML_TRUE; - if (startDoctypeDeclHandler) { - XML_Char *pubId; - if (!XmlIsPublicId(enc, s, next, eventPP)) - return XML_ERROR_PUBLICID; - pubId = poolStoreString(&tempPool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!pubId) - return XML_ERROR_NO_MEMORY; - normalizePublicId(pubId); - poolFinish(&tempPool); - doctypePubid = pubId; - handleDefault = XML_FALSE; - goto alreadyChecked; - } - /* fall through */ - case XML_ROLE_ENTITY_PUBLIC_ID: - if (!XmlIsPublicId(enc, s, next, eventPP)) - return XML_ERROR_PUBLICID; - alreadyChecked: - if (dtd->keepProcessing && declEntity) { - XML_Char *tem = poolStoreString(&dtd->pool, - enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!tem) - return XML_ERROR_NO_MEMORY; - normalizePublicId(tem); - declEntity->publicId = tem; - poolFinish(&dtd->pool); - if (entityDeclHandler) - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_DOCTYPE_CLOSE: - if (doctypeName) { - startDoctypeDeclHandler(handlerArg, doctypeName, - doctypeSysid, doctypePubid, 0); - poolClear(&tempPool); - handleDefault = XML_FALSE; - } - /* doctypeSysid will be non-NULL in the case of a previous - XML_ROLE_DOCTYPE_SYSTEM_ID, even if startDoctypeDeclHandler - was not set, indicating an external subset - */ -#ifdef XML_DTD - if (doctypeSysid || useForeignDTD) { - XML_Bool hadParamEntityRefs = dtd->hasParamEntityRefs; - dtd->hasParamEntityRefs = XML_TRUE; - if (paramEntityParsing && externalEntityRefHandler) { - ENTITY *entity = (ENTITY *)lookup(parser, - &dtd->paramEntities, - externalSubsetName, - sizeof(ENTITY)); - if (!entity) - return XML_ERROR_NO_MEMORY; - if (useForeignDTD) - entity->base = curBase; - dtd->paramEntityRead = XML_FALSE; - if (!externalEntityRefHandler(externalEntityRefHandlerArg, - 0, - entity->base, - entity->systemId, - entity->publicId)) - return XML_ERROR_EXTERNAL_ENTITY_HANDLING; - if (dtd->paramEntityRead) { - if (!dtd->standalone && - notStandaloneHandler && - !notStandaloneHandler(handlerArg)) - return XML_ERROR_NOT_STANDALONE; - } - /* if we didn't read the foreign DTD then this means that there - is no external subset and we must reset dtd->hasParamEntityRefs - */ - else if (!doctypeSysid) - dtd->hasParamEntityRefs = hadParamEntityRefs; - /* end of DTD - no need to update dtd->keepProcessing */ - } - useForeignDTD = XML_FALSE; - } -#endif /* XML_DTD */ - if (endDoctypeDeclHandler) { - endDoctypeDeclHandler(handlerArg); - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_INSTANCE_START: -#ifdef XML_DTD - /* if there is no DOCTYPE declaration then now is the - last chance to read the foreign DTD - */ - if (useForeignDTD) { - XML_Bool hadParamEntityRefs = dtd->hasParamEntityRefs; - dtd->hasParamEntityRefs = XML_TRUE; - if (paramEntityParsing && externalEntityRefHandler) { - ENTITY *entity = (ENTITY *)lookup(parser, &dtd->paramEntities, - externalSubsetName, - sizeof(ENTITY)); - if (!entity) - return XML_ERROR_NO_MEMORY; - entity->base = curBase; - dtd->paramEntityRead = XML_FALSE; - if (!externalEntityRefHandler(externalEntityRefHandlerArg, - 0, - entity->base, - entity->systemId, - entity->publicId)) - return XML_ERROR_EXTERNAL_ENTITY_HANDLING; - if (dtd->paramEntityRead) { - if (!dtd->standalone && - notStandaloneHandler && - !notStandaloneHandler(handlerArg)) - return XML_ERROR_NOT_STANDALONE; - } - /* if we didn't read the foreign DTD then this means that there - is no external subset and we must reset dtd->hasParamEntityRefs - */ - else - dtd->hasParamEntityRefs = hadParamEntityRefs; - /* end of DTD - no need to update dtd->keepProcessing */ - } - } -#endif /* XML_DTD */ - processor = contentProcessor; - return contentProcessor(parser, s, end, nextPtr); - case XML_ROLE_ATTLIST_ELEMENT_NAME: - declElementType = getElementType(parser, enc, s, next); - if (!declElementType) - return XML_ERROR_NO_MEMORY; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_NAME: - declAttributeId = getAttributeId(parser, enc, s, next); - if (!declAttributeId) - return XML_ERROR_NO_MEMORY; - declAttributeIsCdata = XML_FALSE; - declAttributeType = NULL; - declAttributeIsId = XML_FALSE; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_CDATA: - declAttributeIsCdata = XML_TRUE; - declAttributeType = atypeCDATA; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_ID: - declAttributeIsId = XML_TRUE; - declAttributeType = atypeID; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_IDREF: - declAttributeType = atypeIDREF; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_IDREFS: - declAttributeType = atypeIDREFS; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_ENTITY: - declAttributeType = atypeENTITY; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_ENTITIES: - declAttributeType = atypeENTITIES; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_NMTOKEN: - declAttributeType = atypeNMTOKEN; - goto checkAttListDeclHandler; - case XML_ROLE_ATTRIBUTE_TYPE_NMTOKENS: - declAttributeType = atypeNMTOKENS; - checkAttListDeclHandler: - if (dtd->keepProcessing && attlistDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_ATTRIBUTE_ENUM_VALUE: - case XML_ROLE_ATTRIBUTE_NOTATION_VALUE: - if (dtd->keepProcessing && attlistDeclHandler) { - const XML_Char *prefix; - if (declAttributeType) { - prefix = enumValueSep; - } - else { - prefix = (role == XML_ROLE_ATTRIBUTE_NOTATION_VALUE - ? notationPrefix - : enumValueStart); - } - if (!poolAppendString(&tempPool, prefix)) - return XML_ERROR_NO_MEMORY; - if (!poolAppend(&tempPool, enc, s, next)) - return XML_ERROR_NO_MEMORY; - declAttributeType = tempPool.start; - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_IMPLIED_ATTRIBUTE_VALUE: - case XML_ROLE_REQUIRED_ATTRIBUTE_VALUE: - if (dtd->keepProcessing) { - if (!defineAttribute(declElementType, declAttributeId, - declAttributeIsCdata, declAttributeIsId, - 0, parser)) - return XML_ERROR_NO_MEMORY; - if (attlistDeclHandler && declAttributeType) { - if (*declAttributeType == XML_T(ASCII_LPAREN) - || (*declAttributeType == XML_T(ASCII_N) - && declAttributeType[1] == XML_T(ASCII_O))) { - /* Enumerated or Notation type */ - if (!poolAppendChar(&tempPool, XML_T(ASCII_RPAREN)) - || !poolAppendChar(&tempPool, XML_T('\0'))) - return XML_ERROR_NO_MEMORY; - declAttributeType = tempPool.start; - poolFinish(&tempPool); - } - *eventEndPP = s; - attlistDeclHandler(handlerArg, declElementType->name, - declAttributeId->name, declAttributeType, - 0, role == XML_ROLE_REQUIRED_ATTRIBUTE_VALUE); - poolClear(&tempPool); - handleDefault = XML_FALSE; - } - } - break; - case XML_ROLE_DEFAULT_ATTRIBUTE_VALUE: - case XML_ROLE_FIXED_ATTRIBUTE_VALUE: - if (dtd->keepProcessing) { - const XML_Char *attVal; - enum XML_Error result = - storeAttributeValue(parser, enc, declAttributeIsCdata, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar, - &dtd->pool); - if (result) - return result; - attVal = poolStart(&dtd->pool); - poolFinish(&dtd->pool); - /* ID attributes aren't allowed to have a default */ - if (!defineAttribute(declElementType, declAttributeId, - declAttributeIsCdata, XML_FALSE, attVal, parser)) - return XML_ERROR_NO_MEMORY; - if (attlistDeclHandler && declAttributeType) { - if (*declAttributeType == XML_T(ASCII_LPAREN) - || (*declAttributeType == XML_T(ASCII_N) - && declAttributeType[1] == XML_T(ASCII_O))) { - /* Enumerated or Notation type */ - if (!poolAppendChar(&tempPool, XML_T(ASCII_RPAREN)) - || !poolAppendChar(&tempPool, XML_T('\0'))) - return XML_ERROR_NO_MEMORY; - declAttributeType = tempPool.start; - poolFinish(&tempPool); - } - *eventEndPP = s; - attlistDeclHandler(handlerArg, declElementType->name, - declAttributeId->name, declAttributeType, - attVal, - role == XML_ROLE_FIXED_ATTRIBUTE_VALUE); - poolClear(&tempPool); - handleDefault = XML_FALSE; - } - } - break; - case XML_ROLE_ENTITY_VALUE: - if (dtd->keepProcessing) { - enum XML_Error result = storeEntityValue(parser, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (declEntity) { - declEntity->textPtr = poolStart(&dtd->entityValuePool); - declEntity->textLen = (int)(poolLength(&dtd->entityValuePool)); - poolFinish(&dtd->entityValuePool); - if (entityDeclHandler) { - *eventEndPP = s; - entityDeclHandler(handlerArg, - declEntity->name, - declEntity->is_param, - declEntity->textPtr, - declEntity->textLen, - curBase, 0, 0, 0); - handleDefault = XML_FALSE; - } - } - else - poolDiscard(&dtd->entityValuePool); - if (result != XML_ERROR_NONE) - return result; - } - break; - case XML_ROLE_DOCTYPE_SYSTEM_ID: -#ifdef XML_DTD - useForeignDTD = XML_FALSE; -#endif /* XML_DTD */ - dtd->hasParamEntityRefs = XML_TRUE; - if (startDoctypeDeclHandler) { - doctypeSysid = poolStoreString(&tempPool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (doctypeSysid == NULL) - return XML_ERROR_NO_MEMORY; - poolFinish(&tempPool); - handleDefault = XML_FALSE; - } -#ifdef XML_DTD - else - /* use externalSubsetName to make doctypeSysid non-NULL - for the case where no startDoctypeDeclHandler is set */ - doctypeSysid = externalSubsetName; -#endif /* XML_DTD */ - if (!dtd->standalone -#ifdef XML_DTD - && !paramEntityParsing -#endif /* XML_DTD */ - && notStandaloneHandler - && !notStandaloneHandler(handlerArg)) - return XML_ERROR_NOT_STANDALONE; -#ifndef XML_DTD - break; -#else /* XML_DTD */ - if (!declEntity) { - declEntity = (ENTITY *)lookup(parser, - &dtd->paramEntities, - externalSubsetName, - sizeof(ENTITY)); - if (!declEntity) - return XML_ERROR_NO_MEMORY; - declEntity->publicId = NULL; - } - /* fall through */ -#endif /* XML_DTD */ - case XML_ROLE_ENTITY_SYSTEM_ID: - if (dtd->keepProcessing && declEntity) { - declEntity->systemId = poolStoreString(&dtd->pool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!declEntity->systemId) - return XML_ERROR_NO_MEMORY; - declEntity->base = curBase; - poolFinish(&dtd->pool); - if (entityDeclHandler) - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_ENTITY_COMPLETE: - if (dtd->keepProcessing && declEntity && entityDeclHandler) { - *eventEndPP = s; - entityDeclHandler(handlerArg, - declEntity->name, - declEntity->is_param, - 0,0, - declEntity->base, - declEntity->systemId, - declEntity->publicId, - 0); - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_ENTITY_NOTATION_NAME: - if (dtd->keepProcessing && declEntity) { - declEntity->notation = poolStoreString(&dtd->pool, enc, s, next); - if (!declEntity->notation) - return XML_ERROR_NO_MEMORY; - poolFinish(&dtd->pool); - if (unparsedEntityDeclHandler) { - *eventEndPP = s; - unparsedEntityDeclHandler(handlerArg, - declEntity->name, - declEntity->base, - declEntity->systemId, - declEntity->publicId, - declEntity->notation); - handleDefault = XML_FALSE; - } - else if (entityDeclHandler) { - *eventEndPP = s; - entityDeclHandler(handlerArg, - declEntity->name, - 0,0,0, - declEntity->base, - declEntity->systemId, - declEntity->publicId, - declEntity->notation); - handleDefault = XML_FALSE; - } - } - break; - case XML_ROLE_GENERAL_ENTITY_NAME: - { - if (XmlPredefinedEntityName(enc, s, next)) { - declEntity = NULL; - break; - } - if (dtd->keepProcessing) { - const XML_Char *name = poolStoreString(&dtd->pool, enc, s, next); - if (!name) - return XML_ERROR_NO_MEMORY; - declEntity = (ENTITY *)lookup(parser, &dtd->generalEntities, name, - sizeof(ENTITY)); - if (!declEntity) - return XML_ERROR_NO_MEMORY; - if (declEntity->name != name) { - poolDiscard(&dtd->pool); - declEntity = NULL; - } - else { - poolFinish(&dtd->pool); - declEntity->publicId = NULL; - declEntity->is_param = XML_FALSE; - /* if we have a parent parser or are reading an internal parameter - entity, then the entity declaration is not considered "internal" - */ - declEntity->is_internal = !(parentParser || openInternalEntities); - if (entityDeclHandler) - handleDefault = XML_FALSE; - } - } - else { - poolDiscard(&dtd->pool); - declEntity = NULL; - } - } - break; - case XML_ROLE_PARAM_ENTITY_NAME: -#ifdef XML_DTD - if (dtd->keepProcessing) { - const XML_Char *name = poolStoreString(&dtd->pool, enc, s, next); - if (!name) - return XML_ERROR_NO_MEMORY; - declEntity = (ENTITY *)lookup(parser, &dtd->paramEntities, - name, sizeof(ENTITY)); - if (!declEntity) - return XML_ERROR_NO_MEMORY; - if (declEntity->name != name) { - poolDiscard(&dtd->pool); - declEntity = NULL; - } - else { - poolFinish(&dtd->pool); - declEntity->publicId = NULL; - declEntity->is_param = XML_TRUE; - /* if we have a parent parser or are reading an internal parameter - entity, then the entity declaration is not considered "internal" - */ - declEntity->is_internal = !(parentParser || openInternalEntities); - if (entityDeclHandler) - handleDefault = XML_FALSE; - } - } - else { - poolDiscard(&dtd->pool); - declEntity = NULL; - } -#else /* not XML_DTD */ - declEntity = NULL; -#endif /* XML_DTD */ - break; - case XML_ROLE_NOTATION_NAME: - declNotationPublicId = NULL; - declNotationName = NULL; - if (notationDeclHandler) { - declNotationName = poolStoreString(&tempPool, enc, s, next); - if (!declNotationName) - return XML_ERROR_NO_MEMORY; - poolFinish(&tempPool); - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_NOTATION_PUBLIC_ID: - if (!XmlIsPublicId(enc, s, next, eventPP)) - return XML_ERROR_PUBLICID; - if (declNotationName) { /* means notationDeclHandler != NULL */ - XML_Char *tem = poolStoreString(&tempPool, - enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!tem) - return XML_ERROR_NO_MEMORY; - normalizePublicId(tem); - declNotationPublicId = tem; - poolFinish(&tempPool); - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_NOTATION_SYSTEM_ID: - if (declNotationName && notationDeclHandler) { - const XML_Char *systemId - = poolStoreString(&tempPool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!systemId) - return XML_ERROR_NO_MEMORY; - *eventEndPP = s; - notationDeclHandler(handlerArg, - declNotationName, - curBase, - systemId, - declNotationPublicId); - handleDefault = XML_FALSE; - } - poolClear(&tempPool); - break; - case XML_ROLE_NOTATION_NO_SYSTEM_ID: - if (declNotationPublicId && notationDeclHandler) { - *eventEndPP = s; - notationDeclHandler(handlerArg, - declNotationName, - curBase, - 0, - declNotationPublicId); - handleDefault = XML_FALSE; - } - poolClear(&tempPool); - break; - case XML_ROLE_ERROR: - switch (tok) { - case XML_TOK_PARAM_ENTITY_REF: - /* PE references in internal subset are - not allowed within declarations. */ - return XML_ERROR_PARAM_ENTITY_REF; - case XML_TOK_XML_DECL: - return XML_ERROR_MISPLACED_XML_PI; - default: - return XML_ERROR_SYNTAX; - } -#ifdef XML_DTD - case XML_ROLE_IGNORE_SECT: - { - enum XML_Error result; - if (defaultHandler) - reportDefault(parser, enc, s, next); - handleDefault = XML_FALSE; - result = doIgnoreSection(parser, enc, &next, end, nextPtr, haveMore); - if (result != XML_ERROR_NONE) - return result; - else if (!next) { - processor = ignoreSectionProcessor; - return result; - } - } - break; -#endif /* XML_DTD */ - case XML_ROLE_GROUP_OPEN: - if (prologState.level >= groupSize) { - if (groupSize) { - char *temp = (char *)REALLOC(groupConnector, groupSize *= 2); - if (temp == NULL) - return XML_ERROR_NO_MEMORY; - groupConnector = temp; - if (dtd->scaffIndex) { - int *temp = (int *)REALLOC(dtd->scaffIndex, - groupSize * sizeof(int)); - if (temp == NULL) - return XML_ERROR_NO_MEMORY; - dtd->scaffIndex = temp; - } - } - else { - groupConnector = (char *)MALLOC(groupSize = 32); - if (!groupConnector) - return XML_ERROR_NO_MEMORY; - } - } - groupConnector[prologState.level] = 0; - if (dtd->in_eldecl) { - int myindex = nextScaffoldPart(parser); - if (myindex < 0) - return XML_ERROR_NO_MEMORY; - dtd->scaffIndex[dtd->scaffLevel] = myindex; - dtd->scaffLevel++; - dtd->scaffold[myindex].type = XML_CTYPE_SEQ; - if (elementDeclHandler) - handleDefault = XML_FALSE; - } - break; - case XML_ROLE_GROUP_SEQUENCE: - if (groupConnector[prologState.level] == ASCII_PIPE) - return XML_ERROR_SYNTAX; - groupConnector[prologState.level] = ASCII_COMMA; - if (dtd->in_eldecl && elementDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_GROUP_CHOICE: - if (groupConnector[prologState.level] == ASCII_COMMA) - return XML_ERROR_SYNTAX; - if (dtd->in_eldecl - && !groupConnector[prologState.level] - && (dtd->scaffold[dtd->scaffIndex[dtd->scaffLevel - 1]].type - != XML_CTYPE_MIXED) - ) { - dtd->scaffold[dtd->scaffIndex[dtd->scaffLevel - 1]].type - = XML_CTYPE_CHOICE; - if (elementDeclHandler) - handleDefault = XML_FALSE; - } - groupConnector[prologState.level] = ASCII_PIPE; - break; - case XML_ROLE_PARAM_ENTITY_REF: -#ifdef XML_DTD - case XML_ROLE_INNER_PARAM_ENTITY_REF: - dtd->hasParamEntityRefs = XML_TRUE; - if (!paramEntityParsing) - dtd->keepProcessing = dtd->standalone; - else { - const XML_Char *name; - ENTITY *entity; - name = poolStoreString(&dtd->pool, enc, - s + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!name) - return XML_ERROR_NO_MEMORY; - entity = (ENTITY *)lookup(parser, &dtd->paramEntities, name, 0); - poolDiscard(&dtd->pool); - /* first, determine if a check for an existing declaration is needed; - if yes, check that the entity exists, and that it is internal, - otherwise call the skipped entity handler - */ - if (prologState.documentEntity && - (dtd->standalone - ? !openInternalEntities - : !dtd->hasParamEntityRefs)) { - if (!entity) - return XML_ERROR_UNDEFINED_ENTITY; - else if (!entity->is_internal) - return XML_ERROR_ENTITY_DECLARED_IN_PE; - } - else if (!entity) { - dtd->keepProcessing = dtd->standalone; - /* cannot report skipped entities in declarations */ - if ((role == XML_ROLE_PARAM_ENTITY_REF) && skippedEntityHandler) { - skippedEntityHandler(handlerArg, name, 1); - handleDefault = XML_FALSE; - } - break; - } - if (entity->open) - return XML_ERROR_RECURSIVE_ENTITY_REF; - if (entity->textPtr) { - enum XML_Error result; - XML_Bool betweenDecl = - (role == XML_ROLE_PARAM_ENTITY_REF ? XML_TRUE : XML_FALSE); - result = processInternalEntity(parser, entity, betweenDecl); - if (result != XML_ERROR_NONE) - return result; - handleDefault = XML_FALSE; - break; - } - if (externalEntityRefHandler) { - dtd->paramEntityRead = XML_FALSE; - entity->open = XML_TRUE; - if (!externalEntityRefHandler(externalEntityRefHandlerArg, - 0, - entity->base, - entity->systemId, - entity->publicId)) { - entity->open = XML_FALSE; - return XML_ERROR_EXTERNAL_ENTITY_HANDLING; - } - entity->open = XML_FALSE; - handleDefault = XML_FALSE; - if (!dtd->paramEntityRead) { - dtd->keepProcessing = dtd->standalone; - break; - } - } - else { - dtd->keepProcessing = dtd->standalone; - break; - } - } -#endif /* XML_DTD */ - if (!dtd->standalone && - notStandaloneHandler && - !notStandaloneHandler(handlerArg)) - return XML_ERROR_NOT_STANDALONE; - break; - - /* Element declaration stuff */ - - case XML_ROLE_ELEMENT_NAME: - if (elementDeclHandler) { - declElementType = getElementType(parser, enc, s, next); - if (!declElementType) - return XML_ERROR_NO_MEMORY; - dtd->scaffLevel = 0; - dtd->scaffCount = 0; - dtd->in_eldecl = XML_TRUE; - handleDefault = XML_FALSE; - } - break; - - case XML_ROLE_CONTENT_ANY: - case XML_ROLE_CONTENT_EMPTY: - if (dtd->in_eldecl) { - if (elementDeclHandler) { - XML_Content * content = (XML_Content *) MALLOC(sizeof(XML_Content)); - if (!content) - return XML_ERROR_NO_MEMORY; - content->quant = XML_CQUANT_NONE; - content->name = NULL; - content->numchildren = 0; - content->children = NULL; - content->type = ((role == XML_ROLE_CONTENT_ANY) ? - XML_CTYPE_ANY : - XML_CTYPE_EMPTY); - *eventEndPP = s; - elementDeclHandler(handlerArg, declElementType->name, content); - handleDefault = XML_FALSE; - } - dtd->in_eldecl = XML_FALSE; - } - break; - - case XML_ROLE_CONTENT_PCDATA: - if (dtd->in_eldecl) { - dtd->scaffold[dtd->scaffIndex[dtd->scaffLevel - 1]].type - = XML_CTYPE_MIXED; - if (elementDeclHandler) - handleDefault = XML_FALSE; - } - break; - - case XML_ROLE_CONTENT_ELEMENT: - quant = XML_CQUANT_NONE; - goto elementContent; - case XML_ROLE_CONTENT_ELEMENT_OPT: - quant = XML_CQUANT_OPT; - goto elementContent; - case XML_ROLE_CONTENT_ELEMENT_REP: - quant = XML_CQUANT_REP; - goto elementContent; - case XML_ROLE_CONTENT_ELEMENT_PLUS: - quant = XML_CQUANT_PLUS; - elementContent: - if (dtd->in_eldecl) { - ELEMENT_TYPE *el; - const XML_Char *name; - int nameLen; - const char *nxt = (quant == XML_CQUANT_NONE - ? next - : next - enc->minBytesPerChar); - int myindex = nextScaffoldPart(parser); - if (myindex < 0) - return XML_ERROR_NO_MEMORY; - dtd->scaffold[myindex].type = XML_CTYPE_NAME; - dtd->scaffold[myindex].quant = quant; - el = getElementType(parser, enc, s, nxt); - if (!el) - return XML_ERROR_NO_MEMORY; - name = el->name; - dtd->scaffold[myindex].name = name; - nameLen = 0; - for (; name[nameLen++]; ); - dtd->contentStringLen += nameLen; - if (elementDeclHandler) - handleDefault = XML_FALSE; - } - break; - - case XML_ROLE_GROUP_CLOSE: - quant = XML_CQUANT_NONE; - goto closeGroup; - case XML_ROLE_GROUP_CLOSE_OPT: - quant = XML_CQUANT_OPT; - goto closeGroup; - case XML_ROLE_GROUP_CLOSE_REP: - quant = XML_CQUANT_REP; - goto closeGroup; - case XML_ROLE_GROUP_CLOSE_PLUS: - quant = XML_CQUANT_PLUS; - closeGroup: - if (dtd->in_eldecl) { - if (elementDeclHandler) - handleDefault = XML_FALSE; - dtd->scaffLevel--; - dtd->scaffold[dtd->scaffIndex[dtd->scaffLevel]].quant = quant; - if (dtd->scaffLevel == 0) { - if (!handleDefault) { - XML_Content *model = build_model(parser); - if (!model) - return XML_ERROR_NO_MEMORY; - *eventEndPP = s; - elementDeclHandler(handlerArg, declElementType->name, model); - } - dtd->in_eldecl = XML_FALSE; - dtd->contentStringLen = 0; - } - } - break; - /* End element declaration stuff */ - - case XML_ROLE_PI: - if (!reportProcessingInstruction(parser, enc, s, next)) - return XML_ERROR_NO_MEMORY; - handleDefault = XML_FALSE; - break; - case XML_ROLE_COMMENT: - if (!reportComment(parser, enc, s, next)) - return XML_ERROR_NO_MEMORY; - handleDefault = XML_FALSE; - break; - case XML_ROLE_NONE: - switch (tok) { - case XML_TOK_BOM: - handleDefault = XML_FALSE; - break; - } - break; - case XML_ROLE_DOCTYPE_NONE: - if (startDoctypeDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_ENTITY_NONE: - if (dtd->keepProcessing && entityDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_NOTATION_NONE: - if (notationDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_ATTLIST_NONE: - if (dtd->keepProcessing && attlistDeclHandler) - handleDefault = XML_FALSE; - break; - case XML_ROLE_ELEMENT_NONE: - if (elementDeclHandler) - handleDefault = XML_FALSE; - break; - } /* end of big switch */ - - if (handleDefault && defaultHandler) - reportDefault(parser, enc, s, next); - - switch (ps_parsing) { - case XML_SUSPENDED: - *nextPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: - s = next; - tok = XmlPrologTok(enc, s, end, &next); - } - } - /* not reached */ -} - -static enum XML_Error PTRCALL -epilogProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - processor = epilogProcessor; - eventPtr = s; - for (;;) { - const char *next = NULL; - int tok = XmlPrologTok(encoding, s, end, &next); - eventEndPtr = next; - switch (tok) { - /* report partial linebreak - it might be the last token */ - case -XML_TOK_PROLOG_S: - if (defaultHandler) { - reportDefault(parser, encoding, s, next); - if (ps_parsing == XML_FINISHED) - return XML_ERROR_ABORTED; - } - *nextPtr = next; - return XML_ERROR_NONE; - case XML_TOK_NONE: - *nextPtr = s; - return XML_ERROR_NONE; - case XML_TOK_PROLOG_S: - if (defaultHandler) - reportDefault(parser, encoding, s, next); - break; - case XML_TOK_PI: - if (!reportProcessingInstruction(parser, encoding, s, next)) - return XML_ERROR_NO_MEMORY; - break; - case XML_TOK_COMMENT: - if (!reportComment(parser, encoding, s, next)) - return XML_ERROR_NO_MEMORY; - break; - case XML_TOK_INVALID: - eventPtr = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - if (!ps_finalBuffer) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - if (!ps_finalBuffer) { - *nextPtr = s; - return XML_ERROR_NONE; - } - return XML_ERROR_PARTIAL_CHAR; - default: - return XML_ERROR_JUNK_AFTER_DOC_ELEMENT; - } - eventPtr = s = next; - switch (ps_parsing) { - case XML_SUSPENDED: - *nextPtr = next; - return XML_ERROR_NONE; - case XML_FINISHED: - return XML_ERROR_ABORTED; - default: ; - } - } -} - -static enum XML_Error -processInternalEntity(XML_Parser parser, ENTITY *entity, - XML_Bool betweenDecl) -{ - const char *textStart, *textEnd; - const char *next; - enum XML_Error result; - OPEN_INTERNAL_ENTITY *openEntity; - - if (freeInternalEntities) { - openEntity = freeInternalEntities; - freeInternalEntities = openEntity->next; - } - else { - openEntity = (OPEN_INTERNAL_ENTITY *)MALLOC(sizeof(OPEN_INTERNAL_ENTITY)); - if (!openEntity) - return XML_ERROR_NO_MEMORY; - } - entity->open = XML_TRUE; - entity->processed = 0; - openEntity->next = openInternalEntities; - openInternalEntities = openEntity; - openEntity->entity = entity; - openEntity->startTagLevel = tagLevel; - openEntity->betweenDecl = betweenDecl; - openEntity->internalEventPtr = NULL; - openEntity->internalEventEndPtr = NULL; - textStart = (char *)entity->textPtr; - textEnd = (char *)(entity->textPtr + entity->textLen); - -#ifdef XML_DTD - if (entity->is_param) { - int tok = XmlPrologTok(internalEncoding, textStart, textEnd, &next); - result = doProlog(parser, internalEncoding, textStart, textEnd, tok, - next, &next, XML_FALSE); - } - else -#endif /* XML_DTD */ - result = doContent(parser, tagLevel, internalEncoding, textStart, - textEnd, &next, XML_FALSE); - - if (result == XML_ERROR_NONE) { - if (textEnd != next && ps_parsing == XML_SUSPENDED) { - entity->processed = (int)(next - textStart); - processor = internalEntityProcessor; - } - else { - entity->open = XML_FALSE; - openInternalEntities = openEntity->next; - /* put openEntity back in list of free instances */ - openEntity->next = freeInternalEntities; - freeInternalEntities = openEntity; - } - } - return result; -} - -static enum XML_Error PTRCALL -internalEntityProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - ENTITY *entity; - const char *textStart, *textEnd; - const char *next; - enum XML_Error result; - OPEN_INTERNAL_ENTITY *openEntity = openInternalEntities; - if (!openEntity) - return XML_ERROR_UNEXPECTED_STATE; - - entity = openEntity->entity; - textStart = ((char *)entity->textPtr) + entity->processed; - textEnd = (char *)(entity->textPtr + entity->textLen); - -#ifdef XML_DTD - if (entity->is_param) { - int tok = XmlPrologTok(internalEncoding, textStart, textEnd, &next); - result = doProlog(parser, internalEncoding, textStart, textEnd, tok, - next, &next, XML_FALSE); - } - else -#endif /* XML_DTD */ - result = doContent(parser, openEntity->startTagLevel, internalEncoding, - textStart, textEnd, &next, XML_FALSE); - - if (result != XML_ERROR_NONE) - return result; - else if (textEnd != next && ps_parsing == XML_SUSPENDED) { - entity->processed = (int)(next - (char *)entity->textPtr); - return result; - } - else { - entity->open = XML_FALSE; - openInternalEntities = openEntity->next; - /* put openEntity back in list of free instances */ - openEntity->next = freeInternalEntities; - freeInternalEntities = openEntity; - } - -#ifdef XML_DTD - if (entity->is_param) { - int tok; - processor = prologProcessor; - tok = XmlPrologTok(encoding, s, end, &next); - return doProlog(parser, encoding, s, end, tok, next, nextPtr, - (XML_Bool)!ps_finalBuffer); - } - else -#endif /* XML_DTD */ - { - processor = contentProcessor; - /* see externalEntityContentProcessor vs contentProcessor */ - return doContent(parser, parentParser ? 1 : 0, encoding, s, end, - nextPtr, (XML_Bool)!ps_finalBuffer); - } -} - -static enum XML_Error PTRCALL -errorProcessor(XML_Parser parser, - const char *s, - const char *end, - const char **nextPtr) -{ - return errorCode; -} - -static enum XML_Error -storeAttributeValue(XML_Parser parser, const ENCODING *enc, XML_Bool isCdata, - const char *ptr, const char *end, - STRING_POOL *pool) -{ - enum XML_Error result = appendAttributeValue(parser, enc, isCdata, ptr, - end, pool); - if (result) - return result; - if (!isCdata && poolLength(pool) && poolLastChar(pool) == 0x20) - poolChop(pool); - if (!poolAppendChar(pool, XML_T('\0'))) - return XML_ERROR_NO_MEMORY; - return XML_ERROR_NONE; -} - -static enum XML_Error -appendAttributeValue(XML_Parser parser, const ENCODING *enc, XML_Bool isCdata, - const char *ptr, const char *end, - STRING_POOL *pool) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - for (;;) { - const char *next; - int tok = XmlAttributeValueTok(enc, ptr, end, &next); - switch (tok) { - case XML_TOK_NONE: - return XML_ERROR_NONE; - case XML_TOK_INVALID: - if (enc == encoding) - eventPtr = next; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_PARTIAL: - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_INVALID_TOKEN; - case XML_TOK_CHAR_REF: - { - XML_Char buf[XML_ENCODE_MAX]; - int i; - int n = XmlCharRefNumber(enc, ptr); - if (n < 0) { - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_BAD_CHAR_REF; - } - if (!isCdata - && n == 0x20 /* space */ - && (poolLength(pool) == 0 || poolLastChar(pool) == 0x20)) - break; - n = XmlEncode(n, (ICHAR *)buf); - if (!n) { - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_BAD_CHAR_REF; - } - for (i = 0; i < n; i++) { - if (!poolAppendChar(pool, buf[i])) - return XML_ERROR_NO_MEMORY; - } - } - break; - case XML_TOK_DATA_CHARS: - if (!poolAppend(pool, enc, ptr, next)) - return XML_ERROR_NO_MEMORY; - break; - case XML_TOK_TRAILING_CR: - next = ptr + enc->minBytesPerChar; - /* fall through */ - case XML_TOK_ATTRIBUTE_VALUE_S: - case XML_TOK_DATA_NEWLINE: - if (!isCdata && (poolLength(pool) == 0 || poolLastChar(pool) == 0x20)) - break; - if (!poolAppendChar(pool, 0x20)) - return XML_ERROR_NO_MEMORY; - break; - case XML_TOK_ENTITY_REF: - { - const XML_Char *name; - ENTITY *entity; - char checkEntityDecl; - XML_Char ch = (XML_Char) XmlPredefinedEntityName(enc, - ptr + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (ch) { - if (!poolAppendChar(pool, ch)) - return XML_ERROR_NO_MEMORY; - break; - } - name = poolStoreString(&temp2Pool, enc, - ptr + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!name) - return XML_ERROR_NO_MEMORY; - entity = (ENTITY *)lookup(parser, &dtd->generalEntities, name, 0); - poolDiscard(&temp2Pool); - /* First, determine if a check for an existing declaration is needed; - if yes, check that the entity exists, and that it is internal. - */ - if (pool == &dtd->pool) /* are we called from prolog? */ - checkEntityDecl = -#ifdef XML_DTD - prologState.documentEntity && -#endif /* XML_DTD */ - (dtd->standalone - ? !openInternalEntities - : !dtd->hasParamEntityRefs); - else /* if (pool == &tempPool): we are called from content */ - checkEntityDecl = !dtd->hasParamEntityRefs || dtd->standalone; - if (checkEntityDecl) { - if (!entity) - return XML_ERROR_UNDEFINED_ENTITY; - else if (!entity->is_internal) - return XML_ERROR_ENTITY_DECLARED_IN_PE; - } - else if (!entity) { - /* Cannot report skipped entity here - see comments on - skippedEntityHandler. - if (skippedEntityHandler) - skippedEntityHandler(handlerArg, name, 0); - */ - /* Cannot call the default handler because this would be - out of sync with the call to the startElementHandler. - if ((pool == &tempPool) && defaultHandler) - reportDefault(parser, enc, ptr, next); - */ - break; - } - if (entity->open) { - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_RECURSIVE_ENTITY_REF; - } - if (entity->notation) { - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_BINARY_ENTITY_REF; - } - if (!entity->textPtr) { - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF; - } - else { - enum XML_Error result; - const XML_Char *textEnd = entity->textPtr + entity->textLen; - entity->open = XML_TRUE; - result = appendAttributeValue(parser, internalEncoding, isCdata, - (char *)entity->textPtr, - (char *)textEnd, pool); - entity->open = XML_FALSE; - if (result) - return result; - } - } - break; - default: - if (enc == encoding) - eventPtr = ptr; - return XML_ERROR_UNEXPECTED_STATE; - } - ptr = next; - } - /* not reached */ -} - -static enum XML_Error -storeEntityValue(XML_Parser parser, - const ENCODING *enc, - const char *entityTextPtr, - const char *entityTextEnd) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - STRING_POOL *pool = &(dtd->entityValuePool); - enum XML_Error result = XML_ERROR_NONE; -#ifdef XML_DTD - int oldInEntityValue = prologState.inEntityValue; - prologState.inEntityValue = 1; -#endif /* XML_DTD */ - /* never return Null for the value argument in EntityDeclHandler, - since this would indicate an external entity; therefore we - have to make sure that entityValuePool.start is not null */ - if (!pool->blocks) { - if (!poolGrow(pool)) - return XML_ERROR_NO_MEMORY; - } - - for (;;) { - const char *next; - int tok = XmlEntityValueTok(enc, entityTextPtr, entityTextEnd, &next); - switch (tok) { - case XML_TOK_PARAM_ENTITY_REF: -#ifdef XML_DTD - if (isParamEntity || enc != encoding) { - const XML_Char *name; - ENTITY *entity; - name = poolStoreString(&tempPool, enc, - entityTextPtr + enc->minBytesPerChar, - next - enc->minBytesPerChar); - if (!name) { - result = XML_ERROR_NO_MEMORY; - goto endEntityValue; - } - entity = (ENTITY *)lookup(parser, &dtd->paramEntities, name, 0); - poolDiscard(&tempPool); - if (!entity) { - /* not a well-formedness error - see XML 1.0: WFC Entity Declared */ - /* cannot report skipped entity here - see comments on - skippedEntityHandler - if (skippedEntityHandler) - skippedEntityHandler(handlerArg, name, 0); - */ - dtd->keepProcessing = dtd->standalone; - goto endEntityValue; - } - if (entity->open) { - if (enc == encoding) - eventPtr = entityTextPtr; - result = XML_ERROR_RECURSIVE_ENTITY_REF; - goto endEntityValue; - } - if (entity->systemId) { - if (externalEntityRefHandler) { - dtd->paramEntityRead = XML_FALSE; - entity->open = XML_TRUE; - if (!externalEntityRefHandler(externalEntityRefHandlerArg, - 0, - entity->base, - entity->systemId, - entity->publicId)) { - entity->open = XML_FALSE; - result = XML_ERROR_EXTERNAL_ENTITY_HANDLING; - goto endEntityValue; - } - entity->open = XML_FALSE; - if (!dtd->paramEntityRead) - dtd->keepProcessing = dtd->standalone; - } - else - dtd->keepProcessing = dtd->standalone; - } - else { - entity->open = XML_TRUE; - result = storeEntityValue(parser, - internalEncoding, - (char *)entity->textPtr, - (char *)(entity->textPtr - + entity->textLen)); - entity->open = XML_FALSE; - if (result) - goto endEntityValue; - } - break; - } -#endif /* XML_DTD */ - /* In the internal subset, PE references are not legal - within markup declarations, e.g entity values in this case. */ - eventPtr = entityTextPtr; - result = XML_ERROR_PARAM_ENTITY_REF; - goto endEntityValue; - case XML_TOK_NONE: - result = XML_ERROR_NONE; - goto endEntityValue; - case XML_TOK_ENTITY_REF: - case XML_TOK_DATA_CHARS: - if (!poolAppend(pool, enc, entityTextPtr, next)) { - result = XML_ERROR_NO_MEMORY; - goto endEntityValue; - } - break; - case XML_TOK_TRAILING_CR: - next = entityTextPtr + enc->minBytesPerChar; - /* fall through */ - case XML_TOK_DATA_NEWLINE: - if (pool->end == pool->ptr && !poolGrow(pool)) { - result = XML_ERROR_NO_MEMORY; - goto endEntityValue; - } - *(pool->ptr)++ = 0xA; - break; - case XML_TOK_CHAR_REF: - { - XML_Char buf[XML_ENCODE_MAX]; - int i; - int n = XmlCharRefNumber(enc, entityTextPtr); - if (n < 0) { - if (enc == encoding) - eventPtr = entityTextPtr; - result = XML_ERROR_BAD_CHAR_REF; - goto endEntityValue; - } - n = XmlEncode(n, (ICHAR *)buf); - if (!n) { - if (enc == encoding) - eventPtr = entityTextPtr; - result = XML_ERROR_BAD_CHAR_REF; - goto endEntityValue; - } - for (i = 0; i < n; i++) { - if (pool->end == pool->ptr && !poolGrow(pool)) { - result = XML_ERROR_NO_MEMORY; - goto endEntityValue; - } - *(pool->ptr)++ = buf[i]; - } - } - break; - case XML_TOK_PARTIAL: - if (enc == encoding) - eventPtr = entityTextPtr; - result = XML_ERROR_INVALID_TOKEN; - goto endEntityValue; - case XML_TOK_INVALID: - if (enc == encoding) - eventPtr = next; - result = XML_ERROR_INVALID_TOKEN; - goto endEntityValue; - default: - if (enc == encoding) - eventPtr = entityTextPtr; - result = XML_ERROR_UNEXPECTED_STATE; - goto endEntityValue; - } - entityTextPtr = next; - } -endEntityValue: -#ifdef XML_DTD - prologState.inEntityValue = oldInEntityValue; -#endif /* XML_DTD */ - return result; -} - -static void FASTCALL -normalizeLines(XML_Char *s) -{ - XML_Char *p; - for (;; s++) { - if (*s == XML_T('\0')) - return; - if (*s == 0xD) - break; - } - p = s; - do { - if (*s == 0xD) { - *p++ = 0xA; - if (*++s == 0xA) - s++; - } - else - *p++ = *s++; - } while (*s); - *p = XML_T('\0'); -} - -static int -reportProcessingInstruction(XML_Parser parser, const ENCODING *enc, - const char *start, const char *end) -{ - const XML_Char *target; - XML_Char *data; - const char *tem; - if (!processingInstructionHandler) { - if (defaultHandler) - reportDefault(parser, enc, start, end); - return 1; - } - start += enc->minBytesPerChar * 2; - tem = start + XmlNameLength(enc, start); - target = poolStoreString(&tempPool, enc, start, tem); - if (!target) - return 0; - poolFinish(&tempPool); - data = poolStoreString(&tempPool, enc, - XmlSkipS(enc, tem), - end - enc->minBytesPerChar*2); - if (!data) - return 0; - normalizeLines(data); - processingInstructionHandler(handlerArg, target, data); - poolClear(&tempPool); - return 1; -} - -static int -reportComment(XML_Parser parser, const ENCODING *enc, - const char *start, const char *end) -{ - XML_Char *data; - if (!commentHandler) { - if (defaultHandler) - reportDefault(parser, enc, start, end); - return 1; - } - data = poolStoreString(&tempPool, - enc, - start + enc->minBytesPerChar * 4, - end - enc->minBytesPerChar * 3); - if (!data) - return 0; - normalizeLines(data); - commentHandler(handlerArg, data); - poolClear(&tempPool); - return 1; -} - -static void -reportDefault(XML_Parser parser, const ENCODING *enc, - const char *s, const char *end) -{ - if (MUST_CONVERT(enc, s)) { - const char **eventPP; - const char **eventEndPP; - if (enc == encoding) { - eventPP = &eventPtr; - eventEndPP = &eventEndPtr; - } - else { - eventPP = &(openInternalEntities->internalEventPtr); - eventEndPP = &(openInternalEntities->internalEventEndPtr); - } - do { - ICHAR *dataPtr = (ICHAR *)dataBuf; - XmlConvert(enc, &s, end, &dataPtr, (ICHAR *)dataBufEnd); - *eventEndPP = s; - defaultHandler(handlerArg, dataBuf, (int)(dataPtr - (ICHAR *)dataBuf)); - *eventPP = s; - } while (s != end); - } - else - defaultHandler(handlerArg, (XML_Char *)s, (int)((XML_Char *)end - (XML_Char *)s)); -} - - -static int -defineAttribute(ELEMENT_TYPE *type, ATTRIBUTE_ID *attId, XML_Bool isCdata, - XML_Bool isId, const XML_Char *value, XML_Parser parser) -{ - DEFAULT_ATTRIBUTE *att; - if (value || isId) { - /* The handling of default attributes gets messed up if we have - a default which duplicates a non-default. */ - int i; - for (i = 0; i < type->nDefaultAtts; i++) - if (attId == type->defaultAtts[i].id) - return 1; - if (isId && !type->idAtt && !attId->xmlns) - type->idAtt = attId; - } - if (type->nDefaultAtts == type->allocDefaultAtts) { - if (type->allocDefaultAtts == 0) { - type->allocDefaultAtts = 8; - type->defaultAtts = (DEFAULT_ATTRIBUTE *)MALLOC(type->allocDefaultAtts - * sizeof(DEFAULT_ATTRIBUTE)); - if (!type->defaultAtts) - return 0; - } - else { - DEFAULT_ATTRIBUTE *temp; - int count = type->allocDefaultAtts * 2; - temp = (DEFAULT_ATTRIBUTE *) - REALLOC(type->defaultAtts, (count * sizeof(DEFAULT_ATTRIBUTE))); - if (temp == NULL) - return 0; - type->allocDefaultAtts = count; - type->defaultAtts = temp; - } - } - att = type->defaultAtts + type->nDefaultAtts; - att->id = attId; - att->value = value; - att->isCdata = isCdata; - if (!isCdata) - attId->maybeTokenized = XML_TRUE; - type->nDefaultAtts += 1; - return 1; -} - -static int -setElementTypePrefix(XML_Parser parser, ELEMENT_TYPE *elementType) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - const XML_Char *name; - for (name = elementType->name; *name; name++) { - if (*name == XML_T(ASCII_COLON)) { - PREFIX *prefix; - const XML_Char *s; - for (s = elementType->name; s != name; s++) { - if (!poolAppendChar(&dtd->pool, *s)) - return 0; - } - if (!poolAppendChar(&dtd->pool, XML_T('\0'))) - return 0; - prefix = (PREFIX *)lookup(parser, &dtd->prefixes, poolStart(&dtd->pool), - sizeof(PREFIX)); - if (!prefix) - return 0; - if (prefix->name == poolStart(&dtd->pool)) - poolFinish(&dtd->pool); - else - poolDiscard(&dtd->pool); - elementType->prefix = prefix; - - } - } - return 1; -} - -static ATTRIBUTE_ID * -getAttributeId(XML_Parser parser, const ENCODING *enc, - const char *start, const char *end) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - ATTRIBUTE_ID *id; - const XML_Char *name; - if (!poolAppendChar(&dtd->pool, XML_T('\0'))) - return NULL; - name = poolStoreString(&dtd->pool, enc, start, end); - if (!name) - return NULL; - /* skip quotation mark - its storage will be re-used (like in name[-1]) */ - ++name; - id = (ATTRIBUTE_ID *)lookup(parser, &dtd->attributeIds, name, sizeof(ATTRIBUTE_ID)); - if (!id) - return NULL; - if (id->name != name) - poolDiscard(&dtd->pool); - else { - poolFinish(&dtd->pool); - if (!ns) - ; - else if (name[0] == XML_T(ASCII_x) - && name[1] == XML_T(ASCII_m) - && name[2] == XML_T(ASCII_l) - && name[3] == XML_T(ASCII_n) - && name[4] == XML_T(ASCII_s) - && (name[5] == XML_T('\0') || name[5] == XML_T(ASCII_COLON))) { - if (name[5] == XML_T('\0')) - id->prefix = &dtd->defaultPrefix; - else - id->prefix = (PREFIX *)lookup(parser, &dtd->prefixes, name + 6, sizeof(PREFIX)); - id->xmlns = XML_TRUE; - } - else { - int i; - for (i = 0; name[i]; i++) { - /* attributes without prefix are *not* in the default namespace */ - if (name[i] == XML_T(ASCII_COLON)) { - int j; - for (j = 0; j < i; j++) { - if (!poolAppendChar(&dtd->pool, name[j])) - return NULL; - } - if (!poolAppendChar(&dtd->pool, XML_T('\0'))) - return NULL; - id->prefix = (PREFIX *)lookup(parser, &dtd->prefixes, poolStart(&dtd->pool), - sizeof(PREFIX)); - if (id->prefix->name == poolStart(&dtd->pool)) - poolFinish(&dtd->pool); - else - poolDiscard(&dtd->pool); - break; - } - } - } - } - return id; -} - -#define CONTEXT_SEP XML_T(ASCII_FF) - -static const XML_Char * -getContext(XML_Parser parser) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - HASH_TABLE_ITER iter; - XML_Bool needSep = XML_FALSE; - - if (dtd->defaultPrefix.binding) { - int i; - int len; - if (!poolAppendChar(&tempPool, XML_T(ASCII_EQUALS))) - return NULL; - len = dtd->defaultPrefix.binding->uriLen; - if (namespaceSeparator) - len--; - for (i = 0; i < len; i++) - if (!poolAppendChar(&tempPool, dtd->defaultPrefix.binding->uri[i])) - return NULL; - needSep = XML_TRUE; - } - - hashTableIterInit(&iter, &(dtd->prefixes)); - for (;;) { - int i; - int len; - const XML_Char *s; - PREFIX *prefix = (PREFIX *)hashTableIterNext(&iter); - if (!prefix) - break; - if (!prefix->binding) - continue; - if (needSep && !poolAppendChar(&tempPool, CONTEXT_SEP)) - return NULL; - for (s = prefix->name; *s; s++) - if (!poolAppendChar(&tempPool, *s)) - return NULL; - if (!poolAppendChar(&tempPool, XML_T(ASCII_EQUALS))) - return NULL; - len = prefix->binding->uriLen; - if (namespaceSeparator) - len--; - for (i = 0; i < len; i++) - if (!poolAppendChar(&tempPool, prefix->binding->uri[i])) - return NULL; - needSep = XML_TRUE; - } - - - hashTableIterInit(&iter, &(dtd->generalEntities)); - for (;;) { - const XML_Char *s; - ENTITY *e = (ENTITY *)hashTableIterNext(&iter); - if (!e) - break; - if (!e->open) - continue; - if (needSep && !poolAppendChar(&tempPool, CONTEXT_SEP)) - return NULL; - for (s = e->name; *s; s++) - if (!poolAppendChar(&tempPool, *s)) - return 0; - needSep = XML_TRUE; - } - - if (!poolAppendChar(&tempPool, XML_T('\0'))) - return NULL; - return tempPool.start; -} - -static XML_Bool -setContext(XML_Parser parser, const XML_Char *context) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - const XML_Char *s = context; - - while (*context != XML_T('\0')) { - if (*s == CONTEXT_SEP || *s == XML_T('\0')) { - ENTITY *e; - if (!poolAppendChar(&tempPool, XML_T('\0'))) - return XML_FALSE; - e = (ENTITY *)lookup(parser, &dtd->generalEntities, poolStart(&tempPool), 0); - if (e) - e->open = XML_TRUE; - if (*s != XML_T('\0')) - s++; - context = s; - poolDiscard(&tempPool); - } - else if (*s == XML_T(ASCII_EQUALS)) { - PREFIX *prefix; - if (poolLength(&tempPool) == 0) - prefix = &dtd->defaultPrefix; - else { - if (!poolAppendChar(&tempPool, XML_T('\0'))) - return XML_FALSE; - prefix = (PREFIX *)lookup(parser, &dtd->prefixes, poolStart(&tempPool), - sizeof(PREFIX)); - if (!prefix) - return XML_FALSE; - if (prefix->name == poolStart(&tempPool)) { - prefix->name = poolCopyString(&dtd->pool, prefix->name); - if (!prefix->name) - return XML_FALSE; - } - poolDiscard(&tempPool); - } - for (context = s + 1; - *context != CONTEXT_SEP && *context != XML_T('\0'); - context++) - if (!poolAppendChar(&tempPool, *context)) - return XML_FALSE; - if (!poolAppendChar(&tempPool, XML_T('\0'))) - return XML_FALSE; - if (addBinding(parser, prefix, NULL, poolStart(&tempPool), - &inheritedBindings) != XML_ERROR_NONE) - return XML_FALSE; - poolDiscard(&tempPool); - if (*context != XML_T('\0')) - ++context; - s = context; - } - else { - if (!poolAppendChar(&tempPool, *s)) - return XML_FALSE; - s++; - } - } - return XML_TRUE; -} - -static void FASTCALL -normalizePublicId(XML_Char *publicId) -{ - XML_Char *p = publicId; - XML_Char *s; - for (s = publicId; *s; s++) { - switch (*s) { - case 0x20: - case 0xD: - case 0xA: - if (p != publicId && p[-1] != 0x20) - *p++ = 0x20; - break; - default: - *p++ = *s; - } - } - if (p != publicId && p[-1] == 0x20) - --p; - *p = XML_T('\0'); -} - -static DTD * -dtdCreate(const XML_Memory_Handling_Suite *ms) -{ - DTD *p = (DTD *)ms->malloc_fcn(sizeof(DTD)); - if (p == NULL) - return p; - poolInit(&(p->pool), ms); - poolInit(&(p->entityValuePool), ms); - hashTableInit(&(p->generalEntities), ms); - hashTableInit(&(p->elementTypes), ms); - hashTableInit(&(p->attributeIds), ms); - hashTableInit(&(p->prefixes), ms); -#ifdef XML_DTD - p->paramEntityRead = XML_FALSE; - hashTableInit(&(p->paramEntities), ms); -#endif /* XML_DTD */ - p->defaultPrefix.name = NULL; - p->defaultPrefix.binding = NULL; - - p->in_eldecl = XML_FALSE; - p->scaffIndex = NULL; - p->scaffold = NULL; - p->scaffLevel = 0; - p->scaffSize = 0; - p->scaffCount = 0; - p->contentStringLen = 0; - - p->keepProcessing = XML_TRUE; - p->hasParamEntityRefs = XML_FALSE; - p->standalone = XML_FALSE; - return p; -} - -static void -dtdReset(DTD *p, const XML_Memory_Handling_Suite *ms) -{ - HASH_TABLE_ITER iter; - hashTableIterInit(&iter, &(p->elementTypes)); - for (;;) { - ELEMENT_TYPE *e = (ELEMENT_TYPE *)hashTableIterNext(&iter); - if (!e) - break; - if (e->allocDefaultAtts != 0) - ms->free_fcn(e->defaultAtts); - } - hashTableClear(&(p->generalEntities)); -#ifdef XML_DTD - p->paramEntityRead = XML_FALSE; - hashTableClear(&(p->paramEntities)); -#endif /* XML_DTD */ - hashTableClear(&(p->elementTypes)); - hashTableClear(&(p->attributeIds)); - hashTableClear(&(p->prefixes)); - poolClear(&(p->pool)); - poolClear(&(p->entityValuePool)); - p->defaultPrefix.name = NULL; - p->defaultPrefix.binding = NULL; - - p->in_eldecl = XML_FALSE; - - ms->free_fcn(p->scaffIndex); - p->scaffIndex = NULL; - ms->free_fcn(p->scaffold); - p->scaffold = NULL; - - p->scaffLevel = 0; - p->scaffSize = 0; - p->scaffCount = 0; - p->contentStringLen = 0; - - p->keepProcessing = XML_TRUE; - p->hasParamEntityRefs = XML_FALSE; - p->standalone = XML_FALSE; -} - -static void -dtdDestroy(DTD *p, XML_Bool isDocEntity, const XML_Memory_Handling_Suite *ms) -{ - HASH_TABLE_ITER iter; - hashTableIterInit(&iter, &(p->elementTypes)); - for (;;) { - ELEMENT_TYPE *e = (ELEMENT_TYPE *)hashTableIterNext(&iter); - if (!e) - break; - if (e->allocDefaultAtts != 0) - ms->free_fcn(e->defaultAtts); - } - hashTableDestroy(&(p->generalEntities)); -#ifdef XML_DTD - hashTableDestroy(&(p->paramEntities)); -#endif /* XML_DTD */ - hashTableDestroy(&(p->elementTypes)); - hashTableDestroy(&(p->attributeIds)); - hashTableDestroy(&(p->prefixes)); - poolDestroy(&(p->pool)); - poolDestroy(&(p->entityValuePool)); - if (isDocEntity) { - ms->free_fcn(p->scaffIndex); - ms->free_fcn(p->scaffold); - } - ms->free_fcn(p); -} - -/* Do a deep copy of the DTD. Return 0 for out of memory, non-zero otherwise. - The new DTD has already been initialized. -*/ -static int -dtdCopy(XML_Parser oldParser, DTD *newDtd, const DTD *oldDtd, const XML_Memory_Handling_Suite *ms) -{ - HASH_TABLE_ITER iter; - - /* Copy the prefix table. */ - - hashTableIterInit(&iter, &(oldDtd->prefixes)); - for (;;) { - const XML_Char *name; - const PREFIX *oldP = (PREFIX *)hashTableIterNext(&iter); - if (!oldP) - break; - name = poolCopyString(&(newDtd->pool), oldP->name); - if (!name) - return 0; - if (!lookup(oldParser, &(newDtd->prefixes), name, sizeof(PREFIX))) - return 0; - } - - hashTableIterInit(&iter, &(oldDtd->attributeIds)); - - /* Copy the attribute id table. */ - - for (;;) { - ATTRIBUTE_ID *newA; - const XML_Char *name; - const ATTRIBUTE_ID *oldA = (ATTRIBUTE_ID *)hashTableIterNext(&iter); - - if (!oldA) - break; - /* Remember to allocate the scratch byte before the name. */ - if (!poolAppendChar(&(newDtd->pool), XML_T('\0'))) - return 0; - name = poolCopyString(&(newDtd->pool), oldA->name); - if (!name) - return 0; - ++name; - newA = (ATTRIBUTE_ID *)lookup(oldParser, &(newDtd->attributeIds), name, - sizeof(ATTRIBUTE_ID)); - if (!newA) - return 0; - newA->maybeTokenized = oldA->maybeTokenized; - if (oldA->prefix) { - newA->xmlns = oldA->xmlns; - if (oldA->prefix == &oldDtd->defaultPrefix) - newA->prefix = &newDtd->defaultPrefix; - else - newA->prefix = (PREFIX *)lookup(oldParser, &(newDtd->prefixes), - oldA->prefix->name, 0); - } - } - - /* Copy the element type table. */ - - hashTableIterInit(&iter, &(oldDtd->elementTypes)); - - for (;;) { - int i; - ELEMENT_TYPE *newE; - const XML_Char *name; - const ELEMENT_TYPE *oldE = (ELEMENT_TYPE *)hashTableIterNext(&iter); - if (!oldE) - break; - name = poolCopyString(&(newDtd->pool), oldE->name); - if (!name) - return 0; - newE = (ELEMENT_TYPE *)lookup(oldParser, &(newDtd->elementTypes), name, - sizeof(ELEMENT_TYPE)); - if (!newE) - return 0; - if (oldE->nDefaultAtts) { - newE->defaultAtts = (DEFAULT_ATTRIBUTE *) - ms->malloc_fcn(oldE->nDefaultAtts * sizeof(DEFAULT_ATTRIBUTE)); - if (!newE->defaultAtts) { - ms->free_fcn(newE); - return 0; - } - } - if (oldE->idAtt) - newE->idAtt = (ATTRIBUTE_ID *) - lookup(oldParser, &(newDtd->attributeIds), oldE->idAtt->name, 0); - newE->allocDefaultAtts = newE->nDefaultAtts = oldE->nDefaultAtts; - if (oldE->prefix) - newE->prefix = (PREFIX *)lookup(oldParser, &(newDtd->prefixes), - oldE->prefix->name, 0); - for (i = 0; i < newE->nDefaultAtts; i++) { - newE->defaultAtts[i].id = (ATTRIBUTE_ID *) - lookup(oldParser, &(newDtd->attributeIds), oldE->defaultAtts[i].id->name, 0); - newE->defaultAtts[i].isCdata = oldE->defaultAtts[i].isCdata; - if (oldE->defaultAtts[i].value) { - newE->defaultAtts[i].value - = poolCopyString(&(newDtd->pool), oldE->defaultAtts[i].value); - if (!newE->defaultAtts[i].value) - return 0; - } - else - newE->defaultAtts[i].value = NULL; - } - } - - /* Copy the entity tables. */ - if (!copyEntityTable(oldParser, - &(newDtd->generalEntities), - &(newDtd->pool), - &(oldDtd->generalEntities))) - return 0; - -#ifdef XML_DTD - if (!copyEntityTable(oldParser, - &(newDtd->paramEntities), - &(newDtd->pool), - &(oldDtd->paramEntities))) - return 0; - newDtd->paramEntityRead = oldDtd->paramEntityRead; -#endif /* XML_DTD */ - - newDtd->keepProcessing = oldDtd->keepProcessing; - newDtd->hasParamEntityRefs = oldDtd->hasParamEntityRefs; - newDtd->standalone = oldDtd->standalone; - - /* Don't want deep copying for scaffolding */ - newDtd->in_eldecl = oldDtd->in_eldecl; - newDtd->scaffold = oldDtd->scaffold; - newDtd->contentStringLen = oldDtd->contentStringLen; - newDtd->scaffSize = oldDtd->scaffSize; - newDtd->scaffLevel = oldDtd->scaffLevel; - newDtd->scaffIndex = oldDtd->scaffIndex; - - return 1; -} /* End dtdCopy */ - -static int -copyEntityTable(XML_Parser oldParser, - HASH_TABLE *newTable, - STRING_POOL *newPool, - const HASH_TABLE *oldTable) -{ - HASH_TABLE_ITER iter; - const XML_Char *cachedOldBase = NULL; - const XML_Char *cachedNewBase = NULL; - - hashTableIterInit(&iter, oldTable); - - for (;;) { - ENTITY *newE; - const XML_Char *name; - const ENTITY *oldE = (ENTITY *)hashTableIterNext(&iter); - if (!oldE) - break; - name = poolCopyString(newPool, oldE->name); - if (!name) - return 0; - newE = (ENTITY *)lookup(oldParser, newTable, name, sizeof(ENTITY)); - if (!newE) - return 0; - if (oldE->systemId) { - const XML_Char *tem = poolCopyString(newPool, oldE->systemId); - if (!tem) - return 0; - newE->systemId = tem; - if (oldE->base) { - if (oldE->base == cachedOldBase) - newE->base = cachedNewBase; - else { - cachedOldBase = oldE->base; - tem = poolCopyString(newPool, cachedOldBase); - if (!tem) - return 0; - cachedNewBase = newE->base = tem; - } - } - if (oldE->publicId) { - tem = poolCopyString(newPool, oldE->publicId); - if (!tem) - return 0; - newE->publicId = tem; - } - } - else { - const XML_Char *tem = poolCopyStringN(newPool, oldE->textPtr, - oldE->textLen); - if (!tem) - return 0; - newE->textPtr = tem; - newE->textLen = oldE->textLen; - } - if (oldE->notation) { - const XML_Char *tem = poolCopyString(newPool, oldE->notation); - if (!tem) - return 0; - newE->notation = tem; - } - newE->is_param = oldE->is_param; - newE->is_internal = oldE->is_internal; - } - return 1; -} - -#define INIT_POWER 6 - -static XML_Bool FASTCALL -keyeq(KEY s1, KEY s2) -{ - for (; *s1 == *s2; s1++, s2++) - if (*s1 == 0) - return XML_TRUE; - return XML_FALSE; -} - -static unsigned long FASTCALL -hash(XML_Parser parser, KEY s) -{ - unsigned long h = hash_secret_salt; - while (*s) - h = CHAR_HASH(h, *s++); - return h; -} - -static NAMED * -lookup(XML_Parser parser, HASH_TABLE *table, KEY name, size_t createSize) -{ - size_t i; - if (table->size == 0) { - size_t tsize; - if (!createSize) - return NULL; - table->power = INIT_POWER; - /* table->size is a power of 2 */ - table->size = (size_t)1 << INIT_POWER; - tsize = table->size * sizeof(NAMED *); - table->v = (NAMED **)table->mem->malloc_fcn(tsize); - if (!table->v) { - table->size = 0; - return NULL; - } - memset(table->v, 0, tsize); - i = hash(parser, name) & ((unsigned long)table->size - 1); - } - else { - unsigned long h = hash(parser, name); - unsigned long mask = (unsigned long)table->size - 1; - unsigned char step = 0; - i = h & mask; - while (table->v[i]) { - if (keyeq(name, table->v[i]->name)) - return table->v[i]; - if (!step) - step = PROBE_STEP(h, mask, table->power); - i < step ? (i += table->size - step) : (i -= step); - } - if (!createSize) - return NULL; - - /* check for overflow (table is half full) */ - if (table->used >> (table->power - 1)) { - unsigned char newPower = table->power + 1; - size_t newSize = (size_t)1 << newPower; - unsigned long newMask = (unsigned long)newSize - 1; - size_t tsize = newSize * sizeof(NAMED *); - NAMED **newV = (NAMED **)table->mem->malloc_fcn(tsize); - if (!newV) - return NULL; - memset(newV, 0, tsize); - for (i = 0; i < table->size; i++) - if (table->v[i]) { - unsigned long newHash = hash(parser, table->v[i]->name); - size_t j = newHash & newMask; - step = 0; - while (newV[j]) { - if (!step) - step = PROBE_STEP(newHash, newMask, newPower); - j < step ? (j += newSize - step) : (j -= step); - } - newV[j] = table->v[i]; - } - table->mem->free_fcn(table->v); - table->v = newV; - table->power = newPower; - table->size = newSize; - i = h & newMask; - step = 0; - while (table->v[i]) { - if (!step) - step = PROBE_STEP(h, newMask, newPower); - i < step ? (i += newSize - step) : (i -= step); - } - } - } - table->v[i] = (NAMED *)table->mem->malloc_fcn(createSize); - if (!table->v[i]) - return NULL; - memset(table->v[i], 0, createSize); - table->v[i]->name = name; - (table->used)++; - return table->v[i]; -} - -static void FASTCALL -hashTableClear(HASH_TABLE *table) -{ - size_t i; - for (i = 0; i < table->size; i++) { - table->mem->free_fcn(table->v[i]); - table->v[i] = NULL; - } - table->used = 0; -} - -static void FASTCALL -hashTableDestroy(HASH_TABLE *table) -{ - size_t i; - for (i = 0; i < table->size; i++) - table->mem->free_fcn(table->v[i]); - table->mem->free_fcn(table->v); -} - -static void FASTCALL -hashTableInit(HASH_TABLE *p, const XML_Memory_Handling_Suite *ms) -{ - p->power = 0; - p->size = 0; - p->used = 0; - p->v = NULL; - p->mem = ms; -} - -static void FASTCALL -hashTableIterInit(HASH_TABLE_ITER *iter, const HASH_TABLE *table) -{ - iter->p = table->v; - iter->end = iter->p + table->size; -} - -static NAMED * FASTCALL -hashTableIterNext(HASH_TABLE_ITER *iter) -{ - while (iter->p != iter->end) { - NAMED *tem = *(iter->p)++; - if (tem) - return tem; - } - return NULL; -} - -static void FASTCALL -poolInit(STRING_POOL *pool, const XML_Memory_Handling_Suite *ms) -{ - pool->blocks = NULL; - pool->freeBlocks = NULL; - pool->start = NULL; - pool->ptr = NULL; - pool->end = NULL; - pool->mem = ms; -} - -static void FASTCALL -poolClear(STRING_POOL *pool) -{ - if (!pool->freeBlocks) - pool->freeBlocks = pool->blocks; - else { - BLOCK *p = pool->blocks; - while (p) { - BLOCK *tem = p->next; - p->next = pool->freeBlocks; - pool->freeBlocks = p; - p = tem; - } - } - pool->blocks = NULL; - pool->start = NULL; - pool->ptr = NULL; - pool->end = NULL; -} - -static void FASTCALL -poolDestroy(STRING_POOL *pool) -{ - BLOCK *p = pool->blocks; - while (p) { - BLOCK *tem = p->next; - pool->mem->free_fcn(p); - p = tem; - } - p = pool->freeBlocks; - while (p) { - BLOCK *tem = p->next; - pool->mem->free_fcn(p); - p = tem; - } -} - -static XML_Char * -poolAppend(STRING_POOL *pool, const ENCODING *enc, - const char *ptr, const char *end) -{ - if (!pool->ptr && !poolGrow(pool)) - return NULL; - for (;;) { - XmlConvert(enc, &ptr, end, (ICHAR **)&(pool->ptr), (ICHAR *)pool->end); - if (ptr == end) - break; - if (!poolGrow(pool)) - return NULL; - } - return pool->start; -} - -static const XML_Char * FASTCALL -poolCopyString(STRING_POOL *pool, const XML_Char *s) -{ - do { - if (!poolAppendChar(pool, *s)) - return NULL; - } while (*s++); - s = pool->start; - poolFinish(pool); - return s; -} - -static const XML_Char * -poolCopyStringN(STRING_POOL *pool, const XML_Char *s, int n) -{ - if (!pool->ptr && !poolGrow(pool)) - return NULL; - for (; n > 0; --n, s++) { - if (!poolAppendChar(pool, *s)) - return NULL; - } - s = pool->start; - poolFinish(pool); - return s; -} - -static const XML_Char * FASTCALL -poolAppendString(STRING_POOL *pool, const XML_Char *s) -{ - while (*s) { - if (!poolAppendChar(pool, *s)) - return NULL; - s++; - } - return pool->start; -} - -static XML_Char * -poolStoreString(STRING_POOL *pool, const ENCODING *enc, - const char *ptr, const char *end) -{ - if (!poolAppend(pool, enc, ptr, end)) - return NULL; - if (pool->ptr == pool->end && !poolGrow(pool)) - return NULL; - *(pool->ptr)++ = 0; - return pool->start; -} - -static XML_Bool FASTCALL -poolGrow(STRING_POOL *pool) -{ - if (pool->freeBlocks) { - if (pool->start == 0) { - pool->blocks = pool->freeBlocks; - pool->freeBlocks = pool->freeBlocks->next; - pool->blocks->next = NULL; - pool->start = pool->blocks->s; - pool->end = pool->start + pool->blocks->size; - pool->ptr = pool->start; - return XML_TRUE; - } - if (pool->end - pool->start < pool->freeBlocks->size) { - BLOCK *tem = pool->freeBlocks->next; - pool->freeBlocks->next = pool->blocks; - pool->blocks = pool->freeBlocks; - pool->freeBlocks = tem; - memcpy(pool->blocks->s, pool->start, - (pool->end - pool->start) * sizeof(XML_Char)); - pool->ptr = pool->blocks->s + (pool->ptr - pool->start); - pool->start = pool->blocks->s; - pool->end = pool->start + pool->blocks->size; - return XML_TRUE; - } - } - if (pool->blocks && pool->start == pool->blocks->s) { - int blockSize = (int)(pool->end - pool->start)*2; - BLOCK *temp = (BLOCK *) - pool->mem->realloc_fcn(pool->blocks, - (offsetof(BLOCK, s) - + blockSize * sizeof(XML_Char))); - if (temp == NULL) - return XML_FALSE; - pool->blocks = temp; - pool->blocks->size = blockSize; - pool->ptr = pool->blocks->s + (pool->ptr - pool->start); - pool->start = pool->blocks->s; - pool->end = pool->start + blockSize; - } - else { - BLOCK *tem; - int blockSize = (int)(pool->end - pool->start); - if (blockSize < INIT_BLOCK_SIZE) - blockSize = INIT_BLOCK_SIZE; - else - blockSize *= 2; - tem = (BLOCK *)pool->mem->malloc_fcn(offsetof(BLOCK, s) - + blockSize * sizeof(XML_Char)); - if (!tem) - return XML_FALSE; - tem->size = blockSize; - tem->next = pool->blocks; - pool->blocks = tem; - if (pool->ptr != pool->start) - memcpy(tem->s, pool->start, - (pool->ptr - pool->start) * sizeof(XML_Char)); - pool->ptr = tem->s + (pool->ptr - pool->start); - pool->start = tem->s; - pool->end = tem->s + blockSize; - } - return XML_TRUE; -} - -static int FASTCALL -nextScaffoldPart(XML_Parser parser) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - CONTENT_SCAFFOLD * me; - int next; - - if (!dtd->scaffIndex) { - dtd->scaffIndex = (int *)MALLOC(groupSize * sizeof(int)); - if (!dtd->scaffIndex) - return -1; - dtd->scaffIndex[0] = 0; - } - - if (dtd->scaffCount >= dtd->scaffSize) { - CONTENT_SCAFFOLD *temp; - if (dtd->scaffold) { - temp = (CONTENT_SCAFFOLD *) - REALLOC(dtd->scaffold, dtd->scaffSize * 2 * sizeof(CONTENT_SCAFFOLD)); - if (temp == NULL) - return -1; - dtd->scaffSize *= 2; - } - else { - temp = (CONTENT_SCAFFOLD *)MALLOC(INIT_SCAFFOLD_ELEMENTS - * sizeof(CONTENT_SCAFFOLD)); - if (temp == NULL) - return -1; - dtd->scaffSize = INIT_SCAFFOLD_ELEMENTS; - } - dtd->scaffold = temp; - } - next = dtd->scaffCount++; - me = &dtd->scaffold[next]; - if (dtd->scaffLevel) { - CONTENT_SCAFFOLD *parent = &dtd->scaffold[dtd->scaffIndex[dtd->scaffLevel-1]]; - if (parent->lastchild) { - dtd->scaffold[parent->lastchild].nextsib = next; - } - if (!parent->childcnt) - parent->firstchild = next; - parent->lastchild = next; - parent->childcnt++; - } - me->firstchild = me->lastchild = me->childcnt = me->nextsib = 0; - return next; -} - -static void -build_node(XML_Parser parser, - int src_node, - XML_Content *dest, - XML_Content **contpos, - XML_Char **strpos) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - dest->type = dtd->scaffold[src_node].type; - dest->quant = dtd->scaffold[src_node].quant; - if (dest->type == XML_CTYPE_NAME) { - const XML_Char *src; - dest->name = *strpos; - src = dtd->scaffold[src_node].name; - for (;;) { - *(*strpos)++ = *src; - if (!*src) - break; - src++; - } - dest->numchildren = 0; - dest->children = NULL; - } - else { - unsigned int i; - int cn; - dest->numchildren = dtd->scaffold[src_node].childcnt; - dest->children = *contpos; - *contpos += dest->numchildren; - for (i = 0, cn = dtd->scaffold[src_node].firstchild; - i < dest->numchildren; - i++, cn = dtd->scaffold[cn].nextsib) { - build_node(parser, cn, &(dest->children[i]), contpos, strpos); - } - dest->name = NULL; - } -} - -static XML_Content * -build_model (XML_Parser parser) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - XML_Content *ret; - XML_Content *cpos; - XML_Char * str; - int allocsize = (dtd->scaffCount * sizeof(XML_Content) - + (dtd->contentStringLen * sizeof(XML_Char))); - - ret = (XML_Content *)MALLOC(allocsize); - if (!ret) - return NULL; - - str = (XML_Char *) (&ret[dtd->scaffCount]); - cpos = &ret[1]; - - build_node(parser, 0, ret, &cpos, &str); - return ret; -} - -static ELEMENT_TYPE * -getElementType(XML_Parser parser, - const ENCODING *enc, - const char *ptr, - const char *end) -{ - DTD * const dtd = _dtd; /* save one level of indirection */ - const XML_Char *name = poolStoreString(&dtd->pool, enc, ptr, end); - ELEMENT_TYPE *ret; - - if (!name) - return NULL; - ret = (ELEMENT_TYPE *) lookup(parser, &dtd->elementTypes, name, sizeof(ELEMENT_TYPE)); - if (!ret) - return NULL; - if (ret->name != name) - poolDiscard(&dtd->pool); - else { - poolFinish(&dtd->pool); - if (!setElementTypePrefix(parser, ret)) - return NULL; - } - return ret; -} diff --git a/lib-src/expat/lib/xmlrole.c b/lib-src/expat/lib/xmlrole.c deleted file mode 100644 index 44772e21d..000000000 --- a/lib-src/expat/lib/xmlrole.c +++ /dev/null @@ -1,1336 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include - -#ifdef COMPILED_FROM_DSP -#include "winconfig.h" -#elif defined(MACOS_CLASSIC) -#include "macconfig.h" -#elif defined(__amigaos__) -#include "amigaconfig.h" -#elif defined(__WATCOMC__) -#include "watcomconfig.h" -#else -#ifdef HAVE_EXPAT_CONFIG_H -#include -#endif -#endif /* ndef COMPILED_FROM_DSP */ - -#include "expat_external.h" -#include "internal.h" -#include "xmlrole.h" -#include "ascii.h" - -/* Doesn't check: - - that ,| are not mixed in a model group - content of literals - -*/ - -static const char KW_ANY[] = { - ASCII_A, ASCII_N, ASCII_Y, '\0' }; -static const char KW_ATTLIST[] = { - ASCII_A, ASCII_T, ASCII_T, ASCII_L, ASCII_I, ASCII_S, ASCII_T, '\0' }; -static const char KW_CDATA[] = { - ASCII_C, ASCII_D, ASCII_A, ASCII_T, ASCII_A, '\0' }; -static const char KW_DOCTYPE[] = { - ASCII_D, ASCII_O, ASCII_C, ASCII_T, ASCII_Y, ASCII_P, ASCII_E, '\0' }; -static const char KW_ELEMENT[] = { - ASCII_E, ASCII_L, ASCII_E, ASCII_M, ASCII_E, ASCII_N, ASCII_T, '\0' }; -static const char KW_EMPTY[] = { - ASCII_E, ASCII_M, ASCII_P, ASCII_T, ASCII_Y, '\0' }; -static const char KW_ENTITIES[] = { - ASCII_E, ASCII_N, ASCII_T, ASCII_I, ASCII_T, ASCII_I, ASCII_E, ASCII_S, - '\0' }; -static const char KW_ENTITY[] = { - ASCII_E, ASCII_N, ASCII_T, ASCII_I, ASCII_T, ASCII_Y, '\0' }; -static const char KW_FIXED[] = { - ASCII_F, ASCII_I, ASCII_X, ASCII_E, ASCII_D, '\0' }; -static const char KW_ID[] = { - ASCII_I, ASCII_D, '\0' }; -static const char KW_IDREF[] = { - ASCII_I, ASCII_D, ASCII_R, ASCII_E, ASCII_F, '\0' }; -static const char KW_IDREFS[] = { - ASCII_I, ASCII_D, ASCII_R, ASCII_E, ASCII_F, ASCII_S, '\0' }; -#ifdef XML_DTD -static const char KW_IGNORE[] = { - ASCII_I, ASCII_G, ASCII_N, ASCII_O, ASCII_R, ASCII_E, '\0' }; -#endif -static const char KW_IMPLIED[] = { - ASCII_I, ASCII_M, ASCII_P, ASCII_L, ASCII_I, ASCII_E, ASCII_D, '\0' }; -#ifdef XML_DTD -static const char KW_INCLUDE[] = { - ASCII_I, ASCII_N, ASCII_C, ASCII_L, ASCII_U, ASCII_D, ASCII_E, '\0' }; -#endif -static const char KW_NDATA[] = { - ASCII_N, ASCII_D, ASCII_A, ASCII_T, ASCII_A, '\0' }; -static const char KW_NMTOKEN[] = { - ASCII_N, ASCII_M, ASCII_T, ASCII_O, ASCII_K, ASCII_E, ASCII_N, '\0' }; -static const char KW_NMTOKENS[] = { - ASCII_N, ASCII_M, ASCII_T, ASCII_O, ASCII_K, ASCII_E, ASCII_N, ASCII_S, - '\0' }; -static const char KW_NOTATION[] = - { ASCII_N, ASCII_O, ASCII_T, ASCII_A, ASCII_T, ASCII_I, ASCII_O, ASCII_N, - '\0' }; -static const char KW_PCDATA[] = { - ASCII_P, ASCII_C, ASCII_D, ASCII_A, ASCII_T, ASCII_A, '\0' }; -static const char KW_PUBLIC[] = { - ASCII_P, ASCII_U, ASCII_B, ASCII_L, ASCII_I, ASCII_C, '\0' }; -static const char KW_REQUIRED[] = { - ASCII_R, ASCII_E, ASCII_Q, ASCII_U, ASCII_I, ASCII_R, ASCII_E, ASCII_D, - '\0' }; -static const char KW_SYSTEM[] = { - ASCII_S, ASCII_Y, ASCII_S, ASCII_T, ASCII_E, ASCII_M, '\0' }; - -#ifndef MIN_BYTES_PER_CHAR -#define MIN_BYTES_PER_CHAR(enc) ((enc)->minBytesPerChar) -#endif - -#ifdef XML_DTD -#define setTopLevel(state) \ - ((state)->handler = ((state)->documentEntity \ - ? internalSubset \ - : externalSubset1)) -#else /* not XML_DTD */ -#define setTopLevel(state) ((state)->handler = internalSubset) -#endif /* not XML_DTD */ - -typedef int PTRCALL PROLOG_HANDLER(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc); - -static PROLOG_HANDLER - prolog0, prolog1, prolog2, - doctype0, doctype1, doctype2, doctype3, doctype4, doctype5, - internalSubset, - entity0, entity1, entity2, entity3, entity4, entity5, entity6, - entity7, entity8, entity9, entity10, - notation0, notation1, notation2, notation3, notation4, - attlist0, attlist1, attlist2, attlist3, attlist4, attlist5, attlist6, - attlist7, attlist8, attlist9, - element0, element1, element2, element3, element4, element5, element6, - element7, -#ifdef XML_DTD - externalSubset0, externalSubset1, - condSect0, condSect1, condSect2, -#endif /* XML_DTD */ - declClose, - error; - -static int FASTCALL common(PROLOG_STATE *state, int tok); - -static int PTRCALL -prolog0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - state->handler = prolog1; - return XML_ROLE_NONE; - case XML_TOK_XML_DECL: - state->handler = prolog1; - return XML_ROLE_XML_DECL; - case XML_TOK_PI: - state->handler = prolog1; - return XML_ROLE_PI; - case XML_TOK_COMMENT: - state->handler = prolog1; - return XML_ROLE_COMMENT; - case XML_TOK_BOM: - return XML_ROLE_NONE; - case XML_TOK_DECL_OPEN: - if (!XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_DOCTYPE)) - break; - state->handler = doctype0; - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_INSTANCE_START: - state->handler = error; - return XML_ROLE_INSTANCE_START; - } - return common(state, tok); -} - -static int PTRCALL -prolog1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_PI: - return XML_ROLE_PI; - case XML_TOK_COMMENT: - return XML_ROLE_COMMENT; - case XML_TOK_BOM: - return XML_ROLE_NONE; - case XML_TOK_DECL_OPEN: - if (!XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_DOCTYPE)) - break; - state->handler = doctype0; - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_INSTANCE_START: - state->handler = error; - return XML_ROLE_INSTANCE_START; - } - return common(state, tok); -} - -static int PTRCALL -prolog2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_PI: - return XML_ROLE_PI; - case XML_TOK_COMMENT: - return XML_ROLE_COMMENT; - case XML_TOK_INSTANCE_START: - state->handler = error; - return XML_ROLE_INSTANCE_START; - } - return common(state, tok); -} - -static int PTRCALL -doctype0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = doctype1; - return XML_ROLE_DOCTYPE_NAME; - } - return common(state, tok); -} - -static int PTRCALL -doctype1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_OPEN_BRACKET: - state->handler = internalSubset; - return XML_ROLE_DOCTYPE_INTERNAL_SUBSET; - case XML_TOK_DECL_CLOSE: - state->handler = prolog2; - return XML_ROLE_DOCTYPE_CLOSE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_SYSTEM)) { - state->handler = doctype3; - return XML_ROLE_DOCTYPE_NONE; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_PUBLIC)) { - state->handler = doctype2; - return XML_ROLE_DOCTYPE_NONE; - } - break; - } - return common(state, tok); -} - -static int PTRCALL -doctype2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_LITERAL: - state->handler = doctype3; - return XML_ROLE_DOCTYPE_PUBLIC_ID; - } - return common(state, tok); -} - -static int PTRCALL -doctype3(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_LITERAL: - state->handler = doctype4; - return XML_ROLE_DOCTYPE_SYSTEM_ID; - } - return common(state, tok); -} - -static int PTRCALL -doctype4(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_OPEN_BRACKET: - state->handler = internalSubset; - return XML_ROLE_DOCTYPE_INTERNAL_SUBSET; - case XML_TOK_DECL_CLOSE: - state->handler = prolog2; - return XML_ROLE_DOCTYPE_CLOSE; - } - return common(state, tok); -} - -static int PTRCALL -doctype5(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_DECL_CLOSE: - state->handler = prolog2; - return XML_ROLE_DOCTYPE_CLOSE; - } - return common(state, tok); -} - -static int PTRCALL -internalSubset(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_DECL_OPEN: - if (XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_ENTITY)) { - state->handler = entity0; - return XML_ROLE_ENTITY_NONE; - } - if (XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_ATTLIST)) { - state->handler = attlist0; - return XML_ROLE_ATTLIST_NONE; - } - if (XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_ELEMENT)) { - state->handler = element0; - return XML_ROLE_ELEMENT_NONE; - } - if (XmlNameMatchesAscii(enc, - ptr + 2 * MIN_BYTES_PER_CHAR(enc), - end, - KW_NOTATION)) { - state->handler = notation0; - return XML_ROLE_NOTATION_NONE; - } - break; - case XML_TOK_PI: - return XML_ROLE_PI; - case XML_TOK_COMMENT: - return XML_ROLE_COMMENT; - case XML_TOK_PARAM_ENTITY_REF: - return XML_ROLE_PARAM_ENTITY_REF; - case XML_TOK_CLOSE_BRACKET: - state->handler = doctype5; - return XML_ROLE_DOCTYPE_NONE; - case XML_TOK_NONE: - return XML_ROLE_NONE; - } - return common(state, tok); -} - -#ifdef XML_DTD - -static int PTRCALL -externalSubset0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - state->handler = externalSubset1; - if (tok == XML_TOK_XML_DECL) - return XML_ROLE_TEXT_DECL; - return externalSubset1(state, tok, ptr, end, enc); -} - -static int PTRCALL -externalSubset1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_COND_SECT_OPEN: - state->handler = condSect0; - return XML_ROLE_NONE; - case XML_TOK_COND_SECT_CLOSE: - if (state->includeLevel == 0) - break; - state->includeLevel -= 1; - return XML_ROLE_NONE; - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_CLOSE_BRACKET: - break; - case XML_TOK_NONE: - if (state->includeLevel) - break; - return XML_ROLE_NONE; - default: - return internalSubset(state, tok, ptr, end, enc); - } - return common(state, tok); -} - -#endif /* XML_DTD */ - -static int PTRCALL -entity0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_PERCENT: - state->handler = entity1; - return XML_ROLE_ENTITY_NONE; - case XML_TOK_NAME: - state->handler = entity2; - return XML_ROLE_GENERAL_ENTITY_NAME; - } - return common(state, tok); -} - -static int PTRCALL -entity1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_NAME: - state->handler = entity7; - return XML_ROLE_PARAM_ENTITY_NAME; - } - return common(state, tok); -} - -static int PTRCALL -entity2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_SYSTEM)) { - state->handler = entity4; - return XML_ROLE_ENTITY_NONE; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_PUBLIC)) { - state->handler = entity3; - return XML_ROLE_ENTITY_NONE; - } - break; - case XML_TOK_LITERAL: - state->handler = declClose; - state->role_none = XML_ROLE_ENTITY_NONE; - return XML_ROLE_ENTITY_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -entity3(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_LITERAL: - state->handler = entity4; - return XML_ROLE_ENTITY_PUBLIC_ID; - } - return common(state, tok); -} - -static int PTRCALL -entity4(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_LITERAL: - state->handler = entity5; - return XML_ROLE_ENTITY_SYSTEM_ID; - } - return common(state, tok); -} - -static int PTRCALL -entity5(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_DECL_CLOSE: - setTopLevel(state); - return XML_ROLE_ENTITY_COMPLETE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_NDATA)) { - state->handler = entity6; - return XML_ROLE_ENTITY_NONE; - } - break; - } - return common(state, tok); -} - -static int PTRCALL -entity6(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_NAME: - state->handler = declClose; - state->role_none = XML_ROLE_ENTITY_NONE; - return XML_ROLE_ENTITY_NOTATION_NAME; - } - return common(state, tok); -} - -static int PTRCALL -entity7(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_SYSTEM)) { - state->handler = entity9; - return XML_ROLE_ENTITY_NONE; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_PUBLIC)) { - state->handler = entity8; - return XML_ROLE_ENTITY_NONE; - } - break; - case XML_TOK_LITERAL: - state->handler = declClose; - state->role_none = XML_ROLE_ENTITY_NONE; - return XML_ROLE_ENTITY_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -entity8(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_LITERAL: - state->handler = entity9; - return XML_ROLE_ENTITY_PUBLIC_ID; - } - return common(state, tok); -} - -static int PTRCALL -entity9(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_LITERAL: - state->handler = entity10; - return XML_ROLE_ENTITY_SYSTEM_ID; - } - return common(state, tok); -} - -static int PTRCALL -entity10(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ENTITY_NONE; - case XML_TOK_DECL_CLOSE: - setTopLevel(state); - return XML_ROLE_ENTITY_COMPLETE; - } - return common(state, tok); -} - -static int PTRCALL -notation0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NOTATION_NONE; - case XML_TOK_NAME: - state->handler = notation1; - return XML_ROLE_NOTATION_NAME; - } - return common(state, tok); -} - -static int PTRCALL -notation1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NOTATION_NONE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_SYSTEM)) { - state->handler = notation3; - return XML_ROLE_NOTATION_NONE; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_PUBLIC)) { - state->handler = notation2; - return XML_ROLE_NOTATION_NONE; - } - break; - } - return common(state, tok); -} - -static int PTRCALL -notation2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NOTATION_NONE; - case XML_TOK_LITERAL: - state->handler = notation4; - return XML_ROLE_NOTATION_PUBLIC_ID; - } - return common(state, tok); -} - -static int PTRCALL -notation3(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NOTATION_NONE; - case XML_TOK_LITERAL: - state->handler = declClose; - state->role_none = XML_ROLE_NOTATION_NONE; - return XML_ROLE_NOTATION_SYSTEM_ID; - } - return common(state, tok); -} - -static int PTRCALL -notation4(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NOTATION_NONE; - case XML_TOK_LITERAL: - state->handler = declClose; - state->role_none = XML_ROLE_NOTATION_NONE; - return XML_ROLE_NOTATION_SYSTEM_ID; - case XML_TOK_DECL_CLOSE: - setTopLevel(state); - return XML_ROLE_NOTATION_NO_SYSTEM_ID; - } - return common(state, tok); -} - -static int PTRCALL -attlist0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = attlist1; - return XML_ROLE_ATTLIST_ELEMENT_NAME; - } - return common(state, tok); -} - -static int PTRCALL -attlist1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_DECL_CLOSE: - setTopLevel(state); - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = attlist2; - return XML_ROLE_ATTRIBUTE_NAME; - } - return common(state, tok); -} - -static int PTRCALL -attlist2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_NAME: - { - static const char * const types[] = { - KW_CDATA, - KW_ID, - KW_IDREF, - KW_IDREFS, - KW_ENTITY, - KW_ENTITIES, - KW_NMTOKEN, - KW_NMTOKENS, - }; - int i; - for (i = 0; i < (int)(sizeof(types)/sizeof(types[0])); i++) - if (XmlNameMatchesAscii(enc, ptr, end, types[i])) { - state->handler = attlist8; - return XML_ROLE_ATTRIBUTE_TYPE_CDATA + i; - } - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_NOTATION)) { - state->handler = attlist5; - return XML_ROLE_ATTLIST_NONE; - } - break; - case XML_TOK_OPEN_PAREN: - state->handler = attlist3; - return XML_ROLE_ATTLIST_NONE; - } - return common(state, tok); -} - -static int PTRCALL -attlist3(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_NMTOKEN: - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = attlist4; - return XML_ROLE_ATTRIBUTE_ENUM_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -attlist4(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_CLOSE_PAREN: - state->handler = attlist8; - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_OR: - state->handler = attlist3; - return XML_ROLE_ATTLIST_NONE; - } - return common(state, tok); -} - -static int PTRCALL -attlist5(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_OPEN_PAREN: - state->handler = attlist6; - return XML_ROLE_ATTLIST_NONE; - } - return common(state, tok); -} - -static int PTRCALL -attlist6(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_NAME: - state->handler = attlist7; - return XML_ROLE_ATTRIBUTE_NOTATION_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -attlist7(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_CLOSE_PAREN: - state->handler = attlist8; - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_OR: - state->handler = attlist6; - return XML_ROLE_ATTLIST_NONE; - } - return common(state, tok); -} - -/* default value */ -static int PTRCALL -attlist8(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_POUND_NAME: - if (XmlNameMatchesAscii(enc, - ptr + MIN_BYTES_PER_CHAR(enc), - end, - KW_IMPLIED)) { - state->handler = attlist1; - return XML_ROLE_IMPLIED_ATTRIBUTE_VALUE; - } - if (XmlNameMatchesAscii(enc, - ptr + MIN_BYTES_PER_CHAR(enc), - end, - KW_REQUIRED)) { - state->handler = attlist1; - return XML_ROLE_REQUIRED_ATTRIBUTE_VALUE; - } - if (XmlNameMatchesAscii(enc, - ptr + MIN_BYTES_PER_CHAR(enc), - end, - KW_FIXED)) { - state->handler = attlist9; - return XML_ROLE_ATTLIST_NONE; - } - break; - case XML_TOK_LITERAL: - state->handler = attlist1; - return XML_ROLE_DEFAULT_ATTRIBUTE_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -attlist9(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ATTLIST_NONE; - case XML_TOK_LITERAL: - state->handler = attlist1; - return XML_ROLE_FIXED_ATTRIBUTE_VALUE; - } - return common(state, tok); -} - -static int PTRCALL -element0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = element1; - return XML_ROLE_ELEMENT_NAME; - } - return common(state, tok); -} - -static int PTRCALL -element1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_EMPTY)) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - return XML_ROLE_CONTENT_EMPTY; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_ANY)) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - return XML_ROLE_CONTENT_ANY; - } - break; - case XML_TOK_OPEN_PAREN: - state->handler = element2; - state->level = 1; - return XML_ROLE_GROUP_OPEN; - } - return common(state, tok); -} - -static int PTRCALL -element2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_POUND_NAME: - if (XmlNameMatchesAscii(enc, - ptr + MIN_BYTES_PER_CHAR(enc), - end, - KW_PCDATA)) { - state->handler = element3; - return XML_ROLE_CONTENT_PCDATA; - } - break; - case XML_TOK_OPEN_PAREN: - state->level = 2; - state->handler = element6; - return XML_ROLE_GROUP_OPEN; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT; - case XML_TOK_NAME_QUESTION: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_OPT; - case XML_TOK_NAME_ASTERISK: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_REP; - case XML_TOK_NAME_PLUS: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_PLUS; - } - return common(state, tok); -} - -static int PTRCALL -element3(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_CLOSE_PAREN: - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - return XML_ROLE_GROUP_CLOSE; - case XML_TOK_CLOSE_PAREN_ASTERISK: - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - return XML_ROLE_GROUP_CLOSE_REP; - case XML_TOK_OR: - state->handler = element4; - return XML_ROLE_ELEMENT_NONE; - } - return common(state, tok); -} - -static int PTRCALL -element4(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = element5; - return XML_ROLE_CONTENT_ELEMENT; - } - return common(state, tok); -} - -static int PTRCALL -element5(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_CLOSE_PAREN_ASTERISK: - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - return XML_ROLE_GROUP_CLOSE_REP; - case XML_TOK_OR: - state->handler = element4; - return XML_ROLE_ELEMENT_NONE; - } - return common(state, tok); -} - -static int PTRCALL -element6(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_OPEN_PAREN: - state->level += 1; - return XML_ROLE_GROUP_OPEN; - case XML_TOK_NAME: - case XML_TOK_PREFIXED_NAME: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT; - case XML_TOK_NAME_QUESTION: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_OPT; - case XML_TOK_NAME_ASTERISK: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_REP; - case XML_TOK_NAME_PLUS: - state->handler = element7; - return XML_ROLE_CONTENT_ELEMENT_PLUS; - } - return common(state, tok); -} - -static int PTRCALL -element7(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_ELEMENT_NONE; - case XML_TOK_CLOSE_PAREN: - state->level -= 1; - if (state->level == 0) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - } - return XML_ROLE_GROUP_CLOSE; - case XML_TOK_CLOSE_PAREN_ASTERISK: - state->level -= 1; - if (state->level == 0) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - } - return XML_ROLE_GROUP_CLOSE_REP; - case XML_TOK_CLOSE_PAREN_QUESTION: - state->level -= 1; - if (state->level == 0) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - } - return XML_ROLE_GROUP_CLOSE_OPT; - case XML_TOK_CLOSE_PAREN_PLUS: - state->level -= 1; - if (state->level == 0) { - state->handler = declClose; - state->role_none = XML_ROLE_ELEMENT_NONE; - } - return XML_ROLE_GROUP_CLOSE_PLUS; - case XML_TOK_COMMA: - state->handler = element6; - return XML_ROLE_GROUP_SEQUENCE; - case XML_TOK_OR: - state->handler = element6; - return XML_ROLE_GROUP_CHOICE; - } - return common(state, tok); -} - -#ifdef XML_DTD - -static int PTRCALL -condSect0(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_NAME: - if (XmlNameMatchesAscii(enc, ptr, end, KW_INCLUDE)) { - state->handler = condSect1; - return XML_ROLE_NONE; - } - if (XmlNameMatchesAscii(enc, ptr, end, KW_IGNORE)) { - state->handler = condSect2; - return XML_ROLE_NONE; - } - break; - } - return common(state, tok); -} - -static int PTRCALL -condSect1(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_OPEN_BRACKET: - state->handler = externalSubset1; - state->includeLevel += 1; - return XML_ROLE_NONE; - } - return common(state, tok); -} - -static int PTRCALL -condSect2(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return XML_ROLE_NONE; - case XML_TOK_OPEN_BRACKET: - state->handler = externalSubset1; - return XML_ROLE_IGNORE_SECT; - } - return common(state, tok); -} - -#endif /* XML_DTD */ - -static int PTRCALL -declClose(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - switch (tok) { - case XML_TOK_PROLOG_S: - return state->role_none; - case XML_TOK_DECL_CLOSE: - setTopLevel(state); - return state->role_none; - } - return common(state, tok); -} - -static int PTRCALL -error(PROLOG_STATE *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc) -{ - return XML_ROLE_NONE; -} - -static int FASTCALL -common(PROLOG_STATE *state, int tok) -{ -#ifdef XML_DTD - if (!state->documentEntity && tok == XML_TOK_PARAM_ENTITY_REF) - return XML_ROLE_INNER_PARAM_ENTITY_REF; -#endif - state->handler = error; - return XML_ROLE_ERROR; -} - -void -XmlPrologStateInit(PROLOG_STATE *state) -{ - state->handler = prolog0; -#ifdef XML_DTD - state->documentEntity = 1; - state->includeLevel = 0; - state->inEntityValue = 0; -#endif /* XML_DTD */ -} - -#ifdef XML_DTD - -void -XmlPrologStateInitExternalEntity(PROLOG_STATE *state) -{ - state->handler = externalSubset0; - state->documentEntity = 0; - state->includeLevel = 0; -} - -#endif /* XML_DTD */ diff --git a/lib-src/expat/lib/xmlrole.h b/lib-src/expat/lib/xmlrole.h deleted file mode 100644 index 4dd9f06f9..000000000 --- a/lib-src/expat/lib/xmlrole.h +++ /dev/null @@ -1,114 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#ifndef XmlRole_INCLUDED -#define XmlRole_INCLUDED 1 - -#ifdef __VMS -/* 0 1 2 3 0 1 2 3 - 1234567890123456789012345678901 1234567890123456789012345678901 */ -#define XmlPrologStateInitExternalEntity XmlPrologStateInitExternalEnt -#endif - -#include "xmltok.h" - -#ifdef __cplusplus -extern "C" { -#endif - -enum { - XML_ROLE_ERROR = -1, - XML_ROLE_NONE = 0, - XML_ROLE_XML_DECL, - XML_ROLE_INSTANCE_START, - XML_ROLE_DOCTYPE_NONE, - XML_ROLE_DOCTYPE_NAME, - XML_ROLE_DOCTYPE_SYSTEM_ID, - XML_ROLE_DOCTYPE_PUBLIC_ID, - XML_ROLE_DOCTYPE_INTERNAL_SUBSET, - XML_ROLE_DOCTYPE_CLOSE, - XML_ROLE_GENERAL_ENTITY_NAME, - XML_ROLE_PARAM_ENTITY_NAME, - XML_ROLE_ENTITY_NONE, - XML_ROLE_ENTITY_VALUE, - XML_ROLE_ENTITY_SYSTEM_ID, - XML_ROLE_ENTITY_PUBLIC_ID, - XML_ROLE_ENTITY_COMPLETE, - XML_ROLE_ENTITY_NOTATION_NAME, - XML_ROLE_NOTATION_NONE, - XML_ROLE_NOTATION_NAME, - XML_ROLE_NOTATION_SYSTEM_ID, - XML_ROLE_NOTATION_NO_SYSTEM_ID, - XML_ROLE_NOTATION_PUBLIC_ID, - XML_ROLE_ATTRIBUTE_NAME, - XML_ROLE_ATTRIBUTE_TYPE_CDATA, - XML_ROLE_ATTRIBUTE_TYPE_ID, - XML_ROLE_ATTRIBUTE_TYPE_IDREF, - XML_ROLE_ATTRIBUTE_TYPE_IDREFS, - XML_ROLE_ATTRIBUTE_TYPE_ENTITY, - XML_ROLE_ATTRIBUTE_TYPE_ENTITIES, - XML_ROLE_ATTRIBUTE_TYPE_NMTOKEN, - XML_ROLE_ATTRIBUTE_TYPE_NMTOKENS, - XML_ROLE_ATTRIBUTE_ENUM_VALUE, - XML_ROLE_ATTRIBUTE_NOTATION_VALUE, - XML_ROLE_ATTLIST_NONE, - XML_ROLE_ATTLIST_ELEMENT_NAME, - XML_ROLE_IMPLIED_ATTRIBUTE_VALUE, - XML_ROLE_REQUIRED_ATTRIBUTE_VALUE, - XML_ROLE_DEFAULT_ATTRIBUTE_VALUE, - XML_ROLE_FIXED_ATTRIBUTE_VALUE, - XML_ROLE_ELEMENT_NONE, - XML_ROLE_ELEMENT_NAME, - XML_ROLE_CONTENT_ANY, - XML_ROLE_CONTENT_EMPTY, - XML_ROLE_CONTENT_PCDATA, - XML_ROLE_GROUP_OPEN, - XML_ROLE_GROUP_CLOSE, - XML_ROLE_GROUP_CLOSE_REP, - XML_ROLE_GROUP_CLOSE_OPT, - XML_ROLE_GROUP_CLOSE_PLUS, - XML_ROLE_GROUP_CHOICE, - XML_ROLE_GROUP_SEQUENCE, - XML_ROLE_CONTENT_ELEMENT, - XML_ROLE_CONTENT_ELEMENT_REP, - XML_ROLE_CONTENT_ELEMENT_OPT, - XML_ROLE_CONTENT_ELEMENT_PLUS, - XML_ROLE_PI, - XML_ROLE_COMMENT, -#ifdef XML_DTD - XML_ROLE_TEXT_DECL, - XML_ROLE_IGNORE_SECT, - XML_ROLE_INNER_PARAM_ENTITY_REF, -#endif /* XML_DTD */ - XML_ROLE_PARAM_ENTITY_REF -}; - -typedef struct prolog_state { - int (PTRCALL *handler) (struct prolog_state *state, - int tok, - const char *ptr, - const char *end, - const ENCODING *enc); - unsigned level; - int role_none; -#ifdef XML_DTD - unsigned includeLevel; - int documentEntity; - int inEntityValue; -#endif /* XML_DTD */ -} PROLOG_STATE; - -void XmlPrologStateInit(PROLOG_STATE *); -#ifdef XML_DTD -void XmlPrologStateInitExternalEntity(PROLOG_STATE *); -#endif /* XML_DTD */ - -#define XmlTokenRole(state, tok, ptr, end, enc) \ - (((state)->handler)(state, tok, ptr, end, enc)) - -#ifdef __cplusplus -} -#endif - -#endif /* not XmlRole_INCLUDED */ diff --git a/lib-src/expat/lib/xmltok.c b/lib-src/expat/lib/xmltok.c deleted file mode 100644 index bf09dfc72..000000000 --- a/lib-src/expat/lib/xmltok.c +++ /dev/null @@ -1,1651 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include - -#ifdef COMPILED_FROM_DSP -#include "winconfig.h" -#elif defined(MACOS_CLASSIC) -#include "macconfig.h" -#elif defined(__amigaos__) -#include "amigaconfig.h" -#elif defined(__WATCOMC__) -#include "watcomconfig.h" -#else -#ifdef HAVE_EXPAT_CONFIG_H -#include -#endif -#endif /* ndef COMPILED_FROM_DSP */ - -#include "expat_external.h" -#include "internal.h" -#include "xmltok.h" -#include "nametab.h" - -#ifdef XML_DTD -#define IGNORE_SECTION_TOK_VTABLE , PREFIX(ignoreSectionTok) -#else -#define IGNORE_SECTION_TOK_VTABLE /* as nothing */ -#endif - -#define VTABLE1 \ - { PREFIX(prologTok), PREFIX(contentTok), \ - PREFIX(cdataSectionTok) IGNORE_SECTION_TOK_VTABLE }, \ - { PREFIX(attributeValueTok), PREFIX(entityValueTok) }, \ - PREFIX(sameName), \ - PREFIX(nameMatchesAscii), \ - PREFIX(nameLength), \ - PREFIX(skipS), \ - PREFIX(getAtts), \ - PREFIX(charRefNumber), \ - PREFIX(predefinedEntityName), \ - PREFIX(updatePosition), \ - PREFIX(isPublicId) - -#define VTABLE VTABLE1, PREFIX(toUtf8), PREFIX(toUtf16) - -#define UCS2_GET_NAMING(pages, hi, lo) \ - (namingBitmap[(pages[hi] << 3) + ((lo) >> 5)] & (1 << ((lo) & 0x1F))) - -/* A 2 byte UTF-8 representation splits the characters 11 bits between - the bottom 5 and 6 bits of the bytes. We need 8 bits to index into - pages, 3 bits to add to that index and 5 bits to generate the mask. -*/ -#define UTF8_GET_NAMING2(pages, byte) \ - (namingBitmap[((pages)[(((byte)[0]) >> 2) & 7] << 3) \ - + ((((byte)[0]) & 3) << 1) \ - + ((((byte)[1]) >> 5) & 1)] \ - & (1 << (((byte)[1]) & 0x1F))) - -/* A 3 byte UTF-8 representation splits the characters 16 bits between - the bottom 4, 6 and 6 bits of the bytes. We need 8 bits to index - into pages, 3 bits to add to that index and 5 bits to generate the - mask. -*/ -#define UTF8_GET_NAMING3(pages, byte) \ - (namingBitmap[((pages)[((((byte)[0]) & 0xF) << 4) \ - + ((((byte)[1]) >> 2) & 0xF)] \ - << 3) \ - + ((((byte)[1]) & 3) << 1) \ - + ((((byte)[2]) >> 5) & 1)] \ - & (1 << (((byte)[2]) & 0x1F))) - -#define UTF8_GET_NAMING(pages, p, n) \ - ((n) == 2 \ - ? UTF8_GET_NAMING2(pages, (const unsigned char *)(p)) \ - : ((n) == 3 \ - ? UTF8_GET_NAMING3(pages, (const unsigned char *)(p)) \ - : 0)) - -/* Detection of invalid UTF-8 sequences is based on Table 3.1B - of Unicode 3.2: http://www.unicode.org/unicode/reports/tr28/ - with the additional restriction of not allowing the Unicode - code points 0xFFFF and 0xFFFE (sequences EF,BF,BF and EF,BF,BE). - Implementation details: - (A & 0x80) == 0 means A < 0x80 - and - (A & 0xC0) == 0xC0 means A > 0xBF -*/ - -#define UTF8_INVALID2(p) \ - ((*p) < 0xC2 || ((p)[1] & 0x80) == 0 || ((p)[1] & 0xC0) == 0xC0) - -#define UTF8_INVALID3(p) \ - (((p)[2] & 0x80) == 0 \ - || \ - ((*p) == 0xEF && (p)[1] == 0xBF \ - ? \ - (p)[2] > 0xBD \ - : \ - ((p)[2] & 0xC0) == 0xC0) \ - || \ - ((*p) == 0xE0 \ - ? \ - (p)[1] < 0xA0 || ((p)[1] & 0xC0) == 0xC0 \ - : \ - ((p)[1] & 0x80) == 0 \ - || \ - ((*p) == 0xED ? (p)[1] > 0x9F : ((p)[1] & 0xC0) == 0xC0))) - -#define UTF8_INVALID4(p) \ - (((p)[3] & 0x80) == 0 || ((p)[3] & 0xC0) == 0xC0 \ - || \ - ((p)[2] & 0x80) == 0 || ((p)[2] & 0xC0) == 0xC0 \ - || \ - ((*p) == 0xF0 \ - ? \ - (p)[1] < 0x90 || ((p)[1] & 0xC0) == 0xC0 \ - : \ - ((p)[1] & 0x80) == 0 \ - || \ - ((*p) == 0xF4 ? (p)[1] > 0x8F : ((p)[1] & 0xC0) == 0xC0))) - -static int PTRFASTCALL -isNever(const ENCODING *enc, const char *p) -{ - return 0; -} - -static int PTRFASTCALL -utf8_isName2(const ENCODING *enc, const char *p) -{ - return UTF8_GET_NAMING2(namePages, (const unsigned char *)p); -} - -static int PTRFASTCALL -utf8_isName3(const ENCODING *enc, const char *p) -{ - return UTF8_GET_NAMING3(namePages, (const unsigned char *)p); -} - -#define utf8_isName4 isNever - -static int PTRFASTCALL -utf8_isNmstrt2(const ENCODING *enc, const char *p) -{ - return UTF8_GET_NAMING2(nmstrtPages, (const unsigned char *)p); -} - -static int PTRFASTCALL -utf8_isNmstrt3(const ENCODING *enc, const char *p) -{ - return UTF8_GET_NAMING3(nmstrtPages, (const unsigned char *)p); -} - -#define utf8_isNmstrt4 isNever - -static int PTRFASTCALL -utf8_isInvalid2(const ENCODING *enc, const char *p) -{ - return UTF8_INVALID2((const unsigned char *)p); -} - -static int PTRFASTCALL -utf8_isInvalid3(const ENCODING *enc, const char *p) -{ - return UTF8_INVALID3((const unsigned char *)p); -} - -static int PTRFASTCALL -utf8_isInvalid4(const ENCODING *enc, const char *p) -{ - return UTF8_INVALID4((const unsigned char *)p); -} - -struct normal_encoding { - ENCODING enc; - unsigned char type[256]; -#ifdef XML_MIN_SIZE - int (PTRFASTCALL *byteType)(const ENCODING *, const char *); - int (PTRFASTCALL *isNameMin)(const ENCODING *, const char *); - int (PTRFASTCALL *isNmstrtMin)(const ENCODING *, const char *); - int (PTRFASTCALL *byteToAscii)(const ENCODING *, const char *); - int (PTRCALL *charMatches)(const ENCODING *, const char *, int); -#endif /* XML_MIN_SIZE */ - int (PTRFASTCALL *isName2)(const ENCODING *, const char *); - int (PTRFASTCALL *isName3)(const ENCODING *, const char *); - int (PTRFASTCALL *isName4)(const ENCODING *, const char *); - int (PTRFASTCALL *isNmstrt2)(const ENCODING *, const char *); - int (PTRFASTCALL *isNmstrt3)(const ENCODING *, const char *); - int (PTRFASTCALL *isNmstrt4)(const ENCODING *, const char *); - int (PTRFASTCALL *isInvalid2)(const ENCODING *, const char *); - int (PTRFASTCALL *isInvalid3)(const ENCODING *, const char *); - int (PTRFASTCALL *isInvalid4)(const ENCODING *, const char *); -}; - -#define AS_NORMAL_ENCODING(enc) ((const struct normal_encoding *) (enc)) - -#ifdef XML_MIN_SIZE - -#define STANDARD_VTABLE(E) \ - E ## byteType, \ - E ## isNameMin, \ - E ## isNmstrtMin, \ - E ## byteToAscii, \ - E ## charMatches, - -#else - -#define STANDARD_VTABLE(E) /* as nothing */ - -#endif - -#define NORMAL_VTABLE(E) \ - E ## isName2, \ - E ## isName3, \ - E ## isName4, \ - E ## isNmstrt2, \ - E ## isNmstrt3, \ - E ## isNmstrt4, \ - E ## isInvalid2, \ - E ## isInvalid3, \ - E ## isInvalid4 - -static int FASTCALL checkCharRefNumber(int); - -#include "xmltok_impl.h" -#include "ascii.h" - -#ifdef XML_MIN_SIZE -#define sb_isNameMin isNever -#define sb_isNmstrtMin isNever -#endif - -#ifdef XML_MIN_SIZE -#define MINBPC(enc) ((enc)->minBytesPerChar) -#else -/* minimum bytes per character */ -#define MINBPC(enc) 1 -#endif - -#define SB_BYTE_TYPE(enc, p) \ - (((struct normal_encoding *)(enc))->type[(unsigned char)*(p)]) - -#ifdef XML_MIN_SIZE -static int PTRFASTCALL -sb_byteType(const ENCODING *enc, const char *p) -{ - return SB_BYTE_TYPE(enc, p); -} -#define BYTE_TYPE(enc, p) \ - (AS_NORMAL_ENCODING(enc)->byteType(enc, p)) -#else -#define BYTE_TYPE(enc, p) SB_BYTE_TYPE(enc, p) -#endif - -#ifdef XML_MIN_SIZE -#define BYTE_TO_ASCII(enc, p) \ - (AS_NORMAL_ENCODING(enc)->byteToAscii(enc, p)) -static int PTRFASTCALL -sb_byteToAscii(const ENCODING *enc, const char *p) -{ - return *p; -} -#else -#define BYTE_TO_ASCII(enc, p) (*(p)) -#endif - -#define IS_NAME_CHAR(enc, p, n) \ - (AS_NORMAL_ENCODING(enc)->isName ## n(enc, p)) -#define IS_NMSTRT_CHAR(enc, p, n) \ - (AS_NORMAL_ENCODING(enc)->isNmstrt ## n(enc, p)) -#define IS_INVALID_CHAR(enc, p, n) \ - (AS_NORMAL_ENCODING(enc)->isInvalid ## n(enc, p)) - -#ifdef XML_MIN_SIZE -#define IS_NAME_CHAR_MINBPC(enc, p) \ - (AS_NORMAL_ENCODING(enc)->isNameMin(enc, p)) -#define IS_NMSTRT_CHAR_MINBPC(enc, p) \ - (AS_NORMAL_ENCODING(enc)->isNmstrtMin(enc, p)) -#else -#define IS_NAME_CHAR_MINBPC(enc, p) (0) -#define IS_NMSTRT_CHAR_MINBPC(enc, p) (0) -#endif - -#ifdef XML_MIN_SIZE -#define CHAR_MATCHES(enc, p, c) \ - (AS_NORMAL_ENCODING(enc)->charMatches(enc, p, c)) -static int PTRCALL -sb_charMatches(const ENCODING *enc, const char *p, int c) -{ - return *p == c; -} -#else -/* c is an ASCII character */ -#define CHAR_MATCHES(enc, p, c) (*(p) == c) -#endif - -#define PREFIX(ident) normal_ ## ident -#define XML_TOK_IMPL_C -#include "xmltok_impl.c" -#undef XML_TOK_IMPL_C - -#undef MINBPC -#undef BYTE_TYPE -#undef BYTE_TO_ASCII -#undef CHAR_MATCHES -#undef IS_NAME_CHAR -#undef IS_NAME_CHAR_MINBPC -#undef IS_NMSTRT_CHAR -#undef IS_NMSTRT_CHAR_MINBPC -#undef IS_INVALID_CHAR - -enum { /* UTF8_cvalN is value of masked first byte of N byte sequence */ - UTF8_cval1 = 0x00, - UTF8_cval2 = 0xc0, - UTF8_cval3 = 0xe0, - UTF8_cval4 = 0xf0 -}; - -static void PTRCALL -utf8_toUtf8(const ENCODING *enc, - const char **fromP, const char *fromLim, - char **toP, const char *toLim) -{ - char *to; - const char *from; - if (fromLim - *fromP > toLim - *toP) { - /* Avoid copying partial characters. */ - for (fromLim = *fromP + (toLim - *toP); fromLim > *fromP; fromLim--) - if (((unsigned char)fromLim[-1] & 0xc0) != 0x80) - break; - } - for (to = *toP, from = *fromP; from != fromLim; from++, to++) - *to = *from; - *fromP = from; - *toP = to; -} - -static void PTRCALL -utf8_toUtf16(const ENCODING *enc, - const char **fromP, const char *fromLim, - unsigned short **toP, const unsigned short *toLim) -{ - unsigned short *to = *toP; - const char *from = *fromP; - while (from != fromLim && to != toLim) { - switch (((struct normal_encoding *)enc)->type[(unsigned char)*from]) { - case BT_LEAD2: - *to++ = (unsigned short)(((from[0] & 0x1f) << 6) | (from[1] & 0x3f)); - from += 2; - break; - case BT_LEAD3: - *to++ = (unsigned short)(((from[0] & 0xf) << 12) - | ((from[1] & 0x3f) << 6) | (from[2] & 0x3f)); - from += 3; - break; - case BT_LEAD4: - { - unsigned long n; - if (to + 1 == toLim) - goto after; - n = ((from[0] & 0x7) << 18) | ((from[1] & 0x3f) << 12) - | ((from[2] & 0x3f) << 6) | (from[3] & 0x3f); - n -= 0x10000; - to[0] = (unsigned short)((n >> 10) | 0xD800); - to[1] = (unsigned short)((n & 0x3FF) | 0xDC00); - to += 2; - from += 4; - } - break; - default: - *to++ = *from++; - break; - } - } -after: - *fromP = from; - *toP = to; -} - -#ifdef XML_NS -static const struct normal_encoding utf8_encoding_ns = { - { VTABLE1, utf8_toUtf8, utf8_toUtf16, 1, 1, 0 }, - { -#include "asciitab.h" -#include "utf8tab.h" - }, - STANDARD_VTABLE(sb_) NORMAL_VTABLE(utf8_) -}; -#endif - -static const struct normal_encoding utf8_encoding = { - { VTABLE1, utf8_toUtf8, utf8_toUtf16, 1, 1, 0 }, - { -#define BT_COLON BT_NMSTRT -#include "asciitab.h" -#undef BT_COLON -#include "utf8tab.h" - }, - STANDARD_VTABLE(sb_) NORMAL_VTABLE(utf8_) -}; - -#ifdef XML_NS - -static const struct normal_encoding internal_utf8_encoding_ns = { - { VTABLE1, utf8_toUtf8, utf8_toUtf16, 1, 1, 0 }, - { -#include "iasciitab.h" -#include "utf8tab.h" - }, - STANDARD_VTABLE(sb_) NORMAL_VTABLE(utf8_) -}; - -#endif - -static const struct normal_encoding internal_utf8_encoding = { - { VTABLE1, utf8_toUtf8, utf8_toUtf16, 1, 1, 0 }, - { -#define BT_COLON BT_NMSTRT -#include "iasciitab.h" -#undef BT_COLON -#include "utf8tab.h" - }, - STANDARD_VTABLE(sb_) NORMAL_VTABLE(utf8_) -}; - -static void PTRCALL -latin1_toUtf8(const ENCODING *enc, - const char **fromP, const char *fromLim, - char **toP, const char *toLim) -{ - for (;;) { - unsigned char c; - if (*fromP == fromLim) - break; - c = (unsigned char)**fromP; - if (c & 0x80) { - if (toLim - *toP < 2) - break; - *(*toP)++ = (char)((c >> 6) | UTF8_cval2); - *(*toP)++ = (char)((c & 0x3f) | 0x80); - (*fromP)++; - } - else { - if (*toP == toLim) - break; - *(*toP)++ = *(*fromP)++; - } - } -} - -static void PTRCALL -latin1_toUtf16(const ENCODING *enc, - const char **fromP, const char *fromLim, - unsigned short **toP, const unsigned short *toLim) -{ - while (*fromP != fromLim && *toP != toLim) - *(*toP)++ = (unsigned char)*(*fromP)++; -} - -#ifdef XML_NS - -static const struct normal_encoding latin1_encoding_ns = { - { VTABLE1, latin1_toUtf8, latin1_toUtf16, 1, 0, 0 }, - { -#include "asciitab.h" -#include "latin1tab.h" - }, - STANDARD_VTABLE(sb_) -}; - -#endif - -static const struct normal_encoding latin1_encoding = { - { VTABLE1, latin1_toUtf8, latin1_toUtf16, 1, 0, 0 }, - { -#define BT_COLON BT_NMSTRT -#include "asciitab.h" -#undef BT_COLON -#include "latin1tab.h" - }, - STANDARD_VTABLE(sb_) -}; - -static void PTRCALL -ascii_toUtf8(const ENCODING *enc, - const char **fromP, const char *fromLim, - char **toP, const char *toLim) -{ - while (*fromP != fromLim && *toP != toLim) - *(*toP)++ = *(*fromP)++; -} - -#ifdef XML_NS - -static const struct normal_encoding ascii_encoding_ns = { - { VTABLE1, ascii_toUtf8, latin1_toUtf16, 1, 1, 0 }, - { -#include "asciitab.h" -/* BT_NONXML == 0 */ - }, - STANDARD_VTABLE(sb_) -}; - -#endif - -static const struct normal_encoding ascii_encoding = { - { VTABLE1, ascii_toUtf8, latin1_toUtf16, 1, 1, 0 }, - { -#define BT_COLON BT_NMSTRT -#include "asciitab.h" -#undef BT_COLON -/* BT_NONXML == 0 */ - }, - STANDARD_VTABLE(sb_) -}; - -static int PTRFASTCALL -unicode_byte_type(char hi, char lo) -{ - switch ((unsigned char)hi) { - case 0xD8: case 0xD9: case 0xDA: case 0xDB: - return BT_LEAD4; - case 0xDC: case 0xDD: case 0xDE: case 0xDF: - return BT_TRAIL; - case 0xFF: - switch ((unsigned char)lo) { - case 0xFF: - case 0xFE: - return BT_NONXML; - } - break; - } - return BT_NONASCII; -} - -#define DEFINE_UTF16_TO_UTF8(E) \ -static void PTRCALL \ -E ## toUtf8(const ENCODING *enc, \ - const char **fromP, const char *fromLim, \ - char **toP, const char *toLim) \ -{ \ - const char *from; \ - for (from = *fromP; from != fromLim; from += 2) { \ - int plane; \ - unsigned char lo2; \ - unsigned char lo = GET_LO(from); \ - unsigned char hi = GET_HI(from); \ - switch (hi) { \ - case 0: \ - if (lo < 0x80) { \ - if (*toP == toLim) { \ - *fromP = from; \ - return; \ - } \ - *(*toP)++ = lo; \ - break; \ - } \ - /* fall through */ \ - case 0x1: case 0x2: case 0x3: \ - case 0x4: case 0x5: case 0x6: case 0x7: \ - if (toLim - *toP < 2) { \ - *fromP = from; \ - return; \ - } \ - *(*toP)++ = ((lo >> 6) | (hi << 2) | UTF8_cval2); \ - *(*toP)++ = ((lo & 0x3f) | 0x80); \ - break; \ - default: \ - if (toLim - *toP < 3) { \ - *fromP = from; \ - return; \ - } \ - /* 16 bits divided 4, 6, 6 amongst 3 bytes */ \ - *(*toP)++ = ((hi >> 4) | UTF8_cval3); \ - *(*toP)++ = (((hi & 0xf) << 2) | (lo >> 6) | 0x80); \ - *(*toP)++ = ((lo & 0x3f) | 0x80); \ - break; \ - case 0xD8: case 0xD9: case 0xDA: case 0xDB: \ - if (toLim - *toP < 4) { \ - *fromP = from; \ - return; \ - } \ - plane = (((hi & 0x3) << 2) | ((lo >> 6) & 0x3)) + 1; \ - *(*toP)++ = ((plane >> 2) | UTF8_cval4); \ - *(*toP)++ = (((lo >> 2) & 0xF) | ((plane & 0x3) << 4) | 0x80); \ - from += 2; \ - lo2 = GET_LO(from); \ - *(*toP)++ = (((lo & 0x3) << 4) \ - | ((GET_HI(from) & 0x3) << 2) \ - | (lo2 >> 6) \ - | 0x80); \ - *(*toP)++ = ((lo2 & 0x3f) | 0x80); \ - break; \ - } \ - } \ - *fromP = from; \ -} - -#define DEFINE_UTF16_TO_UTF16(E) \ -static void PTRCALL \ -E ## toUtf16(const ENCODING *enc, \ - const char **fromP, const char *fromLim, \ - unsigned short **toP, const unsigned short *toLim) \ -{ \ - /* Avoid copying first half only of surrogate */ \ - if (fromLim - *fromP > ((toLim - *toP) << 1) \ - && (GET_HI(fromLim - 2) & 0xF8) == 0xD8) \ - fromLim -= 2; \ - for (; *fromP != fromLim && *toP != toLim; *fromP += 2) \ - *(*toP)++ = (GET_HI(*fromP) << 8) | GET_LO(*fromP); \ -} - -#define SET2(ptr, ch) \ - (((ptr)[0] = ((ch) & 0xff)), ((ptr)[1] = ((ch) >> 8))) -#define GET_LO(ptr) ((unsigned char)(ptr)[0]) -#define GET_HI(ptr) ((unsigned char)(ptr)[1]) - -DEFINE_UTF16_TO_UTF8(little2_) -DEFINE_UTF16_TO_UTF16(little2_) - -#undef SET2 -#undef GET_LO -#undef GET_HI - -#define SET2(ptr, ch) \ - (((ptr)[0] = ((ch) >> 8)), ((ptr)[1] = ((ch) & 0xFF))) -#define GET_LO(ptr) ((unsigned char)(ptr)[1]) -#define GET_HI(ptr) ((unsigned char)(ptr)[0]) - -DEFINE_UTF16_TO_UTF8(big2_) -DEFINE_UTF16_TO_UTF16(big2_) - -#undef SET2 -#undef GET_LO -#undef GET_HI - -#define LITTLE2_BYTE_TYPE(enc, p) \ - ((p)[1] == 0 \ - ? ((struct normal_encoding *)(enc))->type[(unsigned char)*(p)] \ - : unicode_byte_type((p)[1], (p)[0])) -#define LITTLE2_BYTE_TO_ASCII(enc, p) ((p)[1] == 0 ? (p)[0] : -1) -#define LITTLE2_CHAR_MATCHES(enc, p, c) ((p)[1] == 0 && (p)[0] == c) -#define LITTLE2_IS_NAME_CHAR_MINBPC(enc, p) \ - UCS2_GET_NAMING(namePages, (unsigned char)p[1], (unsigned char)p[0]) -#define LITTLE2_IS_NMSTRT_CHAR_MINBPC(enc, p) \ - UCS2_GET_NAMING(nmstrtPages, (unsigned char)p[1], (unsigned char)p[0]) - -#ifdef XML_MIN_SIZE - -static int PTRFASTCALL -little2_byteType(const ENCODING *enc, const char *p) -{ - return LITTLE2_BYTE_TYPE(enc, p); -} - -static int PTRFASTCALL -little2_byteToAscii(const ENCODING *enc, const char *p) -{ - return LITTLE2_BYTE_TO_ASCII(enc, p); -} - -static int PTRCALL -little2_charMatches(const ENCODING *enc, const char *p, int c) -{ - return LITTLE2_CHAR_MATCHES(enc, p, c); -} - -static int PTRFASTCALL -little2_isNameMin(const ENCODING *enc, const char *p) -{ - return LITTLE2_IS_NAME_CHAR_MINBPC(enc, p); -} - -static int PTRFASTCALL -little2_isNmstrtMin(const ENCODING *enc, const char *p) -{ - return LITTLE2_IS_NMSTRT_CHAR_MINBPC(enc, p); -} - -#undef VTABLE -#define VTABLE VTABLE1, little2_toUtf8, little2_toUtf16 - -#else /* not XML_MIN_SIZE */ - -#undef PREFIX -#define PREFIX(ident) little2_ ## ident -#define MINBPC(enc) 2 -/* CHAR_MATCHES is guaranteed to have MINBPC bytes available. */ -#define BYTE_TYPE(enc, p) LITTLE2_BYTE_TYPE(enc, p) -#define BYTE_TO_ASCII(enc, p) LITTLE2_BYTE_TO_ASCII(enc, p) -#define CHAR_MATCHES(enc, p, c) LITTLE2_CHAR_MATCHES(enc, p, c) -#define IS_NAME_CHAR(enc, p, n) 0 -#define IS_NAME_CHAR_MINBPC(enc, p) LITTLE2_IS_NAME_CHAR_MINBPC(enc, p) -#define IS_NMSTRT_CHAR(enc, p, n) (0) -#define IS_NMSTRT_CHAR_MINBPC(enc, p) LITTLE2_IS_NMSTRT_CHAR_MINBPC(enc, p) - -#define XML_TOK_IMPL_C -#include "xmltok_impl.c" -#undef XML_TOK_IMPL_C - -#undef MINBPC -#undef BYTE_TYPE -#undef BYTE_TO_ASCII -#undef CHAR_MATCHES -#undef IS_NAME_CHAR -#undef IS_NAME_CHAR_MINBPC -#undef IS_NMSTRT_CHAR -#undef IS_NMSTRT_CHAR_MINBPC -#undef IS_INVALID_CHAR - -#endif /* not XML_MIN_SIZE */ - -#ifdef XML_NS - -static const struct normal_encoding little2_encoding_ns = { - { VTABLE, 2, 0, -#if BYTEORDER == 1234 - 1 -#else - 0 -#endif - }, - { -#include "asciitab.h" -#include "latin1tab.h" - }, - STANDARD_VTABLE(little2_) -}; - -#endif - -static const struct normal_encoding little2_encoding = { - { VTABLE, 2, 0, -#if BYTEORDER == 1234 - 1 -#else - 0 -#endif - }, - { -#define BT_COLON BT_NMSTRT -#include "asciitab.h" -#undef BT_COLON -#include "latin1tab.h" - }, - STANDARD_VTABLE(little2_) -}; - -#if BYTEORDER != 4321 - -#ifdef XML_NS - -static const struct normal_encoding internal_little2_encoding_ns = { - { VTABLE, 2, 0, 1 }, - { -#include "iasciitab.h" -#include "latin1tab.h" - }, - STANDARD_VTABLE(little2_) -}; - -#endif - -static const struct normal_encoding internal_little2_encoding = { - { VTABLE, 2, 0, 1 }, - { -#define BT_COLON BT_NMSTRT -#include "iasciitab.h" -#undef BT_COLON -#include "latin1tab.h" - }, - STANDARD_VTABLE(little2_) -}; - -#endif - - -#define BIG2_BYTE_TYPE(enc, p) \ - ((p)[0] == 0 \ - ? ((struct normal_encoding *)(enc))->type[(unsigned char)(p)[1]] \ - : unicode_byte_type((p)[0], (p)[1])) -#define BIG2_BYTE_TO_ASCII(enc, p) ((p)[0] == 0 ? (p)[1] : -1) -#define BIG2_CHAR_MATCHES(enc, p, c) ((p)[0] == 0 && (p)[1] == c) -#define BIG2_IS_NAME_CHAR_MINBPC(enc, p) \ - UCS2_GET_NAMING(namePages, (unsigned char)p[0], (unsigned char)p[1]) -#define BIG2_IS_NMSTRT_CHAR_MINBPC(enc, p) \ - UCS2_GET_NAMING(nmstrtPages, (unsigned char)p[0], (unsigned char)p[1]) - -#ifdef XML_MIN_SIZE - -static int PTRFASTCALL -big2_byteType(const ENCODING *enc, const char *p) -{ - return BIG2_BYTE_TYPE(enc, p); -} - -static int PTRFASTCALL -big2_byteToAscii(const ENCODING *enc, const char *p) -{ - return BIG2_BYTE_TO_ASCII(enc, p); -} - -static int PTRCALL -big2_charMatches(const ENCODING *enc, const char *p, int c) -{ - return BIG2_CHAR_MATCHES(enc, p, c); -} - -static int PTRFASTCALL -big2_isNameMin(const ENCODING *enc, const char *p) -{ - return BIG2_IS_NAME_CHAR_MINBPC(enc, p); -} - -static int PTRFASTCALL -big2_isNmstrtMin(const ENCODING *enc, const char *p) -{ - return BIG2_IS_NMSTRT_CHAR_MINBPC(enc, p); -} - -#undef VTABLE -#define VTABLE VTABLE1, big2_toUtf8, big2_toUtf16 - -#else /* not XML_MIN_SIZE */ - -#undef PREFIX -#define PREFIX(ident) big2_ ## ident -#define MINBPC(enc) 2 -/* CHAR_MATCHES is guaranteed to have MINBPC bytes available. */ -#define BYTE_TYPE(enc, p) BIG2_BYTE_TYPE(enc, p) -#define BYTE_TO_ASCII(enc, p) BIG2_BYTE_TO_ASCII(enc, p) -#define CHAR_MATCHES(enc, p, c) BIG2_CHAR_MATCHES(enc, p, c) -#define IS_NAME_CHAR(enc, p, n) 0 -#define IS_NAME_CHAR_MINBPC(enc, p) BIG2_IS_NAME_CHAR_MINBPC(enc, p) -#define IS_NMSTRT_CHAR(enc, p, n) (0) -#define IS_NMSTRT_CHAR_MINBPC(enc, p) BIG2_IS_NMSTRT_CHAR_MINBPC(enc, p) - -#define XML_TOK_IMPL_C -#include "xmltok_impl.c" -#undef XML_TOK_IMPL_C - -#undef MINBPC -#undef BYTE_TYPE -#undef BYTE_TO_ASCII -#undef CHAR_MATCHES -#undef IS_NAME_CHAR -#undef IS_NAME_CHAR_MINBPC -#undef IS_NMSTRT_CHAR -#undef IS_NMSTRT_CHAR_MINBPC -#undef IS_INVALID_CHAR - -#endif /* not XML_MIN_SIZE */ - -#ifdef XML_NS - -static const struct normal_encoding big2_encoding_ns = { - { VTABLE, 2, 0, -#if BYTEORDER == 4321 - 1 -#else - 0 -#endif - }, - { -#include "asciitab.h" -#include "latin1tab.h" - }, - STANDARD_VTABLE(big2_) -}; - -#endif - -static const struct normal_encoding big2_encoding = { - { VTABLE, 2, 0, -#if BYTEORDER == 4321 - 1 -#else - 0 -#endif - }, - { -#define BT_COLON BT_NMSTRT -#include "asciitab.h" -#undef BT_COLON -#include "latin1tab.h" - }, - STANDARD_VTABLE(big2_) -}; - -#if BYTEORDER != 1234 - -#ifdef XML_NS - -static const struct normal_encoding internal_big2_encoding_ns = { - { VTABLE, 2, 0, 1 }, - { -#include "iasciitab.h" -#include "latin1tab.h" - }, - STANDARD_VTABLE(big2_) -}; - -#endif - -static const struct normal_encoding internal_big2_encoding = { - { VTABLE, 2, 0, 1 }, - { -#define BT_COLON BT_NMSTRT -#include "iasciitab.h" -#undef BT_COLON -#include "latin1tab.h" - }, - STANDARD_VTABLE(big2_) -}; - -#endif - -#undef PREFIX - -static int FASTCALL -streqci(const char *s1, const char *s2) -{ - for (;;) { - char c1 = *s1++; - char c2 = *s2++; - if (ASCII_a <= c1 && c1 <= ASCII_z) - c1 += ASCII_A - ASCII_a; - if (ASCII_a <= c2 && c2 <= ASCII_z) - c2 += ASCII_A - ASCII_a; - if (c1 != c2) - return 0; - if (!c1) - break; - } - return 1; -} - -static void PTRCALL -initUpdatePosition(const ENCODING *enc, const char *ptr, - const char *end, POSITION *pos) -{ - normal_updatePosition(&utf8_encoding.enc, ptr, end, pos); -} - -static int -toAscii(const ENCODING *enc, const char *ptr, const char *end) -{ - char buf[1]; - char *p = buf; - XmlUtf8Convert(enc, &ptr, end, &p, p + 1); - if (p == buf) - return -1; - else - return buf[0]; -} - -static int FASTCALL -isSpace(int c) -{ - switch (c) { - case 0x20: - case 0xD: - case 0xA: - case 0x9: - return 1; - } - return 0; -} - -/* Return 1 if there's just optional white space or there's an S - followed by name=val. -*/ -static int -parsePseudoAttribute(const ENCODING *enc, - const char *ptr, - const char *end, - const char **namePtr, - const char **nameEndPtr, - const char **valPtr, - const char **nextTokPtr) -{ - int c; - char open; - if (ptr == end) { - *namePtr = NULL; - return 1; - } - if (!isSpace(toAscii(enc, ptr, end))) { - *nextTokPtr = ptr; - return 0; - } - do { - ptr += enc->minBytesPerChar; - } while (isSpace(toAscii(enc, ptr, end))); - if (ptr == end) { - *namePtr = NULL; - return 1; - } - *namePtr = ptr; - for (;;) { - c = toAscii(enc, ptr, end); - if (c == -1) { - *nextTokPtr = ptr; - return 0; - } - if (c == ASCII_EQUALS) { - *nameEndPtr = ptr; - break; - } - if (isSpace(c)) { - *nameEndPtr = ptr; - do { - ptr += enc->minBytesPerChar; - } while (isSpace(c = toAscii(enc, ptr, end))); - if (c != ASCII_EQUALS) { - *nextTokPtr = ptr; - return 0; - } - break; - } - ptr += enc->minBytesPerChar; - } - if (ptr == *namePtr) { - *nextTokPtr = ptr; - return 0; - } - ptr += enc->minBytesPerChar; - c = toAscii(enc, ptr, end); - while (isSpace(c)) { - ptr += enc->minBytesPerChar; - c = toAscii(enc, ptr, end); - } - if (c != ASCII_QUOT && c != ASCII_APOS) { - *nextTokPtr = ptr; - return 0; - } - open = (char)c; - ptr += enc->minBytesPerChar; - *valPtr = ptr; - for (;; ptr += enc->minBytesPerChar) { - c = toAscii(enc, ptr, end); - if (c == open) - break; - if (!(ASCII_a <= c && c <= ASCII_z) - && !(ASCII_A <= c && c <= ASCII_Z) - && !(ASCII_0 <= c && c <= ASCII_9) - && c != ASCII_PERIOD - && c != ASCII_MINUS - && c != ASCII_UNDERSCORE) { - *nextTokPtr = ptr; - return 0; - } - } - *nextTokPtr = ptr + enc->minBytesPerChar; - return 1; -} - -static const char KW_version[] = { - ASCII_v, ASCII_e, ASCII_r, ASCII_s, ASCII_i, ASCII_o, ASCII_n, '\0' -}; - -static const char KW_encoding[] = { - ASCII_e, ASCII_n, ASCII_c, ASCII_o, ASCII_d, ASCII_i, ASCII_n, ASCII_g, '\0' -}; - -static const char KW_standalone[] = { - ASCII_s, ASCII_t, ASCII_a, ASCII_n, ASCII_d, ASCII_a, ASCII_l, ASCII_o, - ASCII_n, ASCII_e, '\0' -}; - -static const char KW_yes[] = { - ASCII_y, ASCII_e, ASCII_s, '\0' -}; - -static const char KW_no[] = { - ASCII_n, ASCII_o, '\0' -}; - -static int -doParseXmlDecl(const ENCODING *(*encodingFinder)(const ENCODING *, - const char *, - const char *), - int isGeneralTextEntity, - const ENCODING *enc, - const char *ptr, - const char *end, - const char **badPtr, - const char **versionPtr, - const char **versionEndPtr, - const char **encodingName, - const ENCODING **encoding, - int *standalone) -{ - const char *val = NULL; - const char *name = NULL; - const char *nameEnd = NULL; - ptr += 5 * enc->minBytesPerChar; - end -= 2 * enc->minBytesPerChar; - if (!parsePseudoAttribute(enc, ptr, end, &name, &nameEnd, &val, &ptr) - || !name) { - *badPtr = ptr; - return 0; - } - if (!XmlNameMatchesAscii(enc, name, nameEnd, KW_version)) { - if (!isGeneralTextEntity) { - *badPtr = name; - return 0; - } - } - else { - if (versionPtr) - *versionPtr = val; - if (versionEndPtr) - *versionEndPtr = ptr; - if (!parsePseudoAttribute(enc, ptr, end, &name, &nameEnd, &val, &ptr)) { - *badPtr = ptr; - return 0; - } - if (!name) { - if (isGeneralTextEntity) { - /* a TextDecl must have an EncodingDecl */ - *badPtr = ptr; - return 0; - } - return 1; - } - } - if (XmlNameMatchesAscii(enc, name, nameEnd, KW_encoding)) { - int c = toAscii(enc, val, end); - if (!(ASCII_a <= c && c <= ASCII_z) && !(ASCII_A <= c && c <= ASCII_Z)) { - *badPtr = val; - return 0; - } - if (encodingName) - *encodingName = val; - if (encoding) - *encoding = encodingFinder(enc, val, ptr - enc->minBytesPerChar); - if (!parsePseudoAttribute(enc, ptr, end, &name, &nameEnd, &val, &ptr)) { - *badPtr = ptr; - return 0; - } - if (!name) - return 1; - } - if (!XmlNameMatchesAscii(enc, name, nameEnd, KW_standalone) - || isGeneralTextEntity) { - *badPtr = name; - return 0; - } - if (XmlNameMatchesAscii(enc, val, ptr - enc->minBytesPerChar, KW_yes)) { - if (standalone) - *standalone = 1; - } - else if (XmlNameMatchesAscii(enc, val, ptr - enc->minBytesPerChar, KW_no)) { - if (standalone) - *standalone = 0; - } - else { - *badPtr = val; - return 0; - } - while (isSpace(toAscii(enc, ptr, end))) - ptr += enc->minBytesPerChar; - if (ptr != end) { - *badPtr = ptr; - return 0; - } - return 1; -} - -static int FASTCALL -checkCharRefNumber(int result) -{ - switch (result >> 8) { - case 0xD8: case 0xD9: case 0xDA: case 0xDB: - case 0xDC: case 0xDD: case 0xDE: case 0xDF: - return -1; - case 0: - if (latin1_encoding.type[result] == BT_NONXML) - return -1; - break; - case 0xFF: - if (result == 0xFFFE || result == 0xFFFF) - return -1; - break; - } - return result; -} - -int FASTCALL -XmlUtf8Encode(int c, char *buf) -{ - enum { - /* minN is minimum legal resulting value for N byte sequence */ - min2 = 0x80, - min3 = 0x800, - min4 = 0x10000 - }; - - if (c < 0) - return 0; - if (c < min2) { - buf[0] = (char)(c | UTF8_cval1); - return 1; - } - if (c < min3) { - buf[0] = (char)((c >> 6) | UTF8_cval2); - buf[1] = (char)((c & 0x3f) | 0x80); - return 2; - } - if (c < min4) { - buf[0] = (char)((c >> 12) | UTF8_cval3); - buf[1] = (char)(((c >> 6) & 0x3f) | 0x80); - buf[2] = (char)((c & 0x3f) | 0x80); - return 3; - } - if (c < 0x110000) { - buf[0] = (char)((c >> 18) | UTF8_cval4); - buf[1] = (char)(((c >> 12) & 0x3f) | 0x80); - buf[2] = (char)(((c >> 6) & 0x3f) | 0x80); - buf[3] = (char)((c & 0x3f) | 0x80); - return 4; - } - return 0; -} - -int FASTCALL -XmlUtf16Encode(int charNum, unsigned short *buf) -{ - if (charNum < 0) - return 0; - if (charNum < 0x10000) { - buf[0] = (unsigned short)charNum; - return 1; - } - if (charNum < 0x110000) { - charNum -= 0x10000; - buf[0] = (unsigned short)((charNum >> 10) + 0xD800); - buf[1] = (unsigned short)((charNum & 0x3FF) + 0xDC00); - return 2; - } - return 0; -} - -struct unknown_encoding { - struct normal_encoding normal; - CONVERTER convert; - void *userData; - unsigned short utf16[256]; - char utf8[256][4]; -}; - -#define AS_UNKNOWN_ENCODING(enc) ((const struct unknown_encoding *) (enc)) - -int -XmlSizeOfUnknownEncoding(void) -{ - return sizeof(struct unknown_encoding); -} - -static int PTRFASTCALL -unknown_isName(const ENCODING *enc, const char *p) -{ - const struct unknown_encoding *uenc = AS_UNKNOWN_ENCODING(enc); - int c = uenc->convert(uenc->userData, p); - if (c & ~0xFFFF) - return 0; - return UCS2_GET_NAMING(namePages, c >> 8, c & 0xFF); -} - -static int PTRFASTCALL -unknown_isNmstrt(const ENCODING *enc, const char *p) -{ - const struct unknown_encoding *uenc = AS_UNKNOWN_ENCODING(enc); - int c = uenc->convert(uenc->userData, p); - if (c & ~0xFFFF) - return 0; - return UCS2_GET_NAMING(nmstrtPages, c >> 8, c & 0xFF); -} - -static int PTRFASTCALL -unknown_isInvalid(const ENCODING *enc, const char *p) -{ - const struct unknown_encoding *uenc = AS_UNKNOWN_ENCODING(enc); - int c = uenc->convert(uenc->userData, p); - return (c & ~0xFFFF) || checkCharRefNumber(c) < 0; -} - -static void PTRCALL -unknown_toUtf8(const ENCODING *enc, - const char **fromP, const char *fromLim, - char **toP, const char *toLim) -{ - const struct unknown_encoding *uenc = AS_UNKNOWN_ENCODING(enc); - char buf[XML_UTF8_ENCODE_MAX]; - for (;;) { - const char *utf8; - int n; - if (*fromP == fromLim) - break; - utf8 = uenc->utf8[(unsigned char)**fromP]; - n = *utf8++; - if (n == 0) { - int c = uenc->convert(uenc->userData, *fromP); - n = XmlUtf8Encode(c, buf); - if (n > toLim - *toP) - break; - utf8 = buf; - *fromP += (AS_NORMAL_ENCODING(enc)->type[(unsigned char)**fromP] - - (BT_LEAD2 - 2)); - } - else { - if (n > toLim - *toP) - break; - (*fromP)++; - } - do { - *(*toP)++ = *utf8++; - } while (--n != 0); - } -} - -static void PTRCALL -unknown_toUtf16(const ENCODING *enc, - const char **fromP, const char *fromLim, - unsigned short **toP, const unsigned short *toLim) -{ - const struct unknown_encoding *uenc = AS_UNKNOWN_ENCODING(enc); - while (*fromP != fromLim && *toP != toLim) { - unsigned short c = uenc->utf16[(unsigned char)**fromP]; - if (c == 0) { - c = (unsigned short) - uenc->convert(uenc->userData, *fromP); - *fromP += (AS_NORMAL_ENCODING(enc)->type[(unsigned char)**fromP] - - (BT_LEAD2 - 2)); - } - else - (*fromP)++; - *(*toP)++ = c; - } -} - -ENCODING * -XmlInitUnknownEncoding(void *mem, - int *table, - CONVERTER convert, - void *userData) -{ - int i; - struct unknown_encoding *e = (struct unknown_encoding *)mem; - for (i = 0; i < (int)sizeof(struct normal_encoding); i++) - ((char *)mem)[i] = ((char *)&latin1_encoding)[i]; - for (i = 0; i < 128; i++) - if (latin1_encoding.type[i] != BT_OTHER - && latin1_encoding.type[i] != BT_NONXML - && table[i] != i) - return 0; - for (i = 0; i < 256; i++) { - int c = table[i]; - if (c == -1) { - e->normal.type[i] = BT_MALFORM; - /* This shouldn't really get used. */ - e->utf16[i] = 0xFFFF; - e->utf8[i][0] = 1; - e->utf8[i][1] = 0; - } - else if (c < 0) { - if (c < -4) - return 0; - e->normal.type[i] = (unsigned char)(BT_LEAD2 - (c + 2)); - e->utf8[i][0] = 0; - e->utf16[i] = 0; - } - else if (c < 0x80) { - if (latin1_encoding.type[c] != BT_OTHER - && latin1_encoding.type[c] != BT_NONXML - && c != i) - return 0; - e->normal.type[i] = latin1_encoding.type[c]; - e->utf8[i][0] = 1; - e->utf8[i][1] = (char)c; - e->utf16[i] = (unsigned short)(c == 0 ? 0xFFFF : c); - } - else if (checkCharRefNumber(c) < 0) { - e->normal.type[i] = BT_NONXML; - /* This shouldn't really get used. */ - e->utf16[i] = 0xFFFF; - e->utf8[i][0] = 1; - e->utf8[i][1] = 0; - } - else { - if (c > 0xFFFF) - return 0; - if (UCS2_GET_NAMING(nmstrtPages, c >> 8, c & 0xff)) - e->normal.type[i] = BT_NMSTRT; - else if (UCS2_GET_NAMING(namePages, c >> 8, c & 0xff)) - e->normal.type[i] = BT_NAME; - else - e->normal.type[i] = BT_OTHER; - e->utf8[i][0] = (char)XmlUtf8Encode(c, e->utf8[i] + 1); - e->utf16[i] = (unsigned short)c; - } - } - e->userData = userData; - e->convert = convert; - if (convert) { - e->normal.isName2 = unknown_isName; - e->normal.isName3 = unknown_isName; - e->normal.isName4 = unknown_isName; - e->normal.isNmstrt2 = unknown_isNmstrt; - e->normal.isNmstrt3 = unknown_isNmstrt; - e->normal.isNmstrt4 = unknown_isNmstrt; - e->normal.isInvalid2 = unknown_isInvalid; - e->normal.isInvalid3 = unknown_isInvalid; - e->normal.isInvalid4 = unknown_isInvalid; - } - e->normal.enc.utf8Convert = unknown_toUtf8; - e->normal.enc.utf16Convert = unknown_toUtf16; - return &(e->normal.enc); -} - -/* If this enumeration is changed, getEncodingIndex and encodings -must also be changed. */ -enum { - UNKNOWN_ENC = -1, - ISO_8859_1_ENC = 0, - US_ASCII_ENC, - UTF_8_ENC, - UTF_16_ENC, - UTF_16BE_ENC, - UTF_16LE_ENC, - /* must match encodingNames up to here */ - NO_ENC -}; - -static const char KW_ISO_8859_1[] = { - ASCII_I, ASCII_S, ASCII_O, ASCII_MINUS, ASCII_8, ASCII_8, ASCII_5, ASCII_9, - ASCII_MINUS, ASCII_1, '\0' -}; -static const char KW_US_ASCII[] = { - ASCII_U, ASCII_S, ASCII_MINUS, ASCII_A, ASCII_S, ASCII_C, ASCII_I, ASCII_I, - '\0' -}; -static const char KW_UTF_8[] = { - ASCII_U, ASCII_T, ASCII_F, ASCII_MINUS, ASCII_8, '\0' -}; -static const char KW_UTF_16[] = { - ASCII_U, ASCII_T, ASCII_F, ASCII_MINUS, ASCII_1, ASCII_6, '\0' -}; -static const char KW_UTF_16BE[] = { - ASCII_U, ASCII_T, ASCII_F, ASCII_MINUS, ASCII_1, ASCII_6, ASCII_B, ASCII_E, - '\0' -}; -static const char KW_UTF_16LE[] = { - ASCII_U, ASCII_T, ASCII_F, ASCII_MINUS, ASCII_1, ASCII_6, ASCII_L, ASCII_E, - '\0' -}; - -static int FASTCALL -getEncodingIndex(const char *name) -{ - static const char * const encodingNames[] = { - KW_ISO_8859_1, - KW_US_ASCII, - KW_UTF_8, - KW_UTF_16, - KW_UTF_16BE, - KW_UTF_16LE, - }; - int i; - if (name == NULL) - return NO_ENC; - for (i = 0; i < (int)(sizeof(encodingNames)/sizeof(encodingNames[0])); i++) - if (streqci(name, encodingNames[i])) - return i; - return UNKNOWN_ENC; -} - -/* For binary compatibility, we store the index of the encoding - specified at initialization in the isUtf16 member. -*/ - -#define INIT_ENC_INDEX(enc) ((int)(enc)->initEnc.isUtf16) -#define SET_INIT_ENC_INDEX(enc, i) ((enc)->initEnc.isUtf16 = (char)i) - -/* This is what detects the encoding. encodingTable maps from - encoding indices to encodings; INIT_ENC_INDEX(enc) is the index of - the external (protocol) specified encoding; state is - XML_CONTENT_STATE if we're parsing an external text entity, and - XML_PROLOG_STATE otherwise. -*/ - - -static int -initScan(const ENCODING * const *encodingTable, - const INIT_ENCODING *enc, - int state, - const char *ptr, - const char *end, - const char **nextTokPtr) -{ - const ENCODING **encPtr; - - if (ptr == end) - return XML_TOK_NONE; - encPtr = enc->encPtr; - if (ptr + 1 == end) { - /* only a single byte available for auto-detection */ -#ifndef XML_DTD /* FIXME */ - /* a well-formed document entity must have more than one byte */ - if (state != XML_CONTENT_STATE) - return XML_TOK_PARTIAL; -#endif - /* so we're parsing an external text entity... */ - /* if UTF-16 was externally specified, then we need at least 2 bytes */ - switch (INIT_ENC_INDEX(enc)) { - case UTF_16_ENC: - case UTF_16LE_ENC: - case UTF_16BE_ENC: - return XML_TOK_PARTIAL; - } - switch ((unsigned char)*ptr) { - case 0xFE: - case 0xFF: - case 0xEF: /* possibly first byte of UTF-8 BOM */ - if (INIT_ENC_INDEX(enc) == ISO_8859_1_ENC - && state == XML_CONTENT_STATE) - break; - /* fall through */ - case 0x00: - case 0x3C: - return XML_TOK_PARTIAL; - } - } - else { - switch (((unsigned char)ptr[0] << 8) | (unsigned char)ptr[1]) { - case 0xFEFF: - if (INIT_ENC_INDEX(enc) == ISO_8859_1_ENC - && state == XML_CONTENT_STATE) - break; - *nextTokPtr = ptr + 2; - *encPtr = encodingTable[UTF_16BE_ENC]; - return XML_TOK_BOM; - /* 00 3C is handled in the default case */ - case 0x3C00: - if ((INIT_ENC_INDEX(enc) == UTF_16BE_ENC - || INIT_ENC_INDEX(enc) == UTF_16_ENC) - && state == XML_CONTENT_STATE) - break; - *encPtr = encodingTable[UTF_16LE_ENC]; - return XmlTok(*encPtr, state, ptr, end, nextTokPtr); - case 0xFFFE: - if (INIT_ENC_INDEX(enc) == ISO_8859_1_ENC - && state == XML_CONTENT_STATE) - break; - *nextTokPtr = ptr + 2; - *encPtr = encodingTable[UTF_16LE_ENC]; - return XML_TOK_BOM; - case 0xEFBB: - /* Maybe a UTF-8 BOM (EF BB BF) */ - /* If there's an explicitly specified (external) encoding - of ISO-8859-1 or some flavour of UTF-16 - and this is an external text entity, - don't look for the BOM, - because it might be a legal data. - */ - if (state == XML_CONTENT_STATE) { - int e = INIT_ENC_INDEX(enc); - if (e == ISO_8859_1_ENC || e == UTF_16BE_ENC - || e == UTF_16LE_ENC || e == UTF_16_ENC) - break; - } - if (ptr + 2 == end) - return XML_TOK_PARTIAL; - if ((unsigned char)ptr[2] == 0xBF) { - *nextTokPtr = ptr + 3; - *encPtr = encodingTable[UTF_8_ENC]; - return XML_TOK_BOM; - } - break; - default: - if (ptr[0] == '\0') { - /* 0 isn't a legal data character. Furthermore a document - entity can only start with ASCII characters. So the only - way this can fail to be big-endian UTF-16 if it it's an - external parsed general entity that's labelled as - UTF-16LE. - */ - if (state == XML_CONTENT_STATE && INIT_ENC_INDEX(enc) == UTF_16LE_ENC) - break; - *encPtr = encodingTable[UTF_16BE_ENC]; - return XmlTok(*encPtr, state, ptr, end, nextTokPtr); - } - else if (ptr[1] == '\0') { - /* We could recover here in the case: - - parsing an external entity - - second byte is 0 - - no externally specified encoding - - no encoding declaration - by assuming UTF-16LE. But we don't, because this would mean when - presented just with a single byte, we couldn't reliably determine - whether we needed further bytes. - */ - if (state == XML_CONTENT_STATE) - break; - *encPtr = encodingTable[UTF_16LE_ENC]; - return XmlTok(*encPtr, state, ptr, end, nextTokPtr); - } - break; - } - } - *encPtr = encodingTable[INIT_ENC_INDEX(enc)]; - return XmlTok(*encPtr, state, ptr, end, nextTokPtr); -} - - -#define NS(x) x -#define ns(x) x -#define XML_TOK_NS_C -#include "xmltok_ns.c" -#undef XML_TOK_NS_C -#undef NS -#undef ns - -#ifdef XML_NS - -#define NS(x) x ## NS -#define ns(x) x ## _ns - -#define XML_TOK_NS_C -#include "xmltok_ns.c" -#undef XML_TOK_NS_C - -#undef NS -#undef ns - -ENCODING * -XmlInitUnknownEncodingNS(void *mem, - int *table, - CONVERTER convert, - void *userData) -{ - ENCODING *enc = XmlInitUnknownEncoding(mem, table, convert, userData); - if (enc) - ((struct normal_encoding *)enc)->type[ASCII_COLON] = BT_COLON; - return enc; -} - -#endif /* XML_NS */ diff --git a/lib-src/expat/lib/xmltok.h b/lib-src/expat/lib/xmltok.h deleted file mode 100644 index ca867aa6b..000000000 --- a/lib-src/expat/lib/xmltok.h +++ /dev/null @@ -1,316 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#ifndef XmlTok_INCLUDED -#define XmlTok_INCLUDED 1 - -#ifdef __cplusplus -extern "C" { -#endif - -/* The following token may be returned by XmlContentTok */ -#define XML_TOK_TRAILING_RSQB -5 /* ] or ]] at the end of the scan; might be - start of illegal ]]> sequence */ -/* The following tokens may be returned by both XmlPrologTok and - XmlContentTok. -*/ -#define XML_TOK_NONE -4 /* The string to be scanned is empty */ -#define XML_TOK_TRAILING_CR -3 /* A CR at the end of the scan; - might be part of CRLF sequence */ -#define XML_TOK_PARTIAL_CHAR -2 /* only part of a multibyte sequence */ -#define XML_TOK_PARTIAL -1 /* only part of a token */ -#define XML_TOK_INVALID 0 - -/* The following tokens are returned by XmlContentTok; some are also - returned by XmlAttributeValueTok, XmlEntityTok, XmlCdataSectionTok. -*/ -#define XML_TOK_START_TAG_WITH_ATTS 1 -#define XML_TOK_START_TAG_NO_ATTS 2 -#define XML_TOK_EMPTY_ELEMENT_WITH_ATTS 3 /* empty element tag */ -#define XML_TOK_EMPTY_ELEMENT_NO_ATTS 4 -#define XML_TOK_END_TAG 5 -#define XML_TOK_DATA_CHARS 6 -#define XML_TOK_DATA_NEWLINE 7 -#define XML_TOK_CDATA_SECT_OPEN 8 -#define XML_TOK_ENTITY_REF 9 -#define XML_TOK_CHAR_REF 10 /* numeric character reference */ - -/* The following tokens may be returned by both XmlPrologTok and - XmlContentTok. -*/ -#define XML_TOK_PI 11 /* processing instruction */ -#define XML_TOK_XML_DECL 12 /* XML decl or text decl */ -#define XML_TOK_COMMENT 13 -#define XML_TOK_BOM 14 /* Byte order mark */ - -/* The following tokens are returned only by XmlPrologTok */ -#define XML_TOK_PROLOG_S 15 -#define XML_TOK_DECL_OPEN 16 /* */ -#define XML_TOK_NAME 18 -#define XML_TOK_NMTOKEN 19 -#define XML_TOK_POUND_NAME 20 /* #name */ -#define XML_TOK_OR 21 /* | */ -#define XML_TOK_PERCENT 22 -#define XML_TOK_OPEN_PAREN 23 -#define XML_TOK_CLOSE_PAREN 24 -#define XML_TOK_OPEN_BRACKET 25 -#define XML_TOK_CLOSE_BRACKET 26 -#define XML_TOK_LITERAL 27 -#define XML_TOK_PARAM_ENTITY_REF 28 -#define XML_TOK_INSTANCE_START 29 - -/* The following occur only in element type declarations */ -#define XML_TOK_NAME_QUESTION 30 /* name? */ -#define XML_TOK_NAME_ASTERISK 31 /* name* */ -#define XML_TOK_NAME_PLUS 32 /* name+ */ -#define XML_TOK_COND_SECT_OPEN 33 /* */ -#define XML_TOK_CLOSE_PAREN_QUESTION 35 /* )? */ -#define XML_TOK_CLOSE_PAREN_ASTERISK 36 /* )* */ -#define XML_TOK_CLOSE_PAREN_PLUS 37 /* )+ */ -#define XML_TOK_COMMA 38 - -/* The following token is returned only by XmlAttributeValueTok */ -#define XML_TOK_ATTRIBUTE_VALUE_S 39 - -/* The following token is returned only by XmlCdataSectionTok */ -#define XML_TOK_CDATA_SECT_CLOSE 40 - -/* With namespace processing this is returned by XmlPrologTok for a - name with a colon. -*/ -#define XML_TOK_PREFIXED_NAME 41 - -#ifdef XML_DTD -#define XML_TOK_IGNORE_SECT 42 -#endif /* XML_DTD */ - -#ifdef XML_DTD -#define XML_N_STATES 4 -#else /* not XML_DTD */ -#define XML_N_STATES 3 -#endif /* not XML_DTD */ - -#define XML_PROLOG_STATE 0 -#define XML_CONTENT_STATE 1 -#define XML_CDATA_SECTION_STATE 2 -#ifdef XML_DTD -#define XML_IGNORE_SECTION_STATE 3 -#endif /* XML_DTD */ - -#define XML_N_LITERAL_TYPES 2 -#define XML_ATTRIBUTE_VALUE_LITERAL 0 -#define XML_ENTITY_VALUE_LITERAL 1 - -/* The size of the buffer passed to XmlUtf8Encode must be at least this. */ -#define XML_UTF8_ENCODE_MAX 4 -/* The size of the buffer passed to XmlUtf16Encode must be at least this. */ -#define XML_UTF16_ENCODE_MAX 2 - -typedef struct position { - /* first line and first column are 0 not 1 */ - XML_Size lineNumber; - XML_Size columnNumber; -} POSITION; - -typedef struct { - const char *name; - const char *valuePtr; - const char *valueEnd; - char normalized; -} ATTRIBUTE; - -struct encoding; -typedef struct encoding ENCODING; - -typedef int (PTRCALL *SCANNER)(const ENCODING *, - const char *, - const char *, - const char **); - -struct encoding { - SCANNER scanners[XML_N_STATES]; - SCANNER literalScanners[XML_N_LITERAL_TYPES]; - int (PTRCALL *sameName)(const ENCODING *, - const char *, - const char *); - int (PTRCALL *nameMatchesAscii)(const ENCODING *, - const char *, - const char *, - const char *); - int (PTRFASTCALL *nameLength)(const ENCODING *, const char *); - const char *(PTRFASTCALL *skipS)(const ENCODING *, const char *); - int (PTRCALL *getAtts)(const ENCODING *enc, - const char *ptr, - int attsMax, - ATTRIBUTE *atts); - int (PTRFASTCALL *charRefNumber)(const ENCODING *enc, const char *ptr); - int (PTRCALL *predefinedEntityName)(const ENCODING *, - const char *, - const char *); - void (PTRCALL *updatePosition)(const ENCODING *, - const char *ptr, - const char *end, - POSITION *); - int (PTRCALL *isPublicId)(const ENCODING *enc, - const char *ptr, - const char *end, - const char **badPtr); - void (PTRCALL *utf8Convert)(const ENCODING *enc, - const char **fromP, - const char *fromLim, - char **toP, - const char *toLim); - void (PTRCALL *utf16Convert)(const ENCODING *enc, - const char **fromP, - const char *fromLim, - unsigned short **toP, - const unsigned short *toLim); - int minBytesPerChar; - char isUtf8; - char isUtf16; -}; - -/* Scan the string starting at ptr until the end of the next complete - token, but do not scan past eptr. Return an integer giving the - type of token. - - Return XML_TOK_NONE when ptr == eptr; nextTokPtr will not be set. - - Return XML_TOK_PARTIAL when the string does not contain a complete - token; nextTokPtr will not be set. - - Return XML_TOK_INVALID when the string does not start a valid - token; nextTokPtr will be set to point to the character which made - the token invalid. - - Otherwise the string starts with a valid token; nextTokPtr will be - set to point to the character following the end of that token. - - Each data character counts as a single token, but adjacent data - characters may be returned together. Similarly for characters in - the prolog outside literals, comments and processing instructions. -*/ - - -#define XmlTok(enc, state, ptr, end, nextTokPtr) \ - (((enc)->scanners[state])(enc, ptr, end, nextTokPtr)) - -#define XmlPrologTok(enc, ptr, end, nextTokPtr) \ - XmlTok(enc, XML_PROLOG_STATE, ptr, end, nextTokPtr) - -#define XmlContentTok(enc, ptr, end, nextTokPtr) \ - XmlTok(enc, XML_CONTENT_STATE, ptr, end, nextTokPtr) - -#define XmlCdataSectionTok(enc, ptr, end, nextTokPtr) \ - XmlTok(enc, XML_CDATA_SECTION_STATE, ptr, end, nextTokPtr) - -#ifdef XML_DTD - -#define XmlIgnoreSectionTok(enc, ptr, end, nextTokPtr) \ - XmlTok(enc, XML_IGNORE_SECTION_STATE, ptr, end, nextTokPtr) - -#endif /* XML_DTD */ - -/* This is used for performing a 2nd-level tokenization on the content - of a literal that has already been returned by XmlTok. -*/ -#define XmlLiteralTok(enc, literalType, ptr, end, nextTokPtr) \ - (((enc)->literalScanners[literalType])(enc, ptr, end, nextTokPtr)) - -#define XmlAttributeValueTok(enc, ptr, end, nextTokPtr) \ - XmlLiteralTok(enc, XML_ATTRIBUTE_VALUE_LITERAL, ptr, end, nextTokPtr) - -#define XmlEntityValueTok(enc, ptr, end, nextTokPtr) \ - XmlLiteralTok(enc, XML_ENTITY_VALUE_LITERAL, ptr, end, nextTokPtr) - -#define XmlSameName(enc, ptr1, ptr2) (((enc)->sameName)(enc, ptr1, ptr2)) - -#define XmlNameMatchesAscii(enc, ptr1, end1, ptr2) \ - (((enc)->nameMatchesAscii)(enc, ptr1, end1, ptr2)) - -#define XmlNameLength(enc, ptr) \ - (((enc)->nameLength)(enc, ptr)) - -#define XmlSkipS(enc, ptr) \ - (((enc)->skipS)(enc, ptr)) - -#define XmlGetAttributes(enc, ptr, attsMax, atts) \ - (((enc)->getAtts)(enc, ptr, attsMax, atts)) - -#define XmlCharRefNumber(enc, ptr) \ - (((enc)->charRefNumber)(enc, ptr)) - -#define XmlPredefinedEntityName(enc, ptr, end) \ - (((enc)->predefinedEntityName)(enc, ptr, end)) - -#define XmlUpdatePosition(enc, ptr, end, pos) \ - (((enc)->updatePosition)(enc, ptr, end, pos)) - -#define XmlIsPublicId(enc, ptr, end, badPtr) \ - (((enc)->isPublicId)(enc, ptr, end, badPtr)) - -#define XmlUtf8Convert(enc, fromP, fromLim, toP, toLim) \ - (((enc)->utf8Convert)(enc, fromP, fromLim, toP, toLim)) - -#define XmlUtf16Convert(enc, fromP, fromLim, toP, toLim) \ - (((enc)->utf16Convert)(enc, fromP, fromLim, toP, toLim)) - -typedef struct { - ENCODING initEnc; - const ENCODING **encPtr; -} INIT_ENCODING; - -int XmlParseXmlDecl(int isGeneralTextEntity, - const ENCODING *enc, - const char *ptr, - const char *end, - const char **badPtr, - const char **versionPtr, - const char **versionEndPtr, - const char **encodingNamePtr, - const ENCODING **namedEncodingPtr, - int *standalonePtr); - -int XmlInitEncoding(INIT_ENCODING *, const ENCODING **, const char *name); -const ENCODING *XmlGetUtf8InternalEncoding(void); -const ENCODING *XmlGetUtf16InternalEncoding(void); -int FASTCALL XmlUtf8Encode(int charNumber, char *buf); -int FASTCALL XmlUtf16Encode(int charNumber, unsigned short *buf); -int XmlSizeOfUnknownEncoding(void); - - -typedef int (XMLCALL *CONVERTER) (void *userData, const char *p); - -ENCODING * -XmlInitUnknownEncoding(void *mem, - int *table, - CONVERTER convert, - void *userData); - -int XmlParseXmlDeclNS(int isGeneralTextEntity, - const ENCODING *enc, - const char *ptr, - const char *end, - const char **badPtr, - const char **versionPtr, - const char **versionEndPtr, - const char **encodingNamePtr, - const ENCODING **namedEncodingPtr, - int *standalonePtr); - -int XmlInitEncodingNS(INIT_ENCODING *, const ENCODING **, const char *name); -const ENCODING *XmlGetUtf8InternalEncodingNS(void); -const ENCODING *XmlGetUtf16InternalEncodingNS(void); -ENCODING * -XmlInitUnknownEncodingNS(void *mem, - int *table, - CONVERTER convert, - void *userData); -#ifdef __cplusplus -} -#endif - -#endif /* not XmlTok_INCLUDED */ diff --git a/lib-src/expat/lib/xmltok_impl.c b/lib-src/expat/lib/xmltok_impl.c deleted file mode 100644 index 9c2895b87..000000000 --- a/lib-src/expat/lib/xmltok_impl.c +++ /dev/null @@ -1,1783 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -/* This file is included! */ -#ifdef XML_TOK_IMPL_C - -#ifndef IS_INVALID_CHAR -#define IS_INVALID_CHAR(enc, ptr, n) (0) -#endif - -#define INVALID_LEAD_CASE(n, ptr, nextTokPtr) \ - case BT_LEAD ## n: \ - if (end - ptr < n) \ - return XML_TOK_PARTIAL_CHAR; \ - if (IS_INVALID_CHAR(enc, ptr, n)) { \ - *(nextTokPtr) = (ptr); \ - return XML_TOK_INVALID; \ - } \ - ptr += n; \ - break; - -#define INVALID_CASES(ptr, nextTokPtr) \ - INVALID_LEAD_CASE(2, ptr, nextTokPtr) \ - INVALID_LEAD_CASE(3, ptr, nextTokPtr) \ - INVALID_LEAD_CASE(4, ptr, nextTokPtr) \ - case BT_NONXML: \ - case BT_MALFORM: \ - case BT_TRAIL: \ - *(nextTokPtr) = (ptr); \ - return XML_TOK_INVALID; - -#define CHECK_NAME_CASE(n, enc, ptr, end, nextTokPtr) \ - case BT_LEAD ## n: \ - if (end - ptr < n) \ - return XML_TOK_PARTIAL_CHAR; \ - if (!IS_NAME_CHAR(enc, ptr, n)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_INVALID; \ - } \ - ptr += n; \ - break; - -#define CHECK_NAME_CASES(enc, ptr, end, nextTokPtr) \ - case BT_NONASCII: \ - if (!IS_NAME_CHAR_MINBPC(enc, ptr)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_INVALID; \ - } \ - case BT_NMSTRT: \ - case BT_HEX: \ - case BT_DIGIT: \ - case BT_NAME: \ - case BT_MINUS: \ - ptr += MINBPC(enc); \ - break; \ - CHECK_NAME_CASE(2, enc, ptr, end, nextTokPtr) \ - CHECK_NAME_CASE(3, enc, ptr, end, nextTokPtr) \ - CHECK_NAME_CASE(4, enc, ptr, end, nextTokPtr) - -#define CHECK_NMSTRT_CASE(n, enc, ptr, end, nextTokPtr) \ - case BT_LEAD ## n: \ - if (end - ptr < n) \ - return XML_TOK_PARTIAL_CHAR; \ - if (!IS_NMSTRT_CHAR(enc, ptr, n)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_INVALID; \ - } \ - ptr += n; \ - break; - -#define CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr) \ - case BT_NONASCII: \ - if (!IS_NMSTRT_CHAR_MINBPC(enc, ptr)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_INVALID; \ - } \ - case BT_NMSTRT: \ - case BT_HEX: \ - ptr += MINBPC(enc); \ - break; \ - CHECK_NMSTRT_CASE(2, enc, ptr, end, nextTokPtr) \ - CHECK_NMSTRT_CASE(3, enc, ptr, end, nextTokPtr) \ - CHECK_NMSTRT_CASE(4, enc, ptr, end, nextTokPtr) - -#ifndef PREFIX -#define PREFIX(ident) ident -#endif - -/* ptr points to character following " */ - switch (BYTE_TYPE(enc, ptr + MINBPC(enc))) { - case BT_S: case BT_CR: case BT_LF: case BT_PERCNT: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - /* fall through */ - case BT_S: case BT_CR: case BT_LF: - *nextTokPtr = ptr; - return XML_TOK_DECL_OPEN; - case BT_NMSTRT: - case BT_HEX: - ptr += MINBPC(enc); - break; - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - } - return XML_TOK_PARTIAL; -} - -static int PTRCALL -PREFIX(checkPiTarget)(const ENCODING *enc, const char *ptr, - const char *end, int *tokPtr) -{ - int upper = 0; - *tokPtr = XML_TOK_PI; - if (end - ptr != MINBPC(enc)*3) - return 1; - switch (BYTE_TO_ASCII(enc, ptr)) { - case ASCII_x: - break; - case ASCII_X: - upper = 1; - break; - default: - return 1; - } - ptr += MINBPC(enc); - switch (BYTE_TO_ASCII(enc, ptr)) { - case ASCII_m: - break; - case ASCII_M: - upper = 1; - break; - default: - return 1; - } - ptr += MINBPC(enc); - switch (BYTE_TO_ASCII(enc, ptr)) { - case ASCII_l: - break; - case ASCII_L: - upper = 1; - break; - default: - return 1; - } - if (upper) - return 0; - *tokPtr = XML_TOK_XML_DECL; - return 1; -} - -/* ptr points to character following " 1) { - size_t n = end - ptr; - if (n & (MINBPC(enc) - 1)) { - n &= ~(MINBPC(enc) - 1); - if (n == 0) - return XML_TOK_PARTIAL; - end = ptr + n; - } - } - switch (BYTE_TYPE(enc, ptr)) { - case BT_RSQB: - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_PARTIAL; - if (!CHAR_MATCHES(enc, ptr, ASCII_RSQB)) - break; - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_PARTIAL; - if (!CHAR_MATCHES(enc, ptr, ASCII_GT)) { - ptr -= MINBPC(enc); - break; - } - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_CDATA_SECT_CLOSE; - case BT_CR: - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_PARTIAL; - if (BYTE_TYPE(enc, ptr) == BT_LF) - ptr += MINBPC(enc); - *nextTokPtr = ptr; - return XML_TOK_DATA_NEWLINE; - case BT_LF: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_DATA_NEWLINE; - INVALID_CASES(ptr, nextTokPtr) - default: - ptr += MINBPC(enc); - break; - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: \ - if (end - ptr < n || IS_INVALID_CHAR(enc, ptr, n)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_DATA_CHARS; \ - } \ - ptr += n; \ - break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_NONXML: - case BT_MALFORM: - case BT_TRAIL: - case BT_CR: - case BT_LF: - case BT_RSQB: - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - default: - ptr += MINBPC(enc); - break; - } - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; -} - -/* ptr points to character following " 1) { - size_t n = end - ptr; - if (n & (MINBPC(enc) - 1)) { - n &= ~(MINBPC(enc) - 1); - if (n == 0) - return XML_TOK_PARTIAL; - end = ptr + n; - } - } - switch (BYTE_TYPE(enc, ptr)) { - case BT_LT: - return PREFIX(scanLt)(enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_AMP: - return PREFIX(scanRef)(enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_CR: - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_TRAILING_CR; - if (BYTE_TYPE(enc, ptr) == BT_LF) - ptr += MINBPC(enc); - *nextTokPtr = ptr; - return XML_TOK_DATA_NEWLINE; - case BT_LF: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_DATA_NEWLINE; - case BT_RSQB: - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_TRAILING_RSQB; - if (!CHAR_MATCHES(enc, ptr, ASCII_RSQB)) - break; - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_TRAILING_RSQB; - if (!CHAR_MATCHES(enc, ptr, ASCII_GT)) { - ptr -= MINBPC(enc); - break; - } - *nextTokPtr = ptr; - return XML_TOK_INVALID; - INVALID_CASES(ptr, nextTokPtr) - default: - ptr += MINBPC(enc); - break; - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: \ - if (end - ptr < n || IS_INVALID_CHAR(enc, ptr, n)) { \ - *nextTokPtr = ptr; \ - return XML_TOK_DATA_CHARS; \ - } \ - ptr += n; \ - break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_RSQB: - if (ptr + MINBPC(enc) != end) { - if (!CHAR_MATCHES(enc, ptr + MINBPC(enc), ASCII_RSQB)) { - ptr += MINBPC(enc); - break; - } - if (ptr + 2*MINBPC(enc) != end) { - if (!CHAR_MATCHES(enc, ptr + 2*MINBPC(enc), ASCII_GT)) { - ptr += MINBPC(enc); - break; - } - *nextTokPtr = ptr + 2*MINBPC(enc); - return XML_TOK_INVALID; - } - } - /* fall through */ - case BT_AMP: - case BT_LT: - case BT_NONXML: - case BT_MALFORM: - case BT_TRAIL: - case BT_CR: - case BT_LF: - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - default: - ptr += MINBPC(enc); - break; - } - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; -} - -/* ptr points to character following "%" */ - -static int PTRCALL -PREFIX(scanPercent)(const ENCODING *enc, const char *ptr, const char *end, - const char **nextTokPtr) -{ - if (ptr == end) - return XML_TOK_PARTIAL; - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr) - case BT_S: case BT_LF: case BT_CR: case BT_PERCNT: - *nextTokPtr = ptr; - return XML_TOK_PERCENT; - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NAME_CASES(enc, ptr, end, nextTokPtr) - case BT_SEMI: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_PARAM_ENTITY_REF; - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - } - return XML_TOK_PARTIAL; -} - -static int PTRCALL -PREFIX(scanPoundName)(const ENCODING *enc, const char *ptr, const char *end, - const char **nextTokPtr) -{ - if (ptr == end) - return XML_TOK_PARTIAL; - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr) - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NAME_CASES(enc, ptr, end, nextTokPtr) - case BT_CR: case BT_LF: case BT_S: - case BT_RPAR: case BT_GT: case BT_PERCNT: case BT_VERBAR: - *nextTokPtr = ptr; - return XML_TOK_POUND_NAME; - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - } - return -XML_TOK_POUND_NAME; -} - -static int PTRCALL -PREFIX(scanLit)(int open, const ENCODING *enc, - const char *ptr, const char *end, - const char **nextTokPtr) -{ - while (ptr != end) { - int t = BYTE_TYPE(enc, ptr); - switch (t) { - INVALID_CASES(ptr, nextTokPtr) - case BT_QUOT: - case BT_APOS: - ptr += MINBPC(enc); - if (t != open) - break; - if (ptr == end) - return -XML_TOK_LITERAL; - *nextTokPtr = ptr; - switch (BYTE_TYPE(enc, ptr)) { - case BT_S: case BT_CR: case BT_LF: - case BT_GT: case BT_PERCNT: case BT_LSQB: - return XML_TOK_LITERAL; - default: - return XML_TOK_INVALID; - } - default: - ptr += MINBPC(enc); - break; - } - } - return XML_TOK_PARTIAL; -} - -static int PTRCALL -PREFIX(prologTok)(const ENCODING *enc, const char *ptr, const char *end, - const char **nextTokPtr) -{ - int tok; - if (ptr == end) - return XML_TOK_NONE; - if (MINBPC(enc) > 1) { - size_t n = end - ptr; - if (n & (MINBPC(enc) - 1)) { - n &= ~(MINBPC(enc) - 1); - if (n == 0) - return XML_TOK_PARTIAL; - end = ptr + n; - } - } - switch (BYTE_TYPE(enc, ptr)) { - case BT_QUOT: - return PREFIX(scanLit)(BT_QUOT, enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_APOS: - return PREFIX(scanLit)(BT_APOS, enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_LT: - { - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_PARTIAL; - switch (BYTE_TYPE(enc, ptr)) { - case BT_EXCL: - return PREFIX(scanDecl)(enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_QUEST: - return PREFIX(scanPi)(enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_NMSTRT: - case BT_HEX: - case BT_NONASCII: - case BT_LEAD2: - case BT_LEAD3: - case BT_LEAD4: - *nextTokPtr = ptr - MINBPC(enc); - return XML_TOK_INSTANCE_START; - } - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - case BT_CR: - if (ptr + MINBPC(enc) == end) { - *nextTokPtr = end; - /* indicate that this might be part of a CR/LF pair */ - return -XML_TOK_PROLOG_S; - } - /* fall through */ - case BT_S: case BT_LF: - for (;;) { - ptr += MINBPC(enc); - if (ptr == end) - break; - switch (BYTE_TYPE(enc, ptr)) { - case BT_S: case BT_LF: - break; - case BT_CR: - /* don't split CR/LF pair */ - if (ptr + MINBPC(enc) != end) - break; - /* fall through */ - default: - *nextTokPtr = ptr; - return XML_TOK_PROLOG_S; - } - } - *nextTokPtr = ptr; - return XML_TOK_PROLOG_S; - case BT_PERCNT: - return PREFIX(scanPercent)(enc, ptr + MINBPC(enc), end, nextTokPtr); - case BT_COMMA: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_COMMA; - case BT_LSQB: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_OPEN_BRACKET; - case BT_RSQB: - ptr += MINBPC(enc); - if (ptr == end) - return -XML_TOK_CLOSE_BRACKET; - if (CHAR_MATCHES(enc, ptr, ASCII_RSQB)) { - if (ptr + MINBPC(enc) == end) - return XML_TOK_PARTIAL; - if (CHAR_MATCHES(enc, ptr + MINBPC(enc), ASCII_GT)) { - *nextTokPtr = ptr + 2*MINBPC(enc); - return XML_TOK_COND_SECT_CLOSE; - } - } - *nextTokPtr = ptr; - return XML_TOK_CLOSE_BRACKET; - case BT_LPAR: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_OPEN_PAREN; - case BT_RPAR: - ptr += MINBPC(enc); - if (ptr == end) - return -XML_TOK_CLOSE_PAREN; - switch (BYTE_TYPE(enc, ptr)) { - case BT_AST: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_CLOSE_PAREN_ASTERISK; - case BT_QUEST: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_CLOSE_PAREN_QUESTION; - case BT_PLUS: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_CLOSE_PAREN_PLUS; - case BT_CR: case BT_LF: case BT_S: - case BT_GT: case BT_COMMA: case BT_VERBAR: - case BT_RPAR: - *nextTokPtr = ptr; - return XML_TOK_CLOSE_PAREN; - } - *nextTokPtr = ptr; - return XML_TOK_INVALID; - case BT_VERBAR: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_OR; - case BT_GT: - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_DECL_CLOSE; - case BT_NUM: - return PREFIX(scanPoundName)(enc, ptr + MINBPC(enc), end, nextTokPtr); -#define LEAD_CASE(n) \ - case BT_LEAD ## n: \ - if (end - ptr < n) \ - return XML_TOK_PARTIAL_CHAR; \ - if (IS_NMSTRT_CHAR(enc, ptr, n)) { \ - ptr += n; \ - tok = XML_TOK_NAME; \ - break; \ - } \ - if (IS_NAME_CHAR(enc, ptr, n)) { \ - ptr += n; \ - tok = XML_TOK_NMTOKEN; \ - break; \ - } \ - *nextTokPtr = ptr; \ - return XML_TOK_INVALID; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_NMSTRT: - case BT_HEX: - tok = XML_TOK_NAME; - ptr += MINBPC(enc); - break; - case BT_DIGIT: - case BT_NAME: - case BT_MINUS: -#ifdef XML_NS - case BT_COLON: -#endif - tok = XML_TOK_NMTOKEN; - ptr += MINBPC(enc); - break; - case BT_NONASCII: - if (IS_NMSTRT_CHAR_MINBPC(enc, ptr)) { - ptr += MINBPC(enc); - tok = XML_TOK_NAME; - break; - } - if (IS_NAME_CHAR_MINBPC(enc, ptr)) { - ptr += MINBPC(enc); - tok = XML_TOK_NMTOKEN; - break; - } - /* fall through */ - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NAME_CASES(enc, ptr, end, nextTokPtr) - case BT_GT: case BT_RPAR: case BT_COMMA: - case BT_VERBAR: case BT_LSQB: case BT_PERCNT: - case BT_S: case BT_CR: case BT_LF: - *nextTokPtr = ptr; - return tok; -#ifdef XML_NS - case BT_COLON: - ptr += MINBPC(enc); - switch (tok) { - case XML_TOK_NAME: - if (ptr == end) - return XML_TOK_PARTIAL; - tok = XML_TOK_PREFIXED_NAME; - switch (BYTE_TYPE(enc, ptr)) { - CHECK_NAME_CASES(enc, ptr, end, nextTokPtr) - default: - tok = XML_TOK_NMTOKEN; - break; - } - break; - case XML_TOK_PREFIXED_NAME: - tok = XML_TOK_NMTOKEN; - break; - } - break; -#endif - case BT_PLUS: - if (tok == XML_TOK_NMTOKEN) { - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_NAME_PLUS; - case BT_AST: - if (tok == XML_TOK_NMTOKEN) { - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_NAME_ASTERISK; - case BT_QUEST: - if (tok == XML_TOK_NMTOKEN) { - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_NAME_QUESTION; - default: - *nextTokPtr = ptr; - return XML_TOK_INVALID; - } - } - return -tok; -} - -static int PTRCALL -PREFIX(attributeValueTok)(const ENCODING *enc, const char *ptr, - const char *end, const char **nextTokPtr) -{ - const char *start; - if (ptr == end) - return XML_TOK_NONE; - start = ptr; - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: ptr += n; break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_AMP: - if (ptr == start) - return PREFIX(scanRef)(enc, ptr + MINBPC(enc), end, nextTokPtr); - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_LT: - /* this is for inside entity references */ - *nextTokPtr = ptr; - return XML_TOK_INVALID; - case BT_LF: - if (ptr == start) { - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_DATA_NEWLINE; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_CR: - if (ptr == start) { - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_TRAILING_CR; - if (BYTE_TYPE(enc, ptr) == BT_LF) - ptr += MINBPC(enc); - *nextTokPtr = ptr; - return XML_TOK_DATA_NEWLINE; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_S: - if (ptr == start) { - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_ATTRIBUTE_VALUE_S; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - default: - ptr += MINBPC(enc); - break; - } - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; -} - -static int PTRCALL -PREFIX(entityValueTok)(const ENCODING *enc, const char *ptr, - const char *end, const char **nextTokPtr) -{ - const char *start; - if (ptr == end) - return XML_TOK_NONE; - start = ptr; - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: ptr += n; break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_AMP: - if (ptr == start) - return PREFIX(scanRef)(enc, ptr + MINBPC(enc), end, nextTokPtr); - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_PERCNT: - if (ptr == start) { - int tok = PREFIX(scanPercent)(enc, ptr + MINBPC(enc), - end, nextTokPtr); - return (tok == XML_TOK_PERCENT) ? XML_TOK_INVALID : tok; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_LF: - if (ptr == start) { - *nextTokPtr = ptr + MINBPC(enc); - return XML_TOK_DATA_NEWLINE; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - case BT_CR: - if (ptr == start) { - ptr += MINBPC(enc); - if (ptr == end) - return XML_TOK_TRAILING_CR; - if (BYTE_TYPE(enc, ptr) == BT_LF) - ptr += MINBPC(enc); - *nextTokPtr = ptr; - return XML_TOK_DATA_NEWLINE; - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; - default: - ptr += MINBPC(enc); - break; - } - } - *nextTokPtr = ptr; - return XML_TOK_DATA_CHARS; -} - -#ifdef XML_DTD - -static int PTRCALL -PREFIX(ignoreSectionTok)(const ENCODING *enc, const char *ptr, - const char *end, const char **nextTokPtr) -{ - int level = 0; - if (MINBPC(enc) > 1) { - size_t n = end - ptr; - if (n & (MINBPC(enc) - 1)) { - n &= ~(MINBPC(enc) - 1); - end = ptr + n; - } - } - while (ptr != end) { - switch (BYTE_TYPE(enc, ptr)) { - INVALID_CASES(ptr, nextTokPtr) - case BT_LT: - if ((ptr += MINBPC(enc)) == end) - return XML_TOK_PARTIAL; - if (CHAR_MATCHES(enc, ptr, ASCII_EXCL)) { - if ((ptr += MINBPC(enc)) == end) - return XML_TOK_PARTIAL; - if (CHAR_MATCHES(enc, ptr, ASCII_LSQB)) { - ++level; - ptr += MINBPC(enc); - } - } - break; - case BT_RSQB: - if ((ptr += MINBPC(enc)) == end) - return XML_TOK_PARTIAL; - if (CHAR_MATCHES(enc, ptr, ASCII_RSQB)) { - if ((ptr += MINBPC(enc)) == end) - return XML_TOK_PARTIAL; - if (CHAR_MATCHES(enc, ptr, ASCII_GT)) { - ptr += MINBPC(enc); - if (level == 0) { - *nextTokPtr = ptr; - return XML_TOK_IGNORE_SECT; - } - --level; - } - } - break; - default: - ptr += MINBPC(enc); - break; - } - } - return XML_TOK_PARTIAL; -} - -#endif /* XML_DTD */ - -static int PTRCALL -PREFIX(isPublicId)(const ENCODING *enc, const char *ptr, const char *end, - const char **badPtr) -{ - ptr += MINBPC(enc); - end -= MINBPC(enc); - for (; ptr != end; ptr += MINBPC(enc)) { - switch (BYTE_TYPE(enc, ptr)) { - case BT_DIGIT: - case BT_HEX: - case BT_MINUS: - case BT_APOS: - case BT_LPAR: - case BT_RPAR: - case BT_PLUS: - case BT_COMMA: - case BT_SOL: - case BT_EQUALS: - case BT_QUEST: - case BT_CR: - case BT_LF: - case BT_SEMI: - case BT_EXCL: - case BT_AST: - case BT_PERCNT: - case BT_NUM: -#ifdef XML_NS - case BT_COLON: -#endif - break; - case BT_S: - if (CHAR_MATCHES(enc, ptr, ASCII_TAB)) { - *badPtr = ptr; - return 0; - } - break; - case BT_NAME: - case BT_NMSTRT: - if (!(BYTE_TO_ASCII(enc, ptr) & ~0x7f)) - break; - default: - switch (BYTE_TO_ASCII(enc, ptr)) { - case 0x24: /* $ */ - case 0x40: /* @ */ - break; - default: - *badPtr = ptr; - return 0; - } - break; - } - } - return 1; -} - -/* This must only be called for a well-formed start-tag or empty - element tag. Returns the number of attributes. Pointers to the - first attsMax attributes are stored in atts. -*/ - -static int PTRCALL -PREFIX(getAtts)(const ENCODING *enc, const char *ptr, - int attsMax, ATTRIBUTE *atts) -{ - enum { other, inName, inValue } state = inName; - int nAtts = 0; - int open = 0; /* defined when state == inValue; - initialization just to shut up compilers */ - - for (ptr += MINBPC(enc);; ptr += MINBPC(enc)) { - switch (BYTE_TYPE(enc, ptr)) { -#define START_NAME \ - if (state == other) { \ - if (nAtts < attsMax) { \ - atts[nAtts].name = ptr; \ - atts[nAtts].normalized = 1; \ - } \ - state = inName; \ - } -#define LEAD_CASE(n) \ - case BT_LEAD ## n: START_NAME ptr += (n - MINBPC(enc)); break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_NONASCII: - case BT_NMSTRT: - case BT_HEX: - START_NAME - break; -#undef START_NAME - case BT_QUOT: - if (state != inValue) { - if (nAtts < attsMax) - atts[nAtts].valuePtr = ptr + MINBPC(enc); - state = inValue; - open = BT_QUOT; - } - else if (open == BT_QUOT) { - state = other; - if (nAtts < attsMax) - atts[nAtts].valueEnd = ptr; - nAtts++; - } - break; - case BT_APOS: - if (state != inValue) { - if (nAtts < attsMax) - atts[nAtts].valuePtr = ptr + MINBPC(enc); - state = inValue; - open = BT_APOS; - } - else if (open == BT_APOS) { - state = other; - if (nAtts < attsMax) - atts[nAtts].valueEnd = ptr; - nAtts++; - } - break; - case BT_AMP: - if (nAtts < attsMax) - atts[nAtts].normalized = 0; - break; - case BT_S: - if (state == inName) - state = other; - else if (state == inValue - && nAtts < attsMax - && atts[nAtts].normalized - && (ptr == atts[nAtts].valuePtr - || BYTE_TO_ASCII(enc, ptr) != ASCII_SPACE - || BYTE_TO_ASCII(enc, ptr + MINBPC(enc)) == ASCII_SPACE - || BYTE_TYPE(enc, ptr + MINBPC(enc)) == open)) - atts[nAtts].normalized = 0; - break; - case BT_CR: case BT_LF: - /* This case ensures that the first attribute name is counted - Apart from that we could just change state on the quote. */ - if (state == inName) - state = other; - else if (state == inValue && nAtts < attsMax) - atts[nAtts].normalized = 0; - break; - case BT_GT: - case BT_SOL: - if (state != inValue) - return nAtts; - break; - default: - break; - } - } - /* not reached */ -} - -static int PTRFASTCALL -PREFIX(charRefNumber)(const ENCODING *enc, const char *ptr) -{ - int result = 0; - /* skip &# */ - ptr += 2*MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_x)) { - for (ptr += MINBPC(enc); - !CHAR_MATCHES(enc, ptr, ASCII_SEMI); - ptr += MINBPC(enc)) { - int c = BYTE_TO_ASCII(enc, ptr); - switch (c) { - case ASCII_0: case ASCII_1: case ASCII_2: case ASCII_3: case ASCII_4: - case ASCII_5: case ASCII_6: case ASCII_7: case ASCII_8: case ASCII_9: - result <<= 4; - result |= (c - ASCII_0); - break; - case ASCII_A: case ASCII_B: case ASCII_C: - case ASCII_D: case ASCII_E: case ASCII_F: - result <<= 4; - result += 10 + (c - ASCII_A); - break; - case ASCII_a: case ASCII_b: case ASCII_c: - case ASCII_d: case ASCII_e: case ASCII_f: - result <<= 4; - result += 10 + (c - ASCII_a); - break; - } - if (result >= 0x110000) - return -1; - } - } - else { - for (; !CHAR_MATCHES(enc, ptr, ASCII_SEMI); ptr += MINBPC(enc)) { - int c = BYTE_TO_ASCII(enc, ptr); - result *= 10; - result += (c - ASCII_0); - if (result >= 0x110000) - return -1; - } - } - return checkCharRefNumber(result); -} - -static int PTRCALL -PREFIX(predefinedEntityName)(const ENCODING *enc, const char *ptr, - const char *end) -{ - switch ((end - ptr)/MINBPC(enc)) { - case 2: - if (CHAR_MATCHES(enc, ptr + MINBPC(enc), ASCII_t)) { - switch (BYTE_TO_ASCII(enc, ptr)) { - case ASCII_l: - return ASCII_LT; - case ASCII_g: - return ASCII_GT; - } - } - break; - case 3: - if (CHAR_MATCHES(enc, ptr, ASCII_a)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_m)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_p)) - return ASCII_AMP; - } - } - break; - case 4: - switch (BYTE_TO_ASCII(enc, ptr)) { - case ASCII_q: - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_u)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_o)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_t)) - return ASCII_QUOT; - } - } - break; - case ASCII_a: - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_p)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_o)) { - ptr += MINBPC(enc); - if (CHAR_MATCHES(enc, ptr, ASCII_s)) - return ASCII_APOS; - } - } - break; - } - } - return 0; -} - -static int PTRCALL -PREFIX(sameName)(const ENCODING *enc, const char *ptr1, const char *ptr2) -{ - for (;;) { - switch (BYTE_TYPE(enc, ptr1)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: \ - if (*ptr1++ != *ptr2++) \ - return 0; - LEAD_CASE(4) LEAD_CASE(3) LEAD_CASE(2) -#undef LEAD_CASE - /* fall through */ - if (*ptr1++ != *ptr2++) - return 0; - break; - case BT_NONASCII: - case BT_NMSTRT: -#ifdef XML_NS - case BT_COLON: -#endif - case BT_HEX: - case BT_DIGIT: - case BT_NAME: - case BT_MINUS: - if (*ptr2++ != *ptr1++) - return 0; - if (MINBPC(enc) > 1) { - if (*ptr2++ != *ptr1++) - return 0; - if (MINBPC(enc) > 2) { - if (*ptr2++ != *ptr1++) - return 0; - if (MINBPC(enc) > 3) { - if (*ptr2++ != *ptr1++) - return 0; - } - } - } - break; - default: - if (MINBPC(enc) == 1 && *ptr1 == *ptr2) - return 1; - switch (BYTE_TYPE(enc, ptr2)) { - case BT_LEAD2: - case BT_LEAD3: - case BT_LEAD4: - case BT_NONASCII: - case BT_NMSTRT: -#ifdef XML_NS - case BT_COLON: -#endif - case BT_HEX: - case BT_DIGIT: - case BT_NAME: - case BT_MINUS: - return 0; - default: - return 1; - } - } - } - /* not reached */ -} - -static int PTRCALL -PREFIX(nameMatchesAscii)(const ENCODING *enc, const char *ptr1, - const char *end1, const char *ptr2) -{ - for (; *ptr2; ptr1 += MINBPC(enc), ptr2++) { - if (ptr1 == end1) - return 0; - if (!CHAR_MATCHES(enc, ptr1, *ptr2)) - return 0; - } - return ptr1 == end1; -} - -static int PTRFASTCALL -PREFIX(nameLength)(const ENCODING *enc, const char *ptr) -{ - const char *start = ptr; - for (;;) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: ptr += n; break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_NONASCII: - case BT_NMSTRT: -#ifdef XML_NS - case BT_COLON: -#endif - case BT_HEX: - case BT_DIGIT: - case BT_NAME: - case BT_MINUS: - ptr += MINBPC(enc); - break; - default: - return (int)(ptr - start); - } - } -} - -static const char * PTRFASTCALL -PREFIX(skipS)(const ENCODING *enc, const char *ptr) -{ - for (;;) { - switch (BYTE_TYPE(enc, ptr)) { - case BT_LF: - case BT_CR: - case BT_S: - ptr += MINBPC(enc); - break; - default: - return ptr; - } - } -} - -static void PTRCALL -PREFIX(updatePosition)(const ENCODING *enc, - const char *ptr, - const char *end, - POSITION *pos) -{ - while (ptr < end) { - switch (BYTE_TYPE(enc, ptr)) { -#define LEAD_CASE(n) \ - case BT_LEAD ## n: \ - ptr += n; \ - break; - LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4) -#undef LEAD_CASE - case BT_LF: - pos->columnNumber = (XML_Size)-1; - pos->lineNumber++; - ptr += MINBPC(enc); - break; - case BT_CR: - pos->lineNumber++; - ptr += MINBPC(enc); - if (ptr != end && BYTE_TYPE(enc, ptr) == BT_LF) - ptr += MINBPC(enc); - pos->columnNumber = (XML_Size)-1; - break; - default: - ptr += MINBPC(enc); - break; - } - pos->columnNumber++; - } -} - -#undef DO_LEAD_CASE -#undef MULTIBYTE_CASES -#undef INVALID_CASES -#undef CHECK_NAME_CASE -#undef CHECK_NAME_CASES -#undef CHECK_NMSTRT_CASE -#undef CHECK_NMSTRT_CASES - -#endif /* XML_TOK_IMPL_C */ diff --git a/lib-src/expat/lib/xmltok_impl.h b/lib-src/expat/lib/xmltok_impl.h deleted file mode 100644 index da0ea60a6..000000000 --- a/lib-src/expat/lib/xmltok_impl.h +++ /dev/null @@ -1,46 +0,0 @@ -/* -Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd -See the file COPYING for copying permission. -*/ - -enum { - BT_NONXML, - BT_MALFORM, - BT_LT, - BT_AMP, - BT_RSQB, - BT_LEAD2, - BT_LEAD3, - BT_LEAD4, - BT_TRAIL, - BT_CR, - BT_LF, - BT_GT, - BT_QUOT, - BT_APOS, - BT_EQUALS, - BT_QUEST, - BT_EXCL, - BT_SOL, - BT_SEMI, - BT_NUM, - BT_LSQB, - BT_S, - BT_NMSTRT, - BT_COLON, - BT_HEX, - BT_DIGIT, - BT_NAME, - BT_MINUS, - BT_OTHER, /* known not to be a name or name start character */ - BT_NONASCII, /* might be a name or name start character */ - BT_PERCNT, - BT_LPAR, - BT_RPAR, - BT_AST, - BT_PLUS, - BT_COMMA, - BT_VERBAR -}; - -#include diff --git a/lib-src/expat/lib/xmltok_ns.c b/lib-src/expat/lib/xmltok_ns.c deleted file mode 100644 index c3b88fdf4..000000000 --- a/lib-src/expat/lib/xmltok_ns.c +++ /dev/null @@ -1,115 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -/* This file is included! */ -#ifdef XML_TOK_NS_C - -const ENCODING * -NS(XmlGetUtf8InternalEncoding)(void) -{ - return &ns(internal_utf8_encoding).enc; -} - -const ENCODING * -NS(XmlGetUtf16InternalEncoding)(void) -{ -#if BYTEORDER == 1234 - return &ns(internal_little2_encoding).enc; -#elif BYTEORDER == 4321 - return &ns(internal_big2_encoding).enc; -#else - const short n = 1; - return (*(const char *)&n - ? &ns(internal_little2_encoding).enc - : &ns(internal_big2_encoding).enc); -#endif -} - -static const ENCODING * const NS(encodings)[] = { - &ns(latin1_encoding).enc, - &ns(ascii_encoding).enc, - &ns(utf8_encoding).enc, - &ns(big2_encoding).enc, - &ns(big2_encoding).enc, - &ns(little2_encoding).enc, - &ns(utf8_encoding).enc /* NO_ENC */ -}; - -static int PTRCALL -NS(initScanProlog)(const ENCODING *enc, const char *ptr, const char *end, - const char **nextTokPtr) -{ - return initScan(NS(encodings), (const INIT_ENCODING *)enc, - XML_PROLOG_STATE, ptr, end, nextTokPtr); -} - -static int PTRCALL -NS(initScanContent)(const ENCODING *enc, const char *ptr, const char *end, - const char **nextTokPtr) -{ - return initScan(NS(encodings), (const INIT_ENCODING *)enc, - XML_CONTENT_STATE, ptr, end, nextTokPtr); -} - -int -NS(XmlInitEncoding)(INIT_ENCODING *p, const ENCODING **encPtr, - const char *name) -{ - int i = getEncodingIndex(name); - if (i == UNKNOWN_ENC) - return 0; - SET_INIT_ENC_INDEX(p, i); - p->initEnc.scanners[XML_PROLOG_STATE] = NS(initScanProlog); - p->initEnc.scanners[XML_CONTENT_STATE] = NS(initScanContent); - p->initEnc.updatePosition = initUpdatePosition; - p->encPtr = encPtr; - *encPtr = &(p->initEnc); - return 1; -} - -static const ENCODING * -NS(findEncoding)(const ENCODING *enc, const char *ptr, const char *end) -{ -#define ENCODING_MAX 128 - char buf[ENCODING_MAX]; - char *p = buf; - int i; - XmlUtf8Convert(enc, &ptr, end, &p, p + ENCODING_MAX - 1); - if (ptr != end) - return 0; - *p = 0; - if (streqci(buf, KW_UTF_16) && enc->minBytesPerChar == 2) - return enc; - i = getEncodingIndex(buf); - if (i == UNKNOWN_ENC) - return 0; - return NS(encodings)[i]; -} - -int -NS(XmlParseXmlDecl)(int isGeneralTextEntity, - const ENCODING *enc, - const char *ptr, - const char *end, - const char **badPtr, - const char **versionPtr, - const char **versionEndPtr, - const char **encodingName, - const ENCODING **encoding, - int *standalone) -{ - return doParseXmlDecl(NS(findEncoding), - isGeneralTextEntity, - enc, - ptr, - end, - badPtr, - versionPtr, - versionEndPtr, - encodingName, - encoding, - standalone); -} - -#endif /* XML_TOK_NS_C */ diff --git a/lib-src/expat/m4/libtool.m4 b/lib-src/expat/m4/libtool.m4 deleted file mode 100644 index d7c043f4f..000000000 --- a/lib-src/expat/m4/libtool.m4 +++ /dev/null @@ -1,7997 +0,0 @@ -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -m4_define([_LT_COPYING], [dnl -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -]) - -# serial 57 LT_INIT - - -# LT_PREREQ(VERSION) -# ------------------ -# Complain and exit if this libtool version is less that VERSION. -m4_defun([LT_PREREQ], -[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, - [m4_default([$3], - [m4_fatal([Libtool version $1 or higher is required], - 63)])], - [$2])]) - - -# _LT_CHECK_BUILDDIR -# ------------------ -# Complain if the absolute build directory name contains unusual characters -m4_defun([_LT_CHECK_BUILDDIR], -[case `pwd` in - *\ * | *\ *) - AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; -esac -]) - - -# LT_INIT([OPTIONS]) -# ------------------ -AC_DEFUN([LT_INIT], -[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT -AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl -AC_BEFORE([$0], [LT_LANG])dnl -AC_BEFORE([$0], [LT_OUTPUT])dnl -AC_BEFORE([$0], [LTDL_INIT])dnl -m4_require([_LT_CHECK_BUILDDIR])dnl - -dnl Autoconf doesn't catch unexpanded LT_ macros by default: -m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl -m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl -dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 -dnl unless we require an AC_DEFUNed macro: -AC_REQUIRE([LTOPTIONS_VERSION])dnl -AC_REQUIRE([LTSUGAR_VERSION])dnl -AC_REQUIRE([LTVERSION_VERSION])dnl -AC_REQUIRE([LTOBSOLETE_VERSION])dnl -m4_require([_LT_PROG_LTMAIN])dnl - -_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) - -dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -_LT_SETUP - -# Only expand once: -m4_define([LT_INIT]) -])# LT_INIT - -# Old names: -AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) -AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PROG_LIBTOOL], []) -dnl AC_DEFUN([AM_PROG_LIBTOOL], []) - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -m4_defun([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` -]) - - -# _LT_FILEUTILS_DEFAULTS -# ---------------------- -# It is okay to use these file commands and assume they have been set -# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. -m4_defun([_LT_FILEUTILS_DEFAULTS], -[: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} -])# _LT_FILEUTILS_DEFAULTS - - -# _LT_SETUP -# --------- -m4_defun([_LT_SETUP], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl - -_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl -dnl -_LT_DECL([], [host_alias], [0], [The host system])dnl -_LT_DECL([], [host], [0])dnl -_LT_DECL([], [host_os], [0])dnl -dnl -_LT_DECL([], [build_alias], [0], [The build system])dnl -_LT_DECL([], [build], [0])dnl -_LT_DECL([], [build_os], [0])dnl -dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -dnl -AC_REQUIRE([AC_PROG_LN_S])dnl -test -z "$LN_S" && LN_S="ln -s" -_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl -dnl -AC_REQUIRE([LT_CMD_MAX_LEN])dnl -_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl -_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl -dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl -m4_require([_LT_CMD_RELOAD])dnl -m4_require([_LT_CHECK_MAGIC_METHOD])dnl -m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl -m4_require([_LT_CMD_OLD_ARCHIVE])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_WITH_SYSROOT])dnl - -_LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi -]) -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - -_LT_CHECK_OBJDIR - -m4_require([_LT_TAG_COMPILER])dnl - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - _LT_PATH_MAGIC - fi - ;; -esac - -# Use C for the default configuration in the libtool script -LT_SUPPORTED_TAG([CC]) -_LT_LANG_C_CONFIG -_LT_LANG_DEFAULT_CONFIG -_LT_CONFIG_COMMANDS -])# _LT_SETUP - - -# _LT_PREPARE_SED_QUOTE_VARS -# -------------------------- -# Define a few sed substitution that help us do robust quoting. -m4_defun([_LT_PREPARE_SED_QUOTE_VARS], -[# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([["`\\]]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' -]) - -# _LT_PROG_LTMAIN -# --------------- -# Note that this code is called both from `configure', and `config.status' -# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# `config.status' has no value for ac_aux_dir unless we are using Automake, -# so we pass a copy along to make sure it has a sensible value anyway. -m4_defun([_LT_PROG_LTMAIN], -[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl -_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain="$ac_aux_dir/ltmain.sh" -])# _LT_PROG_LTMAIN - - -## ------------------------------------- ## -## Accumulate code for creating libtool. ## -## ------------------------------------- ## - -# So that we can recreate a full libtool script including additional -# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the `libtool' -# label. - - -# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) -# ---------------------------------------- -# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL_INIT], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_INIT], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_INIT]) - - -# _LT_CONFIG_LIBTOOL([COMMANDS]) -# ------------------------------ -# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) - - -# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) -# ----------------------------------------------------- -m4_defun([_LT_CONFIG_SAVE_COMMANDS], -[_LT_CONFIG_LIBTOOL([$1]) -_LT_CONFIG_LIBTOOL_INIT([$2]) -]) - - -# _LT_FORMAT_COMMENT([COMMENT]) -# ----------------------------- -# Add leading comment marks to the start of each line, and a trailing -# full-stop to the whole comment if one is not present already. -m4_define([_LT_FORMAT_COMMENT], -[m4_ifval([$1], [ -m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], - [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) -)]) - - - -## ------------------------ ## -## FIXME: Eliminate VARNAME ## -## ------------------------ ## - - -# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) -# ------------------------------------------------------------------- -# CONFIGNAME is the name given to the value in the libtool script. -# VARNAME is the (base) name used in the configure script. -# VALUE may be 0, 1 or 2 for a computed quote escaped value based on -# VARNAME. Any other value will be used directly. -m4_define([_LT_DECL], -[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], - [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], - [m4_ifval([$1], [$1], [$2])]) - lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) - m4_ifval([$4], - [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) - lt_dict_add_subkey([lt_decl_dict], [$2], - [tagged?], [m4_ifval([$5], [yes], [no])])]) -]) - - -# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) -# -------------------------------------------------------- -m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) - - -# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_tag_varnames], -[_lt_decl_filter([tagged?], [yes], $@)]) - - -# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) -# --------------------------------------------------------- -m4_define([_lt_decl_filter], -[m4_case([$#], - [0], [m4_fatal([$0: too few arguments: $#])], - [1], [m4_fatal([$0: too few arguments: $#: $1])], - [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], - [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], - [lt_dict_filter([lt_decl_dict], $@)])[]dnl -]) - - -# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) -# -------------------------------------------------- -m4_define([lt_decl_quote_varnames], -[_lt_decl_filter([value], [1], $@)]) - - -# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_dquote_varnames], -[_lt_decl_filter([value], [2], $@)]) - - -# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_varnames_tagged], -[m4_assert([$# <= 2])dnl -_$0(m4_quote(m4_default([$1], [[, ]])), - m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), - m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) -m4_define([_lt_decl_varnames_tagged], -[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) - - -# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_all_varnames], -[_$0(m4_quote(m4_default([$1], [[, ]])), - m4_if([$2], [], - m4_quote(lt_decl_varnames), - m4_quote(m4_shift($@))))[]dnl -]) -m4_define([_lt_decl_all_varnames], -[lt_join($@, lt_decl_varnames_tagged([$1], - lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl -]) - - -# _LT_CONFIG_STATUS_DECLARE([VARNAME]) -# ------------------------------------ -# Quote a variable value, and forward it to `config.status' so that its -# declaration there will have the same value as in `configure'. VARNAME -# must have a single quote delimited value for this to work. -m4_define([_LT_CONFIG_STATUS_DECLARE], -[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) - - -# _LT_CONFIG_STATUS_DECLARATIONS -# ------------------------------ -# We delimit libtool config variables with single quotes, so when -# we write them to config.status, we have to be sure to quote all -# embedded single quotes properly. In configure, this macro expands -# each variable declared with _LT_DECL (and _LT_TAGDECL) into: -# -# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' -m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], -[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), - [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAGS -# ---------------- -# Output comment and list of tags supported by the script -m4_defun([_LT_LIBTOOL_TAGS], -[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags="_LT_TAGS"dnl -]) - - -# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) -# ----------------------------------- -# Extract the dictionary values for VARNAME (optionally with TAG) and -# expand to a commented shell variable setting: -# -# # Some comment about what VAR is for. -# visible_name=$lt_internal_name -m4_define([_LT_LIBTOOL_DECLARE], -[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], - [description])))[]dnl -m4_pushdef([_libtool_name], - m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl -m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), - [0], [_libtool_name=[$]$1], - [1], [_libtool_name=$lt_[]$1], - [2], [_libtool_name=$lt_[]$1], - [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl -m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl -]) - - -# _LT_LIBTOOL_CONFIG_VARS -# ----------------------- -# Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' -# script. Tagged libtool config variables (even for the LIBTOOL CONFIG -# section) are produced by _LT_LIBTOOL_TAG_VARS. -m4_defun([_LT_LIBTOOL_CONFIG_VARS], -[m4_foreach([_lt_var], - m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAG_VARS(TAG) -# ------------------------- -m4_define([_LT_LIBTOOL_TAG_VARS], -[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) - - -# _LT_TAGVAR(VARNAME, [TAGNAME]) -# ------------------------------ -m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) - - -# _LT_CONFIG_COMMANDS -# ------------------- -# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of -# variables for single and double quote escaping we saved from calls -# to _LT_DECL, we can put quote escaped variables declarations -# into `config.status', and then the shell code to quote escape them in -# for loops in `config.status'. Finally, any additional code accumulated -# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. -m4_defun([_LT_CONFIG_COMMANDS], -[AC_PROVIDE_IFELSE([LT_OUTPUT], - dnl If the libtool generation code has been placed in $CONFIG_LT, - dnl instead of duplicating it all over again into config.status, - dnl then we will have config.status run $CONFIG_LT later, so it - dnl needs to know what name is stored there: - [AC_CONFIG_COMMANDS([libtool], - [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], - dnl If the libtool generation code is destined for config.status, - dnl expand the accumulated commands and init code now: - [AC_CONFIG_COMMANDS([libtool], - [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) -])#_LT_CONFIG_COMMANDS - - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], -[ - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -_LT_CONFIG_STATUS_DECLARATIONS -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$[]1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_quote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_dquote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -_LT_OUTPUT_LIBTOOL_INIT -]) - -# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) -# ------------------------------------ -# Generate a child script FILE with all initialization necessary to -# reuse the environment learned by the parent script, and make the -# file executable. If COMMENT is supplied, it is inserted after the -# `#!' sequence but before initialization text begins. After this -# macro, additional text can be appended to FILE to form the body of -# the child script. The macro ends with non-zero status if the -# file could not be fully written (such as if the disk is full). -m4_ifdef([AS_INIT_GENERATED], -[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], -[m4_defun([_LT_GENERATED_FILE_INIT], -[m4_require([AS_PREPARE])]dnl -[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl -[lt_write_fail=0 -cat >$1 <<_ASEOF || lt_write_fail=1 -#! $SHELL -# Generated by $as_me. -$2 -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$1 <<\_ASEOF || lt_write_fail=1 -AS_SHELL_SANITIZE -_AS_PREPARE -exec AS_MESSAGE_FD>&1 -_ASEOF -test $lt_write_fail = 0 && chmod +x $1[]dnl -m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT - -# LT_OUTPUT -# --------- -# This macro allows early generation of the libtool script (before -# AC_OUTPUT is called), incase it is used in configure for compilation -# tests. -AC_DEFUN([LT_OUTPUT], -[: ${CONFIG_LT=./config.lt} -AC_MSG_NOTICE([creating $CONFIG_LT]) -_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], -[# Run this file to recreate a libtool stub with the current configuration.]) - -cat >>"$CONFIG_LT" <<\_LTEOF -lt_cl_silent=false -exec AS_MESSAGE_LOG_FD>>config.log -{ - echo - AS_BOX([Running $as_me.]) -} >&AS_MESSAGE_LOG_FD - -lt_cl_help="\ -\`$as_me' creates a local libtool stub from the current configuration, -for use in further configure time tests before the real libtool is -generated. - -Usage: $[0] [[OPTIONS]] - - -h, --help print this help, then exit - -V, --version print version number, then exit - -q, --quiet do not print progress messages - -d, --debug don't remove temporary files - -Report bugs to ." - -lt_cl_version="\ -m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl -m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) -configured by $[0], generated by m4_PACKAGE_STRING. - -Copyright (C) 2011 Free Software Foundation, Inc. -This config.lt script is free software; the Free Software Foundation -gives unlimited permision to copy, distribute and modify it." - -while test $[#] != 0 -do - case $[1] in - --version | --v* | -V ) - echo "$lt_cl_version"; exit 0 ;; - --help | --h* | -h ) - echo "$lt_cl_help"; exit 0 ;; - --debug | --d* | -d ) - debug=: ;; - --quiet | --q* | --silent | --s* | -q ) - lt_cl_silent=: ;; - - -*) AC_MSG_ERROR([unrecognized option: $[1] -Try \`$[0] --help' for more information.]) ;; - - *) AC_MSG_ERROR([unrecognized argument: $[1] -Try \`$[0] --help' for more information.]) ;; - esac - shift -done - -if $lt_cl_silent; then - exec AS_MESSAGE_FD>/dev/null -fi -_LTEOF - -cat >>"$CONFIG_LT" <<_LTEOF -_LT_OUTPUT_LIBTOOL_COMMANDS_INIT -_LTEOF - -cat >>"$CONFIG_LT" <<\_LTEOF -AC_MSG_NOTICE([creating $ofile]) -_LT_OUTPUT_LIBTOOL_COMMANDS -AS_EXIT(0) -_LTEOF -chmod +x "$CONFIG_LT" - -# configure is writing to config.log, but config.lt does its own redirection, -# appending to config.log, which fails on DOS, as config.log is still kept -# open by configure. Here we exec the FD to /dev/null, effectively closing -# config.log, so it can be properly (re)opened and appended to by config.lt. -lt_cl_success=: -test "$silent" = yes && - lt_config_lt_args="$lt_config_lt_args --quiet" -exec AS_MESSAGE_LOG_FD>/dev/null -$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false -exec AS_MESSAGE_LOG_FD>>config.log -$lt_cl_success || AS_EXIT(1) -])# LT_OUTPUT - - -# _LT_CONFIG(TAG) -# --------------- -# If TAG is the built-in tag, create an initial libtool script with a -# default configuration from the untagged config vars. Otherwise add code -# to config.status for appending the configuration named by TAG from the -# matching tagged config vars. -m4_defun([_LT_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_CONFIG_SAVE_COMMANDS([ - m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl - m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -_LT_COPYING -_LT_LIBTOOL_TAGS - -# ### BEGIN LIBTOOL CONFIG -_LT_LIBTOOL_CONFIG_VARS -_LT_LIBTOOL_TAG_VARS -# ### END LIBTOOL CONFIG - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - _LT_PROG_LTMAIN - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - _LT_PROG_REPLACE_SHELLFNS - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -], -[cat <<_LT_EOF >> "$ofile" - -dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded -dnl in a comment (ie after a #). -# ### BEGIN LIBTOOL TAG CONFIG: $1 -_LT_LIBTOOL_TAG_VARS(_LT_TAG) -# ### END LIBTOOL TAG CONFIG: $1 -_LT_EOF -])dnl /m4_if -], -[m4_if([$1], [], [ - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile'], []) -])dnl /_LT_CONFIG_SAVE_COMMANDS -])# _LT_CONFIG - - -# LT_SUPPORTED_TAG(TAG) -# --------------------- -# Trace this macro to discover what tags are supported by the libtool -# --tag option, using: -# autoconf --trace 'LT_SUPPORTED_TAG:$1' -AC_DEFUN([LT_SUPPORTED_TAG], []) - - -# C support is built-in for now -m4_define([_LT_LANG_C_enabled], []) -m4_define([_LT_TAGS], []) - - -# LT_LANG(LANG) -# ------------- -# Enable libtool support for the given language if not already enabled. -AC_DEFUN([LT_LANG], -[AC_BEFORE([$0], [LT_OUTPUT])dnl -m4_case([$1], - [C], [_LT_LANG(C)], - [C++], [_LT_LANG(CXX)], - [Go], [_LT_LANG(GO)], - [Java], [_LT_LANG(GCJ)], - [Fortran 77], [_LT_LANG(F77)], - [Fortran], [_LT_LANG(FC)], - [Windows Resource], [_LT_LANG(RC)], - [m4_ifdef([_LT_LANG_]$1[_CONFIG], - [_LT_LANG($1)], - [m4_fatal([$0: unsupported language: "$1"])])])dnl -])# LT_LANG - - -# _LT_LANG(LANGNAME) -# ------------------ -m4_defun([_LT_LANG], -[m4_ifdef([_LT_LANG_]$1[_enabled], [], - [LT_SUPPORTED_TAG([$1])dnl - m4_append([_LT_TAGS], [$1 ])dnl - m4_define([_LT_LANG_]$1[_enabled], [])dnl - _LT_LANG_$1_CONFIG($1)])dnl -])# _LT_LANG - - -m4_ifndef([AC_PROG_GO], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_GO. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ -m4_defun([AC_PROG_GO], -[AC_LANG_PUSH(Go)dnl -AC_ARG_VAR([GOC], [Go compiler command])dnl -AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl -_AC_ARG_VAR_LDFLAGS()dnl -AC_CHECK_TOOL(GOC, gccgo) -if test -z "$GOC"; then - if test -n "$ac_tool_prefix"; then - AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) - fi -fi -if test -z "$GOC"; then - AC_CHECK_PROG(GOC, gccgo, gccgo, false) -fi -])#m4_defun -])#m4_ifndef - - -# _LT_LANG_DEFAULT_CONFIG -# ----------------------- -m4_defun([_LT_LANG_DEFAULT_CONFIG], -[AC_PROVIDE_IFELSE([AC_PROG_CXX], - [LT_LANG(CXX)], - [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) - -AC_PROVIDE_IFELSE([AC_PROG_F77], - [LT_LANG(F77)], - [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) - -AC_PROVIDE_IFELSE([AC_PROG_FC], - [LT_LANG(FC)], - [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) - -dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal -dnl pulling things in needlessly. -AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([LT_PROG_GCJ], - [LT_LANG(GCJ)], - [m4_ifdef([AC_PROG_GCJ], - [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([A][M_PROG_GCJ], - [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([LT_PROG_GCJ], - [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) - -AC_PROVIDE_IFELSE([AC_PROG_GO], - [LT_LANG(GO)], - [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) - -AC_PROVIDE_IFELSE([LT_PROG_RC], - [LT_LANG(RC)], - [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) -])# _LT_LANG_DEFAULT_CONFIG - -# Obsolete macros: -AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) -AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) -AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) -AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) -AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_CXX], []) -dnl AC_DEFUN([AC_LIBTOOL_F77], []) -dnl AC_DEFUN([AC_LIBTOOL_FC], []) -dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) -dnl AC_DEFUN([AC_LIBTOOL_RC], []) - - -# _LT_TAG_COMPILER -# ---------------- -m4_defun([_LT_TAG_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl -_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl -_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl -_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_TAG_COMPILER - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -m4_defun([_LT_COMPILER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -m4_defun([_LT_LINKER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* -])# _LT_LINKER_BOILERPLATE - -# _LT_REQUIRED_DARWIN_CHECKS -# ------------------------- -m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ - case $host_os in - rhapsody* | darwin*) - AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) - AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) - AC_CHECK_TOOL([LIPO], [lipo], [:]) - AC_CHECK_TOOL([OTOOL], [otool], [:]) - AC_CHECK_TOOL([OTOOL64], [otool64], [:]) - _LT_DECL([], [DSYMUTIL], [1], - [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) - _LT_DECL([], [NMEDIT], [1], - [Tool to change global to local symbols on Mac OS X]) - _LT_DECL([], [LIPO], [1], - [Tool to manipulate fat objects and archives on Mac OS X]) - _LT_DECL([], [OTOOL], [1], - [ldd/readelf like tool for Mach-O binaries on Mac OS X]) - _LT_DECL([], [OTOOL64], [1], - [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) - - AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], - [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi]) - - AC_CACHE_CHECK([for -exported_symbols_list linker flag], - [lt_cv_ld_exported_symbols_list], - [lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [lt_cv_ld_exported_symbols_list=yes], - [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" - ]) - - AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], - [lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD - echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD - $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - ]) - case $host_os in - rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac -]) - - -# _LT_DARWIN_LINKER_FEATURES([TAG]) -# --------------------------------- -# Checks for linker and compiler features on darwin -m4_defun([_LT_DARWIN_LINKER_FEATURES], -[ - m4_require([_LT_REQUIRED_DARWIN_CHECKS]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_automatic, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - _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\"`' - m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], - [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='' - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - _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}" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _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}" - _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}" - m4_if([$1], [CXX], -[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _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}" - _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}" - fi -],[]) - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi -]) - -# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) -# ---------------------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -# Store the results from the different compilers for each TAGNAME. -# Allow to override them for all tags through lt_cv_aix_libpath. -m4_defun([_LT_SYS_MODULE_PATH_AIX], -[m4_require([_LT_DECL_SED])dnl -if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], - [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ - lt_aix_libpath_sed='[ - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }]' - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi],[]) - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" - fi - ]) - aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) -fi -])# _LT_SYS_MODULE_PATH_AIX - - -# _LT_SHELL_INIT(ARG) -# ------------------- -m4_define([_LT_SHELL_INIT], -[m4_divert_text([M4SH-INIT], [$1 -])])# _LT_SHELL_INIT - - - -# _LT_PROG_ECHO_BACKSLASH -# ----------------------- -# Find how we can fake an echo command that does not interpret backslash. -# In particular, with Autoconf 2.60 or later we add some code to the start -# of the generated configure script which will find a shell with a builtin -# printf (which we can use as an echo command). -m4_defun([_LT_PROG_ECHO_BACKSLASH], -[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -AC_MSG_CHECKING([how to print strings]) -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$[]1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -case "$ECHO" in - printf*) AC_MSG_RESULT([printf]) ;; - print*) AC_MSG_RESULT([print -r]) ;; - *) AC_MSG_RESULT([cat]) ;; -esac - -m4_ifdef([_AS_DETECT_SUGGESTED], -[_AS_DETECT_SUGGESTED([ - test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test "X`printf %s $ECHO`" = "X$ECHO" \ - || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) - -_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) -_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) -])# _LT_PROG_ECHO_BACKSLASH - - -# _LT_WITH_SYSROOT -# ---------------- -AC_DEFUN([_LT_WITH_SYSROOT], -[AC_MSG_CHECKING([for sysroot]) -AC_ARG_WITH([sysroot], -[ --with-sysroot[=DIR] Search for dependent libraries within DIR - (or the compiler's sysroot if not specified).], -[], [with_sysroot=no]) - -dnl lt_sysroot will always be passed unquoted. We quote it here -dnl in case the user passed a directory name. -lt_sysroot= -case ${with_sysroot} in #( - yes) - if test "$GCC" = yes; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - AC_MSG_RESULT([${with_sysroot}]) - AC_MSG_ERROR([The sysroot must be an absolute path.]) - ;; -esac - - AC_MSG_RESULT([${lt_sysroot:-no}]) -_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl -[dependent libraries, and in which our libraries should be installed.])]) - -# _LT_ENABLE_LOCK -# --------------- -m4_defun([_LT_ENABLE_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" -])# _LT_ENABLE_LOCK - - -# _LT_PROG_AR -# ----------- -m4_defun([_LT_PROG_AR], -[AC_CHECK_TOOLS(AR, [ar], false) -: ${AR=ar} -: ${AR_FLAGS=cru} -_LT_DECL([], [AR], [1], [The archiver]) -_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) - -AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], - [lt_cv_ar_at_file=no - AC_COMPILE_IFELSE([AC_LANG_PROGRAM], - [echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' - AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -eq 0; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -ne 0; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - ]) - ]) - -if test "x$lt_cv_ar_at_file" = xno; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi -_LT_DECL([], [archiver_list_spec], [1], - [How to feed a file listing to the archiver]) -])# _LT_PROG_AR - - -# _LT_CMD_OLD_ARCHIVE -# ------------------- -m4_defun([_LT_CMD_OLD_ARCHIVE], -[_LT_PROG_AR - -AC_CHECK_TOOL(STRIP, strip, :) -test -z "$STRIP" && STRIP=: -_LT_DECL([], [STRIP], [1], [A symbol stripping program]) - -AC_CHECK_TOOL(RANLIB, ranlib, :) -test -z "$RANLIB" && RANLIB=: -_LT_DECL([], [RANLIB], [1], - [Commands used to install an old-style archive]) - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac -_LT_DECL([], [old_postinstall_cmds], [2]) -_LT_DECL([], [old_postuninstall_cmds], [2]) -_LT_TAGDECL([], [old_archive_cmds], [2], - [Commands used to build an old-style archive]) -_LT_DECL([], [lock_old_archive_extraction], [0], - [Whether to use a lock for old archive extraction]) -])# _LT_CMD_OLD_ARCHIVE - - -# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([_LT_COMPILER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $RM conftest* -]) - -if test x"[$]$2" = xyes; then - m4_if([$5], , :, [$5]) -else - m4_if([$6], , :, [$6]) -fi -])# _LT_COMPILER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) - - -# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------- -# Check whether the given linker option works -AC_DEFUN([_LT_LINKER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - m4_if([$4], , :, [$4]) -else - m4_if([$5], , :, [$5]) -fi -])# _LT_LINKER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) - - -# LT_CMD_MAX_LEN -#--------------- -AC_DEFUN([LT_CMD_MAX_LEN], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -max_cmd_len=$lt_cv_sys_max_cmd_len -_LT_DECL([], [max_cmd_len], [0], - [What is the maximum length of a command?]) -])# LT_CMD_MAX_LEN - -# Old name: -AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) - - -# _LT_HEADER_DLFCN -# ---------------- -m4_defun([_LT_HEADER_DLFCN], -[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl -])# _LT_HEADER_DLFCN - - -# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ---------------------------------------------------------------- -m4_defun([_LT_TRY_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -[#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -}] -_LT_EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_dlunknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_TRY_DLOPEN_SELF - - -# LT_SYS_DLOPEN_SELF -# ------------------ -AC_DEFUN([LT_SYS_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -_LT_DECL([dlopen_support], [enable_dlopen], [0], - [Whether dlopen is supported]) -_LT_DECL([dlopen_self], [enable_dlopen_self], [0], - [Whether dlopen of programs is supported]) -_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], - [Whether dlopen of statically linked programs is supported]) -])# LT_SYS_DLOPEN_SELF - -# Old name: -AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) - - -# _LT_COMPILER_C_O([TAGNAME]) -# --------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler. -# This macro does not hard code the compiler like AC_PROG_CC_C_O. -m4_defun([_LT_COMPILER_C_O], -[m4_require([_LT_DECL_SED])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* -]) -_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], - [Does compiler simultaneously support -c and -o options?]) -])# _LT_COMPILER_C_O - - -# _LT_COMPILER_FILE_LOCKS([TAGNAME]) -# ---------------------------------- -# Check to see if we can do hard links to lock some files if needed -m4_defun([_LT_COMPILER_FILE_LOCKS], -[m4_require([_LT_ENABLE_LOCK])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_COMPILER_C_O([$1]) - -hard_links="nottested" -if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) -])# _LT_COMPILER_FILE_LOCKS - - -# _LT_CHECK_OBJDIR -# ---------------- -m4_defun([_LT_CHECK_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -_LT_DECL([], [objdir], [0], - [The name of the directory that contains temporary libtool files])dnl -m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", - [Define to the sub-directory in which libtool stores uninstalled libraries.]) -])# _LT_CHECK_OBJDIR - - -# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) -# -------------------------------------- -# Check hardcoding attributes. -m4_defun([_LT_LINKER_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || - test -n "$_LT_TAGVAR(runpath_var, $1)" || - test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) - -if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || - test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -_LT_TAGDECL([], [hardcode_action], [0], - [How to hardcode a shared library path into an executable]) -])# _LT_LINKER_HARDCODE_LIBPATH - - -# _LT_CMD_STRIPLIB -# ---------------- -m4_defun([_LT_CMD_STRIPLIB], -[m4_require([_LT_DECL_EGREP]) -striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) -_LT_DECL([], [striplib], [1]) -])# _LT_CMD_STRIPLIB - - -# _LT_SYS_DYNAMIC_LINKER([TAG]) -# ----------------------------- -# PORTME Fill in your ld.so characteristics -m4_defun([_LT_SYS_DYNAMIC_LINKER], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_OBJDUMP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -AC_MSG_CHECKING([dynamic linker characteristics]) -m4_if([$1], - [], [ -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[[lt_foo]]++; } - if (lt_freq[[lt_foo]] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[[4-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[23]].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ - freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[[3-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], - [lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ - LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], - [lt_cv_shlibpath_overrides_runpath=yes])]) - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - ]) - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - -_LT_DECL([], [variables_saved_for_relink], [1], - [Variables whose values should be saved in libtool wrapper scripts and - restored at link time]) -_LT_DECL([], [need_lib_prefix], [0], - [Do we need the "lib" prefix for modules?]) -_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) -_LT_DECL([], [version_type], [0], [Library versioning type]) -_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) -_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) -_LT_DECL([], [shlibpath_overrides_runpath], [0], - [Is shlibpath searched before the hard-coded library search path?]) -_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) -_LT_DECL([], [library_names_spec], [1], - [[List of archive names. First name is the real one, the rest are links. - The last name is the one that the linker finds with -lNAME]]) -_LT_DECL([], [soname_spec], [1], - [[The coded name of the library, if different from the real name]]) -_LT_DECL([], [install_override_mode], [1], - [Permission mode override for installation of shared libraries]) -_LT_DECL([], [postinstall_cmds], [2], - [Command to use after installation of a shared archive]) -_LT_DECL([], [postuninstall_cmds], [2], - [Command to use after uninstallation of a shared archive]) -_LT_DECL([], [finish_cmds], [2], - [Commands used to finish a libtool library installation in a directory]) -_LT_DECL([], [finish_eval], [1], - [[As "finish_cmds", except a single script fragment to be evaled but - not shown]]) -_LT_DECL([], [hardcode_into_libs], [0], - [Whether we should hardcode library paths into libraries]) -_LT_DECL([], [sys_lib_search_path_spec], [2], - [Compile-time system search path for libraries]) -_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], - [Run-time system search path for libraries]) -])# _LT_SYS_DYNAMIC_LINKER - - -# _LT_PATH_TOOL_PREFIX(TOOL) -# -------------------------- -# find a file program which can recognize shared library -AC_DEFUN([_LT_PATH_TOOL_PREFIX], -[m4_require([_LT_DECL_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="m4_if([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -_LT_DECL([], [MAGIC_CMD], [0], - [Used to examine libraries when file_magic_cmd begins with "file"])dnl -])# _LT_PATH_TOOL_PREFIX - -# Old name: -AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) - - -# _LT_PATH_MAGIC -# -------------- -# find a file program which can recognize a shared library -m4_defun([_LT_PATH_MAGIC], -[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# _LT_PATH_MAGIC - - -# LT_PATH_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([LT_PATH_LD], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PROG_ECHO_BACKSLASH])dnl - -AC_ARG_WITH([gnu-ld], - [AS_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no])dnl - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [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]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[[3-9]]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - 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]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - -_LT_DECL([], [deplibs_check_method], [1], - [Method to check whether dependent libraries are shared objects]) -_LT_DECL([], [file_magic_cmd], [1], - [Command to use when deplibs_check_method = "file_magic"]) -_LT_DECL([], [file_magic_glob], [1], - [How to find potential files when deplibs_check_method = "file_magic"]) -_LT_DECL([], [want_nocaseglob], [1], - [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) -])# _LT_CHECK_MAGIC_METHOD - - -# LT_PATH_NM -# ---------- -# find the pathname to a BSD- or MS-compatible name lister -AC_DEFUN([LT_PATH_NM], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi]) -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols" - ;; - *) - DUMPBIN=: - ;; - esac - fi - AC_SUBST([DUMPBIN]) - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm -AC_SUBST([NM]) -_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl - -AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], - [lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) - cat conftest.out >&AS_MESSAGE_LOG_FD - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest*]) -])# LT_PATH_NM - -# Old names: -AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) -AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_PROG_NM], []) -dnl AC_DEFUN([AC_PROG_NM], []) - -# _LT_CHECK_SHAREDLIB_FROM_LINKLIB -# -------------------------------- -# how to determine the name of the shared library -# associated with a specific link library. -# -- PORTME fill in with the dynamic library characteristics -m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], -[m4_require([_LT_DECL_EGREP]) -m4_require([_LT_DECL_OBJDUMP]) -m4_require([_LT_DECL_DLLTOOL]) -AC_CACHE_CHECK([how to associate runtime and link libraries], -lt_cv_sharedlib_from_linklib_cmd, -[lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" - ;; -esac -]) -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - -_LT_DECL([], [sharedlib_from_linklib_cmd], [1], - [Command to associate shared and link libraries]) -])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB - - -# _LT_PATH_MANIFEST_TOOL -# ---------------------- -# locate the manifest tool -m4_defun([_LT_PATH_MANIFEST_TOOL], -[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], - [lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&AS_MESSAGE_LOG_FD - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest*]) -if test "x$lt_cv_path_mainfest_tool" != xyes; then - MANIFEST_TOOL=: -fi -_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl -])# _LT_PATH_MANIFEST_TOOL - - -# LT_LIB_M -# -------- -# check for math library -AC_DEFUN([LT_LIB_M], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -AC_SUBST([LIBM]) -])# LT_LIB_M - -# Old name: -AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_CHECK_LIBM], []) - - -# _LT_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------- -m4_defun([_LT_COMPILER_NO_RTTI], -[m4_require([_LT_TAG_COMPILER])dnl - -_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test "$GCC" = yes; then - case $cc_basename in - nvcc*) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; - *) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; - esac - - _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], - [Compiler flag to turn off builtin functions]) -])# _LT_COMPILER_NO_RTTI - - -# _LT_CMD_GLOBAL_SYMBOLS -# ---------------------- -m4_defun([_LT_CMD_GLOBAL_SYMBOLS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([LT_PATH_NM])dnl -AC_REQUIRE([LT_PATH_LD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_TAG_COMPILER])dnl - -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris*) - symcode='[[BDRT]]' - ;; -sco3.2v5*) - symcode='[[DT]]' - ;; -sysv4.2uw2*) - symcode='[[DT]]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[[ABDT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" -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'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK ['"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx]" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT@&t@_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT@&t@_DLSYM_CONST -#else -# define LT@&t@_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT@&t@_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[[]] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - -_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], - [Take the output of nm and produce a listing of raw symbols and C names]) -_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], - [Transform the output of nm in a proper C declaration]) -_LT_DECL([global_symbol_to_c_name_address], - [lt_cv_sys_global_symbol_to_c_name_address], [1], - [Transform the output of nm in a C name address pair]) -_LT_DECL([global_symbol_to_c_name_address_lib_prefix], - [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], - [Transform the output of nm in a C name address pair when lib prefix is needed]) -_LT_DECL([], [nm_file_list_spec], [1], - [Specify filename containing input files for $NM]) -]) # _LT_CMD_GLOBAL_SYMBOLS - - -# _LT_COMPILER_PIC([TAGNAME]) -# --------------------------- -m4_defun([_LT_COMPILER_PIC], -[m4_require([_LT_TAG_COMPILER])dnl -_LT_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_TAGVAR(lt_prog_compiler_static, $1)= - -m4_if([$1], [CXX], [ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix[[4-9]]*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _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" - ;; - esac - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) - # IBM XL 8.0, 9.0 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd* | netbsdelf*-gnu) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' - if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - hpux9* | hpux10* | hpux11*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' - _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' - ;; - nagfor*) - # NAG Fortran compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='' - ;; - *Sun\ F* | *Sun*Fortran*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - *Intel*\ [[CF]]*Compiler*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - *Portland\ Group*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - rdos*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - solaris*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - unicos*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" - ;; -esac - -AC_CACHE_CHECK([for $compiler option to produce PIC], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) -_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], - [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], - [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], - [Additional compiler flags for building library objects]) - -_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], - [How to pass a linker flag through the compiler]) -# -# Check to make sure the static flag actually works. -# -wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" -_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], - _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), - $lt_tmp_static_flag, - [], - [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) -_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], - [Compiler flag to prevent dynamic linking]) -])# _LT_COMPILER_PIC - - -# _LT_LINKER_SHLIBS([TAGNAME]) -# ---------------------------- -# See if the linker supports building shared libraries. -m4_defun([_LT_LINKER_SHLIBS], -[AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -m4_if([$1], [CXX], [ - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - case $host_os in - aix[[4-9]]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global defined - # symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _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' - else - _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' - fi - ;; - pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw* | cegcc*) - case $cc_basename in - cl*) - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - ;; - *) - _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' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - ;; - esac - ;; - linux* | k*bsd*-gnu | gnu*) - _LT_TAGVAR(link_all_deplibs, $1)=no - ;; - *) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -], [ - runpath_var= - _LT_TAGVAR(allow_undefined_flag, $1)= - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(archive_cmds, $1)= - _LT_TAGVAR(archive_expsym_cmds, $1)= - _LT_TAGVAR(compiler_needs_object, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(hardcode_automatic, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(hardcode_libdir_separator, $1)= - _LT_TAGVAR(hardcode_minus_L, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_TAGVAR(inherit_rpath, $1)=no - _LT_TAGVAR(link_all_deplibs, $1)=unknown - _LT_TAGVAR(module_cmds, $1)= - _LT_TAGVAR(module_expsym_cmds, $1)= - _LT_TAGVAR(old_archive_from_new_cmds, $1)= - _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_TAGVAR(thread_safe_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. -dnl Note also adjust exclude_expsyms for C++ above. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - linux* | k*bsd*-gnu | gnu*) - _LT_TAGVAR(link_all_deplibs, $1)=no - ;; - esac - - _LT_TAGVAR(ld_shlibs, $1)=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; - *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test "$lt_use_gnu_ld_interface" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[[3-9]]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _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)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _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' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _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' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _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' - _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' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _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' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - _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' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - _LT_TAGVAR(whole_archive_flag_spec, $1)= - tmp_sharedflag='--shared' ;; - xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - sunos4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _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' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _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' - else - _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' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - _LT_TAGVAR(link_all_deplibs, $1)=no - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _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" - else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _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' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _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)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - bsdi[[45]]*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl*) - # Native MSVC - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - _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' - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC wrapper - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - esac - ;; - - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test "$GCC" = yes; then - _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' - else - _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' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - m4_if($1, [], [ - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - _LT_LINKER_OPTION([if $CC understands -b], - _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], - [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) - ;; - esac - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _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' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], - [lt_cv_irix_exported_symbol], - [save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - AC_LINK_IFELSE( - [AC_LANG_SOURCE( - [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], - [C++], [[int foo (void) { return 0; }]], - [Fortran 77], [[ - subroutine foo - end]], - [Fortran], [[ - subroutine foo - end]])])], - [lt_cv_irix_exported_symbol=yes], - [lt_cv_irix_exported_symbol=no]) - LDFLAGS="$save_LDFLAGS"]) - if test "$lt_cv_irix_exported_symbol" = yes; then - _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' - fi - else - _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' - _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' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *nto* | *qnx*) - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _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' - _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - _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~ - $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' - - # Both c and cxx compiler support -rpath directly - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - solaris*) - _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - fi - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_TAGVAR(ld_shlibs, $1)=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' - ;; - esac - fi - fi -]) -AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld - -_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl -_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl -_LT_DECL([], [extract_expsyms_cmds], [2], - [The commands to extract the exported symbol list from a shared archive]) - -# -# Do we need to explicitly link libc? -# -case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_CACHE_CHECK([whether -lc should be explicitly linked in], - [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), - [$RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) - pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) - _LT_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) - then - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no - else - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - ]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) - ;; - esac - fi - ;; -esac - -_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], - [Whether or not to add -lc for building shared libraries]) -_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], - [enable_shared_with_static_runtimes], [0], - [Whether or not to disallow shared libs when runtime libs are static]) -_LT_TAGDECL([], [export_dynamic_flag_spec], [1], - [Compiler flag to allow reflexive dlopens]) -_LT_TAGDECL([], [whole_archive_flag_spec], [1], - [Compiler flag to generate shared objects directly from archives]) -_LT_TAGDECL([], [compiler_needs_object], [1], - [Whether the compiler copes with passing no objects directly]) -_LT_TAGDECL([], [old_archive_from_new_cmds], [2], - [Create an old-style archive from a shared archive]) -_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], - [Create a temporary old-style archive to link instead of a shared archive]) -_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) -_LT_TAGDECL([], [archive_expsym_cmds], [2]) -_LT_TAGDECL([], [module_cmds], [2], - [Commands used to build a loadable module if different from building - a shared archive.]) -_LT_TAGDECL([], [module_expsym_cmds], [2]) -_LT_TAGDECL([], [with_gnu_ld], [1], - [Whether we are building with GNU ld or not]) -_LT_TAGDECL([], [allow_undefined_flag], [1], - [Flag that allows shared libraries with undefined symbols to be built]) -_LT_TAGDECL([], [no_undefined_flag], [1], - [Flag that enforces no undefined symbols]) -_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], - [Flag to hardcode $libdir into a binary during linking. - This must work even if $libdir does not exist]) -_LT_TAGDECL([], [hardcode_libdir_separator], [1], - [Whether we need a single "-rpath" flag with a separated argument]) -_LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary]) -_LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting ${shlibpath_var} if the - library is relocated]) -_LT_TAGDECL([], [hardcode_minus_L], [0], - [Set to "yes" if using the -LDIR flag during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_shlibpath_var], [0], - [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_automatic], [0], - [Set to "yes" if building a shared library automatically hardcodes DIR - into the library and all subsequent libraries and executables linked - against it]) -_LT_TAGDECL([], [inherit_rpath], [0], - [Set to yes if linker adds runtime paths of dependent libraries - to runtime path list]) -_LT_TAGDECL([], [link_all_deplibs], [0], - [Whether libtool must link a program against all its dependency libraries]) -_LT_TAGDECL([], [always_export_symbols], [0], - [Set to "yes" if exported symbols are required]) -_LT_TAGDECL([], [export_symbols_cmds], [2], - [The commands to list exported symbols]) -_LT_TAGDECL([], [exclude_expsyms], [1], - [Symbols that should not be listed in the preloaded symbols]) -_LT_TAGDECL([], [include_expsyms], [1], - [Symbols that must always be exported]) -_LT_TAGDECL([], [prelink_cmds], [2], - [Commands necessary for linking programs (against libraries) with templates]) -_LT_TAGDECL([], [postlink_cmds], [2], - [Commands necessary for finishing linking programs]) -_LT_TAGDECL([], [file_list_spec], [1], - [Specify filename containing input files]) -dnl FIXME: Not yet implemented -dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], -dnl [Compiler flag to generate thread safe objects]) -])# _LT_LINKER_SHLIBS - - -# _LT_LANG_C_CONFIG([TAG]) -# ------------------------ -# Ensure that the configuration variables for a C compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_C_CONFIG], -[m4_require([_LT_DECL_EGREP])dnl -lt_save_CC="$CC" -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - -_LT_TAG_COMPILER -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - LT_SYS_DLOPEN_SELF - _LT_CMD_STRIPLIB - - # Report which library types will actually be built - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_CONFIG($1) -fi -AC_LANG_POP -CC="$lt_save_CC" -])# _LT_LANG_C_CONFIG - - -# _LT_LANG_CXX_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a C++ compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_CXX_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -else - _lt_caught_CXX_error=yes -fi - -AC_LANG_PUSH(C++) -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(compiler_needs_object, $1)=no -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_CFLAGS=$CFLAGS - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - CFLAGS=$CXXFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - else - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - fi - - if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - LT_PATH_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) - _LT_TAGVAR(ld_shlibs, $1)=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty - # executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _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" - else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - _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' - fi - fi - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - case $GXX,$cc_basename in - ,cl* | no,cl*) - # Native MSVC - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # g++ - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _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' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - freebsd2.*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - freebsd-elf*) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - - freebsd* | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - _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' - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _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' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _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' - ;; - *) - _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' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _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' - _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' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _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' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _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' - else - _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' - fi - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _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' - _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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - ;; - esac - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) - _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' - _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' - _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $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' - ;; - *) # Version 6 and above use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _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' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _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' - ;; - cxx*) - # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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' - ;; - xl* | mpixl* | bgxl*) - # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - esac - ;; - - lynxos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - m88k*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - - *nto* | *qnx*) - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - openbsd2*) - # C++ shared libraries are fairly broken - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _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' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd=func_echo_all - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - case $host in - osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - ;; - *) - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $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~ - $RM $lib.exp' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - case $host in - osf3*) - _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' - ;; - *) - _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' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _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' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - fi - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ - '"$_LT_TAGVAR(old_archive_cmds, $1)" - _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ - '"$_LT_TAGVAR(reload_cmds, $1)" - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - - _LT_TAGVAR(GCC, $1)="$GXX" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes - -AC_LANG_POP -])# _LT_LANG_CXX_CONFIG - - -# _LT_FUNC_STRIPNAME_CNF -# ---------------------- -# func_stripname_cnf prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# -# This function is identical to the (non-XSI) version of func_stripname, -# except this one can be used by m4 code that may be executed by configure, -# rather than the libtool script. -m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl -AC_REQUIRE([_LT_DECL_SED]) -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) -func_stripname_cnf () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname_cnf -])# _LT_FUNC_STRIPNAME_CNF - -# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) -# --------------------------------- -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -m4_defun([_LT_SYS_HIDDEN_LIBDEPS], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl -# Dependencies to place before and after the object being linked: -_LT_TAGVAR(predep_objects, $1)= -_LT_TAGVAR(postdep_objects, $1)= -_LT_TAGVAR(predeps, $1)= -_LT_TAGVAR(postdeps, $1)= -_LT_TAGVAR(compiler_lib_search_path, $1)= - -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF -int a; -void foo (void) { a = 0; } -_LT_EOF -], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -_LT_EOF -], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer*4 a - a=0 - return - end -_LT_EOF -], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer a - a=0 - return - end -_LT_EOF -], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF -public class foo { - private int a; - public void bar (void) { - a = 0; - } -}; -_LT_EOF -], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF -package foo -func foo() { -} -_LT_EOF -]) - -_lt_libdeps_save_CFLAGS=$CFLAGS -case "$CC $CFLAGS " in #( -*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; -*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; -*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; -esac - -dnl Parse the compiler output and extract the necessary -dnl objects, libraries and library flags. -if AC_TRY_EVAL(ac_compile); then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - for p in `eval "$output_verbose_link_cmd"`; do - case ${prev}${p} in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test $p = "-L" || - test $p = "-R"; then - prev=$p - continue - fi - - # Expand the sysroot to ease extracting the directories later. - if test -z "$prev"; then - case $p in - -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; - -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; - -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; - esac - fi - case $p in - =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; - esac - if test "$pre_test_object_deps_done" = no; then - case ${prev} in - -L | -R) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" - else - _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$_LT_TAGVAR(postdeps, $1)"; then - _LT_TAGVAR(postdeps, $1)="${prev}${p}" - else - _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" - fi - fi - prev= - ;; - - *.lto.$objext) ;; # Ignore GCC LTO objects - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test "$pre_test_object_deps_done" = no; then - if test -z "$_LT_TAGVAR(predep_objects, $1)"; then - _LT_TAGVAR(predep_objects, $1)="$p" - else - _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" - fi - else - if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then - _LT_TAGVAR(postdep_objects, $1)="$p" - else - _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling $1 test program" -fi - -$RM -f confest.$objext -CFLAGS=$_lt_libdeps_save_CFLAGS - -# PORTME: override above test on systems where it is broken -m4_if([$1], [CXX], -[case $host_os in -interix[[3-9]]*) - # Interix 3.5 installs completely hosed .la files for C++, so rather than - # hack all around it, let's just trust "g++" to DTRT. - _LT_TAGVAR(predep_objects,$1)= - _LT_TAGVAR(postdep_objects,$1)= - _LT_TAGVAR(postdeps,$1)= - ;; - -linux*) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; - -solaris*) - case $cc_basename in - CC* | sunCC*) - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - # Adding this requires a known-good setup of shared libraries for - # Sun compiler versions before 5.6, else PIC objects from an old - # archive will be linked into the output, leading to subtle bugs. - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; -esac -]) - -case " $_LT_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; -esac - _LT_TAGVAR(compiler_lib_search_dirs, $1)= -if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` -fi -_LT_TAGDECL([], [compiler_lib_search_dirs], [1], - [The directories searched by this compiler when creating a shared library]) -_LT_TAGDECL([], [predep_objects], [1], - [Dependencies to place before and after the objects being linked to - create a shared library]) -_LT_TAGDECL([], [postdep_objects], [1]) -_LT_TAGDECL([], [predeps], [1]) -_LT_TAGDECL([], [postdeps], [1]) -_LT_TAGDECL([], [compiler_lib_search_path], [1], - [The library search path used internally by the compiler when linking - a shared library]) -])# _LT_SYS_HIDDEN_LIBDEPS - - -# _LT_LANG_F77_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a Fortran 77 compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_F77_CONFIG], -[AC_LANG_PUSH(Fortran 77) -if test -z "$F77" || test "X$F77" = "Xno"; then - _lt_disable_F77=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the F77 compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_F77" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${F77-"f77"} - CFLAGS=$FFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - GCC=$G77 - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$G77" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC="$lt_save_CC" - CFLAGS="$lt_save_CFLAGS" -fi # test "$_lt_disable_F77" != yes - -AC_LANG_POP -])# _LT_LANG_F77_CONFIG - - -# _LT_LANG_FC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for a Fortran compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_FC_CONFIG], -[AC_LANG_PUSH(Fortran) - -if test -z "$FC" || test "X$FC" = "Xno"; then - _lt_disable_FC=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for fc test sources. -ac_ext=${ac_fc_srcext-f} - -# Object file extension for compiled fc test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the FC compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_FC" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${FC-"f95"} - CFLAGS=$FCFLAGS - compiler=$CC - GCC=$ac_cv_fc_compiler_gnu - - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS -fi # test "$_lt_disable_FC" != yes - -AC_LANG_POP -])# _LT_LANG_FC_CONFIG - - -# _LT_LANG_GCJ_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Java Compiler compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_GCJ_CONFIG], -[AC_REQUIRE([LT_PROG_GCJ])dnl -AC_LANG_SAVE - -# Source file extension for Java test sources. -ac_ext=java - -# Object file extension for compiled Java test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}" - -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GCJ-"gcj"} -CFLAGS=$GCJFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" -_LT_CC_BASENAME([$compiler]) - -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GCJ_CONFIG - - -# _LT_LANG_GO_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Go compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_GO_CONFIG], -[AC_REQUIRE([LT_PROG_GO])dnl -AC_LANG_SAVE - -# Source file extension for Go test sources. -ac_ext=go - -# Object file extension for compiled Go test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="package main; func main() { }" - -# Code to be used in simple link tests -lt_simple_link_test_code='package main; func main() { }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GOC-"gccgo"} -CFLAGS=$GOFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" -_LT_CC_BASENAME([$compiler]) - -# Go did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GO_CONFIG - - -# _LT_LANG_RC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for the Windows resource compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_RC_CONFIG], -[AC_REQUIRE([LT_PROG_RC])dnl -AC_LANG_SAVE - -# Source file extension for RC test sources. -ac_ext=rc - -# Object file extension for compiled RC test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' - -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC= -CC=${RC-"windres"} -CFLAGS= -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) -_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -if test -n "$compiler"; then - : - _LT_CONFIG($1) -fi - -GCC=$lt_save_GCC -AC_LANG_RESTORE -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_RC_CONFIG - - -# LT_PROG_GCJ -# ----------- -AC_DEFUN([LT_PROG_GCJ], -[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], - [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], - [AC_CHECK_TOOL(GCJ, gcj,) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS)])])[]dnl -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_GCJ], []) - - -# LT_PROG_GO -# ---------- -AC_DEFUN([LT_PROG_GO], -[AC_CHECK_TOOL(GOC, gccgo,) -]) - - -# LT_PROG_RC -# ---------- -AC_DEFUN([LT_PROG_RC], -[AC_CHECK_TOOL(RC, windres,) -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_RC], []) - - -# _LT_DECL_EGREP -# -------------- -# If we don't have a new enough Autoconf to choose the best grep -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_EGREP], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_REQUIRE([AC_PROG_FGREP])dnl -test -z "$GREP" && GREP=grep -_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) -_LT_DECL([], [EGREP], [1], [An ERE matcher]) -_LT_DECL([], [FGREP], [1], [A literal string matcher]) -dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too -AC_SUBST([GREP]) -]) - - -# _LT_DECL_OBJDUMP -# -------------- -# If we don't have a new enough Autoconf to choose the best objdump -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_OBJDUMP], -[AC_CHECK_TOOL(OBJDUMP, objdump, false) -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) -AC_SUBST([OBJDUMP]) -]) - -# _LT_DECL_DLLTOOL -# ---------------- -# Ensure DLLTOOL variable is set. -m4_defun([_LT_DECL_DLLTOOL], -[AC_CHECK_TOOL(DLLTOOL, dlltool, false) -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) -AC_SUBST([DLLTOOL]) -]) - -# _LT_DECL_SED -# ------------ -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -m4_defun([_LT_DECL_SED], -[AC_PROG_SED -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" -_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) -_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], - [Sed that helps us avoid accidentally triggering echo(1) options like -n]) -])# _LT_DECL_SED - -m4_ifndef([AC_PROG_SED], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ - -m4_defun([AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -])#AC_PROG_SED -])#m4_ifndef - -# Old name: -AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_SED], []) - - -# _LT_CHECK_SHELL_FEATURES -# ------------------------ -# Find out whether the shell is Bourne or XSI compatible, -# or has some other useful features. -m4_defun([_LT_CHECK_SHELL_FEATURES], -[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -AC_MSG_RESULT([$xsi_shell]) -_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) - -AC_MSG_CHECKING([whether the shell understands "+="]) -lt_shell_append=no -( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -AC_MSG_RESULT([$lt_shell_append]) -_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi -_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac -_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl -_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl -])# _LT_CHECK_SHELL_FEATURES - - -# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) -# ------------------------------------------------------ -# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and -# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. -m4_defun([_LT_PROG_FUNCTION_REPLACE], -[dnl { -sed -e '/^$1 ()$/,/^} # $1 /c\ -$1 ()\ -{\ -m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) -} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: -]) - - -# _LT_PROG_REPLACE_SHELLFNS -# ------------------------- -# Replace existing portable implementations of several shell functions with -# equivalent extended shell implementations where those features are available.. -m4_defun([_LT_PROG_REPLACE_SHELLFNS], -[if test x"$xsi_shell" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl - func_split_long_opt_name=${1%%=*} - func_split_long_opt_arg=${1#*=}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl - func_split_short_opt_arg=${1#??} - func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) - - _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) - - _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) - - _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) -fi - -if test x"$lt_shell_append" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) - - _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl - func_quote_for_eval "${2}" -dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ - eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) -fi -]) - -# _LT_PATH_CONVERSION_FUNCTIONS -# ----------------------------- -# Determine which file name conversion functions should be used by -# func_to_host_file (and, implicitly, by func_to_host_path). These are needed -# for certain cross-compile configurations and native mingw. -m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_MSG_CHECKING([how to convert $build file names to $host format]) -AC_CACHE_VAL(lt_cv_to_host_file_cmd, -[case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac -]) -to_host_file_cmd=$lt_cv_to_host_file_cmd -AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) -_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], - [0], [convert $build file names to $host format])dnl - -AC_MSG_CHECKING([how to convert $build file names to toolchain format]) -AC_CACHE_VAL(lt_cv_to_tool_file_cmd, -[#assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac -]) -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) -_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], - [0], [convert $build files to toolchain format])dnl -])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/lib-src/expat/m4/ltoptions.m4 b/lib-src/expat/m4/ltoptions.m4 deleted file mode 100644 index 5d9acd8e2..000000000 --- a/lib-src/expat/m4/ltoptions.m4 +++ /dev/null @@ -1,384 +0,0 @@ -# Helper functions for option handling. -*- Autoconf -*- -# -# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 7 ltoptions.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) - - -# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) -# ------------------------------------------ -m4_define([_LT_MANGLE_OPTION], -[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) - - -# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) -# --------------------------------------- -# Set option OPTION-NAME for macro MACRO-NAME, and if there is a -# matching handler defined, dispatch to it. Other OPTION-NAMEs are -# saved as a flag. -m4_define([_LT_SET_OPTION], -[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl -m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), - _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option `$2'])])[]dnl -]) - - -# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) -# ------------------------------------------------------------ -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -m4_define([_LT_IF_OPTION], -[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) - - -# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) -# ------------------------------------------------------- -# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME -# are set. -m4_define([_LT_UNLESS_OPTIONS], -[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), - [m4_define([$0_found])])])[]dnl -m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 -])[]dnl -]) - - -# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) -# ---------------------------------------- -# OPTION-LIST is a space-separated list of Libtool options associated -# with MACRO-NAME. If any OPTION has a matching handler declared with -# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about -# the unknown option and exit. -m4_defun([_LT_SET_OPTIONS], -[# Set options -m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [_LT_SET_OPTION([$1], _LT_Option)]) - -m4_if([$1],[LT_INIT],[ - dnl - dnl Simply set some default values (i.e off) if boolean options were not - dnl specified: - _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no - ]) - _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no - ]) - dnl - dnl If no reference was made to various pairs of opposing options, then - dnl we run the default mode handler for the pair. For example, if neither - dnl `shared' nor `disable-shared' was passed, we enable building of shared - dnl archives by default: - _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) - _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) - ]) -])# _LT_SET_OPTIONS - - -## --------------------------------- ## -## Macros to handle LT_INIT options. ## -## --------------------------------- ## - -# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) -# ----------------------------------------- -m4_define([_LT_MANGLE_DEFUN], -[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) - - -# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) -# ----------------------------------------------- -m4_define([LT_OPTION_DEFINE], -[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl -])# LT_OPTION_DEFINE - - -# dlopen -# ------ -LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes -]) - -AU_DEFUN([AC_LIBTOOL_DLOPEN], -[_LT_SET_OPTION([LT_INIT], [dlopen]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) - - -# win32-dll -# --------- -# Declare package support for building win32 dll's. -LT_OPTION_DEFINE([LT_INIT], [win32-dll], -[enable_win32_dll=yes - -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; -esac - -test -z "$AS" && AS=as -_LT_DECL([], [AS], [1], [Assembler program])dnl - -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl - -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl -])# win32-dll - -AU_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -_LT_SET_OPTION([LT_INIT], [win32-dll]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `win32-dll' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) - - -# _LT_ENABLE_SHARED([DEFAULT]) -# ---------------------------- -# implement the --enable-shared flag, and supports the `shared' and -# `disable-shared' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_SHARED], -[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) - - _LT_DECL([build_libtool_libs], [enable_shared], [0], - [Whether or not to build shared libraries]) -])# _LT_ENABLE_SHARED - -LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) -]) - -AC_DEFUN([AC_DISABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], [disable-shared]) -]) - -AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_SHARED], []) -dnl AC_DEFUN([AM_DISABLE_SHARED], []) - - - -# _LT_ENABLE_STATIC([DEFAULT]) -# ---------------------------- -# implement the --enable-static flag, and support the `static' and -# `disable-static' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_STATIC], -[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([static], - [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_static=]_LT_ENABLE_STATIC_DEFAULT) - - _LT_DECL([build_old_libs], [enable_static], [0], - [Whether or not to build static libraries]) -])# _LT_ENABLE_STATIC - -LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) -]) - -AC_DEFUN([AC_DISABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], [disable-static]) -]) - -AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_STATIC], []) -dnl AC_DEFUN([AM_DISABLE_STATIC], []) - - - -# _LT_ENABLE_FAST_INSTALL([DEFAULT]) -# ---------------------------------- -# implement the --enable-fast-install flag, and support the `fast-install' -# and `disable-fast-install' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_FAST_INSTALL], -[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([fast-install], - [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) - -_LT_DECL([fast_install], [enable_fast_install], [0], - [Whether or not to optimize for fast installation])dnl -])# _LT_ENABLE_FAST_INSTALL - -LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) - -# Old names: -AU_DEFUN([AC_ENABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `fast-install' option into LT_INIT's first parameter.]) -]) - -AU_DEFUN([AC_DISABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `disable-fast-install' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) -dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) - - -# _LT_WITH_PIC([MODE]) -# -------------------- -# implement the --with-pic flag, and support the `pic-only' and `no-pic' -# LT_INIT options. -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -m4_define([_LT_WITH_PIC], -[AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for lt_pkg in $withval; do - IFS="$lt_save_ifs" - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [pic_mode=default]) - -test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) - -_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl -])# _LT_WITH_PIC - -LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) - -# Old name: -AU_DEFUN([AC_LIBTOOL_PICMODE], -[_LT_SET_OPTION([LT_INIT], [pic-only]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `pic-only' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) - -## ----------------- ## -## LTDL_INIT Options ## -## ----------------- ## - -m4_define([_LTDL_MODE], []) -LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], - [m4_define([_LTDL_MODE], [nonrecursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [recursive], - [m4_define([_LTDL_MODE], [recursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [subproject], - [m4_define([_LTDL_MODE], [subproject])]) - -m4_define([_LTDL_TYPE], []) -LT_OPTION_DEFINE([LTDL_INIT], [installable], - [m4_define([_LTDL_TYPE], [installable])]) -LT_OPTION_DEFINE([LTDL_INIT], [convenience], - [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/lib-src/expat/m4/ltsugar.m4 b/lib-src/expat/m4/ltsugar.m4 deleted file mode 100644 index 9000a057d..000000000 --- a/lib-src/expat/m4/ltsugar.m4 +++ /dev/null @@ -1,123 +0,0 @@ -# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 6 ltsugar.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) - - -# lt_join(SEP, ARG1, [ARG2...]) -# ----------------------------- -# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their -# associated separator. -# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier -# versions in m4sugar had bugs. -m4_define([lt_join], -[m4_if([$#], [1], [], - [$#], [2], [[$2]], - [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) -m4_define([_lt_join], -[m4_if([$#$2], [2], [], - [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) - - -# lt_car(LIST) -# lt_cdr(LIST) -# ------------ -# Manipulate m4 lists. -# These macros are necessary as long as will still need to support -# Autoconf-2.59 which quotes differently. -m4_define([lt_car], [[$1]]) -m4_define([lt_cdr], -[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], - [$#], 1, [], - [m4_dquote(m4_shift($@))])]) -m4_define([lt_unquote], $1) - - -# lt_append(MACRO-NAME, STRING, [SEPARATOR]) -# ------------------------------------------ -# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. -# Note that neither SEPARATOR nor STRING are expanded; they are appended -# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). -# No SEPARATOR is output if MACRO-NAME was previously undefined (different -# than defined and empty). -# -# This macro is needed until we can rely on Autoconf 2.62, since earlier -# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. -m4_define([lt_append], -[m4_define([$1], - m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) - - - -# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) -# ---------------------------------------------------------- -# Produce a SEP delimited list of all paired combinations of elements of -# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list -# has the form PREFIXmINFIXSUFFIXn. -# Needed until we can rely on m4_combine added in Autoconf 2.62. -m4_define([lt_combine], -[m4_if(m4_eval([$# > 3]), [1], - [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl -[[m4_foreach([_Lt_prefix], [$2], - [m4_foreach([_Lt_suffix], - ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, - [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) - - -# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) -# ----------------------------------------------------------------------- -# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited -# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. -m4_define([lt_if_append_uniq], -[m4_ifdef([$1], - [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], - [lt_append([$1], [$2], [$3])$4], - [$5])], - [lt_append([$1], [$2], [$3])$4])]) - - -# lt_dict_add(DICT, KEY, VALUE) -# ----------------------------- -m4_define([lt_dict_add], -[m4_define([$1($2)], [$3])]) - - -# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) -# -------------------------------------------- -m4_define([lt_dict_add_subkey], -[m4_define([$1($2:$3)], [$4])]) - - -# lt_dict_fetch(DICT, KEY, [SUBKEY]) -# ---------------------------------- -m4_define([lt_dict_fetch], -[m4_ifval([$3], - m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), - m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) - - -# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) -# ----------------------------------------------------------------- -m4_define([lt_if_dict_fetch], -[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], - [$5], - [$6])]) - - -# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) -# -------------------------------------------------------------- -m4_define([lt_dict_filter], -[m4_if([$5], [], [], - [lt_join(m4_quote(m4_default([$4], [[, ]])), - lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), - [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl -]) diff --git a/lib-src/expat/m4/ltversion.m4 b/lib-src/expat/m4/ltversion.m4 deleted file mode 100644 index 07a8602d4..000000000 --- a/lib-src/expat/m4/ltversion.m4 +++ /dev/null @@ -1,23 +0,0 @@ -# ltversion.m4 -- version numbers -*- Autoconf -*- -# -# Copyright (C) 2004 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# @configure_input@ - -# serial 3337 ltversion.m4 -# This file is part of GNU Libtool - -m4_define([LT_PACKAGE_VERSION], [2.4.2]) -m4_define([LT_PACKAGE_REVISION], [1.3337]) - -AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.2' -macro_revision='1.3337' -_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) -_LT_DECL(, macro_revision, 0) -]) diff --git a/lib-src/expat/m4/lt~obsolete.m4 b/lib-src/expat/m4/lt~obsolete.m4 deleted file mode 100644 index c573da90c..000000000 --- a/lib-src/expat/m4/lt~obsolete.m4 +++ /dev/null @@ -1,98 +0,0 @@ -# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004. -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 5 lt~obsolete.m4 - -# These exist entirely to fool aclocal when bootstrapping libtool. -# -# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) -# which have later been changed to m4_define as they aren't part of the -# exported API, or moved to Autoconf or Automake where they belong. -# -# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN -# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us -# using a macro with the same name in our local m4/libtool.m4 it'll -# pull the old libtool.m4 in (it doesn't see our shiny new m4_define -# and doesn't know about Autoconf macros at all.) -# -# So we provide this file, which has a silly filename so it's always -# included after everything else. This provides aclocal with the -# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything -# because those macros already exist, or will be overwritten later. -# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. -# -# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. -# Yes, that means every name once taken will need to remain here until -# we give up compatibility with versions before 1.7, at which point -# we need to keep only those names which we still refer to. - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) - -m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) -m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) -m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) -m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) -m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) -m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) -m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) -m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) -m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) -m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) -m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) -m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) -m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) -m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) -m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) -m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) -m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) -m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) -m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) -m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) -m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) -m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) -m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) -m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) -m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) -m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) -m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) -m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) -m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) -m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) -m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) -m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) -m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) -m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) -m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) -m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) -m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) -m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) -m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) -m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) -m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) -m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) -m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) -m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) -m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) -m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) -m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) -m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) -m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) -m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/lib-src/expat/tests/README.txt b/lib-src/expat/tests/README.txt deleted file mode 100644 index 30e1d4dab..000000000 --- a/lib-src/expat/tests/README.txt +++ /dev/null @@ -1,13 +0,0 @@ -This directory contains the (fledgling) test suite for Expat. The -tests provide general unit testing and regression coverage. The tests -are not expected to be useful examples of Expat usage; see the -examples/ directory for that. - -The Expat tests use a partial internal implementation of the "Check" -unit testing framework for C. More information on Check can be found at: - - http://check.sourceforge.net/ - -Expat must be built and, depending on platform, must be installed, before "make check" can be executed. - -This test suite can all change in a later version. diff --git a/lib-src/expat/tests/benchmark/README.txt b/lib-src/expat/tests/benchmark/README.txt deleted file mode 100644 index 7f9cca037..000000000 --- a/lib-src/expat/tests/benchmark/README.txt +++ /dev/null @@ -1,16 +0,0 @@ -Use this benchmark command line utility as follows: - - benchmark [-n] <# iterations> - -The command line arguments are: - - -n ... optional; if supplied, namespace processing is turned on - ... name/path of test xml file - ... size of processing buffer; - the file is parsed in chunks of this size - <# iterations> ... how often will the file be parsed - -Returns: - - The time (in seconds) it takes to parse the test file, - averaged over the number of iterations. \ No newline at end of file diff --git a/lib-src/expat/tests/benchmark/benchmark.c b/lib-src/expat/tests/benchmark/benchmark.c deleted file mode 100644 index 0f0fd18c1..000000000 --- a/lib-src/expat/tests/benchmark/benchmark.c +++ /dev/null @@ -1,114 +0,0 @@ -#include -#include -#include -#include -#include "expat.h" - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -#ifdef XML_LARGE_SIZE -#define XML_FMT_INT_MOD "ll" -#else -#define XML_FMT_INT_MOD "l" -#endif - -static void -usage(const char *prog, int rc) -{ - fprintf(stderr, - "usage: %s [-n] filename bufferSize nr_of_loops\n", prog); - exit(rc); -} - -int main (int argc, char *argv[]) -{ - XML_Parser parser; - char *XMLBuf, *XMLBufEnd, *XMLBufPtr; - FILE *fd; - struct stat fileAttr; - int nrOfLoops, bufferSize, fileSize, i, isFinal; - int j = 0, ns = 0; - clock_t tstart, tend; - double cpuTime = 0.0; - - if (argc > 1) { - if (argv[1][0] == '-') { - if (argv[1][1] == 'n' && argv[1][2] == '\0') { - ns = 1; - j = 1; - } - else - usage(argv[0], 1); - } - } - - if (argc != j + 4) - usage(argv[0], 1); - - if (stat (argv[j + 1], &fileAttr) != 0) { - fprintf (stderr, "could not access file '%s'\n", argv[j + 1]); - return 2; - } - - fd = fopen (argv[j + 1], "r"); - if (!fd) { - fprintf (stderr, "could not open file '%s'\n", argv[j + 1]); - exit(2); - } - - bufferSize = atoi (argv[j + 2]); - nrOfLoops = atoi (argv[j + 3]); - if (bufferSize <= 0 || nrOfLoops <= 0) { - fprintf (stderr, - "buffer size and nr of loops must be greater than zero.\n"); - exit(3); - } - - XMLBuf = malloc (fileAttr.st_size); - fileSize = fread (XMLBuf, sizeof (char), fileAttr.st_size, fd); - fclose (fd); - - if (ns) - parser = XML_ParserCreateNS(NULL, '!'); - else - parser = XML_ParserCreate(NULL); - - i = 0; - XMLBufEnd = XMLBuf + fileSize; - while (i < nrOfLoops) { - XMLBufPtr = XMLBuf; - isFinal = 0; - tstart = clock(); - do { - int parseBufferSize = XMLBufEnd - XMLBufPtr; - if (parseBufferSize <= bufferSize) - isFinal = 1; - else - parseBufferSize = bufferSize; - if (!XML_Parse (parser, XMLBufPtr, parseBufferSize, isFinal)) { - fprintf (stderr, "error '%s' at line %" XML_FMT_INT_MOD \ - "u character %" XML_FMT_INT_MOD "u\n", - XML_ErrorString (XML_GetErrorCode (parser)), - XML_GetCurrentLineNumber (parser), - XML_GetCurrentColumnNumber (parser)); - free (XMLBuf); - XML_ParserFree (parser); - exit (4); - } - XMLBufPtr += bufferSize; - } while (!isFinal); - tend = clock(); - cpuTime += ((double) (tend - tstart)) / CLOCKS_PER_SEC; - XML_ParserReset(parser, NULL); - i++; - } - - XML_ParserFree (parser); - free (XMLBuf); - - printf ("%d loops, with buffer size %d. Average time per loop: %f\n", - nrOfLoops, bufferSize, cpuTime / (double) nrOfLoops); - return 0; -} diff --git a/lib-src/expat/tests/benchmark/benchmark.dsp b/lib-src/expat/tests/benchmark/benchmark.dsp deleted file mode 100644 index b58a39b9e..000000000 --- a/lib-src/expat/tests/benchmark/benchmark.dsp +++ /dev/null @@ -1,88 +0,0 @@ -# Microsoft Developer Studio Project File - Name="benchmark" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=benchmark - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "benchmark.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "benchmark.mak" CFG="benchmark - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "benchmark - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "benchmark - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "benchmark - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /W3 /GX /O2 /I "..\..\lib" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c -# ADD BASE RSC /l 0x1009 /d "NDEBUG" -# ADD RSC /l 0x1009 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /machine:I386 -# ADD LINK32 libexpat.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\win32\bin\Release" - -!ELSEIF "$(CFG)" == "benchmark - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\lib" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD BASE RSC /l 0x1009 /d "_DEBUG" -# ADD RSC /l 0x1009 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 libexpat.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\win32\bin\Debug" - -!ENDIF - -# Begin Target - -# Name "benchmark - Win32 Release" -# Name "benchmark - Win32 Debug" -# Begin Source File - -SOURCE=.\benchmark.c -# End Source File -# End Target -# End Project diff --git a/lib-src/expat/tests/benchmark/benchmark.dsw b/lib-src/expat/tests/benchmark/benchmark.dsw deleted file mode 100644 index db8504c0f..000000000 --- a/lib-src/expat/tests/benchmark/benchmark.dsw +++ /dev/null @@ -1,44 +0,0 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "benchmark"=.\benchmark.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name expat - End Project Dependency -}}} - -############################################################################### - -Project: "expat"=..\..\lib\expat.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - diff --git a/lib-src/expat/tests/chardata.c b/lib-src/expat/tests/chardata.c deleted file mode 100644 index 5fb0299d8..000000000 --- a/lib-src/expat/tests/chardata.c +++ /dev/null @@ -1,131 +0,0 @@ -/* Copyright (c) 1998-2003 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. - - chardata.c -*/ - -#ifdef HAVE_EXPAT_CONFIG_H -#include -#endif -#ifdef HAVE_CHECK_H -#include -#else -#include "minicheck.h" -#endif - -#include -#include -#include - -#include "chardata.h" - - -static int -xmlstrlen(const XML_Char *s) -{ - int len = 0; - assert(s != NULL); - while (s[len] != 0) - ++len; - return len; -} - - -void -CharData_Init(CharData *storage) -{ - assert(storage != NULL); - storage->count = -1; -} - -void -CharData_AppendString(CharData *storage, const char *s) -{ - int maxchars = sizeof(storage->data) / sizeof(storage->data[0]); - int len; - - assert(s != NULL); - len = strlen(s); - if (storage->count < 0) - storage->count = 0; - if ((len + storage->count) > maxchars) { - len = (maxchars - storage->count); - } - if (len + storage->count < sizeof(storage->data)) { - memcpy(storage->data + storage->count, s, len); - storage->count += len; - } -} - -void -CharData_AppendXMLChars(CharData *storage, const XML_Char *s, int len) -{ - int maxchars; - - assert(storage != NULL); - assert(s != NULL); - maxchars = sizeof(storage->data) / sizeof(storage->data[0]); - if (storage->count < 0) - storage->count = 0; - if (len < 0) - len = xmlstrlen(s); - if ((len + storage->count) > maxchars) { - len = (maxchars - storage->count); - } - if (len + storage->count < sizeof(storage->data)) { - memcpy(storage->data + storage->count, s, - len * sizeof(storage->data[0])); - storage->count += len; - } -} - -int -CharData_CheckString(CharData *storage, const char *expected) -{ - char buffer[1280]; - int len; - int count; - - assert(storage != NULL); - assert(expected != NULL); - count = (storage->count < 0) ? 0 : storage->count; - len = strlen(expected); - if (len != count) { - if (sizeof(XML_Char) == 1) - sprintf(buffer, "wrong number of data characters:" - " got %d, expected %d:\n%s", count, len, storage->data); - else - sprintf(buffer, - "wrong number of data characters: got %d, expected %d", - count, len); - fail(buffer); - return 0; - } - if (memcmp(expected, storage->data, len) != 0) { - fail("got bad data bytes"); - return 0; - } - return 1; -} - -int -CharData_CheckXMLChars(CharData *storage, const XML_Char *expected) -{ - char buffer[1024]; - int len = xmlstrlen(expected); - int count; - - assert(storage != NULL); - count = (storage->count < 0) ? 0 : storage->count; - if (len != count) { - sprintf(buffer, "wrong number of data characters: got %d, expected %d", - count, len); - fail(buffer); - return 0; - } - if (memcmp(expected, storage->data, len * sizeof(storage->data[0])) != 0) { - fail("got bad data bytes"); - return 0; - } - return 1; -} diff --git a/lib-src/expat/tests/chardata.h b/lib-src/expat/tests/chardata.h deleted file mode 100644 index e8dc4ce22..000000000 --- a/lib-src/expat/tests/chardata.h +++ /dev/null @@ -1,40 +0,0 @@ -/* chardata.h - - Interface to some helper routines used to accumulate and check text - and attribute content. -*/ - -#ifdef __cplusplus -extern "C" { -#endif - -#ifndef XML_CHARDATA_H -#define XML_CHARDATA_H 1 - -#ifndef XML_VERSION -#include "expat.h" /* need XML_Char */ -#endif - - -typedef struct { - int count; /* # of chars, < 0 if not set */ - XML_Char data[1024]; -} CharData; - - -void CharData_Init(CharData *storage); - -void CharData_AppendString(CharData *storage, const char *s); - -void CharData_AppendXMLChars(CharData *storage, const XML_Char *s, int len); - -int CharData_CheckString(CharData *storage, const char *s); - -int CharData_CheckXMLChars(CharData *storage, const XML_Char *s); - - -#endif /* XML_CHARDATA_H */ - -#ifdef __cplusplus -} -#endif diff --git a/lib-src/expat/tests/minicheck.c b/lib-src/expat/tests/minicheck.c deleted file mode 100644 index d2f4295ff..000000000 --- a/lib-src/expat/tests/minicheck.c +++ /dev/null @@ -1,182 +0,0 @@ -/* Miniature re-implementation of the "check" library. - * - * This is intended to support just enough of check to run the Expat - * tests. This interface is based entirely on the portion of the - * check library being used. - */ - -#include -#include -#include -#include - -#include "minicheck.h" - -Suite * -suite_create(char *name) -{ - Suite *suite = (Suite *) calloc(1, sizeof(Suite)); - if (suite != NULL) { - suite->name = name; - } - return suite; -} - -TCase * -tcase_create(char *name) -{ - TCase *tc = (TCase *) calloc(1, sizeof(TCase)); - if (tc != NULL) { - tc->name = name; - } - return tc; -} - -void -suite_add_tcase(Suite *suite, TCase *tc) -{ - assert(suite != NULL); - assert(tc != NULL); - assert(tc->next_tcase == NULL); - - tc->next_tcase = suite->tests; - suite->tests = tc; -} - -void -tcase_add_checked_fixture(TCase *tc, - tcase_setup_function setup, - tcase_teardown_function teardown) -{ - assert(tc != NULL); - tc->setup = setup; - tc->teardown = teardown; -} - -void -tcase_add_test(TCase *tc, tcase_test_function test) -{ - assert(tc != NULL); - if (tc->allocated == tc->ntests) { - int nalloc = tc->allocated + 100; - size_t new_size = sizeof(tcase_test_function) * nalloc; - tcase_test_function *new_tests = realloc(tc->tests, new_size); - assert(new_tests != NULL); - if (new_tests != tc->tests) { - free(tc->tests); - tc->tests = new_tests; - } - tc->allocated = nalloc; - } - tc->tests[tc->ntests] = test; - tc->ntests++; -} - -SRunner * -srunner_create(Suite *suite) -{ - SRunner *runner = calloc(1, sizeof(SRunner)); - if (runner != NULL) { - runner->suite = suite; - } - return runner; -} - -static jmp_buf env; - -static char const *_check_current_function = NULL; -static int _check_current_lineno = -1; -static char const *_check_current_filename = NULL; - -void -_check_set_test_info(char const *function, char const *filename, int lineno) -{ - _check_current_function = function; - _check_current_lineno = lineno; - _check_current_filename = filename; -} - - -static void -add_failure(SRunner *runner, int verbosity) -{ - runner->nfailures++; - if (verbosity >= CK_VERBOSE) { - printf("%s:%d: %s\n", _check_current_filename, - _check_current_lineno, _check_current_function); - } -} - -void -srunner_run_all(SRunner *runner, int verbosity) -{ - Suite *suite; - TCase *tc; - assert(runner != NULL); - suite = runner->suite; - tc = suite->tests; - while (tc != NULL) { - int i; - for (i = 0; i < tc->ntests; ++i) { - runner->nchecks++; - - if (tc->setup != NULL) { - /* setup */ - if (setjmp(env)) { - add_failure(runner, verbosity); - continue; - } - tc->setup(); - } - /* test */ - if (setjmp(env)) { - add_failure(runner, verbosity); - continue; - } - (tc->tests[i])(); - - /* teardown */ - if (tc->teardown != NULL) { - if (setjmp(env)) { - add_failure(runner, verbosity); - continue; - } - tc->teardown(); - } - } - tc = tc->next_tcase; - } - if (verbosity) { - int passed = runner->nchecks - runner->nfailures; - double percentage = ((double) passed) / runner->nchecks; - int display = (int) (percentage * 100); - printf("%d%%: Checks: %d, Failed: %d\n", - display, runner->nchecks, runner->nfailures); - } -} - -void -_fail_unless(int condition, const char *file, int line, char *msg) -{ - /* Always print the error message so it isn't lost. In this case, - we have a failure, so there's no reason to be quiet about what - it is. - */ - if (msg != NULL) - printf("%s", msg); - longjmp(env, 1); -} - -int -srunner_ntests_failed(SRunner *runner) -{ - assert(runner != NULL); - return runner->nfailures; -} - -void -srunner_free(SRunner *runner) -{ - free(runner->suite); - free(runner); -} diff --git a/lib-src/expat/tests/minicheck.h b/lib-src/expat/tests/minicheck.h deleted file mode 100644 index c917c0269..000000000 --- a/lib-src/expat/tests/minicheck.h +++ /dev/null @@ -1,90 +0,0 @@ -/* Miniature re-implementation of the "check" library. - * - * This is intended to support just enough of check to run the Expat - * tests. This interface is based entirely on the portion of the - * check library being used. - * - * This is *source* compatible, but not necessary *link* compatible. - */ - -#ifdef __cplusplus -extern "C" { -#endif - -#define CK_NOFORK 0 -#define CK_FORK 1 - -#define CK_SILENT 0 -#define CK_NORMAL 1 -#define CK_VERBOSE 2 - -/* Workaround for Microsoft's compiler and Tru64 Unix systems where the - C compiler has a working __func__, but the C++ compiler only has a - working __FUNCTION__. This could be fixed in configure.in, but it's - not worth it right now. */ -#if defined (_MSC_VER) || (defined(__osf__) && defined(__cplusplus)) -#define __func__ __FUNCTION__ -#endif - -#define START_TEST(testname) static void testname(void) { \ - _check_set_test_info(__func__, __FILE__, __LINE__); \ - { -#define END_TEST } } - -#define fail(msg) _fail_unless(0, __FILE__, __LINE__, msg) - -typedef void (*tcase_setup_function)(void); -typedef void (*tcase_teardown_function)(void); -typedef void (*tcase_test_function)(void); - -typedef struct SRunner SRunner; -typedef struct Suite Suite; -typedef struct TCase TCase; - -struct SRunner { - Suite *suite; - int nchecks; - int nfailures; -}; - -struct Suite { - char *name; - TCase *tests; -}; - -struct TCase { - char *name; - tcase_setup_function setup; - tcase_teardown_function teardown; - tcase_test_function *tests; - int ntests; - int allocated; - TCase *next_tcase; -}; - - -/* Internal helper. */ -void _check_set_test_info(char const *function, - char const *filename, int lineno); - - -/* - * Prototypes for the actual implementation. - */ - -void _fail_unless(int condition, const char *file, int line, char *msg); -Suite *suite_create(char *name); -TCase *tcase_create(char *name); -void suite_add_tcase(Suite *suite, TCase *tc); -void tcase_add_checked_fixture(TCase *, - tcase_setup_function, - tcase_teardown_function); -void tcase_add_test(TCase *tc, tcase_test_function test); -SRunner *srunner_create(Suite *suite); -void srunner_run_all(SRunner *runner, int verbosity); -int srunner_ntests_failed(SRunner *runner); -void srunner_free(SRunner *runner); - -#ifdef __cplusplus -} -#endif diff --git a/lib-src/expat/tests/runtests.c b/lib-src/expat/tests/runtests.c deleted file mode 100644 index 614d6b248..000000000 --- a/lib-src/expat/tests/runtests.c +++ /dev/null @@ -1,1515 +0,0 @@ -/* Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. - - runtest.c : run the Expat test suite -*/ - -#ifdef HAVE_EXPAT_CONFIG_H -#include -#endif - -#include -#include -#include -#include -#include - -#include "expat.h" -#include "chardata.h" -#include "minicheck.h" - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -#ifdef XML_LARGE_SIZE -#define XML_FMT_INT_MOD "ll" -#else -#define XML_FMT_INT_MOD "l" -#endif - -static XML_Parser parser; - - -static void -basic_setup(void) -{ - parser = XML_ParserCreate(NULL); - if (parser == NULL) - fail("Parser not created."); -} - -static void -basic_teardown(void) -{ - if (parser != NULL) - XML_ParserFree(parser); -} - -/* Generate a failure using the parser state to create an error message; - this should be used when the parser reports an error we weren't - expecting. -*/ -static void -_xml_failure(XML_Parser parser, const char *file, int line) -{ - char buffer[1024]; - enum XML_Error err = XML_GetErrorCode(parser); - sprintf(buffer, - " %d: %s (line %" XML_FMT_INT_MOD "u, offset %"\ - XML_FMT_INT_MOD "u)\n reported from %s, line %d\n", - err, - XML_ErrorString(err), - XML_GetCurrentLineNumber(parser), - XML_GetCurrentColumnNumber(parser), - file, line); - _fail_unless(0, file, line, buffer); -} - -#define xml_failure(parser) _xml_failure((parser), __FILE__, __LINE__) - -static void -_expect_failure(char *text, enum XML_Error errorCode, char *errorMessage, - char *file, int lineno) -{ - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_OK) - /* Hackish use of _fail_unless() macro, but let's us report - the right filename and line number. */ - _fail_unless(0, file, lineno, errorMessage); - if (XML_GetErrorCode(parser) != errorCode) - _xml_failure(parser, file, lineno); -} - -#define expect_failure(text, errorCode, errorMessage) \ - _expect_failure((text), (errorCode), (errorMessage), \ - __FILE__, __LINE__) - -/* Dummy handlers for when we need to set a handler to tickle a bug, - but it doesn't need to do anything. -*/ - -static void XMLCALL -dummy_start_doctype_handler(void *userData, - const XML_Char *doctypeName, - const XML_Char *sysid, - const XML_Char *pubid, - int has_internal_subset) -{} - -static void XMLCALL -dummy_end_doctype_handler(void *userData) -{} - -static void XMLCALL -dummy_entity_decl_handler(void *userData, - const XML_Char *entityName, - int is_parameter_entity, - const XML_Char *value, - int value_length, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName) -{} - -static void XMLCALL -dummy_notation_decl_handler(void *userData, - const XML_Char *notationName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{} - -static void XMLCALL -dummy_element_decl_handler(void *userData, - const XML_Char *name, - XML_Content *model) -{} - -static void XMLCALL -dummy_attlist_decl_handler(void *userData, - const XML_Char *elname, - const XML_Char *attname, - const XML_Char *att_type, - const XML_Char *dflt, - int isrequired) -{} - -static void XMLCALL -dummy_comment_handler(void *userData, const XML_Char *data) -{} - -static void XMLCALL -dummy_pi_handler(void *userData, const XML_Char *target, const XML_Char *data) -{} - -static void XMLCALL -dummy_start_element(void *userData, - const XML_Char *name, const XML_Char **atts) -{} - - -/* - * Character & encoding tests. - */ - -START_TEST(test_nul_byte) -{ - char text[] = "\0"; - - /* test that a NUL byte (in US-ASCII data) is an error */ - if (XML_Parse(parser, text, sizeof(text) - 1, XML_TRUE) == XML_STATUS_OK) - fail("Parser did not report error on NUL-byte."); - if (XML_GetErrorCode(parser) != XML_ERROR_INVALID_TOKEN) - xml_failure(parser); -} -END_TEST - - -START_TEST(test_u0000_char) -{ - /* test that a NUL byte (in US-ASCII data) is an error */ - expect_failure("", - XML_ERROR_BAD_CHAR_REF, - "Parser did not report error on NUL-byte."); -} -END_TEST - -START_TEST(test_bom_utf8) -{ - /* This test is really just making sure we don't core on a UTF-8 BOM. */ - char *text = "\357\273\277"; - - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -START_TEST(test_bom_utf16_be) -{ - char text[] = "\376\377\0<\0e\0/\0>"; - - if (XML_Parse(parser, text, sizeof(text)-1, XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -START_TEST(test_bom_utf16_le) -{ - char text[] = "\377\376<\0e\0/\0>\0"; - - if (XML_Parse(parser, text, sizeof(text)-1, XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -static void XMLCALL -accumulate_characters(void *userData, const XML_Char *s, int len) -{ - CharData_AppendXMLChars((CharData *)userData, s, len); -} - -static void XMLCALL -accumulate_attribute(void *userData, const XML_Char *name, - const XML_Char **atts) -{ - CharData *storage = (CharData *)userData; - if (storage->count < 0 && atts != NULL && atts[0] != NULL) { - /* "accumulate" the value of the first attribute we see */ - CharData_AppendXMLChars(storage, atts[1], -1); - } -} - - -static void -_run_character_check(XML_Char *text, XML_Char *expected, - const char *file, int line) -{ - CharData storage; - - CharData_Init(&storage); - XML_SetUserData(parser, &storage); - XML_SetCharacterDataHandler(parser, accumulate_characters); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - _xml_failure(parser, file, line); - CharData_CheckXMLChars(&storage, expected); -} - -#define run_character_check(text, expected) \ - _run_character_check(text, expected, __FILE__, __LINE__) - -static void -_run_attribute_check(XML_Char *text, XML_Char *expected, - const char *file, int line) -{ - CharData storage; - - CharData_Init(&storage); - XML_SetUserData(parser, &storage); - XML_SetStartElementHandler(parser, accumulate_attribute); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - _xml_failure(parser, file, line); - CharData_CheckXMLChars(&storage, expected); -} - -#define run_attribute_check(text, expected) \ - _run_attribute_check(text, expected, __FILE__, __LINE__) - -/* Regression test for SF bug #491986. */ -START_TEST(test_danish_latin1) -{ - char *text = - "\n" - "J\xF8rgen \xE6\xF8\xE5\xC6\xD8\xC5"; - run_character_check(text, - "J\xC3\xB8rgen \xC3\xA6\xC3\xB8\xC3\xA5\xC3\x86\xC3\x98\xC3\x85"); -} -END_TEST - - -/* Regression test for SF bug #514281. */ -START_TEST(test_french_charref_hexidecimal) -{ - char *text = - "\n" - "éèàçêÈ"; - run_character_check(text, - "\xC3\xA9\xC3\xA8\xC3\xA0\xC3\xA7\xC3\xAA\xC3\x88"); -} -END_TEST - -START_TEST(test_french_charref_decimal) -{ - char *text = - "\n" - "éèàçêÈ"; - run_character_check(text, - "\xC3\xA9\xC3\xA8\xC3\xA0\xC3\xA7\xC3\xAA\xC3\x88"); -} -END_TEST - -START_TEST(test_french_latin1) -{ - char *text = - "\n" - "\xE9\xE8\xE0\xE7\xEa\xC8"; - run_character_check(text, - "\xC3\xA9\xC3\xA8\xC3\xA0\xC3\xA7\xC3\xAA\xC3\x88"); -} -END_TEST - -START_TEST(test_french_utf8) -{ - char *text = - "\n" - "\xC3\xA9"; - run_character_check(text, "\xC3\xA9"); -} -END_TEST - -/* Regression test for SF bug #600479. - XXX There should be a test that exercises all legal XML Unicode - characters as PCDATA and attribute value content, and XML Name - characters as part of element and attribute names. -*/ -START_TEST(test_utf8_false_rejection) -{ - char *text = "\xEF\xBA\xBF"; - run_character_check(text, "\xEF\xBA\xBF"); -} -END_TEST - -/* Regression test for SF bug #477667. - This test assures that any 8-bit character followed by a 7-bit - character will not be mistakenly interpreted as a valid UTF-8 - sequence. -*/ -START_TEST(test_illegal_utf8) -{ - char text[100]; - int i; - - for (i = 128; i <= 255; ++i) { - sprintf(text, "%ccd", i); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_OK) { - sprintf(text, - "expected token error for '%c' (ordinal %d) in UTF-8 text", - i, i); - fail(text); - } - else if (XML_GetErrorCode(parser) != XML_ERROR_INVALID_TOKEN) - xml_failure(parser); - /* Reset the parser since we use the same parser repeatedly. */ - XML_ParserReset(parser, NULL); - } -} -END_TEST - -START_TEST(test_utf16) -{ - /* - some text - */ - char text[] = - "\000<\000?\000x\000m\000\154\000 \000v\000e\000r\000s\000i\000o" - "\000n\000=\000'\0001\000.\000\060\000'\000 \000e\000n\000c\000o" - "\000d\000i\000n\000g\000=\000'\000U\000T\000F\000-\0001\000\066" - "\000'\000?\000>\000\n" - "\000<\000d\000o\000c\000 \000a\000=\000'\0001\0002\0003\000'" - "\000>\000s\000o\000m\000e\000 \000t\000e\000x\000t\000<\000/" - "\000d\000o\000c\000>"; - if (XML_Parse(parser, text, sizeof(text)-1, XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -START_TEST(test_utf16_le_epilog_newline) -{ - unsigned int first_chunk_bytes = 17; - char text[] = - "\xFF\xFE" /* BOM */ - "<\000e\000/\000>\000" /* document element */ - "\r\000\n\000\r\000\n\000"; /* epilog */ - - if (first_chunk_bytes >= sizeof(text) - 1) - fail("bad value of first_chunk_bytes"); - if ( XML_Parse(parser, text, first_chunk_bytes, XML_FALSE) - == XML_STATUS_ERROR) - xml_failure(parser); - else { - enum XML_Status rc; - rc = XML_Parse(parser, text + first_chunk_bytes, - sizeof(text) - first_chunk_bytes - 1, XML_TRUE); - if (rc == XML_STATUS_ERROR) - xml_failure(parser); - } -} -END_TEST - -/* Regression test for SF bug #481609, #774028. */ -START_TEST(test_latin1_umlauts) -{ - char *text = - "\n" - "\xE4 \xF6 \xFC ä ö ü ä ö ü >"; - char *utf8 = - "\xC3\xA4 \xC3\xB6 \xC3\xBC " - "\xC3\xA4 \xC3\xB6 \xC3\xBC " - "\xC3\xA4 \xC3\xB6 \xC3\xBC >"; - run_character_check(text, utf8); - XML_ParserReset(parser, NULL); - run_attribute_check(text, utf8); -} -END_TEST - -/* Regression test #1 for SF bug #653180. */ -START_TEST(test_line_number_after_parse) -{ - char *text = - "\n" - "\n" - "\n"; - XML_Size lineno; - - if (XML_Parse(parser, text, strlen(text), XML_FALSE) == XML_STATUS_ERROR) - xml_failure(parser); - lineno = XML_GetCurrentLineNumber(parser); - if (lineno != 4) { - char buffer[100]; - sprintf(buffer, - "expected 4 lines, saw %" XML_FMT_INT_MOD "u", lineno); - fail(buffer); - } -} -END_TEST - -/* Regression test #2 for SF bug #653180. */ -START_TEST(test_column_number_after_parse) -{ - char *text = ""; - XML_Size colno; - - if (XML_Parse(parser, text, strlen(text), XML_FALSE) == XML_STATUS_ERROR) - xml_failure(parser); - colno = XML_GetCurrentColumnNumber(parser); - if (colno != 11) { - char buffer[100]; - sprintf(buffer, - "expected 11 columns, saw %" XML_FMT_INT_MOD "u", colno); - fail(buffer); - } -} -END_TEST - -static void XMLCALL -start_element_event_handler2(void *userData, const XML_Char *name, - const XML_Char **attr) -{ - CharData *storage = (CharData *) userData; - char buffer[100]; - - sprintf(buffer, - "<%s> at col:%" XML_FMT_INT_MOD "u line:%"\ - XML_FMT_INT_MOD "u\n", name, - XML_GetCurrentColumnNumber(parser), - XML_GetCurrentLineNumber(parser)); - CharData_AppendString(storage, buffer); -} - -static void XMLCALL -end_element_event_handler2(void *userData, const XML_Char *name) -{ - CharData *storage = (CharData *) userData; - char buffer[100]; - - sprintf(buffer, - " at col:%" XML_FMT_INT_MOD "u line:%"\ - XML_FMT_INT_MOD "u\n", name, - XML_GetCurrentColumnNumber(parser), - XML_GetCurrentLineNumber(parser)); - CharData_AppendString(storage, buffer); -} - -/* Regression test #3 for SF bug #653180. */ -START_TEST(test_line_and_column_numbers_inside_handlers) -{ - char *text = - "\n" /* Unix end-of-line */ - " \r\n" /* Windows end-of-line */ - " \r" /* Mac OS end-of-line */ - " \n" - " \n" - " \n" - " \n" - ""; - char *expected = - " at col:0 line:1\n" - " at col:2 line:2\n" - " at col:4 line:3\n" - " at col:8 line:3\n" - " at col:2 line:4\n" - " at col:2 line:5\n" - " at col:4 line:6\n" - " at col:8 line:6\n" - " at col:2 line:7\n" - " at col:0 line:8\n"; - CharData storage; - - CharData_Init(&storage); - XML_SetUserData(parser, &storage); - XML_SetStartElementHandler(parser, start_element_event_handler2); - XML_SetEndElementHandler(parser, end_element_event_handler2); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); - - CharData_CheckString(&storage, expected); -} -END_TEST - -/* Regression test #4 for SF bug #653180. */ -START_TEST(test_line_number_after_error) -{ - char *text = - "\n" - " \n" - " "; /* missing */ - XML_Size lineno; - if (XML_Parse(parser, text, strlen(text), XML_FALSE) != XML_STATUS_ERROR) - fail("Expected a parse error"); - - lineno = XML_GetCurrentLineNumber(parser); - if (lineno != 3) { - char buffer[100]; - sprintf(buffer, "expected 3 lines, saw %" XML_FMT_INT_MOD "u", lineno); - fail(buffer); - } -} -END_TEST - -/* Regression test #5 for SF bug #653180. */ -START_TEST(test_column_number_after_error) -{ - char *text = - "\n" - " \n" - " "; /* missing */ - XML_Size colno; - if (XML_Parse(parser, text, strlen(text), XML_FALSE) != XML_STATUS_ERROR) - fail("Expected a parse error"); - - colno = XML_GetCurrentColumnNumber(parser); - if (colno != 4) { - char buffer[100]; - sprintf(buffer, - "expected 4 columns, saw %" XML_FMT_INT_MOD "u", colno); - fail(buffer); - } -} -END_TEST - -/* Regression test for SF bug #478332. */ -START_TEST(test_really_long_lines) -{ - /* This parses an input line longer than INIT_DATA_BUF_SIZE - characters long (defined to be 1024 in xmlparse.c). We take a - really cheesy approach to building the input buffer, because - this avoids writing bugs in buffer-filling code. - */ - char *text = - "" - /* 64 chars */ - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - /* until we have at least 1024 characters on the line: */ - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-+" - ""; - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - - -/* - * Element event tests. - */ - -static void XMLCALL -end_element_event_handler(void *userData, const XML_Char *name) -{ - CharData *storage = (CharData *) userData; - CharData_AppendString(storage, "/"); - CharData_AppendXMLChars(storage, name, -1); -} - -START_TEST(test_end_element_events) -{ - char *text = ""; - char *expected = "/c/b/f/d/a"; - CharData storage; - - CharData_Init(&storage); - XML_SetUserData(parser, &storage); - XML_SetEndElementHandler(parser, end_element_event_handler); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); - CharData_CheckString(&storage, expected); -} -END_TEST - - -/* - * Attribute tests. - */ - -/* Helpers used by the following test; this checks any "attr" and "refs" - attributes to make sure whitespace has been normalized. - - Return true if whitespace has been normalized in a string, using - the rules for attribute value normalization. The 'is_cdata' flag - is needed since CDATA attributes don't need to have multiple - whitespace characters collapsed to a single space, while other - attribute data types do. (Section 3.3.3 of the recommendation.) -*/ -static int -is_whitespace_normalized(const XML_Char *s, int is_cdata) -{ - int blanks = 0; - int at_start = 1; - while (*s) { - if (*s == ' ') - ++blanks; - else if (*s == '\t' || *s == '\n' || *s == '\r') - return 0; - else { - if (at_start) { - at_start = 0; - if (blanks && !is_cdata) - /* illegal leading blanks */ - return 0; - } - else if (blanks > 1 && !is_cdata) - return 0; - blanks = 0; - } - ++s; - } - if (blanks && !is_cdata) - return 0; - return 1; -} - -/* Check the attribute whitespace checker: */ -static void -testhelper_is_whitespace_normalized(void) -{ - assert(is_whitespace_normalized("abc", 0)); - assert(is_whitespace_normalized("abc", 1)); - assert(is_whitespace_normalized("abc def ghi", 0)); - assert(is_whitespace_normalized("abc def ghi", 1)); - assert(!is_whitespace_normalized(" abc def ghi", 0)); - assert(is_whitespace_normalized(" abc def ghi", 1)); - assert(!is_whitespace_normalized("abc def ghi", 0)); - assert(is_whitespace_normalized("abc def ghi", 1)); - assert(!is_whitespace_normalized("abc def ghi ", 0)); - assert(is_whitespace_normalized("abc def ghi ", 1)); - assert(!is_whitespace_normalized(" ", 0)); - assert(is_whitespace_normalized(" ", 1)); - assert(!is_whitespace_normalized("\t", 0)); - assert(!is_whitespace_normalized("\t", 1)); - assert(!is_whitespace_normalized("\n", 0)); - assert(!is_whitespace_normalized("\n", 1)); - assert(!is_whitespace_normalized("\r", 0)); - assert(!is_whitespace_normalized("\r", 1)); - assert(!is_whitespace_normalized("abc\t def", 1)); -} - -static void XMLCALL -check_attr_contains_normalized_whitespace(void *userData, - const XML_Char *name, - const XML_Char **atts) -{ - int i; - for (i = 0; atts[i] != NULL; i += 2) { - const XML_Char *attrname = atts[i]; - const XML_Char *value = atts[i + 1]; - if (strcmp("attr", attrname) == 0 - || strcmp("ents", attrname) == 0 - || strcmp("refs", attrname) == 0) { - if (!is_whitespace_normalized(value, 0)) { - char buffer[256]; - sprintf(buffer, "attribute value not normalized: %s='%s'", - attrname, value); - fail(buffer); - } - } - } -} - -START_TEST(test_attr_whitespace_normalization) -{ - char *text = - "\n" - "]>\n" - "\n" - " \n" - " \n" - ""; - - XML_SetStartElementHandler(parser, - check_attr_contains_normalized_whitespace); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - - -/* - * XML declaration tests. - */ - -START_TEST(test_xmldecl_misplaced) -{ - expect_failure("\n" - "\n" - "", - XML_ERROR_MISPLACED_XML_PI, - "failed to report misplaced XML declaration"); -} -END_TEST - -/* Regression test for SF bug #584832. */ -static int XMLCALL -UnknownEncodingHandler(void *data,const XML_Char *encoding,XML_Encoding *info) -{ - if (strcmp(encoding,"unsupported-encoding") == 0) { - int i; - for (i = 0; i < 256; ++i) - info->map[i] = i; - info->data = NULL; - info->convert = NULL; - info->release = NULL; - return XML_STATUS_OK; - } - return XML_STATUS_ERROR; -} - -START_TEST(test_unknown_encoding_internal_entity) -{ - char *text = - "\n" - "]>\n" - ""; - - XML_SetUnknownEncodingHandler(parser, UnknownEncodingHandler, NULL); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Regression test for SF bug #620106. */ -static int XMLCALL -external_entity_loader_set_encoding(XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - /* This text says it's an unsupported encoding, but it's really - UTF-8, which we tell Expat using XML_SetEncoding(). - */ - char *text = - "" - "\xC3\xA9"; - XML_Parser extparser; - - extparser = XML_ExternalEntityParserCreate(parser, context, NULL); - if (extparser == NULL) - fail("Could not create external entity parser."); - if (!XML_SetEncoding(extparser, "utf-8")) - fail("XML_SetEncoding() ignored for external entity"); - if ( XML_Parse(extparser, text, strlen(text), XML_TRUE) - == XML_STATUS_ERROR) { - xml_failure(parser); - return 0; - } - return 1; -} - -START_TEST(test_ext_entity_set_encoding) -{ - char *text = - "\n" - "]>\n" - "&en;"; - - XML_SetExternalEntityRefHandler(parser, - external_entity_loader_set_encoding); - run_character_check(text, "\xC3\xA9"); -} -END_TEST - -/* Test that no error is reported for unknown entities if we don't - read an external subset. This was fixed in Expat 1.95.5. -*/ -START_TEST(test_wfc_undeclared_entity_unread_external_subset) { - char *text = - "\n" - "&entity;"; - - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Test that an error is reported for unknown entities if we don't - have an external subset. -*/ -START_TEST(test_wfc_undeclared_entity_no_external_subset) { - expect_failure("&entity;", - XML_ERROR_UNDEFINED_ENTITY, - "Parser did not report undefined entity w/out a DTD."); -} -END_TEST - -/* Test that an error is reported for unknown entities if we don't - read an external subset, but have been declared standalone. -*/ -START_TEST(test_wfc_undeclared_entity_standalone) { - char *text = - "\n" - "\n" - "&entity;"; - - expect_failure(text, - XML_ERROR_UNDEFINED_ENTITY, - "Parser did not report undefined entity (standalone)."); -} -END_TEST - -static int XMLCALL -external_entity_loader(XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - char *text = (char *)XML_GetUserData(parser); - XML_Parser extparser; - - extparser = XML_ExternalEntityParserCreate(parser, context, NULL); - if (extparser == NULL) - fail("Could not create external entity parser."); - if ( XML_Parse(extparser, text, strlen(text), XML_TRUE) - == XML_STATUS_ERROR) { - xml_failure(parser); - return XML_STATUS_ERROR; - } - return XML_STATUS_OK; -} - -/* Test that an error is reported for unknown entities if we have read - an external subset, and standalone is true. -*/ -START_TEST(test_wfc_undeclared_entity_with_external_subset_standalone) { - char *text = - "\n" - "\n" - "&entity;"; - char *foo_text = - ""; - - XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); - XML_SetUserData(parser, foo_text); - XML_SetExternalEntityRefHandler(parser, external_entity_loader); - expect_failure(text, - XML_ERROR_UNDEFINED_ENTITY, - "Parser did not report undefined entity (external DTD)."); -} -END_TEST - -/* Test that no error is reported for unknown entities if we have read - an external subset, and standalone is false. -*/ -START_TEST(test_wfc_undeclared_entity_with_external_subset) { - char *text = - "\n" - "\n" - "&entity;"; - char *foo_text = - ""; - - XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); - XML_SetUserData(parser, foo_text); - XML_SetExternalEntityRefHandler(parser, external_entity_loader); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -START_TEST(test_wfc_no_recursive_entity_refs) -{ - char *text = - "\n" - "]>\n" - "&entity;"; - - expect_failure(text, - XML_ERROR_RECURSIVE_ENTITY_REF, - "Parser did not report recursive entity reference."); -} -END_TEST - -/* Regression test for SF bug #483514. */ -START_TEST(test_dtd_default_handling) -{ - char *text = - "\n" - "\n" - "\n" - "\n" - "\n" - "\n" - "]>"; - - XML_SetDefaultHandler(parser, accumulate_characters); - XML_SetDoctypeDeclHandler(parser, - dummy_start_doctype_handler, - dummy_end_doctype_handler); - XML_SetEntityDeclHandler(parser, dummy_entity_decl_handler); - XML_SetNotationDeclHandler(parser, dummy_notation_decl_handler); - XML_SetElementDeclHandler(parser, dummy_element_decl_handler); - XML_SetAttlistDeclHandler(parser, dummy_attlist_decl_handler); - XML_SetProcessingInstructionHandler(parser, dummy_pi_handler); - XML_SetCommentHandler(parser, dummy_comment_handler); - run_character_check(text, "\n\n\n\n\n\n\n"); -} -END_TEST - -/* See related SF bug #673791. - When namespace processing is enabled, setting the namespace URI for - a prefix is not allowed; this test ensures that it *is* allowed - when namespace processing is not enabled. - (See Namespaces in XML, section 2.) -*/ -START_TEST(test_empty_ns_without_namespaces) -{ - char *text = - "\n" - " \n" - ""; - - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Regression test for SF bug #824420. - Checks that an xmlns:prefix attribute set in an attribute's default - value isn't misinterpreted. -*/ -START_TEST(test_ns_in_attribute_default_without_namespaces) -{ - char *text = - "\n" - " ]>\n" - ""; - - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -static char *long_character_data_text = - "" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - "012345678901234567890123456789012345678901234567890123456789" - ""; - -static XML_Bool resumable = XML_FALSE; - -static void -clearing_aborting_character_handler(void *userData, - const XML_Char *s, int len) -{ - XML_StopParser(parser, resumable); - XML_SetCharacterDataHandler(parser, NULL); -} - -/* Regression test for SF bug #1515266: missing check of stopped - parser in doContext() 'for' loop. */ -START_TEST(test_stop_parser_between_char_data_calls) -{ - /* The sample data must be big enough that there are two calls to - the character data handler from within the inner "for" loop of - the XML_TOK_DATA_CHARS case in doContent(), and the character - handler must stop the parser and clear the character data - handler. - */ - char *text = long_character_data_text; - - XML_SetCharacterDataHandler(parser, clearing_aborting_character_handler); - resumable = XML_FALSE; - if (XML_Parse(parser, text, strlen(text), XML_TRUE) != XML_STATUS_ERROR) - xml_failure(parser); - if (XML_GetErrorCode(parser) != XML_ERROR_ABORTED) - xml_failure(parser); -} -END_TEST - -/* Regression test for SF bug #1515266: missing check of stopped - parser in doContext() 'for' loop. */ -START_TEST(test_suspend_parser_between_char_data_calls) -{ - /* The sample data must be big enough that there are two calls to - the character data handler from within the inner "for" loop of - the XML_TOK_DATA_CHARS case in doContent(), and the character - handler must stop the parser and clear the character data - handler. - */ - char *text = long_character_data_text; - - XML_SetCharacterDataHandler(parser, clearing_aborting_character_handler); - resumable = XML_TRUE; - if (XML_Parse(parser, text, strlen(text), XML_TRUE) != XML_STATUS_SUSPENDED) - xml_failure(parser); - if (XML_GetErrorCode(parser) != XML_ERROR_NONE) - xml_failure(parser); -} -END_TEST - - -/* - * Namespaces tests. - */ - -static void -namespace_setup(void) -{ - parser = XML_ParserCreateNS(NULL, ' '); - if (parser == NULL) - fail("Parser not created."); -} - -static void -namespace_teardown(void) -{ - basic_teardown(); -} - -/* Check that an element name and attribute name match the expected values. - The expected values are passed as an array reference of string pointers - provided as the userData argument; the first is the expected - element name, and the second is the expected attribute name. -*/ -static void XMLCALL -triplet_start_checker(void *userData, const XML_Char *name, - const XML_Char **atts) -{ - char **elemstr = (char **)userData; - char buffer[1024]; - if (strcmp(elemstr[0], name) != 0) { - sprintf(buffer, "unexpected start string: '%s'", name); - fail(buffer); - } - if (strcmp(elemstr[1], atts[0]) != 0) { - sprintf(buffer, "unexpected attribute string: '%s'", atts[0]); - fail(buffer); - } -} - -/* Check that the element name passed to the end-element handler matches - the expected value. The expected value is passed as the first element - in an array of strings passed as the userData argument. -*/ -static void XMLCALL -triplet_end_checker(void *userData, const XML_Char *name) -{ - char **elemstr = (char **)userData; - if (strcmp(elemstr[0], name) != 0) { - char buffer[1024]; - sprintf(buffer, "unexpected end string: '%s'", name); - fail(buffer); - } -} - -START_TEST(test_return_ns_triplet) -{ - char *text = - ""; - char *elemstr[] = { - "http://expat.sf.net/ e foo", - "http://expat.sf.net/ a bar" - }; - XML_SetReturnNSTriplet(parser, XML_TRUE); - XML_SetUserData(parser, elemstr); - XML_SetElementHandler(parser, triplet_start_checker, triplet_end_checker); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -static void XMLCALL -overwrite_start_checker(void *userData, const XML_Char *name, - const XML_Char **atts) -{ - CharData *storage = (CharData *) userData; - CharData_AppendString(storage, "start "); - CharData_AppendXMLChars(storage, name, -1); - while (*atts != NULL) { - CharData_AppendString(storage, "\nattribute "); - CharData_AppendXMLChars(storage, *atts, -1); - atts += 2; - } - CharData_AppendString(storage, "\n"); -} - -static void XMLCALL -overwrite_end_checker(void *userData, const XML_Char *name) -{ - CharData *storage = (CharData *) userData; - CharData_AppendString(storage, "end "); - CharData_AppendXMLChars(storage, name, -1); - CharData_AppendString(storage, "\n"); -} - -static void -run_ns_tagname_overwrite_test(char *text, char *result) -{ - CharData storage; - CharData_Init(&storage); - XML_SetUserData(parser, &storage); - XML_SetElementHandler(parser, - overwrite_start_checker, overwrite_end_checker); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); - CharData_CheckString(&storage, result); -} - -/* Regression test for SF bug #566334. */ -START_TEST(test_ns_tagname_overwrite) -{ - char *text = - "\n" - " \n" - " \n" - ""; - char *result = - "start http://xml.libexpat.org/ e\n" - "start http://xml.libexpat.org/ f\n" - "attribute http://xml.libexpat.org/ attr\n" - "end http://xml.libexpat.org/ f\n" - "start http://xml.libexpat.org/ g\n" - "attribute http://xml.libexpat.org/ attr2\n" - "end http://xml.libexpat.org/ g\n" - "end http://xml.libexpat.org/ e\n"; - run_ns_tagname_overwrite_test(text, result); -} -END_TEST - -/* Regression test for SF bug #566334. */ -START_TEST(test_ns_tagname_overwrite_triplet) -{ - char *text = - "\n" - " \n" - " \n" - ""; - char *result = - "start http://xml.libexpat.org/ e n\n" - "start http://xml.libexpat.org/ f n\n" - "attribute http://xml.libexpat.org/ attr n\n" - "end http://xml.libexpat.org/ f n\n" - "start http://xml.libexpat.org/ g n\n" - "attribute http://xml.libexpat.org/ attr2 n\n" - "end http://xml.libexpat.org/ g n\n" - "end http://xml.libexpat.org/ e n\n"; - XML_SetReturnNSTriplet(parser, XML_TRUE); - run_ns_tagname_overwrite_test(text, result); -} -END_TEST - - -/* Regression test for SF bug #620343. */ -static void XMLCALL -start_element_fail(void *userData, - const XML_Char *name, const XML_Char **atts) -{ - /* We should never get here. */ - fail("should never reach start_element_fail()"); -} - -static void XMLCALL -start_ns_clearing_start_element(void *userData, - const XML_Char *prefix, - const XML_Char *uri) -{ - XML_SetStartElementHandler((XML_Parser) userData, NULL); -} - -START_TEST(test_start_ns_clears_start_element) -{ - /* This needs to use separate start/end tags; using the empty tag - syntax doesn't cause the problematic path through Expat to be - taken. - */ - char *text = ""; - - XML_SetStartElementHandler(parser, start_element_fail); - XML_SetStartNamespaceDeclHandler(parser, start_ns_clearing_start_element); - XML_UseParserAsHandlerArg(parser); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Regression test for SF bug #616863. */ -static int XMLCALL -external_entity_handler(XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - intptr_t callno = 1 + (intptr_t)XML_GetUserData(parser); - char *text; - XML_Parser p2; - - if (callno == 1) - text = ("\n" - "\n" - "\n"); - else - text = ("" - ""); - - XML_SetUserData(parser, (void *) callno); - p2 = XML_ExternalEntityParserCreate(parser, context, NULL); - if (XML_Parse(p2, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) { - xml_failure(p2); - return 0; - } - XML_ParserFree(p2); - return 1; -} - -START_TEST(test_default_ns_from_ext_subset_and_ext_ge) -{ - char *text = - "\n" - "\n" - "]>\n" - "\n" - "&en;\n" - ""; - - XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); - XML_SetExternalEntityRefHandler(parser, external_entity_handler); - /* We actually need to set this handler to tickle this bug. */ - XML_SetStartElementHandler(parser, dummy_start_element); - XML_SetUserData(parser, NULL); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Regression test #1 for SF bug #673791. */ -START_TEST(test_ns_prefix_with_empty_uri_1) -{ - char *text = - "\n" - " \n" - ""; - - expect_failure(text, - XML_ERROR_UNDECLARING_PREFIX, - "Did not report re-setting namespace" - " URI with prefix to ''."); -} -END_TEST - -/* Regression test #2 for SF bug #673791. */ -START_TEST(test_ns_prefix_with_empty_uri_2) -{ - char *text = - "\n" - ""; - - expect_failure(text, - XML_ERROR_UNDECLARING_PREFIX, - "Did not report setting namespace URI with prefix to ''."); -} -END_TEST - -/* Regression test #3 for SF bug #673791. */ -START_TEST(test_ns_prefix_with_empty_uri_3) -{ - char *text = - "\n" - " \n" - "]>\n" - ""; - - expect_failure(text, - XML_ERROR_UNDECLARING_PREFIX, - "Didn't report attr default setting NS w/ prefix to ''."); -} -END_TEST - -/* Regression test #4 for SF bug #673791. */ -START_TEST(test_ns_prefix_with_empty_uri_4) -{ - char *text = - "\n" - " \n" - "]>\n" - ""; - /* Packaged info expected by the end element handler; - the weird structuring lets us re-use the triplet_end_checker() - function also used for another test. */ - char *elemstr[] = { - "http://xml.libexpat.org/ doc prefix" - }; - XML_SetReturnNSTriplet(parser, XML_TRUE); - XML_SetUserData(parser, elemstr); - XML_SetEndElementHandler(parser, triplet_end_checker); - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -START_TEST(test_ns_default_with_empty_uri) -{ - char *text = - "\n" - " \n" - ""; - if (XML_Parse(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) - xml_failure(parser); -} -END_TEST - -/* Regression test for SF bug #692964: two prefixes for one namespace. */ -START_TEST(test_ns_duplicate_attrs_diff_prefixes) -{ - char *text = - ""; - expect_failure(text, - XML_ERROR_DUPLICATE_ATTRIBUTE, - "did not report multiple attributes with same URI+name"); -} -END_TEST - -/* Regression test for SF bug #695401: unbound prefix. */ -START_TEST(test_ns_unbound_prefix_on_attribute) -{ - char *text = ""; - expect_failure(text, - XML_ERROR_UNBOUND_PREFIX, - "did not report unbound prefix on attribute"); -} -END_TEST - -/* Regression test for SF bug #695401: unbound prefix. */ -START_TEST(test_ns_unbound_prefix_on_element) -{ - char *text = ""; - expect_failure(text, - XML_ERROR_UNBOUND_PREFIX, - "did not report unbound prefix on element"); -} -END_TEST - -static Suite * -make_suite(void) -{ - Suite *s = suite_create("basic"); - TCase *tc_basic = tcase_create("basic tests"); - TCase *tc_namespace = tcase_create("XML namespaces"); - - suite_add_tcase(s, tc_basic); - tcase_add_checked_fixture(tc_basic, basic_setup, basic_teardown); - tcase_add_test(tc_basic, test_nul_byte); - tcase_add_test(tc_basic, test_u0000_char); - tcase_add_test(tc_basic, test_bom_utf8); - tcase_add_test(tc_basic, test_bom_utf16_be); - tcase_add_test(tc_basic, test_bom_utf16_le); - tcase_add_test(tc_basic, test_illegal_utf8); - tcase_add_test(tc_basic, test_utf16); - tcase_add_test(tc_basic, test_utf16_le_epilog_newline); - tcase_add_test(tc_basic, test_latin1_umlauts); - /* Regression test for SF bug #491986. */ - tcase_add_test(tc_basic, test_danish_latin1); - /* Regression test for SF bug #514281. */ - tcase_add_test(tc_basic, test_french_charref_hexidecimal); - tcase_add_test(tc_basic, test_french_charref_decimal); - tcase_add_test(tc_basic, test_french_latin1); - tcase_add_test(tc_basic, test_french_utf8); - tcase_add_test(tc_basic, test_utf8_false_rejection); - tcase_add_test(tc_basic, test_line_number_after_parse); - tcase_add_test(tc_basic, test_column_number_after_parse); - tcase_add_test(tc_basic, test_line_and_column_numbers_inside_handlers); - tcase_add_test(tc_basic, test_line_number_after_error); - tcase_add_test(tc_basic, test_column_number_after_error); - tcase_add_test(tc_basic, test_really_long_lines); - tcase_add_test(tc_basic, test_end_element_events); - tcase_add_test(tc_basic, test_attr_whitespace_normalization); - tcase_add_test(tc_basic, test_xmldecl_misplaced); - tcase_add_test(tc_basic, test_unknown_encoding_internal_entity); - tcase_add_test(tc_basic, - test_wfc_undeclared_entity_unread_external_subset); - tcase_add_test(tc_basic, test_wfc_undeclared_entity_no_external_subset); - tcase_add_test(tc_basic, test_wfc_undeclared_entity_standalone); - tcase_add_test(tc_basic, test_wfc_undeclared_entity_with_external_subset); - tcase_add_test(tc_basic, - test_wfc_undeclared_entity_with_external_subset_standalone); - tcase_add_test(tc_basic, test_wfc_no_recursive_entity_refs); - tcase_add_test(tc_basic, test_ext_entity_set_encoding); - tcase_add_test(tc_basic, test_dtd_default_handling); - tcase_add_test(tc_basic, test_empty_ns_without_namespaces); - tcase_add_test(tc_basic, test_ns_in_attribute_default_without_namespaces); - tcase_add_test(tc_basic, test_stop_parser_between_char_data_calls); - tcase_add_test(tc_basic, test_suspend_parser_between_char_data_calls); - - suite_add_tcase(s, tc_namespace); - tcase_add_checked_fixture(tc_namespace, - namespace_setup, namespace_teardown); - tcase_add_test(tc_namespace, test_return_ns_triplet); - tcase_add_test(tc_namespace, test_ns_tagname_overwrite); - tcase_add_test(tc_namespace, test_ns_tagname_overwrite_triplet); - tcase_add_test(tc_namespace, test_start_ns_clears_start_element); - tcase_add_test(tc_namespace, test_default_ns_from_ext_subset_and_ext_ge); - tcase_add_test(tc_namespace, test_ns_prefix_with_empty_uri_1); - tcase_add_test(tc_namespace, test_ns_prefix_with_empty_uri_2); - tcase_add_test(tc_namespace, test_ns_prefix_with_empty_uri_3); - tcase_add_test(tc_namespace, test_ns_prefix_with_empty_uri_4); - tcase_add_test(tc_namespace, test_ns_default_with_empty_uri); - tcase_add_test(tc_namespace, test_ns_duplicate_attrs_diff_prefixes); - tcase_add_test(tc_namespace, test_ns_unbound_prefix_on_attribute); - tcase_add_test(tc_namespace, test_ns_unbound_prefix_on_element); - - return s; -} - - -int -main(int argc, char *argv[]) -{ - int i, nf; - int verbosity = CK_NORMAL; - Suite *s = make_suite(); - SRunner *sr = srunner_create(s); - - /* run the tests for internal helper functions */ - testhelper_is_whitespace_normalized(); - - for (i = 1; i < argc; ++i) { - char *opt = argv[i]; - if (strcmp(opt, "-v") == 0 || strcmp(opt, "--verbose") == 0) - verbosity = CK_VERBOSE; - else if (strcmp(opt, "-q") == 0 || strcmp(opt, "--quiet") == 0) - verbosity = CK_SILENT; - else { - fprintf(stderr, "runtests: unknown option '%s'\n", opt); - return 2; - } - } - if (verbosity != CK_SILENT) - printf("Expat version: %s\n", XML_ExpatVersion()); - srunner_run_all(sr, verbosity); - nf = srunner_ntests_failed(sr); - srunner_free(sr); - - return (nf == 0) ? EXIT_SUCCESS : EXIT_FAILURE; -} diff --git a/lib-src/expat/tests/runtestspp.cpp b/lib-src/expat/tests/runtestspp.cpp deleted file mode 100644 index c35dc583d..000000000 --- a/lib-src/expat/tests/runtestspp.cpp +++ /dev/null @@ -1,6 +0,0 @@ -// C++ compilation harness for the test suite. -// -// This is used to ensure the Expat headers can be included from C++ -// and have everything work as expected. -// -#include "runtests.c" diff --git a/lib-src/expat/tests/xmltest.sh b/lib-src/expat/tests/xmltest.sh deleted file mode 100755 index 793a5cc28..000000000 --- a/lib-src/expat/tests/xmltest.sh +++ /dev/null @@ -1,142 +0,0 @@ -#! /bin/sh - -# EXPAT TEST SCRIPT FOR W3C XML TEST SUITE - -# This script can be used to exercise Expat against the -# w3c.org xml test suite, available from -# http://www.w3.org/XML/Test/xmlts20020606.zip. - -# To run this script, first set XMLWF below so that xmlwf can be -# found, then set the output directory with OUTPUT. - -# The script lists all test cases where Expat shows a discrepancy -# from the expected result. Test cases where only the canonical -# output differs are prefixed with "Output differs:", and a diff file -# is generated in the appropriate subdirectory under $OUTPUT. - -# If there are output files provided, the script will use -# output from xmlwf and compare the desired output against it. -# However, one has to take into account that the canonical output -# produced by xmlwf conforms to an older definition of canonical XML -# and does not generate notation declarations. - -MYDIR="`dirname \"$0\"`" -cd "$MYDIR" -MYDIR="`pwd`" -XMLWF="`dirname \"$MYDIR\"`/xmlwf/xmlwf" -# XMLWF=/usr/local/bin/xmlwf -TS="$MYDIR/XML-Test-Suite" -# OUTPUT must terminate with the directory separator. -OUTPUT="$TS/out/" -# OUTPUT=/home/tmp/xml-testsuite-out/ - - -# RunXmlwfNotWF file reldir -# reldir includes trailing slash -RunXmlwfNotWF() { - file="$1" - reldir="$2" - $XMLWF -p "$file" > outfile || return $? - read outdata < outfile - if test "$outdata" = "" ; then - echo "Expected not well-formed: $reldir$file" - return 1 - else - return 0 - fi -} - -# RunXmlwfWF file reldir -# reldir includes trailing slash -RunXmlwfWF() { - file="$1" - reldir="$2" - $XMLWF -p -d "$OUTPUT$reldir" "$file" > outfile || return $? - read outdata < outfile - if test "$outdata" = "" ; then - if [ -f "out/$file" ] ; then - diff -u "$OUTPUT$reldir$file" "out/$file" > outfile - if [ -s outfile ] ; then - cp outfile "$OUTPUT$reldir$file.diff" - echo "Output differs: $reldir$file" - return 1 - fi - fi - return 0 - else - echo "In $reldir: $outdata" - return 1 - fi -} - -SUCCESS=0 -ERROR=0 - -UpdateStatus() { - if [ "$1" -eq 0 ] ; then - SUCCESS=`expr $SUCCESS + 1` - else - ERROR=`expr $ERROR + 1` - fi -} - -########################## -# well-formed test cases # -########################## - -cd "$TS/xmlconf" -for xmldir in ibm/valid/P* \ - ibm/invalid/P* \ - xmltest/valid/ext-sa \ - xmltest/valid/not-sa \ - xmltest/invalid \ - xmltest/invalid/not-sa \ - xmltest/valid/sa \ - sun/valid \ - sun/invalid ; do - cd "$TS/xmlconf/$xmldir" - mkdir -p "$OUTPUT$xmldir" - for xmlfile in *.xml ; do - RunXmlwfWF "$xmlfile" "$xmldir/" - UpdateStatus $? - done - rm outfile -done - -cd "$TS/xmlconf/oasis" -mkdir -p "$OUTPUT"oasis -for xmlfile in *pass*.xml ; do - RunXmlwfWF "$xmlfile" "oasis/" - UpdateStatus $? -done -rm outfile - -############################## -# not well-formed test cases # -############################## - -cd "$TS/xmlconf" -for xmldir in ibm/not-wf/P* \ - ibm/not-wf/p28a \ - ibm/not-wf/misc \ - xmltest/not-wf/ext-sa \ - xmltest/not-wf/not-sa \ - xmltest/not-wf/sa \ - sun/not-wf ; do - cd "$TS/xmlconf/$xmldir" - for xmlfile in *.xml ; do - RunXmlwfNotWF "$xmlfile" "$xmldir/" - UpdateStatus $? - done - rm outfile -done - -cd "$TS/xmlconf/oasis" -for xmlfile in *fail*.xml ; do - RunXmlwfNotWF "$xmlfile" "oasis/" - UpdateStatus $? -done -rm outfile - -echo "Passed: $SUCCESS" -echo "Failed: $ERROR" diff --git a/lib-src/expat/vms/README.vms b/lib-src/expat/vms/README.vms deleted file mode 100644 index 3dd2ca73f..000000000 --- a/lib-src/expat/vms/README.vms +++ /dev/null @@ -1,23 +0,0 @@ -4-jun-2002 Craig A. Berry - Added rudimentary build procedures for - OpenVMS based on work by Martin Vorlaender. - - -You'll need MMS or its freeware equivalent MMK. Just go to the -top-level directory and type - -$ MMS/DESCRIPTION=[.vms] - - or - -$ MMK/DESCRIPTION=[.vms] - -You'll end up with the object library expat.olb. For now, installation -consists merely of copying the object library, include files, and -documentation to a suitable location. - -To-do list: - - -- create a shareable image - -- build and run the tests and build the xmlwf utility - -- create an install target diff --git a/lib-src/expat/vms/descrip.mms b/lib-src/expat/vms/descrip.mms deleted file mode 100644 index d9ee3d98e..000000000 --- a/lib-src/expat/vms/descrip.mms +++ /dev/null @@ -1,70 +0,0 @@ -# Bare bones description file (Makefile) for OpenVMS - -PACKAGE = expat -VERSION = 1.95.8 -EXPAT_MAJOR_VERSION=1 -EXPAT_MINOR_VERSION=95 -EXPAT_EDIT=8 - -O = .obj -OLB = .olb - -LIBRARY = expat$(OLB) -LIBDIR = [.lib] -SOURCES = $(LIBDIR)xmlparse.c $(LIBDIR)xmltok.c $(LIBDIR)xmlrole.c -OBJECTS = xmlparse$(O) xmltok$(O) xmlrole$(O) - -TEMPLATES = xmltok_impl.c xmltok_ns.c -APIHEADER = $(LIBDIR)expat.h -HEADERS = $(LIBDIR)ascii.h $(LIBDIR)iasciitab.h $(LIBDIR)utf8tab.h $(LIBDIR)xmltok.h \ - $(LIBDIR)asciitab.h $(LIBDIR)latin1tab.h \ - $(LIBDIR)nametab.h $(LIBDIR)xmldef.h $(LIBDIR)xmlrole.h $(LIBDIR)xmltok_impl.h - -CONFIG_HEADER = expat_config.h -INCLUDES = /INCLUDE=([],[.lib]) -DEFS = /DEFINE=(PACKAGE="""$(PACKAGE)""",VERSION="""$(PACKAGE)_$(VERSION)""",HAVE_EXPAT_CONFIG_H) -LIBREVISION = 0 -LIBCURRENT = 1 -LIBAGE = 0 -# -COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) -# -# DISTFILES = $(DIST_COMMON) $(SOURCES) $(TEMPLATES) $(APIHEADER) $(HEADERS) -# -# TAR = gtar -# GZIP_ENV = --best -# -.FIRST : - IF F$SEARCH("$(LIBRARY)") .EQS. "" THEN $(LIBR) /CREATE /OBJECT $(LIBRARY) - -all : $(LIBRARY) - @ write sys$output "All made." - -.SUFFIXES : -.SUFFIXES : $(OLB) $(O) .C .H - -.c$(O) : - $(COMPILE) $(MMS$SOURCE) - -$(O)$(OLB) : - @ IF F$SEARCH("$(MMS$TARGET)") .EQS. "" - - THEN LIBRARY/CREATE/LOG $(MMS$TARGET) - @ LIBRARY /REPLACE /LOG $(MMS$TARGET) $(MMS$SOURCE) - -clean : - DELETE $(LIBRARY);*,*$(O);* - -$(LIBRARY) : $(LIBRARY)( $(OBJECTS) ) - $(LIBR) /COMPRESS $(MMS$TARGET) - -$(CONFIG_HEADER) : [.vms]expat_config.h - COPY/LOG $(MMS$SOURCE) $(MMS$TARGET) - -xmlparse$(O) : $(LIBDIR)xmlparse.c $(LIBDIR)expat.h $(LIBDIR)xmlrole.h $(LIBDIR)xmltok.h $(CONFIG_HEADER) - -xmlrole$(O) : $(LIBDIR)xmlrole.c $(LIBDIR)ascii.h $(LIBDIR)xmlrole.h $(CONFIG_HEADER) - -xmltok$(O) : $(LIBDIR)xmltok.c $(LIBDIR)xmltok_impl.c $(LIBDIR)xmltok_ns.c \ - $(LIBDIR)ascii.h $(LIBDIR)asciitab.h $(LIBDIR)iasciitab.h $(LIBDIR)latin1tab.h \ - $(LIBDIR)nametab.h $(LIBDIR)utf8tab.h $(LIBDIR)xmltok.h $(LIBDIR)xmltok_impl.h $(CONFIG_HEADER) - diff --git a/lib-src/expat/vms/expat_config.h b/lib-src/expat/vms/expat_config.h deleted file mode 100644 index d5db89e56..000000000 --- a/lib-src/expat/vms/expat_config.h +++ /dev/null @@ -1,52 +0,0 @@ -/* Copyright 2000, Clark Cooper - All rights reserved. - - This is free software. You are permitted to copy, distribute, or modify - it under the terms of the MIT/X license (contained in the COPYING file - with this distribution.) -*/ - -/* Define to empty if the keyword does not work. */ -#undef const - -/* Define if you have a working `mmap' system call. */ -#undef HAVE_MMAP - -/* Define to `long' if doesn't define. */ -#undef off_t - -/* Define to `unsigned' if doesn't define. */ -#undef size_t - -/* Define if your processor stores words with the most significant - byte first (like Motorola and SPARC, unlike Intel and VAX). */ -#undef WORDS_BIGENDIAN - -/* Define if you have the bcopy function. */ -#undef HAVE_BCOPY - -/* Define if you have the memmove function. */ -#define HAVE_MEMMOVE 1 - -/* Define if you have the header file. */ -#define HAVE_UNISTD_H 1 - -#define XML_NS -#define XML_DTD - -#ifdef WORDS_BIGENDIAN -#define XML_BYTE_ORDER 21 -#else -#define XML_BYTE_ORDER 12 -#endif - -#define XML_CONTEXT_BYTES 1024 - -#ifndef HAVE_MEMMOVE -#ifdef HAVE_BCOPY -#define memmove(d,s,l) bcopy((s),(d),(l)) -#else -#define memmove(d,s,l) ;punting on memmove; -#endif - -#endif diff --git a/lib-src/expat/win32/MANIFEST.txt b/lib-src/expat/win32/MANIFEST.txt deleted file mode 100644 index b7cd39543..000000000 --- a/lib-src/expat/win32/MANIFEST.txt +++ /dev/null @@ -1,27 +0,0 @@ - Overview of the Expat distribution - -The Expat distribution creates several subdirectories on your system. -Some of these directories contain components of interest to all Expat -users, and some contain material of interest to developers who wish to -use Expat in their applications. In the list below, is the -directory you specified to the installer. - - Directory Contents - --------------------------------------------------------------------- - \ Some general information files. - - \Doc\ API documentation for developers. - - \Bin\ Pre-compiled dynamic libraries for developers. - Pre-compiled static libraries for developers (*MT.lib). - The XML well-formedness checker xmlwf. - - \Source\ Source code, which may interest some developers, - including a workspace for Microsft Visual C++. - The source code includes the parser, the well- - formedness checker, and a couple of small sample - applications. - - \Source\bcb5\ Project files for Borland C++ Builder 5 and BCC 5.5. - - diff --git a/lib-src/expat/win32/README.txt b/lib-src/expat/win32/README.txt deleted file mode 100644 index e3702ae62..000000000 --- a/lib-src/expat/win32/README.txt +++ /dev/null @@ -1,80 +0,0 @@ - -Expat can be built on Windows in three ways: - using MS Visual C++ (6.0 or .NET), Borland C++ Builder 5 or Cygwin. - -* Cygwin: - This follows the Unix build procedures. - -* C++ Builder 5: - Possible with make files in the BCB5 subdirectory. - Details can be found in the ReadMe file located there. - -* MS Visual C++ 6: - Based on the workspace file expat.dsw. The related project - files (.dsp) are located in the lib subdirectory. - -* MS Visual Studio .NET 2002, 2003, 2005, 2008, 2010: - The VC++ 6 workspace file (expat.dsw) and project files (.dsp) - can be opened and imported in VS.NET without problems. - -* All MS C/C++ compilers: - The output for all projects will be generated in the win32\bin - directory, intermediate files will be located in project-specific - subdirectories of win32\tmp. - -* Creating MinGW dynamic libraries from MS VC++ DLLs: - - On the command line, execute these steps: - pexports libexpat.dll > expat.def - pexports libexpatw.dll > expatw.def - dlltool -d expat.def -l libexpat.a - dlltool -d expatw.def -l libexpatw.a - - The *.a files are mingw libraries. - -* Special note about MS VC++ and runtime libraries: - - There are three possible configurations: using the - single threaded or multithreaded run-time library, - or using the multi-threaded run-time Dll. That is, - one can build three different Expat libraries depending - on the needs of the application. - - Dynamic Linking: - - By default the Expat Dlls are built to link statically - with the multi-threaded run-time library. - The libraries are named - - libexpat(w).dll - - libexpat(w).lib (import library) - The "w" indicates the UTF-16 version of the library. - - One rarely uses other versions of the Dll, but they can - be built easily by specifying a different RTL linkage in - the IDE on the C/C++ tab under the category Code Generation. - - Static Linking: - - The libraries should be named like this: - Single-theaded: libexpat(w)ML.lib - Multi-threaded: libexpat(w)MT.lib - Multi-threaded Dll: libexpat(w)MD.lib - The suffixes conform to the compiler switch settings - /ML, /MT and /MD for MS VC++. - - Note: In Visual Studio 2005 (Visual C++ 8.0) and later, the - single-threaded runtime library is not supported anymore. - - By default, the expat-static and expatw-static projects are set up - to link statically against the multithreaded run-time library, - so they will build libexpatMT.lib or libexpatwMT.lib files. - - To build the other versions of the static library, - go to Project - Settings: - - specify a different RTL linkage on the C/C++ tab - under the category Code Generation. - - then, on the Library tab, change the output file name - accordingly, as described above - - An application linking to the static libraries must - have the global macro XML_STATIC defined. diff --git a/lib-src/expat/win32/expat.iss b/lib-src/expat/win32/expat.iss deleted file mode 100644 index de5b6efdd..000000000 --- a/lib-src/expat/win32/expat.iss +++ /dev/null @@ -1,69 +0,0 @@ -; Basic setup script for the Inno Setup installer builder. For more -; information on the free installer builder, see www.jrsoftware.org. -; -; This script was contributed by Tim Peters. -; It was designed for Inno Setup 2.0.19 but works with later versions as well. - -[Setup] -AppName=Expat -AppId=expat -AppVersion=2.1.0 -AppVerName=Expat 2.1.0 -AppCopyright=Copyright © 1998-2012 Thai Open Source Software Center, Clark Cooper, and the Expat maintainers -AppPublisher=The Expat Developers -AppPublisherURL=http://www.libexpat.org/ -AppSupportURL=http://www.libexpat.org/ -AppUpdatesURL=http://www.libexpat.org/ -UninstallDisplayName=Expat XML Parser 2.1.0 -VersionInfoVersion=2.1.0 - -DefaultDirName={pf}\Expat 2.1.0 -UninstallFilesDir={app}\Uninstall - -Compression=lzma -SolidCompression=yes -SourceDir=.. -OutputDir=win32 -DisableStartupPrompt=yes -AllowNoIcons=yes -DisableProgramGroupPage=yes -DisableReadyPage=yes - -[Files] -Flags: ignoreversion; Source: win32\bin\Release\xmlwf.exe; DestDir: "{app}\Bin" -Flags: ignoreversion; Source: win32\MANIFEST.txt; DestDir: "{app}" -Flags: ignoreversion; Source: Changes; DestDir: "{app}"; DestName: Changes.txt -Flags: ignoreversion; Source: COPYING; DestDir: "{app}"; DestName: COPYING.txt -Flags: ignoreversion; Source: README; DestDir: "{app}"; DestName: README.txt -Flags: ignoreversion; Source: doc\*.html; DestDir: "{app}\Doc" -Flags: ignoreversion; Source: doc\*.css; DestDir: "{app}\Doc" -Flags: ignoreversion; Source: doc\*.png; DestDir: "{app}\Doc" -Flags: ignoreversion; Source: win32\bin\Release\*.dll; DestDir: "{app}\Bin" -Flags: ignoreversion; Source: win32\bin\Release\*.lib; DestDir: "{app}\Bin" -Flags: ignoreversion; Source: expat.dsw; DestDir: "{app}\Source" -Flags: ignoreversion; Source: win32\README.txt; DestDir: "{app}\Source" -Flags: ignoreversion; Source: bcb5\*.bp*; DestDir: "{app}\Source\bcb5" -Flags: ignoreversion; Source: bcb5\*.mak; DestDir: "{app}\Source\bcb5" -Flags: ignoreversion; Source: bcb5\*.def; DestDir: "{app}\Source\bcb5" -Flags: ignoreversion; Source: bcb5\*.txt; DestDir: "{app}\Source\bcb5" -Flags: ignoreversion; Source: bcb5\*.bat; DestDir: "{app}\Source\bcb5" -Flags: ignoreversion; Source: lib\*.c; DestDir: "{app}\Source\lib" -Flags: ignoreversion; Source: lib\*.h; DestDir: "{app}\Source\lib" -Flags: ignoreversion; Source: lib\*.def; DestDir: "{app}\Source\lib" -Flags: ignoreversion; Source: lib\*.dsp; DestDir: "{app}\Source\lib" -Flags: ignoreversion; Source: examples\*.c; DestDir: "{app}\Source\examples" -Flags: ignoreversion; Source: examples\*.dsp; DestDir: "{app}\Source\examples" -Flags: ignoreversion; Source: tests\*.c; DestDir: "{app}\Source\tests" -Flags: ignoreversion; Source: tests\*.cpp; DestDir: "{app}\Source\tests" -Flags: ignoreversion; Source: tests\*.h; DestDir: "{app}\Source\tests" -Flags: ignoreversion; Source: tests\README.txt; DestDir: "{app}\Source\tests" -Flags: ignoreversion; Source: tests\benchmark\*.c; DestDir: "{app}\Source\tests\benchmark" -Flags: ignoreversion; Source: tests\benchmark\*.ds*; DestDir: "{app}\Source\tests\benchmark" -Flags: ignoreversion; Source: tests\benchmark\README.txt; DestDir: "{app}\Source\tests\benchmark" -Flags: ignoreversion; Source: xmlwf\*.c*; DestDir: "{app}\Source\xmlwf" -Flags: ignoreversion; Source: xmlwf\*.h; DestDir: "{app}\Source\xmlwf" -Flags: ignoreversion; Source: xmlwf\*.dsp; DestDir: "{app}\Source\xmlwf" - -[Messages] -WelcomeLabel1=Welcome to the Expat XML Parser Setup Wizard -WelcomeLabel2=This will install [name/ver] on your computer.%n%nExpat is an XML parser with a C-language API, and is primarily made available to allow developers to build applications which use XML using a portable API and fast implementation.%n%nIt is strongly recommended that you close all other applications you have running before continuing. This will help prevent any conflicts during the installation process. diff --git a/lib-src/expat/xmlwf/codepage.c b/lib-src/expat/xmlwf/codepage.c deleted file mode 100755 index 57e48ff2d..000000000 --- a/lib-src/expat/xmlwf/codepage.c +++ /dev/null @@ -1,68 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include "codepage.h" - -#if (defined(WIN32) || (defined(__WATCOMC__) && defined(__NT__))) -#define STRICT 1 -#define WIN32_LEAN_AND_MEAN 1 - -#include - -int -codepageMap(int cp, int *map) -{ - int i; - CPINFO info; - if (!GetCPInfo(cp, &info) || info.MaxCharSize > 2) - return 0; - for (i = 0; i < 256; i++) - map[i] = -1; - if (info.MaxCharSize > 1) { - for (i = 0; i < MAX_LEADBYTES; i+=2) { - int j, lim; - if (info.LeadByte[i] == 0 && info.LeadByte[i + 1] == 0) - break; - lim = info.LeadByte[i + 1]; - for (j = info.LeadByte[i]; j <= lim; j++) - map[j] = -2; - } - } - for (i = 0; i < 256; i++) { - if (map[i] == -1) { - char c = (char)i; - unsigned short n; - if (MultiByteToWideChar(cp, MB_PRECOMPOSED|MB_ERR_INVALID_CHARS, - &c, 1, &n, 1) == 1) - map[i] = n; - } - } - return 1; -} - -int -codepageConvert(int cp, const char *p) -{ - unsigned short c; - if (MultiByteToWideChar(cp, MB_PRECOMPOSED|MB_ERR_INVALID_CHARS, - p, 2, &c, 1) == 1) - return c; - return -1; -} - -#else /* not WIN32 */ - -int -codepageMap(int cp, int *map) -{ - return 0; -} - -int -codepageConvert(int cp, const char *p) -{ - return -1; -} - -#endif /* not WIN32 */ diff --git a/lib-src/expat/xmlwf/codepage.h b/lib-src/expat/xmlwf/codepage.h deleted file mode 100755 index 6a4df6888..000000000 --- a/lib-src/expat/xmlwf/codepage.h +++ /dev/null @@ -1,6 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -int codepageMap(int cp, int *map); -int codepageConvert(int cp, const char *p); diff --git a/lib-src/expat/xmlwf/ct.c b/lib-src/expat/xmlwf/ct.c deleted file mode 100755 index 95903a345..000000000 --- a/lib-src/expat/xmlwf/ct.c +++ /dev/null @@ -1,147 +0,0 @@ -#define CHARSET_MAX 41 - -static const char * -getTok(const char **pp) -{ - enum { inAtom, inString, init, inComment }; - int state = init; - const char *tokStart = 0; - for (;;) { - switch (**pp) { - case '\0': - return 0; - case ' ': - case '\r': - case '\t': - case '\n': - if (state == inAtom) - return tokStart; - break; - case '(': - if (state == inAtom) - return tokStart; - if (state != inString) - state++; - break; - case ')': - if (state > init) - --state; - else if (state != inString) - return 0; - break; - case ';': - case '/': - case '=': - if (state == inAtom) - return tokStart; - if (state == init) - return (*pp)++; - break; - case '\\': - ++*pp; - if (**pp == '\0') - return 0; - break; - case '"': - switch (state) { - case inString: - ++*pp; - return tokStart; - case inAtom: - return tokStart; - case init: - tokStart = *pp; - state = inString; - break; - } - break; - default: - if (state == init) { - tokStart = *pp; - state = inAtom; - } - break; - } - ++*pp; - } - /* not reached */ -} - -/* key must be lowercase ASCII */ - -static int -matchkey(const char *start, const char *end, const char *key) -{ - if (!start) - return 0; - for (; start != end; start++, key++) - if (*start != *key && *start != 'A' + (*key - 'a')) - return 0; - return *key == '\0'; -} - -void -getXMLCharset(const char *buf, char *charset) -{ - const char *next, *p; - - charset[0] = '\0'; - next = buf; - p = getTok(&next); - if (matchkey(p, next, "text")) - strcpy(charset, "us-ascii"); - else if (!matchkey(p, next, "application")) - return; - p = getTok(&next); - if (!p || *p != '/') - return; - p = getTok(&next); - if (matchkey(p, next, "xml")) - isXml = 1; - p = getTok(&next); - while (p) { - if (*p == ';') { - p = getTok(&next); - if (matchkey(p, next, "charset")) { - p = getTok(&next); - if (p && *p == '=') { - p = getTok(&next); - if (p) { - char *s = charset; - if (*p == '"') { - while (++p != next - 1) { - if (*p == '\\') - ++p; - if (s == charset + CHARSET_MAX - 1) { - charset[0] = '\0'; - break; - } - *s++ = *p; - } - *s++ = '\0'; - } - else { - if (next - p > CHARSET_MAX - 1) - break; - while (p != next) - *s++ = *p++; - *s = 0; - break; - } - } - } - } - } - else - p = getTok(&next); - } -} - -int -main(int argc, char **argv) -{ - char buf[CHARSET_MAX]; - getXMLCharset(argv[1], buf); - printf("charset = \"%s\"\n", buf); - return 0; -} diff --git a/lib-src/expat/xmlwf/filemap.h b/lib-src/expat/xmlwf/filemap.h deleted file mode 100755 index 814edec25..000000000 --- a/lib-src/expat/xmlwf/filemap.h +++ /dev/null @@ -1,17 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include - -#ifdef XML_UNICODE -int filemap(const wchar_t *name, - void (*processor)(const void *, size_t, - const wchar_t *, void *arg), - void *arg); -#else -int filemap(const char *name, - void (*processor)(const void *, size_t, - const char *, void *arg), - void *arg); -#endif diff --git a/lib-src/expat/xmlwf/readfilemap.c b/lib-src/expat/xmlwf/readfilemap.c deleted file mode 100755 index bd32b9341..000000000 --- a/lib-src/expat/xmlwf/readfilemap.c +++ /dev/null @@ -1,100 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include -#include -#include -#include -#include - -#ifdef __WATCOMC__ -#ifndef __LINUX__ -#include -#else -#include -#endif -#endif - -#ifdef __BEOS__ -#include -#endif - -#ifndef S_ISREG -#ifndef S_IFREG -#define S_IFREG _S_IFREG -#endif -#ifndef S_IFMT -#define S_IFMT _S_IFMT -#endif -#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) -#endif /* not S_ISREG */ - -#ifndef O_BINARY -#ifdef _O_BINARY -#define O_BINARY _O_BINARY -#else -#define O_BINARY 0 -#endif -#endif - -#include "filemap.h" - -int -filemap(const char *name, - void (*processor)(const void *, size_t, const char *, void *arg), - void *arg) -{ - size_t nbytes; - int fd; - int n; - struct stat sb; - void *p; - - fd = open(name, O_RDONLY|O_BINARY); - if (fd < 0) { - perror(name); - return 0; - } - if (fstat(fd, &sb) < 0) { - perror(name); - close(fd); - return 0; - } - if (!S_ISREG(sb.st_mode)) { - fprintf(stderr, "%s: not a regular file\n", name); - close(fd); - return 0; - } - nbytes = sb.st_size; - /* malloc will return NULL with nbytes == 0, handle files with size 0 */ - if (nbytes == 0) { - static const char c = '\0'; - processor(&c, 0, name, arg); - close(fd); - return 1; - } - p = malloc(nbytes); - if (!p) { - fprintf(stderr, "%s: out of memory\n", name); - close(fd); - return 0; - } - n = read(fd, p, nbytes); - if (n < 0) { - perror(name); - free(p); - close(fd); - return 0; - } - if (n != nbytes) { - fprintf(stderr, "%s: read unexpected number of bytes\n", name); - free(p); - close(fd); - return 0; - } - processor(p, nbytes, name, arg); - free(p); - close(fd); - return 1; -} diff --git a/lib-src/expat/xmlwf/unixfilemap.c b/lib-src/expat/xmlwf/unixfilemap.c deleted file mode 100755 index 93adce32e..000000000 --- a/lib-src/expat/xmlwf/unixfilemap.c +++ /dev/null @@ -1,65 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include -#include -#include -#include -#include -#include -#include -#include - -#ifndef MAP_FILE -#define MAP_FILE 0 -#endif - -#include "filemap.h" - -int -filemap(const char *name, - void (*processor)(const void *, size_t, const char *, void *arg), - void *arg) -{ - int fd; - size_t nbytes; - struct stat sb; - void *p; - - fd = open(name, O_RDONLY); - if (fd < 0) { - perror(name); - return 0; - } - if (fstat(fd, &sb) < 0) { - perror(name); - close(fd); - return 0; - } - if (!S_ISREG(sb.st_mode)) { - close(fd); - fprintf(stderr, "%s: not a regular file\n", name); - return 0; - } - - nbytes = sb.st_size; - /* mmap fails for zero length files */ - if (nbytes == 0) { - static const char c = '\0'; - processor(&c, 0, name, arg); - close(fd); - return 1; - } - p = (void *)mmap((caddr_t)0, (size_t)nbytes, PROT_READ, - MAP_FILE|MAP_PRIVATE, fd, (off_t)0); - if (p == (void *)-1) { - perror(name); - close(fd); - return 0; - } - processor(p, nbytes, name, arg); - munmap((caddr_t)p, nbytes); - close(fd); - return 1; -} diff --git a/lib-src/expat/xmlwf/win32filemap.c b/lib-src/expat/xmlwf/win32filemap.c deleted file mode 100755 index 41dc35b61..000000000 --- a/lib-src/expat/xmlwf/win32filemap.c +++ /dev/null @@ -1,96 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#define STRICT 1 -#define WIN32_LEAN_AND_MEAN 1 - -#ifdef XML_UNICODE_WCHAR_T -#ifndef XML_UNICODE -#define XML_UNICODE -#endif -#endif - -#ifdef XML_UNICODE -#define UNICODE -#define _UNICODE -#endif /* XML_UNICODE */ -#include -#include -#include -#include "filemap.h" - -static void win32perror(const TCHAR *); - -int -filemap(const TCHAR *name, - void (*processor)(const void *, size_t, const TCHAR *, void *arg), - void *arg) -{ - HANDLE f; - HANDLE m; - DWORD size; - DWORD sizeHi; - void *p; - - f = CreateFile(name, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, - FILE_FLAG_SEQUENTIAL_SCAN, NULL); - if (f == INVALID_HANDLE_VALUE) { - win32perror(name); - return 0; - } - size = GetFileSize(f, &sizeHi); - if (size == (DWORD)-1) { - win32perror(name); - return 0; - } - if (sizeHi) { - _ftprintf(stderr, _T("%s: bigger than 2Gb\n"), name); - return 0; - } - /* CreateFileMapping barfs on zero length files */ - if (size == 0) { - static const char c = '\0'; - processor(&c, 0, name, arg); - CloseHandle(f); - return 1; - } - m = CreateFileMapping(f, NULL, PAGE_READONLY, 0, 0, NULL); - if (m == NULL) { - win32perror(name); - CloseHandle(f); - return 0; - } - p = MapViewOfFile(m, FILE_MAP_READ, 0, 0, 0); - if (p == NULL) { - win32perror(name); - CloseHandle(m); - CloseHandle(f); - return 0; - } - processor(p, size, name, arg); - UnmapViewOfFile(p); - CloseHandle(m); - CloseHandle(f); - return 1; -} - -static void -win32perror(const TCHAR *s) -{ - LPVOID buf; - if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER - | FORMAT_MESSAGE_FROM_SYSTEM, - NULL, - GetLastError(), - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), - (LPTSTR) &buf, - 0, - NULL)) { - _ftprintf(stderr, _T("%s: %s"), s, buf); - fflush(stderr); - LocalFree(buf); - } - else - _ftprintf(stderr, _T("%s: unknown Windows error\n"), s); -} diff --git a/lib-src/expat/xmlwf/xmlfile.c b/lib-src/expat/xmlwf/xmlfile.c deleted file mode 100755 index 99eeeaaef..000000000 --- a/lib-src/expat/xmlwf/xmlfile.c +++ /dev/null @@ -1,244 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include -#include -#include -#include -#include - -#ifdef COMPILED_FROM_DSP -#include "winconfig.h" -#elif defined(MACOS_CLASSIC) -#include "macconfig.h" -#elif defined(__amigaos__) -#include "amigaconfig.h" -#elif defined(__WATCOMC__) -#include "watcomconfig.h" -#elif defined(HAVE_EXPAT_CONFIG_H) -#include -#endif /* ndef COMPILED_FROM_DSP */ - -#include "expat.h" -#include "xmlfile.h" -#include "xmltchar.h" -#include "filemap.h" - -#if (defined(_MSC_VER) || (defined(__WATCOMC__) && !defined(__LINUX__))) -#include -#endif - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -#ifdef HAVE_UNISTD_H -#include -#endif - -#ifndef O_BINARY -#ifdef _O_BINARY -#define O_BINARY _O_BINARY -#else -#define O_BINARY 0 -#endif -#endif - -#ifdef _DEBUG -#define READ_SIZE 16 -#else -#define READ_SIZE (1024*8) -#endif - - -typedef struct { - XML_Parser parser; - int *retPtr; -} PROCESS_ARGS; - -static void -reportError(XML_Parser parser, const XML_Char *filename) -{ - enum XML_Error code = XML_GetErrorCode(parser); - const XML_Char *message = XML_ErrorString(code); - if (message) - ftprintf(stdout, T("%s:%" XML_FMT_INT_MOD "u:%" XML_FMT_INT_MOD "u: %s\n"), - filename, - XML_GetErrorLineNumber(parser), - XML_GetErrorColumnNumber(parser), - message); - else - ftprintf(stderr, T("%s: (unknown message %d)\n"), filename, code); -} - -/* This implementation will give problems on files larger than INT_MAX. */ -static void -processFile(const void *data, size_t size, - const XML_Char *filename, void *args) -{ - XML_Parser parser = ((PROCESS_ARGS *)args)->parser; - int *retPtr = ((PROCESS_ARGS *)args)->retPtr; - if (XML_Parse(parser, (const char *)data, (int)size, 1) == XML_STATUS_ERROR) { - reportError(parser, filename); - *retPtr = 0; - } - else - *retPtr = 1; -} - -#if (defined(WIN32) || defined(__WATCOMC__)) - -static int -isAsciiLetter(XML_Char c) -{ - return (T('a') <= c && c <= T('z')) || (T('A') <= c && c <= T('Z')); -} - -#endif /* WIN32 */ - -static const XML_Char * -resolveSystemId(const XML_Char *base, const XML_Char *systemId, - XML_Char **toFree) -{ - XML_Char *s; - *toFree = 0; - if (!base - || *systemId == T('/') -#if (defined(WIN32) || defined(__WATCOMC__)) - || *systemId == T('\\') - || (isAsciiLetter(systemId[0]) && systemId[1] == T(':')) -#endif - ) - return systemId; - *toFree = (XML_Char *)malloc((tcslen(base) + tcslen(systemId) + 2) - * sizeof(XML_Char)); - if (!*toFree) - return systemId; - tcscpy(*toFree, base); - s = *toFree; - if (tcsrchr(s, T('/'))) - s = tcsrchr(s, T('/')) + 1; -#if (defined(WIN32) || defined(__WATCOMC__)) - if (tcsrchr(s, T('\\'))) - s = tcsrchr(s, T('\\')) + 1; -#endif - tcscpy(s, systemId); - return *toFree; -} - -static int -externalEntityRefFilemap(XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - int result; - XML_Char *s; - const XML_Char *filename; - XML_Parser entParser = XML_ExternalEntityParserCreate(parser, context, 0); - PROCESS_ARGS args; - args.retPtr = &result; - args.parser = entParser; - filename = resolveSystemId(base, systemId, &s); - XML_SetBase(entParser, filename); - if (!filemap(filename, processFile, &args)) - result = 0; - free(s); - XML_ParserFree(entParser); - return result; -} - -static int -processStream(const XML_Char *filename, XML_Parser parser) -{ - /* passing NULL for filename means read intput from stdin */ - int fd = 0; /* 0 is the fileno for stdin */ - - if (filename != NULL) { - fd = topen(filename, O_BINARY|O_RDONLY); - if (fd < 0) { - tperror(filename); - return 0; - } - } - for (;;) { - int nread; - char *buf = (char *)XML_GetBuffer(parser, READ_SIZE); - if (!buf) { - if (filename != NULL) - close(fd); - ftprintf(stderr, T("%s: out of memory\n"), - filename != NULL ? filename : "xmlwf"); - return 0; - } - nread = read(fd, buf, READ_SIZE); - if (nread < 0) { - tperror(filename != NULL ? filename : "STDIN"); - if (filename != NULL) - close(fd); - return 0; - } - if (XML_ParseBuffer(parser, nread, nread == 0) == XML_STATUS_ERROR) { - reportError(parser, filename != NULL ? filename : "STDIN"); - if (filename != NULL) - close(fd); - return 0; - } - if (nread == 0) { - if (filename != NULL) - close(fd); - break;; - } - } - return 1; -} - -static int -externalEntityRefStream(XML_Parser parser, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - XML_Char *s; - const XML_Char *filename; - int ret; - XML_Parser entParser = XML_ExternalEntityParserCreate(parser, context, 0); - filename = resolveSystemId(base, systemId, &s); - XML_SetBase(entParser, filename); - ret = processStream(filename, entParser); - free(s); - XML_ParserFree(entParser); - return ret; -} - -int -XML_ProcessFile(XML_Parser parser, - const XML_Char *filename, - unsigned flags) -{ - int result; - - if (!XML_SetBase(parser, filename)) { - ftprintf(stderr, T("%s: out of memory"), filename); - exit(1); - } - - if (flags & XML_EXTERNAL_ENTITIES) - XML_SetExternalEntityRefHandler(parser, - (flags & XML_MAP_FILE) - ? externalEntityRefFilemap - : externalEntityRefStream); - if (flags & XML_MAP_FILE) { - PROCESS_ARGS args; - args.retPtr = &result; - args.parser = parser; - if (!filemap(filename, processFile, &args)) - result = 0; - } - else - result = processStream(filename, parser); - return result; -} diff --git a/lib-src/expat/xmlwf/xmlfile.h b/lib-src/expat/xmlwf/xmlfile.h deleted file mode 100755 index d093ecc06..000000000 --- a/lib-src/expat/xmlwf/xmlfile.h +++ /dev/null @@ -1,20 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#define XML_MAP_FILE 01 -#define XML_EXTERNAL_ENTITIES 02 - -#ifdef XML_LARGE_SIZE -#if defined(XML_USE_MSC_EXTENSIONS) && _MSC_VER < 1400 -#define XML_FMT_INT_MOD "I64" -#else -#define XML_FMT_INT_MOD "ll" -#endif -#else -#define XML_FMT_INT_MOD "l" -#endif - -extern int XML_ProcessFile(XML_Parser parser, - const XML_Char *filename, - unsigned flags); diff --git a/lib-src/expat/xmlwf/xmlmime.c b/lib-src/expat/xmlwf/xmlmime.c deleted file mode 100755 index 56a0e7f40..000000000 --- a/lib-src/expat/xmlwf/xmlmime.c +++ /dev/null @@ -1,163 +0,0 @@ -#include -#include "xmlmime.h" - -static const char * -getTok(const char **pp) -{ - /* inComment means one level of nesting; inComment+1 means two levels etc */ - enum { inAtom, inString, init, inComment }; - int state = init; - const char *tokStart = 0; - for (;;) { - switch (**pp) { - case '\0': - if (state == inAtom) - return tokStart; - return 0; - case ' ': - case '\r': - case '\t': - case '\n': - if (state == inAtom) - return tokStart; - break; - case '(': - if (state == inAtom) - return tokStart; - if (state != inString) - state++; - break; - case ')': - if (state > init) - --state; - else if (state != inString) - return 0; - break; - case ';': - case '/': - case '=': - if (state == inAtom) - return tokStart; - if (state == init) - return (*pp)++; - break; - case '\\': - ++*pp; - if (**pp == '\0') - return 0; - break; - case '"': - switch (state) { - case inString: - ++*pp; - return tokStart; - case inAtom: - return tokStart; - case init: - tokStart = *pp; - state = inString; - break; - } - break; - default: - if (state == init) { - tokStart = *pp; - state = inAtom; - } - break; - } - ++*pp; - } - /* not reached */ -} - -/* key must be lowercase ASCII */ - -static int -matchkey(const char *start, const char *end, const char *key) -{ - if (!start) - return 0; - for (; start != end; start++, key++) - if (*start != *key && *start != 'A' + (*key - 'a')) - return 0; - return *key == '\0'; -} - -void -getXMLCharset(const char *buf, char *charset) -{ - const char *next, *p; - - charset[0] = '\0'; - next = buf; - p = getTok(&next); - if (matchkey(p, next, "text")) - strcpy(charset, "us-ascii"); - else if (!matchkey(p, next, "application")) - return; - p = getTok(&next); - if (!p || *p != '/') - return; - p = getTok(&next); -#if 0 - if (!matchkey(p, next, "xml") && charset[0] == '\0') - return; -#endif - p = getTok(&next); - while (p) { - if (*p == ';') { - p = getTok(&next); - if (matchkey(p, next, "charset")) { - p = getTok(&next); - if (p && *p == '=') { - p = getTok(&next); - if (p) { - char *s = charset; - if (*p == '"') { - while (++p != next - 1) { - if (*p == '\\') - ++p; - if (s == charset + CHARSET_MAX - 1) { - charset[0] = '\0'; - break; - } - *s++ = *p; - } - *s++ = '\0'; - } - else { - if (next - p > CHARSET_MAX - 1) - break; - while (p != next) - *s++ = *p++; - *s = 0; - break; - } - } - } - break; - } - } - else - p = getTok(&next); - } -} - -#ifdef TEST - -#include - -int -main(int argc, char *argv[]) -{ - char buf[CHARSET_MAX]; - if (argc <= 1) - return 1; - printf("%s\n", argv[1]); - getXMLCharset(argv[1], buf); - printf("charset=\"%s\"\n", buf); - return 0; -} - -#endif /* TEST */ diff --git a/lib-src/expat/xmlwf/xmlmime.h b/lib-src/expat/xmlwf/xmlmime.h deleted file mode 100755 index bf0356df0..000000000 --- a/lib-src/expat/xmlwf/xmlmime.h +++ /dev/null @@ -1,19 +0,0 @@ -#ifdef __cplusplus -extern "C" { -#endif - -/* Registered charset names are at most 40 characters long. */ - -#define CHARSET_MAX 41 - -/* Figure out the charset to use from the ContentType. - buf contains the body of the header field (the part after "Content-Type:"). - charset gets the charset to use. It must be at least CHARSET_MAX chars - long. charset will be empty if the default charset should be used. -*/ - -void getXMLCharset(const char *buf, char *charset); - -#ifdef __cplusplus -} -#endif diff --git a/lib-src/expat/xmlwf/xmltchar.h b/lib-src/expat/xmlwf/xmltchar.h deleted file mode 100755 index 108857551..000000000 --- a/lib-src/expat/xmlwf/xmltchar.h +++ /dev/null @@ -1,36 +0,0 @@ -#ifdef XML_UNICODE -#ifndef XML_UNICODE_WCHAR_T -#error xmlwf requires a 16-bit Unicode-compatible wchar_t -#endif -#define T(x) L ## x -#define ftprintf fwprintf -#define tfopen _wfopen -#define fputts fputws -#define puttc putwc -#define tcscmp wcscmp -#define tcscpy wcscpy -#define tcscat wcscat -#define tcschr wcschr -#define tcsrchr wcsrchr -#define tcslen wcslen -#define tperror _wperror -#define topen _wopen -#define tmain wmain -#define tremove _wremove -#else /* not XML_UNICODE */ -#define T(x) x -#define ftprintf fprintf -#define tfopen fopen -#define fputts fputs -#define puttc putc -#define tcscmp strcmp -#define tcscpy strcpy -#define tcscat strcat -#define tcschr strchr -#define tcsrchr strrchr -#define tcslen strlen -#define tperror perror -#define topen open -#define tmain main -#define tremove remove -#endif /* not XML_UNICODE */ diff --git a/lib-src/expat/xmlwf/xmlurl.h b/lib-src/expat/xmlwf/xmlurl.h deleted file mode 100755 index d329913ac..000000000 --- a/lib-src/expat/xmlwf/xmlurl.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifdef __cplusplus -extern "C" { -#endif - -int XML_URLInit(); -void XML_URLUninit(); -int XML_ProcessURL(XML_Parser parser, - const XML_Char *url, - unsigned flags); - -#ifdef __cplusplus -} -#endif diff --git a/lib-src/expat/xmlwf/xmlwf.c b/lib-src/expat/xmlwf/xmlwf.c deleted file mode 100755 index 4fc77da94..000000000 --- a/lib-src/expat/xmlwf/xmlwf.c +++ /dev/null @@ -1,861 +0,0 @@ -/* Copyright (c) 1998, 1999 Thai Open Source Software Center Ltd - See the file COPYING for copying permission. -*/ - -#include -#include -#include -#include - -#include "expat.h" -#include "codepage.h" -#include "xmlfile.h" -#include "xmltchar.h" - -#ifdef _MSC_VER -#include -#endif - -#if defined(__amigaos__) && defined(__USE_INLINE__) -#include -#endif - -/* This ensures proper sorting. */ - -#define NSSEP T('\001') - -static void XMLCALL -characterData(void *userData, const XML_Char *s, int len) -{ - FILE *fp = (FILE *)userData; - for (; len > 0; --len, ++s) { - switch (*s) { - case T('&'): - fputts(T("&"), fp); - break; - case T('<'): - fputts(T("<"), fp); - break; - case T('>'): - fputts(T(">"), fp); - break; -#ifdef W3C14N - case 13: - fputts(T(" "), fp); - break; -#else - case T('"'): - fputts(T("""), fp); - break; - case 9: - case 10: - case 13: - ftprintf(fp, T("&#%d;"), *s); - break; -#endif - default: - puttc(*s, fp); - break; - } - } -} - -static void -attributeValue(FILE *fp, const XML_Char *s) -{ - puttc(T('='), fp); - puttc(T('"'), fp); - for (;;) { - switch (*s) { - case 0: - case NSSEP: - puttc(T('"'), fp); - return; - case T('&'): - fputts(T("&"), fp); - break; - case T('<'): - fputts(T("<"), fp); - break; - case T('"'): - fputts(T("""), fp); - break; -#ifdef W3C14N - case 9: - fputts(T(" "), fp); - break; - case 10: - fputts(T(" "), fp); - break; - case 13: - fputts(T(" "), fp); - break; -#else - case T('>'): - fputts(T(">"), fp); - break; - case 9: - case 10: - case 13: - ftprintf(fp, T("&#%d;"), *s); - break; -#endif - default: - puttc(*s, fp); - break; - } - s++; - } -} - -/* Lexicographically comparing UTF-8 encoded attribute values, -is equivalent to lexicographically comparing based on the character number. */ - -static int -attcmp(const void *att1, const void *att2) -{ - return tcscmp(*(const XML_Char **)att1, *(const XML_Char **)att2); -} - -static void XMLCALL -startElement(void *userData, const XML_Char *name, const XML_Char **atts) -{ - int nAtts; - const XML_Char **p; - FILE *fp = (FILE *)userData; - puttc(T('<'), fp); - fputts(name, fp); - - p = atts; - while (*p) - ++p; - nAtts = (int)((p - atts) >> 1); - if (nAtts > 1) - qsort((void *)atts, nAtts, sizeof(XML_Char *) * 2, attcmp); - while (*atts) { - puttc(T(' '), fp); - fputts(*atts++, fp); - attributeValue(fp, *atts); - atts++; - } - puttc(T('>'), fp); -} - -static void XMLCALL -endElement(void *userData, const XML_Char *name) -{ - FILE *fp = (FILE *)userData; - puttc(T('<'), fp); - puttc(T('/'), fp); - fputts(name, fp); - puttc(T('>'), fp); -} - -static int -nsattcmp(const void *p1, const void *p2) -{ - const XML_Char *att1 = *(const XML_Char **)p1; - const XML_Char *att2 = *(const XML_Char **)p2; - int sep1 = (tcsrchr(att1, NSSEP) != 0); - int sep2 = (tcsrchr(att1, NSSEP) != 0); - if (sep1 != sep2) - return sep1 - sep2; - return tcscmp(att1, att2); -} - -static void XMLCALL -startElementNS(void *userData, const XML_Char *name, const XML_Char **atts) -{ - int nAtts; - int nsi; - const XML_Char **p; - FILE *fp = (FILE *)userData; - const XML_Char *sep; - puttc(T('<'), fp); - - sep = tcsrchr(name, NSSEP); - if (sep) { - fputts(T("n1:"), fp); - fputts(sep + 1, fp); - fputts(T(" xmlns:n1"), fp); - attributeValue(fp, name); - nsi = 2; - } - else { - fputts(name, fp); - nsi = 1; - } - - p = atts; - while (*p) - ++p; - nAtts = (int)((p - atts) >> 1); - if (nAtts > 1) - qsort((void *)atts, nAtts, sizeof(XML_Char *) * 2, nsattcmp); - while (*atts) { - name = *atts++; - sep = tcsrchr(name, NSSEP); - puttc(T(' '), fp); - if (sep) { - ftprintf(fp, T("n%d:"), nsi); - fputts(sep + 1, fp); - } - else - fputts(name, fp); - attributeValue(fp, *atts); - if (sep) { - ftprintf(fp, T(" xmlns:n%d"), nsi++); - attributeValue(fp, name); - } - atts++; - } - puttc(T('>'), fp); -} - -static void XMLCALL -endElementNS(void *userData, const XML_Char *name) -{ - FILE *fp = (FILE *)userData; - const XML_Char *sep; - puttc(T('<'), fp); - puttc(T('/'), fp); - sep = tcsrchr(name, NSSEP); - if (sep) { - fputts(T("n1:"), fp); - fputts(sep + 1, fp); - } - else - fputts(name, fp); - puttc(T('>'), fp); -} - -#ifndef W3C14N - -static void XMLCALL -processingInstruction(void *userData, const XML_Char *target, - const XML_Char *data) -{ - FILE *fp = (FILE *)userData; - puttc(T('<'), fp); - puttc(T('?'), fp); - fputts(target, fp); - puttc(T(' '), fp); - fputts(data, fp); - puttc(T('?'), fp); - puttc(T('>'), fp); -} - -#endif /* not W3C14N */ - -static void XMLCALL -defaultCharacterData(void *userData, const XML_Char *s, int len) -{ - XML_DefaultCurrent((XML_Parser) userData); -} - -static void XMLCALL -defaultStartElement(void *userData, const XML_Char *name, - const XML_Char **atts) -{ - XML_DefaultCurrent((XML_Parser) userData); -} - -static void XMLCALL -defaultEndElement(void *userData, const XML_Char *name) -{ - XML_DefaultCurrent((XML_Parser) userData); -} - -static void XMLCALL -defaultProcessingInstruction(void *userData, const XML_Char *target, - const XML_Char *data) -{ - XML_DefaultCurrent((XML_Parser) userData); -} - -static void XMLCALL -nopCharacterData(void *userData, const XML_Char *s, int len) -{ -} - -static void XMLCALL -nopStartElement(void *userData, const XML_Char *name, const XML_Char **atts) -{ -} - -static void XMLCALL -nopEndElement(void *userData, const XML_Char *name) -{ -} - -static void XMLCALL -nopProcessingInstruction(void *userData, const XML_Char *target, - const XML_Char *data) -{ -} - -static void XMLCALL -markup(void *userData, const XML_Char *s, int len) -{ - FILE *fp = (FILE *)XML_GetUserData((XML_Parser) userData); - for (; len > 0; --len, ++s) - puttc(*s, fp); -} - -static void -metaLocation(XML_Parser parser) -{ - const XML_Char *uri = XML_GetBase(parser); - if (uri) - ftprintf((FILE *)XML_GetUserData(parser), T(" uri=\"%s\""), uri); - ftprintf((FILE *)XML_GetUserData(parser), - T(" byte=\"%" XML_FMT_INT_MOD "d\" nbytes=\"%d\" \ - line=\"%" XML_FMT_INT_MOD "u\" col=\"%" XML_FMT_INT_MOD "u\""), - XML_GetCurrentByteIndex(parser), - XML_GetCurrentByteCount(parser), - XML_GetCurrentLineNumber(parser), - XML_GetCurrentColumnNumber(parser)); -} - -static void -metaStartDocument(void *userData) -{ - fputts(T("\n"), (FILE *)XML_GetUserData((XML_Parser) userData)); -} - -static void -metaEndDocument(void *userData) -{ - fputts(T("\n"), (FILE *)XML_GetUserData((XML_Parser) userData)); -} - -static void XMLCALL -metaStartElement(void *userData, const XML_Char *name, - const XML_Char **atts) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - const XML_Char **specifiedAttsEnd - = atts + XML_GetSpecifiedAttributeCount(parser); - const XML_Char **idAttPtr; - int idAttIndex = XML_GetIdAttributeIndex(parser); - if (idAttIndex < 0) - idAttPtr = 0; - else - idAttPtr = atts + idAttIndex; - - ftprintf(fp, T("\n"), fp); - do { - ftprintf(fp, T("= specifiedAttsEnd) - fputts(T("\" defaulted=\"yes\"/>\n"), fp); - else if (atts == idAttPtr) - fputts(T("\" id=\"yes\"/>\n"), fp); - else - fputts(T("\"/>\n"), fp); - } while (*(atts += 2)); - fputts(T("\n"), fp); - } - else - fputts(T("/>\n"), fp); -} - -static void XMLCALL -metaEndElement(void *userData, const XML_Char *name) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - ftprintf(fp, T("\n"), fp); -} - -static void XMLCALL -metaProcessingInstruction(void *userData, const XML_Char *target, - const XML_Char *data) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - ftprintf(fp, T("\n"), fp); -} - -static void XMLCALL -metaComment(void *userData, const XML_Char *data) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); -} - -static void XMLCALL -metaStartCdataSection(void *userData) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); -} - -static void XMLCALL -metaEndCdataSection(void *userData) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); -} - -static void XMLCALL -metaCharacterData(void *userData, const XML_Char *s, int len) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); -} - -static void XMLCALL -metaStartDoctypeDecl(void *userData, - const XML_Char *doctypeName, - const XML_Char *sysid, - const XML_Char *pubid, - int has_internal_subset) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - ftprintf(fp, T("\n"), fp); -} - -static void XMLCALL -metaEndDoctypeDecl(void *userData) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); -} - -static void XMLCALL -metaNotationDecl(void *userData, - const XML_Char *notationName, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - ftprintf(fp, T("\n"), fp); -} - - -static void XMLCALL -metaEntityDecl(void *userData, - const XML_Char *entityName, - int is_param, - const XML_Char *value, - int value_length, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId, - const XML_Char *notationName) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - - if (value) { - ftprintf(fp, T("'), fp); - characterData(fp, value, value_length); - fputts(T("\n"), fp); - } - else if (notationName) { - ftprintf(fp, T("\n"), fp); - } - else { - ftprintf(fp, T("\n"), fp); - } -} - -static void XMLCALL -metaStartNamespaceDecl(void *userData, - const XML_Char *prefix, - const XML_Char *uri) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - fputts(T("\n"), fp); - } - else - fputts(T("/>\n"), fp); -} - -static void XMLCALL -metaEndNamespaceDecl(void *userData, const XML_Char *prefix) -{ - XML_Parser parser = (XML_Parser) userData; - FILE *fp = (FILE *)XML_GetUserData(parser); - if (!prefix) - fputts(T("\n"), fp); - else - ftprintf(fp, T("\n"), prefix); -} - -static int XMLCALL -unknownEncodingConvert(void *data, const char *p) -{ - return codepageConvert(*(int *)data, p); -} - -static int XMLCALL -unknownEncoding(void *userData, const XML_Char *name, XML_Encoding *info) -{ - int cp; - static const XML_Char prefixL[] = T("windows-"); - static const XML_Char prefixU[] = T("WINDOWS-"); - int i; - - for (i = 0; prefixU[i]; i++) - if (name[i] != prefixU[i] && name[i] != prefixL[i]) - return 0; - - cp = 0; - for (; name[i]; i++) { - static const XML_Char digits[] = T("0123456789"); - const XML_Char *s = tcschr(digits, name[i]); - if (!s) - return 0; - cp *= 10; - cp += (int)(s - digits); - if (cp >= 0x10000) - return 0; - } - if (!codepageMap(cp, info->map)) - return 0; - info->convert = unknownEncodingConvert; - /* We could just cast the code page integer to a void *, - and avoid the use of release. */ - info->release = free; - info->data = malloc(sizeof(int)); - if (!info->data) - return 0; - *(int *)info->data = cp; - return 1; -} - -static int XMLCALL -notStandalone(void *userData) -{ - return 0; -} - -static void -showVersion(XML_Char *prog) -{ - XML_Char *s = prog; - XML_Char ch; - const XML_Feature *features = XML_GetFeatureList(); - while ((ch = *s) != 0) { - if (ch == '/' -#if (defined(WIN32) || defined(__WATCOMC__)) - || ch == '\\' -#endif - ) - prog = s + 1; - ++s; - } - ftprintf(stdout, T("%s using %s\n"), prog, XML_ExpatVersion()); - if (features != NULL && features[0].feature != XML_FEATURE_END) { - int i = 1; - ftprintf(stdout, T("%s"), features[0].name); - if (features[0].value) - ftprintf(stdout, T("=%ld"), features[0].value); - while (features[i].feature != XML_FEATURE_END) { - ftprintf(stdout, T(", %s"), features[i].name); - if (features[i].value) - ftprintf(stdout, T("=%ld"), features[i].value); - ++i; - } - ftprintf(stdout, T("\n")); - } -} - -static void -usage(const XML_Char *prog, int rc) -{ - ftprintf(stderr, - T("usage: %s [-n] [-p] [-r] [-s] [-w] [-x] [-d output-dir] " - "[-e encoding] file ...\n"), prog); - exit(rc); -} - -int -tmain(int argc, XML_Char **argv) -{ - int i, j; - const XML_Char *outputDir = NULL; - const XML_Char *encoding = NULL; - unsigned processFlags = XML_MAP_FILE; - int windowsCodePages = 0; - int outputType = 0; - int useNamespaces = 0; - int requireStandalone = 0; - enum XML_ParamEntityParsing paramEntityParsing = - XML_PARAM_ENTITY_PARSING_NEVER; - int useStdin = 0; - -#ifdef _MSC_VER - _CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF|_CRTDBG_LEAK_CHECK_DF); -#endif - - i = 1; - j = 0; - while (i < argc) { - if (j == 0) { - if (argv[i][0] != T('-')) - break; - if (argv[i][1] == T('-') && argv[i][2] == T('\0')) { - i++; - break; - } - j++; - } - switch (argv[i][j]) { - case T('r'): - processFlags &= ~XML_MAP_FILE; - j++; - break; - case T('s'): - requireStandalone = 1; - j++; - break; - case T('n'): - useNamespaces = 1; - j++; - break; - case T('p'): - paramEntityParsing = XML_PARAM_ENTITY_PARSING_ALWAYS; - /* fall through */ - case T('x'): - processFlags |= XML_EXTERNAL_ENTITIES; - j++; - break; - case T('w'): - windowsCodePages = 1; - j++; - break; - case T('m'): - outputType = 'm'; - j++; - break; - case T('c'): - outputType = 'c'; - useNamespaces = 0; - j++; - break; - case T('t'): - outputType = 't'; - j++; - break; - case T('d'): - if (argv[i][j + 1] == T('\0')) { - if (++i == argc) - usage(argv[0], 2); - outputDir = argv[i]; - } - else - outputDir = argv[i] + j + 1; - i++; - j = 0; - break; - case T('e'): - if (argv[i][j + 1] == T('\0')) { - if (++i == argc) - usage(argv[0], 2); - encoding = argv[i]; - } - else - encoding = argv[i] + j + 1; - i++; - j = 0; - break; - case T('h'): - usage(argv[0], 0); - return 0; - case T('v'): - showVersion(argv[0]); - return 0; - case T('\0'): - if (j > 1) { - i++; - j = 0; - break; - } - /* fall through */ - default: - usage(argv[0], 2); - } - } - if (i == argc) { - useStdin = 1; - processFlags &= ~XML_MAP_FILE; - i--; - } - for (; i < argc; i++) { - FILE *fp = 0; - XML_Char *outName = 0; - int result; - XML_Parser parser; - if (useNamespaces) - parser = XML_ParserCreateNS(encoding, NSSEP); - else - parser = XML_ParserCreate(encoding); - if (requireStandalone) - XML_SetNotStandaloneHandler(parser, notStandalone); - XML_SetParamEntityParsing(parser, paramEntityParsing); - if (outputType == 't') { - /* This is for doing timings; this gives a more realistic estimate of - the parsing time. */ - outputDir = 0; - XML_SetElementHandler(parser, nopStartElement, nopEndElement); - XML_SetCharacterDataHandler(parser, nopCharacterData); - XML_SetProcessingInstructionHandler(parser, nopProcessingInstruction); - } - else if (outputDir) { - const XML_Char * delim = T("/"); - const XML_Char *file = useStdin ? T("STDIN") : argv[i]; - if (!useStdin) { - /* Jump after last (back)slash */ - const XML_Char * lastDelim = tcsrchr(file, delim[0]); - if (lastDelim) - file = lastDelim + 1; -#if (defined(WIN32) || defined(__WATCOMC__)) - else { - const XML_Char * winDelim = T("\\"); - lastDelim = tcsrchr(file, winDelim[0]); - if (lastDelim) { - file = lastDelim + 1; - delim = winDelim; - } - } -#endif - } - outName = (XML_Char *)malloc((tcslen(outputDir) + tcslen(file) + 2) - * sizeof(XML_Char)); - tcscpy(outName, outputDir); - tcscat(outName, delim); - tcscat(outName, file); - fp = tfopen(outName, T("wb")); - if (!fp) { - tperror(outName); - exit(1); - } - setvbuf(fp, NULL, _IOFBF, 16384); -#ifdef XML_UNICODE - puttc(0xFEFF, fp); -#endif - XML_SetUserData(parser, fp); - switch (outputType) { - case 'm': - XML_UseParserAsHandlerArg(parser); - XML_SetElementHandler(parser, metaStartElement, metaEndElement); - XML_SetProcessingInstructionHandler(parser, metaProcessingInstruction); - XML_SetCommentHandler(parser, metaComment); - XML_SetCdataSectionHandler(parser, metaStartCdataSection, - metaEndCdataSection); - XML_SetCharacterDataHandler(parser, metaCharacterData); - XML_SetDoctypeDeclHandler(parser, metaStartDoctypeDecl, - metaEndDoctypeDecl); - XML_SetEntityDeclHandler(parser, metaEntityDecl); - XML_SetNotationDeclHandler(parser, metaNotationDecl); - XML_SetNamespaceDeclHandler(parser, metaStartNamespaceDecl, - metaEndNamespaceDecl); - metaStartDocument(parser); - break; - case 'c': - XML_UseParserAsHandlerArg(parser); - XML_SetDefaultHandler(parser, markup); - XML_SetElementHandler(parser, defaultStartElement, defaultEndElement); - XML_SetCharacterDataHandler(parser, defaultCharacterData); - XML_SetProcessingInstructionHandler(parser, - defaultProcessingInstruction); - break; - default: - if (useNamespaces) - XML_SetElementHandler(parser, startElementNS, endElementNS); - else - XML_SetElementHandler(parser, startElement, endElement); - XML_SetCharacterDataHandler(parser, characterData); -#ifndef W3C14N - XML_SetProcessingInstructionHandler(parser, processingInstruction); -#endif /* not W3C14N */ - break; - } - } - if (windowsCodePages) - XML_SetUnknownEncodingHandler(parser, unknownEncoding, 0); - result = XML_ProcessFile(parser, useStdin ? NULL : argv[i], processFlags); - if (outputDir) { - if (outputType == 'm') - metaEndDocument(parser); - fclose(fp); - if (!result) { - tremove(outName); - exit(2); - } - free(outName); - } - XML_ParserFree(parser); - } - return 0; -} diff --git a/lib-src/expat/xmlwf/xmlwf.dsp b/lib-src/expat/xmlwf/xmlwf.dsp deleted file mode 100755 index eb80c62be..000000000 --- a/lib-src/expat/xmlwf/xmlwf.dsp +++ /dev/null @@ -1,139 +0,0 @@ -# Microsoft Developer Studio Project File - Name="xmlwf" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Console Application" 0x0103 - -CFG=xmlwf - Win32 Release -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "xmlwf.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "xmlwf.mak" CFG="xmlwf - Win32 Release" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "xmlwf - Win32 Release" (based on "Win32 (x86) Console Application") -!MESSAGE "xmlwf - Win32 Debug" (based on "Win32 (x86) Console Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "xmlwf - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir ".\Release" -# PROP BASE Intermediate_Dir ".\Release" -# PROP BASE Target_Dir "." -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "..\win32\bin\Release" -# PROP Intermediate_Dir "..\win32\tmp\Release-xmlwf" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "." -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c -# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\lib" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "COMPILED_FROM_DSP" /FD /c -# SUBTRACT CPP /YX /Yc /Yu -# ADD BASE RSC /l 0x809 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /machine:I386 -# ADD LINK32 libexpat.lib setargv.obj /nologo /subsystem:console /pdb:none /machine:I386 /libpath:"..\win32\bin\Release" /out:"..\win32\bin\Release\xmlwf.exe" -# SUBTRACT LINK32 /nodefaultlib - -!ELSEIF "$(CFG)" == "xmlwf - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir ".\Debug" -# PROP BASE Intermediate_Dir ".\Debug" -# PROP BASE Target_Dir "." -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "..\win32\bin\Debug" -# PROP Intermediate_Dir "..\win32\tmp\Debug-xmlwf" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "." -# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /YX /c -# ADD CPP /nologo /MTd /W3 /GX /ZI /Od /I "..\lib" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "COMPILED_FROM_DSP" /FD /c -# SUBTRACT CPP /Fr /YX -# ADD BASE RSC /l 0x809 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 -# ADD LINK32 libexpat.lib setargv.obj /nologo /subsystem:console /pdb:none /debug /machine:I386 /libpath:"..\win32\bin\Debug" /out:"..\win32\bin\Debug\xmlwf.exe" - -!ENDIF - -# Begin Target - -# Name "xmlwf - Win32 Release" -# Name "xmlwf - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat;for;f90" -# Begin Source File - -SOURCE=.\codepage.c -# End Source File -# Begin Source File - -SOURCE=.\readfilemap.c -# PROP Exclude_From_Build 1 -# End Source File -# Begin Source File - -SOURCE=.\unixfilemap.c -# PROP Exclude_From_Build 1 -# End Source File -# Begin Source File - -SOURCE=.\win32filemap.c -# End Source File -# Begin Source File - -SOURCE=.\xmlfile.c -# End Source File -# Begin Source File - -SOURCE=.\xmlwf.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl;fi;fd" -# Begin Source File - -SOURCE=.\codepage.h -# End Source File -# Begin Source File - -SOURCE=.\xmlfile.h -# End Source File -# Begin Source File - -SOURCE=.\xmltchar.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;cnt;rtf;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/lib-src/expat/xmlwf/xmlwin32url.cxx b/lib-src/expat/xmlwf/xmlwin32url.cxx deleted file mode 100755 index bbfcce22c..000000000 --- a/lib-src/expat/xmlwf/xmlwin32url.cxx +++ /dev/null @@ -1,395 +0,0 @@ -#include "expat.h" -#ifdef XML_UNICODE -#define UNICODE -#endif -#include -#include -#include -#include -#include -#include "xmlurl.h" -#include "xmlmime.h" - -static int -processURL(XML_Parser parser, IMoniker *baseMoniker, const XML_Char *url); - -typedef void (*StopHandler)(void *, HRESULT); - -class Callback : public IBindStatusCallback { -public: - // IUnknown methods - STDMETHODIMP QueryInterface(REFIID,void **); - STDMETHODIMP_(ULONG) AddRef(); - STDMETHODIMP_(ULONG) Release(); - // IBindStatusCallback methods - STDMETHODIMP OnStartBinding(DWORD, IBinding *); - STDMETHODIMP GetPriority(LONG *); - STDMETHODIMP OnLowResource(DWORD); - STDMETHODIMP OnProgress(ULONG, ULONG, ULONG, LPCWSTR); - STDMETHODIMP OnStopBinding(HRESULT, LPCWSTR); - STDMETHODIMP GetBindInfo(DWORD *, BINDINFO *); - STDMETHODIMP OnDataAvailable(DWORD, DWORD, FORMATETC *, STGMEDIUM *); - STDMETHODIMP OnObjectAvailable(REFIID, IUnknown *); - Callback(XML_Parser, IMoniker *, StopHandler, void *); - ~Callback(); - int externalEntityRef(const XML_Char *context, - const XML_Char *systemId, const XML_Char *publicId); -private: - XML_Parser parser_; - IMoniker *baseMoniker_; - DWORD totalRead_; - ULONG ref_; - IBinding *pBinding_; - StopHandler stopHandler_; - void *stopArg_; -}; - -STDMETHODIMP_(ULONG) -Callback::AddRef() -{ - return ref_++; -} - -STDMETHODIMP_(ULONG) -Callback::Release() -{ - if (--ref_ == 0) { - delete this; - return 0; - } - return ref_; -} - -STDMETHODIMP -Callback::QueryInterface(REFIID riid, void** ppv) -{ - if (IsEqualGUID(riid, IID_IUnknown)) - *ppv = (IUnknown *)this; - else if (IsEqualGUID(riid, IID_IBindStatusCallback)) - *ppv = (IBindStatusCallback *)this; - else - return E_NOINTERFACE; - ((LPUNKNOWN)*ppv)->AddRef(); - return S_OK; -} - -STDMETHODIMP -Callback::OnStartBinding(DWORD, IBinding* pBinding) -{ - pBinding_ = pBinding; - pBinding->AddRef(); - return S_OK; -} - -STDMETHODIMP -Callback::GetPriority(LONG *) -{ - return E_NOTIMPL; -} - -STDMETHODIMP -Callback::OnLowResource(DWORD) -{ - return E_NOTIMPL; -} - -STDMETHODIMP -Callback::OnProgress(ULONG, ULONG, ULONG, LPCWSTR) -{ - return S_OK; -} - -STDMETHODIMP -Callback::OnStopBinding(HRESULT hr, LPCWSTR szError) -{ - if (pBinding_) { - pBinding_->Release(); - pBinding_ = 0; - } - if (baseMoniker_) { - baseMoniker_->Release(); - baseMoniker_ = 0; - } - stopHandler_(stopArg_, hr); - return S_OK; -} - -STDMETHODIMP -Callback::GetBindInfo(DWORD* pgrfBINDF, BINDINFO* pbindinfo) -{ - *pgrfBINDF = BINDF_ASYNCHRONOUS; - return S_OK; -} - -static void -reportError(XML_Parser parser) -{ - int code = XML_GetErrorCode(parser); - const XML_Char *message = XML_ErrorString(code); - if (message) - _ftprintf(stderr, _T("%s:%d:%ld: %s\n"), - XML_GetBase(parser), - XML_GetErrorLineNumber(parser), - XML_GetErrorColumnNumber(parser), - message); - else - _ftprintf(stderr, _T("%s: (unknown message %d)\n"), - XML_GetBase(parser), code); -} - -STDMETHODIMP -Callback::OnDataAvailable(DWORD grfBSCF, - DWORD dwSize, - FORMATETC *pfmtetc, - STGMEDIUM* pstgmed) -{ - if (grfBSCF & BSCF_FIRSTDATANOTIFICATION) { - IWinInetHttpInfo *hp; - HRESULT hr = pBinding_->QueryInterface(IID_IWinInetHttpInfo, - (void **)&hp); - if (SUCCEEDED(hr)) { - char contentType[1024]; - DWORD bufSize = sizeof(contentType); - DWORD flags = 0; - contentType[0] = 0; - hr = hp->QueryInfo(HTTP_QUERY_CONTENT_TYPE, contentType, - &bufSize, 0, NULL); - if (SUCCEEDED(hr)) { - char charset[CHARSET_MAX]; - getXMLCharset(contentType, charset); - if (charset[0]) { -#ifdef XML_UNICODE - XML_Char wcharset[CHARSET_MAX]; - XML_Char *p1 = wcharset; - const char *p2 = charset; - while ((*p1++ = (unsigned char)*p2++) != 0) - ; - XML_SetEncoding(parser_, wcharset); -#else - XML_SetEncoding(parser_, charset); -#endif - } - } - hp->Release(); - } - } - if (!parser_) - return E_ABORT; - if (pstgmed->tymed == TYMED_ISTREAM) { - while (totalRead_ < dwSize) { -#define READ_MAX (64*1024) - DWORD nToRead = dwSize - totalRead_; - if (nToRead > READ_MAX) - nToRead = READ_MAX; - void *buf = XML_GetBuffer(parser_, nToRead); - if (!buf) { - _ftprintf(stderr, _T("out of memory\n")); - return E_ABORT; - } - DWORD nRead; - HRESULT hr = pstgmed->pstm->Read(buf, nToRead, &nRead); - if (SUCCEEDED(hr)) { - totalRead_ += nRead; - if (!XML_ParseBuffer(parser_, - nRead, - (grfBSCF & BSCF_LASTDATANOTIFICATION) != 0 - && totalRead_ == dwSize)) { - reportError(parser_); - return E_ABORT; - } - } - } - } - return S_OK; -} - -STDMETHODIMP -Callback::OnObjectAvailable(REFIID, IUnknown *) -{ - return S_OK; -} - -int -Callback::externalEntityRef(const XML_Char *context, - const XML_Char *systemId, - const XML_Char *publicId) -{ - XML_Parser entParser = XML_ExternalEntityParserCreate(parser_, context, 0); - XML_SetBase(entParser, systemId); - int ret = processURL(entParser, baseMoniker_, systemId); - XML_ParserFree(entParser); - return ret; -} - -Callback::Callback(XML_Parser parser, IMoniker *baseMoniker, - StopHandler stopHandler, void *stopArg) -: parser_(parser), - baseMoniker_(baseMoniker), - ref_(0), - pBinding_(0), - totalRead_(0), - stopHandler_(stopHandler), - stopArg_(stopArg) -{ - if (baseMoniker_) - baseMoniker_->AddRef(); -} - -Callback::~Callback() -{ - if (pBinding_) - pBinding_->Release(); - if (baseMoniker_) - baseMoniker_->Release(); -} - -static int -externalEntityRef(void *arg, - const XML_Char *context, - const XML_Char *base, - const XML_Char *systemId, - const XML_Char *publicId) -{ - return ((Callback *)arg)->externalEntityRef(context, systemId, publicId); -} - - -static HRESULT -openStream(XML_Parser parser, - IMoniker *baseMoniker, - const XML_Char *uri, - StopHandler stopHandler, void *stopArg) -{ - if (!XML_SetBase(parser, uri)) - return E_OUTOFMEMORY; - HRESULT hr; - IMoniker *m; -#ifdef XML_UNICODE - hr = CreateURLMoniker(0, uri, &m); -#else - LPWSTR uriw = new wchar_t[strlen(uri) + 1]; - for (int i = 0;; i++) { - uriw[i] = uri[i]; - if (uriw[i] == 0) - break; - } - hr = CreateURLMoniker(baseMoniker, uriw, &m); - delete [] uriw; -#endif - if (FAILED(hr)) - return hr; - IBindStatusCallback *cb = new Callback(parser, m, stopHandler, stopArg); - XML_SetExternalEntityRefHandler(parser, externalEntityRef); - XML_SetExternalEntityRefHandlerArg(parser, cb); - cb->AddRef(); - IBindCtx *b; - if (FAILED(hr = CreateAsyncBindCtx(0, cb, 0, &b))) { - cb->Release(); - m->Release(); - return hr; - } - cb->Release(); - IStream *pStream; - hr = m->BindToStorage(b, 0, IID_IStream, (void **)&pStream); - if (SUCCEEDED(hr)) { - if (pStream) - pStream->Release(); - } - if (hr == MK_S_ASYNCHRONOUS) - hr = S_OK; - m->Release(); - b->Release(); - return hr; -} - -struct QuitInfo { - const XML_Char *url; - HRESULT hr; - int stop; -}; - -static void -winPerror(const XML_Char *url, HRESULT hr) -{ - LPVOID buf; - if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER - | FORMAT_MESSAGE_FROM_HMODULE, - GetModuleHandleA("urlmon.dll"), - hr, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), - (LPTSTR) &buf, - 0, - NULL) - || FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER - | FORMAT_MESSAGE_FROM_SYSTEM, - 0, - hr, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), - (LPTSTR) &buf, - 0, - NULL)) { - /* The system error messages seem to end with a newline. */ - _ftprintf(stderr, _T("%s: %s"), url, buf); - fflush(stderr); - LocalFree(buf); - } - else - _ftprintf(stderr, _T("%s: error %x\n"), url, hr); -} - -static void -threadQuit(void *p, HRESULT hr) -{ - QuitInfo *qi = (QuitInfo *)p; - qi->hr = hr; - qi->stop = 1; -} - -extern "C" -int -XML_URLInit(void) -{ - return SUCCEEDED(CoInitialize(0)); -} - -extern "C" -void -XML_URLUninit(void) -{ - CoUninitialize(); -} - -static int -processURL(XML_Parser parser, IMoniker *baseMoniker, - const XML_Char *url) -{ - QuitInfo qi; - qi.stop = 0; - qi.url = url; - - XML_SetBase(parser, url); - HRESULT hr = openStream(parser, baseMoniker, url, threadQuit, &qi); - if (FAILED(hr)) { - winPerror(url, hr); - return 0; - } - else if (FAILED(qi.hr)) { - winPerror(url, qi.hr); - return 0; - } - MSG msg; - while (!qi.stop && GetMessage (&msg, NULL, 0, 0)) { - TranslateMessage (&msg); - DispatchMessage (&msg); - } - return 1; -} - -extern "C" -int -XML_ProcessURL(XML_Parser parser, - const XML_Char *url, - unsigned flags) -{ - return processURL(parser, 0, url); -} diff --git a/lib-src/lame/lame/lame.h b/lib-src/lame/lame/lame.h deleted file mode 100644 index 5196690ff..000000000 --- a/lib-src/lame/lame/lame.h +++ /dev/null @@ -1,1342 +0,0 @@ -/* - * Interface to MP3 LAME encoding engine - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: lame.h,v 1.192 2017/08/31 14:14:46 robert Exp $ */ - -#ifndef LAME_LAME_H -#define LAME_LAME_H - -/* for size_t typedef */ -#include -/* for va_list typedef */ -#include -/* for FILE typedef, TODO: remove when removing lame_mp3_tags_fid */ -#include - -#if defined(__cplusplus) -extern "C" { -#endif - -typedef void (*lame_report_function)(const char *format, va_list ap); - -#if defined(WIN32) || defined(_WIN32) -#undef CDECL -#define CDECL __cdecl -#else -#define CDECL -#endif - -#define DEPRECATED_OR_OBSOLETE_CODE_REMOVED 1 - -typedef enum vbr_mode_e { - vbr_off=0, - vbr_mt, /* obsolete, same as vbr_mtrh */ - vbr_rh, - vbr_abr, - vbr_mtrh, - vbr_max_indicator, /* Don't use this! It's used for sanity checks. */ - vbr_default=vbr_mtrh /* change this to change the default VBR mode of LAME */ -} vbr_mode; - - -/* MPEG modes */ -typedef enum MPEG_mode_e { - STEREO = 0, - JOINT_STEREO, - DUAL_CHANNEL, /* LAME doesn't supports this! */ - MONO, - NOT_SET, - MAX_INDICATOR /* Don't use this! It's used for sanity checks. */ -} MPEG_mode; - -/* Padding types */ -typedef enum Padding_type_e { - PAD_NO = 0, - PAD_ALL, - PAD_ADJUST, - PAD_MAX_INDICATOR /* Don't use this! It's used for sanity checks. */ -} Padding_type; - - - -/*presets*/ -typedef enum preset_mode_e { - /*values from 8 to 320 should be reserved for abr bitrates*/ - /*for abr I'd suggest to directly use the targeted bitrate as a value*/ - ABR_8 = 8, - ABR_320 = 320, - - V9 = 410, /*Vx to match Lame and VBR_xx to match FhG*/ - VBR_10 = 410, - V8 = 420, - VBR_20 = 420, - V7 = 430, - VBR_30 = 430, - V6 = 440, - VBR_40 = 440, - V5 = 450, - VBR_50 = 450, - V4 = 460, - VBR_60 = 460, - V3 = 470, - VBR_70 = 470, - V2 = 480, - VBR_80 = 480, - V1 = 490, - VBR_90 = 490, - V0 = 500, - VBR_100 = 500, - - - - /*still there for compatibility*/ - R3MIX = 1000, - STANDARD = 1001, - EXTREME = 1002, - INSANE = 1003, - STANDARD_FAST = 1004, - EXTREME_FAST = 1005, - MEDIUM = 1006, - MEDIUM_FAST = 1007 -} preset_mode; - - -/*asm optimizations*/ -typedef enum asm_optimizations_e { - MMX = 1, - AMD_3DNOW = 2, - SSE = 3 -} asm_optimizations; - - -/* psychoacoustic model */ -typedef enum Psy_model_e { - PSY_GPSYCHO = 1, - PSY_NSPSYTUNE = 2 -} Psy_model; - - -/* buffer considerations */ -typedef enum buffer_constraint_e { - MDB_DEFAULT=0, - MDB_STRICT_ISO=1, - MDB_MAXIMUM=2 -} buffer_constraint; - - -struct lame_global_struct; -typedef struct lame_global_struct lame_global_flags; -typedef lame_global_flags *lame_t; - - - - -/*********************************************************************** - * - * The LAME API - * These functions should be called, in this order, for each - * MP3 file to be encoded. See the file "API" for more documentation - * - ***********************************************************************/ - - -/* - * REQUIRED: - * initialize the encoder. sets default for all encoder parameters, - * returns NULL if some malloc()'s failed - * otherwise returns pointer to structure needed for all future - * API calls. - */ -lame_global_flags * CDECL lame_init(void); -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* obsolete version */ -int CDECL lame_init_old(lame_global_flags *); -#endif - -/* - * OPTIONAL: - * set as needed to override defaults - */ - -/******************************************************************** - * input stream description - ***********************************************************************/ -/* number of samples. default = 2^32-1 */ -int CDECL lame_set_num_samples(lame_global_flags *, unsigned long); -unsigned long CDECL lame_get_num_samples(const lame_global_flags *); - -/* input sample rate in Hz. default = 44100hz */ -int CDECL lame_set_in_samplerate(lame_global_flags *, int); -int CDECL lame_get_in_samplerate(const lame_global_flags *); - -/* number of channels in input stream. default=2 */ -int CDECL lame_set_num_channels(lame_global_flags *, int); -int CDECL lame_get_num_channels(const lame_global_flags *); - -/* - scale the input by this amount before encoding. default=1 - (not used by decoding routines) -*/ -int CDECL lame_set_scale(lame_global_flags *, float); -float CDECL lame_get_scale(const lame_global_flags *); - -/* - scale the channel 0 (left) input by this amount before encoding. default=1 - (not used by decoding routines) -*/ -int CDECL lame_set_scale_left(lame_global_flags *, float); -float CDECL lame_get_scale_left(const lame_global_flags *); - -/* - scale the channel 1 (right) input by this amount before encoding. default=1 - (not used by decoding routines) -*/ -int CDECL lame_set_scale_right(lame_global_flags *, float); -float CDECL lame_get_scale_right(const lame_global_flags *); - -/* - output sample rate in Hz. default = 0, which means LAME picks best value - based on the amount of compression. MPEG only allows: - MPEG1 32, 44.1, 48khz - MPEG2 16, 22.05, 24 - MPEG2.5 8, 11.025, 12 - (not used by decoding routines) -*/ -int CDECL lame_set_out_samplerate(lame_global_flags *, int); -int CDECL lame_get_out_samplerate(const lame_global_flags *); - - -/******************************************************************** - * general control parameters - ***********************************************************************/ -/* 1=cause LAME to collect data for an MP3 frame analyzer. default=0 */ -int CDECL lame_set_analysis(lame_global_flags *, int); -int CDECL lame_get_analysis(const lame_global_flags *); - -/* - 1 = write a Xing VBR header frame. - default = 1 - this variable must have been added by a Hungarian notation Windows programmer :-) -*/ -int CDECL lame_set_bWriteVbrTag(lame_global_flags *, int); -int CDECL lame_get_bWriteVbrTag(const lame_global_flags *); - -/* 1=decode only. use lame/mpglib to convert mp3/ogg to wav. default=0 */ -int CDECL lame_set_decode_only(lame_global_flags *, int); -int CDECL lame_get_decode_only(const lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* 1=encode a Vorbis .ogg file. default=0 */ -/* DEPRECATED */ -int CDECL lame_set_ogg(lame_global_flags *, int); -int CDECL lame_get_ogg(const lame_global_flags *); -#endif - -/* - internal algorithm selection. True quality is determined by the bitrate - but this variable will effect quality by selecting expensive or cheap algorithms. - quality=0..9. 0=best (very slow). 9=worst. - recommended: 2 near-best quality, not too slow - 5 good quality, fast - 7 ok quality, really fast -*/ -int CDECL lame_set_quality(lame_global_flags *, int); -int CDECL lame_get_quality(const lame_global_flags *); - -/* - mode = 0,1,2,3 = stereo, jstereo, dual channel (not supported), mono - default: lame picks based on compression ration and input channels -*/ -int CDECL lame_set_mode(lame_global_flags *, MPEG_mode); -MPEG_mode CDECL lame_get_mode(const lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* - mode_automs. Use a M/S mode with a switching threshold based on - compression ratio - DEPRECATED -*/ -int CDECL lame_set_mode_automs(lame_global_flags *, int); -int CDECL lame_get_mode_automs(const lame_global_flags *); -#endif - -/* - force_ms. Force M/S for all frames. For testing only. - default = 0 (disabled) -*/ -int CDECL lame_set_force_ms(lame_global_flags *, int); -int CDECL lame_get_force_ms(const lame_global_flags *); - -/* use free_format? default = 0 (disabled) */ -int CDECL lame_set_free_format(lame_global_flags *, int); -int CDECL lame_get_free_format(const lame_global_flags *); - -/* perform ReplayGain analysis? default = 0 (disabled) */ -int CDECL lame_set_findReplayGain(lame_global_flags *, int); -int CDECL lame_get_findReplayGain(const lame_global_flags *); - -/* decode on the fly. Search for the peak sample. If the ReplayGain - * analysis is enabled then perform the analysis on the decoded data - * stream. default = 0 (disabled) - * NOTE: if this option is set the build-in decoder should not be used */ -int CDECL lame_set_decode_on_the_fly(lame_global_flags *, int); -int CDECL lame_get_decode_on_the_fly(const lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* DEPRECATED: now does the same as lame_set_findReplayGain() - default = 0 (disabled) */ -int CDECL lame_set_ReplayGain_input(lame_global_flags *, int); -int CDECL lame_get_ReplayGain_input(const lame_global_flags *); - -/* DEPRECATED: now does the same as - lame_set_decode_on_the_fly() && lame_set_findReplayGain() - default = 0 (disabled) */ -int CDECL lame_set_ReplayGain_decode(lame_global_flags *, int); -int CDECL lame_get_ReplayGain_decode(const lame_global_flags *); - -/* DEPRECATED: now does the same as lame_set_decode_on_the_fly() - default = 0 (disabled) */ -int CDECL lame_set_findPeakSample(lame_global_flags *, int); -int CDECL lame_get_findPeakSample(const lame_global_flags *); -#endif - -/* counters for gapless encoding */ -int CDECL lame_set_nogap_total(lame_global_flags*, int); -int CDECL lame_get_nogap_total(const lame_global_flags*); - -int CDECL lame_set_nogap_currentindex(lame_global_flags* , int); -int CDECL lame_get_nogap_currentindex(const lame_global_flags*); - - -/* - * OPTIONAL: - * Set printf like error/debug/message reporting functions. - * The second argument has to be a pointer to a function which looks like - * void my_debugf(const char *format, va_list ap) - * { - * (void) vfprintf(stdout, format, ap); - * } - * If you use NULL as the value of the pointer in the set function, the - * lame buildin function will be used (prints to stderr). - * To quiet any output you have to replace the body of the example function - * with just "return;" and use it in the set function. - */ -int CDECL lame_set_errorf(lame_global_flags *, lame_report_function); -int CDECL lame_set_debugf(lame_global_flags *, lame_report_function); -int CDECL lame_set_msgf (lame_global_flags *, lame_report_function); - - - -/* set one of brate compression ratio. default is compression ratio of 11. */ -int CDECL lame_set_brate(lame_global_flags *, int); -int CDECL lame_get_brate(const lame_global_flags *); -int CDECL lame_set_compression_ratio(lame_global_flags *, float); -float CDECL lame_get_compression_ratio(const lame_global_flags *); - - -int CDECL lame_set_preset( lame_global_flags* gfp, int ); -int CDECL lame_set_asm_optimizations( lame_global_flags* gfp, int, int ); - - - -/******************************************************************** - * frame params - ***********************************************************************/ -/* mark as copyright. default=0 */ -int CDECL lame_set_copyright(lame_global_flags *, int); -int CDECL lame_get_copyright(const lame_global_flags *); - -/* mark as original. default=1 */ -int CDECL lame_set_original(lame_global_flags *, int); -int CDECL lame_get_original(const lame_global_flags *); - -/* error_protection. Use 2 bytes from each frame for CRC checksum. default=0 */ -int CDECL lame_set_error_protection(lame_global_flags *, int); -int CDECL lame_get_error_protection(const lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* padding_type. 0=pad no frames 1=pad all frames 2=adjust padding(default) */ -int CDECL lame_set_padding_type(lame_global_flags *, Padding_type); -Padding_type CDECL lame_get_padding_type(const lame_global_flags *); -#endif - -/* MP3 'private extension' bit Meaningless. default=0 */ -int CDECL lame_set_extension(lame_global_flags *, int); -int CDECL lame_get_extension(const lame_global_flags *); - -/* enforce strict ISO compliance. default=0 */ -int CDECL lame_set_strict_ISO(lame_global_flags *, int); -int CDECL lame_get_strict_ISO(const lame_global_flags *); - - -/******************************************************************** - * quantization/noise shaping - ***********************************************************************/ - -/* disable the bit reservoir. For testing only. default=0 */ -int CDECL lame_set_disable_reservoir(lame_global_flags *, int); -int CDECL lame_get_disable_reservoir(const lame_global_flags *); - -/* select a different "best quantization" function. default=0 */ -int CDECL lame_set_quant_comp(lame_global_flags *, int); -int CDECL lame_get_quant_comp(const lame_global_flags *); -int CDECL lame_set_quant_comp_short(lame_global_flags *, int); -int CDECL lame_get_quant_comp_short(const lame_global_flags *); - -int CDECL lame_set_experimentalX(lame_global_flags *, int); /* compatibility*/ -int CDECL lame_get_experimentalX(const lame_global_flags *); - -/* another experimental option. for testing only */ -int CDECL lame_set_experimentalY(lame_global_flags *, int); -int CDECL lame_get_experimentalY(const lame_global_flags *); - -/* another experimental option. for testing only */ -int CDECL lame_set_experimentalZ(lame_global_flags *, int); -int CDECL lame_get_experimentalZ(const lame_global_flags *); - -/* Naoki's psycho acoustic model. default=0 */ -int CDECL lame_set_exp_nspsytune(lame_global_flags *, int); -int CDECL lame_get_exp_nspsytune(const lame_global_flags *); - -void CDECL lame_set_msfix(lame_global_flags *, double); -float CDECL lame_get_msfix(const lame_global_flags *); - - -/******************************************************************** - * VBR control - ***********************************************************************/ -/* Types of VBR. default = vbr_off = CBR */ -int CDECL lame_set_VBR(lame_global_flags *, vbr_mode); -vbr_mode CDECL lame_get_VBR(const lame_global_flags *); - -/* VBR quality level. 0=highest 9=lowest */ -int CDECL lame_set_VBR_q(lame_global_flags *, int); -int CDECL lame_get_VBR_q(const lame_global_flags *); - -/* VBR quality level. 0=highest 9=lowest, Range [0,...,10[ */ -int CDECL lame_set_VBR_quality(lame_global_flags *, float); -float CDECL lame_get_VBR_quality(const lame_global_flags *); - -/* Ignored except for VBR=vbr_abr (ABR mode) */ -int CDECL lame_set_VBR_mean_bitrate_kbps(lame_global_flags *, int); -int CDECL lame_get_VBR_mean_bitrate_kbps(const lame_global_flags *); - -int CDECL lame_set_VBR_min_bitrate_kbps(lame_global_flags *, int); -int CDECL lame_get_VBR_min_bitrate_kbps(const lame_global_flags *); - -int CDECL lame_set_VBR_max_bitrate_kbps(lame_global_flags *, int); -int CDECL lame_get_VBR_max_bitrate_kbps(const lame_global_flags *); - -/* - 1=strictly enforce VBR_min_bitrate. Normally it will be violated for - analog silence -*/ -int CDECL lame_set_VBR_hard_min(lame_global_flags *, int); -int CDECL lame_get_VBR_hard_min(const lame_global_flags *); - -/* for preset */ -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -int CDECL lame_set_preset_expopts(lame_global_flags *, int); -#endif - -/******************************************************************** - * Filtering control - ***********************************************************************/ -/* freq in Hz to apply lowpass. Default = 0 = lame chooses. -1 = disabled */ -int CDECL lame_set_lowpassfreq(lame_global_flags *, int); -int CDECL lame_get_lowpassfreq(const lame_global_flags *); -/* width of transition band, in Hz. Default = one polyphase filter band */ -int CDECL lame_set_lowpasswidth(lame_global_flags *, int); -int CDECL lame_get_lowpasswidth(const lame_global_flags *); - -/* freq in Hz to apply highpass. Default = 0 = lame chooses. -1 = disabled */ -int CDECL lame_set_highpassfreq(lame_global_flags *, int); -int CDECL lame_get_highpassfreq(const lame_global_flags *); -/* width of transition band, in Hz. Default = one polyphase filter band */ -int CDECL lame_set_highpasswidth(lame_global_flags *, int); -int CDECL lame_get_highpasswidth(const lame_global_flags *); - - -/******************************************************************** - * psycho acoustics and other arguments which you should not change - * unless you know what you are doing - ***********************************************************************/ - -/* only use ATH for masking */ -int CDECL lame_set_ATHonly(lame_global_flags *, int); -int CDECL lame_get_ATHonly(const lame_global_flags *); - -/* only use ATH for short blocks */ -int CDECL lame_set_ATHshort(lame_global_flags *, int); -int CDECL lame_get_ATHshort(const lame_global_flags *); - -/* disable ATH */ -int CDECL lame_set_noATH(lame_global_flags *, int); -int CDECL lame_get_noATH(const lame_global_flags *); - -/* select ATH formula */ -int CDECL lame_set_ATHtype(lame_global_flags *, int); -int CDECL lame_get_ATHtype(const lame_global_flags *); - -/* lower ATH by this many db */ -int CDECL lame_set_ATHlower(lame_global_flags *, float); -float CDECL lame_get_ATHlower(const lame_global_flags *); - -/* select ATH adaptive adjustment type */ -int CDECL lame_set_athaa_type( lame_global_flags *, int); -int CDECL lame_get_athaa_type( const lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* select the loudness approximation used by the ATH adaptive auto-leveling */ -int CDECL lame_set_athaa_loudapprox( lame_global_flags *, int); -int CDECL lame_get_athaa_loudapprox( const lame_global_flags *); -#endif - -/* adjust (in dB) the point below which adaptive ATH level adjustment occurs */ -int CDECL lame_set_athaa_sensitivity( lame_global_flags *, float); -float CDECL lame_get_athaa_sensitivity( const lame_global_flags* ); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* OBSOLETE: predictability limit (ISO tonality formula) */ -int CDECL lame_set_cwlimit(lame_global_flags *, int); -int CDECL lame_get_cwlimit(const lame_global_flags *); -#endif - -/* - allow blocktypes to differ between channels? - default: 0 for jstereo, 1 for stereo -*/ -int CDECL lame_set_allow_diff_short(lame_global_flags *, int); -int CDECL lame_get_allow_diff_short(const lame_global_flags *); - -/* use temporal masking effect (default = 1) */ -int CDECL lame_set_useTemporal(lame_global_flags *, int); -int CDECL lame_get_useTemporal(const lame_global_flags *); - -/* use temporal masking effect (default = 1) */ -int CDECL lame_set_interChRatio(lame_global_flags *, float); -float CDECL lame_get_interChRatio(const lame_global_flags *); - -/* disable short blocks */ -int CDECL lame_set_no_short_blocks(lame_global_flags *, int); -int CDECL lame_get_no_short_blocks(const lame_global_flags *); - -/* force short blocks */ -int CDECL lame_set_force_short_blocks(lame_global_flags *, int); -int CDECL lame_get_force_short_blocks(const lame_global_flags *); - -/* Input PCM is emphased PCM (for instance from one of the rarely - emphased CDs), it is STRONGLY not recommended to use this, because - psycho does not take it into account, and last but not least many decoders - ignore these bits */ -int CDECL lame_set_emphasis(lame_global_flags *, int); -int CDECL lame_get_emphasis(const lame_global_flags *); - - - -/************************************************************************/ -/* internal variables, cannot be set... */ -/* provided because they may be of use to calling application */ -/************************************************************************/ -/* version 0=MPEG-2 1=MPEG-1 (2=MPEG-2.5) */ -int CDECL lame_get_version(const lame_global_flags *); - -/* encoder delay */ -int CDECL lame_get_encoder_delay(const lame_global_flags *); - -/* - padding appended to the input to make sure decoder can fully decode - all input. Note that this value can only be calculated during the - call to lame_encoder_flush(). Before lame_encoder_flush() has - been called, the value of encoder_padding = 0. -*/ -int CDECL lame_get_encoder_padding(const lame_global_flags *); - -/* size of MPEG frame */ -int CDECL lame_get_framesize(const lame_global_flags *); - -/* number of PCM samples buffered, but not yet encoded to mp3 data. */ -int CDECL lame_get_mf_samples_to_encode( const lame_global_flags* gfp ); - -/* - size (bytes) of mp3 data buffered, but not yet encoded. - this is the number of bytes which would be output by a call to - lame_encode_flush_nogap. NOTE: lame_encode_flush() will return - more bytes than this because it will encode the reamining buffered - PCM samples before flushing the mp3 buffers. -*/ -int CDECL lame_get_size_mp3buffer( const lame_global_flags* gfp ); - -/* number of frames encoded so far */ -int CDECL lame_get_frameNum(const lame_global_flags *); - -/* - lame's estimate of the total number of frames to be encoded - only valid if calling program set num_samples -*/ -int CDECL lame_get_totalframes(const lame_global_flags *); - -/* RadioGain value. Multiplied by 10 and rounded to the nearest. */ -int CDECL lame_get_RadioGain(const lame_global_flags *); - -/* AudiophileGain value. Multipled by 10 and rounded to the nearest. */ -int CDECL lame_get_AudiophileGain(const lame_global_flags *); - -/* the peak sample */ -float CDECL lame_get_PeakSample(const lame_global_flags *); - -/* Gain change required for preventing clipping. The value is correct only if - peak sample searching was enabled. If negative then the waveform - already does not clip. The value is multiplied by 10 and rounded up. */ -int CDECL lame_get_noclipGainChange(const lame_global_flags *); - -/* user-specified scale factor required for preventing clipping. Value is - correct only if peak sample searching was enabled and no user-specified - scaling was performed. If negative then either the waveform already does - not clip or the value cannot be determined */ -float CDECL lame_get_noclipScale(const lame_global_flags *); - -/* returns the limit of PCM samples, which one can pass in an encode call - under the constrain of a provided buffer of size buffer_size */ -int CDECL lame_get_maximum_number_of_samples(lame_t gfp, size_t buffer_size); - - - - -/* - * REQUIRED: - * sets more internal configuration based on data provided above. - * returns -1 if something failed. - */ -int CDECL lame_init_params(lame_global_flags *); - - -/* - * OPTIONAL: - * get the version number, in a string. of the form: - * "3.63 (beta)" or just "3.63". - */ -const char* CDECL get_lame_version ( void ); -const char* CDECL get_lame_short_version ( void ); -const char* CDECL get_lame_very_short_version ( void ); -const char* CDECL get_psy_version ( void ); -const char* CDECL get_lame_url ( void ); -const char* CDECL get_lame_os_bitness ( void ); - -/* - * OPTIONAL: - * get the version numbers in numerical form. - */ -typedef struct { - /* generic LAME version */ - int major; - int minor; - int alpha; /* 0 if not an alpha version */ - int beta; /* 0 if not a beta version */ - - /* version of the psy model */ - int psy_major; - int psy_minor; - int psy_alpha; /* 0 if not an alpha version */ - int psy_beta; /* 0 if not a beta version */ - - /* compile time features */ - const char *features; /* Don't make assumptions about the contents! */ -} lame_version_t; -void CDECL get_lame_version_numerical(lame_version_t *); - - -/* - * OPTIONAL: - * print internal lame configuration to message handler - */ -void CDECL lame_print_config(const lame_global_flags* gfp); - -void CDECL lame_print_internals( const lame_global_flags *gfp); - - -/* - * input pcm data, output (maybe) mp3 frames. - * This routine handles all buffering, resampling and filtering for you. - * - * return code number of bytes output in mp3buf. Can be 0 - * -1: mp3buf was too small - * -2: malloc() problem - * -3: lame_init_params() not called - * -4: psycho acoustic problems - * - * The required mp3buf_size can be computed from num_samples, - * samplerate and encoding rate, but here is a worst case estimate: - * - * mp3buf_size in bytes = 1.25*num_samples + 7200 - * - * I think a tighter bound could be: (mt, March 2000) - * MPEG1: - * num_samples*(bitrate/8)/samplerate + 4*1152*(bitrate/8)/samplerate + 512 - * MPEG2: - * num_samples*(bitrate/8)/samplerate + 4*576*(bitrate/8)/samplerate + 256 - * - * but test first if you use that! - * - * set mp3buf_size = 0 and LAME will not check if mp3buf_size is - * large enough. - * - * NOTE: - * if gfp->num_channels=2, but gfp->mode = 3 (mono), the L & R channels - * will be averaged into the L channel before encoding only the L channel - * This will overwrite the data in buffer_l[] and buffer_r[]. - * -*/ -int CDECL lame_encode_buffer ( - lame_global_flags* gfp, /* global context handle */ - const short int buffer_l [], /* PCM data for left channel */ - const short int buffer_r [], /* PCM data for right channel */ - const int nsamples, /* number of samples per channel */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - -/* - * as above, but input has L & R channel data interleaved. - * NOTE: - * num_samples = number of samples in the L (or R) - * channel, not the total number of samples in pcm[] - */ -int CDECL lame_encode_buffer_interleaved( - lame_global_flags* gfp, /* global context handlei */ - short int pcm[], /* PCM data for left and right - channel, interleaved */ - int num_samples, /* number of samples per channel, - _not_ number of samples in - pcm[] */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - int mp3buf_size ); /* number of valid octets in this - stream */ - - -/* as lame_encode_buffer, but for 'float's. - * !! NOTE: !! data must still be scaled to be in the same range as - * short int, +/- 32768 - */ -int CDECL lame_encode_buffer_float( - lame_global_flags* gfp, /* global context handle */ - const float pcm_l [], /* PCM data for left channel */ - const float pcm_r [], /* PCM data for right channel */ - const int nsamples, /* number of samples per channel */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - -/* as lame_encode_buffer, but for 'float's. - * !! NOTE: !! data must be scaled to +/- 1 full scale - */ -int CDECL lame_encode_buffer_ieee_float( - lame_t gfp, - const float pcm_l [], /* PCM data for left channel */ - const float pcm_r [], /* PCM data for right channel */ - const int nsamples, - unsigned char * mp3buf, - const int mp3buf_size); -int CDECL lame_encode_buffer_interleaved_ieee_float( - lame_t gfp, - const float pcm[], /* PCM data for left and right - channel, interleaved */ - const int nsamples, - unsigned char * mp3buf, - const int mp3buf_size); - -/* as lame_encode_buffer, but for 'double's. - * !! NOTE: !! data must be scaled to +/- 1 full scale - */ -int CDECL lame_encode_buffer_ieee_double( - lame_t gfp, - const double pcm_l [], /* PCM data for left channel */ - const double pcm_r [], /* PCM data for right channel */ - const int nsamples, - unsigned char * mp3buf, - const int mp3buf_size); -int CDECL lame_encode_buffer_interleaved_ieee_double( - lame_t gfp, - const double pcm[], /* PCM data for left and right - channel, interleaved */ - const int nsamples, - unsigned char * mp3buf, - const int mp3buf_size); - -/* as lame_encode_buffer, but for long's - * !! NOTE: !! data must still be scaled to be in the same range as - * short int, +/- 32768 - * - * This scaling was a mistake (doesn't allow one to exploit full - * precision of type 'long'. Use lame_encode_buffer_long2() instead. - * - */ -int CDECL lame_encode_buffer_long( - lame_global_flags* gfp, /* global context handle */ - const long buffer_l [], /* PCM data for left channel */ - const long buffer_r [], /* PCM data for right channel */ - const int nsamples, /* number of samples per channel */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - -/* Same as lame_encode_buffer_long(), but with correct scaling. - * !! NOTE: !! data must still be scaled to be in the same range as - * type 'long'. Data should be in the range: +/- 2^(8*size(long)-1) - * - */ -int CDECL lame_encode_buffer_long2( - lame_global_flags* gfp, /* global context handle */ - const long buffer_l [], /* PCM data for left channel */ - const long buffer_r [], /* PCM data for right channel */ - const int nsamples, /* number of samples per channel */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - -/* as lame_encode_buffer, but for int's - * !! NOTE: !! input should be scaled to the maximum range of 'int' - * If int is 4 bytes, then the values should range from - * +/- 2147483648. - * - * This routine does not (and cannot, without loosing precision) use - * the same scaling as the rest of the lame_encode_buffer() routines. - * - */ -int CDECL lame_encode_buffer_int( - lame_global_flags* gfp, /* global context handle */ - const int buffer_l [], /* PCM data for left channel */ - const int buffer_r [], /* PCM data for right channel */ - const int nsamples, /* number of samples per channel */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - -/* - * as above, but for interleaved data. - * !! NOTE: !! data must still be scaled to be in the same range as - * type 'int32_t'. Data should be in the range: +/- 2^(8*size(int32_t)-1) - * NOTE: - * num_samples = number of samples in the L (or R) - * channel, not the total number of samples in pcm[] - */ -int -lame_encode_buffer_interleaved_int( - lame_t gfp, - const int pcm [], /* PCM data for left and right - channel, interleaved */ - const int nsamples, /* number of samples per channel, - _not_ number of samples in - pcm[] */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - const int mp3buf_size ); /* number of valid octets in this - stream */ - - - -/* - * REQUIRED: - * lame_encode_flush will flush the intenal PCM buffers, padding with - * 0's to make sure the final frame is complete, and then flush - * the internal MP3 buffers, and thus may return a - * final few mp3 frames. 'mp3buf' should be at least 7200 bytes long - * to hold all possible emitted data. - * - * will also write id3v1 tags (if any) into the bitstream - * - * return code = number of bytes output to mp3buf. Can be 0 - */ -int CDECL lame_encode_flush( - lame_global_flags * gfp, /* global context handle */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - int size); /* number of valid octets in this stream */ - -/* - * OPTIONAL: - * lame_encode_flush_nogap will flush the internal mp3 buffers and pad - * the last frame with ancillary data so it is a complete mp3 frame. - * - * 'mp3buf' should be at least 7200 bytes long - * to hold all possible emitted data. - * - * After a call to this routine, the outputed mp3 data is complete, but - * you may continue to encode new PCM samples and write future mp3 data - * to a different file. The two mp3 files will play back with no gaps - * if they are concatenated together. - * - * This routine will NOT write id3v1 tags into the bitstream. - * - * return code = number of bytes output to mp3buf. Can be 0 - */ -int CDECL lame_encode_flush_nogap( - lame_global_flags * gfp, /* global context handle */ - unsigned char* mp3buf, /* pointer to encoded MP3 stream */ - int size); /* number of valid octets in this stream */ - -/* - * OPTIONAL: - * Normally, this is called by lame_init_params(). It writes id3v2 and - * Xing headers into the front of the bitstream, and sets frame counters - * and bitrate histogram data to 0. You can also call this after - * lame_encode_flush_nogap(). - */ -int CDECL lame_init_bitstream( - lame_global_flags * gfp); /* global context handle */ - - - -/* - * OPTIONAL: some simple statistics - * a bitrate histogram to visualize the distribution of used frame sizes - * a stereo mode histogram to visualize the distribution of used stereo - * modes, useful in joint-stereo mode only - * 0: LR left-right encoded - * 1: LR-I left-right and intensity encoded (currently not supported) - * 2: MS mid-side encoded - * 3: MS-I mid-side and intensity encoded (currently not supported) - * - * attention: don't call them after lame_encode_finish - * suggested: lame_encode_flush -> lame_*_hist -> lame_close - */ - -void CDECL lame_bitrate_hist( - const lame_global_flags * gfp, - int bitrate_count[14] ); -void CDECL lame_bitrate_kbps( - const lame_global_flags * gfp, - int bitrate_kbps [14] ); -void CDECL lame_stereo_mode_hist( - const lame_global_flags * gfp, - int stereo_mode_count[4] ); - -void CDECL lame_bitrate_stereo_mode_hist ( - const lame_global_flags * gfp, - int bitrate_stmode_count[14][4] ); - -void CDECL lame_block_type_hist ( - const lame_global_flags * gfp, - int btype_count[6] ); - -void CDECL lame_bitrate_block_type_hist ( - const lame_global_flags * gfp, - int bitrate_btype_count[14][6] ); - -#if (DEPRECATED_OR_OBSOLETE_CODE_REMOVED && 0) -#else -/* - * OPTIONAL: - * lame_mp3_tags_fid will rewrite a Xing VBR tag to the mp3 file with file - * pointer fid. These calls perform forward and backwards seeks, so make - * sure fid is a real file. Make sure lame_encode_flush has been called, - * and all mp3 data has been written to the file before calling this - * function. - * NOTE: - * if VBR tags are turned off by the user, or turned off by LAME because - * the output is not a regular file, this call does nothing - * NOTE: - * LAME wants to read from the file to skip an optional ID3v2 tag, so - * make sure you opened the file for writing and reading. - * NOTE: - * You can call lame_get_lametag_frame instead, if you want to insert - * the lametag yourself. -*/ -void CDECL lame_mp3_tags_fid(lame_global_flags *, FILE* fid); -#endif - -/* - * OPTIONAL: - * lame_get_lametag_frame copies the final LAME-tag into 'buffer'. - * The function returns the number of bytes copied into buffer, or - * the required buffer size, if the provided buffer is too small. - * Function failed, if the return value is larger than 'size'! - * Make sure lame_encode flush has been called before calling this function. - * NOTE: - * if VBR tags are turned off by the user, or turned off by LAME, - * this call does nothing and returns 0. - * NOTE: - * LAME inserted an empty frame in the beginning of mp3 audio data, - * which you have to replace by the final LAME-tag frame after encoding. - * In case there is no ID3v2 tag, usually this frame will be the very first - * data in your mp3 file. If you put some other leading data into your - * file, you'll have to do some bookkeeping about where to write this buffer. - */ -size_t CDECL lame_get_lametag_frame( - const lame_global_flags *, unsigned char* buffer, size_t size); - -/* - * REQUIRED: - * final call to free all remaining buffers - */ -int CDECL lame_close (lame_global_flags *); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* - * OBSOLETE: - * lame_encode_finish combines lame_encode_flush() and lame_close() in - * one call. However, once this call is made, the statistics routines - * will no longer work because the data will have been cleared, and - * lame_mp3_tags_fid() cannot be called to add data to the VBR header - */ -int CDECL lame_encode_finish( - lame_global_flags* gfp, - unsigned char* mp3buf, - int size ); -#endif - - - - - - -/********************************************************************* - * - * decoding - * - * a simple interface to mpglib, part of mpg123, is also included if - * libmp3lame is compiled with HAVE_MPGLIB - * - *********************************************************************/ - -struct hip_global_struct; -typedef struct hip_global_struct hip_global_flags; -typedef hip_global_flags *hip_t; - - -typedef struct { - int header_parsed; /* 1 if header was parsed and following data was - computed */ - int stereo; /* number of channels */ - int samplerate; /* sample rate */ - int bitrate; /* bitrate */ - int mode; /* mp3 frame type */ - int mode_ext; /* mp3 frame type */ - int framesize; /* number of samples per mp3 frame */ - - /* this data is only computed if mpglib detects a Xing VBR header */ - unsigned long nsamp; /* number of samples in mp3 file. */ - int totalframes; /* total number of frames in mp3 file */ - - /* this data is not currently computed by the mpglib routines */ - int framenum; /* frames decoded counter */ -} mp3data_struct; - -/* required call to initialize decoder */ -hip_t CDECL hip_decode_init(void); - -/* cleanup call to exit decoder */ -int CDECL hip_decode_exit(hip_t gfp); - -/* HIP reporting functions */ -void CDECL hip_set_errorf(hip_t gfp, lame_report_function f); -void CDECL hip_set_debugf(hip_t gfp, lame_report_function f); -void CDECL hip_set_msgf (hip_t gfp, lame_report_function f); - -/********************************************************************* - * input 1 mp3 frame, output (maybe) pcm data. - * - * nout = hip_decode(hip, mp3buf,len,pcm_l,pcm_r); - * - * input: - * len : number of bytes of mp3 data in mp3buf - * mp3buf[len] : mp3 data to be decoded - * - * output: - * nout: -1 : decoding error - * 0 : need more data before we can complete the decode - * >0 : returned 'nout' samples worth of data in pcm_l,pcm_r - * pcm_l[nout] : left channel data - * pcm_r[nout] : right channel data - * - *********************************************************************/ -int CDECL hip_decode( hip_t gfp - , unsigned char * mp3buf - , size_t len - , short pcm_l[] - , short pcm_r[] - ); - -/* same as hip_decode, and also returns mp3 header data */ -int CDECL hip_decode_headers( hip_t gfp - , unsigned char* mp3buf - , size_t len - , short pcm_l[] - , short pcm_r[] - , mp3data_struct* mp3data - ); - -/* same as hip_decode, but returns at most one frame */ -int CDECL hip_decode1( hip_t gfp - , unsigned char* mp3buf - , size_t len - , short pcm_l[] - , short pcm_r[] - ); - -/* same as hip_decode1, but returns at most one frame and mp3 header data */ -int CDECL hip_decode1_headers( hip_t gfp - , unsigned char* mp3buf - , size_t len - , short pcm_l[] - , short pcm_r[] - , mp3data_struct* mp3data - ); - -/* same as hip_decode1_headers, but also returns enc_delay and enc_padding - from VBR Info tag, (-1 if no info tag was found) */ -int CDECL hip_decode1_headersB( hip_t gfp - , unsigned char* mp3buf - , size_t len - , short pcm_l[] - , short pcm_r[] - , mp3data_struct* mp3data - , int *enc_delay - , int *enc_padding - ); - - - -/* OBSOLETE: - * lame_decode... functions are there to keep old code working - * but it is strongly recommended to replace calls by hip_decode... - * function calls, see above. - */ -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -int CDECL lame_decode_init(void); -int CDECL lame_decode( - unsigned char * mp3buf, - int len, - short pcm_l[], - short pcm_r[] ); -int CDECL lame_decode_headers( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data ); -int CDECL lame_decode1( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[] ); -int CDECL lame_decode1_headers( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data ); -int CDECL lame_decode1_headersB( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data, - int *enc_delay, - int *enc_padding ); -int CDECL lame_decode_exit(void); - -#endif /* obsolete lame_decode API calls */ - - -/********************************************************************* - * - * id3tag stuff - * - *********************************************************************/ - -/* - * id3tag.h -- Interface to write ID3 version 1 and 2 tags. - * - * Copyright (C) 2000 Don Melton. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. - */ - -/* utility to obtain alphabetically sorted list of genre names with numbers */ -void CDECL id3tag_genre_list( - void (*handler)(int, const char *, void *), - void* cookie); - -void CDECL id3tag_init (lame_t gfp); - -/* force addition of version 2 tag */ -void CDECL id3tag_add_v2 (lame_t gfp); - -/* add only a version 1 tag */ -void CDECL id3tag_v1_only (lame_t gfp); - -/* add only a version 2 tag */ -void CDECL id3tag_v2_only (lame_t gfp); - -/* pad version 1 tag with spaces instead of nulls */ -void CDECL id3tag_space_v1 (lame_t gfp); - -/* pad version 2 tag with extra 128 bytes */ -void CDECL id3tag_pad_v2 (lame_t gfp); - -/* pad version 2 tag with extra n bytes */ -void CDECL id3tag_set_pad (lame_t gfp, size_t n); - -void CDECL id3tag_set_title(lame_t gfp, const char* title); -void CDECL id3tag_set_artist(lame_t gfp, const char* artist); -void CDECL id3tag_set_album(lame_t gfp, const char* album); -void CDECL id3tag_set_year(lame_t gfp, const char* year); -void CDECL id3tag_set_comment(lame_t gfp, const char* comment); - -/* return -1 result if track number is out of ID3v1 range - and ignored for ID3v1 */ -int CDECL id3tag_set_track(lame_t gfp, const char* track); - -/* return non-zero result if genre name or number is invalid - result 0: OK - result -1: genre number out of range - result -2: no valid ID3v1 genre name, mapped to ID3v1 'Other' - but taken as-is for ID3v2 genre tag */ -int CDECL id3tag_set_genre(lame_t gfp, const char* genre); - -/* return non-zero result if field name is invalid */ -int CDECL id3tag_set_fieldvalue(lame_t gfp, const char* fieldvalue); - -/* return non-zero result if image type is invalid */ -int CDECL id3tag_set_albumart(lame_t gfp, const char* image, size_t size); - -/* lame_get_id3v1_tag copies ID3v1 tag into buffer. - * Function returns number of bytes copied into buffer, or number - * of bytes rquired if buffer 'size' is too small. - * Function fails, if returned value is larger than 'size'. - * NOTE: - * This functions does nothing, if user/LAME disabled ID3v1 tag. - */ -size_t CDECL lame_get_id3v1_tag(lame_t gfp, unsigned char* buffer, size_t size); - -/* lame_get_id3v2_tag copies ID3v2 tag into buffer. - * Function returns number of bytes copied into buffer, or number - * of bytes rquired if buffer 'size' is too small. - * Function fails, if returned value is larger than 'size'. - * NOTE: - * This functions does nothing, if user/LAME disabled ID3v2 tag. - */ -size_t CDECL lame_get_id3v2_tag(lame_t gfp, unsigned char* buffer, size_t size); - -/* normaly lame_init_param writes ID3v2 tags into the audio stream - * Call lame_set_write_id3tag_automatic(gfp, 0) before lame_init_param - * to turn off this behaviour and get ID3v2 tag with above function - * write it yourself into your file. - */ -void CDECL lame_set_write_id3tag_automatic(lame_global_flags * gfp, int); -int CDECL lame_get_write_id3tag_automatic(lame_global_flags const* gfp); - -/* experimental */ -int CDECL id3tag_set_textinfo_latin1(lame_t gfp, char const *id, char const *text); - -/* experimental */ -int CDECL id3tag_set_comment_latin1(lame_t gfp, char const *lang, char const *desc, char const *text); - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -#else -/* experimental */ -int CDECL id3tag_set_textinfo_ucs2(lame_t gfp, char const *id, unsigned short const *text); - -/* experimental */ -int CDECL id3tag_set_comment_ucs2(lame_t gfp, char const *lang, - unsigned short const *desc, unsigned short const *text); - -/* experimental */ -int CDECL id3tag_set_fieldvalue_ucs2(lame_t gfp, const unsigned short *fieldvalue); -#endif - -/* experimental */ -int CDECL id3tag_set_fieldvalue_utf16(lame_t gfp, const unsigned short *fieldvalue); - -/* experimental */ -int CDECL id3tag_set_textinfo_utf16(lame_t gfp, char const *id, unsigned short const *text); - -/* experimental */ -int CDECL id3tag_set_comment_utf16(lame_t gfp, char const *lang, unsigned short const *desc, unsigned short const *text); - - -/*********************************************************************** -* -* list of valid bitrates [kbps] & sample frequencies [Hz]. -* first index: 0: MPEG-2 values (sample frequencies 16...24 kHz) -* 1: MPEG-1 values (sample frequencies 32...48 kHz) -* 2: MPEG-2.5 values (sample frequencies 8...12 kHz) -***********************************************************************/ - -extern const int bitrate_table [3][16]; -extern const int samplerate_table [3][ 4]; - -/* access functions for use in DLL, global vars are not exported */ -int CDECL lame_get_bitrate(int mpeg_version, int table_index); -int CDECL lame_get_samplerate(int mpeg_version, int table_index); - - -/* maximum size of albumart image (128KB), which affects LAME_MAXMP3BUFFER - as well since lame_encode_buffer() also returns ID3v2 tag data */ -#define LAME_MAXALBUMART (128 * 1024) - -/* maximum size of mp3buffer needed if you encode at most 1152 samples for - each call to lame_encode_buffer. see lame_encode_buffer() below - (LAME_MAXMP3BUFFER is now obsolete) */ -#define LAME_MAXMP3BUFFER (16384 + LAME_MAXALBUMART) - - -typedef enum { - LAME_OKAY = 0, - LAME_NOERROR = 0, - LAME_GENERICERROR = -1, - LAME_NOMEM = -10, - LAME_BADBITRATE = -11, - LAME_BADSAMPFREQ = -12, - LAME_INTERNALERROR = -13, - - FRONTEND_READERROR = -80, - FRONTEND_WRITEERROR = -81, - FRONTEND_FILETOOLARGE = -82 - -} lame_errorcodes_t; - -#if defined(__cplusplus) -} -#endif -#endif /* LAME_LAME_H */ - diff --git a/lib-src/lame/libmp3lame/Makefile.am b/lib-src/lame/libmp3lame/Makefile.am deleted file mode 100644 index 50cef7580..000000000 --- a/lib-src/lame/libmp3lame/Makefile.am +++ /dev/null @@ -1,102 +0,0 @@ -## $Id: Makefile.am,v 1.41 2016/01/29 21:06:26 aleidinger Exp $ - -include $(top_srcdir)/Makefile.am.global - -SUBDIRS = i386 vector - -lib_LTLIBRARIES = libmp3lame.la - -if HAVE_NASM -cpu_ldadd = $(top_builddir)/libmp3lame/@CPUTYPE@/liblameasmroutines.la -endif -if WITH_VECTOR -vector_ldadd = $(top_builddir)/libmp3lame/vector/liblamevectorroutines.la -endif - -if LIB_WITH_DECODER -decoder_ldadd = $(top_builddir)/mpglib/libmpgdecoder.la -else -decoder_ldadd = -endif - -libmp3lame_la_LIBADD = $(cpu_ldadd) $(vector_ldadd) $(decoder_ldadd) \ - $(CONFIG_MATH_LIB) -libmp3lame_la_LDFLAGS = -version-info @LIB_MAJOR_VERSION@:@LIB_MINOR_VERSION@ \ - -export-symbols $(top_srcdir)/include/libmp3lame.sym \ - -no-undefined - -INCLUDES = @INCLUDES@ -I$(top_srcdir)/mpglib -I$(top_builddir) - -DEFS = @DEFS@ @CONFIG_DEFS@ - -EXTRA_DIST = \ - lame.rc \ - vbrquantize.h \ - logoe.ico - -libmp3lame_la_SOURCES = \ - VbrTag.c \ - bitstream.c \ - encoder.c \ - fft.c \ - gain_analysis.c \ - id3tag.c \ - lame.c \ - newmdct.c \ - presets.c \ - psymodel.c \ - quantize.c \ - quantize_pvt.c \ - reservoir.c \ - set_get.c \ - tables.c \ - takehiro.c \ - util.c \ - vbrquantize.c \ - version.c \ - mpglib_interface.c - -noinst_HEADERS= \ - VbrTag.h \ - bitstream.h \ - encoder.h \ - fft.h \ - gain_analysis.h \ - id3tag.h \ - l3side.h \ - lame-analysis.h \ - lame_global_flags.h \ - lameerror.h \ - machine.h \ - newmdct.h \ - psymodel.h \ - quantize.h \ - quantize_pvt.h \ - reservoir.h \ - set_get.h \ - tables.h \ - util.h \ - vbrquantize.h \ - version.h - -CLEANFILES = lclint.txt - -LCLINTFLAGS= \ - +posixlib \ - +showsummary \ - +showalluses \ - +whichlib \ - +forcehints \ - -fixedformalarray \ - +matchanyintegral \ - -Dlint - -lclint.txt: ${libmp3lame_la_SOURCES} ${noinst_HEADERS} - @lclint ${LCLINTFLAGS} ${INCLUDES} ${DEFS} ${libmp3lame_la_SOURCES} 2>&1 >lclint.txt || true - -lclint: lclint.txt - more lclint.txt - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck diff --git a/lib-src/lame/libmp3lame/Makefile.in b/lib-src/lame/libmp3lame/Makefile.in deleted file mode 100644 index 5437b3891..000000000 --- a/lib-src/lame/libmp3lame/Makefile.in +++ /dev/null @@ -1,904 +0,0 @@ -# Makefile.in generated by automake 1.15.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2017 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# global section for every Makefile.am - - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = libmp3lame -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ - $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ - $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(libdir)" -LTLIBRARIES = $(lib_LTLIBRARIES) -@LIB_WITH_DECODER_TRUE@am__DEPENDENCIES_1 = $(top_builddir)/mpglib/libmpgdecoder.la -am__DEPENDENCIES_2 = -libmp3lame_la_DEPENDENCIES = $(cpu_ldadd) $(vector_ldadd) \ - $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) -am_libmp3lame_la_OBJECTS = VbrTag.lo bitstream.lo encoder.lo fft.lo \ - gain_analysis.lo id3tag.lo lame.lo newmdct.lo presets.lo \ - psymodel.lo quantize.lo quantize_pvt.lo reservoir.lo \ - set_get.lo tables.lo takehiro.lo util.lo vbrquantize.lo \ - version.lo mpglib_interface.lo -libmp3lame_la_OBJECTS = $(am_libmp3lame_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libmp3lame_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(libmp3lame_la_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(libmp3lame_la_SOURCES) -DIST_SOURCES = $(libmp3lame_la_SOURCES) -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -HEADERS = $(noinst_HEADERS) -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -DIST_SUBDIRS = $(SUBDIRS) -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/Makefile.am.global $(top_srcdir)/depcomp depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -ALLOCA = @ALLOCA@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CONFIG_DEFS = @CONFIG_DEFS@ -CONFIG_MATH_LIB = @CONFIG_MATH_LIB@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CPUCCODE = @CPUCCODE@ -CPUTYPE = @CPUTYPE@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ @CONFIG_DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FRONTEND_CFLAGS = @FRONTEND_CFLAGS@ -FRONTEND_LDADD = @FRONTEND_LDADD@ -FRONTEND_LDFLAGS = @FRONTEND_LDFLAGS@ -GREP = @GREP@ -GTK_CFLAGS = @GTK_CFLAGS@ -GTK_CONFIG = @GTK_CONFIG@ -GTK_LIBS = @GTK_LIBS@ -INCLUDES = @INCLUDES@ -I$(top_srcdir)/mpglib -I$(top_builddir) -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDADD = @LDADD@ -LDFLAGS = @LDFLAGS@ -LIBICONV = @LIBICONV@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIB_MAJOR_VERSION = @LIB_MAJOR_VERSION@ -LIB_MINOR_VERSION = @LIB_MINOR_VERSION@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBICONV = @LTLIBICONV@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAINT = @MAINT@ -MAKEDEP = @MAKEDEP@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NASM = @NASM@ -NASM_FORMAT = @NASM_FORMAT@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -RANLIB = @RANLIB@ -RM_F = @RM_F@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SNDFILE_CFLAGS = @SNDFILE_CFLAGS@ -SNDFILE_LIBS = @SNDFILE_LIBS@ -STRIP = @STRIP@ -VERSION = @VERSION@ -WITH_FRONTEND = @WITH_FRONTEND@ -WITH_MP3RTP = @WITH_MP3RTP@ -WITH_MP3X = @WITH_MP3X@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = 1.15 foreign -SUBDIRS = i386 vector -lib_LTLIBRARIES = libmp3lame.la -@HAVE_NASM_TRUE@cpu_ldadd = $(top_builddir)/libmp3lame/@CPUTYPE@/liblameasmroutines.la -@WITH_VECTOR_TRUE@vector_ldadd = $(top_builddir)/libmp3lame/vector/liblamevectorroutines.la -@LIB_WITH_DECODER_FALSE@decoder_ldadd = -@LIB_WITH_DECODER_TRUE@decoder_ldadd = $(top_builddir)/mpglib/libmpgdecoder.la -libmp3lame_la_LIBADD = $(cpu_ldadd) $(vector_ldadd) $(decoder_ldadd) \ - $(CONFIG_MATH_LIB) - -libmp3lame_la_LDFLAGS = -version-info @LIB_MAJOR_VERSION@:@LIB_MINOR_VERSION@ \ - -export-symbols $(top_srcdir)/include/libmp3lame.sym \ - -no-undefined - -EXTRA_DIST = \ - lame.rc \ - vbrquantize.h \ - logoe.ico - -libmp3lame_la_SOURCES = \ - VbrTag.c \ - bitstream.c \ - encoder.c \ - fft.c \ - gain_analysis.c \ - id3tag.c \ - lame.c \ - newmdct.c \ - presets.c \ - psymodel.c \ - quantize.c \ - quantize_pvt.c \ - reservoir.c \ - set_get.c \ - tables.c \ - takehiro.c \ - util.c \ - vbrquantize.c \ - version.c \ - mpglib_interface.c - -noinst_HEADERS = \ - VbrTag.h \ - bitstream.h \ - encoder.h \ - fft.h \ - gain_analysis.h \ - id3tag.h \ - l3side.h \ - lame-analysis.h \ - lame_global_flags.h \ - lameerror.h \ - machine.h \ - newmdct.h \ - psymodel.h \ - quantize.h \ - quantize_pvt.h \ - reservoir.h \ - set_get.h \ - tables.h \ - util.h \ - vbrquantize.h \ - version.h - -CLEANFILES = lclint.txt -LCLINTFLAGS = \ - +posixlib \ - +showsummary \ - +showalluses \ - +whichlib \ - +forcehints \ - -fixedformalarray \ - +matchanyintegral \ - -Dlint - -all: all-recursive - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/Makefile.am.global $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libmp3lame/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign libmp3lame/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; -$(top_srcdir)/Makefile.am.global $(am__empty): - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libmp3lame.la: $(libmp3lame_la_OBJECTS) $(libmp3lame_la_DEPENDENCIES) $(EXTRA_libmp3lame_la_DEPENDENCIES) - $(AM_V_CCLD)$(libmp3lame_la_LINK) -rpath $(libdir) $(libmp3lame_la_OBJECTS) $(libmp3lame_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/VbrTag.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bitstream.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/encoder.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fft.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gain_analysis.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/id3tag.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lame.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpglib_interface.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/newmdct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/presets.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/psymodel.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/quantize.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/quantize_pvt.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reservoir.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_get.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tables.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/takehiro.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vbrquantize.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Plo@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-recursive -all-am: Makefile $(LTLIBRARIES) $(HEADERS) -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(libdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ - mostlyclean-am - -distclean: distclean-recursive - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: install-libLTLIBRARIES - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-libLTLIBRARIES - -.MAKE: $(am__recursive_targets) install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libLTLIBRARIES \ - clean-libtool cscopelist-am ctags ctags-am distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am \ - install-libLTLIBRARIES install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am uninstall-libLTLIBRARIES - -.PRECIOUS: Makefile - - -# end global section - -lclint.txt: ${libmp3lame_la_SOURCES} ${noinst_HEADERS} - @lclint ${LCLINTFLAGS} ${INCLUDES} ${DEFS} ${libmp3lame_la_SOURCES} 2>&1 >lclint.txt || true - -lclint: lclint.txt - more lclint.txt - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/lame/libmp3lame/VbrTag.c b/lib-src/lame/libmp3lame/VbrTag.c deleted file mode 100644 index 832cba22e..000000000 --- a/lib-src/lame/libmp3lame/VbrTag.c +++ /dev/null @@ -1,1082 +0,0 @@ -/* - * Xing VBR tagging for LAME. - * - * Copyright (c) 1999 A.L. Faber - * Copyright (c) 2001 Jonathan Dee - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: VbrTag.c,v 1.106 2017/08/06 18:15:47 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "bitstream.h" -#include "VbrTag.h" -#include "lame_global_flags.h" -#include "tables.h" - -#ifdef __sun__ -/* woraround for SunOS 4.x, it has SEEK_* defined here */ -#include -#endif - - -#ifdef _DEBUG -/* #define DEBUG_VBRTAG */ -#endif - -/* - * 4 bytes for Header Tag - * 4 bytes for Header Flags - * 100 bytes for entry (NUMTOCENTRIES) - * 4 bytes for FRAME SIZE - * 4 bytes for STREAM_SIZE - * 4 bytes for VBR SCALE. a VBR quality indicator: 0=best 100=worst - * 20 bytes for LAME tag. for example, "LAME3.12 (beta 6)" - * ___________ - * 140 bytes -*/ -#define VBRHEADERSIZE (NUMTOCENTRIES+4+4+4+4+4) - -#define LAMEHEADERSIZE (VBRHEADERSIZE + 9 + 1 + 1 + 8 + 1 + 1 + 3 + 1 + 1 + 2 + 4 + 2 + 2) - -/* the size of the Xing header (MPEG1 and MPEG2) in kbps */ -#define XING_BITRATE1 128 -#define XING_BITRATE2 64 -#define XING_BITRATE25 32 - -extern const char* get_lame_tag_encoder_short_version(void); - -static const char VBRTag0[] = { "Xing" }; -static const char VBRTag1[] = { "Info" }; - - - - -/* Lookup table for fast CRC computation - * See 'CRC_update_lookup' - * Uses the polynomial x^16+x^15+x^2+1 */ - -static const unsigned int crc16_lookup[256] = { - 0x0000, 0xC0C1, 0xC181, 0x0140, 0xC301, 0x03C0, 0x0280, 0xC241, - 0xC601, 0x06C0, 0x0780, 0xC741, 0x0500, 0xC5C1, 0xC481, 0x0440, - 0xCC01, 0x0CC0, 0x0D80, 0xCD41, 0x0F00, 0xCFC1, 0xCE81, 0x0E40, - 0x0A00, 0xCAC1, 0xCB81, 0x0B40, 0xC901, 0x09C0, 0x0880, 0xC841, - 0xD801, 0x18C0, 0x1980, 0xD941, 0x1B00, 0xDBC1, 0xDA81, 0x1A40, - 0x1E00, 0xDEC1, 0xDF81, 0x1F40, 0xDD01, 0x1DC0, 0x1C80, 0xDC41, - 0x1400, 0xD4C1, 0xD581, 0x1540, 0xD701, 0x17C0, 0x1680, 0xD641, - 0xD201, 0x12C0, 0x1380, 0xD341, 0x1100, 0xD1C1, 0xD081, 0x1040, - 0xF001, 0x30C0, 0x3180, 0xF141, 0x3300, 0xF3C1, 0xF281, 0x3240, - 0x3600, 0xF6C1, 0xF781, 0x3740, 0xF501, 0x35C0, 0x3480, 0xF441, - 0x3C00, 0xFCC1, 0xFD81, 0x3D40, 0xFF01, 0x3FC0, 0x3E80, 0xFE41, - 0xFA01, 0x3AC0, 0x3B80, 0xFB41, 0x3900, 0xF9C1, 0xF881, 0x3840, - 0x2800, 0xE8C1, 0xE981, 0x2940, 0xEB01, 0x2BC0, 0x2A80, 0xEA41, - 0xEE01, 0x2EC0, 0x2F80, 0xEF41, 0x2D00, 0xEDC1, 0xEC81, 0x2C40, - 0xE401, 0x24C0, 0x2580, 0xE541, 0x2700, 0xE7C1, 0xE681, 0x2640, - 0x2200, 0xE2C1, 0xE381, 0x2340, 0xE101, 0x21C0, 0x2080, 0xE041, - 0xA001, 0x60C0, 0x6180, 0xA141, 0x6300, 0xA3C1, 0xA281, 0x6240, - 0x6600, 0xA6C1, 0xA781, 0x6740, 0xA501, 0x65C0, 0x6480, 0xA441, - 0x6C00, 0xACC1, 0xAD81, 0x6D40, 0xAF01, 0x6FC0, 0x6E80, 0xAE41, - 0xAA01, 0x6AC0, 0x6B80, 0xAB41, 0x6900, 0xA9C1, 0xA881, 0x6840, - 0x7800, 0xB8C1, 0xB981, 0x7940, 0xBB01, 0x7BC0, 0x7A80, 0xBA41, - 0xBE01, 0x7EC0, 0x7F80, 0xBF41, 0x7D00, 0xBDC1, 0xBC81, 0x7C40, - 0xB401, 0x74C0, 0x7580, 0xB541, 0x7700, 0xB7C1, 0xB681, 0x7640, - 0x7200, 0xB2C1, 0xB381, 0x7340, 0xB101, 0x71C0, 0x7080, 0xB041, - 0x5000, 0x90C1, 0x9181, 0x5140, 0x9301, 0x53C0, 0x5280, 0x9241, - 0x9601, 0x56C0, 0x5780, 0x9741, 0x5500, 0x95C1, 0x9481, 0x5440, - 0x9C01, 0x5CC0, 0x5D80, 0x9D41, 0x5F00, 0x9FC1, 0x9E81, 0x5E40, - 0x5A00, 0x9AC1, 0x9B81, 0x5B40, 0x9901, 0x59C0, 0x5880, 0x9841, - 0x8801, 0x48C0, 0x4980, 0x8941, 0x4B00, 0x8BC1, 0x8A81, 0x4A40, - 0x4E00, 0x8EC1, 0x8F81, 0x4F40, 0x8D01, 0x4DC0, 0x4C80, 0x8C41, - 0x4400, 0x84C1, 0x8581, 0x4540, 0x8701, 0x47C0, 0x4680, 0x8641, - 0x8201, 0x42C0, 0x4380, 0x8341, 0x4100, 0x81C1, 0x8081, 0x4040 -}; - - - - - -/*********************************************************************** - * Robert Hegemann 2001-01-17 - ***********************************************************************/ - -static void -addVbr(VBR_seek_info_t * v, int bitrate) -{ - int i; - - v->nVbrNumFrames++; - v->sum += bitrate; - v->seen++; - - if (v->seen < v->want) { - return; - } - - if (v->pos < v->size) { - v->bag[v->pos] = v->sum; - v->pos++; - v->seen = 0; - } - if (v->pos == v->size) { - for (i = 1; i < v->size; i += 2) { - v->bag[i / 2] = v->bag[i]; - } - v->want *= 2; - v->pos /= 2; - } -} - -static void -Xing_seek_table(VBR_seek_info_t const* v, unsigned char *t) -{ - int i, indx; - int seek_point; - - if (v->pos <= 0) - return; - - for (i = 1; i < NUMTOCENTRIES; ++i) { - float j = i / (float) NUMTOCENTRIES, act, sum; - indx = (int) (floor(j * v->pos)); - if (indx > v->pos - 1) - indx = v->pos - 1; - act = v->bag[indx]; - sum = v->sum; - seek_point = (int) (256. * act / sum); - if (seek_point > 255) - seek_point = 255; - t[i] = seek_point; - } -} - -#ifdef DEBUG_VBR_SEEKING_TABLE -static void -print_seeking(unsigned char *t) -{ - int i; - - printf("seeking table "); - for (i = 0; i < NUMTOCENTRIES; ++i) { - printf(" %d ", t[i]); - } - printf("\n"); -} -#endif - - -/**************************************************************************** - * AddVbrFrame: Add VBR entry, used to fill the VBR the TOC entries - * Paramters: - * nStreamPos: how many bytes did we write to the bitstream so far - * (in Bytes NOT Bits) - **************************************************************************** -*/ -void -AddVbrFrame(lame_internal_flags * gfc) -{ - int kbps = bitrate_table[gfc->cfg.version][gfc->ov_enc.bitrate_index]; - assert(gfc->VBR_seek_table.bag); - addVbr(&gfc->VBR_seek_table, kbps); -} - - -/*-------------------------------------------------------------*/ -static int -ExtractI4(const unsigned char *buf) -{ - int x; - /* big endian extract */ - x = buf[0]; - x <<= 8; - x |= buf[1]; - x <<= 8; - x |= buf[2]; - x <<= 8; - x |= buf[3]; - return x; -} - -static void -CreateI4(unsigned char *buf, uint32_t nValue) -{ - /* big endian create */ - buf[0] = (nValue >> 24) & 0xff; - buf[1] = (nValue >> 16) & 0xff; - buf[2] = (nValue >> 8) & 0xff; - buf[3] = (nValue) & 0xff; -} - - - -static void -CreateI2(unsigned char *buf, int nValue) -{ - /* big endian create */ - buf[0] = (nValue >> 8) & 0xff; - buf[1] = (nValue) & 0xff; -} - -/* check for magic strings*/ -static int -IsVbrTag(const unsigned char *buf) -{ - int isTag0, isTag1; - - isTag0 = ((buf[0] == VBRTag0[0]) && (buf[1] == VBRTag0[1]) && (buf[2] == VBRTag0[2]) - && (buf[3] == VBRTag0[3])); - isTag1 = ((buf[0] == VBRTag1[0]) && (buf[1] == VBRTag1[1]) && (buf[2] == VBRTag1[2]) - && (buf[3] == VBRTag1[3])); - - return (isTag0 || isTag1); -} - -#define SHIFT_IN_BITS_VALUE(x,n,v) ( x = (x << (n)) | ( (v) & ~(-1u << (n)) ) ) - -static void -setLameTagFrameHeader(lame_internal_flags const *gfc, unsigned char *buffer) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - char abyte, bbyte; - - SHIFT_IN_BITS_VALUE(buffer[0], 8u, 0xffu); - - SHIFT_IN_BITS_VALUE(buffer[1], 3u, 7); - SHIFT_IN_BITS_VALUE(buffer[1], 1u, (cfg->samplerate_out < 16000) ? 0 : 1); - SHIFT_IN_BITS_VALUE(buffer[1], 1u, cfg->version); - SHIFT_IN_BITS_VALUE(buffer[1], 2u, 4 - 3); - SHIFT_IN_BITS_VALUE(buffer[1], 1u, (!cfg->error_protection) ? 1 : 0); - - SHIFT_IN_BITS_VALUE(buffer[2], 4u, eov->bitrate_index); - SHIFT_IN_BITS_VALUE(buffer[2], 2u, cfg->samplerate_index); - SHIFT_IN_BITS_VALUE(buffer[2], 1u, 0); - SHIFT_IN_BITS_VALUE(buffer[2], 1u, cfg->extension); - - SHIFT_IN_BITS_VALUE(buffer[3], 2u, cfg->mode); - SHIFT_IN_BITS_VALUE(buffer[3], 2u, eov->mode_ext); - SHIFT_IN_BITS_VALUE(buffer[3], 1u, cfg->copyright); - SHIFT_IN_BITS_VALUE(buffer[3], 1u, cfg->original); - SHIFT_IN_BITS_VALUE(buffer[3], 2u, cfg->emphasis); - - /* the default VBR header. 48 kbps layer III, no padding, no crc */ - /* but sampling freq, mode andy copyright/copy protection taken */ - /* from first valid frame */ - buffer[0] = (uint8_t) 0xff; - abyte = (buffer[1] & (unsigned char) 0xf1); - { - int bitrate; - if (1 == cfg->version) { - bitrate = XING_BITRATE1; - } - else { - if (cfg->samplerate_out < 16000) - bitrate = XING_BITRATE25; - else - bitrate = XING_BITRATE2; - } - - if (cfg->vbr == vbr_off) - bitrate = cfg->avg_bitrate; - - if (cfg->free_format) - bbyte = 0x00; - else - bbyte = 16 * BitrateIndex(bitrate, cfg->version, cfg->samplerate_out); - } - - /* Use as much of the info from the real frames in the - * Xing header: samplerate, channels, crc, etc... - */ - if (cfg->version == 1) { - /* MPEG1 */ - buffer[1] = abyte | (char) 0x0a; /* was 0x0b; */ - abyte = buffer[2] & (char) 0x0d; /* AF keep also private bit */ - buffer[2] = (char) bbyte | abyte; /* 64kbs MPEG1 frame */ - } - else { - /* MPEG2 */ - buffer[1] = abyte | (char) 0x02; /* was 0x03; */ - abyte = buffer[2] & (char) 0x0d; /* AF keep also private bit */ - buffer[2] = (char) bbyte | abyte; /* 64kbs MPEG2 frame */ - } -} - -#if 0 -static int CheckVbrTag(unsigned char *buf); - -/*-------------------------------------------------------------*/ -/* Same as GetVbrTag below, but only checks for the Xing tag. - requires buf to contain only 40 bytes */ -/*-------------------------------------------------------------*/ -int -CheckVbrTag(unsigned char *buf) -{ - int h_id, h_mode; - - /* get selected MPEG header data */ - h_id = (buf[1] >> 3) & 1; - h_mode = (buf[3] >> 6) & 3; - - /* determine offset of header */ - if (h_id) { - /* mpeg1 */ - if (h_mode != 3) - buf += (32 + 4); - else - buf += (17 + 4); - } - else { - /* mpeg2 */ - if (h_mode != 3) - buf += (17 + 4); - else - buf += (9 + 4); - } - - return IsVbrTag(buf); -} -#endif - -int -GetVbrTag(VBRTAGDATA * pTagData, const unsigned char *buf) -{ - int i, head_flags; - int h_bitrate, h_id, h_mode, h_sr_index, h_layer; - int enc_delay, enc_padding; - - /* get Vbr header data */ - pTagData->flags = 0; - - /* get selected MPEG header data */ - h_layer = (buf[1] >> 1) & 3; - if ( h_layer != 0x01 ) { - /* the following code assumes Layer-3, so give up here */ - return 0; - } - h_id = (buf[1] >> 3) & 1; - h_sr_index = (buf[2] >> 2) & 3; - h_mode = (buf[3] >> 6) & 3; - h_bitrate = ((buf[2] >> 4) & 0xf); - h_bitrate = bitrate_table[h_id][h_bitrate]; - - /* check for FFE syncword */ - if ((buf[1] >> 4) == 0xE) - pTagData->samprate = samplerate_table[2][h_sr_index]; - else - pTagData->samprate = samplerate_table[h_id][h_sr_index]; - /* if( h_id == 0 ) */ - /* pTagData->samprate >>= 1; */ - - - - /* determine offset of header */ - if (h_id) { - /* mpeg1 */ - if (h_mode != 3) - buf += (32 + 4); - else - buf += (17 + 4); - } - else { - /* mpeg2 */ - if (h_mode != 3) - buf += (17 + 4); - else - buf += (9 + 4); - } - - if (!IsVbrTag(buf)) - return 0; - - buf += 4; - - pTagData->h_id = h_id; - - head_flags = pTagData->flags = ExtractI4(buf); - buf += 4; /* get flags */ - - if (head_flags & FRAMES_FLAG) { - pTagData->frames = ExtractI4(buf); - buf += 4; - } - - if (head_flags & BYTES_FLAG) { - pTagData->bytes = ExtractI4(buf); - buf += 4; - } - - if (head_flags & TOC_FLAG) { - if ((void *)pTagData->toc != NULL) { - for (i = 0; i < NUMTOCENTRIES; i++) - pTagData->toc[i] = buf[i]; - } - buf += NUMTOCENTRIES; - } - - pTagData->vbr_scale = -1; - - if (head_flags & VBR_SCALE_FLAG) { - pTagData->vbr_scale = ExtractI4(buf); - buf += 4; - } - - pTagData->headersize = ((h_id + 1) * 72000 * h_bitrate) / pTagData->samprate; - - buf += 21; - enc_delay = buf[0] << 4; - enc_delay += buf[1] >> 4; - enc_padding = (buf[1] & 0x0F) << 8; - enc_padding += buf[2]; - /* check for reasonable values (this may be an old Xing header, */ - /* not a INFO tag) */ - if (enc_delay < 0 || enc_delay > 3000) - enc_delay = -1; - if (enc_padding < 0 || enc_padding > 3000) - enc_padding = -1; - - pTagData->enc_delay = enc_delay; - pTagData->enc_padding = enc_padding; - -#ifdef DEBUG_VBRTAG - fprintf(stderr, "\n\n********************* VBR TAG INFO *****************\n"); - fprintf(stderr, "tag :%s\n", VBRTag); - fprintf(stderr, "head_flags :%d\n", head_flags); - fprintf(stderr, "bytes :%d\n", pTagData->bytes); - fprintf(stderr, "frames :%d\n", pTagData->frames); - fprintf(stderr, "VBR Scale :%d\n", pTagData->vbr_scale); - fprintf(stderr, "enc_delay = %i \n", enc_delay); - fprintf(stderr, "enc_padding= %i \n", enc_padding); - fprintf(stderr, "toc:\n"); - if (pTagData->toc != NULL) { - for (i = 0; i < NUMTOCENTRIES; i++) { - if ((i % 10) == 0) - fprintf(stderr, "\n"); - fprintf(stderr, " %3d", (int) (pTagData->toc[i])); - } - } - fprintf(stderr, "\n***************** END OF VBR TAG INFO ***************\n"); -#endif - return 1; /* success */ -} - - -/**************************************************************************** - * InitVbrTag: Initializes the header, and write empty frame to stream - * Paramters: - * fpStream: pointer to output file stream - * nMode : Channel Mode: 0=STEREO 1=JS 2=DS 3=MONO - **************************************************************************** -*/ -int -InitVbrTag(lame_global_flags * gfp) -{ - lame_internal_flags *gfc = gfp->internal_flags; - SessionConfig_t const *const cfg = &gfc->cfg; - int kbps_header; - -#define MAXFRAMESIZE 2880 /* or 0xB40, the max freeformat 640 32kHz framesize */ - - /* - * Xing VBR pretends to be a 48kbs layer III frame. (at 44.1kHz). - * (at 48kHz they use 56kbs since 48kbs frame not big enough for - * table of contents) - * let's always embed Xing header inside a 64kbs layer III frame. - * this gives us enough room for a LAME version string too. - * size determined by sampling frequency (MPEG1) - * 32kHz: 216 bytes@48kbs 288bytes@ 64kbs - * 44.1kHz: 156 bytes 208bytes@64kbs (+1 if padding = 1) - * 48kHz: 144 bytes 192 - * - * MPEG 2 values are the same since the framesize and samplerate - * are each reduced by a factor of 2. - */ - - - if (1 == cfg->version) { - kbps_header = XING_BITRATE1; - } - else { - if (cfg->samplerate_out < 16000) - kbps_header = XING_BITRATE25; - else - kbps_header = XING_BITRATE2; - } - - if (cfg->vbr == vbr_off) - kbps_header = cfg->avg_bitrate; - - /** make sure LAME Header fits into Frame - */ - { - int total_frame_size = ((cfg->version + 1) * 72000 * kbps_header) / cfg->samplerate_out; - int header_size = (cfg->sideinfo_len + LAMEHEADERSIZE); - gfc->VBR_seek_table.TotalFrameSize = total_frame_size; - if (total_frame_size < header_size || total_frame_size > MAXFRAMESIZE) { - /* disable tag, it wont fit */ - gfc->cfg.write_lame_tag = 0; - return 0; - } - } - - gfc->VBR_seek_table.nVbrNumFrames = 0; - gfc->VBR_seek_table.nBytesWritten = 0; - gfc->VBR_seek_table.sum = 0; - - gfc->VBR_seek_table.seen = 0; - gfc->VBR_seek_table.want = 1; - gfc->VBR_seek_table.pos = 0; - - if (gfc->VBR_seek_table.bag == NULL) { - gfc->VBR_seek_table.bag = lame_calloc(int, 400); - if (gfc->VBR_seek_table.bag != NULL) { - gfc->VBR_seek_table.size = 400; - } - else { - gfc->VBR_seek_table.size = 0; - ERRORF(gfc, "Error: can't allocate VbrFrames buffer\n"); - gfc->cfg.write_lame_tag = 0; - return -1; - } - } - - /* write dummy VBR tag of all 0's into bitstream */ - { - uint8_t buffer[MAXFRAMESIZE]; - size_t i, n; - - memset(buffer, 0, sizeof(buffer)); - setLameTagFrameHeader(gfc, buffer); - n = gfc->VBR_seek_table.TotalFrameSize; - for (i = 0; i < n; ++i) { - add_dummy_byte(gfc, buffer[i], 1); - } - } - /* Success */ - return 0; -} - - - -/* fast CRC-16 computation - uses table crc16_lookup 8*/ -static uint16_t -CRC_update_lookup(uint16_t value, uint16_t crc) -{ - uint16_t tmp; - tmp = crc ^ value; - crc = (crc >> 8) ^ crc16_lookup[tmp & 0xff]; - return crc; -} - -void -UpdateMusicCRC(uint16_t * crc, unsigned char const *buffer, int size) -{ - int i; - for (i = 0; i < size; ++i) - *crc = CRC_update_lookup(buffer[i], *crc); -} - - - - - -/**************************************************************************** - * Jonathan Dee 2001/08/31 - * - * PutLameVBR: Write LAME info: mini version + info on various switches used - * Paramters: - * pbtStreamBuffer : pointer to output buffer - * id3v2size : size of id3v2 tag in bytes - * crc : computation of crc-16 of Lame Tag so far (starting at frame sync) - * - **************************************************************************** -*/ -static int -PutLameVBR(lame_global_flags const *gfp, size_t nMusicLength, uint8_t * pbtStreamBuffer, uint16_t crc) -{ - lame_internal_flags const *gfc = gfp->internal_flags; - SessionConfig_t const *const cfg = &gfc->cfg; - - int nBytesWritten = 0; - int i; - - int enc_delay = gfc->ov_enc.encoder_delay; /* encoder delay */ - int enc_padding = gfc->ov_enc.encoder_padding; /* encoder padding */ - - /*recall: cfg->vbr_q is for example set by the switch -V */ - /* gfp->quality by -q, -h, -f, etc */ - - int nQuality = (100 - 10 * gfp->VBR_q - gfp->quality); - - - /* - NOTE: - Even though the specification for the LAME VBR tag - did explicitly mention other encoders than LAME, - many SW/HW decoder seem to be able to make use of - this tag only, if the encoder version starts with LAME. - To be compatible with such decoders, ANY encoder will - be forced to write a fake LAME version string! - As a result, the encoder version info becomes worthless. - */ - const char *szVersion = get_lame_tag_encoder_short_version(); - uint8_t nVBR; - uint8_t nRevision = 0x00; - uint8_t nRevMethod; - uint8_t vbr_type_translator[] = { 1, 5, 3, 2, 4, 0, 3 }; /*numbering different in vbr_mode vs. Lame tag */ - - uint8_t nLowpass = - (((cfg->lowpassfreq / 100.0) + .5) > 255 ? 255 : (cfg->lowpassfreq / 100.0) + .5); - - uint32_t nPeakSignalAmplitude = 0; - - uint16_t nRadioReplayGain = 0; - uint16_t nAudiophileReplayGain = 0; - - uint8_t nNoiseShaping = cfg->noise_shaping; - uint8_t nStereoMode = 0; - int bNonOptimal = 0; - uint8_t nSourceFreq = 0; - uint8_t nMisc = 0; - uint16_t nMusicCRC = 0; - - /*psy model type: Gpsycho or NsPsytune */ - unsigned char bExpNPsyTune = 1; /* only NsPsytune */ - unsigned char bSafeJoint = (cfg->use_safe_joint_stereo) != 0; - - unsigned char bNoGapMore = 0; - unsigned char bNoGapPrevious = 0; - - int nNoGapCount = gfp->nogap_total; - int nNoGapCurr = gfp->nogap_current; - - - uint8_t nAthType = cfg->ATHtype; /*4 bits. */ - - uint8_t nFlags = 0; - - /* if ABR, {store bitrate <=255} else { store "-b"} */ - int nABRBitrate; - switch (cfg->vbr) { - case vbr_abr:{ - nABRBitrate = cfg->vbr_avg_bitrate_kbps; - break; - } - case vbr_off:{ - nABRBitrate = cfg->avg_bitrate; - break; - } - default:{ /*vbr modes */ - nABRBitrate = bitrate_table[cfg->version][cfg->vbr_min_bitrate_index];; - } - } - - - /*revision and vbr method */ - if (cfg->vbr < sizeof(vbr_type_translator)) - nVBR = vbr_type_translator[cfg->vbr]; - else - nVBR = 0x00; /*unknown. */ - - nRevMethod = 0x10 * nRevision + nVBR; - - - /* ReplayGain */ - if (cfg->findReplayGain) { - int RadioGain = gfc->ov_rpg.RadioGain; - if (RadioGain > 0x1FE) - RadioGain = 0x1FE; - if (RadioGain < -0x1FE) - RadioGain = -0x1FE; - - nRadioReplayGain = 0x2000; /* set name code */ - nRadioReplayGain |= 0xC00; /* set originator code to `determined automatically' */ - - if (RadioGain >= 0) - nRadioReplayGain |= RadioGain; /* set gain adjustment */ - else { - nRadioReplayGain |= 0x200; /* set the sign bit */ - nRadioReplayGain |= -RadioGain; /* set gain adjustment */ - } - } - - /* peak sample */ - if (cfg->findPeakSample) - nPeakSignalAmplitude = - abs((int) ((((FLOAT) gfc->ov_rpg.PeakSample) / 32767.0) * pow(2, 23) + .5)); - - /*nogap */ - if (nNoGapCount != -1) { - if (nNoGapCurr > 0) - bNoGapPrevious = 1; - - if (nNoGapCurr < nNoGapCount - 1) - bNoGapMore = 1; - } - - /*flags */ - - nFlags = nAthType + (bExpNPsyTune << 4) - + (bSafeJoint << 5) - + (bNoGapMore << 6) - + (bNoGapPrevious << 7); - - - if (nQuality < 0) - nQuality = 0; - - /*stereo mode field... a bit ugly. */ - - switch (cfg->mode) { - case MONO: - nStereoMode = 0; - break; - case STEREO: - nStereoMode = 1; - break; - case DUAL_CHANNEL: - nStereoMode = 2; - break; - case JOINT_STEREO: - if (cfg->force_ms) - nStereoMode = 4; - else - nStereoMode = 3; - break; - case NOT_SET: - /* FALLTHROUGH */ - default: - nStereoMode = 7; - break; - } - - /*Intensity stereo : nStereoMode = 6. IS is not implemented */ - - if (cfg->samplerate_in <= 32000) - nSourceFreq = 0x00; - else if (cfg->samplerate_in == 48000) - nSourceFreq = 0x02; - else if (cfg->samplerate_in > 48000) - nSourceFreq = 0x03; - else - nSourceFreq = 0x01; /*default is 44100Hz. */ - - - /*Check if the user overrided the default LAME behaviour with some nasty options */ - - if (cfg->short_blocks == short_block_forced || cfg->short_blocks == short_block_dispensed || ((cfg->lowpassfreq == -1) && (cfg->highpassfreq == -1)) || /* "-k" */ - (cfg->disable_reservoir && cfg->avg_bitrate < 320) || - cfg->noATH || cfg->ATHonly || (nAthType == 0) || cfg->samplerate_in <= 32000) - bNonOptimal = 1; - - nMisc = nNoiseShaping + (nStereoMode << 2) - + (bNonOptimal << 5) - + (nSourceFreq << 6); - - - nMusicCRC = gfc->nMusicCRC; - - - /*Write all this information into the stream */ - CreateI4(&pbtStreamBuffer[nBytesWritten], nQuality); - nBytesWritten += 4; - - strncpy((char *) &pbtStreamBuffer[nBytesWritten], szVersion, 9); - nBytesWritten += 9; - - pbtStreamBuffer[nBytesWritten] = nRevMethod; - nBytesWritten++; - - pbtStreamBuffer[nBytesWritten] = nLowpass; - nBytesWritten++; - - CreateI4(&pbtStreamBuffer[nBytesWritten], nPeakSignalAmplitude); - nBytesWritten += 4; - - CreateI2(&pbtStreamBuffer[nBytesWritten], nRadioReplayGain); - nBytesWritten += 2; - - CreateI2(&pbtStreamBuffer[nBytesWritten], nAudiophileReplayGain); - nBytesWritten += 2; - - pbtStreamBuffer[nBytesWritten] = nFlags; - nBytesWritten++; - - if (nABRBitrate >= 255) - pbtStreamBuffer[nBytesWritten] = 0xFF; - else - pbtStreamBuffer[nBytesWritten] = nABRBitrate; - nBytesWritten++; - - pbtStreamBuffer[nBytesWritten] = enc_delay >> 4; /* works for win32, does it for unix? */ - pbtStreamBuffer[nBytesWritten + 1] = (enc_delay << 4) + (enc_padding >> 8); - pbtStreamBuffer[nBytesWritten + 2] = enc_padding; - - nBytesWritten += 3; - - pbtStreamBuffer[nBytesWritten] = nMisc; - nBytesWritten++; - - - pbtStreamBuffer[nBytesWritten++] = 0; /*unused in rev0 */ - - CreateI2(&pbtStreamBuffer[nBytesWritten], cfg->preset); - nBytesWritten += 2; - - CreateI4(&pbtStreamBuffer[nBytesWritten], (int) nMusicLength); - nBytesWritten += 4; - - CreateI2(&pbtStreamBuffer[nBytesWritten], nMusicCRC); - nBytesWritten += 2; - - /*Calculate tag CRC.... must be done here, since it includes - *previous information*/ - - for (i = 0; i < nBytesWritten; i++) - crc = CRC_update_lookup(pbtStreamBuffer[i], crc); - - CreateI2(&pbtStreamBuffer[nBytesWritten], crc); - nBytesWritten += 2; - - return nBytesWritten; -} - -static long -skipId3v2(FILE * fpStream) -{ - size_t nbytes; - long id3v2TagSize; - unsigned char id3v2Header[10]; - - /* seek to the beginning of the stream */ - if (fseek(fpStream, 0, SEEK_SET) != 0) { - return -2; /* not seekable, abort */ - } - /* read 10 bytes in case there's an ID3 version 2 header here */ - nbytes = fread(id3v2Header, 1, sizeof(id3v2Header), fpStream); - if (nbytes != sizeof(id3v2Header)) { - return -3; /* not readable, maybe opened Write-Only */ - } - /* does the stream begin with the ID3 version 2 file identifier? */ - if (!strncmp((char *) id3v2Header, "ID3", 3)) { - /* the tag size (minus the 10-byte header) is encoded into four - * bytes where the most significant bit is clear in each byte */ - id3v2TagSize = (((id3v2Header[6] & 0x7f) << 21) - | ((id3v2Header[7] & 0x7f) << 14) - | ((id3v2Header[8] & 0x7f) << 7) - | (id3v2Header[9] & 0x7f)) - + sizeof id3v2Header; - } - else { - /* no ID3 version 2 tag in this stream */ - id3v2TagSize = 0; - } - return id3v2TagSize; -} - - - -size_t -lame_get_lametag_frame(lame_global_flags const *gfp, unsigned char *buffer, size_t size) -{ - lame_internal_flags *gfc; - SessionConfig_t const *cfg; - unsigned long stream_size; - unsigned int nStreamIndex; - uint8_t btToc[NUMTOCENTRIES]; - - if (gfp == 0) { - return 0; - } - gfc = gfp->internal_flags; - if (gfc == 0) { - return 0; - } - if (!is_lame_internal_flags_valid(gfc)) { - return 0; - } - cfg = &gfc->cfg; - if (cfg->write_lame_tag == 0) { - return 0; - } - if (gfc->VBR_seek_table.pos <= 0) { - return 0; - } - if (size < gfc->VBR_seek_table.TotalFrameSize) { - return gfc->VBR_seek_table.TotalFrameSize; - } - if (buffer == 0) { - return 0; - } - - memset(buffer, 0, gfc->VBR_seek_table.TotalFrameSize); - - /* 4 bytes frame header */ - - setLameTagFrameHeader(gfc, buffer); - - /* Clear all TOC entries */ - memset(btToc, 0, sizeof(btToc)); - - if (cfg->free_format) { - int i; - for (i = 1; i < NUMTOCENTRIES; ++i) - btToc[i] = 255 * i / 100; - } - else { - Xing_seek_table(&gfc->VBR_seek_table, btToc); - } -#ifdef DEBUG_VBR_SEEKING_TABLE - print_seeking(btToc); -#endif - - /* Start writing the tag after the zero frame */ - nStreamIndex = cfg->sideinfo_len; - /* note! Xing header specifies that Xing data goes in the - * ancillary data with NO ERROR PROTECTION. If error protecton - * in enabled, the Xing data still starts at the same offset, - * and now it is in sideinfo data block, and thus will not - * decode correctly by non-Xing tag aware players */ - if (cfg->error_protection) - nStreamIndex -= 2; - - /* Put Vbr tag */ - if (cfg->vbr == vbr_off) { - buffer[nStreamIndex++] = VBRTag1[0]; - buffer[nStreamIndex++] = VBRTag1[1]; - buffer[nStreamIndex++] = VBRTag1[2]; - buffer[nStreamIndex++] = VBRTag1[3]; - - } - else { - buffer[nStreamIndex++] = VBRTag0[0]; - buffer[nStreamIndex++] = VBRTag0[1]; - buffer[nStreamIndex++] = VBRTag0[2]; - buffer[nStreamIndex++] = VBRTag0[3]; - } - - /* Put header flags */ - CreateI4(&buffer[nStreamIndex], FRAMES_FLAG + BYTES_FLAG + TOC_FLAG + VBR_SCALE_FLAG); - nStreamIndex += 4; - - /* Put Total Number of frames */ - CreateI4(&buffer[nStreamIndex], gfc->VBR_seek_table.nVbrNumFrames); - nStreamIndex += 4; - - /* Put total audio stream size, including Xing/LAME Header */ - stream_size = gfc->VBR_seek_table.nBytesWritten + gfc->VBR_seek_table.TotalFrameSize; - CreateI4(&buffer[nStreamIndex], stream_size); - nStreamIndex += 4; - - /* Put TOC */ - memcpy(&buffer[nStreamIndex], btToc, sizeof(btToc)); - nStreamIndex += sizeof(btToc); - - - if (cfg->error_protection) { - /* (jo) error_protection: add crc16 information to header */ - CRC_writeheader(gfc, (char *) buffer); - } - { - /*work out CRC so far: initially crc = 0 */ - uint16_t crc = 0x00; - unsigned int i; - for (i = 0; i < nStreamIndex; i++) - crc = CRC_update_lookup(buffer[i], crc); - /*Put LAME VBR info */ - nStreamIndex += PutLameVBR(gfp, stream_size, buffer + nStreamIndex, crc); - } - -#ifdef DEBUG_VBRTAG - { - VBRTAGDATA TestHeader; - GetVbrTag(&TestHeader, buffer); - } -#endif - - return gfc->VBR_seek_table.TotalFrameSize; -} - -/*********************************************************************** - * - * PutVbrTag: Write final VBR tag to the file - * Paramters: - * lpszFileName: filename of MP3 bit stream - * nVbrScale : encoder quality indicator (0..100) - **************************************************************************** - */ - -int -PutVbrTag(lame_global_flags const *gfp, FILE * fpStream) -{ - lame_internal_flags *gfc = gfp->internal_flags; - - long lFileSize; - long id3v2TagSize; - size_t nbytes; - uint8_t buffer[MAXFRAMESIZE]; - - if (gfc->VBR_seek_table.pos <= 0) - return -1; - - /* Seek to end of file */ - fseek(fpStream, 0, SEEK_END); - - /* Get file size */ - lFileSize = ftell(fpStream); - - /* Abort if file has zero length. Yes, it can happen :) */ - if (lFileSize == 0) - return -1; - - /* - * The VBR tag may NOT be located at the beginning of the stream. - * If an ID3 version 2 tag was added, then it must be skipped to write - * the VBR tag data. - */ - - id3v2TagSize = skipId3v2(fpStream); - - if (id3v2TagSize < 0) { - return id3v2TagSize; - } - - /*Seek to the beginning of the stream */ - fseek(fpStream, id3v2TagSize, SEEK_SET); - - nbytes = lame_get_lametag_frame(gfp, buffer, sizeof(buffer)); - if (nbytes > sizeof(buffer)) { - return -1; - } - - if (nbytes < 1) { - return 0; - } - - /* Put it all to disk again */ - if (fwrite(buffer, nbytes, 1, fpStream) != 1) { - return -1; - } - - return 0; /* success */ -} diff --git a/lib-src/lame/libmp3lame/VbrTag.h b/lib-src/lame/libmp3lame/VbrTag.h deleted file mode 100644 index 406af3667..000000000 --- a/lib-src/lame/libmp3lame/VbrTag.h +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Xing VBR tagging for LAME. - * - * Copyright (c) 1999 A.L. Faber - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_VRBTAG_H -#define LAME_VRBTAG_H - - -/* ----------------------------------------------------------- - * A Vbr header may be present in the ancillary - * data field of the first frame of an mp3 bitstream - * The Vbr header (optionally) contains - * frames total number of audio frames in the bitstream - * bytes total number of bytes in the bitstream - * toc table of contents - - * toc (table of contents) gives seek points - * for random access - * the ith entry determines the seek point for - * i-percent duration - * seek point in bytes = (toc[i]/256.0) * total_bitstream_bytes - * e.g. half duration seek point = (toc[50]/256.0) * total_bitstream_bytes - */ - - -#define FRAMES_FLAG 0x0001 -#define BYTES_FLAG 0x0002 -#define TOC_FLAG 0x0004 -#define VBR_SCALE_FLAG 0x0008 - -#define NUMTOCENTRIES 100 - -#ifndef lame_internal_flags_defined -#define lame_internal_flags_defined -struct lame_internal_flags; -typedef struct lame_internal_flags lame_internal_flags; -#endif - - -/*structure to receive extracted header */ -/* toc may be NULL*/ -typedef struct { - int h_id; /* from MPEG header, 0=MPEG2, 1=MPEG1 */ - int samprate; /* determined from MPEG header */ - int flags; /* from Vbr header data */ - int frames; /* total bit stream frames from Vbr header data */ - int bytes; /* total bit stream bytes from Vbr header data */ - int vbr_scale; /* encoded vbr scale from Vbr header data */ - unsigned char toc[NUMTOCENTRIES]; /* may be NULL if toc not desired */ - int headersize; /* size of VBR header, in bytes */ - int enc_delay; /* encoder delay */ - int enc_padding; /* encoder paddign added at end of stream */ -} VBRTAGDATA; - -int GetVbrTag(VBRTAGDATA * pTagData, const unsigned char *buf); - -int InitVbrTag(lame_global_flags * gfp); -int PutVbrTag(lame_global_flags const *gfp, FILE * fid); -void AddVbrFrame(lame_internal_flags * gfc); -void UpdateMusicCRC(uint16_t * crc, const unsigned char *buffer, int size); - -#endif diff --git a/lib-src/lame/libmp3lame/bitstream.c b/lib-src/lame/libmp3lame/bitstream.c deleted file mode 100644 index aa3591509..000000000 --- a/lib-src/lame/libmp3lame/bitstream.c +++ /dev/null @@ -1,1111 +0,0 @@ -/* - * MP3 bitstream Output interface for LAME - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 1999-2002 Takehiro Tominaga - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - * - * $Id: bitstream.c,v 1.99 2017/08/31 14:14:46 robert Exp $ - */ - - -#ifdef HAVE_CONFIG_H -#include -#endif - -#include -#include - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "tables.h" -#include "quantize_pvt.h" -#include "lame_global_flags.h" -#include "gain_analysis.h" -#include "VbrTag.h" -#include "bitstream.h" -#include "tables.h" - - - -/* unsigned int is at least this large: */ -/* we work with ints, so when doing bit manipulation, we limit - * ourselves to MAX_LENGTH-2 just to be on the safe side */ -#define MAX_LENGTH 32 - - - -#ifdef DEBUG -static int hogege; -#endif - - - -static int -calcFrameLength(SessionConfig_t const *const cfg, int kbps, int pad) -{ - return 8 * ((cfg->version + 1) * 72000 * kbps / cfg->samplerate_out + pad); -} - - -/*********************************************************************** - * compute bitsperframe and mean_bits for a layer III frame - **********************************************************************/ -int -getframebits(const lame_internal_flags * gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - int bit_rate; - - /* get bitrate in kbps [?] */ - if (eov->bitrate_index) - bit_rate = bitrate_table[cfg->version][eov->bitrate_index]; - else - bit_rate = cfg->avg_bitrate; - /*assert(bit_rate <= 550); */ - assert(8 <= bit_rate && bit_rate <= 640); - - /* main encoding routine toggles padding on and off */ - /* one Layer3 Slot consists of 8 bits */ - return calcFrameLength(cfg, bit_rate, eov->padding); -} - -int -get_max_frame_buffer_size_by_constraint(SessionConfig_t const * cfg, int constraint) -{ - int maxmp3buf = 0; - if (cfg->avg_bitrate > 320) { - /* in freeformat the buffer is constant */ - if (constraint == MDB_STRICT_ISO) { - maxmp3buf = calcFrameLength(cfg, cfg->avg_bitrate, 0); - } - else { - /* maximum allowed bits per granule are 7680 */ - maxmp3buf = 7680 * (cfg->version + 1); - } - } - else { - int max_kbps; - if (cfg->samplerate_out < 16000) { - max_kbps = bitrate_table[cfg->version][8]; /* default: allow 64 kbps (MPEG-2.5) */ - } - else { - max_kbps = bitrate_table[cfg->version][14]; - } - switch (constraint) - { - default: - case MDB_DEFAULT: - /* Bouvigne suggests this more lax interpretation of the ISO doc instead of using 8*960. */ - /* All mp3 decoders should have enough buffer to handle this value: size of a 320kbps 32kHz frame */ - maxmp3buf = 8 * 1440; - break; - case MDB_STRICT_ISO: - maxmp3buf = calcFrameLength(cfg, max_kbps, 0); - break; - case MDB_MAXIMUM: - maxmp3buf = 7680 * (cfg->version + 1); - break; - } - } - return maxmp3buf; -} - - -static void -putheader_bits(lame_internal_flags * gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - Bit_stream_struc *bs = &gfc->bs; -#ifdef DEBUG - hogege += cfg->sideinfo_len * 8; -#endif - memcpy(&bs->buf[bs->buf_byte_idx], esv->header[esv->w_ptr].buf, cfg->sideinfo_len); - bs->buf_byte_idx += cfg->sideinfo_len; - bs->totbit += cfg->sideinfo_len * 8; - esv->w_ptr = (esv->w_ptr + 1) & (MAX_HEADER_BUF - 1); -} - - - - -/*write j bits into the bit stream */ -inline static void -putbits2(lame_internal_flags * gfc, int val, int j) -{ - EncStateVar_t const *const esv = &gfc->sv_enc; - Bit_stream_struc *bs; - bs = &gfc->bs; - - assert(j < MAX_LENGTH - 2); - - while (j > 0) { - int k; - if (bs->buf_bit_idx == 0) { - bs->buf_bit_idx = 8; - bs->buf_byte_idx++; - assert(bs->buf_byte_idx < BUFFER_SIZE); - assert(esv->header[esv->w_ptr].write_timing >= bs->totbit); - if (esv->header[esv->w_ptr].write_timing == bs->totbit) { - putheader_bits(gfc); - } - bs->buf[bs->buf_byte_idx] = 0; - } - - k = Min(j, bs->buf_bit_idx); - j -= k; - - bs->buf_bit_idx -= k; - - assert(j < MAX_LENGTH); /* 32 too large on 32 bit machines */ - assert(bs->buf_bit_idx < MAX_LENGTH); - - bs->buf[bs->buf_byte_idx] |= ((val >> j) << bs->buf_bit_idx); - bs->totbit += k; - } -} - -/*write j bits into the bit stream, ignoring frame headers */ -inline static void -putbits_noheaders(lame_internal_flags * gfc, int val, int j) -{ - Bit_stream_struc *bs; - bs = &gfc->bs; - - assert(j < MAX_LENGTH - 2); - - while (j > 0) { - int k; - if (bs->buf_bit_idx == 0) { - bs->buf_bit_idx = 8; - bs->buf_byte_idx++; - assert(bs->buf_byte_idx < BUFFER_SIZE); - bs->buf[bs->buf_byte_idx] = 0; - } - - k = Min(j, bs->buf_bit_idx); - j -= k; - - bs->buf_bit_idx -= k; - - assert(j < MAX_LENGTH); /* 32 too large on 32 bit machines */ - assert(bs->buf_bit_idx < MAX_LENGTH); - - bs->buf[bs->buf_byte_idx] |= ((val >> j) << bs->buf_bit_idx); - bs->totbit += k; - } -} - - -/* - Some combinations of bitrate, Fs, and stereo make it impossible to stuff - out a frame using just main_data, due to the limited number of bits to - indicate main_data_length. In these situations, we put stuffing bits into - the ancillary data... -*/ - -inline static void -drain_into_ancillary(lame_internal_flags * gfc, int remainingBits) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int i; - assert(remainingBits >= 0); - - if (remainingBits >= 8) { - putbits2(gfc, 0x4c, 8); - remainingBits -= 8; - } - if (remainingBits >= 8) { - putbits2(gfc, 0x41, 8); - remainingBits -= 8; - } - if (remainingBits >= 8) { - putbits2(gfc, 0x4d, 8); - remainingBits -= 8; - } - if (remainingBits >= 8) { - putbits2(gfc, 0x45, 8); - remainingBits -= 8; - } - - if (remainingBits >= 32) { - const char *const version = get_lame_short_version(); - if (remainingBits >= 32) - for (i = 0; i < (int) strlen(version) && remainingBits >= 8; ++i) { - remainingBits -= 8; - putbits2(gfc, version[i], 8); - } - } - - for (; remainingBits >= 1; remainingBits -= 1) { - putbits2(gfc, esv->ancillary_flag, 1); - esv->ancillary_flag ^= !cfg->disable_reservoir; - } - - assert(remainingBits == 0); - -} - -/*write N bits into the header */ -inline static void -writeheader(lame_internal_flags * gfc, int val, int j) -{ - EncStateVar_t *const esv = &gfc->sv_enc; - int ptr = esv->header[esv->h_ptr].ptr; - - while (j > 0) { - int const k = Min(j, 8 - (ptr & 7)); - j -= k; - assert(j < MAX_LENGTH); /* >> 32 too large for 32 bit machines */ - esv->header[esv->h_ptr].buf[ptr >> 3] - |= ((val >> j)) << (8 - (ptr & 7) - k); - ptr += k; - } - esv->header[esv->h_ptr].ptr = ptr; -} - - -static int -CRC_update(int value, int crc) -{ - int i; - value <<= 8; - for (i = 0; i < 8; i++) { - value <<= 1; - crc <<= 1; - - if (((crc ^ value) & 0x10000)) - crc ^= CRC16_POLYNOMIAL; - } - return crc; -} - - -void -CRC_writeheader(lame_internal_flags const *gfc, char *header) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int crc = 0xffff; /* (jo) init crc16 for error_protection */ - int i; - - crc = CRC_update(((unsigned char *) header)[2], crc); - crc = CRC_update(((unsigned char *) header)[3], crc); - for (i = 6; i < cfg->sideinfo_len; i++) { - crc = CRC_update(((unsigned char *) header)[i], crc); - } - - header[4] = crc >> 8; - header[5] = crc & 255; -} - -inline static void -encodeSideInfo2(lame_internal_flags * gfc, int bitsPerFrame) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - EncStateVar_t *const esv = &gfc->sv_enc; - III_side_info_t *l3_side; - int gr, ch; - - l3_side = &gfc->l3_side; - esv->header[esv->h_ptr].ptr = 0; - memset(esv->header[esv->h_ptr].buf, 0, cfg->sideinfo_len); - if (cfg->samplerate_out < 16000) - writeheader(gfc, 0xffe, 12); - else - writeheader(gfc, 0xfff, 12); - writeheader(gfc, (cfg->version), 1); - writeheader(gfc, 4 - 3, 2); - writeheader(gfc, (!cfg->error_protection), 1); - writeheader(gfc, (eov->bitrate_index), 4); - writeheader(gfc, (cfg->samplerate_index), 2); - writeheader(gfc, (eov->padding), 1); - writeheader(gfc, (cfg->extension), 1); - writeheader(gfc, (cfg->mode), 2); - writeheader(gfc, (eov->mode_ext), 2); - writeheader(gfc, (cfg->copyright), 1); - writeheader(gfc, (cfg->original), 1); - writeheader(gfc, (cfg->emphasis), 2); - if (cfg->error_protection) { - writeheader(gfc, 0, 16); /* dummy */ - } - - if (cfg->version == 1) { - /* MPEG1 */ - assert(l3_side->main_data_begin >= 0); - writeheader(gfc, (l3_side->main_data_begin), 9); - - if (cfg->channels_out == 2) - writeheader(gfc, l3_side->private_bits, 3); - else - writeheader(gfc, l3_side->private_bits, 5); - - for (ch = 0; ch < cfg->channels_out; ch++) { - int band; - for (band = 0; band < 4; band++) { - writeheader(gfc, l3_side->scfsi[ch][band], 1); - } - } - - for (gr = 0; gr < 2; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info *const gi = &l3_side->tt[gr][ch]; - writeheader(gfc, gi->part2_3_length + gi->part2_length, 12); - writeheader(gfc, gi->big_values / 2, 9); - writeheader(gfc, gi->global_gain, 8); - writeheader(gfc, gi->scalefac_compress, 4); - - if (gi->block_type != NORM_TYPE) { - writeheader(gfc, 1, 1); /* window_switching_flag */ - writeheader(gfc, gi->block_type, 2); - writeheader(gfc, gi->mixed_block_flag, 1); - - if (gi->table_select[0] == 14) - gi->table_select[0] = 16; - writeheader(gfc, gi->table_select[0], 5); - if (gi->table_select[1] == 14) - gi->table_select[1] = 16; - writeheader(gfc, gi->table_select[1], 5); - - writeheader(gfc, gi->subblock_gain[0], 3); - writeheader(gfc, gi->subblock_gain[1], 3); - writeheader(gfc, gi->subblock_gain[2], 3); - } - else { - writeheader(gfc, 0, 1); /* window_switching_flag */ - if (gi->table_select[0] == 14) - gi->table_select[0] = 16; - writeheader(gfc, gi->table_select[0], 5); - if (gi->table_select[1] == 14) - gi->table_select[1] = 16; - writeheader(gfc, gi->table_select[1], 5); - if (gi->table_select[2] == 14) - gi->table_select[2] = 16; - writeheader(gfc, gi->table_select[2], 5); - - assert(0 <= gi->region0_count && gi->region0_count < 16); - assert(0 <= gi->region1_count && gi->region1_count < 8); - writeheader(gfc, gi->region0_count, 4); - writeheader(gfc, gi->region1_count, 3); - } - writeheader(gfc, gi->preflag, 1); - writeheader(gfc, gi->scalefac_scale, 1); - writeheader(gfc, gi->count1table_select, 1); - } - } - } - else { - /* MPEG2 */ - assert(l3_side->main_data_begin >= 0); - writeheader(gfc, (l3_side->main_data_begin), 8); - writeheader(gfc, l3_side->private_bits, cfg->channels_out); - - gr = 0; - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info *const gi = &l3_side->tt[gr][ch]; - writeheader(gfc, gi->part2_3_length + gi->part2_length, 12); - writeheader(gfc, gi->big_values / 2, 9); - writeheader(gfc, gi->global_gain, 8); - writeheader(gfc, gi->scalefac_compress, 9); - - if (gi->block_type != NORM_TYPE) { - writeheader(gfc, 1, 1); /* window_switching_flag */ - writeheader(gfc, gi->block_type, 2); - writeheader(gfc, gi->mixed_block_flag, 1); - - if (gi->table_select[0] == 14) - gi->table_select[0] = 16; - writeheader(gfc, gi->table_select[0], 5); - if (gi->table_select[1] == 14) - gi->table_select[1] = 16; - writeheader(gfc, gi->table_select[1], 5); - - writeheader(gfc, gi->subblock_gain[0], 3); - writeheader(gfc, gi->subblock_gain[1], 3); - writeheader(gfc, gi->subblock_gain[2], 3); - } - else { - writeheader(gfc, 0, 1); /* window_switching_flag */ - if (gi->table_select[0] == 14) - gi->table_select[0] = 16; - writeheader(gfc, gi->table_select[0], 5); - if (gi->table_select[1] == 14) - gi->table_select[1] = 16; - writeheader(gfc, gi->table_select[1], 5); - if (gi->table_select[2] == 14) - gi->table_select[2] = 16; - writeheader(gfc, gi->table_select[2], 5); - - assert(0 <= gi->region0_count && gi->region0_count < 16); - assert(0 <= gi->region1_count && gi->region1_count < 8); - writeheader(gfc, gi->region0_count, 4); - writeheader(gfc, gi->region1_count, 3); - } - - writeheader(gfc, gi->scalefac_scale, 1); - writeheader(gfc, gi->count1table_select, 1); - } - } - - if (cfg->error_protection) { - /* (jo) error_protection: add crc16 information to header */ - CRC_writeheader(gfc, esv->header[esv->h_ptr].buf); - } - - { - int const old = esv->h_ptr; - assert(esv->header[old].ptr == cfg->sideinfo_len * 8); - - esv->h_ptr = (old + 1) & (MAX_HEADER_BUF - 1); - esv->header[esv->h_ptr].write_timing = esv->header[old].write_timing + bitsPerFrame; - - if (esv->h_ptr == esv->w_ptr) { - /* yikes! we are out of header buffer space */ - ERRORF(gfc, "Error: MAX_HEADER_BUF too small in bitstream.c \n"); - } - - } -} - - -inline static int -huffman_coder_count1(lame_internal_flags * gfc, gr_info const *gi) -{ - /* Write count1 area */ - struct huffcodetab const *const h = &ht[gi->count1table_select + 32]; - int i, bits = 0; -#ifdef DEBUG - int gegebo = gfc->bs.totbit; -#endif - - int const *ix = &gi->l3_enc[gi->big_values]; - FLOAT const *xr = &gi->xr[gi->big_values]; - assert(gi->count1table_select < 2); - - for (i = (gi->count1 - gi->big_values) / 4; i > 0; --i) { - int huffbits = 0; - int p = 0, v; - - v = ix[0]; - if (v) { - p += 8; - if (xr[0] < 0.0f) - huffbits++; - assert(v <= 1); - } - - v = ix[1]; - if (v) { - p += 4; - huffbits *= 2; - if (xr[1] < 0.0f) - huffbits++; - assert(v <= 1); - } - - v = ix[2]; - if (v) { - p += 2; - huffbits *= 2; - if (xr[2] < 0.0f) - huffbits++; - assert(v <= 1); - } - - v = ix[3]; - if (v) { - p++; - huffbits *= 2; - if (xr[3] < 0.0f) - huffbits++; - assert(v <= 1); - } - - ix += 4; - xr += 4; - putbits2(gfc, huffbits + h->table[p], h->hlen[p]); - bits += h->hlen[p]; - } -#ifdef DEBUG - DEBUGF(gfc, "count1: real: %ld counted:%d (bigv %d count1len %d)\n", - gfc->bs.totbit - gegebo, gi->count1bits, gi->big_values, gi->count1); -#endif - return bits; -} - - - -/* - Implements the pseudocode of page 98 of the IS - */ -inline static int -Huffmancode(lame_internal_flags * const gfc, const unsigned int tableindex, - int start, int end, gr_info const *gi) -{ - struct huffcodetab const *const h = &ht[tableindex]; - unsigned int const linbits = h->xlen; - int i, bits = 0; - - assert(tableindex < 32u); - if (!tableindex) - return bits; - - for (i = start; i < end; i += 2) { - int16_t cbits = 0; - uint16_t xbits = 0; - unsigned int xlen = h->xlen; - unsigned int ext = 0; - unsigned int x1 = gi->l3_enc[i]; - unsigned int x2 = gi->l3_enc[i + 1]; - - assert(gi->l3_enc[i] >= 0); - assert(gi->l3_enc[i+1] >= 0); - - if (x1 != 0u) { - if (gi->xr[i] < 0.0f) - ext++; - cbits--; - } - - if (tableindex > 15u) { - /* use ESC-words */ - if (x1 >= 15u) { - uint16_t const linbits_x1 = x1 - 15u; - assert(linbits_x1 <= h->linmax); - ext |= linbits_x1 << 1u; - xbits = linbits; - x1 = 15u; - } - - if (x2 >= 15u) { - uint16_t const linbits_x2 = x2 - 15u; - assert(linbits_x2 <= h->linmax); - ext <<= linbits; - ext |= linbits_x2; - xbits += linbits; - x2 = 15u; - } - xlen = 16; - } - - if (x2 != 0u) { - ext <<= 1; - if (gi->xr[i + 1] < 0.0f) - ext++; - cbits--; - } - - assert((x1 | x2) < 16u); - - x1 = x1 * xlen + x2; - xbits -= cbits; - cbits += h->hlen[x1]; - - assert(cbits <= MAX_LENGTH); - assert(xbits <= MAX_LENGTH); - - putbits2(gfc, h->table[x1], cbits); - putbits2(gfc, (int)ext, xbits); - bits += cbits + xbits; - } - return bits; -} - -/* - Note the discussion of huffmancodebits() on pages 28 - and 29 of the IS, as well as the definitions of the side - information on pages 26 and 27. - */ -static int -ShortHuffmancodebits(lame_internal_flags * gfc, gr_info const *gi) -{ - int bits; - int region1Start; - - region1Start = 3 * gfc->scalefac_band.s[3]; - if (region1Start > gi->big_values) - region1Start = gi->big_values; - - /* short blocks do not have a region2 */ - bits = Huffmancode(gfc, gi->table_select[0], 0, region1Start, gi); - bits += Huffmancode(gfc, gi->table_select[1], region1Start, gi->big_values, gi); - return bits; -} - -static int -LongHuffmancodebits(lame_internal_flags * gfc, gr_info const *gi) -{ - unsigned int i; - int bigvalues, bits; - int region1Start, region2Start; - - bigvalues = gi->big_values; - assert(0 <= bigvalues && bigvalues <= 576); - - assert(gi->region0_count >= -1); - assert(gi->region1_count >= -1); - i = gi->region0_count + 1; - assert((size_t) i < dimension_of(gfc->scalefac_band.l)); - region1Start = gfc->scalefac_band.l[i]; - i += gi->region1_count + 1; - assert((size_t) i < dimension_of(gfc->scalefac_band.l)); - region2Start = gfc->scalefac_band.l[i]; - - if (region1Start > bigvalues) - region1Start = bigvalues; - - if (region2Start > bigvalues) - region2Start = bigvalues; - - bits = Huffmancode(gfc, gi->table_select[0], 0, region1Start, gi); - bits += Huffmancode(gfc, gi->table_select[1], region1Start, region2Start, gi); - bits += Huffmancode(gfc, gi->table_select[2], region2Start, bigvalues, gi); - return bits; -} - -inline static int -writeMainData(lame_internal_flags * const gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - III_side_info_t const *const l3_side = &gfc->l3_side; - int gr, ch, sfb, data_bits, tot_bits = 0; - - if (cfg->version == 1) { - /* MPEG 1 */ - for (gr = 0; gr < 2; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info const *const gi = &l3_side->tt[gr][ch]; - int const slen1 = slen1_tab[gi->scalefac_compress]; - int const slen2 = slen2_tab[gi->scalefac_compress]; - data_bits = 0; -#ifdef DEBUG - hogege = gfc->bs.totbit; -#endif - for (sfb = 0; sfb < gi->sfbdivide; sfb++) { - if (gi->scalefac[sfb] == -1) - continue; /* scfsi is used */ - putbits2(gfc, gi->scalefac[sfb], slen1); - data_bits += slen1; - } - for (; sfb < gi->sfbmax; sfb++) { - if (gi->scalefac[sfb] == -1) - continue; /* scfsi is used */ - putbits2(gfc, gi->scalefac[sfb], slen2); - data_bits += slen2; - } - assert(data_bits == gi->part2_length); - - if (gi->block_type == SHORT_TYPE) { - data_bits += ShortHuffmancodebits(gfc, gi); - } - else { - data_bits += LongHuffmancodebits(gfc, gi); - } - data_bits += huffman_coder_count1(gfc, gi); -#ifdef DEBUG - DEBUGF(gfc, "<%ld> ", gfc->bs.totbit - hogege); -#endif - /* does bitcount in quantize.c agree with actual bit count? */ - assert(data_bits == gi->part2_3_length + gi->part2_length); - tot_bits += data_bits; - } /* for ch */ - } /* for gr */ - } - else { - /* MPEG 2 */ - gr = 0; - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info const *const gi = &l3_side->tt[gr][ch]; - int i, sfb_partition, scale_bits = 0; - assert(gi->sfb_partition_table); - data_bits = 0; -#ifdef DEBUG - hogege = gfc->bs.totbit; -#endif - sfb = 0; - sfb_partition = 0; - - if (gi->block_type == SHORT_TYPE) { - for (; sfb_partition < 4; sfb_partition++) { - int const sfbs = gi->sfb_partition_table[sfb_partition] / 3; - int const slen = gi->slen[sfb_partition]; - for (i = 0; i < sfbs; i++, sfb++) { - putbits2(gfc, Max(gi->scalefac[sfb * 3 + 0], 0), slen); - putbits2(gfc, Max(gi->scalefac[sfb * 3 + 1], 0), slen); - putbits2(gfc, Max(gi->scalefac[sfb * 3 + 2], 0), slen); - scale_bits += 3 * slen; - } - } - data_bits += ShortHuffmancodebits(gfc, gi); - } - else { - for (; sfb_partition < 4; sfb_partition++) { - int const sfbs = gi->sfb_partition_table[sfb_partition]; - int const slen = gi->slen[sfb_partition]; - for (i = 0; i < sfbs; i++, sfb++) { - putbits2(gfc, Max(gi->scalefac[sfb], 0), slen); - scale_bits += slen; - } - } - data_bits += LongHuffmancodebits(gfc, gi); - } - data_bits += huffman_coder_count1(gfc, gi); -#ifdef DEBUG - DEBUGF(gfc, "<%ld> ", gfc->bs.totbit - hogege); -#endif - /* does bitcount in quantize.c agree with actual bit count? */ - assert(data_bits == gi->part2_3_length); - assert(scale_bits == gi->part2_length); - tot_bits += scale_bits + data_bits; - } /* for ch */ - } /* for gf */ - return tot_bits; -} /* main_data */ - - - -/* compute the number of bits required to flush all mp3 frames - currently in the buffer. This should be the same as the - reservoir size. Only call this routine between frames - i.e. - only after all headers and data have been added to the buffer - by format_bitstream(). - - Also compute total_bits_output = - size of mp3 buffer (including frame headers which may not - have yet been send to the mp3 buffer) + - number of bits needed to flush all mp3 frames. - - total_bytes_output is the size of the mp3 output buffer if - lame_encode_flush_nogap() was called right now. - - */ -int -compute_flushbits(const lame_internal_flags * gfc, int *total_bytes_output) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t const *const esv = &gfc->sv_enc; - int flushbits, remaining_headers; - int bitsPerFrame; - int last_ptr, first_ptr; - first_ptr = esv->w_ptr; /* first header to add to bitstream */ - last_ptr = esv->h_ptr - 1; /* last header to add to bitstream */ - if (last_ptr == -1) - last_ptr = MAX_HEADER_BUF - 1; - - /* add this many bits to bitstream so we can flush all headers */ - flushbits = esv->header[last_ptr].write_timing - gfc->bs.totbit; - *total_bytes_output = flushbits; - - if (flushbits >= 0) { - /* if flushbits >= 0, some headers have not yet been written */ - /* reduce flushbits by the size of the headers */ - remaining_headers = 1 + last_ptr - first_ptr; - if (last_ptr < first_ptr) - remaining_headers = 1 + last_ptr - first_ptr + MAX_HEADER_BUF; - flushbits -= remaining_headers * 8 * cfg->sideinfo_len; - } - - - /* finally, add some bits so that the last frame is complete - * these bits are not necessary to decode the last frame, but - * some decoders will ignore last frame if these bits are missing - */ - bitsPerFrame = getframebits(gfc); - flushbits += bitsPerFrame; - *total_bytes_output += bitsPerFrame; - /* round up: */ - if (*total_bytes_output % 8) - *total_bytes_output = 1 + (*total_bytes_output / 8); - else - *total_bytes_output = (*total_bytes_output / 8); - *total_bytes_output += gfc->bs.buf_byte_idx + 1; - - - if (flushbits < 0) { -#if 0 - /* if flushbits < 0, this would mean that the buffer looks like: - * (data...) last_header (data...) (extra data that should not be here...) - */ - DEBUGF(gfc, "last header write_timing = %i \n", esv->header[last_ptr].write_timing); - DEBUGF(gfc, "first header write_timing = %i \n", esv->header[first_ptr].write_timing); - DEBUGF(gfc, "bs.totbit: %i \n", gfc->bs.totbit); - DEBUGF(gfc, "first_ptr, last_ptr %i %i \n", first_ptr, last_ptr); - DEBUGF(gfc, "remaining_headers = %i \n", remaining_headers); - DEBUGF(gfc, "bitsperframe: %i \n", bitsPerFrame); - DEBUGF(gfc, "sidelen: %i \n", cfg->sideinfo_len); -#endif - ERRORF(gfc, "strange error flushing buffer ... \n"); - } - return flushbits; -} - - -void -flush_bitstream(lame_internal_flags * gfc) -{ - EncStateVar_t *const esv = &gfc->sv_enc; - III_side_info_t *l3_side; - int nbytes; - int flushbits; - int last_ptr = esv->h_ptr - 1; /* last header to add to bitstream */ - if (last_ptr == -1) - last_ptr = MAX_HEADER_BUF - 1; - l3_side = &gfc->l3_side; - - - if ((flushbits = compute_flushbits(gfc, &nbytes)) < 0) - return; - drain_into_ancillary(gfc, flushbits); - - /* check that the 100% of the last frame has been written to bitstream */ - assert(esv->header[last_ptr].write_timing + getframebits(gfc) - == gfc->bs.totbit); - - /* we have padded out all frames with ancillary data, which is the - same as filling the bitreservoir with ancillary data, so : */ - esv->ResvSize = 0; - l3_side->main_data_begin = 0; -} - - - - -void -add_dummy_byte(lame_internal_flags * gfc, unsigned char val, unsigned int n) -{ - EncStateVar_t *const esv = &gfc->sv_enc; - int i; - - while (n-- > 0u) { - putbits_noheaders(gfc, val, 8); - - for (i = 0; i < MAX_HEADER_BUF; ++i) - esv->header[i].write_timing += 8; - } -} - - -/* - format_bitstream() - - This is called after a frame of audio has been quantized and coded. - It will write the encoded audio to the bitstream. Note that - from a layer3 encoder's perspective the bit stream is primarily - a series of main_data() blocks, with header and side information - inserted at the proper locations to maintain framing. (See Figure A.7 - in the IS). - */ -int -format_bitstream(lame_internal_flags * gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int bits, nbytes; - III_side_info_t *l3_side; - int bitsPerFrame; - l3_side = &gfc->l3_side; - - bitsPerFrame = getframebits(gfc); - drain_into_ancillary(gfc, l3_side->resvDrain_pre); - - encodeSideInfo2(gfc, bitsPerFrame); - bits = 8 * cfg->sideinfo_len; - bits += writeMainData(gfc); - drain_into_ancillary(gfc, l3_side->resvDrain_post); - bits += l3_side->resvDrain_post; - - l3_side->main_data_begin += (bitsPerFrame - bits) / 8; - - /* compare number of bits needed to clear all buffered mp3 frames - * with what we think the resvsize is: */ - if (compute_flushbits(gfc, &nbytes) != esv->ResvSize) { - ERRORF(gfc, "Internal buffer inconsistency. flushbits <> ResvSize"); - } - - - /* compare main_data_begin for the next frame with what we - * think the resvsize is: */ - if ((l3_side->main_data_begin * 8) != esv->ResvSize) { - ERRORF(gfc, "bit reservoir error: \n" - "l3_side->main_data_begin: %i \n" - "Resvoir size: %i \n" - "resv drain (post) %i \n" - "resv drain (pre) %i \n" - "header and sideinfo: %i \n" - "data bits: %i \n" - "total bits: %i (remainder: %i) \n" - "bitsperframe: %i \n", - 8 * l3_side->main_data_begin, - esv->ResvSize, - l3_side->resvDrain_post, - l3_side->resvDrain_pre, - 8 * cfg->sideinfo_len, - bits - l3_side->resvDrain_post - 8 * cfg->sideinfo_len, - bits, bits % 8, bitsPerFrame); - - ERRORF(gfc, "This is a fatal error. It has several possible causes:"); - ERRORF(gfc, "90%% LAME compiled with buggy version of gcc using advanced optimizations"); - ERRORF(gfc, " 9%% Your system is overclocked"); - ERRORF(gfc, " 1%% bug in LAME encoding library"); - - esv->ResvSize = l3_side->main_data_begin * 8; - }; - assert(gfc->bs.totbit % 8 == 0); - - if (gfc->bs.totbit > 1000000000) { - /* to avoid totbit overflow, (at 8h encoding at 128kbs) lets reset bit counter */ - int i; - for (i = 0; i < MAX_HEADER_BUF; ++i) - esv->header[i].write_timing -= gfc->bs.totbit; - gfc->bs.totbit = 0; - } - - - return 0; -} - - -static int -do_gain_analysis(lame_internal_flags * gfc, unsigned char* buffer, int minimum) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - RpgStateVar_t const *const rsv = &gfc->sv_rpg; - RpgResult_t *const rov = &gfc->ov_rpg; -#ifdef DECODE_ON_THE_FLY - if (cfg->decode_on_the_fly) { /* decode the frame */ - sample_t pcm_buf[2][1152]; - int mp3_in = minimum; - int samples_out = -1; - - /* re-synthesis to pcm. Repeat until we get a samples_out=0 */ - while (samples_out != 0) { - - samples_out = hip_decode1_unclipped(gfc->hip, buffer, mp3_in, pcm_buf[0], pcm_buf[1]); - /* samples_out = 0: need more data to decode - * samples_out = -1: error. Lets assume 0 pcm output - * samples_out = number of samples output */ - - /* set the lenght of the mp3 input buffer to zero, so that in the - * next iteration of the loop we will be querying mpglib about - * buffered data */ - mp3_in = 0; - - if (samples_out == -1) { - /* error decoding. Not fatal, but might screw up - * the ReplayGain tag. What should we do? Ignore for now */ - samples_out = 0; - } - if (samples_out > 0) { - /* process the PCM data */ - - /* this should not be possible, and indicates we have - * overflown the pcm_buf buffer */ - assert(samples_out <= 1152); - - if (cfg->findPeakSample) { - int i; - /* FIXME: is this correct? maybe Max(fabs(pcm),PeakSample) */ - for (i = 0; i < samples_out; i++) { - if (pcm_buf[0][i] > rov->PeakSample) - rov->PeakSample = pcm_buf[0][i]; - else if (-pcm_buf[0][i] > rov->PeakSample) - rov->PeakSample = -pcm_buf[0][i]; - } - if (cfg->channels_out > 1) - for (i = 0; i < samples_out; i++) { - if (pcm_buf[1][i] > rov->PeakSample) - rov->PeakSample = pcm_buf[1][i]; - else if (-pcm_buf[1][i] > rov->PeakSample) - rov->PeakSample = -pcm_buf[1][i]; - } - } - - if (cfg->findReplayGain) - if (AnalyzeSamples - (rsv->rgdata, pcm_buf[0], pcm_buf[1], samples_out, - cfg->channels_out) == GAIN_ANALYSIS_ERROR) - return -6; - - } /* if (samples_out>0) */ - } /* while (samples_out!=0) */ - } /* if (gfc->decode_on_the_fly) */ -#endif - return minimum; -} - -static int -do_copy_buffer(lame_internal_flags * gfc, unsigned char *buffer, int size) -{ - Bit_stream_struc *const bs = &gfc->bs; - int const minimum = bs->buf_byte_idx + 1; - if (minimum <= 0) - return 0; - if (minimum > size) - return -1; /* buffer is too small */ - memcpy(buffer, bs->buf, minimum); - bs->buf_byte_idx = -1; - bs->buf_bit_idx = 0; - return minimum; -} - -/* copy data out of the internal MP3 bit buffer into a user supplied - unsigned char buffer. - - mp3data=0 indicates data in buffer is an id3tags and VBR tags - mp3data=1 data is real mp3 frame data. - - -*/ -int -copy_buffer(lame_internal_flags * gfc, unsigned char *buffer, int size, int mp3data) -{ - int const minimum = do_copy_buffer(gfc, buffer, size); - if (minimum > 0 && mp3data) { - UpdateMusicCRC(&gfc->nMusicCRC, buffer, minimum); - - /** sum number of bytes belonging to the mp3 stream - * this info will be written into the Xing/LAME header for seeking - */ - gfc->VBR_seek_table.nBytesWritten += minimum; - - return do_gain_analysis(gfc, buffer, minimum); - } /* if (mp3data) */ - return minimum; -} - - -void -init_bit_stream_w(lame_internal_flags * gfc) -{ - EncStateVar_t *const esv = &gfc->sv_enc; - - esv->h_ptr = esv->w_ptr = 0; - esv->header[esv->h_ptr].write_timing = 0; - - gfc->bs.buf = lame_calloc(unsigned char, BUFFER_SIZE); - gfc->bs.buf_size = BUFFER_SIZE; - gfc->bs.buf_byte_idx = -1; - gfc->bs.buf_bit_idx = 0; - gfc->bs.totbit = 0; -} - -/* end of bitstream.c */ diff --git a/lib-src/lame/libmp3lame/bitstream.h b/lib-src/lame/libmp3lame/bitstream.h deleted file mode 100644 index 3ae48d029..000000000 --- a/lib-src/lame/libmp3lame/bitstream.h +++ /dev/null @@ -1,40 +0,0 @@ -/* - * MP3 bitstream Output interface for LAME - * - * Copyright (c) 1999 Takehiro TOMINAGA - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_BITSTREAM_H -#define LAME_BITSTREAM_H - -int getframebits(const lame_internal_flags * gfc); - -int format_bitstream(lame_internal_flags * gfc); - -void flush_bitstream(lame_internal_flags * gfc); -void add_dummy_byte(lame_internal_flags * gfc, unsigned char val, unsigned int n); - -int copy_buffer(lame_internal_flags * gfc, unsigned char *buffer, int buffer_size, - int update_crc); -void init_bit_stream_w(lame_internal_flags * gfc); -void CRC_writeheader(lame_internal_flags const *gfc, char *buffer); -int compute_flushbits(const lame_internal_flags * gfp, int *nbytes); - -int get_max_frame_buffer_size_by_constraint(SessionConfig_t const * cfg, int constraint); - -#endif diff --git a/lib-src/lame/libmp3lame/depcomp b/lib-src/lame/libmp3lame/depcomp deleted file mode 100644 index b39f98f9a..000000000 --- a/lib-src/lame/libmp3lame/depcomp +++ /dev/null @@ -1,791 +0,0 @@ -#! /bin/sh -# depcomp - compile a program generating dependencies as side-effects - -scriptversion=2016-01-11.22; # UTC - -# Copyright (C) 1999-2017 Free Software Foundation, Inc. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Originally written by Alexandre Oliva . - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: depcomp [--help] [--version] PROGRAM [ARGS] - -Run PROGRAMS ARGS to compile a file, generating dependencies -as side-effects. - -Environment variables: - depmode Dependency tracking mode. - source Source file read by 'PROGRAMS ARGS'. - object Object file output by 'PROGRAMS ARGS'. - DEPDIR directory where to store dependencies. - depfile Dependency file to output. - tmpdepfile Temporary file to use when outputting dependencies. - libtool Whether libtool is used (yes/no). - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "depcomp $scriptversion" - exit $? - ;; -esac - -# Get the directory component of the given path, and save it in the -# global variables '$dir'. Note that this directory component will -# be either empty or ending with a '/' character. This is deliberate. -set_dir_from () -{ - case $1 in - */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; - *) dir=;; - esac -} - -# Get the suffix-stripped basename of the given path, and save it the -# global variable '$base'. -set_base_from () -{ - base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` -} - -# If no dependency file was actually created by the compiler invocation, -# we still have to create a dummy depfile, to avoid errors with the -# Makefile "include basename.Plo" scheme. -make_dummy_depfile () -{ - echo "#dummy" > "$depfile" -} - -# Factor out some common post-processing of the generated depfile. -# Requires the auxiliary global variable '$tmpdepfile' to be set. -aix_post_process_depfile () -{ - # If the compiler actually managed to produce a dependency file, - # post-process it. - if test -f "$tmpdepfile"; then - # Each line is of the form 'foo.o: dependency.h'. - # Do two passes, one to just change these to - # $object: dependency.h - # and one to simply output - # dependency.h: - # which is needed to avoid the deleted-header problem. - { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" - sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" - } > "$depfile" - rm -f "$tmpdepfile" - else - make_dummy_depfile - fi -} - -# A tabulation character. -tab=' ' -# A newline character. -nl=' -' -# Character ranges might be problematic outside the C locale. -# These definitions help. -upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ -lower=abcdefghijklmnopqrstuvwxyz -digits=0123456789 -alpha=${upper}${lower} - -if test -z "$depmode" || test -z "$source" || test -z "$object"; then - echo "depcomp: Variables source, object and depmode must be set" 1>&2 - exit 1 -fi - -# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. -depfile=${depfile-`echo "$object" | - sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} -tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} - -rm -f "$tmpdepfile" - -# Avoid interferences from the environment. -gccflag= dashmflag= - -# Some modes work just like other modes, but use different flags. We -# parameterize here, but still list the modes in the big case below, -# to make depend.m4 easier to write. Note that we *cannot* use a case -# here, because this file can only contain one case statement. -if test "$depmode" = hp; then - # HP compiler uses -M and no extra arg. - gccflag=-M - depmode=gcc -fi - -if test "$depmode" = dashXmstdout; then - # This is just like dashmstdout with a different argument. - dashmflag=-xM - depmode=dashmstdout -fi - -cygpath_u="cygpath -u -f -" -if test "$depmode" = msvcmsys; then - # This is just like msvisualcpp but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvisualcpp -fi - -if test "$depmode" = msvc7msys; then - # This is just like msvc7 but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvc7 -fi - -if test "$depmode" = xlc; then - # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. - gccflag=-qmakedep=gcc,-MF - depmode=gcc -fi - -case "$depmode" in -gcc3) -## gcc 3 implements dependency tracking that does exactly what -## we want. Yay! Note: for some reason libtool 1.4 doesn't like -## it if -MD -MP comes after the -MF stuff. Hmm. -## Unfortunately, FreeBSD c89 acceptance of flags depends upon -## the command line argument order; so add the flags where they -## appear in depend2.am. Note that the slowdown incurred here -## affects only configure: in makefiles, %FASTDEP% shortcuts this. - for arg - do - case $arg in - -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; - *) set fnord "$@" "$arg" ;; - esac - shift # fnord - shift # $arg - done - "$@" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - mv "$tmpdepfile" "$depfile" - ;; - -gcc) -## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. -## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. -## (see the conditional assignment to $gccflag above). -## There are various ways to get dependency output from gcc. Here's -## why we pick this rather obscure method: -## - Don't want to use -MD because we'd like the dependencies to end -## up in a subdir. Having to rename by hand is ugly. -## (We might end up doing this anyway to support other compilers.) -## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like -## -MM, not -M (despite what the docs say). Also, it might not be -## supported by the other compilers which use the 'gcc' depmode. -## - Using -M directly means running the compiler twice (even worse -## than renaming). - if test -z "$gccflag"; then - gccflag=-MD, - fi - "$@" -Wp,"$gccflag$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The second -e expression handles DOS-style file names with drive - # letters. - sed -e 's/^[^:]*: / /' \ - -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" -## This next piece of magic avoids the "deleted header file" problem. -## The problem is that when a header file which appears in a .P file -## is deleted, the dependency causes make to die (because there is -## typically no way to rebuild the header). We avoid this by adding -## dummy dependencies for each header file. Too bad gcc doesn't do -## this for us directly. -## Some versions of gcc put a space before the ':'. On the theory -## that the space means something, we add a space to the output as -## well. hp depmode also adds that space, but also prefixes the VPATH -## to the object. Take care to not repeat it in the output. -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -sgi) - if test "$libtool" = yes; then - "$@" "-Wp,-MDupdate,$tmpdepfile" - else - "$@" -MDupdate "$tmpdepfile" - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - - if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files - echo "$object : \\" > "$depfile" - # Clip off the initial element (the dependent). Don't try to be - # clever and replace this with sed code, as IRIX sed won't handle - # lines with more than a fixed number of characters (4096 in - # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; - # the IRIX cc adds comments like '#:fec' to the end of the - # dependency line. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ - | tr "$nl" ' ' >> "$depfile" - echo >> "$depfile" - # The second pass generates a dummy entry for each header file. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" - ;; - -xlc) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -aix) - # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. In older versions, this file always lives in the - # current directory. Also, the AIX compiler puts '$object:' at the - # start of each line; $object doesn't have directory information. - # Version 6 uses the directory in both cases. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.u - tmpdepfile2=$base.u - tmpdepfile3=$dir.libs/$base.u - "$@" -Wc,-M - else - tmpdepfile1=$dir$base.u - tmpdepfile2=$dir$base.u - tmpdepfile3=$dir$base.u - "$@" -M - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - aix_post_process_depfile - ;; - -tcc) - # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 - # FIXME: That version still under development at the moment of writing. - # Make that this statement remains true also for stable, released - # versions. - # It will wrap lines (doesn't matter whether long or short) with a - # trailing '\', as in: - # - # foo.o : \ - # foo.c \ - # foo.h \ - # - # It will put a trailing '\' even on the last line, and will use leading - # spaces rather than leading tabs (at least since its commit 0394caf7 - # "Emit spaces for -MD"). - "$@" -MD -MF "$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. - # We have to change lines of the first kind to '$object: \'. - sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" - # And for each line of the second kind, we have to emit a 'dep.h:' - # dummy dependency, to avoid the deleted-header problem. - sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" - rm -f "$tmpdepfile" - ;; - -## The order of this option in the case statement is important, since the -## shell code in configure will try each of these formats in the order -## listed in this file. A plain '-MD' option would be understood by many -## compilers, so we must ensure this comes after the gcc and icc options. -pgcc) - # Portland's C compiler understands '-MD'. - # Will always output deps to 'file.d' where file is the root name of the - # source file under compilation, even if file resides in a subdirectory. - # The object file name does not affect the name of the '.d' file. - # pgcc 10.2 will output - # foo.o: sub/foo.c sub/foo.h - # and will wrap long lines using '\' : - # foo.o: sub/foo.c ... \ - # sub/foo.h ... \ - # ... - set_dir_from "$object" - # Use the source, not the object, to determine the base name, since - # that's sadly what pgcc will do too. - set_base_from "$source" - tmpdepfile=$base.d - - # For projects that build the same source file twice into different object - # files, the pgcc approach of using the *source* file root name can cause - # problems in parallel builds. Use a locking strategy to avoid stomping on - # the same $tmpdepfile. - lockdir=$base.d-lock - trap " - echo '$0: caught signal, cleaning up...' >&2 - rmdir '$lockdir' - exit 1 - " 1 2 13 15 - numtries=100 - i=$numtries - while test $i -gt 0; do - # mkdir is a portable test-and-set. - if mkdir "$lockdir" 2>/dev/null; then - # This process acquired the lock. - "$@" -MD - stat=$? - # Release the lock. - rmdir "$lockdir" - break - else - # If the lock is being held by a different process, wait - # until the winning process is done or we timeout. - while test -d "$lockdir" && test $i -gt 0; do - sleep 1 - i=`expr $i - 1` - done - fi - i=`expr $i - 1` - done - trap - 1 2 13 15 - if test $i -le 0; then - echo "$0: failed to acquire lock after $numtries attempts" >&2 - echo "$0: check lockdir '$lockdir'" >&2 - exit 1 - fi - - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each line is of the form `foo.o: dependent.h', - # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp2) - # The "hp" stanza above does not work with aCC (C++) and HP's ia64 - # compilers, which have integrated preprocessors. The correct option - # to use with these is +Maked; it writes dependencies to a file named - # 'foo.d', which lands next to the object file, wherever that - # happens to be. - # Much of this is similar to the tru64 case; see comments there. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir.libs/$base.d - "$@" -Wc,+Maked - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - "$@" +Maked - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" - do - test -f "$tmpdepfile" && break - done - if test -f "$tmpdepfile"; then - sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" - # Add 'dependent.h:' lines. - sed -ne '2,${ - s/^ *// - s/ \\*$// - s/$/:/ - p - }' "$tmpdepfile" >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" "$tmpdepfile2" - ;; - -tru64) - # The Tru64 compiler uses -MD to generate dependencies as a side - # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. - # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put - # dependencies in 'foo.d' instead, so we check for that too. - # Subdirectories are respected. - set_dir_from "$object" - set_base_from "$object" - - if test "$libtool" = yes; then - # Libtool generates 2 separate objects for the 2 libraries. These - # two compilations output dependencies in $dir.libs/$base.o.d and - # in $dir$base.o.d. We have to check for both files, because - # one of the two compilations can be disabled. We should prefer - # $dir$base.o.d over $dir.libs/$base.o.d because the latter is - # automatically cleaned when .libs/ is deleted, while ignoring - # the former would cause a distcleancheck panic. - tmpdepfile1=$dir$base.o.d # libtool 1.5 - tmpdepfile2=$dir.libs/$base.o.d # Likewise. - tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 - "$@" -Wc,-MD - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - tmpdepfile3=$dir$base.d - "$@" -MD - fi - - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - # Same post-processing that is required for AIX mode. - aix_post_process_depfile - ;; - -msvc7) - if test "$libtool" = yes; then - showIncludes=-Wc,-showIncludes - else - showIncludes=-showIncludes - fi - "$@" $showIncludes > "$tmpdepfile" - stat=$? - grep -v '^Note: including file: ' "$tmpdepfile" - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The first sed program below extracts the file names and escapes - # backslashes for cygpath. The second sed program outputs the file - # name when reading, but also accumulates all include files in the - # hold buffer in order to output them again at the end. This only - # works with sed implementations that can handle large buffers. - sed < "$tmpdepfile" -n ' -/^Note: including file: *\(.*\)/ { - s//\1/ - s/\\/\\\\/g - p -}' | $cygpath_u | sort -u | sed -n ' -s/ /\\ /g -s/\(.*\)/'"$tab"'\1 \\/p -s/.\(.*\) \\/\1:/ -H -$ { - s/.*/'"$tab"'/ - G - p -}' >> "$depfile" - echo >> "$depfile" # make sure the fragment doesn't end with a backslash - rm -f "$tmpdepfile" - ;; - -msvc7msys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -#nosideeffect) - # This comment above is used by automake to tell side-effect - # dependency tracking mechanisms from slower ones. - -dashmstdout) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - test -z "$dashmflag" && dashmflag=-M - # Require at least two characters before searching for ':' - # in the target name. This is to cope with DOS-style filenames: - # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. - "$@" $dashmflag | - sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this sed invocation - # correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -dashXmstdout) - # This case only exists to satisfy depend.m4. It is never actually - # run, as this mode is specially recognized in the preamble. - exit 1 - ;; - -makedepend) - "$@" || exit $? - # Remove any Libtool call - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - # X makedepend - shift - cleared=no eat=no - for arg - do - case $cleared in - no) - set ""; shift - cleared=yes ;; - esac - if test $eat = yes; then - eat=no - continue - fi - case "$arg" in - -D*|-I*) - set fnord "$@" "$arg"; shift ;; - # Strip any option that makedepend may not understand. Remove - # the object too, otherwise makedepend will parse it as a source file. - -arch) - eat=yes ;; - -*|$object) - ;; - *) - set fnord "$@" "$arg"; shift ;; - esac - done - obj_suffix=`echo "$object" | sed 's/^.*\././'` - touch "$tmpdepfile" - ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" - rm -f "$depfile" - # makedepend may prepend the VPATH from the source file name to the object. - # No need to regex-escape $object, excess matching of '.' is harmless. - sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process the last invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed '1,2d' "$tmpdepfile" \ - | tr ' ' "$nl" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" "$tmpdepfile".bak - ;; - -cpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - "$@" -E \ - | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - | sed '$ s: \\$::' > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - cat < "$tmpdepfile" >> "$depfile" - sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvisualcpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - IFS=" " - for arg - do - case "$arg" in - -o) - shift - ;; - $object) - shift - ;; - "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") - set fnord "$@" - shift - shift - ;; - *) - set fnord "$@" "$arg" - shift - shift - ;; - esac - done - "$@" -E 2>/dev/null | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" - echo "$tab" >> "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvcmsys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -none) - exec "$@" - ;; - -*) - echo "Unknown depmode $depmode" 1>&2 - exit 1 - ;; -esac - -exit 0 - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/lame/libmp3lame/encoder.c b/lib-src/lame/libmp3lame/encoder.c deleted file mode 100644 index 48f46c7bf..000000000 --- a/lib-src/lame/libmp3lame/encoder.c +++ /dev/null @@ -1,574 +0,0 @@ -/* - * LAME MP3 encoding engine - * - * Copyright (c) 1999 Mark Taylor - * Copyright (c) 2000-2002 Takehiro Tominaga - * Copyright (c) 2000-2011 Robert Hegemann - * Copyright (c) 2001 Gabriel Bouvigne - * Copyright (c) 2001 John Dahlstrom - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: encoder.c,v 1.114 2017/08/26 10:54:57 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -#include -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "lame_global_flags.h" -#include "newmdct.h" -#include "psymodel.h" -#include "lame-analysis.h" -#include "bitstream.h" -#include "VbrTag.h" -#include "quantize.h" -#include "quantize_pvt.h" - - - -/* - * auto-adjust of ATH, useful for low volume - * Gabriel Bouvigne 3 feb 2001 - * - * modifies some values in - * gfp->internal_flags->ATH - * (gfc->ATH) - */ -static void -adjust_ATH(lame_internal_flags const *const gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - FLOAT gr2_max, max_pow; - - if (gfc->ATH->use_adjust == 0) { - gfc->ATH->adjust_factor = 1.0; /* no adjustment */ - return; - } - - /* jd - 2001 mar 12, 27, jun 30 */ - /* loudness based on equal loudness curve; */ - /* use granule with maximum combined loudness */ - max_pow = gfc->ov_psy.loudness_sq[0][0]; - gr2_max = gfc->ov_psy.loudness_sq[1][0]; - if (cfg->channels_out == 2) { - max_pow += gfc->ov_psy.loudness_sq[0][1]; - gr2_max += gfc->ov_psy.loudness_sq[1][1]; - } - else { - max_pow += max_pow; - gr2_max += gr2_max; - } - if (cfg->mode_gr == 2) { - max_pow = Max(max_pow, gr2_max); - } - max_pow *= 0.5; /* max_pow approaches 1.0 for full band noise */ - - /* jd - 2001 mar 31, jun 30 */ - /* user tuning of ATH adjustment region */ - max_pow *= gfc->ATH->aa_sensitivity_p; - - /* adjust ATH depending on range of maximum value - */ - - /* jd - 2001 feb27, mar12,20, jun30, jul22 */ - /* continuous curves based on approximation */ - /* to GB's original values. */ - /* For an increase in approximate loudness, */ - /* set ATH adjust to adjust_limit immediately */ - /* after a delay of one frame. */ - /* For a loudness decrease, reduce ATH adjust */ - /* towards adjust_limit gradually. */ - /* max_pow is a loudness squared or a power. */ - if (max_pow > 0.03125) { /* ((1 - 0.000625)/ 31.98) from curve below */ - if (gfc->ATH->adjust_factor >= 1.0) { - gfc->ATH->adjust_factor = 1.0; - } - else { - /* preceding frame has lower ATH adjust; */ - /* ascend only to the preceding adjust_limit */ - /* in case there is leading low volume */ - if (gfc->ATH->adjust_factor < gfc->ATH->adjust_limit) { - gfc->ATH->adjust_factor = gfc->ATH->adjust_limit; - } - } - gfc->ATH->adjust_limit = 1.0; - } - else { /* adjustment curve */ - /* about 32 dB maximum adjust (0.000625) */ - FLOAT const adj_lim_new = 31.98 * max_pow + 0.000625; - if (gfc->ATH->adjust_factor >= adj_lim_new) { /* descend gradually */ - gfc->ATH->adjust_factor *= adj_lim_new * 0.075 + 0.925; - if (gfc->ATH->adjust_factor < adj_lim_new) { /* stop descent */ - gfc->ATH->adjust_factor = adj_lim_new; - } - } - else { /* ascend */ - if (gfc->ATH->adjust_limit >= adj_lim_new) { - gfc->ATH->adjust_factor = adj_lim_new; - } - else { /* preceding frame has lower ATH adjust; */ - /* ascend only to the preceding adjust_limit */ - if (gfc->ATH->adjust_factor < gfc->ATH->adjust_limit) { - gfc->ATH->adjust_factor = gfc->ATH->adjust_limit; - } - } - } - gfc->ATH->adjust_limit = adj_lim_new; - } -} - -/*********************************************************************** - * - * some simple statistics - * - * bitrate index 0: free bitrate -> not allowed in VBR mode - * : bitrates, kbps depending on MPEG version - * bitrate index 15: forbidden - * - * mode_ext: - * 0: LR - * 1: LR-i - * 2: MS - * 3: MS-i - * - ***********************************************************************/ - -static void -updateStats(lame_internal_flags * const gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *eov = &gfc->ov_enc; - int gr, ch; - assert(0 <= eov->bitrate_index && eov->bitrate_index < 16); - assert(0 <= eov->mode_ext && eov->mode_ext < 4); - - /* count bitrate indices */ - eov->bitrate_channelmode_hist[eov->bitrate_index][4]++; - eov->bitrate_channelmode_hist[15][4]++; - - /* count 'em for every mode extension in case of 2 channel encoding */ - if (cfg->channels_out == 2) { - eov->bitrate_channelmode_hist[eov->bitrate_index][eov->mode_ext]++; - eov->bitrate_channelmode_hist[15][eov->mode_ext]++; - } - for (gr = 0; gr < cfg->mode_gr; ++gr) { - for (ch = 0; ch < cfg->channels_out; ++ch) { - int bt = gfc->l3_side.tt[gr][ch].block_type; - if (gfc->l3_side.tt[gr][ch].mixed_block_flag) - bt = 4; - eov->bitrate_blocktype_hist[eov->bitrate_index][bt]++; - eov->bitrate_blocktype_hist[eov->bitrate_index][5]++; - eov->bitrate_blocktype_hist[15][bt]++; - eov->bitrate_blocktype_hist[15][5]++; - } - } -} - - - - -static void -lame_encode_frame_init(lame_internal_flags * gfc, const sample_t *const inbuf[2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - - int ch, gr; - - if (gfc->lame_encode_frame_init == 0) { - sample_t primebuff0[286 + 1152 + 576]; - sample_t primebuff1[286 + 1152 + 576]; - int const framesize = 576 * cfg->mode_gr; - /* prime the MDCT/polyphase filterbank with a short block */ - int i, j; - gfc->lame_encode_frame_init = 1; - memset(primebuff0, 0, sizeof(primebuff0)); - memset(primebuff1, 0, sizeof(primebuff1)); - for (i = 0, j = 0; i < 286 + 576 * (1 + cfg->mode_gr); ++i) { - if (i < framesize) { - primebuff0[i] = 0; - if (cfg->channels_out == 2) - primebuff1[i] = 0; - } - else { - primebuff0[i] = inbuf[0][j]; - if (cfg->channels_out == 2) - primebuff1[i] = inbuf[1][j]; - ++j; - } - } - /* polyphase filtering / mdct */ - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gfc->l3_side.tt[gr][ch].block_type = SHORT_TYPE; - } - } - mdct_sub48(gfc, primebuff0, primebuff1); - - /* check FFT will not use a negative starting offset */ -#if 576 < FFTOFFSET -# error FFTOFFSET greater than 576: FFT uses a negative offset -#endif - /* check if we have enough data for FFT */ - assert(gfc->sv_enc.mf_size >= (BLKSIZE + framesize - FFTOFFSET)); - /* check if we have enough data for polyphase filterbank */ - assert(gfc->sv_enc.mf_size >= (512 + framesize - 32)); - } - -} - - - - - - - -/************************************************************************ -* -* encodeframe() Layer 3 -* -* encode a single frame -* -************************************************************************ -lame_encode_frame() - - - gr 0 gr 1 -inbuf: |--------------|--------------|--------------| - - -Polyphase (18 windows, each shifted 32) -gr 0: -window1 <----512----> -window18 <----512----> - -gr 1: -window1 <----512----> -window18 <----512----> - - - -MDCT output: |--------------|--------------|--------------| - -FFT's <---------1024----------> - <---------1024--------> - - - - inbuf = buffer of PCM data size=MP3 framesize - encoder acts on inbuf[ch][0], but output is delayed by MDCTDELAY - so the MDCT coefficints are from inbuf[ch][-MDCTDELAY] - - psy-model FFT has a 1 granule delay, so we feed it data for the - next granule. - FFT is centered over granule: 224+576+224 - So FFT starts at: 576-224-MDCTDELAY - - MPEG2: FFT ends at: BLKSIZE+576-224-MDCTDELAY (1328) - MPEG1: FFT ends at: BLKSIZE+2*576-224-MDCTDELAY (1904) - - MPEG2: polyphase first window: [0..511] - 18th window: [544..1055] (1056) - MPEG1: 36th window: [1120..1631] (1632) - data needed: 512+framesize-32 - - A close look newmdct.c shows that the polyphase filterbank - only uses data from [0..510] for each window. Perhaps because the window - used by the filterbank is zero for the last point, so Takehiro's - code doesn't bother to compute with it. - - FFT starts at 576-224-MDCTDELAY (304) = 576-FFTOFFSET - -*/ - -typedef FLOAT chgrdata[2][2]; - - -int -lame_encode_mp3_frame( /* Output */ - lame_internal_flags * gfc, /* Context */ - sample_t const *inbuf_l, /* Input */ - sample_t const *inbuf_r, /* Input */ - unsigned char *mp3buf, /* Output */ - int mp3buf_size) -{ /* Output */ - SessionConfig_t const *const cfg = &gfc->cfg; - int mp3count; - III_psy_ratio masking_LR[2][2]; /*LR masking & energy */ - III_psy_ratio masking_MS[2][2]; /*MS masking & energy */ - const III_psy_ratio (*masking)[2]; /*pointer to selected maskings */ - const sample_t *inbuf[2]; - - FLOAT tot_ener[2][4]; - FLOAT ms_ener_ratio[2] = { .5, .5 }; - FLOAT pe[2][2] = { {0., 0.}, {0., 0.} }, pe_MS[2][2] = { { - 0., 0.}, { - 0., 0.}}; - FLOAT (*pe_use)[2]; - - int ch, gr; - - inbuf[0] = inbuf_l; - inbuf[1] = inbuf_r; - - if (gfc->lame_encode_frame_init == 0) { - /*first run? */ - lame_encode_frame_init(gfc, inbuf); - - } - - - /********************** padding *****************************/ - /* padding method as described in - * "MPEG-Layer3 / Bitstream Syntax and Decoding" - * by Martin Sieler, Ralph Sperschneider - * - * note: there is no padding for the very first frame - * - * Robert Hegemann 2000-06-22 - */ - gfc->ov_enc.padding = FALSE; - if ((gfc->sv_enc.slot_lag -= gfc->sv_enc.frac_SpF) < 0) { - gfc->sv_enc.slot_lag += cfg->samplerate_out; - gfc->ov_enc.padding = TRUE; - } - - - - /**************************************** - * Stage 1: psychoacoustic model * - ****************************************/ - - { - /* psychoacoustic model - * psy model has a 1 granule (576) delay that we must compensate for - * (mt 6/99). - */ - int ret; - const sample_t *bufp[2] = {0, 0}; /* address of beginning of left & right granule */ - int blocktype[2]; - - for (gr = 0; gr < cfg->mode_gr; gr++) { - - for (ch = 0; ch < cfg->channels_out; ch++) { - bufp[ch] = &inbuf[ch][576 + gr * 576 - FFTOFFSET]; - } - ret = L3psycho_anal_vbr(gfc, bufp, gr, - masking_LR, masking_MS, - pe[gr], pe_MS[gr], tot_ener[gr], blocktype); - if (ret != 0) - return -4; - - if (cfg->mode == JOINT_STEREO) { - ms_ener_ratio[gr] = tot_ener[gr][2] + tot_ener[gr][3]; - if (ms_ener_ratio[gr] > 0) - ms_ener_ratio[gr] = tot_ener[gr][3] / ms_ener_ratio[gr]; - } - - /* block type flags */ - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info *const cod_info = &gfc->l3_side.tt[gr][ch]; - cod_info->block_type = blocktype[ch]; - cod_info->mixed_block_flag = 0; - } - } - } - - - /* auto-adjust of ATH, useful for low volume */ - adjust_ATH(gfc); - - - /**************************************** - * Stage 2: MDCT * - ****************************************/ - - /* polyphase filtering / mdct */ - mdct_sub48(gfc, inbuf[0], inbuf[1]); - - - /**************************************** - * Stage 3: MS/LR decision * - ****************************************/ - - /* Here will be selected MS or LR coding of the 2 stereo channels */ - gfc->ov_enc.mode_ext = MPG_MD_LR_LR; - - if (cfg->force_ms) { - gfc->ov_enc.mode_ext = MPG_MD_MS_LR; - } - else if (cfg->mode == JOINT_STEREO) { - /* ms_ratio = is scaled, for historical reasons, to look like - a ratio of side_channel / total. - 0 = signal is 100% mono - .5 = L & R uncorrelated - */ - - /* [0] and [1] are the results for the two granules in MPEG-1, - * in MPEG-2 it's only a faked averaging of the same value - * _prev is the value of the last granule of the previous frame - * _next is the value of the first granule of the next frame - */ - - FLOAT sum_pe_MS = 0; - FLOAT sum_pe_LR = 0; - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - sum_pe_MS += pe_MS[gr][ch]; - sum_pe_LR += pe[gr][ch]; - } - } - - /* based on PE: M/S coding would not use much more bits than L/R */ - if (sum_pe_MS <= 1.00 * sum_pe_LR) { - - gr_info const *const gi0 = &gfc->l3_side.tt[0][0]; - gr_info const *const gi1 = &gfc->l3_side.tt[cfg->mode_gr - 1][0]; - - if (gi0[0].block_type == gi0[1].block_type && gi1[0].block_type == gi1[1].block_type) { - - gfc->ov_enc.mode_ext = MPG_MD_MS_LR; - } - } - } - - /* bit and noise allocation */ - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - masking = (const III_psy_ratio (*)[2])masking_MS; /* use MS masking */ - pe_use = pe_MS; - } - else { - masking = (const III_psy_ratio (*)[2])masking_LR; /* use LR masking */ - pe_use = pe; - } - - - /* copy data for MP3 frame analyzer */ - if (cfg->analysis && gfc->pinfo != NULL) { - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gfc->pinfo->ms_ratio[gr] = 0; - gfc->pinfo->ms_ener_ratio[gr] = ms_ener_ratio[gr]; - gfc->pinfo->blocktype[gr][ch] = gfc->l3_side.tt[gr][ch].block_type; - gfc->pinfo->pe[gr][ch] = pe_use[gr][ch]; - memcpy(gfc->pinfo->xr[gr][ch], &gfc->l3_side.tt[gr][ch].xr[0], sizeof(FLOAT) * 576); - /* in psymodel, LR and MS data was stored in pinfo. - switch to MS data: */ - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - gfc->pinfo->ers[gr][ch] = gfc->pinfo->ers[gr][ch + 2]; - memcpy(gfc->pinfo->energy[gr][ch], gfc->pinfo->energy[gr][ch + 2], - sizeof(gfc->pinfo->energy[gr][ch])); - } - } - } - } - - - /**************************************** - * Stage 4: quantization loop * - ****************************************/ - - if (cfg->vbr == vbr_off || cfg->vbr == vbr_abr) { - static FLOAT const fircoef[9] = { - -0.0207887 * 5, -0.0378413 * 5, -0.0432472 * 5, -0.031183 * 5, - 7.79609e-18 * 5, 0.0467745 * 5, 0.10091 * 5, 0.151365 * 5, - 0.187098 * 5 - }; - - int i; - FLOAT f; - - for (i = 0; i < 18; i++) - gfc->sv_enc.pefirbuf[i] = gfc->sv_enc.pefirbuf[i + 1]; - - f = 0.0; - for (gr = 0; gr < cfg->mode_gr; gr++) - for (ch = 0; ch < cfg->channels_out; ch++) - f += pe_use[gr][ch]; - gfc->sv_enc.pefirbuf[18] = f; - - f = gfc->sv_enc.pefirbuf[9]; - for (i = 0; i < 9; i++) - f += (gfc->sv_enc.pefirbuf[i] + gfc->sv_enc.pefirbuf[18 - i]) * fircoef[i]; - - f = (670 * 5 * cfg->mode_gr * cfg->channels_out) / f; - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - pe_use[gr][ch] *= f; - } - } - } - switch (cfg->vbr) - { - default: - case vbr_off: - CBR_iteration_loop(gfc, (const FLOAT (*)[2])pe_use, ms_ener_ratio, masking); - break; - case vbr_abr: - ABR_iteration_loop(gfc, (const FLOAT (*)[2])pe_use, ms_ener_ratio, masking); - break; - case vbr_rh: - VBR_old_iteration_loop(gfc, (const FLOAT (*)[2])pe_use, ms_ener_ratio, masking); - break; - case vbr_mt: - case vbr_mtrh: - VBR_new_iteration_loop(gfc, (const FLOAT (*)[2])pe_use, ms_ener_ratio, masking); - break; - } - - - /**************************************** - * Stage 5: bitstream formatting * - ****************************************/ - - - /* write the frame to the bitstream */ - (void) format_bitstream(gfc); - - /* copy mp3 bit buffer into array */ - mp3count = copy_buffer(gfc, mp3buf, mp3buf_size, 1); - - - if (cfg->write_lame_tag) { - AddVbrFrame(gfc); - } - - if (cfg->analysis && gfc->pinfo != NULL) { - int framesize = 576 * cfg->mode_gr; - for (ch = 0; ch < cfg->channels_out; ch++) { - int j; - for (j = 0; j < FFTOFFSET; j++) - gfc->pinfo->pcmdata[ch][j] = gfc->pinfo->pcmdata[ch][j + framesize]; - for (j = FFTOFFSET; j < 1600; j++) { - gfc->pinfo->pcmdata[ch][j] = inbuf[ch][j - FFTOFFSET]; - } - } - gfc->sv_qnt.masking_lower = 1.0; - - set_frame_pinfo(gfc, masking); - } - - ++gfc->ov_enc.frame_number; - - updateStats(gfc); - - return mp3count; -} diff --git a/lib-src/lame/libmp3lame/encoder.h b/lib-src/lame/libmp3lame/encoder.h deleted file mode 100644 index b06a7c644..000000000 --- a/lib-src/lame/libmp3lame/encoder.h +++ /dev/null @@ -1,156 +0,0 @@ -/* - * encoder.h include file - * - * Copyright (c) 2000 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - - -#ifndef LAME_ENCODER_H -#define LAME_ENCODER_H - -/*********************************************************************** -* -* encoder and decoder delays -* -***********************************************************************/ - -/* - * layer III enc->dec delay: 1056 (1057?) (observed) - * layer II enc->dec delay: 480 (481?) (observed) - * - * polyphase 256-16 (dec or enc) = 240 - * mdct 256+32 (9*32) (dec or enc) = 288 - * total: 512+16 - * - * My guess is that delay of polyphase filterbank is actualy 240.5 - * (there are technical reasons for this, see postings in mp3encoder). - * So total Encode+Decode delay = ENCDELAY + 528 + 1 - */ - -/* - * ENCDELAY The encoder delay. - * - * Minimum allowed is MDCTDELAY (see below) - * - * The first 96 samples will be attenuated, so using a value less than 96 - * will result in corrupt data for the first 96-ENCDELAY samples. - * - * suggested: 576 - * set to 1160 to sync with FhG. - */ - -#define ENCDELAY 576 - - - -/* - * make sure there is at least one complete frame after the - * last frame containing real data - * - * Using a value of 288 would be sufficient for a - * a very sophisticated decoder that can decode granule-by-granule instead - * of frame by frame. But lets not assume this, and assume the decoder - * will not decode frame N unless it also has data for frame N+1 - * - */ -/*#define POSTDELAY 288*/ -#define POSTDELAY 1152 - - - -/* - * delay of the MDCT used in mdct.c - * original ISO routines had a delay of 528! - * Takehiro's routines: - */ - -#define MDCTDELAY 48 -#define FFTOFFSET (224+MDCTDELAY) - -/* - * Most decoders, including the one we use, have a delay of 528 samples. - */ - -#define DECDELAY 528 - - -/* number of subbands */ -#define SBLIMIT 32 - -/* parition bands bands */ -#define CBANDS 64 - -/* number of critical bands/scale factor bands where masking is computed*/ -#define SBPSY_l 21 -#define SBPSY_s 12 - -/* total number of scalefactor bands encoded */ -#define SBMAX_l 22 -#define SBMAX_s 13 -#define PSFB21 6 -#define PSFB12 6 - - - -/* FFT sizes */ -#define BLKSIZE 1024 -#define HBLKSIZE (BLKSIZE/2 + 1) -#define BLKSIZE_s 256 -#define HBLKSIZE_s (BLKSIZE_s/2 + 1) - - -/* #define switch_pe 1800 */ -#define NORM_TYPE 0 -#define START_TYPE 1 -#define SHORT_TYPE 2 -#define STOP_TYPE 3 - -/* - * Mode Extention: - * When we are in stereo mode, there are 4 possible methods to store these - * two channels. The stereo modes -m? are using a subset of them. - * - * -ms: MPG_MD_LR_LR - * -mj: MPG_MD_LR_LR and MPG_MD_MS_LR - * -mf: MPG_MD_MS_LR - * -mi: all - */ -#if 0 -#define MPG_MD_LR_LR 0 -#define MPG_MD_LR_I 1 -#define MPG_MD_MS_LR 2 -#define MPG_MD_MS_I 3 -#endif -enum MPEGChannelMode -{ MPG_MD_LR_LR = 0 -, MPG_MD_LR_I = 1 -, MPG_MD_MS_LR = 2 -, MPG_MD_MS_I = 3 -}; - -#ifndef lame_internal_flags_defined -#define lame_internal_flags_defined -struct lame_internal_flags; -typedef struct lame_internal_flags lame_internal_flags; -#endif - -int lame_encode_mp3_frame(lame_internal_flags * gfc, - sample_t const *inbuf_l, - sample_t const *inbuf_r, unsigned char *mp3buf, int mp3buf_size); - -#endif /* LAME_ENCODER_H */ diff --git a/lib-src/lame/libmp3lame/fft.c b/lib-src/lame/libmp3lame/fft.c deleted file mode 100644 index 4eea1adb1..000000000 --- a/lib-src/lame/libmp3lame/fft.c +++ /dev/null @@ -1,339 +0,0 @@ -/* -** FFT and FHT routines -** Copyright 1988, 1993; Ron Mayer -** Copyright (c) 1999-2000 Takehiro Tominaga -** -** fht(fz,n); -** Does a hartley transform of "n" points in the array "fz". -** -** NOTE: This routine uses at least 2 patented algorithms, and may be -** under the restrictions of a bunch of different organizations. -** Although I wrote it completely myself; it is kind of a derivative -** of a routine I once authored and released under the GPL, so it -** may fall under the free software foundation's restrictions; -** it was worked on as a Stanford Univ project, so they claim -** some rights to it; it was further optimized at work here, so -** I think this company claims parts of it. The patents are -** held by R. Bracewell (the FHT algorithm) and O. Buneman (the -** trig generator), both at Stanford Univ. -** If it were up to me, I'd say go do whatever you want with it; -** but it would be polite to give credit to the following people -** if you use this anywhere: -** Euler - probable inventor of the fourier transform. -** Gauss - probable inventor of the FFT. -** Hartley - probable inventor of the hartley transform. -** Buneman - for a really cool trig generator -** Mayer(me) - for authoring this particular version and -** including all the optimizations in one package. -** Thanks, -** Ron Mayer; mayer@acuson.com -** and added some optimization by -** Mather - idea of using lookup table -** Takehiro - some dirty hack for speed up -*/ - -/* $Id: fft.c,v 1.39 2017/09/06 15:07:29 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "fft.h" - -#include "vector/lame_intrin.h" - - - -#define TRI_SIZE (5-1) /* 1024 = 4**5 */ - -/* fft.c */ - -static const FLOAT costab[TRI_SIZE * 2] = { - 9.238795325112867e-01, 3.826834323650898e-01, - 9.951847266721969e-01, 9.801714032956060e-02, - 9.996988186962042e-01, 2.454122852291229e-02, - 9.999811752826011e-01, 6.135884649154475e-03 -}; - -static void -fht(FLOAT * fz, int n) -{ - const FLOAT *tri = costab; - int k4; - FLOAT *fi, *gi; - FLOAT const *fn; - - n <<= 1; /* to get BLKSIZE, because of 3DNow! ASM routine */ - fn = fz + n; - k4 = 4; - do { - FLOAT s1, c1; - int i, k1, k2, k3, kx; - kx = k4 >> 1; - k1 = k4; - k2 = k4 << 1; - k3 = k2 + k1; - k4 = k2 << 1; - fi = fz; - gi = fi + kx; - do { - FLOAT f0, f1, f2, f3; - f1 = fi[0] - fi[k1]; - f0 = fi[0] + fi[k1]; - f3 = fi[k2] - fi[k3]; - f2 = fi[k2] + fi[k3]; - fi[k2] = f0 - f2; - fi[0] = f0 + f2; - fi[k3] = f1 - f3; - fi[k1] = f1 + f3; - f1 = gi[0] - gi[k1]; - f0 = gi[0] + gi[k1]; - f3 = SQRT2 * gi[k3]; - f2 = SQRT2 * gi[k2]; - gi[k2] = f0 - f2; - gi[0] = f0 + f2; - gi[k3] = f1 - f3; - gi[k1] = f1 + f3; - gi += k4; - fi += k4; - } while (fi < fn); - c1 = tri[0]; - s1 = tri[1]; - for (i = 1; i < kx; i++) { - FLOAT c2, s2; - c2 = 1 - (2 * s1) * s1; - s2 = (2 * s1) * c1; - fi = fz + i; - gi = fz + k1 - i; - do { - FLOAT a, b, g0, f0, f1, g1, f2, g2, f3, g3; - b = s2 * fi[k1] - c2 * gi[k1]; - a = c2 * fi[k1] + s2 * gi[k1]; - f1 = fi[0] - a; - f0 = fi[0] + a; - g1 = gi[0] - b; - g0 = gi[0] + b; - b = s2 * fi[k3] - c2 * gi[k3]; - a = c2 * fi[k3] + s2 * gi[k3]; - f3 = fi[k2] - a; - f2 = fi[k2] + a; - g3 = gi[k2] - b; - g2 = gi[k2] + b; - b = s1 * f2 - c1 * g3; - a = c1 * f2 + s1 * g3; - fi[k2] = f0 - a; - fi[0] = f0 + a; - gi[k3] = g1 - b; - gi[k1] = g1 + b; - b = c1 * g2 - s1 * f3; - a = s1 * g2 + c1 * f3; - gi[k2] = g0 - a; - gi[0] = g0 + a; - fi[k3] = f1 - b; - fi[k1] = f1 + b; - gi += k4; - fi += k4; - } while (fi < fn); - c2 = c1; - c1 = c2 * tri[0] - s1 * tri[1]; - s1 = c2 * tri[1] + s1 * tri[0]; - } - tri += 2; - } while (k4 < n); -} - - -static const unsigned char rv_tbl[] = { - 0x00, 0x80, 0x40, 0xc0, 0x20, 0xa0, 0x60, 0xe0, - 0x10, 0x90, 0x50, 0xd0, 0x30, 0xb0, 0x70, 0xf0, - 0x08, 0x88, 0x48, 0xc8, 0x28, 0xa8, 0x68, 0xe8, - 0x18, 0x98, 0x58, 0xd8, 0x38, 0xb8, 0x78, 0xf8, - 0x04, 0x84, 0x44, 0xc4, 0x24, 0xa4, 0x64, 0xe4, - 0x14, 0x94, 0x54, 0xd4, 0x34, 0xb4, 0x74, 0xf4, - 0x0c, 0x8c, 0x4c, 0xcc, 0x2c, 0xac, 0x6c, 0xec, - 0x1c, 0x9c, 0x5c, 0xdc, 0x3c, 0xbc, 0x7c, 0xfc, - 0x02, 0x82, 0x42, 0xc2, 0x22, 0xa2, 0x62, 0xe2, - 0x12, 0x92, 0x52, 0xd2, 0x32, 0xb2, 0x72, 0xf2, - 0x0a, 0x8a, 0x4a, 0xca, 0x2a, 0xaa, 0x6a, 0xea, - 0x1a, 0x9a, 0x5a, 0xda, 0x3a, 0xba, 0x7a, 0xfa, - 0x06, 0x86, 0x46, 0xc6, 0x26, 0xa6, 0x66, 0xe6, - 0x16, 0x96, 0x56, 0xd6, 0x36, 0xb6, 0x76, 0xf6, - 0x0e, 0x8e, 0x4e, 0xce, 0x2e, 0xae, 0x6e, 0xee, - 0x1e, 0x9e, 0x5e, 0xde, 0x3e, 0xbe, 0x7e, 0xfe -}; - -#define ch01(index) (buffer[chn][index]) - -#define ml00(f) (window[i ] * f(i)) -#define ml10(f) (window[i + 0x200] * f(i + 0x200)) -#define ml20(f) (window[i + 0x100] * f(i + 0x100)) -#define ml30(f) (window[i + 0x300] * f(i + 0x300)) - -#define ml01(f) (window[i + 0x001] * f(i + 0x001)) -#define ml11(f) (window[i + 0x201] * f(i + 0x201)) -#define ml21(f) (window[i + 0x101] * f(i + 0x101)) -#define ml31(f) (window[i + 0x301] * f(i + 0x301)) - -#define ms00(f) (window_s[i ] * f(i + k)) -#define ms10(f) (window_s[0x7f - i] * f(i + k + 0x80)) -#define ms20(f) (window_s[i + 0x40] * f(i + k + 0x40)) -#define ms30(f) (window_s[0x3f - i] * f(i + k + 0xc0)) - -#define ms01(f) (window_s[i + 0x01] * f(i + k + 0x01)) -#define ms11(f) (window_s[0x7e - i] * f(i + k + 0x81)) -#define ms21(f) (window_s[i + 0x41] * f(i + k + 0x41)) -#define ms31(f) (window_s[0x3e - i] * f(i + k + 0xc1)) - -void -fft_short(lame_internal_flags const *const gfc, - FLOAT x_real[3][BLKSIZE_s], int chn, const sample_t *const buffer[2]) -{ - int i; - int j; - int b; - -#define window_s gfc->cd_psy->window_s -#define window gfc->cd_psy->window - - for (b = 0; b < 3; b++) { - FLOAT *x = &x_real[b][BLKSIZE_s / 2]; - short const k = (576 / 3) * (b + 1); - j = BLKSIZE_s / 8 - 1; - do { - FLOAT f0, f1, f2, f3, w; - - i = rv_tbl[j << 2]; - - f0 = ms00(ch01); - w = ms10(ch01); - f1 = f0 - w; - f0 = f0 + w; - f2 = ms20(ch01); - w = ms30(ch01); - f3 = f2 - w; - f2 = f2 + w; - - x -= 4; - x[0] = f0 + f2; - x[2] = f0 - f2; - x[1] = f1 + f3; - x[3] = f1 - f3; - - f0 = ms01(ch01); - w = ms11(ch01); - f1 = f0 - w; - f0 = f0 + w; - f2 = ms21(ch01); - w = ms31(ch01); - f3 = f2 - w; - f2 = f2 + w; - - x[BLKSIZE_s / 2 + 0] = f0 + f2; - x[BLKSIZE_s / 2 + 2] = f0 - f2; - x[BLKSIZE_s / 2 + 1] = f1 + f3; - x[BLKSIZE_s / 2 + 3] = f1 - f3; - } while (--j >= 0); - -#undef window -#undef window_s - - gfc->fft_fht(x, BLKSIZE_s / 2); - /* BLKSIZE_s/2 because of 3DNow! ASM routine */ - } -} - -void -fft_long(lame_internal_flags const *const gfc, - FLOAT x[BLKSIZE], int chn, const sample_t *const buffer[2]) -{ - int i; - int jj = BLKSIZE / 8 - 1; - x += BLKSIZE / 2; - -#define window_s gfc->cd_psy->window_s -#define window gfc->cd_psy->window - - do { - FLOAT f0, f1, f2, f3, w; - - i = rv_tbl[jj]; - f0 = ml00(ch01); - w = ml10(ch01); - f1 = f0 - w; - f0 = f0 + w; - f2 = ml20(ch01); - w = ml30(ch01); - f3 = f2 - w; - f2 = f2 + w; - - x -= 4; - x[0] = f0 + f2; - x[2] = f0 - f2; - x[1] = f1 + f3; - x[3] = f1 - f3; - - f0 = ml01(ch01); - w = ml11(ch01); - f1 = f0 - w; - f0 = f0 + w; - f2 = ml21(ch01); - w = ml31(ch01); - f3 = f2 - w; - f2 = f2 + w; - - x[BLKSIZE / 2 + 0] = f0 + f2; - x[BLKSIZE / 2 + 2] = f0 - f2; - x[BLKSIZE / 2 + 1] = f1 + f3; - x[BLKSIZE / 2 + 3] = f1 - f3; - } while (--jj >= 0); - -#undef window -#undef window_s - - gfc->fft_fht(x, BLKSIZE / 2); - /* BLKSIZE/2 because of 3DNow! ASM routine */ -} - -#ifdef HAVE_NASM -extern void fht_3DN(FLOAT * fz, int n); -extern void fht_SSE(FLOAT * fz, int n); -#endif - -void -init_fft(lame_internal_flags * const gfc) -{ - int i; - - /* The type of window used here will make no real difference, but */ - /* in the interest of merging nspsytune stuff - switch to blackman window */ - for (i = 0; i < BLKSIZE; i++) - /* blackman window */ - gfc->cd_psy->window[i] = 0.42 - 0.5 * cos(2 * PI * (i + .5) / BLKSIZE) + - 0.08 * cos(4 * PI * (i + .5) / BLKSIZE); - - for (i = 0; i < BLKSIZE_s / 2; i++) - gfc->cd_psy->window_s[i] = 0.5 * (1.0 - cos(2.0 * PI * (i + 0.5) / BLKSIZE_s)); - - gfc->fft_fht = fht; -#ifdef HAVE_NASM - if (gfc->CPU_features.AMD_3DNow) { - gfc->fft_fht = fht_3DN; - } - else if (gfc->CPU_features.SSE) { - gfc->fft_fht = fht_SSE; - } - else { - gfc->fft_fht = fht; - } -#else -#ifdef HAVE_XMMINTRIN_H -#ifdef MIN_ARCH_SSE - gfc->fft_fht = fht_SSE2; -#endif -#endif -#endif -} diff --git a/lib-src/lame/libmp3lame/fft.h b/lib-src/lame/libmp3lame/fft.h deleted file mode 100644 index 258df8870..000000000 --- a/lib-src/lame/libmp3lame/fft.h +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Fast Fourier Transform include file - * - * Copyright (c) 2000 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_FFT_H -#define LAME_FFT_H - -void fft_long(lame_internal_flags const *const gfc, FLOAT x_real[BLKSIZE], - int chn, const sample_t *const data[2]); - -void fft_short(lame_internal_flags const *const gfc, FLOAT x_real[3][BLKSIZE_s], - int chn, const sample_t *const data[2]); - -void init_fft(lame_internal_flags * const gfc); - -#endif - -/* End of fft.h */ diff --git a/lib-src/lame/libmp3lame/gain_analysis.c b/lib-src/lame/libmp3lame/gain_analysis.c deleted file mode 100644 index c94db780f..000000000 --- a/lib-src/lame/libmp3lame/gain_analysis.c +++ /dev/null @@ -1,476 +0,0 @@ -/* - * ReplayGainAnalysis - analyzes input samples and give the recommended dB change - * Copyright (C) 2001 David Robinson and Glen Sawyer - * Improvements and optimizations added by Frank Klemm, and by Marcel Muller - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * concept and filter values by David Robinson (David@Robinson.org) - * -- blame him if you think the idea is flawed - * original coding by Glen Sawyer (mp3gain@hotmail.com) - * -- blame him if you think this runs too slowly, or the coding is otherwise flawed - * - * lots of code improvements by Frank Klemm ( http://www.uni-jena.de/~pfk/mpp/ ) - * -- credit him for all the _good_ programming ;) - * - * - * For an explanation of the concepts and the basic algorithms involved, go to: - * http://www.replaygain.org/ - */ - -/* - * Here's the deal. Call - * - * InitGainAnalysis ( long samplefreq ); - * - * to initialize everything. Call - * - * AnalyzeSamples ( const Float_t* left_samples, - * const Float_t* right_samples, - * size_t num_samples, - * int num_channels ); - * - * as many times as you want, with as many or as few samples as you want. - * If mono, pass the sample buffer in through left_samples, leave - * right_samples NULL, and make sure num_channels = 1. - * - * GetTitleGain() - * - * will return the recommended dB level change for all samples analyzed - * SINCE THE LAST TIME you called GetTitleGain() OR InitGainAnalysis(). - * - * GetAlbumGain() - * - * will return the recommended dB level change for all samples analyzed - * since InitGainAnalysis() was called and finalized with GetTitleGain(). - * - * Pseudo-code to process an album: - * - * Float_t l_samples [4096]; - * Float_t r_samples [4096]; - * size_t num_samples; - * unsigned int num_songs; - * unsigned int i; - * - * InitGainAnalysis ( 44100 ); - * for ( i = 1; i <= num_songs; i++ ) { - * while ( ( num_samples = getSongSamples ( song[i], left_samples, right_samples ) ) > 0 ) - * AnalyzeSamples ( left_samples, right_samples, num_samples, 2 ); - * fprintf ("Recommended dB change for song %2d: %+6.2f dB\n", i, GetTitleGain() ); - * } - * fprintf ("Recommended dB change for whole album: %+6.2f dB\n", GetAlbumGain() ); - */ - -/* - * So here's the main source of potential code confusion: - * - * The filters applied to the incoming samples are IIR filters, - * meaning they rely on up to number of previous samples - * AND up to number of previous filtered samples. - * - * I set up the AnalyzeSamples routine to minimize memory usage and interface - * complexity. The speed isn't compromised too much (I don't think), but the - * internal complexity is higher than it should be for such a relatively - * simple routine. - * - * Optimization/clarity suggestions are welcome. - */ - -#ifdef HAVE_CONFIG_H -#include -#endif - -#include -#include -#include - -#include "lame.h" -#include "machine.h" -#include "gain_analysis.h" - -/* for each filter: */ -/* [0] 48 kHz, [1] 44.1 kHz, [2] 32 kHz, [3] 24 kHz, [4] 22050 Hz, [5] 16 kHz, [6] 12 kHz, [7] is 11025 Hz, [8] 8 kHz */ - -#ifdef WIN32 -#pragma warning ( disable : 4305 ) -#endif - - -/*lint -save -e736 loss of precision */ -static const Float_t ABYule[9][multiple_of(4, 2 * YULE_ORDER + 1)] = { - /* 20 18 16 14 12 10 8 6 4 2 0 19 17 15 13 11 9 7 5 3 1 */ - { 0.00288463683916, 0.00012025322027, 0.00306428023191, 0.00594298065125, -0.02074045215285, 0.02161526843274, -0.01655260341619, -0.00009291677959, -0.00123395316851, -0.02160367184185, 0.03857599435200, 0.13919314567432, -0.86984376593551, 2.75465861874613, -5.87257861775999, 9.48293806319790,-12.28759895145294, 13.05504219327545,-11.34170355132042, 7.81501653005538, -3.84664617118067}, - {-0.00187763777362, 0.00674613682247, -0.00240879051584, 0.01624864962975, -0.02596338512915, 0.02245293253339, -0.00834990904936, -0.00851165645469, -0.00848709379851, -0.02911007808948, 0.05418656406430, 0.13149317958808, -0.75104302451432, 2.19611684890774, -4.39470996079559, 6.85401540936998, -8.81498681370155, 9.47693607801280, -8.54751527471874, 6.36317777566148, -3.47845948550071}, - {-0.00881362733839, 0.00651420667831, -0.01390589421898, 0.03174092540049, 0.00222312597743, 0.04781476674921, -0.05588393329856, 0.02163541888798, -0.06247880153653, -0.09331049056315, 0.15457299681924, 0.02347897407020, -0.05032077717131, 0.16378164858596, -0.45953458054983, 1.00595954808547, -1.67148153367602, 2.23697657451713, -2.64577170229825, 2.84868151156327, -2.37898834973084}, - {-0.02950134983287, 0.00205861885564, -0.00000828086748, 0.06276101321749, -0.00584456039913, -0.02364141202522, -0.00915702933434, 0.03282930172664, -0.08587323730772, -0.22613988682123, 0.30296907319327, 0.00302439095741, 0.02005851806501, 0.04500235387352, -0.22138138954925, 0.39120800788284, -0.22638893773906, -0.16276719120440, -0.25656257754070, 1.07977492259970, -1.61273165137247}, - {-0.01760176568150, -0.01635381384540, 0.00832043980773, 0.05724228140351, -0.00589500224440, -0.00469977914380, -0.07834489609479, 0.11921148675203, -0.11828570177555, -0.25572241425570, 0.33642304856132, 0.02977207319925, -0.04237348025746, 0.08333755284107, -0.04067510197014, -0.12453458140019, 0.47854794562326, -0.80774944671438, 0.12205022308084, 0.87350271418188, -1.49858979367799}, - { 0.00541907748707, -0.03193428438915, -0.01863887810927, 0.10478503600251, 0.04097565135648, -0.12398163381748, 0.04078262797139, -0.01419140100551, -0.22784394429749, -0.14351757464547, 0.44915256608450, 0.03222754072173, 0.05784820375801, 0.06747620744683, 0.00613424350682, 0.22199650564824, -0.42029820170918, 0.00213767857124, -0.37256372942400, 0.29661783706366, -0.62820619233671}, - {-0.00588215443421, -0.03788984554840, 0.08647503780351, 0.00647310677246, -0.27562961986224, 0.30931782841830, -0.18901604199609, 0.16744243493672, 0.16242137742230, -0.75464456939302, 0.56619470757641, 0.01807364323573, 0.01639907836189, -0.04784254229033, 0.06739368333110, -0.33032403314006, 0.45054734505008, 0.00819999645858, -0.26806001042947, 0.29156311971249, -1.04800335126349}, - {-0.00749618797172, -0.03721611395801, 0.06920467763959, 0.01628462406333, -0.25344790059353, 0.15558449135573, 0.02377945217615, 0.17520704835522, -0.14289799034253, -0.53174909058578, 0.58100494960553, 0.01818801111503, 0.02442357316099, -0.02505961724053, -0.05246019024463, -0.23313271880868, 0.38952639978999, 0.14728154134330, -0.20256413484477, -0.31863563325245, -0.51035327095184}, - {-0.02217936801134, 0.04788665548180, -0.04060034127000, -0.11202315195388, -0.02459864859345, 0.14590772289388, -0.10214864179676, 0.04267842219415, -0.00275953611929, -0.42163034350696, 0.53648789255105, 0.04704409688120, 0.05477720428674, -0.18823009262115, -0.17556493366449, 0.15113130533216, 0.26408300200955, -0.04678328784242, -0.03424681017675, -0.43193942311114, -0.25049871956020} -}; - -static const Float_t ABButter[9][multiple_of(4, 2 * BUTTER_ORDER + 1)] = { - /* 5 4 3 2 1 */ - {0.98621192462708, 0.97261396931306, -1.97242384925416, -1.97223372919527, 0.98621192462708}, - {0.98500175787242, 0.97022847566350, -1.97000351574484, -1.96977855582618, 0.98500175787242}, - {0.97938932735214, 0.95920349965459, -1.95877865470428, -1.95835380975398, 0.97938932735214}, - {0.97531843204928, 0.95124613669835, -1.95063686409857, -1.95002759149878, 0.97531843204928}, - {0.97316523498161, 0.94705070426118, -1.94633046996323, -1.94561023566527, 0.97316523498161}, - {0.96454515552826, 0.93034775234268, -1.92909031105652, -1.92783286977036, 0.96454515552826}, - {0.96009142950541, 0.92177618768381, -1.92018285901082, -1.91858953033784, 0.96009142950541}, - {0.95856916599601, 0.91885558323625, -1.91713833199203, -1.91542108074780, 0.95856916599601}, - {0.94597685600279, 0.89487434461664, -1.89195371200558, -1.88903307939452, 0.94597685600279} -}; - -/*lint -restore */ - -#ifdef WIN32 -#pragma warning ( default : 4305 ) -#endif - -/* When calling this procedure, make sure that ip[-order] and op[-order] point to real data! */ - -static void -filterYule(const Float_t * input, Float_t * output, size_t nSamples, const Float_t * const kernel) -{ - while (nSamples--) { - Float_t y0 = input[-10] * kernel[ 0]; - Float_t y2 = input[ -9] * kernel[ 1]; - Float_t y4 = input[ -8] * kernel[ 2]; - Float_t y6 = input[ -7] * kernel[ 3]; - Float_t s00 = y0 + y2 + y4 + y6; - Float_t y8 = input[ -6] * kernel[ 4]; - Float_t yA = input[ -5] * kernel[ 5]; - Float_t yC = input[ -4] * kernel[ 6]; - Float_t yE = input[ -3] * kernel[ 7]; - Float_t s01 = y8 + yA + yC + yE; - Float_t yG = input[ -2] * kernel[ 8] + input[ -1] * kernel[ 9]; - Float_t yK = input[ 0] * kernel[10]; - - Float_t s1 = s00 + s01 + yG + yK; - - Float_t x1 = output[-10] * kernel[11] + output[ -9] * kernel[12]; - Float_t x5 = output[ -8] * kernel[13] + output[ -7] * kernel[14]; - Float_t x9 = output[ -6] * kernel[15] + output[ -5] * kernel[16]; - Float_t xD = output[ -4] * kernel[17] + output[ -3] * kernel[18]; - Float_t xH = output[ -2] * kernel[19] + output[ -1] * kernel[20]; - - Float_t s2 = x1 + x5 + x9 + xD + xH; - - output[0] = (Float_t)(s1 - s2); - - ++output; - ++input; - } -} - -static void -filterButter(const Float_t * input, Float_t * output, size_t nSamples, const Float_t * const kernel) -{ - while (nSamples--) { - Float_t s1 = input[-2] * kernel[0] + input[-1] * kernel[2] + input[ 0] * kernel[4]; - Float_t s2 = output[-2] * kernel[1] + output[-1] * kernel[3]; - output[0] = (Float_t)(s1 - s2); - ++output; - ++input; - } -} - - - -static int ResetSampleFrequency(replaygain_t * rgData, long samplefreq); - -/* returns a INIT_GAIN_ANALYSIS_OK if successful, INIT_GAIN_ANALYSIS_ERROR if not */ - -int -ResetSampleFrequency(replaygain_t * rgData, long samplefreq) -{ - /* zero out initial values, only first MAX_ORDER values */ - memset(rgData->linprebuf, 0, MAX_ORDER * sizeof(*rgData->linprebuf)); - memset(rgData->rinprebuf, 0, MAX_ORDER * sizeof(*rgData->rinprebuf)); - memset(rgData->lstepbuf, 0, MAX_ORDER * sizeof(*rgData->lstepbuf)); - memset(rgData->rstepbuf, 0, MAX_ORDER * sizeof(*rgData->rstepbuf)); - memset(rgData->loutbuf, 0, MAX_ORDER * sizeof(*rgData->loutbuf)); - memset(rgData->routbuf, 0, MAX_ORDER * sizeof(*rgData->routbuf)); - - switch ((int) (samplefreq)) { - case 48000: - rgData->freqindex = 0; - break; - case 44100: - rgData->freqindex = 1; - break; - case 32000: - rgData->freqindex = 2; - break; - case 24000: - rgData->freqindex = 3; - break; - case 22050: - rgData->freqindex = 4; - break; - case 16000: - rgData->freqindex = 5; - break; - case 12000: - rgData->freqindex = 6; - break; - case 11025: - rgData->freqindex = 7; - break; - case 8000: - rgData->freqindex = 8; - break; - default: - return INIT_GAIN_ANALYSIS_ERROR; - } - - rgData->sampleWindow = - (samplefreq * RMS_WINDOW_TIME_NUMERATOR + RMS_WINDOW_TIME_DENOMINATOR - - 1) / RMS_WINDOW_TIME_DENOMINATOR; - - rgData->lsum = 0.; - rgData->rsum = 0.; - rgData->totsamp = 0; - - memset(rgData->A, 0, sizeof(rgData->A)); - - return INIT_GAIN_ANALYSIS_OK; -} - -int -InitGainAnalysis(replaygain_t * rgData, long samplefreq) -{ - if (ResetSampleFrequency(rgData, samplefreq) != INIT_GAIN_ANALYSIS_OK) { - return INIT_GAIN_ANALYSIS_ERROR; - } - - rgData->linpre = rgData->linprebuf + MAX_ORDER; - rgData->rinpre = rgData->rinprebuf + MAX_ORDER; - rgData->lstep = rgData->lstepbuf + MAX_ORDER; - rgData->rstep = rgData->rstepbuf + MAX_ORDER; - rgData->lout = rgData->loutbuf + MAX_ORDER; - rgData->rout = rgData->routbuf + MAX_ORDER; - - memset(rgData->B, 0, sizeof(rgData->B)); - - return INIT_GAIN_ANALYSIS_OK; -} - -/* returns GAIN_ANALYSIS_OK if successful, GAIN_ANALYSIS_ERROR if not */ - -int -AnalyzeSamples(replaygain_t * rgData, const Float_t * left_samples, const Float_t * right_samples, - size_t num_samples, int num_channels) -{ - const Float_t *curleft; - const Float_t *curright; - long batchsamples; - long cursamples; - long cursamplepos; - int i; - Float_t sum_l, sum_r; - - if (num_samples == 0) - return GAIN_ANALYSIS_OK; - - cursamplepos = 0; - batchsamples = (long) num_samples; - - switch (num_channels) { - case 1: - right_samples = left_samples; - break; - case 2: - break; - default: - return GAIN_ANALYSIS_ERROR; - } - - if (num_samples < MAX_ORDER) { - memcpy(rgData->linprebuf + MAX_ORDER, left_samples, num_samples * sizeof(Float_t)); - memcpy(rgData->rinprebuf + MAX_ORDER, right_samples, num_samples * sizeof(Float_t)); - } - else { - memcpy(rgData->linprebuf + MAX_ORDER, left_samples, MAX_ORDER * sizeof(Float_t)); - memcpy(rgData->rinprebuf + MAX_ORDER, right_samples, MAX_ORDER * sizeof(Float_t)); - } - - while (batchsamples > 0) { - cursamples = batchsamples > rgData->sampleWindow - rgData->totsamp ? - rgData->sampleWindow - rgData->totsamp : batchsamples; - if (cursamplepos < MAX_ORDER) { - curleft = rgData->linpre + cursamplepos; - curright = rgData->rinpre + cursamplepos; - if (cursamples > MAX_ORDER - cursamplepos) - cursamples = MAX_ORDER - cursamplepos; - } - else { - curleft = left_samples + cursamplepos; - curright = right_samples + cursamplepos; - } - - YULE_FILTER(curleft, rgData->lstep + rgData->totsamp, cursamples, - ABYule[rgData->freqindex]); - YULE_FILTER(curright, rgData->rstep + rgData->totsamp, cursamples, - ABYule[rgData->freqindex]); - - BUTTER_FILTER(rgData->lstep + rgData->totsamp, rgData->lout + rgData->totsamp, cursamples, - ABButter[rgData->freqindex]); - BUTTER_FILTER(rgData->rstep + rgData->totsamp, rgData->rout + rgData->totsamp, cursamples, - ABButter[rgData->freqindex]); - - curleft = rgData->lout + rgData->totsamp; /* Get the squared values */ - curright = rgData->rout + rgData->totsamp; - - sum_l = 0; - sum_r = 0; - i = cursamples & 0x03; - while (i--) { - Float_t const l = *curleft++; - Float_t const r = *curright++; - sum_l += l * l; - sum_r += r * r; - } - i = cursamples / 4; - while (i--) { - Float_t l0 = curleft[0] * curleft[0]; - Float_t l1 = curleft[1] * curleft[1]; - Float_t l2 = curleft[2] * curleft[2]; - Float_t l3 = curleft[3] * curleft[3]; - Float_t sl = l0 + l1 + l2 + l3; - Float_t r0 = curright[0] * curright[0]; - Float_t r1 = curright[1] * curright[1]; - Float_t r2 = curright[2] * curright[2]; - Float_t r3 = curright[3] * curright[3]; - Float_t sr = r0 + r1 + r2 + r3; - sum_l += sl; - curleft += 4; - sum_r += sr; - curright += 4; - } - rgData->lsum += sum_l; - rgData->rsum += sum_r; - - batchsamples -= cursamples; - cursamplepos += cursamples; - rgData->totsamp += cursamples; - if (rgData->totsamp == rgData->sampleWindow) { /* Get the Root Mean Square (RMS) for this set of samples */ - double const val = - STEPS_per_dB * 10. * log10((rgData->lsum + rgData->rsum) / rgData->totsamp * 0.5 + - 1.e-37); - size_t ival = (val <= 0) ? 0 : (size_t) val; - if (ival >= sizeof(rgData->A) / sizeof(*(rgData->A))) - ival = sizeof(rgData->A) / sizeof(*(rgData->A)) - 1; - rgData->A[ival]++; - rgData->lsum = rgData->rsum = 0.; - memmove(rgData->loutbuf, rgData->loutbuf + rgData->totsamp, - MAX_ORDER * sizeof(Float_t)); - memmove(rgData->routbuf, rgData->routbuf + rgData->totsamp, - MAX_ORDER * sizeof(Float_t)); - memmove(rgData->lstepbuf, rgData->lstepbuf + rgData->totsamp, - MAX_ORDER * sizeof(Float_t)); - memmove(rgData->rstepbuf, rgData->rstepbuf + rgData->totsamp, - MAX_ORDER * sizeof(Float_t)); - rgData->totsamp = 0; - } - if (rgData->totsamp > rgData->sampleWindow) /* somehow I really screwed up: Error in programming! Contact author about totsamp > sampleWindow */ - return GAIN_ANALYSIS_ERROR; - } - if (num_samples < MAX_ORDER) { - memmove(rgData->linprebuf, rgData->linprebuf + num_samples, - (MAX_ORDER - num_samples) * sizeof(Float_t)); - memmove(rgData->rinprebuf, rgData->rinprebuf + num_samples, - (MAX_ORDER - num_samples) * sizeof(Float_t)); - memcpy(rgData->linprebuf + MAX_ORDER - num_samples, left_samples, - num_samples * sizeof(Float_t)); - memcpy(rgData->rinprebuf + MAX_ORDER - num_samples, right_samples, - num_samples * sizeof(Float_t)); - } - else { - memcpy(rgData->linprebuf, left_samples + num_samples - MAX_ORDER, - MAX_ORDER * sizeof(Float_t)); - memcpy(rgData->rinprebuf, right_samples + num_samples - MAX_ORDER, - MAX_ORDER * sizeof(Float_t)); - } - - return GAIN_ANALYSIS_OK; -} - - -static Float_t -analyzeResult(uint32_t const *Array, size_t len) -{ - uint32_t elems; - uint32_t upper; - uint32_t sum; - size_t i; - - elems = 0; - for (i = 0; i < len; i++) - elems += Array[i]; - if (elems == 0) - return GAIN_NOT_ENOUGH_SAMPLES; - - upper = (uint32_t) ceil(elems * (1. - RMS_PERCENTILE)); - sum = 0; - for (i = len; i-- > 0;) { - sum += Array[i]; - if (sum >= upper) { - break; - } - } - - return (Float_t) ((Float_t) PINK_REF - (Float_t) i / (Float_t) STEPS_per_dB); -} - - -Float_t -GetTitleGain(replaygain_t * rgData) -{ - Float_t retval; - unsigned int i; - - retval = analyzeResult(rgData->A, sizeof(rgData->A) / sizeof(*(rgData->A))); - - for (i = 0; i < sizeof(rgData->A) / sizeof(*(rgData->A)); i++) { - rgData->B[i] += rgData->A[i]; - rgData->A[i] = 0; - } - - for (i = 0; i < MAX_ORDER; i++) - rgData->linprebuf[i] = rgData->lstepbuf[i] - = rgData->loutbuf[i] - = rgData->rinprebuf[i] - = rgData->rstepbuf[i] - = rgData->routbuf[i] = 0.f; - - rgData->totsamp = 0; - rgData->lsum = rgData->rsum = 0.; - return retval; -} - -#if 0 -static Float_t GetAlbumGain(replaygain_t const* rgData); - -Float_t -GetAlbumGain(replaygain_t const* rgData) -{ - return analyzeResult(rgData->B, sizeof(rgData->B) / sizeof(*(rgData->B))); -} -#endif - -/* end of gain_analysis.c */ diff --git a/lib-src/lame/libmp3lame/gain_analysis.h b/lib-src/lame/libmp3lame/gain_analysis.h deleted file mode 100644 index a6b56ab3b..000000000 --- a/lib-src/lame/libmp3lame/gain_analysis.h +++ /dev/null @@ -1,109 +0,0 @@ -/* - * ReplayGainAnalysis - analyzes input samples and give the recommended dB change - * Copyright (C) 2001 David Robinson and Glen Sawyer - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * concept and filter values by David Robinson (David@Robinson.org) - * -- blame him if you think the idea is flawed - * coding by Glen Sawyer (mp3gain@hotmail.com) 735 W 255 N, Orem, UT 84057-4505 USA - * -- blame him if you think this runs too slowly, or the coding is otherwise flawed - * - * For an explanation of the concepts and the basic algorithms involved, go to: - * http://www.replaygain.org/ - */ - -#ifndef GAIN_ANALYSIS_H -#define GAIN_ANALYSIS_H - -#ifdef HAVE_INTTYPES_H -# include -#else -# ifdef HAVE_STDINT_H -# include -# endif -#endif - -#ifdef __cplusplus -extern "C" { -#endif - - - typedef sample_t Float_t; /* Type used for filtering */ - - -#define PINK_REF 64.82 /* 298640883795 */ /* calibration value for 89dB */ - - -#define YULE_ORDER 10 -#define BUTTER_ORDER 2 -#define YULE_FILTER filterYule -#define BUTTER_FILTER filterButter -#define RMS_PERCENTILE 0.95 /* percentile which is louder than the proposed level */ -#define MAX_SAMP_FREQ 48000L /* maximum allowed sample frequency [Hz] */ -#define RMS_WINDOW_TIME_NUMERATOR 1L -#define RMS_WINDOW_TIME_DENOMINATOR 20L /* numerator / denominator = time slice size [s] */ -#define STEPS_per_dB 100 /* Table entries per dB */ -#define MAX_dB 120 /* Table entries for 0...MAX_dB (normal max. values are 70...80 dB) */ - - enum { GAIN_NOT_ENOUGH_SAMPLES = -24601, GAIN_ANALYSIS_ERROR = 0, GAIN_ANALYSIS_OK = - 1, INIT_GAIN_ANALYSIS_ERROR = 0, INIT_GAIN_ANALYSIS_OK = 1 - }; - - enum { MAX_ORDER = (BUTTER_ORDER > YULE_ORDER ? BUTTER_ORDER : YULE_ORDER) - , MAX_SAMPLES_PER_WINDOW = ((MAX_SAMP_FREQ * RMS_WINDOW_TIME_NUMERATOR) / RMS_WINDOW_TIME_DENOMINATOR + 1) /* max. Samples per Time slice */ - }; - - struct replaygain_data { - Float_t linprebuf[MAX_ORDER * 2]; - Float_t *linpre; /* left input samples, with pre-buffer */ - Float_t lstepbuf[MAX_SAMPLES_PER_WINDOW + MAX_ORDER]; - Float_t *lstep; /* left "first step" (i.e. post first filter) samples */ - Float_t loutbuf[MAX_SAMPLES_PER_WINDOW + MAX_ORDER]; - Float_t *lout; /* left "out" (i.e. post second filter) samples */ - Float_t rinprebuf[MAX_ORDER * 2]; - Float_t *rinpre; /* right input samples ... */ - Float_t rstepbuf[MAX_SAMPLES_PER_WINDOW + MAX_ORDER]; - Float_t *rstep; - Float_t routbuf[MAX_SAMPLES_PER_WINDOW + MAX_ORDER]; - Float_t *rout; - long sampleWindow; /* number of samples required to reach number of milliseconds required for RMS window */ - long totsamp; - double lsum; - double rsum; - int freqindex; - int first; - uint32_t A[STEPS_per_dB * MAX_dB]; - uint32_t B[STEPS_per_dB * MAX_dB]; - - }; -#ifndef replaygain_data_defined -#define replaygain_data_defined - typedef struct replaygain_data replaygain_t; -#endif - - - - - int InitGainAnalysis(replaygain_t * rgData, long samplefreq); - int AnalyzeSamples(replaygain_t * rgData, const Float_t * left_samples, - const Float_t * right_samples, size_t num_samples, int num_channels); - Float_t GetTitleGain(replaygain_t * rgData); - - -#ifdef __cplusplus -} -#endif -#endif /* GAIN_ANALYSIS_H */ diff --git a/lib-src/lame/libmp3lame/i386/Makefile.am b/lib-src/lame/libmp3lame/i386/Makefile.am deleted file mode 100644 index 9355e1c90..000000000 --- a/lib-src/lame/libmp3lame/i386/Makefile.am +++ /dev/null @@ -1,73 +0,0 @@ -## $Id: Makefile.am,v 1.28 2013/06/12 09:16:29 rbrito Exp $ - -AUTOMAKE_OPTIONS = foreign - -DEFS = @DEFS@ @CONFIG_DEFS@ - -ECHO ?= echo - -nasm_sources = \ - choose_table.nas \ - cpu_feat.nas \ - fft3dn.nas \ - fftsse.nas - -if HAVE_NASM -noinst_LTLIBRARIES = liblameasmroutines.la -liblameasmroutines_la_SOURCES = $(nasm_sources) -liblameasmroutines_la_DEPENDENCIES = $(nasm_sources:.nas.lo) -am_liblameasmroutines_la_OBJECTS = \ - choose_table$U.lo \ - cpu_feat$U.lo \ - fft3dn$U.lo \ - fftsse$U.lo -endif - -noinst_HEADERS = nasm.h - -INCLUDES = @INCLUDES@ -I$(top_srcdir)/libmp3lame/@CPUTYPE@ - -SUFFIXES = .nas .lo - -EXTRA_liblameasmroutines_la_SOURCES = $(nasm_sources) - -CLEANFILES = \ - choose_table.o.lst \ - choose_table.lo.lst \ - cpu_feat.o.lst \ - cpu_feat.lo.lst \ - fft3dn.o.lst \ - fft3dn.lo.lst \ - fftsse.o.lst \ - fftsse.lo.lst - -EXTRA_DIST = \ - fft.nas \ - fftfpu.nas \ - ffttbl.nas \ - scalar.nas - -NASM = @NASM@ -NASMFLAGS=@NASM_FORMAT@ -i $(top_srcdir)/libmp3lame/@CPUTYPE@/ - -.nas.o: $< nasm.h - $(NASM) $(NASMFLAGS) $< -o $@ -l $@.lst - -.nas.lo: $< nasm.h - $(ECHO) '# Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 22:14:06)' >$@ - $(ECHO) "pic_object='$*.o'" >>$@ - $(ECHO) "non_pic_object='$*.o'" >>$@ - $(NASM) $(NASMFLAGS) $< -o $*.o -l $@.lst - -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ - $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ - - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck diff --git a/lib-src/lame/libmp3lame/i386/Makefile.in b/lib-src/lame/libmp3lame/i386/Makefile.in deleted file mode 100644 index 70002b049..000000000 --- a/lib-src/lame/libmp3lame/i386/Makefile.in +++ /dev/null @@ -1,633 +0,0 @@ -# Makefile.in generated by automake 1.15.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2017 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = libmp3lame/i386 -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ - $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ - $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -LTLIBRARIES = $(noinst_LTLIBRARIES) -liblameasmroutines_la_LIBADD = -am__liblameasmroutines_la_SOURCES_DIST = choose_table.nas cpu_feat.nas \ - fft3dn.nas fftsse.nas -am__objects_1 = choose_table.lo cpu_feat.lo fft3dn.lo fftsse.lo -liblameasmroutines_la_OBJECTS = $(am_liblameasmroutines_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -@HAVE_NASM_TRUE@am_liblameasmroutines_la_rpath = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -SOURCES = $(liblameasmroutines_la_SOURCES) \ - $(EXTRA_liblameasmroutines_la_SOURCES) -DIST_SOURCES = $(am__liblameasmroutines_la_SOURCES_DIST) \ - $(EXTRA_liblameasmroutines_la_SOURCES) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -HEADERS = $(noinst_HEADERS) -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -ALLOCA = @ALLOCA@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CONFIG_DEFS = @CONFIG_DEFS@ -CONFIG_MATH_LIB = @CONFIG_MATH_LIB@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CPUCCODE = @CPUCCODE@ -CPUTYPE = @CPUTYPE@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ @CONFIG_DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FRONTEND_CFLAGS = @FRONTEND_CFLAGS@ -FRONTEND_LDADD = @FRONTEND_LDADD@ -FRONTEND_LDFLAGS = @FRONTEND_LDFLAGS@ -GREP = @GREP@ -GTK_CFLAGS = @GTK_CFLAGS@ -GTK_CONFIG = @GTK_CONFIG@ -GTK_LIBS = @GTK_LIBS@ -INCLUDES = @INCLUDES@ -I$(top_srcdir)/libmp3lame/@CPUTYPE@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDADD = @LDADD@ -LDFLAGS = @LDFLAGS@ -LIBICONV = @LIBICONV@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIB_MAJOR_VERSION = @LIB_MAJOR_VERSION@ -LIB_MINOR_VERSION = @LIB_MINOR_VERSION@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBICONV = @LTLIBICONV@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAINT = @MAINT@ -MAKEDEP = @MAKEDEP@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NASM = @NASM@ -NASM_FORMAT = @NASM_FORMAT@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -RANLIB = @RANLIB@ -RM_F = @RM_F@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SNDFILE_CFLAGS = @SNDFILE_CFLAGS@ -SNDFILE_LIBS = @SNDFILE_LIBS@ -STRIP = @STRIP@ -VERSION = @VERSION@ -WITH_FRONTEND = @WITH_FRONTEND@ -WITH_MP3RTP = @WITH_MP3RTP@ -WITH_MP3X = @WITH_MP3X@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign -nasm_sources = \ - choose_table.nas \ - cpu_feat.nas \ - fft3dn.nas \ - fftsse.nas - -@HAVE_NASM_TRUE@noinst_LTLIBRARIES = liblameasmroutines.la -@HAVE_NASM_TRUE@liblameasmroutines_la_SOURCES = $(nasm_sources) -@HAVE_NASM_TRUE@liblameasmroutines_la_DEPENDENCIES = $(nasm_sources:.nas.lo) -@HAVE_NASM_TRUE@am_liblameasmroutines_la_OBJECTS = \ -@HAVE_NASM_TRUE@ choose_table$U.lo \ -@HAVE_NASM_TRUE@ cpu_feat$U.lo \ -@HAVE_NASM_TRUE@ fft3dn$U.lo \ -@HAVE_NASM_TRUE@ fftsse$U.lo - -noinst_HEADERS = nasm.h -SUFFIXES = .nas .lo -EXTRA_liblameasmroutines_la_SOURCES = $(nasm_sources) -CLEANFILES = \ - choose_table.o.lst \ - choose_table.lo.lst \ - cpu_feat.o.lst \ - cpu_feat.lo.lst \ - fft3dn.o.lst \ - fft3dn.lo.lst \ - fftsse.o.lst \ - fftsse.lo.lst - -EXTRA_DIST = \ - fft.nas \ - fftfpu.nas \ - ffttbl.nas \ - scalar.nas - -NASMFLAGS = @NASM_FORMAT@ -i $(top_srcdir)/libmp3lame/@CPUTYPE@/ -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) - -LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ - $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) - -CCLD = $(CC) -LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ - -all: all-am - -.SUFFIXES: -.SUFFIXES: .nas .lo .o -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libmp3lame/i386/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign libmp3lame/i386/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -liblameasmroutines.la: $(liblameasmroutines_la_OBJECTS) $(liblameasmroutines_la_DEPENDENCIES) $(EXTRA_liblameasmroutines_la_DEPENDENCIES) - $(AM_V_CCLD)$(LINK) $(am_liblameasmroutines_la_rpath) $(liblameasmroutines_la_OBJECTS) $(liblameasmroutines_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LTLIBRARIES) $(HEADERS) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ - mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ - ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -ECHO ?= echo - -.nas.o: $< nasm.h - $(NASM) $(NASMFLAGS) $< -o $@ -l $@.lst - -.nas.lo: $< nasm.h - $(ECHO) '# Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 22:14:06)' >$@ - $(ECHO) "pic_object='$*.o'" >>$@ - $(ECHO) "non_pic_object='$*.o'" >>$@ - $(NASM) $(NASMFLAGS) $< -o $*.o -l $@.lst - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/lame/libmp3lame/i386/choose_table.nas b/lib-src/lame/libmp3lame/i386/choose_table.nas deleted file mode 100644 index 9217c8eda..000000000 --- a/lib-src/lame/libmp3lame/i386/choose_table.nas +++ /dev/null @@ -1,447 +0,0 @@ -; new count bit routine -; part of this code is origined from -; new GOGO-no-coda (1999, 2000) -; Copyright (C) 1999 shigeo -; modified by Keiichi SAKAI - -%include "nasm.h" - - globaldef choose_table_MMX - globaldef MMX_masking - - externdef largetbl - externdef t1l - externdef table23 - externdef table56 - - segment_data - align 16 -D14_14_14_14 dd 0x000E000E, 0x000E000E -D15_15_15_15 dd 0xfff0fff0, 0xfff0fff0 -mul_add dd 0x00010010, 0x00010010 -mul_add23 dd 0x00010003, 0x00010003 -mul_add56 dd 0x00010004, 0x00010004 -tableDEF - dd 0x00010003,0x01,0x00050005,0x05,0x00070006,0x07,0x00090008,0x08,0x000a0008, 0x09 - dd 0x000a0009,0x0a,0x000b000a,0x0a,0x000b000a,0x0b,0x000c000a,0x0a,0x000c000b, 0x0b - dd 0x000c000b,0x0c,0x000d000c,0x0c,0x000d000c,0x0d,0x000d000c,0x0d,0x000e000d, 0x0e - dd 0x000b000e,0x0e,0x00040005,0x04,0x00060005,0x06,0x00080007,0x08,0x00090008, 0x09 - dd 0x000a0009,0x0a,0x000b0009,0x0a,0x000b000a,0x0b,0x000b000a,0x0b,0x000c000a, 0x0b - dd 0x000c000b,0x0b,0x000c000b,0x0c,0x000d000c,0x0c,0x000e000c,0x0d,0x000d000c, 0x0e - dd 0x000e000d,0x0e,0x000b000d,0x0e,0x00070006,0x07,0x00080007,0x08,0x00090007, 0x09 - dd 0x000a0008,0x0a,0x000b0009,0x0b,0x000b0009,0x0b,0x000c000a,0x0c,0x000c000a, 0x0c - dd 0x000d000a,0x0b,0x000c000b,0x0c,0x000d000b,0x0c,0x000d000c,0x0d,0x000d000c, 0x0d - dd 0x000e000d,0x0e,0x000e000d,0x0f,0x000c000d,0x0f,0x00090007,0x08,0x00090008, 0x09 - dd 0x000a0008,0x0a,0x000b0009,0x0b,0x000b0009,0x0b,0x000c000a,0x0c,0x000c000a, 0x0c - dd 0x000c000b,0x0c,0x000d000b,0x0c,0x000d000b,0x0d,0x000e000c,0x0d,0x000e000c, 0x0d - dd 0x000e000c,0x0d,0x000f000d,0x0e,0x000f000d,0x0f,0x000d000d,0x0f,0x000a0008, 0x09 - dd 0x000a0008,0x09,0x000b0009,0x0b,0x000b0009,0x0b,0x000c000a,0x0c,0x000c000a, 0x0c - dd 0x000d000b,0x0d,0x000d000b,0x0d,0x000d000b,0x0c,0x000e000b,0x0d,0x000e000c, 0x0d - dd 0x000e000c,0x0e,0x000f000c,0x0e,0x000f000d,0x0f,0x000f000d,0x0f,0x000c000d, 0x10 - dd 0x000a0009,0x0a,0x000a0009,0x0a,0x000b0009,0x0b,0x000b000a,0x0c,0x000c000a, 0x0c - dd 0x000d000a,0x0c,0x000d000b,0x0d,0x000e000b,0x0d,0x000d000b,0x0d,0x000e000b, 0x0d - dd 0x000e000c,0x0e,0x000f000c,0x0d,0x000f000d,0x0f,0x000f000d,0x0f,0x0010000d, 0x10 - dd 0x000d000e,0x10,0x000b000a,0x0a,0x000b0009,0x0b,0x000b000a,0x0c,0x000c000a, 0x0c - dd 0x000d000a,0x0d,0x000d000b,0x0d,0x000d000b,0x0d,0x000d000b,0x0d,0x000e000b, 0x0d - dd 0x000e000c,0x0e,0x000e000c,0x0e,0x000e000c,0x0e,0x000f000d,0x0f,0x000f000d, 0x0f - dd 0x0010000e,0x10,0x000d000e,0x10,0x000b000a,0x0b,0x000b000a,0x0b,0x000c000a, 0x0c - dd 0x000c000b,0x0d,0x000d000b,0x0d,0x000d000b,0x0d,0x000d000b,0x0e,0x000e000c, 0x0e - dd 0x000e000c,0x0e,0x000f000c,0x0e,0x000f000c,0x0f,0x000f000c,0x0f,0x000f000d, 0x0f - dd 0x0011000d,0x10,0x0011000d,0x12,0x000d000e,0x12,0x000b000a,0x0a,0x000c000a, 0x0a - dd 0x000c000a,0x0b,0x000d000b,0x0c,0x000d000b,0x0c,0x000d000b,0x0d,0x000e000b, 0x0d - dd 0x000e000c,0x0e,0x000f000c,0x0e,0x000f000c,0x0e,0x000f000c,0x0e,0x000f000d, 0x0f - dd 0x0010000d,0x0f,0x0010000e,0x10,0x0010000e,0x11,0x000d000e,0x11,0x000c000a, 0x0b - dd 0x000c000a,0x0b,0x000c000b,0x0c,0x000d000b,0x0c,0x000d000b,0x0d,0x000e000b, 0x0d - dd 0x000e000c,0x0d,0x000f000c,0x0f,0x000f000c,0x0e,0x000f000d,0x0f,0x000f000d, 0x0f - dd 0x0010000d,0x10,0x000f000d,0x10,0x0010000e,0x10,0x000f000e,0x12,0x000e000e, 0x11 - dd 0x000c000b,0x0b,0x000d000b,0x0c,0x000c000b,0x0c,0x000d000b,0x0d,0x000e000c, 0x0d - dd 0x000e000c,0x0e,0x000e000c,0x0e,0x000e000c,0x0f,0x000f000c,0x0e,0x0010000d, 0x0f - dd 0x0010000d,0x10,0x0010000d,0x0f,0x0011000d,0x10,0x0011000e,0x11,0x0010000f, 0x12 - dd 0x000d000e,0x13,0x000d000b,0x0c,0x000d000b,0x0c,0x000d000b,0x0c,0x000d000b, 0x0d - dd 0x000e000c,0x0e,0x000e000c,0x0e,0x000f000c,0x0e,0x0010000c,0x0e,0x0010000d, 0x0f - dd 0x0010000d,0x0f,0x0010000d,0x0f,0x0010000d,0x10,0x0010000e,0x11,0x000f000e, 0x11 - dd 0x0010000e,0x11,0x000e000f,0x12,0x000d000c,0x0c,0x000e000c,0x0d,0x000e000b, 0x0d - dd 0x000e000c,0x0e,0x000e000c,0x0e,0x000f000c,0x0f,0x000f000d,0x0e,0x000f000d, 0x0f - dd 0x000f000d,0x10,0x0011000d,0x10,0x0010000d,0x11,0x0010000d,0x11,0x0010000e, 0x11 - dd 0x0010000e,0x12,0x0012000f,0x12,0x000e000f,0x12,0x000f000c,0x0d,0x000e000c, 0x0d - dd 0x000e000c,0x0e,0x000e000c,0x0f,0x000f000c,0x0f,0x000f000d,0x0f,0x0010000d, 0x10 - dd 0x0010000d,0x10,0x0010000d,0x10,0x0012000e,0x10,0x0011000e,0x10,0x0011000e, 0x11 - dd 0x0011000e,0x12,0x0013000e,0x11,0x0011000f,0x12,0x000e000f,0x12,0x000e000d, 0x0e - dd 0x000f000d,0x0e,0x000d000d,0x0e,0x000e000d,0x0f,0x0010000d,0x0f,0x0010000d, 0x0f - dd 0x000f000d,0x11,0x0010000d,0x10,0x0010000e,0x10,0x0011000e,0x13,0x0012000e, 0x11 - dd 0x0011000e,0x11,0x0013000f,0x11,0x0011000f,0x13,0x0010000e,0x12,0x000e000f, 0x12 - dd 0x000b000d,0x0d,0x000b000d,0x0e,0x000b000d,0x0f,0x000c000d,0x10,0x000c000d, 0x10 - dd 0x000d000d,0x10,0x000d000d,0x11,0x000d000e,0x10,0x000e000e,0x11,0x000e000e, 0x11 - dd 0x000e000e,0x12,0x000e000e,0x12,0x000e000f,0x15,0x000e000f,0x14,0x000e000f, 0x15 - dd 0x000c000f,0x12 - -tableABC - dd 0x00020004,0x1,0x00040004,0x4,0x00060006,0x7,0x00080008,0x9,0x00090009,0xa,0x000a000a,0xa - dd 0x0009000a,0xa,0x000a000a,0xb,0x00000000,0x0,0x00020003,0x1,0x00040004,0x4,0x00070006,0x7 - dd 0x00090007,0x9,0x00090009,0x9,0x000a000a,0xa,0x00000000,0x0,0x00040004,0x4,0x00050005,0x6 - dd 0x00060006,0x8,0x00080007,0x9,0x000a0009,0xa,0x000a0009,0xb,0x0009000a,0xa,0x000a000a,0xa - dd 0x00000000,0x0,0x00040004,0x4,0x00040005,0x6,0x00060006,0x8,0x000a0007,0x9,0x000a0008,0x9 - dd 0x000a000a,0xa,0x00000000,0x0,0x00060006,0x7,0x00070006,0x8,0x00080007,0x9,0x00090008,0xa - dd 0x000a0009,0xb,0x000b000a,0xc,0x000a0009,0xb,0x000a000a,0xb,0x00000000,0x0,0x00070005,0x7 - dd 0x00060006,0x7,0x00080007,0x9,0x000a0008,0xa,0x000a0009,0xa,0x000b000a,0xb,0x00000000,0x0 - dd 0x00080007,0x8,0x00080007,0x9,0x00090008,0xa,0x000b0008,0xb,0x000a0009,0xc,0x000c000a,0xc - dd 0x000a000a,0xb,0x000b000a,0xc,0x00000000,0x0,0x00090007,0x8,0x000a0007,0x9,0x000a0008,0xa - dd 0x000b0009,0xb,0x000b0009,0xb,0x000c000a,0xb,0x00000000,0x0,0x00090008,0x9,0x000a0008,0xa - dd 0x000a0009,0xb,0x000b0009,0xc,0x000b000a,0xc,0x000c000a,0xc,0x000b000a,0xc,0x000c000b,0xc - dd 0x00000000,0x0,0x00090008,0x8,0x00090008,0x9,0x000a0009,0xa,0x000b0009,0xb,0x000c000a,0xb - dd 0x000c000b,0xc,0x00000000,0x0,0x00090009,0xa,0x000a0009,0xb,0x000b000a,0xc,0x000c000a,0xc - dd 0x000c000a,0xd,0x000d000b,0xd,0x000c000a,0xc,0x000d000b,0xd,0x00000000,0x0,0x000a0009,0x9 - dd 0x000a0009,0xa,0x000b000a,0xb,0x000b000a,0xc,0x000d000b,0xc,0x000d000b,0xc,0x00000000,0x0 - dd 0x00090009,0x9,0x00090009,0xa,0x00090009,0xb,0x000a000a,0xc,0x000b000a,0xc,0x000c000b,0xc - dd 0x000c000b,0xd,0x000c000c,0xd,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0 - dd 0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x0009000a,0xa,0x0009000a,0xa - dd 0x000a000a,0xb,0x000b000b,0xc,0x000c000b,0xc,0x000c000b,0xd,0x000c000b,0xd,0x000c000c,0xd - dd 0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0,0x00000000,0x0 - dd 0x0,0x00000000, 0x0,0x00000000 - -linbits32 - dd 0x00040004,0x10001,0x00040004,0x20002,0x00040004,0x30003,0x00040004,0x40004 - dd 0x00050005,0x60006,0x00060006,0x60006,0x00070007,0x80008,0x00080008,0x80008 - dd 0x00090009,0xa000a,0x000b000b,0xa000a,0x000b000b,0xd000d,0x000d000d,0xd000d - dd 0x000d000d,0xd000d - - -choose_table_H - dw 0x1810, 0x1811, 0x1812, 0x1813, 0x1914, 0x1a14, 0x1b15, 0x1c15 - dw 0x1d16, 0x1e16, 0x1e17, 0x1f17, 0x1f17 - -choose_jump_table_L: - dd table_MMX.L_case_0 - choose_table_MMX - dd table_MMX.L_case_1 - choose_table_MMX - dd table_MMX.L_case_2 - choose_table_MMX - dd table_MMX.L_case_3 - choose_table_MMX - dd table_MMX.L_case_45 - choose_table_MMX - dd table_MMX.L_case_45 - choose_table_MMX - dd table_MMX.L_case_67 - choose_table_MMX - dd table_MMX.L_case_67 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - dd table_MMX.L_case_8_15 - choose_table_MMX - - segment_code -; -; use MMX -; - -PIC_OFFSETTABLE - - align 16 -; int choose_table(int *ix, int *end, int *s) -choose_table_MMX: - push ebp - call get_pc.bp - add ebp, PIC_BASE() - - mov ecx,[esp+8] ;ecx = begin - mov edx,[esp+12] ;edx = end - sub ecx,edx ;ecx = begin-end(should be minus) - test ecx,8 - pxor mm0,mm0 ;mm0=[0:0] - movq mm1,[edx+ecx] - jz .lp - - add ecx,8 - jz .exit - - align 4 -.lp: - movq mm4,[edx+ecx] - movq mm5,[edx+ecx+8] - add ecx,16 - psubusw mm4,mm0 ; $BK\Ev$O(B dword $B$G$J$$$H$$$1$J$$$N$@$,(B - psubusw mm5,mm1 ; $B$=$s$J%3%^%s%I$O$J$$(B :-p - paddw mm0,mm4 ; $B$,(B, $B$3$3$G07$&CM$NHO0O$O(B 8191+15 $B0J2<$J$N$GLdBj$J$$(B - paddw mm1,mm5 - jnz .lp -.exit: - psubusw mm1,mm0 ; $B$3$l$bK\Ev$O(B dword $B$G$J$$$H$$$1$J$$(B - paddw mm0,mm1 - - movq mm4,mm0 - punpckhdq mm4,mm4 - psubusw mm4,mm0 ; $B$3$l$bK\Ev$O(B dword $B$G$J$$$H$$$1$J$$(B - paddw mm0,mm4 - movd eax,mm0 - - cmp eax,15 - ja .with_ESC - lea ecx,[PIC_EBP_REL(choose_table_MMX)] - add ecx,[PIC_EBP_REL(choose_jump_table_L+eax*4)] - jmp ecx - -.with_ESC1: - emms - mov ecx, [esp+16] ; *s - mov [ecx], eax - or eax,-1 - pop ebp - ret - -.with_ESC: - cmp eax, 8191+15 - ja .with_ESC1 - - sub eax,15 - push ebx - push esi - bsr eax, eax -%assign _P 4*2 - movq mm5, [PIC_EBP_REL(D15_15_15_15)] - movq mm6, [PIC_EBP_REL(D14_14_14_14)] - movq mm3, [PIC_EBP_REL(mul_add)] - - mov ecx, [esp+_P+8] ; = ix -; mov edx, [esp+_P+12] ; = end - sub ecx, edx - - xor esi, esi ; sum = 0 - test ecx, 8 - pxor mm7, mm7 ; linbits_sum, 14$B$r1[$($?$b$N$N?t(B - jz .H_dual_lp1 - - movq mm0, [edx+ecx] - add ecx,8 - packssdw mm0,mm7 - movq mm2, mm0 - paddusw mm0, mm5 ; mm0 = min(ix, 15)+0xfff0 - pcmpgtw mm2, mm6 ; 14$B$h$jBg$-$$$+!)(B - psubw mm7, mm2 ; 14$B$h$jBg$-$$$H$-(B linbits_sum++; - pmaddwd mm0, mm3 ; {0, 0, y, x}*{1, 16, 1, 16} - movd ebx, mm0 - mov esi, [PIC_EBP_REL(largetbl+ebx*4+(16*16+16)*4)] - - jz .H_dual_exit - - align 4 -.H_dual_lp1: - movq mm0, [edx+ecx] - movq mm1, [edx+ecx+8] - packssdw mm0,mm1 - movq mm2, mm0 - paddusw mm0, mm5 ; mm0 = min(ix, 15)+0xfff0 - pcmpgtw mm2, mm6 ; 14$B$h$jBg$-$$$+!)(B - pmaddwd mm0, mm3 ; {y, x, y, x}*{1, 16, 1, 16} - movd ebx, mm0 - punpckhdq mm0,mm0 - add esi, [PIC_EBP_REL(largetbl+ebx*4+(16*16+16)*4)] - movd ebx, mm0 - add esi, [PIC_EBP_REL(largetbl+ebx*4+(16*16+16)*4)] - add ecx, 16 - psubw mm7, mm2 ; 14$B$h$jBg$-$$$H$-(B linbits_sum++; - jnz .H_dual_lp1 - -.H_dual_exit: - pmov mm1,mm7 - punpckhdq mm7,mm7 - paddd mm7,mm1 - punpckldq mm7,mm7 - - pmaddwd mm7, [PIC_EBP_REL(linbits32+eax*8)] ; linbits - mov ax, [PIC_EBP_REL(choose_table_H+eax*2)] - - movd ecx, mm7 - punpckhdq mm7,mm7 - movd edx,mm7 - emms - shl edx, 16 - add ecx, edx - - add ecx, esi - - pop esi - pop ebx - - mov edx, ecx - and ecx, 0xffff ; ecx = sum2 - shr edx, 16 ; edx = sum - - cmp edx, ecx - jle .chooseE_s1 - mov edx, ecx - shr eax, 8 -.chooseE_s1: - mov ecx, [esp+16] ; *s - and eax, 0xff - add [ecx], edx - pop ebp - ret - -table_MMX.L_case_0: - emms - pop ebp - ret - -table_MMX.L_case_1: - emms - mov eax, [esp+16] ; *s - mov ecx, [esp+8] ; *ix - sub ecx, edx - push ebx -.lp: - mov ebx, [edx+ecx] - add ebx, ebx - add ebx, [edx+ecx+4] - movzx ebx, byte [PIC_EBP_REL(ebx+t1l)] - add [eax], ebx - add ecx, 8 - jnz .lp - pop ebx - mov eax, 1 - pop ebp - ret - -table_MMX.L_case_45: - push dword 7 - lea ecx, [PIC_EBP_REL(tableABC+9*8)] - jmp from3 - -table_MMX.L_case_67: - push dword 10 - lea ecx, [PIC_EBP_REL(tableABC)] - jmp from3 - -table_MMX.L_case_8_15: - push dword 13 - lea ecx, [PIC_EBP_REL(tableDEF)] -from3: - mov eax,[esp+12] ;eax = *begin -; mov edx,[esp+16] ;edx = *end - - push ebx - sub eax, edx - - movq mm5,[PIC_EBP_REL(mul_add)] - pxor mm2,mm2 ;mm2 = sum - - test eax, 8 - jz .choose3_lp1 -; odd length - movq mm0,[edx+eax] ;mm0 = ix[0] | ix[1] - add eax,8 - packssdw mm0,mm2 - - pmaddwd mm0,mm5 - movd ebx,mm0 - - movq mm2, [ecx+ebx*8] - - jz .choose3_exit - - align 4 -.choose3_lp1 - movq mm0,[edx+eax] - movq mm1,[edx+eax+8] - add eax,16 - packssdw mm0,mm1 ;mm0 = ix[0]|ix[1]|ix[2]|ix[3] - pmaddwd mm0,mm5 - movd ebx,mm0 - punpckhdq mm0,mm0 - paddd mm2, [ecx+ebx*8] - movd ebx,mm0 - paddd mm2, [ecx+ebx*8] - jnz .choose3_lp1 -.choose3_exit -; xor eax,eax - movd ebx, mm2 - punpckhdq mm2,mm2 - mov ecx, ebx - and ecx, 0xffff ; ecx = sum2 - shr ebx, 16 ; ebx = sum1 - movd edx, mm2 ; edx = sum - - cmp edx, ebx - jle .choose3_s1 - mov edx, ebx - inc eax -.choose3_s1: - emms - pop ebx - cmp edx, ecx - jle .choose3_s2 - mov edx, ecx - mov eax, 2 -.choose3_s2: - pop ecx - add eax, ecx - mov ecx, [esp+16] ; *s - add [ecx], edx - pop ebp - ret - -table_MMX.L_case_2: - push dword 2 - lea ecx,[PIC_EBP_REL(table23)] - pmov mm5,[PIC_EBP_REL(mul_add23)] - jmp from2 -table_MMX.L_case_3: - push dword 5 - lea ecx,[PIC_EBP_REL(table56)] - pmov mm5,[PIC_EBP_REL(mul_add56)] -from2: - mov eax,[esp+12] ;eax = *begin -; mov edx,[esp+16] ;edx = *end - push ebx - push edi - - sub eax, edx - xor edi, edi - test eax, 8 - jz .choose2_lp1 -; odd length - movq mm0,[edx+eax] ;mm0 = ix[0] | ix[1] - pxor mm2,mm2 ;mm2 = sum - packssdw mm0,mm2 - - pmaddwd mm0,mm5 - movd ebx,mm0 - - mov edi, [ecx+ebx*4] - - add eax,8 - jz .choose2_exit - - align 4 -.choose2_lp1 - movq mm0,[edx+eax] - movq mm1,[edx+eax+8] - packssdw mm0,mm1 ;mm0 = ix[0]|ix[1]|ix[2]|ix[3] - pmaddwd mm0,mm5 - movd ebx,mm0 - punpckhdq mm0,mm0 - add edi, [ecx+ebx*4] - movd ebx, mm0 - add edi, [ecx+ebx*4] - add eax,16 - jnc .choose2_lp1 -.choose2_exit - mov ecx, edi - pop edi - pop ebx - pop eax ; table num. - emms - - mov edx, ecx - and ecx, 0xffff ; ecx = sum2 - shr edx, 16 ; edx = sum1 - - cmp edx, ecx - jle .choose2_s1 - mov edx, ecx - inc eax -.choose2_s1: - mov ecx, [esp+16] ; *s - add [ecx], edx - pop ebp - ret - - end diff --git a/lib-src/lame/libmp3lame/i386/cpu_feat.nas b/lib-src/lame/libmp3lame/i386/cpu_feat.nas deleted file mode 100644 index b5b09c11a..000000000 --- a/lib-src/lame/libmp3lame/i386/cpu_feat.nas +++ /dev/null @@ -1,107 +0,0 @@ -; -; -; assembler routines to detect CPU-features -; -; MMX / 3DNow! / SSE / SSE2 -; -; for the LAME project -; Frank Klemm, Robert Hegemann 2000-10-12 -; - -%include "nasm.h" - - globaldef has_MMX_nasm - globaldef has_3DNow_nasm - globaldef has_SSE_nasm - globaldef has_SSE2_nasm - - segment_code - -testCPUID: - pushfd - pop eax - mov ecx,eax - xor eax,0x200000 - push eax - popfd - pushfd - pop eax - cmp eax,ecx - ret - -;--------------------------------------- -; int has_MMX_nasm (void) -;--------------------------------------- - -has_MMX_nasm: - pushad - call testCPUID - jz return0 ; no CPUID command, so no MMX - - mov eax,0x1 - CPUID - test edx,0x800000 - jz return0 ; no MMX support - jmp return1 ; MMX support - -;--------------------------------------- -; int has_SSE_nasm (void) -;--------------------------------------- - -has_SSE_nasm: - pushad - call testCPUID - jz return0 ; no CPUID command, so no SSE - - mov eax,0x1 - CPUID - test edx,0x02000000 - jz return0 ; no SSE support - jmp return1 ; SSE support - -;--------------------------------------- -; int has_SSE2_nasm (void) -;--------------------------------------- - -has_SSE2_nasm: - pushad - call testCPUID - jz return0 ; no CPUID command, so no SSE2 - - mov eax,0x1 - CPUID - test edx,0x04000000 - jz return0 ; no SSE2 support - jmp return1 ; SSE2 support - -;--------------------------------------- -; int has_3DNow_nasm (void) -;--------------------------------------- - -has_3DNow_nasm: - pushad - call testCPUID - jz return0 ; no CPUID command, so no 3DNow! - - mov eax,0x80000000 - CPUID - cmp eax,0x80000000 - jbe return0 ; no extended MSR(1), so no 3DNow! - - mov eax,0x80000001 - CPUID - test edx,0x80000000 - jz return0 ; no 3DNow! support - ; 3DNow! support -return1: - popad - xor eax,eax - inc eax - ret - -return0: - popad - xor eax,eax - ret - - end diff --git a/lib-src/lame/libmp3lame/i386/fft.nas b/lib-src/lame/libmp3lame/i386/fft.nas deleted file mode 100644 index 7928b334e..000000000 --- a/lib-src/lame/libmp3lame/i386/fft.nas +++ /dev/null @@ -1,267 +0,0 @@ - -; for new GOGO-no-coda (1999/09) -; Copyright (C) 1999 shigeo -; special thanks to Keiichi SAKAI, URURI -%include "nasm.h" - - globaldef fht_3DN - globaldef fht - externdef costab_fft - externdef sintab_fft - externdef gray_index - - segment_data - align 16 -D_MSB1_0 dd 0 ,0x80000000 -D_SQRT2 dd 1.414213562,1.414213562 -t_s0 dd 0 ;[ t_c:t_s] -t_c0 dd 0 -t_c1 dd 0 ;[-t_s:t_c] -t_s1 dd 0 -D_s1c1 dd 0, 0 -D_Mc1s1 dd 0, 0 -D_s2c2 dd 0, 0 -D_Mc2s2 dd 0, 0 -D_0_1 dd 1.0, 0.0 -S_05 DD 0.5 -S_00005 DD 0.0005 -fht dd 0 ;´Ø¿ô¥Ý¥¤¥ó¥¿ - - segment_code - -;************************************************************************ - -; by shigeo -; 99/08/16 -; 23000clk ¿É¤«¤Ã¤¿¡Á -; 18500clk bit reversal from gogo1 by URURI - -;void fht(float *fz, int n); - align 16 -fht_3DN: - push ebx - push esi - push edi - push ebp -%assign _P 4*4 - ;¤Þ¤ººÇ½é¤Î¥ë¡¼¥×... ¤Ïfht()¤Î³°¤Ø°ÜÆ° - - mov esi,[esp+_P+4] ;esi=fz - mov ecx,[esp+_P+8] ;ecx=n - - ;¥á¥¤¥ó¥ë¡¼¥× - movq mm7,[D_MSB1_0] ;mm7=[1<<31:0] - -%assign LOCAL_STACK 16 - sub esp,LOCAL_STACK -%assign _P (_P+LOCAL_STACK) - xor eax,eax - mov [esp],eax ;k=0 -%define k dword [esp] -%define kx dword [esp+4] -%define fn dword [esp+8] - -.lp30: ;k=0; do{ - mov ecx,k - add ecx,2 - mov k,ecx - mov eax,1 - shl eax,cl ;eax=k1 = 1<>1 - mov kx,esi ;Êݸ(¸å¤Ç»È¤¦) - mov edi,[esp+_P+4] ;edi=fi=fz - lea ebp,[edi+esi*4] ;ebp=gi=fz+kx - mov esi,[esp+_P+8] ;esi=n - lea esi,[edi+esi*4] ;esi=fn=fz+n - movq mm6,[D_SQRT2] ;mm6=[¢å2:¢å2] - -.lp31: ;fn=fz+n; do{ FLOAT g0,f0,f1,... - movd mm0,[edi] ;mm0=[0:fi[ 0]] - movd mm1,[edi+eax*4] ;mm1=[0:fi[k1]] - punpckldq mm0,mm0 ;mm0=[fi_0 :fi_0 ] - punpckldq mm1,mm1 ;mm1=[fi_k1:fi_k1] - movd mm2,[edi+ebx*4] - movd mm3,[edi+ecx*4] - punpckldq mm2,mm2 ;mm2=[fi_k2:fi_k2] - punpckldq mm3,mm3 ;mm3=[fi_k3:fi_k3] - pxor mm1,mm7 ;mm1=[-fi_k1:fi_k1] - pxor mm3,mm7 ;mm3=[-fi_k3:fi_k3] - pfadd mm0,mm1 ;mm0=[f1:f0]=[fi_0 -fi_k1 : fi_0 +fi_k1] - pfadd mm2,mm3 ;mm2=[f3:f2]=[fi_k2-fi_k3 : fi_k2+fi_k3] - movq mm3,mm0 ;mm3=[f1:f0] - pfadd mm0,mm2 ;mm0=[f1+f3:f0+f2] - movd [edi],mm0 ;fi[0]=f0+f2 - psrlq mm0,32 ;mm0=[0:f1+f3] - pfsub mm3,mm2 ;mm3=[f1-f3:f0-f2] - movd [edi+eax*4],mm0 ;fi[k1]=f1+f3 - movd [edi+ebx*4],mm3 ;fi[k2]=f0-f2 - psrlq mm3,32 ;mm3=[0:f1-f3] - movd [edi+ecx*4],mm3 ;fi[k3]=f1-f3 - - movd mm0,[ebp] ;mm0=[0:gi_0] - movd mm1,[ebp+eax*4] ;mm1=[0:gi_k1] - punpckldq mm0,mm0 ;mm0=[gi_0 :gi_0 ] - punpckldq mm1,mm1 ;mm1=[gi_k1:gi_k1] - movd mm2,[ebp+ebx*4] ;mm2=[0:gi_k2] - pxor mm1,mm7 ;mm1=[-gi_k1:gi_k1] - punpckldq mm2,[ebp+ecx*4] ;mm2=[gi_k3:gi_k2] - pfadd mm0,mm1 ;mm0=[g1:g0]=[gi_0 -gi_k1:gi_0 +gi_k1] - pfmul mm2,mm6 ;mm2=[g3:g2]=sqrt2 * [gi_k3:gi_k2] - movq mm1,mm0 ;mm1=[g1:g0] - pfadd mm0,mm2 ;mm0=[g1+g3:g0+g2] - movd [ebp],mm0 ;gi[0]=g0+g2 - psrlq mm0,32 ;mm0=[0:g1+g3] - pfsub mm1,mm2 ;mm1=[g1-g3:g0-g2] - movd [ebp+eax*4],mm0 ;gi[k1]=g1+g3 - movd [ebp+ebx*4],mm1 ;gi[k2]=g0-g2 - psrlq mm1,32 ;mm1=[0:g1-g3] - movd [ebp+ecx*4],mm1 ;gi[k3]=g1-g3 - lea edi,[edi+edx*4] ;fi += k4 - lea ebp,[ebp+edx*4] ;gi += k4 - cmp edi,esi - jc near .lp31 ;}while(fi ɬÍ× -; c2 = c1*c1 - s1*s1 = 1 - (2*s1)*s1; -; s2 = c1*s1 + s1*c1 = 2*s1*c1; - shufps xmm7,xmm7,R4(1,0,0,1) - movss xmm5,xmm7 ; = { --, --, --, s1} - xorps xmm7,[PIC_EBP_REL(Q_MMPP)] ; = {-s1, -c1, +c1, +s1} -> ɬÍ× - - addss xmm5,xmm5 ; = (--, --, --, 2*s1) - add esi,4 ; esi = fi = fz + i - shufps xmm5,xmm5,R4(0,0,0,0) ; = (2*s1, 2*s1, 2*s1, 2*s1) - mulps xmm5,xmm6 ; = (2*s1*c1, 2*s1*s1, 2*s1*s1, 2*s1*c1) - subps xmm5,[PIC_EBP_REL(D_1100)] ; = (--, 2*s1*s1-1, --, 2*s1*c1) = {-- -c2 -- s2} - movaps xmm4,xmm5 - shufps xmm5,xmm5,R4(2,0,2,0) ; = {-c2, s2, -c2, s2} -> ɬÍ× - - xorps xmm4,[PIC_EBP_REL(Q_MMPP)] ; = {--, c2, --, s2} - shufps xmm4,xmm4,R4(0,2,0,2) ; = {s2, c2, s2, c2} -> ɬÍ× - - loopalign 16 -.lp21: ; do{ -; a = c2*fi[k1] + s2*gi[k1]; -; b = s2*fi[k1] - c2*gi[k1]; -; c = c2*fi[k3] + s2*gi[k3]; -; d = s2*fi[k3] - c2*gi[k3]; -; f0 = fi[0 ] + a; -; g0 = gi[0 ] + b; -; f2 = fi[k1 * 2] + c; -; g2 = gi[k1 * 2] + d; -; f1 = fi[0 ] - a; -; g1 = gi[0 ] - b; -; f3 = fi[k1 * 2] - c; -; g3 = gi[k1 * 2] - d; - lea edi,[esi + eax*2 - 8] ; edi = gi = fz +k1-i - - movss xmm0,[esi + eax*2] ; = fi[k1] - movss xmm2,[esi + edx*2] ; = fi[k3] - shufps xmm0,xmm2,0x00 ; = {fi[k3], fi[k3], fi[k1], fi[k1]} - movss xmm1,[edi + eax*2] ; = fi[k1] - movss xmm3,[edi + edx*2] ; = fi[k3] - shufps xmm1,xmm3,0x00 ; = {gi[k3], gi[k3], gi[k1], gi[k1]} - movss xmm2,[esi] ; = fi[0] - mulps xmm0,xmm4 ; *= {+s2, +c2, +s2, +c2} - movss xmm3,[esi + eax*4] ; = fi[k2] - unpcklps xmm2,xmm3 ; = {--, --, fi[k2], fi[0]} - mulps xmm1,xmm5 ; *= {-c2, +s2, -c2, +s2} - movss xmm3,[edi + eax*4] ; = gi[k2] - addps xmm0,xmm1 ; = {d, c, b, a} - movss xmm1,[edi] ; = gi[0] - unpcklps xmm1,xmm3 ; = {--, --, gi[k2], gi[0]} - unpcklps xmm2,xmm1 ; = {gi[k2], fi[k2], gi[0], fi[0]} - movaps xmm1,xmm2 - addps xmm1,xmm0 ; = {g2, f2, g0, f0} - subps xmm2,xmm0 ; = {g3, f3, g1, f1} - -; a = c1*f2 + s1*g3; -; c = s1*g2 + c1*f3; -; b = s1*f2 - c1*g3; -; d = c1*g2 - s1*f3; -; fi[0 ] = f0 + a; -; gi[0 ] = g0 + c; -; gi[k1] = g1 + b; -; fi[k1] = f1 + d; -; fi[k1 * 2] = f0 - a; -; gi[k1 * 2] = g0 - c; -; gi[k3] = g1 - b; -; fi[k3] = f1 - d; - movaps xmm3,xmm1 - movhlps xmm1,xmm1 ; = {g2, f2, g2, f2} - shufps xmm3,xmm2,0x14 ; = {f1, g1, g0, f0} - mulps xmm1,xmm6 ; *= {+c1, +s1, +s1, +c1} - shufps xmm2,xmm2,0xBB ; = {f3, g3, f3, g3} - mulps xmm2,xmm7 ; *= {-s1, -c1, +c1, +s1} - addps xmm1,xmm2 ; = {d, b, c, a} - movaps xmm2,xmm3 - addps xmm3,xmm1 ; = {fi[k1], gi[k1], gi[0], fi[0]} - subps xmm2,xmm1 ; = {fi[k3], gi[k3], gi[k1*2], fi[k1*2]} - movhlps xmm0,xmm3 - movss [esi],xmm3 - shufps xmm3,xmm3,0x55 - movss [edi+eax*2],xmm0 - shufps xmm0,xmm0,0x55 - movss [edi],xmm3 - movss [esi+eax*2],xmm0 - movhlps xmm0,xmm2 - movss [esi+eax*4],xmm2 - shufps xmm2,xmm2,0x55 - movss [edi+edx*2],xmm0 - shufps xmm0,xmm0,0x55 - movss [edi+eax*4],xmm2 - movss [esi+edx*2],xmm0 - lea esi,[esi + eax*8] ; fi += (k1 * 4); - cmp esi,[esp] - jl near .lp21 ; while (fi {c3, s3, s3, c3} - jl near .lp22 -; } -.F22: - shl eax,2 - add ecx, byte 8 - cmp eax,[esp+_P+8] ; while ((k1 * 4) define WIN32 -; Borland or cygwin -> WIN32 and COFF -; for FreeBSD 2.x -> AOUT -; for TownsOS -> __tos__ -; otherwise -> none - -;̾����դ��� - -BITS 32 - -section .note.GNU-stack noalloc noexec nowrite progbits - -%ifdef YASM - %define segment_code segment .text align=16 use32 - %define segment_data segment .data align=16 use32 - %define segment_bss segment .bss align=16 use32 -%elifdef WIN32 - %define segment_code segment .text align=16 class=CODE use32 - %define segment_data segment .data align=16 class=DATA use32 -%ifdef __BORLANDC__ - %define segment_bss segment .data align=16 class=DATA use32 -%else - %define segment_bss segment .bss align=16 class=DATA use32 -%endif -%elifdef AOUT - %define _NAMING - %define segment_code segment .text - %define segment_data segment .data - %define segment_bss segment .bss -%else -%ifidn __OUTPUT_FORMAT__,elf - section .note.GNU-stack progbits noalloc noexec nowrite align=1 -%endif - %define segment_code segment .text align=16 class=CODE use32 - %define segment_data segment .data align=16 class=DATA use32 - %define segment_bss segment .bss align=16 class=DATA use32 -%endif - -%ifdef WIN32 - %define _NAMING -%endif - -%ifdef __tos__ -group CGROUP text -group DGROUP data -%endif - -;ñ�����ư�������� - -%idefine float dword -%idefine fsize 4 -%idefine fsizen(a) (fsize*(a)) - -;��ɷ�� - -%idefine wsize 2 -%idefine wsizen(a) (wsize*(a)) -%idefine dwsize 4 -%idefine dwsizen(a) (dwsize*(a)) - -;REG - -%define r0 eax -%define r1 ebx -%define r2 ecx -%define r3 edx -%define r4 esi -%define r5 edi -%define r6 ebp -%define r7 esp - -;MMX,3DNow!,SSE - -%define pmov movq -%define pmovd movd - -%define pupldq punpckldq -%define puphdq punpckhdq -%define puplwd punpcklwd -%define puphwd punpckhwd - -%define xm0 xmm0 -%define xm1 xmm1 -%define xm2 xmm2 -%define xm3 xmm3 -%define xm4 xmm4 -%define xm5 xmm5 -%define xm6 xmm6 -%define xm7 xmm7 - -;�����åե��Ѥ�4�ʥޥ��� - -%define R4(a,b,c,d) (a*64+b*16+c*4+d) - -;C�饤���ʴʰץޥ��� - -%imacro globaldef 1 - %ifdef _NAMING - %define %1 _%1 - %endif - global %1 -%endmacro - -%imacro externdef 1 - %ifdef _NAMING - %define %1 _%1 - %endif - extern %1 -%endmacro - -%imacro proc 1 - %push proc - %ifdef _NAMING - global _%1 - %else - global %1 - %endif - - align 32 -%1: -_%1: - - %assign %$STACK 0 - %assign %$STACKN 0 - %assign %$ARG 4 -%endmacro - -%imacro endproc 0 - %ifnctx proc - %error expected 'proc' before 'endproc'. - %else - %if %$STACK > 0 - add esp, %$STACK - %endif - - %if %$STACK <> (-%$STACKN) - %error STACKLEVEL mismatch check 'local', 'alloc', 'pushd', 'popd' - %endif - - ret - %pop - %endif -%endmacro - -%idefine sp(a) esp+%$STACK+a - -%imacro arg 1 - %00 equ %$ARG - %assign %$ARG %$ARG+%1 -%endmacro - -%imacro local 1 - %assign %$STACKN %$STACKN-%1 - %00 equ %$STACKN -%endmacro - -%imacro alloc 0 - sub esp, (-%$STACKN)-%$STACK - %assign %$STACK (-%$STACKN) -%endmacro - -%imacro pushd 1-* - %rep %0 - push %1 - %assign %$STACK %$STACK+4 - %rotate 1 - %endrep -%endmacro - -%imacro popd 1-* - %rep %0 - %rotate -1 - pop %1 - %assign %$STACK %$STACK-4 - %endrep -%endmacro - -; bug of NASM-0.98 -%define pushf db 0x66, 0x9C -%define popf db 0x66, 0x9D - -%define ge16(n) ((((n) / 16)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge15(n) ((((n) / 15)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge14(n) ((((n) / 14)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge13(n) ((((n) / 13)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge12(n) ((((n) / 12)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge11(n) ((((n) / 11)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge10(n) ((((n) / 10)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge9(n) ((((n) / 9)*0xFFFFFFFF) & 0xFFFFFFFF) -%define ge8(n) (ge9(n) | ((((n) / 8)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge7(n) (ge9(n) | ((((n) / 7)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge6(n) (ge9(n) | ((((n) / 6)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge5(n) (ge9(n) | ((((n) / 5)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge4(n) (ge5(n) | ((((n) / 4)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge3(n) (ge5(n) | ((((n) / 3)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge2(n) (ge3(n) | ((((n) / 2)*0xFFFFFFFF) & 0xFFFFFFFF)) -%define ge1(n) (ge2(n) | ((((n) / 1)*0xFFFFFFFF) & 0xFFFFFFFF)) - -; macro to align for begining of loop -; %1 does not align if it LE bytes to next alignment -; 4..16 -; default is 12 - -%imacro loopalignK6 0-1 12 -%%here: - times (($$-%%here) & 15 & ge1(($$-%%here) & 15) & ~ge4(($$-%%here) & 15)) nop - times (1 & ge4(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) jmp short %%skip - times (((($$-%%here) & 15)-2) & ge4(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) nop -%%skip: -%endmacro - -%imacro loopalignK7 0-1 12 -%%here: - times (1 & ge1(($$-%%here) & 15) & ~ge2(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) nop - times (1 & ge2(($$-%%here) & 15) & ~ge3(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Bh,0C0h - times (1 & ge3(($$-%%here) & 15) & ~ge4(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,004h,020h - times (1 & ge4(($$-%%here) & 15) & ~ge5(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,044h,020h,000h - times (1 & ge5(($$-%%here) & 15) & ~ge6(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,044h,020h,000h,090h - times (1 & ge6(($$-%%here) & 15) & ~ge7(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,080h,0,0,0,0 - times (1 & ge7(($$-%%here) & 15) & ~ge8(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,004h,005h,0,0,0,0 - times (1 & ge8(($$-%%here) & 15) & ~ge9(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 08Dh,004h,005h,0,0,0,0,90h - times (1 & ge9(($$-%%here) & 15) & ~ge10(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,007h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge10(($$-%%here) & 15) & ~ge11(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,008h,90h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge11(($$-%%here) & 15) & ~ge12(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,009h,90h,90h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge12(($$-%%here) & 15) & ~ge13(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,00Ah,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge13(($$-%%here) & 15) & ~ge14(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,00Bh,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge14(($$-%%here) & 15) & ~ge15(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,00Ch,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h - times (1 & ge15(($$-%%here) & 15) & ~ge16(($$-%%here) & 15) & ~ge%1(($$-%%here) & 15)) DB 0EBh,00Dh,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h,90h -%%skip: -%endmacro - -%imacro loopalign 0-1 12 - loopalignK7 %1 -%endmacro -%define PACK(x,y,z,w) (x*64+y*16+z*4+w) - -%ifidn __OUTPUT_FORMAT__,elf - -%idefine PIC_BASE(A) _GLOBAL_OFFSET_TABLE_ + $$ - $ wrt ..gotpc -%idefine PIC_EBP_REL(A) ebp + A wrt ..gotoff -%macro PIC_OFFSETTABLE 0 -extern _GLOBAL_OFFSET_TABLE_ -get_pc.bp: - mov ebp, [esp] - retn -%endmacro - -%else - -%define PIC_BASE(A) (0) -%define PIC_EBP_REL(A) (A) -%macro PIC_OFFSETTABLE 0 -get_pc.bp: - mov ebp, [esp] - retn -%endmacro - -%endif diff --git a/lib-src/lame/libmp3lame/i386/scalar.nas b/lib-src/lame/libmp3lame/i386/scalar.nas deleted file mode 100644 index 6d69f429a..000000000 --- a/lib-src/lame/libmp3lame/i386/scalar.nas +++ /dev/null @@ -1,1022 +0,0 @@ -; -; (C) Frank Klemm 1995,99,2000 -; Dedicated to the LAME project -; -; - %include "nasm.h" - - segment_code - -; float_t scalar04_float32_i387 ( -; const float32_t* const p, -; const float32_t* const q ); - -proc scalar04_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 -endproc - - -proc scalar08_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 -endproc - - -proc scalar12_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 - fld dword [eax + 32] - fmul dword [edx + 32] - faddp st1,st0 - fld dword [eax + 36] - fmul dword [edx + 36] - faddp st1,st0 - fld dword [eax + 40] - fmul dword [edx + 40] - faddp st1,st0 - fld dword [eax + 44] - fmul dword [edx + 44] - faddp st1,st0 -endproc - - -proc scalar16_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 - fld dword [eax + 32] - fmul dword [edx + 32] - faddp st1,st0 - fld dword [eax + 36] - fmul dword [edx + 36] - faddp st1,st0 - fld dword [eax + 40] - fmul dword [edx + 40] - faddp st1,st0 - fld dword [eax + 44] - fmul dword [edx + 44] - faddp st1,st0 - fld dword [eax + 48] - fmul dword [edx + 48] - faddp st1,st0 - fld dword [eax + 52] - fmul dword [edx + 52] - faddp st1,st0 - fld dword [eax + 56] - fmul dword [edx + 56] - faddp st1,st0 - fld dword [eax + 60] - fmul dword [edx + 60] - faddp st1,st0 -endproc - - -proc scalar20_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 - fld dword [eax + 32] - fmul dword [edx + 32] - faddp st1,st0 - fld dword [eax + 36] - fmul dword [edx + 36] - faddp st1,st0 - fld dword [eax + 40] - fmul dword [edx + 40] - faddp st1,st0 - fld dword [eax + 44] - fmul dword [edx + 44] - faddp st1,st0 - fld dword [eax + 48] - fmul dword [edx + 48] - faddp st1,st0 - fld dword [eax + 52] - fmul dword [edx + 52] - faddp st1,st0 - fld dword [eax + 56] - fmul dword [edx + 56] - faddp st1,st0 - fld dword [eax + 60] - fmul dword [edx + 60] - faddp st1,st0 - fld dword [eax + 64] - fmul dword [edx + 64] - faddp st1,st0 - fld dword [eax + 68] - fmul dword [edx + 68] - faddp st1,st0 - fld dword [eax + 72] - fmul dword [edx + 72] - faddp st1,st0 - fld dword [eax + 76] - fmul dword [edx + 76] - faddp st1,st0 -endproc - - -proc scalar24_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 - fld dword [eax + 32] - fmul dword [edx + 32] - faddp st1,st0 - fld dword [eax + 36] - fmul dword [edx + 36] - faddp st1,st0 - fld dword [eax + 40] - fmul dword [edx + 40] - faddp st1,st0 - fld dword [eax + 44] - fmul dword [edx + 44] - faddp st1,st0 - fld dword [eax + 48] - fmul dword [edx + 48] - faddp st1,st0 - fld dword [eax + 52] - fmul dword [edx + 52] - faddp st1,st0 - fld dword [eax + 56] - fmul dword [edx + 56] - faddp st1,st0 - fld dword [eax + 60] - fmul dword [edx + 60] - faddp st1,st0 - fld dword [eax + 64] - fmul dword [edx + 64] - faddp st1,st0 - fld dword [eax + 68] - fmul dword [edx + 68] - faddp st1,st0 - fld dword [eax + 72] - fmul dword [edx + 72] - faddp st1,st0 - fld dword [eax + 76] - fmul dword [edx + 76] - faddp st1,st0 - fld dword [eax + 80] - fmul dword [edx + 80] - faddp st1,st0 - fld dword [eax + 84] - fmul dword [edx + 84] - faddp st1,st0 - fld dword [eax + 88] - fmul dword [edx + 88] - faddp st1,st0 - fld dword [eax + 92] - fmul dword [edx + 92] - faddp st1,st0 -endproc - - -proc scalar32_float32_i387 -%$p arg 4 -%$q arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - fld dword [eax + 16] - fmul dword [edx + 16] - faddp st1,st0 - fld dword [eax + 20] - fmul dword [edx + 20] - faddp st1,st0 - fld dword [eax + 24] - fmul dword [edx + 24] - faddp st1,st0 - fld dword [eax + 28] - fmul dword [edx + 28] - faddp st1,st0 - fld dword [eax + 32] - fmul dword [edx + 32] - faddp st1,st0 - fld dword [eax + 36] - fmul dword [edx + 36] - faddp st1,st0 - fld dword [eax + 40] - fmul dword [edx + 40] - faddp st1,st0 - fld dword [eax + 44] - fmul dword [edx + 44] - faddp st1,st0 - fld dword [eax + 48] - fmul dword [edx + 48] - faddp st1,st0 - fld dword [eax + 52] - fmul dword [edx + 52] - faddp st1,st0 - fld dword [eax + 56] - fmul dword [edx + 56] - faddp st1,st0 - fld dword [eax + 60] - fmul dword [edx + 60] - faddp st1,st0 - fld dword [eax + 64] - fmul dword [edx + 64] - faddp st1,st0 - fld dword [eax + 68] - fmul dword [edx + 68] - faddp st1,st0 - fld dword [eax + 72] - fmul dword [edx + 72] - faddp st1,st0 - fld dword [eax + 76] - fmul dword [edx + 76] - faddp st1,st0 - fld dword [eax + 80] - fmul dword [edx + 80] - faddp st1,st0 - fld dword [eax + 84] - fmul dword [edx + 84] - faddp st1,st0 - fld dword [eax + 88] - fmul dword [edx + 88] - faddp st1,st0 - fld dword [eax + 92] - fmul dword [edx + 92] - faddp st1,st0 - fld dword [eax + 96] - fmul dword [edx + 96] - faddp st1,st0 - fld dword [eax +100] - fmul dword [edx +100] - faddp st1,st0 - fld dword [eax +104] - fmul dword [edx +104] - faddp st1,st0 - fld dword [eax +108] - fmul dword [edx +108] - faddp st1,st0 - fld dword [eax +112] - fmul dword [edx +112] - faddp st1,st0 - fld dword [eax +116] - fmul dword [edx +116] - faddp st1,st0 - fld dword [eax +120] - fmul dword [edx +120] - faddp st1,st0 - fld dword [eax +124] - fmul dword [edx +124] - faddp st1,st0 -endproc - - -; float_t scalar4n_float32_i387 ( -; const float32_t* const p, -; const float32_t* const q, -; const size_t len ); - -proc scalar4n_float32_i387 -%$p arg 4 -%$q arg 4 -%$len arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - mov ecx,[sp(%$len)] - fld dword [eax] - fmul dword [edx] - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - dec ecx - jz .ret1 - add eax,byte 16 - add edx,byte 16 -.lbl1 - fld dword [eax] - fmul dword [edx] - faddp st1,st0 - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - add eax,byte 16 - add edx,byte 16 - dec ecx - jnz .lbl1 -.ret1 -endproc - - -; float_t scalar1n_float32_i387 ( -; const float32_t* const p, -; const float32_t* const q, -; const size_t len ); - -proc scalar1n_float32_i387 -%$p arg 4 -%$q arg 4 -%$len arg 4 -;;; alloc - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - mov ecx,[sp(%$len)] - fld0 - shr ecx,1 - jnc .lbl2 - fld dword [eax] - fmul dword [edx] - faddp st1,st0 - add eax,byte 4 - add edx,byte 4 -.lbl2 - shr ecx,1 - jnc .lbl3 - fld dword [eax] - fmul dword [edx] - faddp st1,st0 - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - add eax,byte 8 - add edx,byte 8 - and ecx,ecx -.lbl3 - jz .ret2 -.lbl4 - fld dword [eax] - fmul dword [edx] - faddp st1,st0 - fld dword [eax + 4] - fmul dword [edx + 4] - faddp st1,st0 - fld dword [eax + 8] - fmul dword [edx + 8] - faddp st1,st0 - fld dword [eax + 12] - fmul dword [edx + 12] - faddp st1,st0 - add eax,byte 16 - add edx,byte 16 - dec ecx - jnz .lbl4 -.ret2 -endproc - - -proc scalar04_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar08_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar12_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+32] - pmov mm3,qword [eax+40] - pfmul mm2,qword [edx+32] - pfmul mm3,qword [edx+40] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar16_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+32] - pmov mm3,qword [eax+40] - pfmul mm2,qword [edx+32] - pfmul mm3,qword [edx+40] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+48] - pmov mm3,qword [eax+56] - pfmul mm2,qword [edx+48] - pfmul mm3,qword [edx+56] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar20_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+32] - pmov mm3,qword [eax+40] - pfmul mm2,qword [edx+32] - pfmul mm3,qword [edx+40] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+48] - pmov mm3,qword [eax+56] - pfmul mm2,qword [edx+48] - pfmul mm3,qword [edx+56] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+64] - pmov mm3,qword [eax+72] - pfmul mm2,qword [edx+64] - pfmul mm3,qword [edx+72] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar24_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+32] - pmov mm3,qword [eax+40] - pfmul mm2,qword [edx+32] - pfmul mm3,qword [edx+40] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+48] - pmov mm3,qword [eax+56] - pfmul mm2,qword [edx+48] - pfmul mm3,qword [edx+56] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+64] - pmov mm3,qword [eax+72] - pfmul mm2,qword [edx+64] - pfmul mm3,qword [edx+72] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+80] - pmov mm3,qword [eax+88] - pfmul mm2,qword [edx+80] - pfmul mm3,qword [edx+88] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - -proc scalar32_float32_3DNow -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - - pmov mm2,qword [eax+16] - pmov mm3,qword [eax+24] - pfmul mm2,qword [edx+16] - pfmul mm3,qword [edx+24] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+32] - pmov mm3,qword [eax+40] - pfmul mm2,qword [edx+32] - pfmul mm3,qword [edx+40] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+48] - pmov mm3,qword [eax+56] - pfmul mm2,qword [edx+48] - pfmul mm3,qword [edx+56] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+64] - pmov mm3,qword [eax+72] - pfmul mm2,qword [edx+64] - pfmul mm3,qword [edx+72] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+80] - pmov mm3,qword [eax+88] - pfmul mm2,qword [edx+80] - pfmul mm3,qword [edx+88] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+96] - pmov mm3,qword [eax+104] - pfmul mm2,qword [edx+96] - pfmul mm3,qword [edx+104] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pmov mm2,qword [eax+112] - pmov mm3,qword [eax+120] - pfmul mm2,qword [edx+112] - pfmul mm3,qword [edx+120] - pfadd mm0,mm2 - pfadd mm1,mm3 - - pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar4n_float32_3DNow -%$p arg 4 -%$q arg 4 -%$len arg 4 - - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - mov ecx,[sp(%$len)] - - pmov mm0,qword [eax] - pmov mm1,qword [eax+8] - pfmul mm0,qword [edx] - pfmul mm1,qword [edx+8] - dec ecx - jz .ret4 - - add eax,byte 16 - add edx,byte 16 -.lbl4: - pmov mm2,qword [eax] - pmov mm3,qword [eax+8] - pfmul mm2,qword [edx] - pfmul mm3,qword [edx+8] - add eax,byte 16 - add edx,byte 16 - pfadd mm0,mm2 - pfadd mm1,mm3 - dec ecx - jnz .lbl4 - -.ret4: pfadd mm0,mm1 - pmov qword [sp(%$p)],mm0 - femms - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar1n_float32_3DNow - jmp scalar24_float32_i387 -endproc - - -proc scalar04_float32_SIMD - jmp scalar04_float32_i387 -endproc - - -proc scalar08_float32_SIMD -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - movups xmm0, [eax] - movups xmm1, [eax+16] - mulps xmm0, [edx] - mulps xmm1, [edx+16] - - addps xmm0,xmm1 - sub esp,16 - movups [esp],xmm0 - fld dword [esp+ 0] - fadd dword [esp+ 4] - fadd dword [esp+ 8] - fadd dword [esp+12] - add esp,16 -endproc - - -proc scalar12_float32_SIMD - jmp scalar12_float32_i387 -endproc - - -proc scalar16_float32_SIMD -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - movups xmm0, [eax] - movups xmm1, [eax+16] - mulps xmm0, [edx] - mulps xmm1, [edx+16] - - movups xmm2, [eax+32] - movups xmm3, [eax+48] - mulps xmm2, [edx+32] - mulps xmm3, [edx+48] - addps xmm0,xmm2 - addps xmm1,xmm3 - - addps xmm0,xmm1 - sub esp,16 - movups [esp],xmm0 - fld dword [esp+ 0] - fadd dword [esp+ 4] - fadd dword [esp+ 8] - fadd dword [esp+12] - add esp,16 -endproc - - -proc scalar20_float32_SIMD - jmp scalar20_float32_i387 -endproc - - -proc scalar24_float32_SIMD -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - movups xmm0, [eax] - movups xmm1, [eax+16] - mulps xmm0, [edx] - mulps xmm1, [edx+16] - - movups xmm2, [eax+32] - movups xmm3, [eax+48] - mulps xmm2, [edx+32] - mulps xmm3, [edx+48] - addps xmm0,xmm2 - addps xmm1,xmm3 - - movups xmm2, [eax+64] - movups xmm3, [eax+80] - mulps xmm2, [edx+64] - mulps xmm3, [edx+80] - addps xmm0,xmm2 - addps xmm1,xmm3 - - addps xmm0,xmm1 - sub esp,16 - movups [esp],xmm0 - fld dword [esp+ 0] - fadd dword [esp+ 4] - fadd dword [esp+ 8] - fadd dword [esp+12] - add esp,16 -endproc - - -proc scalar32_float32_SIMD -%$p arg 4 -%$q arg 4 - mov eax,[sp(%$p)] - mov edx,[sp(%$q)] - - movups xmm0, [eax] - movups xmm1, [eax+16] - mulps xmm0, [edx] - mulps xmm1, [edx+16] - - movups xmm2, [eax+32] - movups xmm3, [eax+48] - mulps xmm2, [edx+32] - mulps xmm3, [edx+48] - addps xmm0,xmm2 - addps xmm1,xmm3 - - movups xmm2, [eax+64] - movups xmm3, [eax+80] - mulps xmm2, [edx+64] - mulps xmm3, [edx+80] - addps xmm0,xmm2 - addps xmm1,xmm3 - - movups xmm2, [eax+96] - movups xmm3, [eax+112] - mulps xmm2, [edx+96] - mulps xmm3, [edx+112] - addps xmm0,xmm2 - addps xmm1,xmm3 - - addps xmm0,xmm1 - - ;sub esp,16 - ;movups [esp],xmm0 - ;fld dword [esp+ 0] - ;fadd dword [esp+ 4] - ;fadd dword [esp+ 8] - ;fadd dword [esp+12] - ;add esp,16 - - movhlps xmm1,xmm0 - addps xmm0,xmm1 - movlps [sp(%$p)],xmm0 - fld dword [sp(%$p)] - fadd dword [sp(%$p)+4] -endproc - - -proc scalar4n_float32_SIMD - jmp scalar4n_float32_i387 -endproc - - -proc scalar1n_float32_SIMD - jmp scalar1n_float32_i387 -endproc - -; end of scalar.nas diff --git a/lib-src/lame/libmp3lame/id3tag.c b/lib-src/lame/libmp3lame/id3tag.c deleted file mode 100644 index ac4851035..000000000 --- a/lib-src/lame/libmp3lame/id3tag.c +++ /dev/null @@ -1,1926 +0,0 @@ -/* - * id3tag.c -- Write ID3 version 1 and 2 tags. - * - * Copyright (C) 2000 Don Melton - * Copyright (C) 2011-2017 Robert Hegemann - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. - */ - -/* - * HISTORY: This source file is part of LAME (see http://www.mp3dev.org) - * and was originally adapted by Conrad Sanderson - * from mp3info by Ricardo Cerqueira to write only ID3 version 1 - * tags. Don Melton COMPLETELY rewrote it to support version - * 2 tags and be more conformant to other standards while remaining flexible. - * - * NOTE: See http://id3.org/ for more information about ID3 tag formats. - */ - -/* $Id: id3tag.c,v 1.80 2017/08/28 15:39:51 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -#include -#endif - -#ifdef STDC_HEADERS -# include -# include -# include -# include -#else -# ifndef HAVE_STRCHR -# define strchr index -# define strrchr rindex -# endif -char *strchr(), *strrchr(); -# ifndef HAVE_MEMCPY -# define memcpy(d, s, n) bcopy ((s), (d), (n)) -# endif -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "id3tag.h" -#include "lame_global_flags.h" -#include "util.h" -#include "bitstream.h" - - -static const char *const genre_names[] = { - /* - * NOTE: The spelling of these genre names is identical to those found in - * Winamp and mp3info. - */ - "Blues", "Classic Rock", "Country", "Dance", "Disco", "Funk", "Grunge", - "Hip-Hop", "Jazz", "Metal", "New Age", "Oldies", "Other", "Pop", "R&B", - "Rap", "Reggae", "Rock", "Techno", "Industrial", "Alternative", "Ska", - "Death Metal", "Pranks", "Soundtrack", "Euro-Techno", "Ambient", "Trip-Hop", - "Vocal", "Jazz+Funk", "Fusion", "Trance", "Classical", "Instrumental", - "Acid", "House", "Game", "Sound Clip", "Gospel", "Noise", "Alternative Rock", - "Bass", "Soul", "Punk", "Space", "Meditative", "Instrumental Pop", - "Instrumental Rock", "Ethnic", "Gothic", "Darkwave", "Techno-Industrial", - "Electronic", "Pop-Folk", "Eurodance", "Dream", "Southern Rock", "Comedy", - "Cult", "Gangsta", "Top 40", "Christian Rap", "Pop/Funk", "Jungle", - "Native US", "Cabaret", "New Wave", "Psychedelic", "Rave", - "Showtunes", "Trailer", "Lo-Fi", "Tribal", "Acid Punk", "Acid Jazz", - "Polka", "Retro", "Musical", "Rock & Roll", "Hard Rock", "Folk", - "Folk-Rock", "National Folk", "Swing", "Fast Fusion", "Bebob", "Latin", - "Revival", "Celtic", "Bluegrass", "Avantgarde", "Gothic Rock", - "Progressive Rock", "Psychedelic Rock", "Symphonic Rock", "Slow Rock", - "Big Band", "Chorus", "Easy Listening", "Acoustic", "Humour", "Speech", - "Chanson", "Opera", "Chamber Music", "Sonata", "Symphony", "Booty Bass", - "Primus", "Porn Groove", "Satire", "Slow Jam", "Club", "Tango", "Samba", - "Folklore", "Ballad", "Power Ballad", "Rhythmic Soul", "Freestyle", "Duet", - "Punk Rock", "Drum Solo", "A Cappella", "Euro-House", "Dance Hall", - "Goa", "Drum & Bass", "Club-House", "Hardcore", "Terror", "Indie", - "BritPop", "Negerpunk", "Polsk Punk", "Beat", "Christian Gangsta", - "Heavy Metal", "Black Metal", "Crossover", "Contemporary Christian", - "Christian Rock", "Merengue", "Salsa", "Thrash Metal", "Anime", "JPop", - "SynthPop" -}; - -#define GENRE_NAME_COUNT \ - ((int)(sizeof genre_names / sizeof (const char *const))) - -static const int genre_alpha_map[] = { - 123, 34, 74, 73, 99, 20, 40, 26, 145, 90, 116, 41, 135, 85, 96, 138, 89, 0, - 107, 132, 65, 88, 104, 102, 97, 136, 61, 141, 32, 1, 112, 128, 57, 140, 2, - 139, 58, 3, 125, 50, 22, 4, 55, 127, 122, 120, 98, 52, 48, 54, 124, 25, 84, - 80, 115, 81, 119, 5, 30, 36, 59, 126, 38, 49, 91, 6, 129, 79, 137, 7, 35, - 100, 131, 19, 33, 46, 47, 8, 29, 146, 63, 86, 71, 45, 142, 9, 77, 82, 64, - 133, 10, 66, 39, 11, 103, 12, 75, 134, 13, 53, 62, 109, 117, 23, 108, 92, - 67, 93, 43, 121, 15, 68, 14, 16, 76, 87, 118, 17, 78, 143, 114, 110, 69, 21, - 111, 95, 105, 42, 37, 24, 56, 44, 101, 83, 94, 106, 147, 113, 18, 51, 130, - 144, 60, 70, 31, 72, 27, 28 -}; - -#define GENRE_ALPHA_COUNT ((int)(sizeof genre_alpha_map / sizeof (int))) - -#define GENRE_INDEX_OTHER 12 - - -#define FRAME_ID(a, b, c, d) \ - ( ((unsigned long)(a) << 24) \ - | ((unsigned long)(b) << 16) \ - | ((unsigned long)(c) << 8) \ - | ((unsigned long)(d) << 0) ) - -typedef enum UsualStringIDs { ID_TITLE = FRAME_ID('T', 'I', 'T', '2') - , ID_ARTIST = FRAME_ID('T', 'P', 'E', '1') - , ID_ALBUM = FRAME_ID('T', 'A', 'L', 'B') - , ID_GENRE = FRAME_ID('T', 'C', 'O', 'N') - , ID_ENCODER = FRAME_ID('T', 'S', 'S', 'E') - , ID_PLAYLENGTH = FRAME_ID('T', 'L', 'E', 'N') - , ID_COMMENT = FRAME_ID('C', 'O', 'M', 'M') /* full text string */ -} UsualStringIDs; - -typedef enum NumericStringIDs { ID_DATE = FRAME_ID('T', 'D', 'A', 'T') /* "ddMM" */ - , ID_TIME = FRAME_ID('T', 'I', 'M', 'E') /* "hhmm" */ - , ID_TPOS = FRAME_ID('T', 'P', 'O', 'S') /* '0'-'9' and '/' allowed */ - , ID_TRACK = FRAME_ID('T', 'R', 'C', 'K') /* '0'-'9' and '/' allowed */ - , ID_YEAR = FRAME_ID('T', 'Y', 'E', 'R') /* "yyyy" */ -} NumericStringIDs; - -typedef enum MiscIDs { ID_TXXX = FRAME_ID('T', 'X', 'X', 'X') - , ID_WXXX = FRAME_ID('W', 'X', 'X', 'X') - , ID_SYLT = FRAME_ID('S', 'Y', 'L', 'T') - , ID_APIC = FRAME_ID('A', 'P', 'I', 'C') - , ID_GEOB = FRAME_ID('G', 'E', 'O', 'B') - , ID_PCNT = FRAME_ID('P', 'C', 'N', 'T') - , ID_AENC = FRAME_ID('A', 'E', 'N', 'C') - , ID_LINK = FRAME_ID('L', 'I', 'N', 'K') - , ID_ENCR = FRAME_ID('E', 'N', 'C', 'R') - , ID_GRID = FRAME_ID('G', 'R', 'I', 'D') - , ID_PRIV = FRAME_ID('P', 'R', 'I', 'V') - , ID_USLT = FRAME_ID('U', 'S', 'L', 'T') /* full text string */ - , ID_USER = FRAME_ID('U', 'S', 'E', 'R') /* full text string */ - , ID_PCST = FRAME_ID('P', 'C', 'S', 'T') /* iTunes Podcast indicator, only presence important */ - , ID_WFED = FRAME_ID('W', 'F', 'E', 'D') /* iTunes Podcast URL as TEXT FRAME !!! violates standard */ -} MiscIDs; - - -static int -frame_id_matches(int id, int mask) -{ - int result = 0, i, window = 0xff; - for (i = 0; i < 4; ++i, window <<= 8) { - int const mw = (mask & window); - int const iw = (id & window); - if (mw != 0 && mw != iw) { - result |= iw; - } - } - return result; -} - -static int -isFrameIdMatching(int id, int mask) -{ - return frame_id_matches(id, mask) == 0 ? 1 : 0; -} - -static int -test_tag_spec_flags(lame_internal_flags const *gfc, unsigned int tst) -{ - return (gfc->tag_spec.flags & tst) != 0u ? 1 : 0; -} - -#if 0 -static void -debug_tag_spec_flags(lame_internal_flags * gfc, const char* info) -{ - MSGF(gfc, "%s\n", info); - MSGF(gfc, "CHANGED_FLAG : %d\n", test_tag_spec_flags(gfc, CHANGED_FLAG )); - MSGF(gfc, "ADD_V2_FLAG : %d\n", test_tag_spec_flags(gfc, ADD_V2_FLAG )); - MSGF(gfc, "V1_ONLY_FLAG : %d\n", test_tag_spec_flags(gfc, V1_ONLY_FLAG )); - MSGF(gfc, "V2_ONLY_FLAG : %d\n", test_tag_spec_flags(gfc, V2_ONLY_FLAG )); - MSGF(gfc, "SPACE_V1_FLAG : %d\n", test_tag_spec_flags(gfc, SPACE_V1_FLAG)); - MSGF(gfc, "PAD_V2_FLAG : %d\n", test_tag_spec_flags(gfc, PAD_V2_FLAG )); -} -#endif - -static int -is_lame_internal_flags_null(lame_t gfp) -{ - return (gfp && gfp->internal_flags) ? 0 : 1; -} - -static int -id3v2_add_ucs2_lng(lame_t gfp, uint32_t frame_id, unsigned short const *desc, unsigned short const *text); -static int -id3v2_add_latin1_lng(lame_t gfp, uint32_t frame_id, char const *desc, char const *text); - - -static void -copyV1ToV2(lame_t gfp, int frame_id, char const *s) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc != 0) { - unsigned int flags = gfc->tag_spec.flags; - id3v2_add_latin1_lng(gfp, frame_id, 0, s); - gfc->tag_spec.flags = flags; -#if 0 - debug_tag_spec_flags(gfc, "copyV1ToV2"); -#endif - } -} - - -static void -id3v2AddLameVersion(lame_t gfp) -{ - char buffer[1024]; - const char *b = get_lame_os_bitness(); - const char *v = get_lame_version(); - const char *u = get_lame_url(); - const size_t lenb = strlen(b); - - if (lenb > 0) { - sprintf(buffer, "LAME %s version %s (%s)", b, v, u); - } - else { - sprintf(buffer, "LAME version %s (%s)", v, u); - } - copyV1ToV2(gfp, ID_ENCODER, buffer); -} - -static void -id3v2AddAudioDuration(lame_t gfp, double ms) -{ - SessionConfig_t const *const cfg = &gfp->internal_flags->cfg; /* caller checked pointers */ - char buffer[1024]; - double const max_ulong = MAX_U_32_NUM; - unsigned long playlength_ms; - - ms *= 1000; - ms /= cfg->samplerate_in; - if (ms > max_ulong) { - playlength_ms = max_ulong; - } - else if (ms < 0) { - playlength_ms = 0; - } - else { - playlength_ms = ms; - } - sprintf(buffer, "%lu", playlength_ms); - copyV1ToV2(gfp, ID_PLAYLENGTH, buffer); -} - -void -id3tag_genre_list(void (*handler) (int, const char *, void *), void *cookie) -{ - if (handler) { - int i; - for (i = 0; i < GENRE_NAME_COUNT; ++i) { - if (i < GENRE_ALPHA_COUNT) { - int j = genre_alpha_map[i]; - handler(j, genre_names[j], cookie); - } - } - } -} - -#define GENRE_NUM_UNKNOWN 255 - - - -void -id3tag_init(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - free_id3tag(gfc); - memset(&gfc->tag_spec, 0, sizeof gfc->tag_spec); - gfc->tag_spec.genre_id3v1 = GENRE_NUM_UNKNOWN; - gfc->tag_spec.padding_size = 128; - id3v2AddLameVersion(gfp); -} - - - -void -id3tag_add_v2(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - gfc->tag_spec.flags &= ~V1_ONLY_FLAG; - gfc->tag_spec.flags |= ADD_V2_FLAG; -} - -void -id3tag_v1_only(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - gfc->tag_spec.flags &= ~(ADD_V2_FLAG | V2_ONLY_FLAG); - gfc->tag_spec.flags |= V1_ONLY_FLAG; -} - -void -id3tag_v2_only(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - gfc->tag_spec.flags &= ~V1_ONLY_FLAG; - gfc->tag_spec.flags |= V2_ONLY_FLAG; -} - -void -id3tag_space_v1(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - gfc->tag_spec.flags &= ~V2_ONLY_FLAG; - gfc->tag_spec.flags |= SPACE_V1_FLAG; -} - -void -id3tag_pad_v2(lame_t gfp) -{ - id3tag_set_pad(gfp, 128); -} - -void -id3tag_set_pad(lame_t gfp, size_t n) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return; - } - gfc = gfp->internal_flags; - gfc->tag_spec.flags &= ~V1_ONLY_FLAG; - gfc->tag_spec.flags |= PAD_V2_FLAG; - gfc->tag_spec.flags |= ADD_V2_FLAG; - gfc->tag_spec.padding_size = (unsigned int)n; -} - -static int -hasUcs2ByteOrderMarker(unsigned short bom) -{ - if (bom == 0xFFFEu || bom == 0xFEFFu) { - return 1; - } - return 0; -} - - -static unsigned short -swap_bytes(unsigned short w) -{ - return (0xff00u & (w << 8)) | (0x00ffu & (w >> 8)); -} - - -static unsigned short -toLittleEndian(unsigned short bom, unsigned short c) -{ - if (bom == 0xFFFEu) { - return swap_bytes(c); - } - return c; -} - -static unsigned short -fromLatin1Char(const unsigned short* s, unsigned short c) -{ - if (s[0] == 0xFFFEu) { - return swap_bytes(c); - } - return c; -} - - -static size_t -local_strdup(char **dst, const char *src) -{ - if (dst == 0) { - return 0; - } - free(*dst); - *dst = 0; - if (src != 0) { - size_t n; - for (n = 0; src[n] != 0; ++n) { /* calc src string length */ - } - if (n > 0) { /* string length without zero termination */ - assert(sizeof(*src) == sizeof(**dst)); - *dst = lame_calloc(char, n + 1); - if (*dst != 0) { - memcpy(*dst, src, n * sizeof(**dst)); - (*dst)[n] = 0; - return n; - } - } - } - return 0; -} - -static size_t -local_ucs2_strdup(unsigned short **dst, unsigned short const *src) -{ - if (dst == 0) { - return 0; - } - free(*dst); /* free old string pointer */ - *dst = 0; - if (src != 0) { - size_t n; - for (n = 0; src[n] != 0; ++n) { /* calc src string length */ - } - if (n > 0) { /* string length without zero termination */ - assert(sizeof(*src) >= 2); - assert(sizeof(*src) == sizeof(**dst)); - *dst = lame_calloc(unsigned short, n + 1); - if (*dst != 0) { - memcpy(*dst, src, n * sizeof(**dst)); - (*dst)[n] = 0; - return n; - } - } - } - return 0; -} - - -static size_t -local_ucs2_strlen(unsigned short const *s) -{ - size_t n = 0; - if (s != 0) { - while (*s++) { - ++n; - } - } - return n; -} - - -static size_t -local_ucs2_substr(unsigned short** dst, unsigned short const* src, size_t start, size_t end) -{ - size_t const len = 1 + 1 + ((start < end) ? (end - start) : 0); - size_t n = 0; - unsigned short *ptr = lame_calloc(unsigned short, len); - *dst = ptr; - if (ptr == 0 || src == 0) { - return 0; - } - if (hasUcs2ByteOrderMarker(src[0])) { - ptr[n++] = src[0]; - if (start == 0) { - ++start; - } - } - while (start < end) { - ptr[n++] = src[start++]; - } - ptr[n] = 0; - return n; -} - -static int -local_ucs2_pos(unsigned short const* str, unsigned short c) -{ - int i; - for (i = 0; str != 0 && str[i] != 0; ++i) { - if (str[i] == c) { - return i; - } - } - return -1; -} - -static int -local_char_pos(char const* str, char c) -{ - int i; - for (i = 0; str != 0 && str[i] != 0; ++i) { - if (str[i] == c) { - return i; - } - } - return -1; -} - -static int -maybeLatin1(unsigned short const* text) -{ - if (text) { - unsigned short bom = *text++; - while (*text) { - unsigned short c = toLittleEndian(bom, *text++); - if (c > 0x00fe) return 0; - } - } - return 1; -} - -static int searchGenre(char const* genre); -static int sloppySearchGenre(char const* genre); - -static int -lookupGenre(char const* genre) -{ - char *str; - int num = strtol(genre, &str, 10); - /* is the input a string or a valid number? */ - if (*str) { - num = searchGenre(genre); - if (num == GENRE_NAME_COUNT) { - num = sloppySearchGenre(genre); - } - if (num == GENRE_NAME_COUNT) { - return -2; /* no common genre text found */ - } - } - else { - if ((num < 0) || (num >= GENRE_NAME_COUNT)) { - return -1; /* number unknown */ - } - } - return num; -} - -static unsigned char * -writeLoBytes(unsigned char *frame, unsigned short const *str, size_t n); - -static char* -local_strdup_utf16_to_latin1(unsigned short const* utf16) -{ - size_t len = local_ucs2_strlen(utf16); - unsigned char* latin1 = lame_calloc(unsigned char, len+1); - writeLoBytes(latin1, utf16, len); - return (char*)latin1; -} - - -static int -id3tag_set_genre_utf16(lame_t gfp, unsigned short const* text) -{ - lame_internal_flags* gfc = gfp->internal_flags; - int ret; - if (text == 0) { - return -3; - } - if (!hasUcs2ByteOrderMarker(text[0])) { - return -3; - } - if (maybeLatin1(text)) { - char* latin1 = local_strdup_utf16_to_latin1(text); - int num = lookupGenre(latin1); - free(latin1); - if (num == -1) return -1; /* number out of range */ - if (num >= 0) { /* common genre found */ - gfc->tag_spec.flags |= CHANGED_FLAG; - gfc->tag_spec.genre_id3v1 = num; - copyV1ToV2(gfp, ID_GENRE, genre_names[num]); - return 0; - } - } - ret = id3v2_add_ucs2_lng(gfp, ID_GENRE, 0, text); - if (ret == 0) { - gfc->tag_spec.flags |= CHANGED_FLAG; - gfc->tag_spec.genre_id3v1 = GENRE_INDEX_OTHER; - } - return ret; -} - -/* -Some existing options for ID3 tag can be specified by --tv option -as follows. ---tt , --tv TIT2=value ---ta , --tv TPE1=value ---tl , --tv TALB=value ---ty , --tv TYER=value ---tn , --tv TRCK=value ---tg , --tv TCON=value -(although some are not exactly same)*/ - -int -id3tag_set_albumart(lame_t gfp, const char *image, size_t size) -{ - int mimetype = MIMETYPE_NONE; - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - gfc = gfp->internal_flags; - - if (image != 0) { - unsigned char const *data = (unsigned char const *) image; - /* determine MIME type from the actual image data */ - if (2 < size && data[0] == 0xFF && data[1] == 0xD8) { - mimetype = MIMETYPE_JPEG; - } - else if (4 < size && data[0] == 0x89 && strncmp((const char *) &data[1], "PNG", 3) == 0) { - mimetype = MIMETYPE_PNG; - } - else if (4 < size && strncmp((const char *) data, "GIF8", 4) == 0) { - mimetype = MIMETYPE_GIF; - } - else { - return -1; - } - } - if (gfc->tag_spec.albumart != 0) { - free(gfc->tag_spec.albumart); - gfc->tag_spec.albumart = 0; - gfc->tag_spec.albumart_size = 0; - gfc->tag_spec.albumart_mimetype = MIMETYPE_NONE; - } - if (size < 1 || mimetype == MIMETYPE_NONE) { - return 0; - } - gfc->tag_spec.albumart = lame_calloc(unsigned char, size); - if (gfc->tag_spec.albumart != 0) { - memcpy(gfc->tag_spec.albumart, image, size); - gfc->tag_spec.albumart_size = (unsigned int)size; - gfc->tag_spec.albumart_mimetype = mimetype; - gfc->tag_spec.flags |= CHANGED_FLAG; - id3tag_add_v2(gfp); - } - return 0; -} - -static unsigned char * -set_4_byte_value(unsigned char *bytes, uint32_t value) -{ - int i; - for (i = 3; i >= 0; --i) { - bytes[i] = value & 0xffUL; - value >>= 8; - } - return bytes + 4; -} - -static uint32_t -toID3v2TagId(char const *s) -{ - unsigned int i, x = 0; - if (s == 0) { - return 0; - } - for (i = 0; i < 4 && s[i] != 0; ++i) { - char const c = s[i]; - unsigned int const u = 0x0ff & c; - x <<= 8; - x |= u; - if (c < 'A' || 'Z' < c) { - if (c < '0' || '9' < c) { - return 0; - } - } - } - return x; -} - -static uint32_t -toID3v2TagId_ucs2(unsigned short const *s) -{ - unsigned int i, x = 0; - unsigned short bom = 0; - if (s == 0) { - return 0; - } - bom = s[0]; - if (hasUcs2ByteOrderMarker(bom)) { - ++s; - } - for (i = 0; i < 4 && s[i] != 0; ++i) { - unsigned short const c = toLittleEndian(bom, s[i]); - if (c < 'A' || 'Z' < c) { - if (c < '0' || '9' < c) { - return 0; - } - } - x <<= 8; - x |= c; - } - return x; -} - -#if 0 -static int -isNumericString(uint32_t frame_id) -{ - switch (frame_id) { - case ID_DATE: - case ID_TIME: - case ID_TPOS: - case ID_TRACK: - case ID_YEAR: - return 1; - } - return 0; -} -#endif - -static int -isMultiFrame(uint32_t frame_id) -{ - switch (frame_id) { - case ID_TXXX: - case ID_WXXX: - case ID_COMMENT: - case ID_SYLT: - case ID_APIC: - case ID_GEOB: - case ID_PCNT: - case ID_AENC: - case ID_LINK: - case ID_ENCR: - case ID_GRID: - case ID_PRIV: - return 1; - } - return 0; -} - -#if 0 -static int -isFullTextString(int frame_id) -{ - switch (frame_id) { - case ID_VSLT: - case ID_COMMENT: - return 1; - } - return 0; -} -#endif - -static FrameDataNode * -findNode(id3tag_spec const *tag, uint32_t frame_id, FrameDataNode const *last) -{ - FrameDataNode *node = last ? last->nxt : tag->v2_head; - while (node != 0) { - if (node->fid == frame_id) { - return node; - } - node = node->nxt; - } - return 0; -} - -static void -appendNode(id3tag_spec * tag, FrameDataNode * node) -{ - if (tag->v2_tail == 0 || tag->v2_head == 0) { - tag->v2_head = node; - tag->v2_tail = node; - } - else { - tag->v2_tail->nxt = node; - tag->v2_tail = node; - } -} - -static void -setLang(char *dst, char const *src) -{ - int i; - if (src == 0 || src[0] == 0) { - dst[0] = 'e'; - dst[1] = 'n'; - dst[2] = 'g'; - } - else { - for (i = 0; i < 3 && src && *src; ++i) { - dst[i] = src[i]; - } - for (; i < 3; ++i) { - dst[i] = ' '; - } - } -} - -static int -isSameLang(char const *l1, char const *l2) -{ - char d[3]; - int i; - setLang(d, l2); - for (i = 0; i < 3; ++i) { - char a = tolower(l1[i]); - char b = tolower(d[i]); - if (a < ' ') - a = ' '; - if (b < ' ') - b = ' '; - if (a != b) { - return 0; - } - } - return 1; -} - -static int -isSameDescriptor(FrameDataNode const *node, char const *dsc) -{ - size_t i; - if (node->dsc.enc == 1 && node->dsc.dim > 0) { - return 0; - } - for (i = 0; i < node->dsc.dim; ++i) { - if (!dsc || node->dsc.ptr.l[i] != dsc[i]) { - return 0; - } - } - return 1; -} - -static int -isSameDescriptorUcs2(FrameDataNode const *node, unsigned short const *dsc) -{ - size_t i; - if (node->dsc.enc != 1 && node->dsc.dim > 0) { - return 0; - } - for (i = 0; i < node->dsc.dim; ++i) { - if (!dsc || node->dsc.ptr.u[i] != dsc[i]) { - return 0; - } - } - return 1; -} - -static int -id3v2_add_ucs2(lame_t gfp, uint32_t frame_id, char const *lng, unsigned short const *desc, unsigned short const *text) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc != 0) { - FrameDataNode *node = findNode(&gfc->tag_spec, frame_id, 0); - char lang[4]; - setLang(lang, lng); - if (isMultiFrame(frame_id)) { - while (node) { - if (isSameLang(node->lng, lang)) { - if (isSameDescriptorUcs2(node, desc)) { - break; - } - } - node = findNode(&gfc->tag_spec, frame_id, node); - } - } - if (node == 0) { - node = lame_calloc(FrameDataNode, 1); - if (node == 0) { - return -254; /* memory problem */ - } - appendNode(&gfc->tag_spec, node); - } - node->fid = frame_id; - setLang(node->lng, lang); - node->dsc.dim = local_ucs2_strdup(&node->dsc.ptr.u, desc); - node->dsc.enc = 1; - node->txt.dim = local_ucs2_strdup(&node->txt.ptr.u, text); - node->txt.enc = 1; - gfc->tag_spec.flags |= (CHANGED_FLAG | ADD_V2_FLAG); - return 0; - } - return -255; -} - -static int -id3v2_add_latin1(lame_t gfp, uint32_t frame_id, char const *lng, char const *desc, char const *text) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc != 0) { - FrameDataNode *node = findNode(&gfc->tag_spec, frame_id, 0); - char lang[4]; - setLang(lang, lng); - if (isMultiFrame(frame_id)) { - while (node) { - if (isSameLang(node->lng, lang)) { - if (isSameDescriptor(node, desc)) { - break; - } - } - node = findNode(&gfc->tag_spec, frame_id, node); - } - } - if (node == 0) { - node = lame_calloc(FrameDataNode, 1); - if (node == 0) { - return -254; /* memory problem */ - } - appendNode(&gfc->tag_spec, node); - } - node->fid = frame_id; - setLang(node->lng, lang); - node->dsc.dim = local_strdup(&node->dsc.ptr.l, desc); - node->dsc.enc = 0; - node->txt.dim = local_strdup(&node->txt.ptr.l, text); - node->txt.enc = 0; - gfc->tag_spec.flags |= (CHANGED_FLAG | ADD_V2_FLAG); - return 0; - } - return -255; -} - -static char const* -id3v2_get_language(lame_t gfp) -{ - lame_internal_flags const* gfc = gfp ? gfp->internal_flags : 0; - if (gfc) return gfc->tag_spec.language; - return 0; -} - -static int -id3v2_add_ucs2_lng(lame_t gfp, uint32_t frame_id, unsigned short const *desc, unsigned short const *text) -{ - char const* lang = id3v2_get_language(gfp); - return id3v2_add_ucs2(gfp, frame_id, lang, desc, text); -} - -static int -id3v2_add_latin1_lng(lame_t gfp, uint32_t frame_id, char const *desc, char const *text) -{ - char const* lang = id3v2_get_language(gfp); - return id3v2_add_latin1(gfp, frame_id, lang, desc, text); -} - -static int -id3tag_set_userinfo_latin1(lame_t gfp, uint32_t id, char const *fieldvalue) -{ - char const separator = '='; - int rc = -7; - int a = local_char_pos(fieldvalue, separator); - if (a >= 0) { - char* dup = 0; - local_strdup(&dup, fieldvalue); - dup[a] = 0; - rc = id3v2_add_latin1_lng(gfp, id, dup, dup+a+1); - free(dup); - } - return rc; -} - -static int -id3tag_set_userinfo_ucs2(lame_t gfp, uint32_t id, unsigned short const *fieldvalue) -{ - unsigned short const separator = fromLatin1Char(fieldvalue,'='); - int rc = -7; - size_t b = local_ucs2_strlen(fieldvalue); - int a = local_ucs2_pos(fieldvalue, separator); - if (a >= 0) { - unsigned short* dsc = 0, *val = 0; - local_ucs2_substr(&dsc, fieldvalue, 0, a); - local_ucs2_substr(&val, fieldvalue, a+1, b); - rc = id3v2_add_ucs2_lng(gfp, id, dsc, val); - free(dsc); - free(val); - } - return rc; -} - -int -id3tag_set_textinfo_utf16(lame_t gfp, char const *id, unsigned short const *text) -{ - uint32_t const frame_id = toID3v2TagId(id); - if (frame_id == 0) { - return -1; - } - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - if (text == 0) { - return 0; - } - if (!hasUcs2ByteOrderMarker(text[0])) { - return -3; /* BOM missing */ - } - if (frame_id == ID_TXXX || frame_id == ID_WXXX || frame_id == ID_COMMENT) { - return id3tag_set_userinfo_ucs2(gfp, frame_id, text); - } - if (frame_id == ID_GENRE) { - return id3tag_set_genre_utf16(gfp, text); - } - if (frame_id == ID_PCST) { - return id3v2_add_ucs2_lng(gfp, frame_id, 0, text); - } - if (frame_id == ID_USER) { - return id3v2_add_ucs2_lng(gfp, frame_id, text, 0); - } - if (frame_id == ID_WFED) { - return id3v2_add_ucs2_lng(gfp, frame_id, text, 0); /* iTunes expects WFED to be a text frame */ - } - if (isFrameIdMatching(frame_id, FRAME_ID('T', 0, 0, 0)) - ||isFrameIdMatching(frame_id, FRAME_ID('W', 0, 0, 0))) { -#if 0 - if (isNumericString(frame_id)) { - return -2; /* must be Latin-1 encoded */ - } -#endif - return id3v2_add_ucs2_lng(gfp, frame_id, 0, text); - } - return -255; /* not supported by now */ -} - -extern int -id3tag_set_textinfo_ucs2(lame_t gfp, char const *id, unsigned short const *text); - -int -id3tag_set_textinfo_ucs2(lame_t gfp, char const *id, unsigned short const *text) -{ - return id3tag_set_textinfo_utf16(gfp, id, text); -} - -int -id3tag_set_textinfo_latin1(lame_t gfp, char const *id, char const *text) -{ - uint32_t const frame_id = toID3v2TagId(id); - if (frame_id == 0) { - return -1; - } - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - if (text == 0) { - return 0; - } - if (frame_id == ID_TXXX || frame_id == ID_WXXX || frame_id == ID_COMMENT) { - return id3tag_set_userinfo_latin1(gfp, frame_id, text); - } - if (frame_id == ID_GENRE) { - return id3tag_set_genre(gfp, text); - } - if (frame_id == ID_PCST) { - return id3v2_add_latin1_lng(gfp, frame_id, 0, text); - } - if (frame_id == ID_USER) { - return id3v2_add_latin1_lng(gfp, frame_id, text, 0); - } - if (frame_id == ID_WFED) { - return id3v2_add_latin1_lng(gfp, frame_id, text, 0); /* iTunes expects WFED to be a text frame */ - } - if (isFrameIdMatching(frame_id, FRAME_ID('T', 0, 0, 0)) - ||isFrameIdMatching(frame_id, FRAME_ID('W', 0, 0, 0))) { - return id3v2_add_latin1_lng(gfp, frame_id, 0, text); - } - return -255; /* not supported by now */ -} - - -int -id3tag_set_comment_latin1(lame_t gfp, char const *lang, char const *desc, char const *text) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - return id3v2_add_latin1(gfp, ID_COMMENT, lang, desc, text); -} - - -int -id3tag_set_comment_utf16(lame_t gfp, char const *lang, unsigned short const *desc, unsigned short const *text) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - return id3v2_add_ucs2(gfp, ID_COMMENT, lang, desc, text); -} - -extern int -id3tag_set_comment_ucs2(lame_t gfp, char const *lang, unsigned short const *desc, unsigned short const *text); - - -int -id3tag_set_comment_ucs2(lame_t gfp, char const *lang, unsigned short const *desc, unsigned short const *text) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - return id3tag_set_comment_utf16(gfp, lang, desc, text); -} - - -void -id3tag_set_title(lame_t gfp, const char *title) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc && title && *title) { - local_strdup(&gfc->tag_spec.title, title); - gfc->tag_spec.flags |= CHANGED_FLAG; - copyV1ToV2(gfp, ID_TITLE, title); - } -} - -void -id3tag_set_artist(lame_t gfp, const char *artist) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc && artist && *artist) { - local_strdup(&gfc->tag_spec.artist, artist); - gfc->tag_spec.flags |= CHANGED_FLAG; - copyV1ToV2(gfp, ID_ARTIST, artist); - } -} - -void -id3tag_set_album(lame_t gfp, const char *album) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc && album && *album) { - local_strdup(&gfc->tag_spec.album, album); - gfc->tag_spec.flags |= CHANGED_FLAG; - copyV1ToV2(gfp, ID_ALBUM, album); - } -} - -void -id3tag_set_year(lame_t gfp, const char *year) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc && year && *year) { - int num = atoi(year); - if (num < 0) { - num = 0; - } - /* limit a year to 4 digits so it fits in a version 1 tag */ - if (num > 9999) { - num = 9999; - } - if (num) { - gfc->tag_spec.year = num; - gfc->tag_spec.flags |= CHANGED_FLAG; - } - copyV1ToV2(gfp, ID_YEAR, year); - } -} - -void -id3tag_set_comment(lame_t gfp, const char *comment) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - if (gfc && comment && *comment) { - local_strdup(&gfc->tag_spec.comment, comment); - gfc->tag_spec.flags |= CHANGED_FLAG; - { - uint32_t const flags = gfc->tag_spec.flags; - id3v2_add_latin1_lng(gfp, ID_COMMENT, "", comment); - gfc->tag_spec.flags = flags; - } - } -} - -int -id3tag_set_track(lame_t gfp, const char *track) -{ - char const *trackcount; - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - int ret = 0; - - if (gfc && track && *track) { - int num = atoi(track); - /* check for valid ID3v1 track number range */ - if (num < 1 || num > 255) { - num = 0; - ret = -1; /* track number out of ID3v1 range, ignored for ID3v1 */ - gfc->tag_spec.flags |= (CHANGED_FLAG | ADD_V2_FLAG); - } - if (num) { - gfc->tag_spec.track_id3v1 = num; - gfc->tag_spec.flags |= CHANGED_FLAG; - } - /* Look for the total track count after a "/", same restrictions */ - trackcount = strchr(track, '/'); - if (trackcount && *trackcount) { - gfc->tag_spec.flags |= (CHANGED_FLAG | ADD_V2_FLAG); - } - copyV1ToV2(gfp, ID_TRACK, track); - } - return ret; -} - -/* would use real "strcasecmp" but it isn't portable */ -static int -local_strcasecmp(const char *s1, const char *s2) -{ - unsigned char c1; - unsigned char c2; - do { - c1 = tolower(*s1); - c2 = tolower(*s2); - if (!c1) { - break; - } - ++s1; - ++s2; - } while (c1 == c2); - return c1 - c2; -} - - -static -const char* nextUpperAlpha(const char* p, char x) -{ - char c; - for(c = toupper(*p); *p != 0; c = toupper(*++p)) { - if ('A' <= c && c <= 'Z') { - if (c != x) { - return p; - } - } - } - return p; -} - - -static int -sloppyCompared(const char* p, const char* q) -{ - char cp, cq; - p = nextUpperAlpha(p, 0); - q = nextUpperAlpha(q, 0); - cp = toupper(*p); - cq = toupper(*q); - while (cp == cq) { - if (cp == 0) { - return 1; - } - if (p[1] == '.') { /* some abbrevation */ - while (*q && *q++ != ' ') { - } - } - p = nextUpperAlpha(p, cp); - q = nextUpperAlpha(q, cq); - cp = toupper(*p); - cq = toupper(*q); - } - return 0; -} - - -static int -sloppySearchGenre(const char *genre) -{ - int i; - for (i = 0; i < GENRE_NAME_COUNT; ++i) { - if (sloppyCompared(genre, genre_names[i])) { - return i; - } - } - return GENRE_NAME_COUNT; -} - - -static int -searchGenre(const char* genre) -{ - int i; - for (i = 0; i < GENRE_NAME_COUNT; ++i) { - if (!local_strcasecmp(genre, genre_names[i])) { - return i; - } - } - return GENRE_NAME_COUNT; -} - - -int -id3tag_set_genre(lame_t gfp, const char *genre) -{ - lame_internal_flags *gfc = gfp != 0 ? gfp->internal_flags : 0; - int ret = 0; - if (gfc && genre && *genre) { - int const num = lookupGenre(genre); - if (num == -1) return num; - gfc->tag_spec.flags |= CHANGED_FLAG; - if (num >= 0) { - gfc->tag_spec.genre_id3v1 = num; - genre = genre_names[num]; - } - else { - gfc->tag_spec.genre_id3v1 = GENRE_INDEX_OTHER; - gfc->tag_spec.flags |= ADD_V2_FLAG; - } - copyV1ToV2(gfp, ID_GENRE, genre); - } - return ret; -} - - -static size_t -sizeOfNode(FrameDataNode const *node) -{ - size_t n = 0; - if (node) { - n = 10; /* header size */ - n += 1; /* text encoding flag */ - switch (node->txt.enc) { - default: - case 0: - if (node->dsc.dim > 0) { - n += node->dsc.dim + 1; - } - n += node->txt.dim; - break; - case 1: - if (node->dsc.dim > 0) { - n += (node->dsc.dim+1) * 2; - } - n += node->txt.dim * 2; - break; - } - } - return n; -} - -static size_t -sizeOfCommentNode(FrameDataNode const *node) -{ - size_t n = 0; - if (node) { - n = 10; /* header size */ - n += 1; /* text encoding flag */ - n += 3; /* language */ - switch (node->dsc.enc) { - default: - case 0: - n += 1 + node->dsc.dim; - break; - case 1: - n += 2 + node->dsc.dim * 2; - break; - } - switch (node->txt.enc) { - default: - case 0: - n += node->txt.dim; - break; - case 1: - n += node->txt.dim * 2; - break; - } - } - return n; -} - -static size_t -sizeOfWxxxNode(FrameDataNode const *node) -{ - size_t n = 0; - if (node) { - n = 10; /* header size */ - if (node->dsc.dim > 0) { - n += 1; /* text encoding flag */ - switch (node->dsc.enc) { - default: - case 0: - n += 1 + node->dsc.dim; - break; - case 1: - n += 2 + node->dsc.dim * 2; - break; - } - } - if (node->txt.dim > 0) { - switch (node->txt.enc) { - default: - case 0: - n += node->txt.dim; - break; - case 1: - n += node->txt.dim - 1; /* UCS2 -> Latin1, skip BOM */ - break; - } - } - } - return n; -} - -static unsigned char * -writeChars(unsigned char *frame, char const *str, size_t n) -{ - while (n--) { - *frame++ = *str++; - } - return frame; -} - -static unsigned char * -writeUcs2s(unsigned char *frame, unsigned short const *str, size_t n) -{ - if (n > 0) { - unsigned short const bom = *str; - while (n--) { - unsigned short const c = toLittleEndian(bom, *str++); - *frame++ = 0x00ffu & c; - *frame++ = 0x00ffu & (c >> 8); - } - } - return frame; -} - -static unsigned char * -writeLoBytes(unsigned char *frame, unsigned short const *str, size_t n) -{ - if (n > 0) { - unsigned short const bom = *str; - if (hasUcs2ByteOrderMarker(bom)) { - str++; n--; /* skip BOM */ - } - while (n--) { - unsigned short const c = toLittleEndian(bom, *str++); - if (c < 0x0020u || 0x00ffu < c) { - *frame++ = 0x0020; /* blank */ - } - else { - *frame++ = c; - } - } - } - return frame; -} - -static unsigned char * -set_frame_comment(unsigned char *frame, FrameDataNode const *node) -{ - size_t const n = sizeOfCommentNode(node); - if (n > 10) { - frame = set_4_byte_value(frame, node->fid); - frame = set_4_byte_value(frame, (uint32_t) (n - 10)); - /* clear 2-byte header flags */ - *frame++ = 0; - *frame++ = 0; - /* encoding descriptor byte */ - *frame++ = node->txt.enc == 1 ? 1 : 0; - /* 3 bytes language */ - *frame++ = node->lng[0]; - *frame++ = node->lng[1]; - *frame++ = node->lng[2]; - /* descriptor with zero byte(s) separator */ - if (node->dsc.enc != 1) { - frame = writeChars(frame, node->dsc.ptr.l, node->dsc.dim); - *frame++ = 0; - } - else { - frame = writeUcs2s(frame, node->dsc.ptr.u, node->dsc.dim); - *frame++ = 0; - *frame++ = 0; - } - /* comment full text */ - if (node->txt.enc != 1) { - frame = writeChars(frame, node->txt.ptr.l, node->txt.dim); - } - else { - frame = writeUcs2s(frame, node->txt.ptr.u, node->txt.dim); - } - } - return frame; -} - -static unsigned char * -set_frame_custom2(unsigned char *frame, FrameDataNode const *node) -{ - size_t const n = sizeOfNode(node); - if (n > 10) { - frame = set_4_byte_value(frame, node->fid); - frame = set_4_byte_value(frame, (unsigned long) (n - 10)); - /* clear 2-byte header flags */ - *frame++ = 0; - *frame++ = 0; - /* clear 1 encoding descriptor byte to indicate ISO-8859-1 format */ - *frame++ = node->txt.enc == 1 ? 1 : 0; - if (node->dsc.dim > 0) { - if (node->dsc.enc != 1) { - frame = writeChars(frame, node->dsc.ptr.l, node->dsc.dim); - *frame++ = 0; - } - else { - frame = writeUcs2s(frame, node->dsc.ptr.u, node->dsc.dim); - *frame++ = 0; - *frame++ = 0; - } - } - if (node->txt.enc != 1) { - frame = writeChars(frame, node->txt.ptr.l, node->txt.dim); - } - else { - frame = writeUcs2s(frame, node->txt.ptr.u, node->txt.dim); - } - } - return frame; -} - -static unsigned char * -set_frame_wxxx(unsigned char *frame, FrameDataNode const *node) -{ - size_t const n = sizeOfWxxxNode(node); - if (n > 10) { - frame = set_4_byte_value(frame, node->fid); - frame = set_4_byte_value(frame, (unsigned long) (n - 10)); - /* clear 2-byte header flags */ - *frame++ = 0; - *frame++ = 0; - if (node->dsc.dim > 0) { - /* clear 1 encoding descriptor byte to indicate ISO-8859-1 format */ - *frame++ = node->dsc.enc == 1 ? 1 : 0; - if (node->dsc.enc != 1) { - frame = writeChars(frame, node->dsc.ptr.l, node->dsc.dim); - *frame++ = 0; - } - else { - frame = writeUcs2s(frame, node->dsc.ptr.u, node->dsc.dim); - *frame++ = 0; - *frame++ = 0; - } - } - if (node->txt.enc != 1) { - frame = writeChars(frame, node->txt.ptr.l, node->txt.dim); - } - else { - frame = writeLoBytes(frame, node->txt.ptr.u, node->txt.dim); - } - } - return frame; -} - -static unsigned char * -set_frame_apic(unsigned char *frame, const char *mimetype, const unsigned char *data, size_t size) -{ - /* ID3v2.3 standard APIC frame: - *
- * Text encoding $xx - * MIME type $00 - * Picture type $xx - * Description $00 (00) - * Picture data - */ - if (mimetype && data && size) { - frame = set_4_byte_value(frame, FRAME_ID('A', 'P', 'I', 'C')); - frame = set_4_byte_value(frame, (unsigned long) (4 + strlen(mimetype) + size)); - /* clear 2-byte header flags */ - *frame++ = 0; - *frame++ = 0; - /* clear 1 encoding descriptor byte to indicate ISO-8859-1 format */ - *frame++ = 0; - /* copy mime_type */ - while (*mimetype) { - *frame++ = *mimetype++; - } - *frame++ = 0; - /* set picture type to 0 */ - *frame++ = 0; - /* empty description field */ - *frame++ = 0; - /* copy the image data */ - while (size--) { - *frame++ = *data++; - } - } - return frame; -} - -int -id3tag_set_fieldvalue(lame_t gfp, const char *fieldvalue) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - if (fieldvalue && *fieldvalue) { - if (strlen(fieldvalue) < 5 || fieldvalue[4] != '=') { - return -1; - } - return id3tag_set_textinfo_latin1(gfp, fieldvalue, &fieldvalue[5]); - } - return 0; -} - -int -id3tag_set_fieldvalue_utf16(lame_t gfp, const unsigned short *fieldvalue) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - if (fieldvalue && *fieldvalue) { - size_t dx = hasUcs2ByteOrderMarker(fieldvalue[0]); - unsigned short const separator = fromLatin1Char(fieldvalue, '='); - char fid[5] = {0,0,0,0,0}; - uint32_t const frame_id = toID3v2TagId_ucs2(fieldvalue); - if (local_ucs2_strlen(fieldvalue) < (5+dx) || fieldvalue[4+dx] != separator) { - return -1; - } - fid[0] = (frame_id >> 24) & 0x0ff; - fid[1] = (frame_id >> 16) & 0x0ff; - fid[2] = (frame_id >> 8) & 0x0ff; - fid[3] = frame_id & 0x0ff; - if (frame_id != 0) { - unsigned short* txt = 0; - int rc; - local_ucs2_substr(&txt, fieldvalue, dx+5, local_ucs2_strlen(fieldvalue)); - rc = id3tag_set_textinfo_utf16(gfp, fid, txt); - free(txt); - return rc; - } - } - return -1; -} - -extern int -id3tag_set_fieldvalue_ucs2(lame_t gfp, const unsigned short *fieldvalue); - -int -id3tag_set_fieldvalue_ucs2(lame_t gfp, const unsigned short *fieldvalue) -{ - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - return id3tag_set_fieldvalue_utf16(gfp, fieldvalue); -} - -size_t -lame_get_id3v2_tag(lame_t gfp, unsigned char *buffer, size_t size) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - gfc = gfp->internal_flags; - if (test_tag_spec_flags(gfc, V1_ONLY_FLAG)) { - return 0; - } -#if 0 - debug_tag_spec_flags(gfc, "lame_get_id3v2_tag"); -#endif - { - int usev2 = test_tag_spec_flags(gfc, ADD_V2_FLAG | V2_ONLY_FLAG); - /* calculate length of four fields which may not fit in verion 1 tag */ - size_t title_length = gfc->tag_spec.title ? strlen(gfc->tag_spec.title) : 0; - size_t artist_length = gfc->tag_spec.artist ? strlen(gfc->tag_spec.artist) : 0; - size_t album_length = gfc->tag_spec.album ? strlen(gfc->tag_spec.album) : 0; - size_t comment_length = gfc->tag_spec.comment ? strlen(gfc->tag_spec.comment) : 0; - /* write tag if explicitly requested or if fields overflow */ - if ((title_length > 30) - || (artist_length > 30) - || (album_length > 30) - || (comment_length > 30) - || (gfc->tag_spec.track_id3v1 && (comment_length > 28))) { - usev2 = 1; - } - if (usev2) { - size_t tag_size; - unsigned char *p; - size_t adjusted_tag_size; - const char *albumart_mime = NULL; - static const char *mime_jpeg = "image/jpeg"; - static const char *mime_png = "image/png"; - static const char *mime_gif = "image/gif"; - - if (gfp->num_samples != MAX_U_32_NUM) { - id3v2AddAudioDuration(gfp, gfp->num_samples); - } - - /* calulate size of tag starting with 10-byte tag header */ - tag_size = 10; - if (gfc->tag_spec.albumart && gfc->tag_spec.albumart_size) { - switch (gfc->tag_spec.albumart_mimetype) { - case MIMETYPE_JPEG: - albumart_mime = mime_jpeg; - break; - case MIMETYPE_PNG: - albumart_mime = mime_png; - break; - case MIMETYPE_GIF: - albumart_mime = mime_gif; - break; - } - if (albumart_mime) { - tag_size += 10 + 4 + strlen(albumart_mime) + gfc->tag_spec.albumart_size; - } - } - { - id3tag_spec *tag = &gfc->tag_spec; - if (tag->v2_head != 0) { - FrameDataNode *node; - for (node = tag->v2_head; node != 0; node = node->nxt) { - if (node->fid == ID_COMMENT || node->fid == ID_USER) { - tag_size += sizeOfCommentNode(node); - } - else if (isFrameIdMatching(node->fid, FRAME_ID('W',0,0,0))) { - tag_size += sizeOfWxxxNode(node); - } - else { - tag_size += sizeOfNode(node); - } - } - } - } - if (test_tag_spec_flags(gfc, PAD_V2_FLAG)) { - /* add some bytes of padding */ - tag_size += gfc->tag_spec.padding_size; - } - if (size < tag_size) { - return tag_size; - } - if (buffer == 0) { - return 0; - } - p = buffer; - /* set tag header starting with file identifier */ - *p++ = 'I'; - *p++ = 'D'; - *p++ = '3'; - /* set version number word */ - *p++ = 3; - *p++ = 0; - /* clear flags byte */ - *p++ = 0; - /* calculate and set tag size = total size - header size */ - adjusted_tag_size = tag_size - 10; - /* encode adjusted size into four bytes where most significant - * bit is clear in each byte, for 28-bit total */ - *p++ = (unsigned char) ((adjusted_tag_size >> 21) & 0x7fu); - *p++ = (unsigned char) ((adjusted_tag_size >> 14) & 0x7fu); - *p++ = (unsigned char) ((adjusted_tag_size >> 7) & 0x7fu); - *p++ = (unsigned char) (adjusted_tag_size & 0x7fu); - - /* - * NOTE: The remainder of the tag (frames and padding, if any) - * are not "unsynchronized" to prevent false MPEG audio headers - * from appearing in the bitstream. Why? Well, most players - * and utilities know how to skip the ID3 version 2 tag by now - * even if they don't read its contents, and it's actually - * very unlikely that such a false "sync" pattern would occur - * in just the simple text frames added here. - */ - - /* set each frame in tag */ - { - id3tag_spec *tag = &gfc->tag_spec; - if (tag->v2_head != 0) { - FrameDataNode *node; - for (node = tag->v2_head; node != 0; node = node->nxt) { - if (node->fid == ID_COMMENT || node->fid == ID_USER) { - p = set_frame_comment(p, node); - } - else if (isFrameIdMatching(node->fid,FRAME_ID('W',0,0,0))) { - p = set_frame_wxxx(p, node); - } - else { - p = set_frame_custom2(p, node); - } - } - } - } - if (albumart_mime) { - p = set_frame_apic(p, albumart_mime, gfc->tag_spec.albumart, - gfc->tag_spec.albumart_size); - } - /* clear any padding bytes */ - memset(p, 0, tag_size - (p - buffer)); - return tag_size; - } - } - return 0; -} - -int -id3tag_write_v2(lame_t gfp) -{ - lame_internal_flags *gfc = 0; - - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - gfc = gfp->internal_flags; -#if 0 - debug_tag_spec_flags(gfc, "write v2"); -#endif - if (test_tag_spec_flags(gfc, V1_ONLY_FLAG)) { - return 0; - } - if (test_tag_spec_flags(gfc, CHANGED_FLAG)) { - unsigned char *tag = 0; - size_t tag_size, n; - - n = lame_get_id3v2_tag(gfp, 0, 0); - tag = lame_calloc(unsigned char, n); - if (tag == 0) { - return -1; - } - tag_size = lame_get_id3v2_tag(gfp, tag, n); - if (tag_size > n) { - free(tag); - return -1; - } - else { - size_t i; - /* write tag directly into bitstream at current position */ - for (i = 0; i < tag_size; ++i) { - add_dummy_byte(gfc, tag[i], 1); - } - } - free(tag); - return (int) tag_size; /* ok, tag should not exceed 2GB */ - } - return 0; -} - -static unsigned char * -set_text_field(unsigned char *field, const char *text, size_t size, int pad) -{ - while (size--) { - if (text && *text) { - *field++ = *text++; - } - else { - *field++ = pad; - } - } - return field; -} - -size_t -lame_get_id3v1_tag(lame_t gfp, unsigned char *buffer, size_t size) -{ - size_t const tag_size = 128; - lame_internal_flags *gfc; - - if (gfp == 0) { - return 0; - } - if (size < tag_size) { - return tag_size; - } - gfc = gfp->internal_flags; - if (gfc == 0) { - return 0; - } - if (buffer == 0) { - return 0; - } - if (test_tag_spec_flags(gfc, V2_ONLY_FLAG)) { - return 0; - } - if (test_tag_spec_flags(gfc, CHANGED_FLAG)) { - unsigned char *p = buffer; - int pad = test_tag_spec_flags(gfc, SPACE_V1_FLAG) ? ' ' : 0; - char year[5]; - - /* set tag identifier */ - *p++ = 'T'; - *p++ = 'A'; - *p++ = 'G'; - /* set each field in tag */ - p = set_text_field(p, gfc->tag_spec.title, 30, pad); - p = set_text_field(p, gfc->tag_spec.artist, 30, pad); - p = set_text_field(p, gfc->tag_spec.album, 30, pad); - sprintf(year, "%d", gfc->tag_spec.year); - p = set_text_field(p, gfc->tag_spec.year ? year : NULL, 4, pad); - /* limit comment field to 28 bytes if a track is specified */ - p = set_text_field(p, gfc->tag_spec.comment, gfc->tag_spec.track_id3v1 ? 28 : 30, pad); - if (gfc->tag_spec.track_id3v1) { - /* clear the next byte to indicate a version 1.1 tag */ - *p++ = 0; - *p++ = gfc->tag_spec.track_id3v1; - } - *p++ = gfc->tag_spec.genre_id3v1; - return tag_size; - } - return 0; -} - -int -id3tag_write_v1(lame_t gfp) -{ - lame_internal_flags* gfc = 0; - size_t i, n, m; - unsigned char tag[128]; - - if (is_lame_internal_flags_null(gfp)) { - return 0; - } - gfc = gfp->internal_flags; - - m = sizeof(tag); - n = lame_get_id3v1_tag(gfp, tag, m); - if (n > m) { - return 0; - } - /* write tag directly into bitstream at current position */ - for (i = 0; i < n; ++i) { - add_dummy_byte(gfc, tag[i], 1); - } - return (int) n; /* ok, tag has fixed size of 128 bytes, well below 2GB */ -} diff --git a/lib-src/lame/libmp3lame/id3tag.h b/lib-src/lame/libmp3lame/id3tag.h deleted file mode 100644 index 9cd9ad9bb..000000000 --- a/lib-src/lame/libmp3lame/id3tag.h +++ /dev/null @@ -1,64 +0,0 @@ - -#ifndef LAME_ID3_H -#define LAME_ID3_H - - -#define CHANGED_FLAG (1U << 0) -#define ADD_V2_FLAG (1U << 1) -#define V1_ONLY_FLAG (1U << 2) -#define V2_ONLY_FLAG (1U << 3) -#define SPACE_V1_FLAG (1U << 4) -#define PAD_V2_FLAG (1U << 5) - -enum { - MIMETYPE_NONE = 0, - MIMETYPE_JPEG, - MIMETYPE_PNG, - MIMETYPE_GIF -}; - -typedef struct FrameDataNode { - struct FrameDataNode *nxt; - uint32_t fid; /* Frame Identifier */ - char lng[4]; /* 3-character language descriptor */ - struct { - union { - char *l; /* ptr to Latin-1 chars */ - unsigned short *u; /* ptr to UCS-2 text */ - unsigned char *b; /* ptr to raw bytes */ - } ptr; - size_t dim; - int enc; /* 0:Latin-1, 1:UCS-2, 2:RAW */ - } dsc , txt; -} FrameDataNode; - - -typedef struct id3tag_spec { - /* private data members */ - unsigned int flags; - int year; - char *title; - char *artist; - char *album; - char *comment; - int track_id3v1; - int genre_id3v1; - unsigned char *albumart; - unsigned int albumart_size; - unsigned int padding_size; - int albumart_mimetype; - char language[4]; /* the language of the frame's content, according to ISO-639-2 */ - FrameDataNode *v2_head, *v2_tail; -} id3tag_spec; - - -/* write tag into stream at current position */ -extern int id3tag_write_v2(lame_global_flags * gfp); -extern int id3tag_write_v1(lame_global_flags * gfp); -/* - * NOTE: A version 2 tag will NOT be added unless one of the text fields won't - * fit in a version 1 tag (e.g. the title string is longer than 30 characters), - * or the "id3tag_add_v2" or "id3tag_v2_only" functions are used. - */ - -#endif diff --git a/lib-src/lame/libmp3lame/l3side.h b/lib-src/lame/libmp3lame/l3side.h deleted file mode 100644 index f65bbedd8..000000000 --- a/lib-src/lame/libmp3lame/l3side.h +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Layer 3 side include file - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_L3SIDE_H -#define LAME_L3SIDE_H - -/* max scalefactor band, max(SBMAX_l, SBMAX_s*3, (SBMAX_s-3)*3+8) */ -#define SFBMAX (SBMAX_s*3) - -/* Layer III side information. */ -typedef struct { - int l[1 + SBMAX_l]; - int s[1 + SBMAX_s]; - int psfb21[1 + PSFB21]; - int psfb12[1 + PSFB12]; -} scalefac_struct; - - -typedef struct { - FLOAT l[SBMAX_l]; - FLOAT s[SBMAX_s][3]; -} III_psy_xmin; - -typedef struct { - III_psy_xmin thm; - III_psy_xmin en; -} III_psy_ratio; - -typedef struct { - FLOAT xr[576]; - int l3_enc[576]; - int scalefac[SFBMAX]; - FLOAT xrpow_max; - - int part2_3_length; - int big_values; - int count1; - int global_gain; - int scalefac_compress; - int block_type; - int mixed_block_flag; - int table_select[3]; - int subblock_gain[3 + 1]; - int region0_count; - int region1_count; - int preflag; - int scalefac_scale; - int count1table_select; - - int part2_length; - int sfb_lmax; - int sfb_smin; - int psy_lmax; - int sfbmax; - int psymax; - int sfbdivide; - int width[SFBMAX]; - int window[SFBMAX]; - int count1bits; - /* added for LSF */ - const int *sfb_partition_table; - int slen[4]; - - int max_nonzero_coeff; - char energy_above_cutoff[SFBMAX]; -} gr_info; - -typedef struct { - gr_info tt[2][2]; - int main_data_begin; - int private_bits; - int resvDrain_pre; - int resvDrain_post; - int scfsi[2][4]; -} III_side_info_t; - -#endif diff --git a/lib-src/lame/libmp3lame/lame-analysis.h b/lib-src/lame/libmp3lame/lame-analysis.h deleted file mode 100644 index 5055a6036..000000000 --- a/lib-src/lame/libmp3lame/lame-analysis.h +++ /dev/null @@ -1,96 +0,0 @@ -/* - * GTK plotting routines source file - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_GTKANAL_H -#define LAME_GTKANAL_H - - -#define READ_AHEAD 40 /* number of frames to read ahead */ -#define MAXMPGLAG READ_AHEAD /* if the mpg123 lag becomes bigger than this - we have to stop */ -#define NUMBACK 6 /* number of frames we can back up */ -#define NUMPINFO (NUMBACK+READ_AHEAD+1) - - - -struct plotting_data { - int frameNum; /* current frame number */ - int frameNum123; - int num_samples; /* number of pcm samples read for this frame */ - double frametime; /* starting time of frame, in seconds */ - double pcmdata[2][1600]; - double pcmdata2[2][1152 + 1152 - DECDELAY]; - double xr[2][2][576]; - double mpg123xr[2][2][576]; - double ms_ratio[2]; - double ms_ener_ratio[2]; - - /* L,R, M and S values */ - double energy_save[4][BLKSIZE]; /* psymodel is one ahead */ - double energy[2][4][BLKSIZE]; - double pe[2][4]; - double thr[2][4][SBMAX_l]; - double en[2][4][SBMAX_l]; - double thr_s[2][4][3 * SBMAX_s]; - double en_s[2][4][3 * SBMAX_s]; - double ers_save[4]; /* psymodel is one ahead */ - double ers[2][4]; - - double sfb[2][2][SBMAX_l]; - double sfb_s[2][2][3 * SBMAX_s]; - double LAMEsfb[2][2][SBMAX_l]; - double LAMEsfb_s[2][2][3 * SBMAX_s]; - - int LAMEqss[2][2]; - int qss[2][2]; - int big_values[2][2]; - int sub_gain[2][2][3]; - - double xfsf[2][2][SBMAX_l]; - double xfsf_s[2][2][3 * SBMAX_s]; - - int over[2][2]; - double tot_noise[2][2]; - double max_noise[2][2]; - double over_noise[2][2]; - int over_SSD[2][2]; - int blocktype[2][2]; - int scalefac_scale[2][2]; - int preflag[2][2]; - int mpg123blocktype[2][2]; - int mixed[2][2]; - int mainbits[2][2]; - int sfbits[2][2]; - int LAMEmainbits[2][2]; - int LAMEsfbits[2][2]; - int framesize, stereo, js, ms_stereo, i_stereo, emph, bitrate, sampfreq, maindata; - int crc, padding; - int scfsi[2], mean_bits, resvsize; - int totbits; -}; -#ifndef plotting_data_defined -#define plotting_data_defined -typedef struct plotting_data plotting_data; -#endif -#if 0 -extern plotting_data *pinfo; -#endif -#endif diff --git a/lib-src/lame/libmp3lame/lame.c b/lib-src/lame/libmp3lame/lame.c deleted file mode 100644 index 8e28d370c..000000000 --- a/lib-src/lame/libmp3lame/lame.c +++ /dev/null @@ -1,2665 +0,0 @@ -/* -*- mode: C; mode: fold -*- */ -/* - * LAME MP3 encoding engine - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 2000-2005 Takehiro Tominaga - * Copyright (c) 2000-2017 Robert Hegemann - * Copyright (c) 2000-2005 Gabriel Bouvigne - * Copyright (c) 2000-2004 Alexander Leidinger - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: lame.c,v 1.377 2017/09/26 12:14:02 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" - -#include "encoder.h" -#include "util.h" -#include "lame_global_flags.h" -#include "gain_analysis.h" -#include "bitstream.h" -#include "quantize_pvt.h" -#include "set_get.h" -#include "quantize.h" -#include "psymodel.h" -#include "version.h" -#include "VbrTag.h" -#include "tables.h" - - -#if defined(__FreeBSD__) && !defined(__alpha__) -#include -#endif -#ifdef __riscos__ -#include "asmstuff.h" -#endif - -#ifdef __sun__ -/* woraround for SunOS 4.x, it has SEEK_* defined here */ -#include -#endif - - -#define LAME_DEFAULT_QUALITY 3 - - - -int -is_lame_global_flags_valid(const lame_global_flags * gfp) -{ - if (gfp == NULL) - return 0; - if (gfp->class_id != LAME_ID) - return 0; - return 1; -} - - -int -is_lame_internal_flags_valid(const lame_internal_flags * gfc) -{ - if (gfc == NULL) - return 0; - if (gfc->class_id != LAME_ID) - return 0; - if (gfc->lame_init_params_successful <=0) - return 0; - return 1; -} - - - -static FLOAT -filter_coef(FLOAT x) -{ - if (x > 1.0) - return 0.0; - if (x <= 0.0) - return 1.0; - - return cos(PI / 2 * x); -} - -static void -lame_init_params_ppflt(lame_internal_flags * gfc) -{ - SessionConfig_t *const cfg = &gfc->cfg; - - /***************************************************************/ - /* compute info needed for polyphase filter (filter type==0, default) */ - /***************************************************************/ - - int band, maxband, minband; - FLOAT freq; - int lowpass_band = 32; - int highpass_band = -1; - - if (cfg->lowpass1 > 0) { - minband = 999; - for (band = 0; band <= 31; band++) { - freq = band / 31.0; - /* this band and above will be zeroed: */ - if (freq >= cfg->lowpass2) { - lowpass_band = Min(lowpass_band, band); - } - if (cfg->lowpass1 < freq && freq < cfg->lowpass2) { - minband = Min(minband, band); - } - } - - /* compute the *actual* transition band implemented by - * the polyphase filter */ - if (minband == 999) { - cfg->lowpass1 = (lowpass_band - .75) / 31.0; - } - else { - cfg->lowpass1 = (minband - .75) / 31.0; - } - cfg->lowpass2 = lowpass_band / 31.0; - } - - /* make sure highpass filter is within 90% of what the effective - * highpass frequency will be */ - if (cfg->highpass2 > 0) { - if (cfg->highpass2 < .9 * (.75 / 31.0)) { - cfg->highpass1 = 0; - cfg->highpass2 = 0; - MSGF(gfc, "Warning: highpass filter disabled. " "highpass frequency too small\n"); - } - } - - if (cfg->highpass2 > 0) { - maxband = -1; - for (band = 0; band <= 31; band++) { - freq = band / 31.0; - /* this band and below will be zereod */ - if (freq <= cfg->highpass1) { - highpass_band = Max(highpass_band, band); - } - if (cfg->highpass1 < freq && freq < cfg->highpass2) { - maxband = Max(maxband, band); - } - } - /* compute the *actual* transition band implemented by - * the polyphase filter */ - cfg->highpass1 = highpass_band / 31.0; - if (maxband == -1) { - cfg->highpass2 = (highpass_band + .75) / 31.0; - } - else { - cfg->highpass2 = (maxband + .75) / 31.0; - } - } - - for (band = 0; band < 32; band++) { - FLOAT fc1, fc2; - freq = band / 31.0f; - if (cfg->highpass2 > cfg->highpass1) { - fc1 = filter_coef((cfg->highpass2 - freq) / (cfg->highpass2 - cfg->highpass1 + 1e-20)); - } - else { - fc1 = 1.0f; - } - if (cfg->lowpass2 > cfg->lowpass1) { - fc2 = filter_coef((freq - cfg->lowpass1) / (cfg->lowpass2 - cfg->lowpass1 + 1e-20)); - } - else { - fc2 = 1.0f; - } - gfc->sv_enc.amp_filter[band] = fc1 * fc2; - } -} - - -static void -optimum_bandwidth(double *const lowerlimit, double *const upperlimit, const unsigned bitrate) -{ -/* - * Input: - * bitrate total bitrate in kbps - * - * Output: - * lowerlimit: best lowpass frequency limit for input filter in Hz - * upperlimit: best highpass frequency limit for input filter in Hz - */ - int table_index; - - typedef struct { - int bitrate; /* only indicative value */ - int lowpass; - } band_pass_t; - - const band_pass_t freq_map[] = { - {8, 2000}, - {16, 3700}, - {24, 3900}, - {32, 5500}, - {40, 7000}, - {48, 7500}, - {56, 10000}, - {64, 11000}, - {80, 13500}, - {96, 15100}, - {112, 15600}, - {128, 17000}, - {160, 17500}, - {192, 18600}, - {224, 19400}, - {256, 19700}, - {320, 20500} - }; - - - table_index = nearestBitrateFullIndex(bitrate); - - (void) freq_map[table_index].bitrate; - *lowerlimit = freq_map[table_index].lowpass; - - -/* - * Now we try to choose a good high pass filtering frequency. - * This value is currently not used. - * For fu < 16 kHz: sqrt(fu*fl) = 560 Hz - * For fu = 18 kHz: no high pass filtering - * This gives: - * - * 2 kHz => 160 Hz - * 3 kHz => 107 Hz - * 4 kHz => 80 Hz - * 8 kHz => 40 Hz - * 16 kHz => 20 Hz - * 17 kHz => 10 Hz - * 18 kHz => 0 Hz - * - * These are ad hoc values and these can be optimized if a high pass is available. - */ -/* if (f_low <= 16000) - f_high = 16000. * 20. / f_low; - else if (f_low <= 18000) - f_high = 180. - 0.01 * f_low; - else - f_high = 0.;*/ - - /* - * When we sometimes have a good highpass filter, we can add the highpass - * frequency to the lowpass frequency - */ - - /*if (upperlimit != NULL) - *upperlimit = f_high;*/ - (void) upperlimit; -} - - -static int -optimum_samplefreq(int lowpassfreq, int input_samplefreq) -{ -/* - * Rules: - * - if possible, sfb21 should NOT be used - * - */ - int suggested_samplefreq = 44100; - - if (input_samplefreq >= 48000) - suggested_samplefreq = 48000; - else if (input_samplefreq >= 44100) - suggested_samplefreq = 44100; - else if (input_samplefreq >= 32000) - suggested_samplefreq = 32000; - else if (input_samplefreq >= 24000) - suggested_samplefreq = 24000; - else if (input_samplefreq >= 22050) - suggested_samplefreq = 22050; - else if (input_samplefreq >= 16000) - suggested_samplefreq = 16000; - else if (input_samplefreq >= 12000) - suggested_samplefreq = 12000; - else if (input_samplefreq >= 11025) - suggested_samplefreq = 11025; - else if (input_samplefreq >= 8000) - suggested_samplefreq = 8000; - - if (lowpassfreq == -1) - return suggested_samplefreq; - - if (lowpassfreq <= 15960) - suggested_samplefreq = 44100; - if (lowpassfreq <= 15250) - suggested_samplefreq = 32000; - if (lowpassfreq <= 11220) - suggested_samplefreq = 24000; - if (lowpassfreq <= 9970) - suggested_samplefreq = 22050; - if (lowpassfreq <= 7230) - suggested_samplefreq = 16000; - if (lowpassfreq <= 5420) - suggested_samplefreq = 12000; - if (lowpassfreq <= 4510) - suggested_samplefreq = 11025; - if (lowpassfreq <= 3970) - suggested_samplefreq = 8000; - - if (input_samplefreq < suggested_samplefreq) { - /* choose a valid MPEG sample frequency above the input sample frequency - to avoid SFB21/12 bitrate bloat - rh 061115 - */ - if (input_samplefreq > 44100) { - return 48000; - } - if (input_samplefreq > 32000) { - return 44100; - } - if (input_samplefreq > 24000) { - return 32000; - } - if (input_samplefreq > 22050) { - return 24000; - } - if (input_samplefreq > 16000) { - return 22050; - } - if (input_samplefreq > 12000) { - return 16000; - } - if (input_samplefreq > 11025) { - return 12000; - } - if (input_samplefreq > 8000) { - return 11025; - } - return 8000; - } - return suggested_samplefreq; -} - - - - - -/* set internal feature flags. USER should not access these since - * some combinations will produce strange results */ -static void -lame_init_qval(lame_global_flags * gfp) -{ - lame_internal_flags *const gfc = gfp->internal_flags; - SessionConfig_t *const cfg = &gfc->cfg; - - switch (gfp->quality) { - default: - case 9: /* no psymodel, no noise shaping */ - cfg->noise_shaping = 0; - cfg->noise_shaping_amp = 0; - cfg->noise_shaping_stop = 0; - cfg->use_best_huffman = 0; - cfg->full_outer_loop = 0; - break; - - case 8: - gfp->quality = 7; - /*lint --fallthrough */ - case 7: /* use psymodel (for short block and m/s switching), but no noise shapping */ - cfg->noise_shaping = 0; - cfg->noise_shaping_amp = 0; - cfg->noise_shaping_stop = 0; - cfg->use_best_huffman = 0; - cfg->full_outer_loop = 0; - if (cfg->vbr == vbr_mt || cfg->vbr == vbr_mtrh) { - cfg->full_outer_loop = -1; - } - break; - - case 6: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - cfg->noise_shaping_amp = 0; - cfg->noise_shaping_stop = 0; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 0; - cfg->full_outer_loop = 0; - break; - - case 5: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - cfg->noise_shaping_amp = 0; - cfg->noise_shaping_stop = 0; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 0; - cfg->full_outer_loop = 0; - break; - - case 4: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - cfg->noise_shaping_amp = 0; - cfg->noise_shaping_stop = 0; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 1; - cfg->full_outer_loop = 0; - break; - - case 3: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - cfg->noise_shaping_amp = 1; - cfg->noise_shaping_stop = 1; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 1; - cfg->full_outer_loop = 0; - break; - - case 2: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - if (gfc->sv_qnt.substep_shaping == 0) - gfc->sv_qnt.substep_shaping = 2; - cfg->noise_shaping_amp = 1; - cfg->noise_shaping_stop = 1; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 1; /* inner loop */ - cfg->full_outer_loop = 0; - break; - - case 1: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - if (gfc->sv_qnt.substep_shaping == 0) - gfc->sv_qnt.substep_shaping = 2; - cfg->noise_shaping_amp = 2; - cfg->noise_shaping_stop = 1; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 1; - cfg->full_outer_loop = 0; - break; - - case 0: - if (cfg->noise_shaping == 0) - cfg->noise_shaping = 1; - if (gfc->sv_qnt.substep_shaping == 0) - gfc->sv_qnt.substep_shaping = 2; - cfg->noise_shaping_amp = 2; - cfg->noise_shaping_stop = 1; - if (cfg->subblock_gain == -1) - cfg->subblock_gain = 1; - cfg->use_best_huffman = 1; /*type 2 disabled because of it slowness, - in favor of full outer loop search */ - cfg->full_outer_loop = 1; - break; - } - -} - - - -static double -linear_int(double a, double b, double m) -{ - return a + m * (b - a); -} - - - -/******************************************************************** - * initialize internal params based on data in gf - * (globalflags struct filled in by calling program) - * - * OUTLINE: - * - * We first have some complex code to determine bitrate, - * output samplerate and mode. It is complicated by the fact - * that we allow the user to set some or all of these parameters, - * and need to determine best possible values for the rest of them: - * - * 1. set some CPU related flags - * 2. check if we are mono->mono, stereo->mono or stereo->stereo - * 3. compute bitrate and output samplerate: - * user may have set compression ratio - * user may have set a bitrate - * user may have set a output samplerate - * 4. set some options which depend on output samplerate - * 5. compute the actual compression ratio - * 6. set mode based on compression ratio - * - * The remaining code is much simpler - it just sets options - * based on the mode & compression ratio: - * - * set allow_diff_short based on mode - * select lowpass filter based on compression ratio & mode - * set the bitrate index, and min/max bitrates for VBR modes - * disable VBR tag if it is not appropriate - * initialize the bitstream - * initialize scalefac_band data - * set sideinfo_len (based on channels, CRC, out_samplerate) - * write an id3v2 tag into the bitstream - * write VBR tag into the bitstream - * set mpeg1/2 flag - * estimate the number of frames (based on a lot of data) - * - * now we set more flags: - * nspsytune: - * see code - * VBR modes - * see code - * CBR/ABR - * see code - * - * Finally, we set the algorithm flags based on the gfp->quality value - * lame_init_qval(gfp); - * - ********************************************************************/ -int -lame_init_params(lame_global_flags * gfp) -{ - - int i; - int j; - lame_internal_flags *gfc; - SessionConfig_t *cfg; - - if (!is_lame_global_flags_valid(gfp)) - return -1; - - gfc = gfp->internal_flags; - if (gfc == 0) - return -1; - - if (is_lame_internal_flags_valid(gfc)) - return -1; /* already initialized */ - - /* start updating lame internal flags */ - gfc->class_id = LAME_ID; - gfc->lame_init_params_successful = 0; /* will be set to one, when we get through until the end */ - - if (gfp->samplerate_in < 1) - return -1; /* input sample rate makes no sense */ - if (gfp->num_channels < 1 || 2 < gfp->num_channels) - return -1; /* number of input channels makes no sense */ - if (gfp->samplerate_out != 0) { - int v=0; - if (SmpFrqIndex(gfp->samplerate_out, &v) < 0) - return -1; /* output sample rate makes no sense */ - } - - cfg = &gfc->cfg; - - cfg->enforce_min_bitrate = gfp->VBR_hard_min; - cfg->analysis = gfp->analysis; - if (cfg->analysis) - gfp->write_lame_tag = 0; - - /* some file options not allowed if output is: not specified or stdout */ - if (gfc->pinfo != NULL) - gfp->write_lame_tag = 0; /* disable Xing VBR tag */ - - /* report functions */ - gfc->report_msg = gfp->report.msgf; - gfc->report_dbg = gfp->report.debugf; - gfc->report_err = gfp->report.errorf; - - if (gfp->asm_optimizations.amd3dnow) - gfc->CPU_features.AMD_3DNow = has_3DNow(); - else - gfc->CPU_features.AMD_3DNow = 0; - - if (gfp->asm_optimizations.mmx) - gfc->CPU_features.MMX = has_MMX(); - else - gfc->CPU_features.MMX = 0; - - if (gfp->asm_optimizations.sse) { - gfc->CPU_features.SSE = has_SSE(); - gfc->CPU_features.SSE2 = has_SSE2(); - } - else { - gfc->CPU_features.SSE = 0; - gfc->CPU_features.SSE2 = 0; - } - - - cfg->vbr = gfp->VBR; - cfg->error_protection = gfp->error_protection; - cfg->copyright = gfp->copyright; - cfg->original = gfp->original; - cfg->extension = gfp->extension; - cfg->emphasis = gfp->emphasis; - - cfg->channels_in = gfp->num_channels; - if (cfg->channels_in == 1) - gfp->mode = MONO; - cfg->channels_out = (gfp->mode == MONO) ? 1 : 2; - if (gfp->mode != JOINT_STEREO) - gfp->force_ms = 0; /* forced mid/side stereo for j-stereo only */ - cfg->force_ms = gfp->force_ms; - - if (cfg->vbr == vbr_off && gfp->VBR_mean_bitrate_kbps != 128 && gfp->brate == 0) - gfp->brate = gfp->VBR_mean_bitrate_kbps; - - switch (cfg->vbr) { - case vbr_off: - case vbr_mtrh: - case vbr_mt: - /* these modes can handle free format condition */ - break; - default: - gfp->free_format = 0; /* mode can't be mixed with free format */ - break; - } - - cfg->free_format = gfp->free_format; - - if (cfg->vbr == vbr_off && gfp->brate == 0) { - /* no bitrate or compression ratio specified, use 11.025 */ - if (EQ(gfp->compression_ratio, 0.0)) - gfp->compression_ratio = 11.025; /* rate to compress a CD down to exactly 128000 bps */ - } - - /* find bitrate if user specify a compression ratio */ - if (cfg->vbr == vbr_off && gfp->compression_ratio > 0) { - - if (gfp->samplerate_out == 0) - gfp->samplerate_out = map2MP3Frequency((int) (0.97 * gfp->samplerate_in)); /* round up with a margin of 3% */ - - /* choose a bitrate for the output samplerate which achieves - * specified compression ratio - */ - gfp->brate = gfp->samplerate_out * 16 * cfg->channels_out / (1.e3 * gfp->compression_ratio); - - /* we need the version for the bitrate table look up */ - cfg->samplerate_index = SmpFrqIndex(gfp->samplerate_out, &cfg->version); - assert(cfg->samplerate_index >=0); - - if (!cfg->free_format) /* for non Free Format find the nearest allowed bitrate */ - gfp->brate = FindNearestBitrate(gfp->brate, cfg->version, gfp->samplerate_out); - } - if (gfp->samplerate_out) { - if (gfp->samplerate_out < 16000) { - gfp->VBR_mean_bitrate_kbps = Max(gfp->VBR_mean_bitrate_kbps, 8); - gfp->VBR_mean_bitrate_kbps = Min(gfp->VBR_mean_bitrate_kbps, 64); - } - else if (gfp->samplerate_out < 32000) { - gfp->VBR_mean_bitrate_kbps = Max(gfp->VBR_mean_bitrate_kbps, 8); - gfp->VBR_mean_bitrate_kbps = Min(gfp->VBR_mean_bitrate_kbps, 160); - } - else { - gfp->VBR_mean_bitrate_kbps = Max(gfp->VBR_mean_bitrate_kbps, 32); - gfp->VBR_mean_bitrate_kbps = Min(gfp->VBR_mean_bitrate_kbps, 320); - } - } - /* WORK IN PROGRESS */ - /* mapping VBR scale to internal VBR quality settings */ - if (gfp->samplerate_out == 0 && (cfg->vbr == vbr_mt || cfg->vbr == vbr_mtrh)) { - float const qval = gfp->VBR_q + gfp->VBR_q_frac; - struct q_map { int sr_a; float qa, qb, ta, tb; int lp; }; - struct q_map const m[9] - = { {48000, 0.0,6.5, 0.0,6.5, 23700} - , {44100, 0.0,6.5, 0.0,6.5, 21780} - , {32000, 6.5,8.0, 5.2,6.5, 15800} - , {24000, 8.0,8.5, 5.2,6.0, 11850} - , {22050, 8.5,9.01, 5.2,6.5, 10892} - , {16000, 9.01,9.4, 4.9,6.5, 7903} - , {12000, 9.4,9.6, 4.5,6.0, 5928} - , {11025, 9.6,9.9, 5.1,6.5, 5446} - , { 8000, 9.9,10., 4.9,6.5, 3952} - }; - for (i = 2; i < 9; ++i) { - if (gfp->samplerate_in == m[i].sr_a) { - if (qval < m[i].qa) { - double d = qval / m[i].qa; - d = d * m[i].ta; - gfp->VBR_q = (int)d; - gfp->VBR_q_frac = d - gfp->VBR_q; - } - } - if (gfp->samplerate_in >= m[i].sr_a) { - if (m[i].qa <= qval && qval < m[i].qb) { - float const q_ = m[i].qb-m[i].qa; - float const t_ = m[i].tb-m[i].ta; - double d = m[i].ta + t_ * (qval-m[i].qa) / q_; - gfp->VBR_q = (int)d; - gfp->VBR_q_frac = d - gfp->VBR_q; - gfp->samplerate_out = m[i].sr_a; - if (gfp->lowpassfreq == 0) { - gfp->lowpassfreq = -1; - } - break; - } - } - } - } - - /****************************************************************/ - /* if a filter has not been enabled, see if we should add one: */ - /****************************************************************/ - if (gfp->lowpassfreq == 0) { - double lowpass = 16000; - double highpass; - - switch (cfg->vbr) { - case vbr_off:{ - optimum_bandwidth(&lowpass, &highpass, gfp->brate); - break; - } - case vbr_abr:{ - optimum_bandwidth(&lowpass, &highpass, gfp->VBR_mean_bitrate_kbps); - break; - } - case vbr_rh:{ - int const x[11] = { - 19500, 19000, 18600, 18000, 17500, 16000, 15600, 14900, 12500, 10000, 3950 - }; - if (0 <= gfp->VBR_q && gfp->VBR_q <= 9) { - double a = x[gfp->VBR_q], b = x[gfp->VBR_q + 1], m = gfp->VBR_q_frac; - lowpass = linear_int(a, b, m); - } - else { - lowpass = 19500; - } - break; - } - case vbr_mtrh: - case vbr_mt:{ - int const x[11] = { - 24000, 19500, 18500, 18000, 17500, 17000, 16500, 15600, 15200, 7230, 3950 - }; - if (0 <= gfp->VBR_q && gfp->VBR_q <= 9) { - double a = x[gfp->VBR_q], b = x[gfp->VBR_q + 1], m = gfp->VBR_q_frac; - lowpass = linear_int(a, b, m); - } - else { - lowpass = 21500; - } - break; - } - default:{ - int const x[11] = { - 19500, 19000, 18500, 18000, 17500, 16500, 15500, 14500, 12500, 9500, 3950 - }; - if (0 <= gfp->VBR_q && gfp->VBR_q <= 9) { - double a = x[gfp->VBR_q], b = x[gfp->VBR_q + 1], m = gfp->VBR_q_frac; - lowpass = linear_int(a, b, m); - } - else { - lowpass = 19500; - } - } - } - - if (gfp->mode == MONO && (cfg->vbr == vbr_off || cfg->vbr == vbr_abr)) - lowpass *= 1.5; - - gfp->lowpassfreq = lowpass; - } - - if (gfp->samplerate_out == 0) { - if (2 * gfp->lowpassfreq > gfp->samplerate_in) { - gfp->lowpassfreq = gfp->samplerate_in / 2; - } - gfp->samplerate_out = optimum_samplefreq((int) gfp->lowpassfreq, gfp->samplerate_in); - } - if (cfg->vbr == vbr_mt || cfg->vbr == vbr_mtrh) { - gfp->lowpassfreq = Min(24000, gfp->lowpassfreq); - } - else { - gfp->lowpassfreq = Min(20500, gfp->lowpassfreq); - } - gfp->lowpassfreq = Min(gfp->samplerate_out / 2, gfp->lowpassfreq); - - if (cfg->vbr == vbr_off) { - gfp->compression_ratio = gfp->samplerate_out * 16 * cfg->channels_out / (1.e3 * gfp->brate); - } - if (cfg->vbr == vbr_abr) { - gfp->compression_ratio = - gfp->samplerate_out * 16 * cfg->channels_out / (1.e3 * gfp->VBR_mean_bitrate_kbps); - } - - cfg->disable_reservoir = gfp->disable_reservoir; - cfg->lowpassfreq = gfp->lowpassfreq; - cfg->highpassfreq = gfp->highpassfreq; - cfg->samplerate_in = gfp->samplerate_in; - cfg->samplerate_out = gfp->samplerate_out; - cfg->mode_gr = cfg->samplerate_out <= 24000 ? 1 : 2; /* Number of granules per frame */ - - - /* - * sample freq bitrate compression ratio - * [kHz] [kbps/channel] for 16 bit input - * 44.1 56 12.6 - * 44.1 64 11.025 - * 44.1 80 8.82 - * 22.05 24 14.7 - * 22.05 32 11.025 - * 22.05 40 8.82 - * 16 16 16.0 - * 16 24 10.667 - * - */ - /* - * For VBR, take a guess at the compression_ratio. - * For example: - * - * VBR_q compression like - * - 4.4 320 kbps/44 kHz - * 0...1 5.5 256 kbps/44 kHz - * 2 7.3 192 kbps/44 kHz - * 4 8.8 160 kbps/44 kHz - * 6 11 128 kbps/44 kHz - * 9 14.7 96 kbps - * - * for lower bitrates, downsample with --resample - */ - - switch (cfg->vbr) { - case vbr_mt: - case vbr_rh: - case vbr_mtrh: - { - /*numbers are a bit strange, but they determine the lowpass value */ - FLOAT const cmp[] = { 5.7, 6.5, 7.3, 8.2, 10, 11.9, 13, 14, 15, 16.5 }; - gfp->compression_ratio = cmp[gfp->VBR_q]; - } - break; - case vbr_abr: - gfp->compression_ratio = - cfg->samplerate_out * 16 * cfg->channels_out / (1.e3 * gfp->VBR_mean_bitrate_kbps); - break; - default: - gfp->compression_ratio = cfg->samplerate_out * 16 * cfg->channels_out / (1.e3 * gfp->brate); - break; - } - - - /* mode = -1 (not set by user) or - * mode = MONO (because of only 1 input channel). - * If mode has not been set, then select J-STEREO - */ - if (gfp->mode == NOT_SET) { - gfp->mode = JOINT_STEREO; - } - - cfg->mode = gfp->mode; - - - /* apply user driven high pass filter */ - if (cfg->highpassfreq > 0) { - cfg->highpass1 = 2. * cfg->highpassfreq; - - if (gfp->highpasswidth >= 0) - cfg->highpass2 = 2. * (cfg->highpassfreq + gfp->highpasswidth); - else /* 0% above on default */ - cfg->highpass2 = (1 + 0.00) * 2. * cfg->highpassfreq; - - cfg->highpass1 /= cfg->samplerate_out; - cfg->highpass2 /= cfg->samplerate_out; - } - else { - cfg->highpass1 = 0; - cfg->highpass2 = 0; - } - /* apply user driven low pass filter */ - cfg->lowpass1 = 0; - cfg->lowpass2 = 0; - if (cfg->lowpassfreq > 0 && cfg->lowpassfreq < (cfg->samplerate_out / 2) ) { - cfg->lowpass2 = 2. * cfg->lowpassfreq; - if (gfp->lowpasswidth >= 0) { - cfg->lowpass1 = 2. * (cfg->lowpassfreq - gfp->lowpasswidth); - if (cfg->lowpass1 < 0) /* has to be >= 0 */ - cfg->lowpass1 = 0; - } - else { /* 0% below on default */ - cfg->lowpass1 = (1 - 0.00) * 2. * cfg->lowpassfreq; - } - cfg->lowpass1 /= cfg->samplerate_out; - cfg->lowpass2 /= cfg->samplerate_out; - } - - - - - /**********************************************************************/ - /* compute info needed for polyphase filter (filter type==0, default) */ - /**********************************************************************/ - lame_init_params_ppflt(gfc); - - - /******************************************************* - * samplerate and bitrate index - *******************************************************/ - cfg->samplerate_index = SmpFrqIndex(cfg->samplerate_out, &cfg->version); - assert(cfg->samplerate_index >= 0); - - if (cfg->vbr == vbr_off) { - if (cfg->free_format) { - gfc->ov_enc.bitrate_index = 0; - } - else { - gfp->brate = FindNearestBitrate(gfp->brate, cfg->version, cfg->samplerate_out); - gfc->ov_enc.bitrate_index = BitrateIndex(gfp->brate, cfg->version, cfg->samplerate_out); - if (gfc->ov_enc.bitrate_index <= 0) { - /* This never happens, because of preceding FindNearestBitrate! - * But, set a sane value, just in case - */ - assert(0); - gfc->ov_enc.bitrate_index = 8; - } - } - } - else { - gfc->ov_enc.bitrate_index = 1; - } - - init_bit_stream_w(gfc); - - j = cfg->samplerate_index + (3 * cfg->version) + 6 * (cfg->samplerate_out < 16000); - for (i = 0; i < SBMAX_l + 1; i++) - gfc->scalefac_band.l[i] = sfBandIndex[j].l[i]; - - for (i = 0; i < PSFB21 + 1; i++) { - int const size = (gfc->scalefac_band.l[22] - gfc->scalefac_band.l[21]) / PSFB21; - int const start = gfc->scalefac_band.l[21] + i * size; - gfc->scalefac_band.psfb21[i] = start; - } - gfc->scalefac_band.psfb21[PSFB21] = 576; - - for (i = 0; i < SBMAX_s + 1; i++) - gfc->scalefac_band.s[i] = sfBandIndex[j].s[i]; - - for (i = 0; i < PSFB12 + 1; i++) { - int const size = (gfc->scalefac_band.s[13] - gfc->scalefac_band.s[12]) / PSFB12; - int const start = gfc->scalefac_band.s[12] + i * size; - gfc->scalefac_band.psfb12[i] = start; - } - gfc->scalefac_band.psfb12[PSFB12] = 192; - - /* determine the mean bitrate for main data */ - if (cfg->mode_gr == 2) /* MPEG 1 */ - cfg->sideinfo_len = (cfg->channels_out == 1) ? 4 + 17 : 4 + 32; - else /* MPEG 2 */ - cfg->sideinfo_len = (cfg->channels_out == 1) ? 4 + 9 : 4 + 17; - - if (cfg->error_protection) - cfg->sideinfo_len += 2; - - { - int k; - - for (k = 0; k < 19; k++) - gfc->sv_enc.pefirbuf[k] = 700 * cfg->mode_gr * cfg->channels_out; - - if (gfp->ATHtype == -1) - gfp->ATHtype = 4; - } - - assert(gfp->VBR_q <= 9); - assert(gfp->VBR_q >= 0); - - switch (cfg->vbr) { - - case vbr_mt: - case vbr_mtrh:{ - if (gfp->strict_ISO < 0) { - gfp->strict_ISO = MDB_MAXIMUM; - } - if (gfp->useTemporal < 0) { - gfp->useTemporal = 0; /* off by default for this VBR mode */ - } - - (void) apply_preset(gfp, 500 - (gfp->VBR_q * 10), 0); - /* The newer VBR code supports only a limited - subset of quality levels: - 9-5=5 are the same, uses x^3/4 quantization - 4-0=0 are the same 5 plus best huffman divide code - */ - if (gfp->quality < 0) - gfp->quality = LAME_DEFAULT_QUALITY; - if (gfp->quality < 5) - gfp->quality = 0; - if (gfp->quality > 7) - gfp->quality = 7; - - /* sfb21 extra only with MPEG-1 at higher sampling rates - */ - if (gfp->experimentalY) - gfc->sv_qnt.sfb21_extra = 0; - else - gfc->sv_qnt.sfb21_extra = (cfg->samplerate_out > 44000); - - break; - - } - case vbr_rh:{ - - (void) apply_preset(gfp, 500 - (gfp->VBR_q * 10), 0); - - /* sfb21 extra only with MPEG-1 at higher sampling rates - */ - if (gfp->experimentalY) - gfc->sv_qnt.sfb21_extra = 0; - else - gfc->sv_qnt.sfb21_extra = (cfg->samplerate_out > 44000); - - /* VBR needs at least the output of GPSYCHO, - * so we have to garantee that by setting a minimum - * quality level, actually level 6 does it. - * down to level 6 - */ - if (gfp->quality > 6) - gfp->quality = 6; - - - if (gfp->quality < 0) - gfp->quality = LAME_DEFAULT_QUALITY; - - break; - } - - default: /* cbr/abr */ { - - /* no sfb21 extra with CBR code - */ - gfc->sv_qnt.sfb21_extra = 0; - - if (gfp->quality < 0) - gfp->quality = LAME_DEFAULT_QUALITY; - - - if (cfg->vbr == vbr_off) - (void) lame_set_VBR_mean_bitrate_kbps(gfp, gfp->brate); - /* second, set parameters depending on bitrate */ - (void) apply_preset(gfp, gfp->VBR_mean_bitrate_kbps, 0); - gfp->VBR = cfg->vbr; - - break; - } - } - - /*initialize default values common for all modes */ - - gfc->sv_qnt.mask_adjust = gfp->maskingadjust; - gfc->sv_qnt.mask_adjust_short = gfp->maskingadjust_short; - - /* just another daily changing developer switch */ - if (gfp->tune) { - gfc->sv_qnt.mask_adjust += gfp->tune_value_a; - gfc->sv_qnt.mask_adjust_short += gfp->tune_value_a; - } - - - if (cfg->vbr != vbr_off) { /* choose a min/max bitrate for VBR */ - /* if the user didn't specify VBR_max_bitrate: */ - cfg->vbr_min_bitrate_index = 1; /* default: allow 8 kbps (MPEG-2) or 32 kbps (MPEG-1) */ - cfg->vbr_max_bitrate_index = 14; /* default: allow 160 kbps (MPEG-2) or 320 kbps (MPEG-1) */ - if (cfg->samplerate_out < 16000) - cfg->vbr_max_bitrate_index = 8; /* default: allow 64 kbps (MPEG-2.5) */ - if (gfp->VBR_min_bitrate_kbps) { - gfp->VBR_min_bitrate_kbps = - FindNearestBitrate(gfp->VBR_min_bitrate_kbps, cfg->version, cfg->samplerate_out); - cfg->vbr_min_bitrate_index = - BitrateIndex(gfp->VBR_min_bitrate_kbps, cfg->version, cfg->samplerate_out); - if (cfg->vbr_min_bitrate_index < 0) { - /* This never happens, because of preceding FindNearestBitrate! - * But, set a sane value, just in case - */ - assert(0); - cfg->vbr_min_bitrate_index = 1; - } - } - if (gfp->VBR_max_bitrate_kbps) { - gfp->VBR_max_bitrate_kbps = - FindNearestBitrate(gfp->VBR_max_bitrate_kbps, cfg->version, cfg->samplerate_out); - cfg->vbr_max_bitrate_index = - BitrateIndex(gfp->VBR_max_bitrate_kbps, cfg->version, cfg->samplerate_out); - if (cfg->vbr_max_bitrate_index < 0) { - /* This never happens, because of preceding FindNearestBitrate! - * But, set a sane value, just in case - */ - assert(0); - cfg->vbr_max_bitrate_index = cfg->samplerate_out < 16000 ? 8 : 14; - } - } - gfp->VBR_min_bitrate_kbps = bitrate_table[cfg->version][cfg->vbr_min_bitrate_index]; - gfp->VBR_max_bitrate_kbps = bitrate_table[cfg->version][cfg->vbr_max_bitrate_index]; - gfp->VBR_mean_bitrate_kbps = - Min(bitrate_table[cfg->version][cfg->vbr_max_bitrate_index], - gfp->VBR_mean_bitrate_kbps); - gfp->VBR_mean_bitrate_kbps = - Max(bitrate_table[cfg->version][cfg->vbr_min_bitrate_index], - gfp->VBR_mean_bitrate_kbps); - } - - cfg->preset = gfp->preset; - cfg->write_lame_tag = gfp->write_lame_tag; - gfc->sv_qnt.substep_shaping = gfp->substep_shaping; - cfg->noise_shaping = gfp->noise_shaping; - cfg->subblock_gain = gfp->subblock_gain; - cfg->use_best_huffman = gfp->use_best_huffman; - cfg->avg_bitrate = gfp->brate; - cfg->vbr_avg_bitrate_kbps = gfp->VBR_mean_bitrate_kbps; - cfg->compression_ratio = gfp->compression_ratio; - - /* initialize internal qval settings */ - lame_init_qval(gfp); - - - /* automatic ATH adjustment on - */ - if (gfp->athaa_type < 0) - gfc->ATH->use_adjust = 3; - else - gfc->ATH->use_adjust = gfp->athaa_type; - - - /* initialize internal adaptive ATH settings -jd */ - gfc->ATH->aa_sensitivity_p = pow(10.0, gfp->athaa_sensitivity / -10.0); - - - if (gfp->short_blocks == short_block_not_set) { - gfp->short_blocks = short_block_allowed; - } - - /*Note Jan/2003: Many hardware decoders cannot handle short blocks in regular - stereo mode unless they are coupled (same type in both channels) - it is a rare event (1 frame per min. or so) that LAME would use - uncoupled short blocks, so lets turn them off until we decide - how to handle this. No other encoders allow uncoupled short blocks, - even though it is in the standard. */ - /* rh 20040217: coupling makes no sense for mono and dual-mono streams - */ - if (gfp->short_blocks == short_block_allowed - && (cfg->mode == JOINT_STEREO || cfg->mode == STEREO)) { - gfp->short_blocks = short_block_coupled; - } - - cfg->short_blocks = gfp->short_blocks; - - - if (lame_get_quant_comp(gfp) < 0) - (void) lame_set_quant_comp(gfp, 1); - if (lame_get_quant_comp_short(gfp) < 0) - (void) lame_set_quant_comp_short(gfp, 0); - - if (lame_get_msfix(gfp) < 0) - lame_set_msfix(gfp, 0); - - /* select psychoacoustic model */ - (void) lame_set_exp_nspsytune(gfp, lame_get_exp_nspsytune(gfp) | 1); - - if (gfp->ATHtype < 0) - gfp->ATHtype = 4; - - if (gfp->ATHcurve < 0) - gfp->ATHcurve = 4; - - if (gfp->interChRatio < 0) - gfp->interChRatio = 0; - - if (gfp->useTemporal < 0) - gfp->useTemporal = 1; /* on by default */ - - - cfg->interChRatio = gfp->interChRatio; - cfg->msfix = gfp->msfix; - cfg->ATH_offset_db = 0-gfp->ATH_lower_db; - cfg->ATH_offset_factor = powf(10.f, cfg->ATH_offset_db * 0.1f); - cfg->ATHcurve = gfp->ATHcurve; - cfg->ATHtype = gfp->ATHtype; - cfg->ATHonly = gfp->ATHonly; - cfg->ATHshort = gfp->ATHshort; - cfg->noATH = gfp->noATH; - - cfg->quant_comp = gfp->quant_comp; - cfg->quant_comp_short = gfp->quant_comp_short; - - cfg->use_temporal_masking_effect = gfp->useTemporal; - if (cfg->mode == JOINT_STEREO) { - cfg->use_safe_joint_stereo = gfp->exp_nspsytune & 2; - } - else { - cfg->use_safe_joint_stereo = 0; - } - { - cfg->adjust_bass_db = (gfp->exp_nspsytune >> 2) & 63; - if (cfg->adjust_bass_db >= 32.f) - cfg->adjust_bass_db -= 64.f; - cfg->adjust_bass_db *= 0.25f; - - cfg->adjust_alto_db = (gfp->exp_nspsytune >> 8) & 63; - if (cfg->adjust_alto_db >= 32.f) - cfg->adjust_alto_db -= 64.f; - cfg->adjust_alto_db *= 0.25f; - - cfg->adjust_treble_db = (gfp->exp_nspsytune >> 14) & 63; - if (cfg->adjust_treble_db >= 32.f) - cfg->adjust_treble_db -= 64.f; - cfg->adjust_treble_db *= 0.25f; - - /* to be compatible with Naoki's original code, the next 6 bits - * define only the amount of changing treble for sfb21 */ - cfg->adjust_sfb21_db = (gfp->exp_nspsytune >> 20) & 63; - if (cfg->adjust_sfb21_db >= 32.f) - cfg->adjust_sfb21_db -= 64.f; - cfg->adjust_sfb21_db *= 0.25f; - cfg->adjust_sfb21_db += cfg->adjust_treble_db; - } - - /* Setting up the PCM input data transform matrix, to apply - * user defined re-scaling, and or two-to-one channel downmix. - */ - { - FLOAT m[2][2] = { {1.0f, 0.0f}, {0.0f, 1.0f} }; - - /* user selected scaling of the samples */ - m[0][0] *= gfp->scale; - m[0][1] *= gfp->scale; - m[1][0] *= gfp->scale; - m[1][1] *= gfp->scale; - /* user selected scaling of the channel 0 (left) samples */ - m[0][0] *= gfp->scale_left; - m[0][1] *= gfp->scale_left; - /* user selected scaling of the channel 1 (right) samples */ - m[1][0] *= gfp->scale_right; - m[1][1] *= gfp->scale_right; - /* Downsample to Mono if 2 channels in and 1 channel out */ - if (cfg->channels_in == 2 && cfg->channels_out == 1) { - m[0][0] = 0.5f * (m[0][0] + m[1][0]); - m[0][1] = 0.5f * (m[0][1] + m[1][1]); - m[1][0] = 0; - m[1][1] = 0; - } - cfg->pcm_transform[0][0] = m[0][0]; - cfg->pcm_transform[0][1] = m[0][1]; - cfg->pcm_transform[1][0] = m[1][0]; - cfg->pcm_transform[1][1] = m[1][1]; - } - - /* padding method as described in - * "MPEG-Layer3 / Bitstream Syntax and Decoding" - * by Martin Sieler, Ralph Sperschneider - * - * note: there is no padding for the very first frame - * - * Robert Hegemann 2000-06-22 - */ - gfc->sv_enc.slot_lag = gfc->sv_enc.frac_SpF = 0; - if (cfg->vbr == vbr_off) - gfc->sv_enc.slot_lag = gfc->sv_enc.frac_SpF - = ((cfg->version + 1) * 72000L * cfg->avg_bitrate) % cfg->samplerate_out; - - (void) lame_init_bitstream(gfp); - - iteration_init(gfc); - (void) psymodel_init(gfp); - - cfg->buffer_constraint = get_max_frame_buffer_size_by_constraint(cfg, gfp->strict_ISO); - - - cfg->findReplayGain = gfp->findReplayGain; - cfg->decode_on_the_fly = gfp->decode_on_the_fly; - - if (cfg->decode_on_the_fly) - cfg->findPeakSample = 1; - - if (cfg->findReplayGain) { - if (InitGainAnalysis(gfc->sv_rpg.rgdata, cfg->samplerate_out) == INIT_GAIN_ANALYSIS_ERROR) { - /* Actually this never happens, our samplerates are the ones RG accepts! - * But just in case, turn RG off - */ - assert(0); - cfg->findReplayGain = 0; - } - } - -#ifdef DECODE_ON_THE_FLY - if (cfg->decode_on_the_fly && !gfp->decode_only) { - if (gfc->hip) { - hip_decode_exit(gfc->hip); - } - gfc->hip = hip_decode_init(); - /* report functions */ - hip_set_errorf(gfc->hip, gfp->report.errorf); - hip_set_debugf(gfc->hip, gfp->report.debugf); - hip_set_msgf(gfc->hip, gfp->report.msgf); - } -#endif - /* updating lame internal flags finished successful */ - gfc->lame_init_params_successful = 1; - return 0; -} - -static void -concatSep(char* dest, char const* sep, char const* str) -{ - if (*dest != 0) strcat(dest, sep); - strcat(dest, str); -} - -/* - * print_config - * - * Prints some selected information about the coding parameters via - * the macro command MSGF(), which is currently mapped to lame_errorf - * (reports via a error function?), which is a printf-like function - * for . - */ - -void -lame_print_config(const lame_global_flags * gfp) -{ - lame_internal_flags const *const gfc = gfp->internal_flags; - SessionConfig_t const *const cfg = &gfc->cfg; - double const out_samplerate = cfg->samplerate_out; - double const in_samplerate = cfg->samplerate_in; - - MSGF(gfc, "LAME %s %s (%s)\n", get_lame_version(), get_lame_os_bitness(), get_lame_url()); - -#if (LAME_ALPHA_VERSION) - MSGF(gfc, "warning: alpha versions should be used for testing only\n"); -#endif - if (gfc->CPU_features.MMX - || gfc->CPU_features.AMD_3DNow || gfc->CPU_features.SSE || gfc->CPU_features.SSE2) { - char text[256] = { 0 }; - int fft_asm_used = 0; -#ifdef HAVE_NASM - if (gfc->CPU_features.AMD_3DNow) { - fft_asm_used = 1; - } - else if (gfc->CPU_features.SSE) { - fft_asm_used = 2; - } -#else -# if defined( HAVE_XMMINTRIN_H ) && defined( MIN_ARCH_SSE ) - { - fft_asm_used = 3; - } -# endif -#endif - if (gfc->CPU_features.MMX) { -#ifdef MMX_choose_table - concatSep(text, ", ", "MMX (ASM used)"); -#else - concatSep(text, ", ", "MMX"); -#endif - } - if (gfc->CPU_features.AMD_3DNow) { - concatSep(text, ", ", (fft_asm_used == 1) ? "3DNow! (ASM used)" : "3DNow!"); - } - if (gfc->CPU_features.SSE) { -#if defined(HAVE_XMMINTRIN_H) - concatSep(text, ", ", "SSE (ASM used)"); -#else - concatSep(text, ", ", (fft_asm_used == 2) ? "SSE (ASM used)" : "SSE"); -#endif - } - if (gfc->CPU_features.SSE2) { - concatSep(text, ", ", (fft_asm_used == 3) ? "SSE2 (ASM used)" : "SSE2"); - } - MSGF(gfc, "CPU features: %s\n", text); - } - - if (cfg->channels_in == 2 && cfg->channels_out == 1 /* mono */ ) { - MSGF(gfc, "Autoconverting from stereo to mono. Setting encoding to mono mode.\n"); - } - - if (isResamplingNecessary(cfg)) { - MSGF(gfc, "Resampling: input %g kHz output %g kHz\n", - 1.e-3 * in_samplerate, 1.e-3 * out_samplerate); - } - - if (cfg->highpass2 > 0.) - MSGF(gfc, - "Using polyphase highpass filter, transition band: %5.0f Hz - %5.0f Hz\n", - 0.5 * cfg->highpass1 * out_samplerate, 0.5 * cfg->highpass2 * out_samplerate); - if (0. < cfg->lowpass1 || 0. < cfg->lowpass2) { - MSGF(gfc, - "Using polyphase lowpass filter, transition band: %5.0f Hz - %5.0f Hz\n", - 0.5 * cfg->lowpass1 * out_samplerate, 0.5 * cfg->lowpass2 * out_samplerate); - } - else { - MSGF(gfc, "polyphase lowpass filter disabled\n"); - } - - if (cfg->free_format) { - MSGF(gfc, "Warning: many decoders cannot handle free format bitstreams\n"); - if (cfg->avg_bitrate > 320) { - MSGF(gfc, - "Warning: many decoders cannot handle free format bitrates >320 kbps (see documentation)\n"); - } - } -} - - -/** rh: - * some pretty printing is very welcome at this point! - * so, if someone is willing to do so, please do it! - * add more, if you see more... - */ -void -lame_print_internals(const lame_global_flags * gfp) -{ - lame_internal_flags const *const gfc = gfp->internal_flags; - SessionConfig_t const *const cfg = &gfc->cfg; - const char *pc = ""; - - /* compiler/processor optimizations, operational, etc. - */ - MSGF(gfc, "\nmisc:\n\n"); - - MSGF(gfc, "\tscaling: %g\n", gfp->scale); - MSGF(gfc, "\tch0 (left) scaling: %g\n", gfp->scale_left); - MSGF(gfc, "\tch1 (right) scaling: %g\n", gfp->scale_right); - switch (cfg->use_best_huffman) { - default: - pc = "normal"; - break; - case 1: - pc = "best (outside loop)"; - break; - case 2: - pc = "best (inside loop, slow)"; - break; - } - MSGF(gfc, "\thuffman search: %s\n", pc); - MSGF(gfc, "\texperimental Y=%d\n", gfp->experimentalY); - MSGF(gfc, "\t...\n"); - - /* everything controlling the stream format - */ - MSGF(gfc, "\nstream format:\n\n"); - switch (cfg->version) { - case 0: - pc = "2.5"; - break; - case 1: - pc = "1"; - break; - case 2: - pc = "2"; - break; - default: - pc = "?"; - break; - } - MSGF(gfc, "\tMPEG-%s Layer 3\n", pc); - switch (cfg->mode) { - case JOINT_STEREO: - pc = "joint stereo"; - break; - case STEREO: - pc = "stereo"; - break; - case DUAL_CHANNEL: - pc = "dual channel"; - break; - case MONO: - pc = "mono"; - break; - case NOT_SET: - pc = "not set (error)"; - break; - default: - pc = "unknown (error)"; - break; - } - MSGF(gfc, "\t%d channel - %s\n", cfg->channels_out, pc); - - switch (cfg->vbr) { - case vbr_off: - pc = "off"; - break; - default: - pc = "all"; - break; - } - MSGF(gfc, "\tpadding: %s\n", pc); - - if (vbr_default == cfg->vbr) - pc = "(default)"; - else if (cfg->free_format) - pc = "(free format)"; - else - pc = ""; - switch (cfg->vbr) { - case vbr_off: - MSGF(gfc, "\tconstant bitrate - CBR %s\n", pc); - break; - case vbr_abr: - MSGF(gfc, "\tvariable bitrate - ABR %s\n", pc); - break; - case vbr_rh: - MSGF(gfc, "\tvariable bitrate - VBR rh %s\n", pc); - break; - case vbr_mt: - MSGF(gfc, "\tvariable bitrate - VBR mt %s\n", pc); - break; - case vbr_mtrh: - MSGF(gfc, "\tvariable bitrate - VBR mtrh %s\n", pc); - break; - default: - MSGF(gfc, "\t ?? oops, some new one ?? \n"); - break; - } - if (cfg->write_lame_tag) - MSGF(gfc, "\tusing LAME Tag\n"); - MSGF(gfc, "\t...\n"); - - /* everything controlling psychoacoustic settings, like ATH, etc. - */ - MSGF(gfc, "\npsychoacoustic:\n\n"); - - switch (cfg->short_blocks) { - default: - case short_block_not_set: - pc = "?"; - break; - case short_block_allowed: - pc = "allowed"; - break; - case short_block_coupled: - pc = "channel coupled"; - break; - case short_block_dispensed: - pc = "dispensed"; - break; - case short_block_forced: - pc = "forced"; - break; - } - MSGF(gfc, "\tusing short blocks: %s\n", pc); - MSGF(gfc, "\tsubblock gain: %d\n", cfg->subblock_gain); - MSGF(gfc, "\tadjust masking: %g dB\n", gfc->sv_qnt.mask_adjust); - MSGF(gfc, "\tadjust masking short: %g dB\n", gfc->sv_qnt.mask_adjust_short); - MSGF(gfc, "\tquantization comparison: %d\n", cfg->quant_comp); - MSGF(gfc, "\t ^ comparison short blocks: %d\n", cfg->quant_comp_short); - MSGF(gfc, "\tnoise shaping: %d\n", cfg->noise_shaping); - MSGF(gfc, "\t ^ amplification: %d\n", cfg->noise_shaping_amp); - MSGF(gfc, "\t ^ stopping: %d\n", cfg->noise_shaping_stop); - - pc = "using"; - if (cfg->ATHshort) - pc = "the only masking for short blocks"; - if (cfg->ATHonly) - pc = "the only masking"; - if (cfg->noATH) - pc = "not used"; - MSGF(gfc, "\tATH: %s\n", pc); - MSGF(gfc, "\t ^ type: %d\n", cfg->ATHtype); - MSGF(gfc, "\t ^ shape: %g%s\n", cfg->ATHcurve, " (only for type 4)"); - MSGF(gfc, "\t ^ level adjustement: %g dB\n", cfg->ATH_offset_db); - MSGF(gfc, "\t ^ adjust type: %d\n", gfc->ATH->use_adjust); - MSGF(gfc, "\t ^ adjust sensitivity power: %f\n", gfc->ATH->aa_sensitivity_p); - - MSGF(gfc, "\texperimental psy tunings by Naoki Shibata\n"); - MSGF(gfc, "\t adjust masking bass=%g dB, alto=%g dB, treble=%g dB, sfb21=%g dB\n", - 10 * log10(gfc->sv_qnt.longfact[0]), - 10 * log10(gfc->sv_qnt.longfact[7]), - 10 * log10(gfc->sv_qnt.longfact[14]), 10 * log10(gfc->sv_qnt.longfact[21])); - - pc = cfg->use_temporal_masking_effect ? "yes" : "no"; - MSGF(gfc, "\tusing temporal masking effect: %s\n", pc); - MSGF(gfc, "\tinterchannel masking ratio: %g\n", cfg->interChRatio); - MSGF(gfc, "\t...\n"); - - /* that's all ? - */ - MSGF(gfc, "\n"); - return; -} - - -static void -save_gain_values(lame_internal_flags * gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - RpgStateVar_t const *const rsv = &gfc->sv_rpg; - RpgResult_t *const rov = &gfc->ov_rpg; - /* save the ReplayGain value */ - if (cfg->findReplayGain) { - FLOAT const RadioGain = (FLOAT) GetTitleGain(rsv->rgdata); - if (NEQ(RadioGain, (float)GAIN_NOT_ENOUGH_SAMPLES)) { - rov->RadioGain = (int) floor(RadioGain * 10.0 + 0.5); /* round to nearest */ - } - else { - rov->RadioGain = 0; - } - } - - /* find the gain and scale change required for no clipping */ - if (cfg->findPeakSample) { - rov->noclipGainChange = (int) ceil(log10(rov->PeakSample / 32767.0) * 20.0 * 10.0); /* round up */ - - if (rov->noclipGainChange > 0) { /* clipping occurs */ - rov->noclipScale = floor((32767.0f / rov->PeakSample) * 100.0f) / 100.0f; /* round down */ - } - else /* no clipping */ - rov->noclipScale = -1.0f; - } -} - - - -static int -update_inbuffer_size(lame_internal_flags * gfc, const int nsamples) -{ - EncStateVar_t *const esv = &gfc->sv_enc; - if (esv->in_buffer_0 == 0 || esv->in_buffer_nsamples < nsamples) { - if (esv->in_buffer_0) { - free(esv->in_buffer_0); - } - if (esv->in_buffer_1) { - free(esv->in_buffer_1); - } - esv->in_buffer_0 = lame_calloc(sample_t, nsamples); - esv->in_buffer_1 = lame_calloc(sample_t, nsamples); - esv->in_buffer_nsamples = nsamples; - } - if (esv->in_buffer_0 == NULL || esv->in_buffer_1 == NULL) { - if (esv->in_buffer_0) { - free(esv->in_buffer_0); - } - if (esv->in_buffer_1) { - free(esv->in_buffer_1); - } - esv->in_buffer_0 = 0; - esv->in_buffer_1 = 0; - esv->in_buffer_nsamples = 0; - ERRORF(gfc, "Error: can't allocate in_buffer buffer\n"); - return -2; - } - return 0; -} - - -static int -calcNeeded(SessionConfig_t const * cfg) -{ - int mf_needed; - int pcm_samples_per_frame = 576 * cfg->mode_gr; - - /* some sanity checks */ -#if ENCDELAY < MDCTDELAY -# error ENCDELAY is less than MDCTDELAY, see encoder.h -#endif -#if FFTOFFSET > BLKSIZE -# error FFTOFFSET is greater than BLKSIZE, see encoder.h -#endif - - mf_needed = BLKSIZE + pcm_samples_per_frame - FFTOFFSET; /* amount needed for FFT */ - /*mf_needed = Max(mf_needed, 286 + 576 * (1 + gfc->mode_gr)); */ - mf_needed = Max(mf_needed, 512 + pcm_samples_per_frame - 32); - - assert(MFSIZE >= mf_needed); - - return mf_needed; -} - - -/* - * THE MAIN LAME ENCODING INTERFACE - * mt 3/00 - * - * input pcm data, output (maybe) mp3 frames. - * This routine handles all buffering, resampling and filtering for you. - * The required mp3buffer_size can be computed from num_samples, - * samplerate and encoding rate, but here is a worst case estimate: - * - * mp3buffer_size in bytes = 1.25*num_samples + 7200 - * - * return code = number of bytes output in mp3buffer. can be 0 - * - * NOTE: this routine uses LAME's internal PCM data representation, - * 'sample_t'. It should not be used by any application. - * applications should use lame_encode_buffer(), - * lame_encode_buffer_float() - * lame_encode_buffer_int() - * etc... depending on what type of data they are working with. -*/ -static int -lame_encode_buffer_sample_t(lame_internal_flags * gfc, - int nsamples, unsigned char *mp3buf, const int mp3buf_size) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int pcm_samples_per_frame = 576 * cfg->mode_gr; - int mp3size = 0, ret, i, ch, mf_needed; - int mp3out; - sample_t *mfbuf[2]; - sample_t *in_buffer[2]; - - if (gfc->class_id != LAME_ID) - return -3; - - if (nsamples == 0) - return 0; - - /* copy out any tags that may have been written into bitstream */ - { /* if user specifed buffer size = 0, dont check size */ - int const buf_size = mp3buf_size == 0 ? INT_MAX : mp3buf_size; - mp3out = copy_buffer(gfc, mp3buf, buf_size, 0); - } - if (mp3out < 0) - return mp3out; /* not enough buffer space */ - mp3buf += mp3out; - mp3size += mp3out; - - in_buffer[0] = esv->in_buffer_0; - in_buffer[1] = esv->in_buffer_1; - - mf_needed = calcNeeded(cfg); - - mfbuf[0] = esv->mfbuf[0]; - mfbuf[1] = esv->mfbuf[1]; - - while (nsamples > 0) { - sample_t const *in_buffer_ptr[2]; - int n_in = 0; /* number of input samples processed with fill_buffer */ - int n_out = 0; /* number of samples output with fill_buffer */ - /* n_in <> n_out if we are resampling */ - - in_buffer_ptr[0] = in_buffer[0]; - in_buffer_ptr[1] = in_buffer[1]; - /* copy in new samples into mfbuf, with resampling */ - fill_buffer(gfc, mfbuf, &in_buffer_ptr[0], nsamples, &n_in, &n_out); - - /* compute ReplayGain of resampled input if requested */ - if (cfg->findReplayGain && !cfg->decode_on_the_fly) - if (AnalyzeSamples - (gfc->sv_rpg.rgdata, &mfbuf[0][esv->mf_size], &mfbuf[1][esv->mf_size], n_out, - cfg->channels_out) == GAIN_ANALYSIS_ERROR) - return -6; - - - - /* update in_buffer counters */ - nsamples -= n_in; - in_buffer[0] += n_in; - if (cfg->channels_out == 2) - in_buffer[1] += n_in; - - /* update mfbuf[] counters */ - esv->mf_size += n_out; - assert(esv->mf_size <= MFSIZE); - - /* lame_encode_flush may have set gfc->mf_sample_to_encode to 0 - * so we have to reinitialize it here when that happened. - */ - if (esv->mf_samples_to_encode < 1) { - esv->mf_samples_to_encode = ENCDELAY + POSTDELAY; - } - esv->mf_samples_to_encode += n_out; - - - if (esv->mf_size >= mf_needed) { - /* encode the frame. */ - /* mp3buf = pointer to current location in buffer */ - /* mp3buf_size = size of original mp3 output buffer */ - /* = 0 if we should not worry about the */ - /* buffer size because calling program is */ - /* to lazy to compute it */ - /* mp3size = size of data written to buffer so far */ - /* mp3buf_size-mp3size = amount of space avalable */ - - int buf_size = mp3buf_size - mp3size; - if (mp3buf_size == 0) - buf_size = INT_MAX; - - ret = lame_encode_mp3_frame(gfc, mfbuf[0], mfbuf[1], mp3buf, buf_size); - - if (ret < 0) - return ret; - mp3buf += ret; - mp3size += ret; - - /* shift out old samples */ - esv->mf_size -= pcm_samples_per_frame; - esv->mf_samples_to_encode -= pcm_samples_per_frame; - for (ch = 0; ch < cfg->channels_out; ch++) - for (i = 0; i < esv->mf_size; i++) - mfbuf[ch][i] = mfbuf[ch][i + pcm_samples_per_frame]; - } - } - assert(nsamples == 0); - - return mp3size; -} - -enum PCMSampleType -{ pcm_short_type -, pcm_int_type -, pcm_long_type -, pcm_float_type -, pcm_double_type -}; - -static void -lame_copy_inbuffer(lame_internal_flags* gfc, - void const* l, void const* r, int nsamples, - enum PCMSampleType pcm_type, int jump, FLOAT s) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - sample_t* ib0 = esv->in_buffer_0; - sample_t* ib1 = esv->in_buffer_1; - FLOAT m[2][2]; - - /* Apply user defined re-scaling */ - m[0][0] = s * cfg->pcm_transform[0][0]; - m[0][1] = s * cfg->pcm_transform[0][1]; - m[1][0] = s * cfg->pcm_transform[1][0]; - m[1][1] = s * cfg->pcm_transform[1][1]; - - /* make a copy of input buffer, changing type to sample_t */ -#define COPY_AND_TRANSFORM(T) \ -{ \ - T const *bl = l, *br = r; \ - int i; \ - for (i = 0; i < nsamples; i++) { \ - sample_t const xl = *bl; \ - sample_t const xr = *br; \ - sample_t const u = xl * m[0][0] + xr * m[0][1]; \ - sample_t const v = xl * m[1][0] + xr * m[1][1]; \ - ib0[i] = u; \ - ib1[i] = v; \ - bl += jump; \ - br += jump; \ - } \ -} - switch ( pcm_type ) { - case pcm_short_type: - COPY_AND_TRANSFORM(short int); - break; - case pcm_int_type: - COPY_AND_TRANSFORM(int); - break; - case pcm_long_type: - COPY_AND_TRANSFORM(long int); - break; - case pcm_float_type: - COPY_AND_TRANSFORM(float); - break; - case pcm_double_type: - COPY_AND_TRANSFORM(double); - break; - } -} - - -static int -lame_encode_buffer_template(lame_global_flags * gfp, - void const* buffer_l, void const* buffer_r, const int nsamples, - unsigned char *mp3buf, const int mp3buf_size, enum PCMSampleType pcm_type, int aa, FLOAT norm) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - - if (nsamples == 0) - return 0; - - if (update_inbuffer_size(gfc, nsamples) != 0) { - return -2; - } - /* make a copy of input buffer, changing type to sample_t */ - if (cfg->channels_in > 1) { - if (buffer_l == 0 || buffer_r == 0) { - return 0; - } - lame_copy_inbuffer(gfc, buffer_l, buffer_r, nsamples, pcm_type, aa, norm); - } - else { - if (buffer_l == 0) { - return 0; - } - lame_copy_inbuffer(gfc, buffer_l, buffer_l, nsamples, pcm_type, aa, norm); - } - - return lame_encode_buffer_sample_t(gfc, nsamples, mp3buf, mp3buf_size); - } - } - return -3; -} - -int -lame_encode_buffer(lame_global_flags * gfp, - const short int pcm_l[], const short int pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_short_type, 1, 1.0); -} - - -int -lame_encode_buffer_float(lame_global_flags * gfp, - const float pcm_l[], const float pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 32768 for full scale */ - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_float_type, 1, 1.0); -} - - -int -lame_encode_buffer_ieee_float(lame_t gfp, - const float pcm_l[], const float pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 1.0 for full scale */ - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_float_type, 1, 32767.0); -} - - -int -lame_encode_buffer_interleaved_ieee_float(lame_t gfp, - const float pcm[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 1.0 for full scale */ - return lame_encode_buffer_template(gfp, pcm, pcm+1, nsamples, mp3buf, mp3buf_size, pcm_float_type, 2, 32767.0); -} - - -int -lame_encode_buffer_ieee_double(lame_t gfp, - const double pcm_l[], const double pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 1.0 for full scale */ - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_double_type, 1, 32767.0); -} - - -int -lame_encode_buffer_interleaved_ieee_double(lame_t gfp, - const double pcm[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 1.0 for full scale */ - return lame_encode_buffer_template(gfp, pcm, pcm+1, nsamples, mp3buf, mp3buf_size, pcm_double_type, 2, 32767.0); -} - - -int -lame_encode_buffer_int(lame_global_flags * gfp, - const int pcm_l[], const int pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- MAX_INT for full scale */ - FLOAT const norm = (1.0 / (1L << (8 * sizeof(int) - 16))); - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_int_type, 1, norm); -} - - -int -lame_encode_buffer_long2(lame_global_flags * gfp, - const long pcm_l[], const long pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- MAX_LONG for full scale */ - FLOAT const norm = (1.0 / (1L << (8 * sizeof(long) - 16))); - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_long_type, 1, norm); -} - - -int -lame_encode_buffer_long(lame_global_flags * gfp, - const long pcm_l[], const long pcm_r[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- 32768 for full scale */ - return lame_encode_buffer_template(gfp, pcm_l, pcm_r, nsamples, mp3buf, mp3buf_size, pcm_long_type, 1, 1.0); -} - - - -int -lame_encode_buffer_interleaved(lame_global_flags * gfp, - short int pcm[], int nsamples, - unsigned char *mp3buf, int mp3buf_size) -{ - /* input is assumed to be normalized to +/- MAX_SHORT for full scale */ - return lame_encode_buffer_template(gfp, pcm, pcm+1, nsamples, mp3buf, mp3buf_size, pcm_short_type, 2, 1.0); -} - - -int -lame_encode_buffer_interleaved_int(lame_t gfp, - const int pcm[], const int nsamples, - unsigned char *mp3buf, const int mp3buf_size) -{ - /* input is assumed to be normalized to +/- MAX(int) for full scale */ - FLOAT const norm = (1.0 / (1L << (8 * sizeof(int)-16))); - return lame_encode_buffer_template(gfp, pcm, pcm + 1, nsamples, mp3buf, mp3buf_size, pcm_int_type, 2, norm); -} - - - - -/***************************************************************** - Flush mp3 buffer, pad with ancillary data so last frame is complete. - Reset reservoir size to 0 - but keep all PCM samples and MDCT data in memory - This option is used to break a large file into several mp3 files - that when concatenated together will decode with no gaps - Because we set the reservoir=0, they will also decode seperately - with no errors. -*********************************************************************/ -int -lame_encode_flush_nogap(lame_global_flags * gfp, unsigned char *mp3buffer, int mp3buffer_size) -{ - int rc = -3; - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - flush_bitstream(gfc); - /* if user specifed buffer size = 0, dont check size */ - if (mp3buffer_size == 0) - mp3buffer_size = INT_MAX; - rc = copy_buffer(gfc, mp3buffer, mp3buffer_size, 1); - save_gain_values(gfc); - } - } - return rc; -} - - -/* called by lame_init_params. You can also call this after flush_nogap - if you want to write new id3v2 and Xing VBR tags into the bitstream */ -int -lame_init_bitstream(lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags *const gfc = gfp->internal_flags; - if (gfc != 0) { - gfc->ov_enc.frame_number = 0; - - if (gfp->write_id3tag_automatic) { - (void) id3tag_write_v2(gfp); - } - /* initialize histogram data optionally used by frontend */ - memset(gfc->ov_enc.bitrate_channelmode_hist, 0, - sizeof(gfc->ov_enc.bitrate_channelmode_hist)); - memset(gfc->ov_enc.bitrate_blocktype_hist, 0, - sizeof(gfc->ov_enc.bitrate_blocktype_hist)); - - gfc->ov_rpg.PeakSample = 0.0; - - /* Write initial VBR Header to bitstream and init VBR data */ - if (gfc->cfg.write_lame_tag) - (void) InitVbrTag(gfp); - - - return 0; - } - } - return -3; -} - - -/*****************************************************************/ -/* flush internal PCM sample buffers, then mp3 buffers */ -/* then write id3 v1 tags into bitstream. */ -/*****************************************************************/ - -int -lame_encode_flush(lame_global_flags * gfp, unsigned char *mp3buffer, int mp3buffer_size) -{ - lame_internal_flags *gfc; - SessionConfig_t const *cfg; - EncStateVar_t *esv; - short int buffer[2][1152]; - int imp3 = 0, mp3count, mp3buffer_size_remaining; - - /* we always add POSTDELAY=288 padding to make sure granule with real - * data can be complety decoded (because of 50% overlap with next granule */ - int end_padding; - int frames_left; - int samples_to_encode; - int pcm_samples_per_frame; - int mf_needed; - int is_resampling_necessary; - double resample_ratio = 1; - - if (!is_lame_global_flags_valid(gfp)) { - return -3; - } - gfc = gfp->internal_flags; - if (!is_lame_internal_flags_valid(gfc)) { - return -3; - } - cfg = &gfc->cfg; - esv = &gfc->sv_enc; - - /* Was flush already called? */ - if (esv->mf_samples_to_encode < 1) { - return 0; - } - pcm_samples_per_frame = 576 * cfg->mode_gr; - mf_needed = calcNeeded(cfg); - - samples_to_encode = esv->mf_samples_to_encode - POSTDELAY; - - memset(buffer, 0, sizeof(buffer)); - mp3count = 0; - - is_resampling_necessary = isResamplingNecessary(cfg); - if (is_resampling_necessary) { - resample_ratio = (double)cfg->samplerate_in / (double)cfg->samplerate_out; - /* delay due to resampling; needs to be fixed, if resampling code gets changed */ - samples_to_encode += 16. / resample_ratio; - } - end_padding = pcm_samples_per_frame - (samples_to_encode % pcm_samples_per_frame); - if (end_padding < 576) - end_padding += pcm_samples_per_frame; - gfc->ov_enc.encoder_padding = end_padding; - - frames_left = (samples_to_encode + end_padding) / pcm_samples_per_frame; - while (frames_left > 0 && imp3 >= 0) { - int const frame_num = gfc->ov_enc.frame_number; - int bunch = mf_needed - esv->mf_size; - - bunch *= resample_ratio; - if (bunch > 1152) bunch = 1152; - if (bunch < 1) bunch = 1; - - mp3buffer_size_remaining = mp3buffer_size - mp3count; - - /* if user specifed buffer size = 0, dont check size */ - if (mp3buffer_size == 0) - mp3buffer_size_remaining = 0; - - /* send in a frame of 0 padding until all internal sample buffers - * are flushed - */ - imp3 = lame_encode_buffer(gfp, buffer[0], buffer[1], bunch, - mp3buffer, mp3buffer_size_remaining); - - mp3buffer += imp3; - mp3count += imp3; - { /* even a single pcm sample can produce several frames! - * for example: 1 Hz input file resampled to 8 kHz mpeg2.5 - */ - int const new_frames = gfc->ov_enc.frame_number - frame_num; - if (new_frames > 0) - frames_left -= new_frames; - } - } - /* Set esv->mf_samples_to_encode to 0, so we may detect - * and break loops calling it more than once in a row. - */ - esv->mf_samples_to_encode = 0; - - if (imp3 < 0) { - /* some type of fatal error */ - return imp3; - } - - mp3buffer_size_remaining = mp3buffer_size - mp3count; - /* if user specifed buffer size = 0, dont check size */ - if (mp3buffer_size == 0) - mp3buffer_size_remaining = INT_MAX; - - /* mp3 related stuff. bit buffer might still contain some mp3 data */ - flush_bitstream(gfc); - imp3 = copy_buffer(gfc, mp3buffer, mp3buffer_size_remaining, 1); - save_gain_values(gfc); - if (imp3 < 0) { - /* some type of fatal error */ - return imp3; - } - mp3buffer += imp3; - mp3count += imp3; - mp3buffer_size_remaining = mp3buffer_size - mp3count; - /* if user specifed buffer size = 0, dont check size */ - if (mp3buffer_size == 0) - mp3buffer_size_remaining = INT_MAX; - - if (gfp->write_id3tag_automatic) { - /* write a id3 tag to the bitstream */ - (void) id3tag_write_v1(gfp); - - imp3 = copy_buffer(gfc, mp3buffer, mp3buffer_size_remaining, 0); - - if (imp3 < 0) { - return imp3; - } - mp3count += imp3; - } -#if 0 - { - int const ed = gfc->ov_enc.encoder_delay; - int const ep = gfc->ov_enc.encoder_padding; - int const ns = (gfc->ov_enc.frame_number * pcm_samples_per_frame) - (ed + ep); - double duration = ns; - duration /= cfg->samplerate_out; - MSGF(gfc, "frames=%d\n", gfc->ov_enc.frame_number); - MSGF(gfc, "pcm_samples_per_frame=%d\n", pcm_samples_per_frame); - MSGF(gfc, "encoder delay=%d\n", ed); - MSGF(gfc, "encoder padding=%d\n", ep); - MSGF(gfc, "sample count=%d (%g)\n", ns, cfg->samplerate_in * duration); - MSGF(gfc, "duration=%g sec\n", duration); - } -#endif - return mp3count; -} - -/*********************************************************************** - * - * lame_close () - * - * frees internal buffers - * - ***********************************************************************/ - -int -lame_close(lame_global_flags * gfp) -{ - int ret = 0; - if (gfp && gfp->class_id == LAME_ID) { - lame_internal_flags *const gfc = gfp->internal_flags; - gfp->class_id = 0; - if (NULL == gfc || gfc->class_id != LAME_ID) { - ret = -3; - } - if (NULL != gfc) { - gfc->lame_init_params_successful = 0; - gfc->class_id = 0; - /* this routine will free all malloc'd data in gfc, and then free gfc: */ - freegfc(gfc); - gfp->internal_flags = NULL; - } - if (gfp->lame_allocated_gfp) { - gfp->lame_allocated_gfp = 0; - free(gfp); - } - } - return ret; -} - -/*****************************************************************/ -/* flush internal mp3 buffers, and free internal buffers */ -/*****************************************************************/ -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -int CDECL -lame_encode_finish(lame_global_flags * gfp, unsigned char *mp3buffer, int mp3buffer_size); -#else -#endif - -int -lame_encode_finish(lame_global_flags * gfp, unsigned char *mp3buffer, int mp3buffer_size) -{ - int const ret = lame_encode_flush(gfp, mp3buffer, mp3buffer_size); - - (void) lame_close(gfp); - - return ret; -} - -/*****************************************************************/ -/* write VBR Xing header, and ID3 version 1 tag, if asked for */ -/*****************************************************************/ -void lame_mp3_tags_fid(lame_global_flags * gfp, FILE * fpStream); - -void -lame_mp3_tags_fid(lame_global_flags * gfp, FILE * fpStream) -{ - lame_internal_flags *gfc; - SessionConfig_t const *cfg; - if (!is_lame_global_flags_valid(gfp)) { - return; - } - gfc = gfp->internal_flags; - if (!is_lame_internal_flags_valid(gfc)) { - return; - } - cfg = &gfc->cfg; - if (!cfg->write_lame_tag) { - return; - } - /* Write Xing header again */ - if (fpStream && !fseek(fpStream, 0, SEEK_SET)) { - int rc = PutVbrTag(gfp, fpStream); - switch (rc) { - default: - /* OK */ - break; - - case -1: - ERRORF(gfc, "Error: could not update LAME tag.\n"); - break; - - case -2: - ERRORF(gfc, "Error: could not update LAME tag, file not seekable.\n"); - break; - - case -3: - ERRORF(gfc, "Error: could not update LAME tag, file not readable.\n"); - break; - } - } -} - - -static int -lame_init_internal_flags(lame_internal_flags* gfc) -{ - if (NULL == gfc) - return -1; - - gfc->cfg.vbr_min_bitrate_index = 1; /* not 0 ????? */ - gfc->cfg.vbr_max_bitrate_index = 13; /* not 14 ????? */ - gfc->cfg.decode_on_the_fly = 0; - gfc->cfg.findReplayGain = 0; - gfc->cfg.findPeakSample = 0; - - gfc->sv_qnt.OldValue[0] = 180; - gfc->sv_qnt.OldValue[1] = 180; - gfc->sv_qnt.CurrentStep[0] = 4; - gfc->sv_qnt.CurrentStep[1] = 4; - gfc->sv_qnt.masking_lower = 1; - - /* The reason for - * int mf_samples_to_encode = ENCDELAY + POSTDELAY; - * ENCDELAY = internal encoder delay. And then we have to add POSTDELAY=288 - * because of the 50% MDCT overlap. A 576 MDCT granule decodes to - * 1152 samples. To synthesize the 576 samples centered under this granule - * we need the previous granule for the first 288 samples (no problem), and - * the next granule for the next 288 samples (not possible if this is last - * granule). So we need to pad with 288 samples to make sure we can - * encode the 576 samples we are interested in. - */ - gfc->sv_enc.mf_samples_to_encode = ENCDELAY + POSTDELAY; - gfc->sv_enc.mf_size = ENCDELAY - MDCTDELAY; /* we pad input with this many 0's */ - gfc->ov_enc.encoder_padding = 0; - gfc->ov_enc.encoder_delay = ENCDELAY; - - gfc->ov_rpg.RadioGain = 0; - gfc->ov_rpg.noclipGainChange = 0; - gfc->ov_rpg.noclipScale = -1.0; - - gfc->ATH = lame_calloc(ATH_t, 1); - if (NULL == gfc->ATH) - return -2; /* maybe error codes should be enumerated in lame.h ?? */ - - gfc->sv_rpg.rgdata = lame_calloc(replaygain_t, 1); - if (NULL == gfc->sv_rpg.rgdata) { - return -2; - } - return 0; -} - -/* initialize mp3 encoder */ -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -static -#else -#endif -int -lame_init_old(lame_global_flags * gfp) -{ - disable_FPE(); /* disable floating point exceptions */ - - memset(gfp, 0, sizeof(lame_global_flags)); - - gfp->class_id = LAME_ID; - - /* Global flags. set defaults here for non-zero values */ - /* see lame.h for description */ - /* set integer values to -1 to mean that LAME will compute the - * best value, UNLESS the calling program as set it - * (and the value is no longer -1) - */ - gfp->strict_ISO = MDB_MAXIMUM; - - gfp->mode = NOT_SET; - gfp->original = 1; - gfp->samplerate_in = 44100; - gfp->num_channels = 2; - gfp->num_samples = MAX_U_32_NUM; - - gfp->write_lame_tag = 1; - gfp->quality = -1; - gfp->short_blocks = short_block_not_set; - gfp->subblock_gain = -1; - - gfp->lowpassfreq = 0; - gfp->highpassfreq = 0; - gfp->lowpasswidth = -1; - gfp->highpasswidth = -1; - - gfp->VBR = vbr_off; - gfp->VBR_q = 4; - gfp->VBR_mean_bitrate_kbps = 128; - gfp->VBR_min_bitrate_kbps = 0; - gfp->VBR_max_bitrate_kbps = 0; - gfp->VBR_hard_min = 0; - - gfp->quant_comp = -1; - gfp->quant_comp_short = -1; - - gfp->msfix = -1; - - gfp->attackthre = -1; - gfp->attackthre_s = -1; - - gfp->scale = 1; - gfp->scale_left = 1; - gfp->scale_right = 1; - - gfp->ATHcurve = -1; - gfp->ATHtype = -1; /* default = -1 = set in lame_init_params */ - /* 2 = equal loudness curve */ - gfp->athaa_sensitivity = 0.0; /* no offset */ - gfp->athaa_type = -1; - gfp->useTemporal = -1; - gfp->interChRatio = -1; - - gfp->findReplayGain = 0; - gfp->decode_on_the_fly = 0; - - gfp->asm_optimizations.mmx = 1; - gfp->asm_optimizations.amd3dnow = 1; - gfp->asm_optimizations.sse = 1; - - gfp->preset = 0; - - gfp->write_id3tag_automatic = 1; - - gfp->report.debugf = &lame_report_def; - gfp->report.errorf = &lame_report_def; - gfp->report.msgf = &lame_report_def; - - gfp->internal_flags = lame_calloc(lame_internal_flags, 1); - - if (lame_init_internal_flags(gfp->internal_flags) < 0) { - freegfc(gfp->internal_flags); - gfp->internal_flags = 0; - return -1; - } - return 0; -} - - -lame_global_flags * -lame_init(void) -{ - lame_global_flags *gfp; - int ret; - - init_log_table(); - - gfp = lame_calloc(lame_global_flags, 1); - if (gfp == NULL) - return NULL; - - ret = lame_init_old(gfp); - if (ret != 0) { - free(gfp); - return NULL; - } - - gfp->lame_allocated_gfp = 1; - return gfp; -} - - -/*********************************************************************** - * - * some simple statistics - * - * Robert Hegemann 2000-10-11 - * - ***********************************************************************/ - -/* histogram of used bitrate indexes: - * One has to weight them to calculate the average bitrate in kbps - * - * bitrate indices: - * there are 14 possible bitrate indices, 0 has the special meaning - * "free format" which is not possible to mix with VBR and 15 is forbidden - * anyway. - * - * stereo modes: - * 0: LR number of left-right encoded frames - * 1: LR-I number of left-right and intensity encoded frames - * 2: MS number of mid-side encoded frames - * 3: MS-I number of mid-side and intensity encoded frames - * - * 4: number of encoded frames - * - */ - -void -lame_bitrate_kbps(const lame_global_flags * gfp, int bitrate_kbps[14]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - int i; - if (cfg->free_format) { - for (i = 0; i < 14; i++) - bitrate_kbps[i] = -1; - bitrate_kbps[0] = cfg->avg_bitrate; - } - else { - for (i = 0; i < 14; i++) - bitrate_kbps[i] = bitrate_table[cfg->version][i + 1]; - } - } - } -} - - -void -lame_bitrate_hist(const lame_global_flags * gfp, int bitrate_count[14]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - int i; - - if (cfg->free_format) { - for (i = 0; i < 14; i++) { - bitrate_count[i] = 0; - } - bitrate_count[0] = eov->bitrate_channelmode_hist[0][4]; - } - else { - for (i = 0; i < 14; i++) { - bitrate_count[i] = eov->bitrate_channelmode_hist[i + 1][4]; - } - } - } - } -} - - -void -lame_stereo_mode_hist(const lame_global_flags * gfp, int stmode_count[4]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - EncResult_t const *const eov = &gfc->ov_enc; - int i; - - for (i = 0; i < 4; i++) { - stmode_count[i] = eov->bitrate_channelmode_hist[15][i]; - } - } - } -} - - - -void -lame_bitrate_stereo_mode_hist(const lame_global_flags * gfp, int bitrate_stmode_count[14][4]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - int i; - int j; - - if (cfg->free_format) { - for (j = 0; j < 14; j++) - for (i = 0; i < 4; i++) { - bitrate_stmode_count[j][i] = 0; - } - for (i = 0; i < 4; i++) { - bitrate_stmode_count[0][i] = eov->bitrate_channelmode_hist[0][i]; - } - } - else { - for (j = 0; j < 14; j++) { - for (i = 0; i < 4; i++) { - bitrate_stmode_count[j][i] = eov->bitrate_channelmode_hist[j + 1][i]; - } - } - } - } - } -} - - -void -lame_block_type_hist(const lame_global_flags * gfp, int btype_count[6]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - EncResult_t const *const eov = &gfc->ov_enc; - int i; - - for (i = 0; i < 6; ++i) { - btype_count[i] = eov->bitrate_blocktype_hist[15][i]; - } - } - } -} - - - -void -lame_bitrate_block_type_hist(const lame_global_flags * gfp, int bitrate_btype_count[14][6]) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t const *const eov = &gfc->ov_enc; - int i, j; - - if (cfg->free_format) { - for (j = 0; j < 14; ++j) { - for (i = 0; i < 6; ++i) { - bitrate_btype_count[j][i] = 0; - } - } - for (i = 0; i < 6; ++i) { - bitrate_btype_count[0][i] = eov->bitrate_blocktype_hist[0][i]; - } - } - else { - for (j = 0; j < 14; ++j) { - for (i = 0; i < 6; ++i) { - bitrate_btype_count[j][i] = eov->bitrate_blocktype_hist[j + 1][i]; - } - } - } - } - } -} - -/* end of lame.c */ diff --git a/lib-src/lame/libmp3lame/lame.rc b/lib-src/lame/libmp3lame/lame.rc deleted file mode 100644 index 12d0193e2..000000000 --- a/lib-src/lame/libmp3lame/lame.rc +++ /dev/null @@ -1,50 +0,0 @@ -#include -#include "version.h" - -#ifdef _DLL -IDI_ICON1 ICON DISCARDABLE "logoe.ico" -#else -IDI_ICON1 ICON DISCARDABLE "logoe.ico" -#endif - -VS_VERSION_INFO VERSIONINFO - FILEVERSION LAME_MAJOR_VERSION,LAME_MINOR_VERSION,LAME_TYPE_VERSION,LAME_PATCH_VERSION - PRODUCTVERSION LAME_MAJOR_VERSION,LAME_MINOR_VERSION,LAME_TYPE_VERSION,LAME_PATCH_VERSION - FILEFLAGSMASK 0x3fL -#ifdef _DEBUG - FILEFLAGS VS_FF_DEBUG -#else - FILEFLAGS 0x0L -#endif - FILEOS VOS__WINDOWS32 -#ifdef _DLL - FILETYPE VFT_DLL -#else - FILETYPE VFT_APP -#endif - FILESUBTYPE 0x0L - BEGIN - BLOCK "StringFileInfo" - BEGIN - BLOCK "040904E4" // Lang=US English, CharSet=Windows Multilingual - BEGIN - VALUE "CompanyName", LAME_URL "\0" - VALUE "FileDescription", "MP3 Encoder.\0" - VALUE "FileVersion", LAME_VERSION_STRING "\0" - VALUE "LegalCopyright", "Copyright (C) 1999-2011 The L.A.M.E. Team\0" -#ifdef _DLL - VALUE "OriginalFilename", STR(_DLL) "\0" -#else - VALUE "OriginalFilename", STR(_APP) "\0" -#endif - VALUE "ProductName", "L.A.M.E.\0" - VALUE "ProductVersion", LAME_VERSION_STRING "\0" - END - END - BLOCK "VarFileInfo" - BEGIN - VALUE "Translation", 0x409, 1252 // mandatory by convention - END - END -/* End of Version info */ - diff --git a/lib-src/lame/libmp3lame/lame_global_flags.h b/lib-src/lame/libmp3lame/lame_global_flags.h deleted file mode 100644 index ad9e677da..000000000 --- a/lib-src/lame/libmp3lame/lame_global_flags.h +++ /dev/null @@ -1,184 +0,0 @@ -#ifndef LAME_GLOBAL_FLAGS_H -#define LAME_GLOBAL_FLAGS_H - -#ifndef lame_internal_flags_defined -#define lame_internal_flags_defined -struct lame_internal_flags; -typedef struct lame_internal_flags lame_internal_flags; -#endif - - -typedef enum short_block_e { - short_block_not_set = -1, /* allow LAME to decide */ - short_block_allowed = 0, /* LAME may use them, even different block types for L/R */ - short_block_coupled, /* LAME may use them, but always same block types in L/R */ - short_block_dispensed, /* LAME will not use short blocks, long blocks only */ - short_block_forced /* LAME will not use long blocks, short blocks only */ -} short_block_t; - -/*********************************************************************** -* -* Control Parameters set by User. These parameters are here for -* backwards compatibility with the old, non-shared lib API. -* Please use the lame_set_variablename() functions below -* -* -***********************************************************************/ -struct lame_global_struct { - unsigned int class_id; - - /* input description */ - unsigned long num_samples; /* number of samples. default=2^32-1 */ - int num_channels; /* input number of channels. default=2 */ - int samplerate_in; /* input_samp_rate in Hz. default=44.1 kHz */ - int samplerate_out; /* output_samp_rate. - default: LAME picks best value - at least not used for MP3 decoding: - Remember 44.1 kHz MP3s and AC97 */ - float scale; /* scale input by this amount before encoding - at least not used for MP3 decoding */ - float scale_left; /* scale input of channel 0 (left) by this - amount before encoding */ - float scale_right; /* scale input of channel 1 (right) by this - amount before encoding */ - - /* general control params */ - int analysis; /* collect data for a MP3 frame analyzer? */ - int write_lame_tag; /* add Xing VBR tag? */ - int decode_only; /* use lame/mpglib to convert mp3 to wav */ - int quality; /* quality setting 0=best, 9=worst default=5 */ - MPEG_mode mode; /* see enum in lame.h - default = LAME picks best value */ - int force_ms; /* force M/S mode. requires mode=1 */ - int free_format; /* use free format? default=0 */ - int findReplayGain; /* find the RG value? default=0 */ - int decode_on_the_fly; /* decode on the fly? default=0 */ - int write_id3tag_automatic; /* 1 (default) writes ID3 tags, 0 not */ - - int nogap_total; - int nogap_current; - - int substep_shaping; - int noise_shaping; - int subblock_gain; /* 0 = no, 1 = yes */ - int use_best_huffman; /* 0 = no. 1=outside loop 2=inside loop(slow) */ - - /* - * set either brate>0 or compression_ratio>0, LAME will compute - * the value of the variable not set. - * Default is compression_ratio = 11.025 - */ - int brate; /* bitrate */ - float compression_ratio; /* sizeof(wav file)/sizeof(mp3 file) */ - - - /* frame params */ - int copyright; /* mark as copyright. default=0 */ - int original; /* mark as original. default=1 */ - int extension; /* the MP3 'private extension' bit. - Meaningless */ - int emphasis; /* Input PCM is emphased PCM (for - instance from one of the rarely - emphased CDs), it is STRONGLY not - recommended to use this, because - psycho does not take it into account, - and last but not least many decoders - don't care about these bits */ - int error_protection; /* use 2 bytes per frame for a CRC - checksum. default=0 */ - int strict_ISO; /* enforce ISO spec as much as possible */ - - int disable_reservoir; /* use bit reservoir? */ - - /* quantization/noise shaping */ - int quant_comp; - int quant_comp_short; - int experimentalY; - int experimentalZ; - int exp_nspsytune; - - int preset; - - /* VBR control */ - vbr_mode VBR; - float VBR_q_frac; /* Range [0,...,1[ */ - int VBR_q; /* Range [0,...,9] */ - int VBR_mean_bitrate_kbps; - int VBR_min_bitrate_kbps; - int VBR_max_bitrate_kbps; - int VBR_hard_min; /* strictly enforce VBR_min_bitrate - normaly, it will be violated for analog - silence */ - - - /* resampling and filtering */ - int lowpassfreq; /* freq in Hz. 0=lame choses. - -1=no filter */ - int highpassfreq; /* freq in Hz. 0=lame choses. - -1=no filter */ - int lowpasswidth; /* freq width of filter, in Hz - (default=15%) */ - int highpasswidth; /* freq width of filter, in Hz - (default=15%) */ - - - - /* - * psycho acoustics and other arguments which you should not change - * unless you know what you are doing - */ - float maskingadjust; - float maskingadjust_short; - int ATHonly; /* only use ATH */ - int ATHshort; /* only use ATH for short blocks */ - int noATH; /* disable ATH */ - int ATHtype; /* select ATH formula */ - float ATHcurve; /* change ATH formula 4 shape */ - float ATH_lower_db; /* lower ATH by this many db */ - int athaa_type; /* select ATH auto-adjust scheme */ - float athaa_sensitivity; /* dB, tune active region of auto-level */ - short_block_t short_blocks; - int useTemporal; /* use temporal masking effect */ - float interChRatio; - float msfix; /* Naoki's adjustment of Mid/Side maskings */ - - int tune; /* 0 off, 1 on */ - float tune_value_a; /* used to pass values for debugging and stuff */ - - float attackthre; /* attack threshold for L/R/M channel */ - float attackthre_s; /* attack threshold for S channel */ - - - struct { - void (*msgf) (const char *format, va_list ap); - void (*debugf) (const char *format, va_list ap); - void (*errorf) (const char *format, va_list ap); - } report; - - /************************************************************************/ - /* internal variables, do not set... */ - /* provided because they may be of use to calling application */ - /************************************************************************/ - - int lame_allocated_gfp; /* is this struct owned by calling - program or lame? */ - - - - /**************************************************************************/ - /* more internal variables are stored in this structure: */ - /**************************************************************************/ - lame_internal_flags *internal_flags; - - - struct { - int mmx; - int amd3dnow; - int sse; - - } asm_optimizations; -}; - -int is_lame_global_flags_valid(const lame_global_flags * gfp); - -#endif /* LAME_GLOBAL_FLAGS_H */ diff --git a/lib-src/lame/libmp3lame/lameerror.h b/lib-src/lame/libmp3lame/lameerror.h deleted file mode 100644 index 7d9216bc4..000000000 --- a/lib-src/lame/libmp3lame/lameerror.h +++ /dev/null @@ -1,26 +0,0 @@ -/* - * A collection of LAME Error Codes - * - * Please use the constants defined here instead of some arbitrary - * values. Currently the values starting at -10 to avoid intersection - * with the -1, -2, -3 and -4 used in the current code. - * - * May be this should be a part of the include/lame.h. - */ - -typedef enum { - LAME_OKAY = 0, - LAME_NOERROR = 0, - LAME_GENERICERROR = -1, - LAME_NOMEM = -10, - LAME_BADBITRATE = -11, - LAME_BADSAMPFREQ = -12, - LAME_INTERNALERROR = -13, - - FRONTEND_READERROR = -80, - FRONTEND_WRITEERROR = -81, - FRONTEND_FILETOOLARGE = -82, - -} lame_errorcodes_t; - -/* end of lameerror.h */ diff --git a/lib-src/lame/libmp3lame/logoe.ico b/lib-src/lame/libmp3lame/logoe.ico deleted file mode 100644 index 70994aefcd1e7e90b51063b89cb10d1a0e7b5deb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 51262 zcmeI5X_QsfweQLB!~K|VZ@h1Qy<@yL#vAwB8}GgGd}^*;ut88kLFt8}C<+i_ZtjS_ zmz%`Ipn_;dcQg6+H0@9O!MTvKW z98cDs`@iN|bM86knyWdx#*O;{|9kY&aeV*hasPN|+_?WVZrr$k;K>QgX<@BZ=G;*)4kdH>Dk)ZXz6tOvNzk8o_+11)9s7<+ZT4X zF3BTc>%#7aMLn&Ezp%S$NxnrzZb8yTJuT&3Ef4iO%;H|bly@~f)ZbE(ZJ_$%UerZd zFcn$hv$(efCKcJ@nDQ<-cueM@{?_s?Y1;Ty=7bL|TGQ~U%w?A3efOj-F!Y(itW%j^ zu3vv8=zs9^VC~5RiyEGtw13TQ$6vm$yXwLIhWWXMB?Bk{b=4!C3Rq9iwex7e46Gh` zl_D6VUfAs^4nuX-KiUR^G1pgQjZ&|gq?V_kN#o-vAU&osC$)HL9urX<2L3#E)jycH z!%({rU--e3Wi(82Ss7w@Ttf)mv_Mjvux5rD@e?hPi3wF+g3~y z0DQzS5Yai@)T#wTMZCjfsKPC4kydESy0@qYjEO+OM37q^Gh?9PJF)-2etdpu{fjpr zSbJZ-YI=8dMPJk6JQ6i7?Q2>#KtFLCu41*30 zv$$9IJk*a?#Z8tCfWce|AUxtGr9dZoConw02qX4PTOLDalmdS+_^EV{R!jt1F%dkb zP=vW>Gr!#M`?0kD>|lO=>)Ja`zBDseQ#pV*%?L=x=sX%Q{Uac{HASIn6lEBQrZ!!W=%ZHOx;=nf|3|)qfKhwCDAY-clIug2AeJaMnG;q(o3maS^nw zSWMOb+Og69p*Q>QZdrN9iS0AH>&kP@Wu4-f>Y=go5-X5JJzZjgdNCM@8(eC*0N^~G zsBRdlXpjM8Aq9-sq|%>yAX;ppV3;ueln_DrNZ9lk`m91Z zF{h77{5g8A@BWVM_jGP5>#JK34PNTAHdMKRiN2}XqsH{$#Vst254FJX(JTeIgo05i z#f`s!Bgz#t{?aRY>qVf4h;X^b-!mWoVN%nxle@Oe>TIaUHPdLAylD*a$(!Va%dM#B>ovZ#4uIxrMdx zNnwnl(I$a`qWOt9P70&3MZj8%w1=j_NP#%71!iqh-~*<-E29|WZxn6`2D-;k2q;cE zqiD2o-7^Z`CMFhw$na6YrJ(U=^vB=br+OxJyfm+`t~^_3Cd~l1w6DbmuO)fn19k$1 z0Zt-eh|vT?#zez#xoki%TtdVwxr9h{!zhIjO|m{PxCRv1>KH8;m@B0SM)Mzsv9UE8 ze}xae10OJ!9?&B8JQ5Kij1xgq2crHG!iJ9vO-i?6h4fF6A1f;i`9*f>m7(xmZs!$OOD$==tRG}h#s8SR|SfJ?; zLmacm>iHN(1Cj8dA$_v)=ncbnp$M9NCB!T(0)2*$$IL!W{yA#%-#zh-!sG z#UgOmL{QFx;fbi=!-}971Q#)9onrmr+m64ps-C_3WKCI5tzQ_?d62|U#PpLF3=F;L z+)B)k#go$WFU8;{XhRlHuqet@=Ms%Yb1QB^L2z5!iRWMH`&36vna9yI9Z){jD@-@; z9vD9QSY?(+(}f}wVoU`1z?QpFi_#xjBoj-C5MZ1L-+un}e^0mFpRHch=O*twR`qKJ z);M`kzh>MN482WZkeazXi3+z^YEX>K6g2;l^%e%o03*v05G!>yp^E@g1)^dkN5TT5 z{KvwMs2Yr|QP4ddxDA8j5Qwl?k^#Z+ZQV=dKSeP#WMa}Z9Fk%ZIh_a|6N+gf%zG>I z>r2glzWU(&FHY~euVeFk=2o)qgb@;QMSL|OC{~aat%xE{=P@=P)LRat6vJRVQa!+6 zmcmEFbpk`v1Y2&=wAJz$nvN(%FnUXxra)ML4@-8&hi{1R@tBB`5Wz5dtB44uia>-k zX6B{FpFh9(?u3@rQ#)gHl=bvVp|PKiH^ zXgDt%JVvt}+pTD!79w~I%r%lg6h2hZup^f+*Stj*TeKF<(P)gJY4%nW(~O;1_vnDf zTu_8UF;xVH{$>@SP)r6R5ut>bGX@$jZT)#^SM|(Xbw$n=SY$xN`!thrn->v9GEB3^ zh$2IzQSeZ$1;$ym`mFE)ptgr!M@%C@FZ9alp%y_*0bBRPL`-i9$=ObLIk4V#@{bSpUd&U0gk73mQ z#WKx3y$HJhXc%+hQX;6BB7zrFM_BLXA_8MHA_QV4M3{N%qV0cu{=nqUs!GYyiO(*e zQBK8w^nkh2F(N8vqdgSNWsCpP7LsbOoZ(sbA_``l9wX?a$7qLT2s1v~bKw(;X_!!i zLNV3s-S9+z;A4(p3{4dtbFuONVD9AP?k(lHdcQD&&lV;RwEG?AKS=kz$$u_p{pX91 z|8&Rx7iP;EqhxD5P<1z+wT!=N+v16qJmZ@w3_c!Wa7;BGi9g1NNP@!>9w`uwHC>mO zqh1VK2^Yg)ux;VvF-$yl*+KaD?rD&*?$M%jj}BPV9-{>(LZO%`5df$N2~`+|erotcUH^HYZQYFQ_Jx`jk|e{H)=?MVl%b&f5m4gEBhE;)rOz0jTZUr5dnQ}l8Op=lis+gFu2r9TVZGuzKXdjCJy{HJP zuFS~e&x-ci`?|L+l4TYmzpU*bGS86+$#=9c!jmQC;G3BL_w}DqTmL!z*6E3zTjzG7 zaIqymR?u|1#8P3rFc>Wr;(cN~gar*3lG1gqKMNaDL9>TUT$F$ z7Jt~cHCI)NI3~%1?c|0Sqo6~GAx0_I7DJ)j@)+0#6c>N!l3}zE#~*6hE$a+rqfkgv zVi6RR5R>3WE$dz&RHA!c%nQb!M_M*d>#l!jfbmq;WH108F<}8q)71t!bgE%T79N>A z+W1QZuuXrD(U2mTzn_0VIXDYGh)znMe;E4Wn;ZA9Efc>cfXLvh+LmEOwJp}0q{JAF z24Xgb;fWhX&-Mr(rO4V2_8H9(3E)P7k3=~z5ydT@7)3kp)^?!4L@CxiVHi;y#wdsY z_`5oP>&5g!Vb7({|NMSe-F>)or$l}xCis-it(bQZ#MD*egQ-a8_g|P>8Ajbu24$U( zNQh?LQr%hhO-P>M6Jm6j7BHQ}JR*!V&86loFmVh$2E(ADVq`)@Ep<}iL(|%GY1%OC z<7m%A5d^~rQ$YmyAf^`qFhtF-VoW4L5iw~+#kBdC6O;Z#B3Q3vB%*tz&)@!d-!o-$ zTAR@gYox>272gCLD6)g2K?WU)t?K9_OFf2BieYSTMK~CS0S*kxHw-GW10GP=A^~IP zW+5s?h=#$)4a2}4VyI#m*cyiJ8AcsJ_<$)CfnhWffvy@R7U81A^dgv;);$xGp3tA7 zVwO06+xYsc_vfoBd)Y@W-uY1fhS6zPas8tK-!Yz%={D5A*X_5_KWx4JVQxym#k~Ge zf|-Zuwow0}2p8193gvW5D?IC@m_$Wsx~Q0D9wqcYW#{vAWlL9r02$08)Y7)r=YP>8Gp5(Vk8u>UaW|L3EK-P3|?G%3NTH^ zBob098g1S98&IyG@wcd$!;QZS+BeMTX88gEWzbR2a``9elg~d({&;G*A4W-z3R}xj zhx=g^iZu+!crJAQR&u%jNWcFY`g-WchhBWJlW0TO38yNK0ue8;TN*dW5FCX-&JoDaB0> zRdB%+oqx4-9-P*@nFAit+JYV4kWnBtF=rkTVchzIP2S0f7+;ulGr$>!fNT?U3K7Pw zKfu=34YOXLb9I)-^38{J5}o8CHJ9YrqD)4{6h?P`7~MHZQe+k9(A`}Y6`g4I$v6yOIu6wAfP=tsg7|nkY=MUSD zAGyDuGqenm{$Q$|?BdCiPVh~@9EJTCJ6pSaFg|}99!$O9`CILt+u-2HZg~EdTX;GH zw_((C$LRbmUT=ZOpTAY15=V%YLP~=goAvxjBK|!3dc&N24G+;a?|9G{0O3w4vHe5w zhT$zaOo)wa9}iR5_1B>$85V0V_u^jb{Hs05oG@* zpv3mCwVWk;OfjLH2w+qw8PF-ynTR4y)2{Dcp_nE@;rZJMP0uXsFS0RB(4!SU|6(%B zrA0Zu`B>cc7{-Vc1`Z*H1r|DwLlFuzqM~*Qp7falkA|pAftXL&1Y?m|DH7E~3{|KY zVqmK=O1^#f0ukuBbWfF>z$kcFF;gPI1P(>Tqx z#wbIEpoxL>QR@Ub16$Svm||FNa}oK^KxXM+Yk7Zj`I-8e z19f+IzH)bV>%{Jt#-G@Dd-qGX9DnYHBhQaN`P@y%p1&Bma@up+X z-EjE1TRUI8<@h>o3FheYe86ZyF-Iv2=BA_TAQr{IgjT@7mR7*PjaJ}8fmUug@!}0f z1aq5WZaGeia*I9~_`2>5i&p*C?|=38=kGYVnaHVzAuCZlJ4_n8^#_xn=tCFRVS8E($?p>59AwvwBxCHHEU{Gnub38>iebP(!KrH z-CJhoY6&}7wPrgqreJkSNv!{*FyNu+ZkJmliYPIkh!XQ*j-$1}h$GMz6kY3(bsIi3 z?I?7kKQpth?tg80w03Xn(5HVZEy(xu?)duO%@Ny{kuf}&&EZwsTOq%S>|e&;VeDTV z#0EHz8Oix`9jX|cm=VZYlMbmm{`R)c>TbO2*yhR?R}OtX^gY$>1-t$A*I!TW+O|L@ zeG-{T^08PAL`?B8Q5Ux(ibVJnhB1P>#CE>n03VOxK`131|G{v}_)t)@7Yt3?7_qp& zX- zYO1L?;@jp0nimRVD-#Oh1K;RVDGn1*(irO6I1Yx8LM=Q0KrB)U{sl$G-z0_L-^k0y zZrZc@%&CD#m+`^|=!dWLbG&x+H^Ouy_K6fNW=b_$J89@1_;w&i^o>(|y|*qvvnKwH>B!ELKz3 z|NfeRKK1)+Nm*@Sq%xnGnyarnxHF}IVYO9xsO_qA8%+aEsLvZTL# zabMHY0lq1>JbV^<6L$^6T`-mTwg}VaFucFZVcH%VR7@Y37Uct_W%=p$N@c5j1hf2f zOQkjqW=emOvZ*_ zVXG7hGP$!_xB%Y4Equ)=eA7CVIoY~v#KmOe``YNT9fOrQ9_}V zk~sgC5)z6h_vCGlKXLlNf?gtM;)!Qkw(C8}a(u7=sMhZjr z0tJ7^@&Rk&*Ro`AH*Zv)R=a9ZKk2<>i5RNSKY4sgak(WA&M5X+X*8g?wH=LzQp;mJ z#qv+>Dt;}#Z}}$_3hIxIclA^qYk9S(#g01hj@LKvEAmhTx|$S9tk*gm37!^HMR1r% zC@?aeSHWX3Awoe+)xTi)kYX+DtegGXCVt+~Z>5GKvHJhBMm z_DyV!0;I?A=)uqm9MpX<2H}GP>i8>sbYPMy9>X!(htIYBw>8VgLiO6l@}sq7y*22t zP)rj+$KSM=UW7t15g`&2vmaJW(hOpk`nzCszne)G-oapPAw}*66qyb{v9+}j6Hw9^ z^*-U_F|5(4!i7TTm-a~&>xof*a&E_eU0pe5`hWV&!8twKFG|c%1WXZCgkq{tNGHlP z!HbG1X|`g3AvhYq0N||ghZFJ{)}M9FLDqj5j#+=!EpKj#(=j_X46%_VBXvw$qn1+# z?5(I{@?sE%8{uOZO%)i&(Ybd_dwGa+a0a*~1I_=vcE!-Ye?2yj;HkmG(>u0V{0YT0 z5ll>E_hK4GckzmdnT#z=DxH|DC~CG7#~+L^6@PdHi{+hZw%g(c9Rf&1af41ki7{}y z*!>stCX9yyR)mo_%3#x^+_nR?O=F|~XU@GbCtDK;6^j`ObrE6)Lb>tRD3*#KBOi^) zG9qJ^o`UkHHLb0XQ)H4I;Ss65mBRhU5F>UgzhrlNi=KFVD-?(ljoR+GfRiQ>rKwp-@Z{!CVHpEdMlBq{Q@?3K2i^ zFGuRjbSUS!qZ2|0&rS=Hj^c56kWnCp7#;l`hFf4f#R^GEym$f~zgA4*_m9)E4XbN6 zkB$Cs*|)x2&k{#MUEuw$Mqs_IbN0RT)Y$_I@^uUc z$^925;4+{ytkd)*oj;K?x;hQFv$YtN@S!2bAlia0vpLO?WW9y97WB7FY<_YK^nd=7 zk2&wLEZAm3SnD1`C&9s%SxC>qttgKPMZm(7VvgwiEm9-?S=PRod zL<4*c&G3zH>i(kyC7cVd#HYaMGG+n;(qkCSLyQj4!iR!kbP(qeNc_>ZWX{Nhk$kVb zr|qU)PY=EG;pKh=uMM8Kx3e}BGZdjvOacfZgcuZs2uNh=N{T59N1>Qp^2lN_qhrQP z&+NOmYQ-;(G|tgzfC0cTI=l)VOOQas2hT$76u|IpYaN9Y16wV_=-Rc^vh`>9D1{!n zg<17kaZI$apsR`ZYt4NAHQGIdIcX@O{j=Wp$p@q&T2 zr`~*hQ~r&q-8E+0*gsi%Xc$Tvsr_RN;8Q*lQ9|QkLYJ_AjNg1@QLbS|u4eJ(HJ4BS z|FV12Ov!vMLd=v1g<_&T!+6`qHB_jym=M9BVLtbF*ZsP6^Q))3@9x@4ywX)W2~%JQ zYZ|X4=)oKtw)hW*h77|uFx=1wMwk#h!DxSk4;b!hM3Rc|vA~$Z;7SpuzPz`U#o^y> zxxniwF6{yBIhCK>U0o)>MRH>N4@pyE7K*?lC?P^IF-2*in5gdFTw`nZq0=9{ z%b&&huFs!Xj^y5dTi(}v=aCKX_4Hqwl83AH<=;NP{f*}q4Q3cjNz97oHW#1&2p>)J zBwb{}3kO}vFP`Qx@$|=RCS|uB>Nx)1d+%Mp>zQ(S=r$g?{2v=uip$%%G>R4y80H8N z8AJJ2!?01?VIoSL{~JZ~f2l=*bOL|GF}V~}hNnPMH@=ANu^8dyc&P zz{%~4WwRAoh83Yu%#;Wv#6*N3|2Lr|G!=@uDA#oJ@l79|movjRw?8vqhD8Yxe%^|| zq$Y;=W(tE7fl1DP1*1Kb#S=WY5X0bQ82k~KPL+E%&K;}sw^#xm zTDbm`S{M;89&DP^TX*x$XCB}7t^QQU7vKDCPIvVKo!j`UD73EOg5ggVVQ{*LGS=%q z<%7+4ZGOy5WzFH8lTWf3{#~wrYGS}(Eu*Xv z9R?AWo@y>TRew*e>h^};{q&WmtD9@O_a8V>zw?X1x86P6d9q<=-~J;zb~V?%cjCI$ zKbex-a(}jJ9?>TH`-3bo5z}bPFLTiZGMbovZ3m1O6Jn?e1>5`ITyBF1CZ?{sI1war zM*Cm36=-6rP{I(CCbZt!^~zhh_>ASlyQ=5tZ-UhKC2ywye=YFrWMhR74KcPFhHvf~ z1|k^0d8)Y$BQGh9!)U=UGRngz#1M1fqZrpT-p4>}7;BMBY^kiPZGLa#tbFU_p3LOF z>N|UCZtdK5dw2DOo~jAm^;2>+({r`6yP7LR7AJxRG!ucI^KfGkz<3d8D-?l7xfP0_ z;1~m+;Y3hA2{Cp36N(daUas+9Vq+pwV-kGR8Kn@SW$+3p z?u>+|P}c@HDDb3K;rUx`VU2tggU3;j%?qP&$w&DlC@Bm^74o5qQXC%>fwd+u_WrR* zs0)jLuqiRaBOIoRq?od|qL`FWMZ}!mTl-ku#!&wszw`dYo~?@{H%^@GNuIyG!1*7n znm}QH^vD14K88{4n4QtZh8;#VNn1on$@e&ayRe%D7Wr+pQrvq~?C&2LMt>nFeJikz-CKf`83mNiowR6cMwhWn%Z{ zPtK>;xNfa~a!zziR9&8)%S=igQwn@Sih7@;a7$g)Ft)c6Qe={)Aw>!x{racX;#=d7 z7&D&~#wavxV2_~+3w_F2ES!SJa4Vpg2qZaD2t^pVP%t#G^?|a9Kp_%AIBRE|EYQ7} z))}SLKbXz@&yA1rwwciWDc21gpV3=Ij8dDy668!K)(Bg*843Q3V)Vr9fp5d`?J>lq z5Cb7ExMa*a?-*FBF3#YBXe`R3p3s!A!J%Rj#T)~&~%FYo!g z{?leQn))BeOv={m-?O(+|4`<(Y~WxR)`DAIva6;XQ(e^@6Z1>Q7TTgAzU`KeEl^U< zi~AVZW2o}Ii$CRk4cBgQ)84{IkQ>b1*|D9Uzu{{*uMJ+B$;5+~?yV#SuaON*e;|43O?J6DF4Cp&x(9zLdV7r&%W!mU07)AIySj`TX{Dpa%HF`h12+O#mv8CLT9~_ z?%CW*=Y|AKC}fWWG#R+H=P`ysQ-kVvH~;EvnU!mrTYZ5)JH;=}@7TR^K_7XzOsM_& z6U>{>ceVb2r?4DBGNbbgnczdAdl1#X$m(U*!+f6vgFGK3D+4?Z6M-j1+Jn<6CSGRI zB?ZAyV0nZk6fj;)h{nfMq2Nnjf2ioq+|&I^XLnbj&8H|^-qT1qH*JjAlfFG(HSN%;X@-E z=};>c^D?bJFUU6BabkP#K%ZA~=|XMSfyrH4ACe7C#zYxg)$G%o7id7wpTwAm;>KTU zMHGiIQ^W`{)IDKn6ypPPD7wiTch4wv$oyE?U>NC2VDNgwkmb@_jF4HR?PJ0gA`KPAn4v}(H_4?f<-^9SG!4d@ zRzAWuI6~|&L^Iz#T2Eq}2qC7Jn1r2J%t8@Rg%^R}y54%|h0gALO2efu2lIpD_pg~R z@5UEH;+qdMcP&V?3@C1I9SRR3g^4H*qv1j@6u`rW0#5-`jQ8L5y|oazg&vAw)SZNUeL_)=Uj8bI(y)$!vw&wA}jit3+^zPc@J7)IP z@>0rFVnAx4ex2UD;E6K=hB*=e+4f&3Sc2g(ICZo!A@hBb5PvWOFun{?F*Xep48#zl z`A>}DS?J!1V61!avHV8^i1~|Qh>FEUAdC?1LJ<(w=Rbuam@42FiJ3lsGA~y<@zpg$ zpZt4K4VNZzX5;3a>sS;eJ`h;&DON%-NOdB!_c(xfvpCj1O{7$k72BPd>bE_=<-@Z z%t8^=+J_avRDlSK`dTM-Y}?r}qCL~1&!X!1-bp9rFK=p}iQ5u(C?jT33c5;RA_@to z)Ut!Agj@oMu8m9lK^4@(c>x#(3XxocjEs7Qf#@+2#bGq;NYezX=m@cN75(euOLQ0t zK?$~A1f?V}p_nNVs1;G1DgYaW?$Hz1;a*;;x_#=_l|>aha^k|Kb<;5?`9o}%{roMd zg1VTT(Y1XX+kfF)D+|c>juelv{TIz-WO<5{ys=(Wuo|@UkuVvG=ouY8bMpLi@)@%>L2engQFt%0Zrh6hLY zma4{(66R&FpLq z2VB`^!W8Y$DVnrHr{qYi1|y&?p74yAoEipA+P;;?uy}&V_BaYLrYNdtZsT5$181t( z_8e7;V$hpk|1peGSf-HtN4w|t$mnEBgb)*nASs-6FBEg}VCLRj&GL<7@yqcrSpD^@ zp$Yq5n$c5T7X6Kk;m+S`Y`MVumn3;e?!ORlO2;2HW5F=;GMa0QA^{LSd=nd$V!;Z- zX6FbDdLGU5xAU?sQ?gYRYgUAs8ME@2AAK^feZ!QF&1K!Sm;{kotq5Ty!wf0m;Z;l* z+aqJd8o^M&dX+-*Bkm6$D10asP>Nt+0t`Opadtc-pvdf4S0p5HRSXYBx~ET2D9oc3 z6H;Ok5XUg!W1$8zyf=We3M<-P88d|!ZD`HAC+|7AX<;uLd|1~=&)@13k@L5fHzJ^p z=4e3jPeQt#t>vIBu}dkkfXv9NPb7h1jR*{U?2sWC)h#KmJHn*e4l$C)8io{Fb!+E% zVJ_>R@ZpL0Bg7t~MkP)2bJ2>ymhrDYzkPRWQJsu2@#n8@y{mK6tWNoR@pRH=F&YZc zDuG?5LKKW*-l3G#{7Vd;54SwVum6~>a?4|sQgr?$)iHIzU^IOa3)lD~ow0&qq*q`( zMSJBa5Wy6obY*5|8^#}8|4QSf?5bR*N7LSQV#1*p=l0evKaHgkK+N_qMcG@ys&()p zX_R4u+mY)zNwMGHLRX*?#ceJCmAL&+e};i{4R;=hAr; zMNB|I^rpKTqJK;a@zI;@cc5Fq3=M|iQWvA@~ogibY$2i;8 zu~o)sQV3qN@5kSYT|u(ix()x<(~ni zej!O|zVW`U>N|Hmv+u|oSB`E+-jn__r*E%&c1m{3OkPcy#WLNC85sxF(P0ok&lfq^o>a0$#~WEx8qTgM<} zf)6f`+<$QxTca51{tE|>2b&kZ**vl9pjst-iBk z>+GJo#r;GiMoEIL41y#rTh{{-K58VHkiLG8z>j6w^7F*@5|3^`u&9Nt@m}-%p>cQ$r@1z zQ>P%4Pz^hhPo~zNxiky|C5a`qRLK&5sG_+I6j<@nU4~JI;ZMkM{!nupIe*I>ne-mD zdko=jNnhiG*_Nr<+8^y%_iuZ)=MQ&`y3|)1!w=tj``0a7Ccd_AO3$`Ax!Of!`;vsa z^S2BNjJ7sVs%uC-$)!?a441$#cwI@5LPW8(9jQggVrMPF$Y`rUOp;svn9c(Jpl7~* z+F;dnb&svv*EsZt^lx&nG`)>_f2v>GIdA8t39r3y`|%ehpR9W@SGO>Sx$;+*oc&|l z1a`Id*#1*K64^glYr_7qZL@#kk76H-yX5jT*Vce{9%dJ41%1oi4VA z7$5(au(sLXJU5@2k*~cwyY0p|HeCD4&*oLH+TOAE?bBz+;BU=*?;ga^M}K+y+?&lk z2Om3>xu{enSFUuwrX16_F1QDX7tw2Kh?1KTsvm`({rt4KExLO%oeY&Uvzdy z<=bs@2J0T^Yq-C^YI1)2?VVdD^>6wg8-Fo#+fz@r)?^2JKN~3Z+qdtXt}b_n`SW~V ze*IN%f4=v_cN>rFZ#mVu{_xIK$J&2&q~*3XzhwT)q?ky>40qzj$I9x~uRPrP?CZ@9 zxntW8?Cv}N{((bpod5Hm{`Tb+{a0&;^xxh{l~?IyJm0Wue|wx>$G7eJd{ld!UB_^{ zj&JLAP+hNs>Utei*Xu`<^}h)&<$lOcu0K!R582E8v#I-gQ`g}o_(XF>t`p63KhZqb ziRQUJo8q6o-kZAr=moA5x8a|d%F)_ondQ z_WDuB?}ujSL+<(?++}oqP3k(jbm~;ISDLZ&)!lu#Clq~k>iQb$x{m1oJyPV_^~~Q7 zuYpHB)%(S+_v#({lKa8+4=!*$E_MHst{)BBe*}i5uCL*K03VmWzB;8p^qVkT^zRJO zT8Z7>t`YdG^8bNdk9)+aBf7rYJ+2?@Rha)uUtg8FUvPcaSJlE*sq248U#I-zhw1B- zfBi6ZeRcXep_Xyuu1Q}f%yJxh&~Ey#^mX#Fjl&Qg^;in%b#HiGB%CG$;yER*d5#GI zc+QCqr=NS;E*=?5c8JTcgK0Zgw>=woSlu@0kOqaI16K>bKx5a)b)d0F^!icHP%npk z11?JV23(Zz5?^h2-@r9??Im!Rk%}EVuQKheU>t*MBD_^l;f -#include - -#ifdef STDC_HEADERS -# include -# include -#else -# ifndef HAVE_STRCHR -# define strchr index -# define strrchr rindex -# endif -char *strchr(), *strrchr(); -# ifndef HAVE_MEMCPY -# define memcpy(d, s, n) bcopy ((s), (d), (n)) -# define memmove(d, s, n) bcopy ((s), (d), (n)) -# endif -#endif - -#if defined(__riscos__) && defined(FPA10) -# include "ymath.h" -#else -# include -#endif -#include - -#include - -#ifdef HAVE_ERRNO_H -# include -#endif -#ifdef HAVE_FCNTL_H -# include -#endif - -#if defined(macintosh) -# include -# include -#else -# include -# include -#endif - -#ifdef HAVE_INTTYPES_H -# include -#else -# ifdef HAVE_STDINT_H -# include -# endif -#endif - -#ifdef WITH_DMALLOC -#include -#endif - -/* - * 3 different types of pow() functions: - * - table lookup - * - pow() - * - exp() on some machines this is claimed to be faster than pow() - */ - -#define POW20(x) (assert(0 <= (x+Q_MAX2) && x < Q_MAX), pow20[x+Q_MAX2]) -/*#define POW20(x) pow(2.0,((double)(x)-210)*.25) */ -/*#define POW20(x) exp( ((double)(x)-210)*(.25*LOG2) ) */ - -#define IPOW20(x) (assert(0 <= x && x < Q_MAX), ipow20[x]) -/*#define IPOW20(x) exp( -((double)(x)-210)*.1875*LOG2 ) */ -/*#define IPOW20(x) pow(2.0,-((double)(x)-210)*.1875) */ - -/* in case this is used without configure */ -#ifndef inline -# define inline -#endif - -#if defined(_MSC_VER) -# undef inline -# define inline _inline -#elif defined(__SASC) || defined(__GNUC__) || defined(__ICC) || defined(__ECC) -/* if __GNUC__ we always want to inline, not only if the user requests it */ -# undef inline -# define inline __inline -#endif - -#if defined(_MSC_VER) -# pragma warning( disable : 4244 ) -/*# pragma warning( disable : 4305 ) */ -#endif - -/* - * FLOAT for variables which require at least 32 bits - * FLOAT8 for variables which require at least 64 bits - * - * On some machines, 64 bit will be faster than 32 bit. Also, some math - * routines require 64 bit float, so setting FLOAT=float will result in a - * lot of conversions. - */ - -#if ( defined(_MSC_VER) || defined(__BORLANDC__) || defined(__MINGW32__) ) -# define WIN32_LEAN_AND_MEAN -# include -# include -# define FLOAT_MAX FLT_MAX -#else -# ifndef FLOAT -typedef float FLOAT; -# ifdef FLT_MAX -# define FLOAT_MAX FLT_MAX -# else -# define FLOAT_MAX 1e37 /* approx */ -# endif -# endif -#endif - -#ifndef FLOAT8 -typedef double FLOAT8; -# ifdef DBL_MAX -# define FLOAT8_MAX DBL_MAX -# else -# define FLOAT8_MAX 1e99 /* approx */ -# endif -#else -# ifdef FLT_MAX -# define FLOAT8_MAX FLT_MAX -# else -# define FLOAT8_MAX 1e37 /* approx */ -# endif -#endif - -/* sample_t must be floating point, at least 32 bits */ -typedef FLOAT sample_t; - -#define dimension_of(array) (sizeof(array)/sizeof(array[0])) -#define beyond(array) (array+dimension_of(array)) -#define compiletime_assert(expression) enum{static_assert_##FILE##_##LINE = 1/((expression)?1:0)} -#define lame_calloc(TYPE, COUNT) ((TYPE*)calloc(COUNT, sizeof(TYPE))) -#define multiple_of(CHUNK, COUNT) (\ - ( (COUNT) < 1 || (CHUNK) < 1 || (COUNT) % (CHUNK) == 0 ) \ - ? (COUNT) \ - : ((COUNT) + (CHUNK) - (COUNT) % (CHUNK)) \ - ) - -#if 1 -#define EQ(a,b) (\ -(fabs(a) > fabs(b)) \ - ? (fabs((a)-(b)) <= (fabs(a) * 1e-6f)) \ - : (fabs((a)-(b)) <= (fabs(b) * 1e-6f))) -#else -#define EQ(a,b) (fabs((a)-(b))<1E-37) -#endif - -#define NEQ(a,b) (!EQ(a,b)) - -#ifdef _MSC_VER -# if _MSC_VER < 1400 -# define fabsf fabs -# define powf pow -# define log10f log10 -# endif -#endif - -#endif - -/* end of machine.h */ diff --git a/lib-src/lame/libmp3lame/mpglib_interface.c b/lib-src/lame/libmp3lame/mpglib_interface.c deleted file mode 100644 index d0f0b1d53..000000000 --- a/lib-src/lame/libmp3lame/mpglib_interface.c +++ /dev/null @@ -1,477 +0,0 @@ -/* -*- mode: C; mode: fold -*- */ -/* - * LAME MP3 encoding engine - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 2003 Olcios - * Copyright (c) 2008 Robert Hegemann - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: mpglib_interface.c,v 1.44 2012/02/18 13:09:00 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#ifdef HAVE_MPGLIB -#define hip_global_struct mpstr_tag -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "interface.h" - -#include "util.h" - - - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -/* - * OBSOLETE: - * - kept to let it link - * - forward declaration to silence compiler - */ -int CDECL lame_decode_init(void); -int CDECL lame_decode( - unsigned char * mp3buf, - int len, - short pcm_l[], - short pcm_r[] ); -int CDECL lame_decode_headers( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data ); -int CDECL lame_decode1( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[] ); -int CDECL lame_decode1_headers( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data ); -int CDECL lame_decode1_headersB( - unsigned char* mp3buf, - int len, - short pcm_l[], - short pcm_r[], - mp3data_struct* mp3data, - int *enc_delay, - int *enc_padding ); -int CDECL lame_decode_exit(void); -#endif - - -static MPSTR mp; - -int -lame_decode_exit(void) -{ - ExitMP3(&mp); - return 0; -} - - -int -lame_decode_init(void) -{ - (void) InitMP3(&mp); - return 0; -} - - - - -/* copy mono samples */ -#define COPY_MONO(DST_TYPE, SRC_TYPE) \ - DST_TYPE *pcm_l = (DST_TYPE *)pcm_l_raw; \ - SRC_TYPE const *p_samples = (SRC_TYPE const *)p; \ - for (i = 0; i < processed_samples; i++) \ - *pcm_l++ = (DST_TYPE)(*p_samples++); - -/* copy stereo samples */ -#define COPY_STEREO(DST_TYPE, SRC_TYPE) \ - DST_TYPE *pcm_l = (DST_TYPE *)pcm_l_raw, *pcm_r = (DST_TYPE *)pcm_r_raw; \ - SRC_TYPE const *p_samples = (SRC_TYPE const *)p; \ - for (i = 0; i < processed_samples; i++) { \ - *pcm_l++ = (DST_TYPE)(*p_samples++); \ - *pcm_r++ = (DST_TYPE)(*p_samples++); \ - } - - - -/* - * For lame_decode: return code - * -1 error - * 0 ok, but need more data before outputing any samples - * n number of samples output. either 576 or 1152 depending on MP3 file. - */ - -static int -decode1_headersB_clipchoice(PMPSTR pmp, unsigned char *buffer, size_t len, - char pcm_l_raw[], char pcm_r_raw[], mp3data_struct * mp3data, - int *enc_delay, int *enc_padding, - char *p, size_t psize, int decoded_sample_size, - int (*decodeMP3_ptr) (PMPSTR, unsigned char *, int, char *, int, - int *)) -{ - static const int smpls[2][4] = { - /* Layer I II III */ - {0, 384, 1152, 1152}, /* MPEG-1 */ - {0, 384, 1152, 576} /* MPEG-2(.5) */ - }; - - int processed_bytes; - int processed_samples; /* processed samples per channel */ - int ret; - int i; - int const len_l = len < INT_MAX ? (int) len : INT_MAX; - int const psize_l = psize < INT_MAX ? (int) psize : INT_MAX; - - mp3data->header_parsed = 0; - ret = (*decodeMP3_ptr) (pmp, buffer, len_l, p, psize_l, &processed_bytes); - /* three cases: - * 1. headers parsed, but data not complete - * pmp->header_parsed==1 - * pmp->framesize=0 - * pmp->fsizeold=size of last frame, or 0 if this is first frame - * - * 2. headers, data parsed, but ancillary data not complete - * pmp->header_parsed==1 - * pmp->framesize=size of frame - * pmp->fsizeold=size of last frame, or 0 if this is first frame - * - * 3. frame fully decoded: - * pmp->header_parsed==0 - * pmp->framesize=0 - * pmp->fsizeold=size of frame (which is now the last frame) - * - */ - if (pmp->header_parsed || pmp->fsizeold > 0 || pmp->framesize > 0) { - mp3data->header_parsed = 1; - mp3data->stereo = pmp->fr.stereo; - mp3data->samplerate = freqs[pmp->fr.sampling_frequency]; - mp3data->mode = pmp->fr.mode; - mp3data->mode_ext = pmp->fr.mode_ext; - mp3data->framesize = smpls[pmp->fr.lsf][pmp->fr.lay]; - - /* free format, we need the entire frame before we can determine - * the bitrate. If we haven't gotten the entire frame, bitrate=0 */ - if (pmp->fsizeold > 0) /* works for free format and fixed, no overrun, temporal results are < 400.e6 */ - mp3data->bitrate = 8 * (4 + pmp->fsizeold) * mp3data->samplerate / - (1.e3 * mp3data->framesize) + 0.5; - else if (pmp->framesize > 0) - mp3data->bitrate = 8 * (4 + pmp->framesize) * mp3data->samplerate / - (1.e3 * mp3data->framesize) + 0.5; - else - mp3data->bitrate = tabsel_123[pmp->fr.lsf][pmp->fr.lay - 1][pmp->fr.bitrate_index]; - - - - if (pmp->num_frames > 0) { - /* Xing VBR header found and num_frames was set */ - mp3data->totalframes = pmp->num_frames; - mp3data->nsamp = mp3data->framesize * pmp->num_frames; - *enc_delay = pmp->enc_delay; - *enc_padding = pmp->enc_padding; - } - } - - switch (ret) { - case MP3_OK: - switch (pmp->fr.stereo) { - case 1: - processed_samples = processed_bytes / decoded_sample_size; - if (decoded_sample_size == sizeof(short)) { - COPY_MONO(short, short) - } - else { - COPY_MONO(sample_t, FLOAT) - } - break; - case 2: - processed_samples = (processed_bytes / decoded_sample_size) >> 1; - if (decoded_sample_size == sizeof(short)) { - COPY_STEREO(short, short) - } - else { - COPY_STEREO(sample_t, FLOAT) - } - break; - default: - processed_samples = -1; - assert(0); - break; - } - break; - - case MP3_NEED_MORE: - processed_samples = 0; - break; - - case MP3_ERR: - processed_samples = -1; - break; - - default: - processed_samples = -1; - assert(0); - break; - } - - /*fprintf(stderr,"ok, more, err: %i %i %i\n", MP3_OK, MP3_NEED_MORE, MP3_ERR ); */ - /*fprintf(stderr,"ret = %i out=%i\n", ret, processed_samples ); */ - return processed_samples; -} - - -#define OUTSIZE_CLIPPED (4096*sizeof(short)) - -int -lame_decode1_headersB(unsigned char *buffer, - int len, - short pcm_l[], short pcm_r[], mp3data_struct * mp3data, - int *enc_delay, int *enc_padding) -{ - static char out[OUTSIZE_CLIPPED]; - - return decode1_headersB_clipchoice(&mp, buffer, len, (char *) pcm_l, (char *) pcm_r, mp3data, - enc_delay, enc_padding, out, OUTSIZE_CLIPPED, - sizeof(short), decodeMP3); -} - - - - - -/* - * For lame_decode: return code - * -1 error - * 0 ok, but need more data before outputing any samples - * n number of samples output. Will be at most one frame of - * MPEG data. - */ - -int -lame_decode1_headers(unsigned char *buffer, - int len, short pcm_l[], short pcm_r[], mp3data_struct * mp3data) -{ - int enc_delay, enc_padding; - return lame_decode1_headersB(buffer, len, pcm_l, pcm_r, mp3data, &enc_delay, &enc_padding); -} - - -int -lame_decode1(unsigned char *buffer, int len, short pcm_l[], short pcm_r[]) -{ - mp3data_struct mp3data; - - return lame_decode1_headers(buffer, len, pcm_l, pcm_r, &mp3data); -} - - -/* - * For lame_decode: return code - * -1 error - * 0 ok, but need more data before outputing any samples - * n number of samples output. a multiple of 576 or 1152 depending on MP3 file. - */ - -int -lame_decode_headers(unsigned char *buffer, - int len, short pcm_l[], short pcm_r[], mp3data_struct * mp3data) -{ - int ret; - int totsize = 0; /* number of decoded samples per channel */ - - for (;;) { - switch (ret = lame_decode1_headers(buffer, len, pcm_l + totsize, pcm_r + totsize, mp3data)) { - case -1: - return ret; - case 0: - return totsize; - default: - totsize += ret; - len = 0; /* future calls to decodeMP3 are just to flush buffers */ - break; - } - } -} - - -int -lame_decode(unsigned char *buffer, int len, short pcm_l[], short pcm_r[]) -{ - mp3data_struct mp3data; - - return lame_decode_headers(buffer, len, pcm_l, pcm_r, &mp3data); -} - - - - -hip_t hip_decode_init(void) -{ - hip_t hip = lame_calloc(hip_global_flags, 1); - InitMP3(hip); - return hip; -} - - -int hip_decode_exit(hip_t hip) -{ - if (hip) { - ExitMP3(hip); - free(hip); - } - return 0; -} - - -/* we forbid input with more than 1152 samples per channel for output in the unclipped mode */ -#define OUTSIZE_UNCLIPPED (1152*2*sizeof(FLOAT)) - -int -hip_decode1_unclipped(hip_t hip, unsigned char *buffer, size_t len, sample_t pcm_l[], sample_t pcm_r[]) -{ - static char out[OUTSIZE_UNCLIPPED]; - mp3data_struct mp3data; - int enc_delay, enc_padding; - - if (hip) { - return decode1_headersB_clipchoice(hip, buffer, len, (char *) pcm_l, (char *) pcm_r, &mp3data, - &enc_delay, &enc_padding, out, OUTSIZE_UNCLIPPED, - sizeof(FLOAT), decodeMP3_unclipped); - } - return 0; -} - -/* - * For hip_decode: return code - * -1 error - * 0 ok, but need more data before outputing any samples - * n number of samples output. Will be at most one frame of - * MPEG data. - */ - -int -hip_decode1_headers(hip_t hip, unsigned char *buffer, - size_t len, short pcm_l[], short pcm_r[], mp3data_struct * mp3data) -{ - int enc_delay, enc_padding; - return hip_decode1_headersB(hip, buffer, len, pcm_l, pcm_r, mp3data, &enc_delay, &enc_padding); -} - - -int -hip_decode1(hip_t hip, unsigned char *buffer, size_t len, short pcm_l[], short pcm_r[]) -{ - mp3data_struct mp3data; - return hip_decode1_headers(hip, buffer, len, pcm_l, pcm_r, &mp3data); -} - - -/* - * For hip_decode: return code - * -1 error - * 0 ok, but need more data before outputing any samples - * n number of samples output. a multiple of 576 or 1152 depending on MP3 file. - */ - -int -hip_decode_headers(hip_t hip, unsigned char *buffer, - size_t len, short pcm_l[], short pcm_r[], mp3data_struct * mp3data) -{ - int ret; - int totsize = 0; /* number of decoded samples per channel */ - - for (;;) { - switch (ret = hip_decode1_headers(hip, buffer, len, pcm_l + totsize, pcm_r + totsize, mp3data)) { - case -1: - return ret; - case 0: - return totsize; - default: - totsize += ret; - len = 0; /* future calls to decodeMP3 are just to flush buffers */ - break; - } - } -} - - -int -hip_decode(hip_t hip, unsigned char *buffer, size_t len, short pcm_l[], short pcm_r[]) -{ - mp3data_struct mp3data; - return hip_decode_headers(hip, buffer, len, pcm_l, pcm_r, &mp3data); -} - - -int -hip_decode1_headersB(hip_t hip, unsigned char *buffer, - size_t len, - short pcm_l[], short pcm_r[], mp3data_struct * mp3data, - int *enc_delay, int *enc_padding) -{ - static char out[OUTSIZE_CLIPPED]; - if (hip) { - return decode1_headersB_clipchoice(hip, buffer, len, (char *) pcm_l, (char *) pcm_r, mp3data, - enc_delay, enc_padding, out, OUTSIZE_CLIPPED, - sizeof(short), decodeMP3); - } - return -1; -} - - -void hip_set_pinfo(hip_t hip, plotting_data* pinfo) -{ - if (hip) { - hip->pinfo = pinfo; - } -} - - - -void hip_set_errorf(hip_t hip, lame_report_function func) -{ - if (hip) { - hip->report_err = func; - } -} - -void hip_set_debugf(hip_t hip, lame_report_function func) -{ - if (hip) { - hip->report_dbg = func; - } -} - -void hip_set_msgf (hip_t hip, lame_report_function func) -{ - if (hip) { - hip->report_msg = func; - } -} - -#endif - -/* end of mpglib_interface.c */ diff --git a/lib-src/lame/libmp3lame/newmdct.c b/lib-src/lame/libmp3lame/newmdct.c deleted file mode 100644 index 596cac919..000000000 --- a/lib-src/lame/libmp3lame/newmdct.c +++ /dev/null @@ -1,1039 +0,0 @@ -/* - * MP3 window subband -> subband filtering -> mdct routine - * - * Copyright (c) 1999-2000 Takehiro Tominaga - * - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - * Special Thanks to Patrick De Smet for your advices. - */ - -/* $Id: newmdct.c,v 1.39 2011/05/07 16:05:17 rbrito Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "newmdct.h" - - - -#ifndef USE_GOGO_SUBBAND -static const FLOAT enwindow[] = { - -4.77e-07 * 0.740951125354959 / 2.384e-06, 1.03951e-04 * 0.740951125354959 / 2.384e-06, - 9.53674e-04 * 0.740951125354959 / 2.384e-06, 2.841473e-03 * 0.740951125354959 / 2.384e-06, - 3.5758972e-02 * 0.740951125354959 / 2.384e-06, 3.401756e-03 * 0.740951125354959 / 2.384e-06, 9.83715e-04 * 0.740951125354959 / 2.384e-06, 9.9182e-05 * 0.740951125354959 / 2.384e-06, /* 15 */ - 1.2398e-05 * 0.740951125354959 / 2.384e-06, 1.91212e-04 * 0.740951125354959 / 2.384e-06, - 2.283096e-03 * 0.740951125354959 / 2.384e-06, 1.6994476e-02 * 0.740951125354959 / 2.384e-06, - -1.8756866e-02 * 0.740951125354959 / 2.384e-06, -2.630711e-03 * 0.740951125354959 / 2.384e-06, - -2.47478e-04 * 0.740951125354959 / 2.384e-06, -1.4782e-05 * 0.740951125354959 / 2.384e-06, - 9.063471690191471e-01, - 1.960342806591213e-01, - - - -4.77e-07 * 0.773010453362737 / 2.384e-06, 1.05858e-04 * 0.773010453362737 / 2.384e-06, - 9.30786e-04 * 0.773010453362737 / 2.384e-06, 2.521515e-03 * 0.773010453362737 / 2.384e-06, - 3.5694122e-02 * 0.773010453362737 / 2.384e-06, 3.643036e-03 * 0.773010453362737 / 2.384e-06, 9.91821e-04 * 0.773010453362737 / 2.384e-06, 9.6321e-05 * 0.773010453362737 / 2.384e-06, /* 14 */ - 1.1444e-05 * 0.773010453362737 / 2.384e-06, 1.65462e-04 * 0.773010453362737 / 2.384e-06, - 2.110004e-03 * 0.773010453362737 / 2.384e-06, 1.6112804e-02 * 0.773010453362737 / 2.384e-06, - -1.9634247e-02 * 0.773010453362737 / 2.384e-06, -2.803326e-03 * 0.773010453362737 / 2.384e-06, - -2.77042e-04 * 0.773010453362737 / 2.384e-06, -1.6689e-05 * 0.773010453362737 / 2.384e-06, - 8.206787908286602e-01, - 3.901806440322567e-01, - - - -4.77e-07 * 0.803207531480645 / 2.384e-06, 1.07288e-04 * 0.803207531480645 / 2.384e-06, - 9.02653e-04 * 0.803207531480645 / 2.384e-06, 2.174854e-03 * 0.803207531480645 / 2.384e-06, - 3.5586357e-02 * 0.803207531480645 / 2.384e-06, 3.858566e-03 * 0.803207531480645 / 2.384e-06, 9.95159e-04 * 0.803207531480645 / 2.384e-06, 9.3460e-05 * 0.803207531480645 / 2.384e-06, /* 13 */ - 1.0014e-05 * 0.803207531480645 / 2.384e-06, 1.40190e-04 * 0.803207531480645 / 2.384e-06, - 1.937389e-03 * 0.803207531480645 / 2.384e-06, 1.5233517e-02 * 0.803207531480645 / 2.384e-06, - -2.0506859e-02 * 0.803207531480645 / 2.384e-06, -2.974033e-03 * 0.803207531480645 / 2.384e-06, - -3.07560e-04 * 0.803207531480645 / 2.384e-06, -1.8120e-05 * 0.803207531480645 / 2.384e-06, - 7.416505462720353e-01, - 5.805693545089249e-01, - - - -4.77e-07 * 0.831469612302545 / 2.384e-06, 1.08242e-04 * 0.831469612302545 / 2.384e-06, - 8.68797e-04 * 0.831469612302545 / 2.384e-06, 1.800537e-03 * 0.831469612302545 / 2.384e-06, - 3.5435200e-02 * 0.831469612302545 / 2.384e-06, 4.049301e-03 * 0.831469612302545 / 2.384e-06, 9.94205e-04 * 0.831469612302545 / 2.384e-06, 9.0599e-05 * 0.831469612302545 / 2.384e-06, /* 12 */ - 9.060e-06 * 0.831469612302545 / 2.384e-06, 1.16348e-04 * 0.831469612302545 / 2.384e-06, - 1.766682e-03 * 0.831469612302545 / 2.384e-06, 1.4358521e-02 * 0.831469612302545 / 2.384e-06, - -2.1372318e-02 * 0.831469612302545 / 2.384e-06, -3.14188e-03 * 0.831469612302545 / 2.384e-06, - -3.39031e-04 * 0.831469612302545 / 2.384e-06, -1.9550e-05 * 0.831469612302545 / 2.384e-06, - 6.681786379192989e-01, - 7.653668647301797e-01, - - - -4.77e-07 * 0.857728610000272 / 2.384e-06, 1.08719e-04 * 0.857728610000272 / 2.384e-06, - 8.29220e-04 * 0.857728610000272 / 2.384e-06, 1.399517e-03 * 0.857728610000272 / 2.384e-06, - 3.5242081e-02 * 0.857728610000272 / 2.384e-06, 4.215240e-03 * 0.857728610000272 / 2.384e-06, 9.89437e-04 * 0.857728610000272 / 2.384e-06, 8.7261e-05 * 0.857728610000272 / 2.384e-06, /* 11 */ - 8.106e-06 * 0.857728610000272 / 2.384e-06, 9.3937e-05 * 0.857728610000272 / 2.384e-06, - 1.597881e-03 * 0.857728610000272 / 2.384e-06, 1.3489246e-02 * 0.857728610000272 / 2.384e-06, - -2.2228718e-02 * 0.857728610000272 / 2.384e-06, -3.306866e-03 * 0.857728610000272 / 2.384e-06, - -3.71456e-04 * 0.857728610000272 / 2.384e-06, -2.1458e-05 * 0.857728610000272 / 2.384e-06, - 5.993769336819237e-01, - 9.427934736519954e-01, - - - -4.77e-07 * 0.881921264348355 / 2.384e-06, 1.08719e-04 * 0.881921264348355 / 2.384e-06, - 7.8392e-04 * 0.881921264348355 / 2.384e-06, 9.71317e-04 * 0.881921264348355 / 2.384e-06, - 3.5007000e-02 * 0.881921264348355 / 2.384e-06, 4.357815e-03 * 0.881921264348355 / 2.384e-06, 9.80854e-04 * 0.881921264348355 / 2.384e-06, 8.3923e-05 * 0.881921264348355 / 2.384e-06, /* 10 */ - 7.629e-06 * 0.881921264348355 / 2.384e-06, 7.2956e-05 * 0.881921264348355 / 2.384e-06, - 1.432419e-03 * 0.881921264348355 / 2.384e-06, 1.2627602e-02 * 0.881921264348355 / 2.384e-06, - -2.3074150e-02 * 0.881921264348355 / 2.384e-06, -3.467083e-03 * 0.881921264348355 / 2.384e-06, - -4.04358e-04 * 0.881921264348355 / 2.384e-06, -2.3365e-05 * 0.881921264348355 / 2.384e-06, - 5.345111359507916e-01, - 1.111140466039205e+00, - - - -9.54e-07 * 0.903989293123443 / 2.384e-06, 1.08242e-04 * 0.903989293123443 / 2.384e-06, - 7.31945e-04 * 0.903989293123443 / 2.384e-06, 5.15938e-04 * 0.903989293123443 / 2.384e-06, - 3.4730434e-02 * 0.903989293123443 / 2.384e-06, 4.477024e-03 * 0.903989293123443 / 2.384e-06, 9.68933e-04 * 0.903989293123443 / 2.384e-06, 8.0585e-05 * 0.903989293123443 / 2.384e-06, /* 9 */ - 6.676e-06 * 0.903989293123443 / 2.384e-06, 5.2929e-05 * 0.903989293123443 / 2.384e-06, - 1.269817e-03 * 0.903989293123443 / 2.384e-06, 1.1775017e-02 * 0.903989293123443 / 2.384e-06, - -2.3907185e-02 * 0.903989293123443 / 2.384e-06, -3.622532e-03 * 0.903989293123443 / 2.384e-06, - -4.38213e-04 * 0.903989293123443 / 2.384e-06, -2.5272e-05 * 0.903989293123443 / 2.384e-06, - 4.729647758913199e-01, - 1.268786568327291e+00, - - - -9.54e-07 * 0.92387953251128675613 / 2.384e-06, - 1.06812e-04 * 0.92387953251128675613 / 2.384e-06, - 6.74248e-04 * 0.92387953251128675613 / 2.384e-06, - 3.3379e-05 * 0.92387953251128675613 / 2.384e-06, - 3.4412861e-02 * 0.92387953251128675613 / 2.384e-06, - 4.573822e-03 * 0.92387953251128675613 / 2.384e-06, - 9.54151e-04 * 0.92387953251128675613 / 2.384e-06, - 7.6771e-05 * 0.92387953251128675613 / 2.384e-06, - 6.199e-06 * 0.92387953251128675613 / 2.384e-06, 3.4332e-05 * 0.92387953251128675613 / 2.384e-06, - 1.111031e-03 * 0.92387953251128675613 / 2.384e-06, - 1.0933399e-02 * 0.92387953251128675613 / 2.384e-06, - -2.4725437e-02 * 0.92387953251128675613 / 2.384e-06, - -3.771782e-03 * 0.92387953251128675613 / 2.384e-06, - -4.72546e-04 * 0.92387953251128675613 / 2.384e-06, - -2.7657e-05 * 0.92387953251128675613 / 2.384e-06, - 4.1421356237309504879e-01, /* tan(PI/8) */ - 1.414213562373095e+00, - - - -9.54e-07 * 0.941544065183021 / 2.384e-06, 1.05381e-04 * 0.941544065183021 / 2.384e-06, - 6.10352e-04 * 0.941544065183021 / 2.384e-06, -4.75883e-04 * 0.941544065183021 / 2.384e-06, - 3.4055710e-02 * 0.941544065183021 / 2.384e-06, 4.649162e-03 * 0.941544065183021 / 2.384e-06, 9.35555e-04 * 0.941544065183021 / 2.384e-06, 7.3433e-05 * 0.941544065183021 / 2.384e-06, /* 7 */ - 5.245e-06 * 0.941544065183021 / 2.384e-06, 1.7166e-05 * 0.941544065183021 / 2.384e-06, - 9.56535e-04 * 0.941544065183021 / 2.384e-06, 1.0103703e-02 * 0.941544065183021 / 2.384e-06, - -2.5527000e-02 * 0.941544065183021 / 2.384e-06, -3.914356e-03 * 0.941544065183021 / 2.384e-06, - -5.07355e-04 * 0.941544065183021 / 2.384e-06, -3.0041e-05 * 0.941544065183021 / 2.384e-06, - 3.578057213145241e-01, - 1.546020906725474e+00, - - - -9.54e-07 * 0.956940335732209 / 2.384e-06, 1.02520e-04 * 0.956940335732209 / 2.384e-06, - 5.39303e-04 * 0.956940335732209 / 2.384e-06, -1.011848e-03 * 0.956940335732209 / 2.384e-06, - 3.3659935e-02 * 0.956940335732209 / 2.384e-06, 4.703045e-03 * 0.956940335732209 / 2.384e-06, 9.15051e-04 * 0.956940335732209 / 2.384e-06, 7.0095e-05 * 0.956940335732209 / 2.384e-06, /* 6 */ - 4.768e-06 * 0.956940335732209 / 2.384e-06, 9.54e-07 * 0.956940335732209 / 2.384e-06, - 8.06808e-04 * 0.956940335732209 / 2.384e-06, 9.287834e-03 * 0.956940335732209 / 2.384e-06, - -2.6310921e-02 * 0.956940335732209 / 2.384e-06, -4.048824e-03 * 0.956940335732209 / 2.384e-06, - -5.42164e-04 * 0.956940335732209 / 2.384e-06, -3.2425e-05 * 0.956940335732209 / 2.384e-06, - 3.033466836073424e-01, - 1.662939224605090e+00, - - - -1.431e-06 * 0.970031253194544 / 2.384e-06, 9.9182e-05 * 0.970031253194544 / 2.384e-06, - 4.62532e-04 * 0.970031253194544 / 2.384e-06, -1.573563e-03 * 0.970031253194544 / 2.384e-06, - 3.3225536e-02 * 0.970031253194544 / 2.384e-06, 4.737377e-03 * 0.970031253194544 / 2.384e-06, 8.91685e-04 * 0.970031253194544 / 2.384e-06, 6.6280e-05 * 0.970031253194544 / 2.384e-06, /* 5 */ - 4.292e-06 * 0.970031253194544 / 2.384e-06, -1.3828e-05 * 0.970031253194544 / 2.384e-06, - 6.61850e-04 * 0.970031253194544 / 2.384e-06, 8.487225e-03 * 0.970031253194544 / 2.384e-06, - -2.7073860e-02 * 0.970031253194544 / 2.384e-06, -4.174709e-03 * 0.970031253194544 / 2.384e-06, - -5.76973e-04 * 0.970031253194544 / 2.384e-06, -3.4809e-05 * 0.970031253194544 / 2.384e-06, - 2.504869601913055e-01, - 1.763842528696710e+00, - - - -1.431e-06 * 0.98078528040323 / 2.384e-06, 9.5367e-05 * 0.98078528040323 / 2.384e-06, - 3.78609e-04 * 0.98078528040323 / 2.384e-06, -2.161503e-03 * 0.98078528040323 / 2.384e-06, - 3.2754898e-02 * 0.98078528040323 / 2.384e-06, 4.752159e-03 * 0.98078528040323 / 2.384e-06, 8.66413e-04 * 0.98078528040323 / 2.384e-06, 6.2943e-05 * 0.98078528040323 / 2.384e-06, /* 4 */ - 3.815e-06 * 0.98078528040323 / 2.384e-06, -2.718e-05 * 0.98078528040323 / 2.384e-06, - 5.22137e-04 * 0.98078528040323 / 2.384e-06, 7.703304e-03 * 0.98078528040323 / 2.384e-06, - -2.7815342e-02 * 0.98078528040323 / 2.384e-06, -4.290581e-03 * 0.98078528040323 / 2.384e-06, - -6.11782e-04 * 0.98078528040323 / 2.384e-06, -3.7670e-05 * 0.98078528040323 / 2.384e-06, - 1.989123673796580e-01, - 1.847759065022573e+00, - - - -1.907e-06 * 0.989176509964781 / 2.384e-06, 9.0122e-05 * 0.989176509964781 / 2.384e-06, - 2.88486e-04 * 0.989176509964781 / 2.384e-06, -2.774239e-03 * 0.989176509964781 / 2.384e-06, - 3.2248020e-02 * 0.989176509964781 / 2.384e-06, 4.748821e-03 * 0.989176509964781 / 2.384e-06, 8.38757e-04 * 0.989176509964781 / 2.384e-06, 5.9605e-05 * 0.989176509964781 / 2.384e-06, /* 3 */ - 3.338e-06 * 0.989176509964781 / 2.384e-06, -3.9577e-05 * 0.989176509964781 / 2.384e-06, - 3.88145e-04 * 0.989176509964781 / 2.384e-06, 6.937027e-03 * 0.989176509964781 / 2.384e-06, - -2.8532982e-02 * 0.989176509964781 / 2.384e-06, -4.395962e-03 * 0.989176509964781 / 2.384e-06, - -6.46591e-04 * 0.989176509964781 / 2.384e-06, -4.0531e-05 * 0.989176509964781 / 2.384e-06, - 1.483359875383474e-01, - 1.913880671464418e+00, - - - -1.907e-06 * 0.995184726672197 / 2.384e-06, 8.4400e-05 * 0.995184726672197 / 2.384e-06, - 1.91689e-04 * 0.995184726672197 / 2.384e-06, -3.411293e-03 * 0.995184726672197 / 2.384e-06, - 3.1706810e-02 * 0.995184726672197 / 2.384e-06, 4.728317e-03 * 0.995184726672197 / 2.384e-06, - 8.09669e-04 * 0.995184726672197 / 2.384e-06, 5.579e-05 * 0.995184726672197 / 2.384e-06, - 3.338e-06 * 0.995184726672197 / 2.384e-06, -5.0545e-05 * 0.995184726672197 / 2.384e-06, - 2.59876e-04 * 0.995184726672197 / 2.384e-06, 6.189346e-03 * 0.995184726672197 / 2.384e-06, - -2.9224873e-02 * 0.995184726672197 / 2.384e-06, -4.489899e-03 * 0.995184726672197 / 2.384e-06, - -6.80923e-04 * 0.995184726672197 / 2.384e-06, -4.3392e-05 * 0.995184726672197 / 2.384e-06, - 9.849140335716425e-02, - 1.961570560806461e+00, - - - -2.384e-06 * 0.998795456205172 / 2.384e-06, 7.7724e-05 * 0.998795456205172 / 2.384e-06, - 8.8215e-05 * 0.998795456205172 / 2.384e-06, -4.072189e-03 * 0.998795456205172 / 2.384e-06, - 3.1132698e-02 * 0.998795456205172 / 2.384e-06, 4.691124e-03 * 0.998795456205172 / 2.384e-06, - 7.79152e-04 * 0.998795456205172 / 2.384e-06, 5.2929e-05 * 0.998795456205172 / 2.384e-06, - 2.861e-06 * 0.998795456205172 / 2.384e-06, -6.0558e-05 * 0.998795456205172 / 2.384e-06, - 1.37329e-04 * 0.998795456205172 / 2.384e-06, 5.462170e-03 * 0.998795456205172 / 2.384e-06, - -2.9890060e-02 * 0.998795456205172 / 2.384e-06, -4.570484e-03 * 0.998795456205172 / 2.384e-06, - -7.14302e-04 * 0.998795456205172 / 2.384e-06, -4.6253e-05 * 0.998795456205172 / 2.384e-06, - 4.912684976946725e-02, - 1.990369453344394e+00, - - - 3.5780907e-02 * SQRT2 * 0.5 / 2.384e-06, 1.7876148e-02 * SQRT2 * 0.5 / 2.384e-06, - 3.134727e-03 * SQRT2 * 0.5 / 2.384e-06, 2.457142e-03 * SQRT2 * 0.5 / 2.384e-06, - 9.71317e-04 * SQRT2 * 0.5 / 2.384e-06, 2.18868e-04 * SQRT2 * 0.5 / 2.384e-06, - 1.01566e-04 * SQRT2 * 0.5 / 2.384e-06, 1.3828e-05 * SQRT2 * 0.5 / 2.384e-06, - - 3.0526638e-02 / 2.384e-06, 4.638195e-03 / 2.384e-06, 7.47204e-04 / 2.384e-06, - 4.9591e-05 / 2.384e-06, - 4.756451e-03 / 2.384e-06, 2.1458e-05 / 2.384e-06, -6.9618e-05 / 2.384e-06, /* 2.384e-06/2.384e-06 */ -}; -#endif - - -#define NS 12 -#define NL 36 - -static const FLOAT win[4][NL] = { - { - 2.382191739347913e-13, - 6.423305872147834e-13, - 9.400849094049688e-13, - 1.122435026096556e-12, - 1.183840321267481e-12, - 1.122435026096556e-12, - 9.400849094049690e-13, - 6.423305872147839e-13, - 2.382191739347918e-13, - - 5.456116108943412e-12, - 4.878985199565852e-12, - 4.240448995017367e-12, - 3.559909094758252e-12, - 2.858043359288075e-12, - 2.156177623817898e-12, - 1.475637723558783e-12, - 8.371015190102974e-13, - 2.599706096327376e-13, - - -5.456116108943412e-12, - -4.878985199565852e-12, - -4.240448995017367e-12, - -3.559909094758252e-12, - -2.858043359288076e-12, - -2.156177623817898e-12, - -1.475637723558783e-12, - -8.371015190102975e-13, - -2.599706096327376e-13, - - -2.382191739347923e-13, - -6.423305872147843e-13, - -9.400849094049696e-13, - -1.122435026096556e-12, - -1.183840321267481e-12, - -1.122435026096556e-12, - -9.400849094049694e-13, - -6.423305872147840e-13, - -2.382191739347918e-13, - }, - { - 2.382191739347913e-13, - 6.423305872147834e-13, - 9.400849094049688e-13, - 1.122435026096556e-12, - 1.183840321267481e-12, - 1.122435026096556e-12, - 9.400849094049688e-13, - 6.423305872147841e-13, - 2.382191739347918e-13, - - 5.456116108943413e-12, - 4.878985199565852e-12, - 4.240448995017367e-12, - 3.559909094758253e-12, - 2.858043359288075e-12, - 2.156177623817898e-12, - 1.475637723558782e-12, - 8.371015190102975e-13, - 2.599706096327376e-13, - - -5.461314069809755e-12, - -4.921085770524055e-12, - -4.343405037091838e-12, - -3.732668368707687e-12, - -3.093523840190885e-12, - -2.430835727329465e-12, - -1.734679010007751e-12, - -9.748253656609281e-13, - -2.797435120168326e-13, - - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - -2.283748241799531e-13, - -4.037858874020686e-13, - -2.146547464825323e-13, - }, - { - 1.316524975873958e-01, /* win[SHORT_TYPE] */ - 4.142135623730950e-01, - 7.673269879789602e-01, - - 1.091308501069271e+00, /* tantab_l */ - 1.303225372841206e+00, - 1.569685577117490e+00, - 1.920982126971166e+00, - 2.414213562373094e+00, - 3.171594802363212e+00, - 4.510708503662055e+00, - 7.595754112725146e+00, - 2.290376554843115e+01, - - 0.98480775301220802032, /* cx */ - 0.64278760968653936292, - 0.34202014332566882393, - 0.93969262078590842791, - -0.17364817766693030343, - -0.76604444311897790243, - 0.86602540378443870761, - 0.500000000000000e+00, - - -5.144957554275265e-01, /* ca */ - -4.717319685649723e-01, - -3.133774542039019e-01, - -1.819131996109812e-01, - -9.457419252642064e-02, - -4.096558288530405e-02, - -1.419856857247115e-02, - -3.699974673760037e-03, - - 8.574929257125442e-01, /* cs */ - 8.817419973177052e-01, - 9.496286491027329e-01, - 9.833145924917901e-01, - 9.955178160675857e-01, - 9.991605581781475e-01, - 9.998991952444470e-01, - 9.999931550702802e-01, - }, - { - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 0.000000000000000e+00, - 2.283748241799531e-13, - 4.037858874020686e-13, - 2.146547464825323e-13, - - 5.461314069809755e-12, - 4.921085770524055e-12, - 4.343405037091838e-12, - 3.732668368707687e-12, - 3.093523840190885e-12, - 2.430835727329466e-12, - 1.734679010007751e-12, - 9.748253656609281e-13, - 2.797435120168326e-13, - - -5.456116108943413e-12, - -4.878985199565852e-12, - -4.240448995017367e-12, - -3.559909094758253e-12, - -2.858043359288075e-12, - -2.156177623817898e-12, - -1.475637723558782e-12, - -8.371015190102975e-13, - -2.599706096327376e-13, - - -2.382191739347913e-13, - -6.423305872147834e-13, - -9.400849094049688e-13, - -1.122435026096556e-12, - -1.183840321267481e-12, - -1.122435026096556e-12, - -9.400849094049688e-13, - -6.423305872147841e-13, - -2.382191739347918e-13, - } -}; - -#define tantab_l (win[SHORT_TYPE]+3) -#define cx (win[SHORT_TYPE]+12) -#define ca (win[SHORT_TYPE]+20) -#define cs (win[SHORT_TYPE]+28) - -/************************************************************************ -* -* window_subband() -* -* PURPOSE: Overlapping window on PCM samples -* -* SEMANTICS: -* 32 16-bit pcm samples are scaled to fractional 2's complement and -* concatenated to the end of the window buffer #x#. The updated window -* buffer #x# is then windowed by the analysis window #c# to produce the -* windowed sample #z# -* -************************************************************************/ - -/* - * new IDCT routine written by Takehiro TOMINAGA - */ -static const int order[] = { - 0, 1, 16, 17, 8, 9, 24, 25, 4, 5, 20, 21, 12, 13, 28, 29, - 2, 3, 18, 19, 10, 11, 26, 27, 6, 7, 22, 23, 14, 15, 30, 31 -}; - - -/* returns sum_j=0^31 a[j]*cos(PI*j*(k+1/2)/32), 0<=k<32 */ -inline static void -window_subband(const sample_t * x1, FLOAT a[SBLIMIT]) -{ - int i; - FLOAT const *wp = enwindow + 10; - - const sample_t *x2 = &x1[238 - 14 - 286]; - - for (i = -15; i < 0; i++) { - FLOAT w, s, t; - - w = wp[-10]; - s = x2[-224] * w; - t = x1[224] * w; - w = wp[-9]; - s += x2[-160] * w; - t += x1[160] * w; - w = wp[-8]; - s += x2[-96] * w; - t += x1[96] * w; - w = wp[-7]; - s += x2[-32] * w; - t += x1[32] * w; - w = wp[-6]; - s += x2[32] * w; - t += x1[-32] * w; - w = wp[-5]; - s += x2[96] * w; - t += x1[-96] * w; - w = wp[-4]; - s += x2[160] * w; - t += x1[-160] * w; - w = wp[-3]; - s += x2[224] * w; - t += x1[-224] * w; - - w = wp[-2]; - s += x1[-256] * w; - t -= x2[256] * w; - w = wp[-1]; - s += x1[-192] * w; - t -= x2[192] * w; - w = wp[0]; - s += x1[-128] * w; - t -= x2[128] * w; - w = wp[1]; - s += x1[-64] * w; - t -= x2[64] * w; - w = wp[2]; - s += x1[0] * w; - t -= x2[0] * w; - w = wp[3]; - s += x1[64] * w; - t -= x2[-64] * w; - w = wp[4]; - s += x1[128] * w; - t -= x2[-128] * w; - w = wp[5]; - s += x1[192] * w; - t -= x2[-192] * w; - - /* - * this multiplyer could be removed, but it needs more 256 FLOAT data. - * thinking about the data cache performance, I think we should not - * use such a huge table. tt 2000/Oct/25 - */ - s *= wp[6]; - w = t - s; - a[30 + i * 2] = t + s; - a[31 + i * 2] = wp[7] * w; - wp += 18; - x1--; - x2++; - } - { - FLOAT s, t, u, v; - t = x1[-16] * wp[-10]; - s = x1[-32] * wp[-2]; - t += (x1[-48] - x1[16]) * wp[-9]; - s += x1[-96] * wp[-1]; - t += (x1[-80] + x1[48]) * wp[-8]; - s += x1[-160] * wp[0]; - t += (x1[-112] - x1[80]) * wp[-7]; - s += x1[-224] * wp[1]; - t += (x1[-144] + x1[112]) * wp[-6]; - s -= x1[32] * wp[2]; - t += (x1[-176] - x1[144]) * wp[-5]; - s -= x1[96] * wp[3]; - t += (x1[-208] + x1[176]) * wp[-4]; - s -= x1[160] * wp[4]; - t += (x1[-240] - x1[208]) * wp[-3]; - s -= x1[224]; - - u = s - t; - v = s + t; - - t = a[14]; - s = a[15] - t; - - a[31] = v + t; /* A0 */ - a[30] = u + s; /* A1 */ - a[15] = u - s; /* A2 */ - a[14] = v - t; /* A3 */ - } - { - FLOAT xr; - xr = a[28] - a[0]; - a[0] += a[28]; - a[28] = xr * wp[-2 * 18 + 7]; - xr = a[29] - a[1]; - a[1] += a[29]; - a[29] = xr * wp[-2 * 18 + 7]; - - xr = a[26] - a[2]; - a[2] += a[26]; - a[26] = xr * wp[-4 * 18 + 7]; - xr = a[27] - a[3]; - a[3] += a[27]; - a[27] = xr * wp[-4 * 18 + 7]; - - xr = a[24] - a[4]; - a[4] += a[24]; - a[24] = xr * wp[-6 * 18 + 7]; - xr = a[25] - a[5]; - a[5] += a[25]; - a[25] = xr * wp[-6 * 18 + 7]; - - xr = a[22] - a[6]; - a[6] += a[22]; - a[22] = xr * SQRT2; - xr = a[23] - a[7]; - a[7] += a[23]; - a[23] = xr * SQRT2 - a[7]; - a[7] -= a[6]; - a[22] -= a[7]; - a[23] -= a[22]; - - xr = a[6]; - a[6] = a[31] - xr; - a[31] = a[31] + xr; - xr = a[7]; - a[7] = a[30] - xr; - a[30] = a[30] + xr; - xr = a[22]; - a[22] = a[15] - xr; - a[15] = a[15] + xr; - xr = a[23]; - a[23] = a[14] - xr; - a[14] = a[14] + xr; - - xr = a[20] - a[8]; - a[8] += a[20]; - a[20] = xr * wp[-10 * 18 + 7]; - xr = a[21] - a[9]; - a[9] += a[21]; - a[21] = xr * wp[-10 * 18 + 7]; - - xr = a[18] - a[10]; - a[10] += a[18]; - a[18] = xr * wp[-12 * 18 + 7]; - xr = a[19] - a[11]; - a[11] += a[19]; - a[19] = xr * wp[-12 * 18 + 7]; - - xr = a[16] - a[12]; - a[12] += a[16]; - a[16] = xr * wp[-14 * 18 + 7]; - xr = a[17] - a[13]; - a[13] += a[17]; - a[17] = xr * wp[-14 * 18 + 7]; - - xr = -a[20] + a[24]; - a[20] += a[24]; - a[24] = xr * wp[-12 * 18 + 7]; - xr = -a[21] + a[25]; - a[21] += a[25]; - a[25] = xr * wp[-12 * 18 + 7]; - - xr = a[4] - a[8]; - a[4] += a[8]; - a[8] = xr * wp[-12 * 18 + 7]; - xr = a[5] - a[9]; - a[5] += a[9]; - a[9] = xr * wp[-12 * 18 + 7]; - - xr = a[0] - a[12]; - a[0] += a[12]; - a[12] = xr * wp[-4 * 18 + 7]; - xr = a[1] - a[13]; - a[1] += a[13]; - a[13] = xr * wp[-4 * 18 + 7]; - xr = a[16] - a[28]; - a[16] += a[28]; - a[28] = xr * wp[-4 * 18 + 7]; - xr = -a[17] + a[29]; - a[17] += a[29]; - a[29] = xr * wp[-4 * 18 + 7]; - - xr = SQRT2 * (a[2] - a[10]); - a[2] += a[10]; - a[10] = xr; - xr = SQRT2 * (a[3] - a[11]); - a[3] += a[11]; - a[11] = xr; - xr = SQRT2 * (-a[18] + a[26]); - a[18] += a[26]; - a[26] = xr - a[18]; - xr = SQRT2 * (-a[19] + a[27]); - a[19] += a[27]; - a[27] = xr - a[19]; - - xr = a[2]; - a[19] -= a[3]; - a[3] -= xr; - a[2] = a[31] - xr; - a[31] += xr; - xr = a[3]; - a[11] -= a[19]; - a[18] -= xr; - a[3] = a[30] - xr; - a[30] += xr; - xr = a[18]; - a[27] -= a[11]; - a[19] -= xr; - a[18] = a[15] - xr; - a[15] += xr; - - xr = a[19]; - a[10] -= xr; - a[19] = a[14] - xr; - a[14] += xr; - xr = a[10]; - a[11] -= xr; - a[10] = a[23] - xr; - a[23] += xr; - xr = a[11]; - a[26] -= xr; - a[11] = a[22] - xr; - a[22] += xr; - xr = a[26]; - a[27] -= xr; - a[26] = a[7] - xr; - a[7] += xr; - - xr = a[27]; - a[27] = a[6] - xr; - a[6] += xr; - - xr = SQRT2 * (a[0] - a[4]); - a[0] += a[4]; - a[4] = xr; - xr = SQRT2 * (a[1] - a[5]); - a[1] += a[5]; - a[5] = xr; - xr = SQRT2 * (a[16] - a[20]); - a[16] += a[20]; - a[20] = xr; - xr = SQRT2 * (a[17] - a[21]); - a[17] += a[21]; - a[21] = xr; - - xr = -SQRT2 * (a[8] - a[12]); - a[8] += a[12]; - a[12] = xr - a[8]; - xr = -SQRT2 * (a[9] - a[13]); - a[9] += a[13]; - a[13] = xr - a[9]; - xr = -SQRT2 * (a[25] - a[29]); - a[25] += a[29]; - a[29] = xr - a[25]; - xr = -SQRT2 * (a[24] + a[28]); - a[24] -= a[28]; - a[28] = xr - a[24]; - - xr = a[24] - a[16]; - a[24] = xr; - xr = a[20] - xr; - a[20] = xr; - xr = a[28] - xr; - a[28] = xr; - - xr = a[25] - a[17]; - a[25] = xr; - xr = a[21] - xr; - a[21] = xr; - xr = a[29] - xr; - a[29] = xr; - - xr = a[17] - a[1]; - a[17] = xr; - xr = a[9] - xr; - a[9] = xr; - xr = a[25] - xr; - a[25] = xr; - xr = a[5] - xr; - a[5] = xr; - xr = a[21] - xr; - a[21] = xr; - xr = a[13] - xr; - a[13] = xr; - xr = a[29] - xr; - a[29] = xr; - - xr = a[1] - a[0]; - a[1] = xr; - xr = a[16] - xr; - a[16] = xr; - xr = a[17] - xr; - a[17] = xr; - xr = a[8] - xr; - a[8] = xr; - xr = a[9] - xr; - a[9] = xr; - xr = a[24] - xr; - a[24] = xr; - xr = a[25] - xr; - a[25] = xr; - xr = a[4] - xr; - a[4] = xr; - xr = a[5] - xr; - a[5] = xr; - xr = a[20] - xr; - a[20] = xr; - xr = a[21] - xr; - a[21] = xr; - xr = a[12] - xr; - a[12] = xr; - xr = a[13] - xr; - a[13] = xr; - xr = a[28] - xr; - a[28] = xr; - xr = a[29] - xr; - a[29] = xr; - - xr = a[0]; - a[0] += a[31]; - a[31] -= xr; - xr = a[1]; - a[1] += a[30]; - a[30] -= xr; - xr = a[16]; - a[16] += a[15]; - a[15] -= xr; - xr = a[17]; - a[17] += a[14]; - a[14] -= xr; - xr = a[8]; - a[8] += a[23]; - a[23] -= xr; - xr = a[9]; - a[9] += a[22]; - a[22] -= xr; - xr = a[24]; - a[24] += a[7]; - a[7] -= xr; - xr = a[25]; - a[25] += a[6]; - a[6] -= xr; - xr = a[4]; - a[4] += a[27]; - a[27] -= xr; - xr = a[5]; - a[5] += a[26]; - a[26] -= xr; - xr = a[20]; - a[20] += a[11]; - a[11] -= xr; - xr = a[21]; - a[21] += a[10]; - a[10] -= xr; - xr = a[12]; - a[12] += a[19]; - a[19] -= xr; - xr = a[13]; - a[13] += a[18]; - a[18] -= xr; - xr = a[28]; - a[28] += a[3]; - a[3] -= xr; - xr = a[29]; - a[29] += a[2]; - a[2] -= xr; - } - -} - - -/*-------------------------------------------------------------------*/ -/* */ -/* Function: Calculation of the MDCT */ -/* In the case of long blocks (type 0,1,3) there are */ -/* 36 coefficents in the time domain and 18 in the frequency */ -/* domain. */ -/* In the case of short blocks (type 2) there are 3 */ -/* transformations with short length. This leads to 12 coefficents */ -/* in the time and 6 in the frequency domain. In this case the */ -/* results are stored side by side in the vector out[]. */ -/* */ -/* New layer3 */ -/* */ -/*-------------------------------------------------------------------*/ - -inline static void -mdct_short(FLOAT * inout) -{ - int l; - for (l = 0; l < 3; l++) { - FLOAT tc0, tc1, tc2, ts0, ts1, ts2; - - ts0 = inout[2 * 3] * win[SHORT_TYPE][0] - inout[5 * 3]; - tc0 = inout[0 * 3] * win[SHORT_TYPE][2] - inout[3 * 3]; - tc1 = ts0 + tc0; - tc2 = ts0 - tc0; - - ts0 = inout[5 * 3] * win[SHORT_TYPE][0] + inout[2 * 3]; - tc0 = inout[3 * 3] * win[SHORT_TYPE][2] + inout[0 * 3]; - ts1 = ts0 + tc0; - ts2 = -ts0 + tc0; - - tc0 = (inout[1 * 3] * win[SHORT_TYPE][1] - inout[4 * 3]) * 2.069978111953089e-11; /* tritab_s[1] */ - ts0 = (inout[4 * 3] * win[SHORT_TYPE][1] + inout[1 * 3]) * 2.069978111953089e-11; /* tritab_s[1] */ - - inout[3 * 0] = tc1 * 1.907525191737280e-11 /* tritab_s[2] */ + tc0; - inout[3 * 5] = -ts1 * 1.907525191737280e-11 /* tritab_s[0] */ + ts0; - - tc2 = tc2 * 0.86602540378443870761 * 1.907525191737281e-11 /* tritab_s[2] */ ; - ts1 = ts1 * 0.5 * 1.907525191737281e-11 + ts0; - inout[3 * 1] = tc2 - ts1; - inout[3 * 2] = tc2 + ts1; - - tc1 = tc1 * 0.5 * 1.907525191737281e-11 - tc0; - ts2 = ts2 * 0.86602540378443870761 * 1.907525191737281e-11 /* tritab_s[0] */ ; - inout[3 * 3] = tc1 + ts2; - inout[3 * 4] = tc1 - ts2; - - inout++; - } -} - -inline static void -mdct_long(FLOAT * out, FLOAT const *in) -{ - FLOAT ct, st; - { - FLOAT tc1, tc2, tc3, tc4, ts5, ts6, ts7, ts8; - /* 1,2, 5,6, 9,10, 13,14, 17 */ - tc1 = in[17] - in[9]; - tc3 = in[15] - in[11]; - tc4 = in[14] - in[12]; - ts5 = in[0] + in[8]; - ts6 = in[1] + in[7]; - ts7 = in[2] + in[6]; - ts8 = in[3] + in[5]; - - out[17] = (ts5 + ts7 - ts8) - (ts6 - in[4]); - st = (ts5 + ts7 - ts8) * cx[7] + (ts6 - in[4]); - ct = (tc1 - tc3 - tc4) * cx[6]; - out[5] = ct + st; - out[6] = ct - st; - - tc2 = (in[16] - in[10]) * cx[6]; - ts6 = ts6 * cx[7] + in[4]; - ct = tc1 * cx[0] + tc2 + tc3 * cx[1] + tc4 * cx[2]; - st = -ts5 * cx[4] + ts6 - ts7 * cx[5] + ts8 * cx[3]; - out[1] = ct + st; - out[2] = ct - st; - - ct = tc1 * cx[1] - tc2 - tc3 * cx[2] + tc4 * cx[0]; - st = -ts5 * cx[5] + ts6 - ts7 * cx[3] + ts8 * cx[4]; - out[9] = ct + st; - out[10] = ct - st; - - ct = tc1 * cx[2] - tc2 + tc3 * cx[0] - tc4 * cx[1]; - st = ts5 * cx[3] - ts6 + ts7 * cx[4] - ts8 * cx[5]; - out[13] = ct + st; - out[14] = ct - st; - } - { - FLOAT ts1, ts2, ts3, ts4, tc5, tc6, tc7, tc8; - - ts1 = in[8] - in[0]; - ts3 = in[6] - in[2]; - ts4 = in[5] - in[3]; - tc5 = in[17] + in[9]; - tc6 = in[16] + in[10]; - tc7 = in[15] + in[11]; - tc8 = in[14] + in[12]; - - out[0] = (tc5 + tc7 + tc8) + (tc6 + in[13]); - ct = (tc5 + tc7 + tc8) * cx[7] - (tc6 + in[13]); - st = (ts1 - ts3 + ts4) * cx[6]; - out[11] = ct + st; - out[12] = ct - st; - - ts2 = (in[7] - in[1]) * cx[6]; - tc6 = in[13] - tc6 * cx[7]; - ct = tc5 * cx[3] - tc6 + tc7 * cx[4] + tc8 * cx[5]; - st = ts1 * cx[2] + ts2 + ts3 * cx[0] + ts4 * cx[1]; - out[3] = ct + st; - out[4] = ct - st; - - ct = -tc5 * cx[5] + tc6 - tc7 * cx[3] - tc8 * cx[4]; - st = ts1 * cx[1] + ts2 - ts3 * cx[2] - ts4 * cx[0]; - out[7] = ct + st; - out[8] = ct - st; - - ct = -tc5 * cx[4] + tc6 - tc7 * cx[5] - tc8 * cx[3]; - st = ts1 * cx[0] - ts2 + ts3 * cx[1] - ts4 * cx[2]; - out[15] = ct + st; - out[16] = ct - st; - } -} - - -void -mdct_sub48(lame_internal_flags * gfc, const sample_t * w0, const sample_t * w1) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int gr, k, ch; - const sample_t *wk; - - wk = w0 + 286; - /* thinking cache performance, ch->gr loop is better than gr->ch loop */ - for (ch = 0; ch < cfg->channels_out; ch++) { - for (gr = 0; gr < cfg->mode_gr; gr++) { - int band; - gr_info *const gi = &(gfc->l3_side.tt[gr][ch]); - FLOAT *mdct_enc = gi->xr; - FLOAT *samp = esv->sb_sample[ch][1 - gr][0]; - - for (k = 0; k < 18 / 2; k++) { - window_subband(wk, samp); - window_subband(wk + 32, samp + 32); - samp += 64; - wk += 64; - /* - * Compensate for inversion in the analysis filter - */ - for (band = 1; band < 32; band += 2) { - samp[band - 32] *= -1; - } - } - - /* - * Perform imdct of 18 previous subband samples - * + 18 current subband samples - */ - for (band = 0; band < 32; band++, mdct_enc += 18) { - int type = gi->block_type; - FLOAT const *const band0 = esv->sb_sample[ch][gr][0] + order[band]; - FLOAT *const band1 = esv->sb_sample[ch][1 - gr][0] + order[band]; - if (gi->mixed_block_flag && band < 2) - type = 0; - if (esv->amp_filter[band] < 1e-12) { - memset(mdct_enc, 0, 18 * sizeof(FLOAT)); - } - else { - if (esv->amp_filter[band] < 1.0) { - for (k = 0; k < 18; k++) - band1[k * 32] *= esv->amp_filter[band]; - } - if (type == SHORT_TYPE) { - for (k = -NS / 4; k < 0; k++) { - FLOAT const w = win[SHORT_TYPE][k + 3]; - mdct_enc[k * 3 + 9] = band0[(9 + k) * 32] * w - band0[(8 - k) * 32]; - mdct_enc[k * 3 + 18] = band0[(14 - k) * 32] * w + band0[(15 + k) * 32]; - mdct_enc[k * 3 + 10] = band0[(15 + k) * 32] * w - band0[(14 - k) * 32]; - mdct_enc[k * 3 + 19] = band1[(2 - k) * 32] * w + band1[(3 + k) * 32]; - mdct_enc[k * 3 + 11] = band1[(3 + k) * 32] * w - band1[(2 - k) * 32]; - mdct_enc[k * 3 + 20] = band1[(8 - k) * 32] * w + band1[(9 + k) * 32]; - } - mdct_short(mdct_enc); - } - else { - FLOAT work[18]; - for (k = -NL / 4; k < 0; k++) { - FLOAT a, b; - a = win[type][k + 27] * band1[(k + 9) * 32] - + win[type][k + 36] * band1[(8 - k) * 32]; - b = win[type][k + 9] * band0[(k + 9) * 32] - - win[type][k + 18] * band0[(8 - k) * 32]; - work[k + 9] = a - b * tantab_l[k + 9]; - work[k + 18] = a * tantab_l[k + 9] + b; - } - - mdct_long(mdct_enc, work); - } - } - /* - * Perform aliasing reduction butterfly - */ - if (type != SHORT_TYPE && band != 0) { - for (k = 7; k >= 0; --k) { - FLOAT bu, bd; - bu = mdct_enc[k] * ca[k] + mdct_enc[-1 - k] * cs[k]; - bd = mdct_enc[k] * cs[k] - mdct_enc[-1 - k] * ca[k]; - - mdct_enc[-1 - k] = bu; - mdct_enc[k] = bd; - } - } - } - } - wk = w1 + 286; - if (cfg->mode_gr == 1) { - memcpy(esv->sb_sample[ch][0], esv->sb_sample[ch][1], 576 * sizeof(FLOAT)); - } - } -} diff --git a/lib-src/lame/libmp3lame/newmdct.h b/lib-src/lame/libmp3lame/newmdct.h deleted file mode 100644 index 0b58a954c..000000000 --- a/lib-src/lame/libmp3lame/newmdct.h +++ /dev/null @@ -1,27 +0,0 @@ -/* - * New Modified DCT include file - * - * Copyright (c) 1999 Takehiro TOMINAGA - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_NEWMDCT_H -#define LAME_NEWMDCT_H - -void mdct_sub48(lame_internal_flags * gfc, const sample_t * w0, const sample_t * w1); - -#endif /* LAME_NEWMDCT_H */ diff --git a/lib-src/lame/libmp3lame/presets.c b/lib-src/lame/libmp3lame/presets.c deleted file mode 100644 index ebfeafb00..000000000 --- a/lib-src/lame/libmp3lame/presets.c +++ /dev/null @@ -1,404 +0,0 @@ -/* - * presets.c -- Apply presets - * - * Copyright (c) 2002-2008 Gabriel Bouvigne - * Copyright (c) 2007-2012 Robert Hegemann - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. - */ - - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "set_get.h" -#include "encoder.h" -#include "util.h" -#include "lame_global_flags.h" - -#define SET_OPTION(opt, val, def) if (enforce) \ - (void) lame_set_##opt(gfp, val); \ - else if (!(fabs(lame_get_##opt(gfp) - def) > 0)) \ - (void) lame_set_##opt(gfp, val); - -#define SET__OPTION(opt, val, def) if (enforce) \ - lame_set_##opt(gfp, val); \ - else if (!(fabs(lame_get_##opt(gfp) - def) > 0)) \ - lame_set_##opt(gfp, val); - -#undef Min -#undef Max - -static inline int -min_int(int a, int b) -{ - if (a < b) { - return a; - } - return b; -} - -static inline int -max_int(int a, int b) -{ - if (a > b) { - return a; - } - return b; -} - - - -typedef struct { - int vbr_q; - int quant_comp; - int quant_comp_s; - int expY; - FLOAT st_lrm; /*short threshold */ - FLOAT st_s; - FLOAT masking_adj; - FLOAT masking_adj_short; - FLOAT ath_lower; - FLOAT ath_curve; - FLOAT ath_sensitivity; - FLOAT interch; - int safejoint; - int sfb21mod; - FLOAT msfix; - FLOAT minval; - FLOAT ath_fixpoint; -} vbr_presets_t; - - /* *INDENT-OFF* */ - - /* Switch mappings for VBR mode VBR_RH */ - static const vbr_presets_t vbr_old_switch_map[] = { - /*vbr_q qcomp_l qcomp_s expY st_lrm st_s mask adj_l adj_s ath_lower ath_curve ath_sens interChR safejoint sfb21mod msfix */ - {0, 9, 9, 0, 5.20, 125.0, -4.2, -6.3, 4.8, 1, 0, 0, 2, 21, 0.97, 5, 100}, - {1, 9, 9, 0, 5.30, 125.0, -3.6, -5.6, 4.5, 1.5, 0, 0, 2, 21, 1.35, 5, 100}, - {2, 9, 9, 0, 5.60, 125.0, -2.2, -3.5, 2.8, 2, 0, 0, 2, 21, 1.49, 5, 100}, - {3, 9, 9, 1, 5.80, 130.0, -1.8, -2.8, 2.6, 3, -4, 0, 2, 20, 1.64, 5, 100}, - {4, 9, 9, 1, 6.00, 135.0, -0.7, -1.1, 1.1, 3.5, -8, 0, 2, 0, 1.79, 5, 100}, - {5, 9, 9, 1, 6.40, 140.0, 0.5, 0.4, -7.5, 4, -12, 0.0002, 0, 0, 1.95, 5, 100}, - {6, 9, 9, 1, 6.60, 145.0, 0.67, 0.65, -14.7, 6.5, -19, 0.0004, 0, 0, 2.30, 5, 100}, - {7, 9, 9, 1, 6.60, 145.0, 0.8, 0.75, -19.7, 8, -22, 0.0006, 0, 0, 2.70, 5, 100}, - {8, 9, 9, 1, 6.60, 145.0, 1.2, 1.15, -27.5, 10, -23, 0.0007, 0, 0, 0, 5, 100}, - {9, 9, 9, 1, 6.60, 145.0, 1.6, 1.6, -36, 11, -25, 0.0008, 0, 0, 0, 5, 100}, - {10, 9, 9, 1, 6.60, 145.0, 2.0, 2.0, -36, 12, -25, 0.0008, 0, 0, 0, 5, 100} - }; - - static const vbr_presets_t vbr_mt_psy_switch_map[] = { - /*vbr_q qcomp_l qcomp_s expY st_lrm st_s mask adj_l adj_s ath_lower ath_curve ath_sens --- safejoint sfb21mod msfix */ - {0, 9, 9, 0, 4.20, 25.0, -6.8, -6.8, 7.1, 1, 0, 0, 2, 31, 1.000, 5, 100}, - {1, 9, 9, 0, 4.20, 25.0, -4.8, -4.8, 5.4, 1.4, -1, 0, 2, 27, 1.122, 5, 98}, - {2, 9, 9, 0, 4.20, 25.0, -2.6, -2.6, 3.7, 2.0, -3, 0, 2, 23, 1.288, 5, 97}, - {3, 9, 9, 1, 4.20, 25.0, -1.6, -1.6, 2.0, 2.0, -5, 0, 2, 18, 1.479, 5, 96}, - {4, 9, 9, 1, 4.20, 25.0, -0.0, -0.0, 0.0, 2.0, -8, 0, 2, 12, 1.698, 5, 95}, - {5, 9, 9, 1, 4.20, 25.0, 1.3, 1.3, -6, 3.5, -11, 0, 2, 8, 1.950, 5, 94.2}, -#if 0 - {6, 9, 9, 1, 4.50, 100.0, 1.5, 1.5, -24.0, 6.0, -14, 0, 2, 4, 2.239, 3, 93.9}, - {7, 9, 9, 1, 4.80, 200.0, 1.7, 1.7, -28.0, 9.0, -20, 0, 2, 0, 2.570, 1, 93.6}, -#else - {6, 9, 9, 1, 4.50, 100.0, 2.2, 2.3, -12.0, 6.0, -14, 0, 2, 4, 2.239, 3, 93.9}, - {7, 9, 9, 1, 4.80, 200.0, 2.7, 2.7, -18.0, 9.0, -17, 0, 2, 0, 2.570, 1, 93.6}, -#endif - {8, 9, 9, 1, 5.30, 300.0, 2.8, 2.8, -21.0, 10.0, -23, 0.0002, 0, 0, 2.951, 0, 93.3}, - {9, 9, 9, 1, 6.60, 300.0, 2.8, 2.8, -23.0, 11.0, -25, 0.0006, 0, 0, 3.388, 0, 93.3}, - {10, 9, 9, 1, 25.00, 300.0, 2.8, 2.8, -25.0, 12.0, -27, 0.0025, 0, 0, 3.500, 0, 93.3} - }; - - /* *INDENT-ON* */ - -static vbr_presets_t const* -get_vbr_preset(int v) -{ - switch (v) { - case vbr_mtrh: - case vbr_mt: - return &vbr_mt_psy_switch_map[0]; - default: - return &vbr_old_switch_map[0]; - } -} - -#define NOOP(m) (void)p.m -#define LERP(m) (p.m = p.m + x * (q.m - p.m)) - -static void -apply_vbr_preset(lame_global_flags * gfp, int a, int enforce) -{ - vbr_presets_t const *vbr_preset = get_vbr_preset(lame_get_VBR(gfp)); - float x = gfp->VBR_q_frac; - vbr_presets_t p = vbr_preset[a]; - vbr_presets_t q = vbr_preset[a + 1]; - vbr_presets_t const *set = &p; - - NOOP(vbr_q); - NOOP(quant_comp); - NOOP(quant_comp_s); - NOOP(expY); - LERP(st_lrm); - LERP(st_s); - LERP(masking_adj); - LERP(masking_adj_short); - LERP(ath_lower); - LERP(ath_curve); - LERP(ath_sensitivity); - LERP(interch); - NOOP(safejoint); - LERP(sfb21mod); - LERP(msfix); - LERP(minval); - LERP(ath_fixpoint); - - (void) lame_set_VBR_q(gfp, set->vbr_q); - SET_OPTION(quant_comp, set->quant_comp, -1.0); - SET_OPTION(quant_comp_short, set->quant_comp_s, -1.0); - if (set->expY) { - (void) lame_set_experimentalY(gfp, set->expY); - } - SET_OPTION(short_threshold_lrm, set->st_lrm, -1); - SET_OPTION(short_threshold_s, set->st_s, -1); - SET_OPTION(maskingadjust, set->masking_adj, 0); - SET_OPTION(maskingadjust_short, set->masking_adj_short, 0); - if (lame_get_VBR(gfp) == vbr_mt || lame_get_VBR(gfp) == vbr_mtrh) { - lame_set_ATHtype(gfp, 5); - } - SET_OPTION(ATHlower, set->ath_lower, 0); - SET_OPTION(ATHcurve, set->ath_curve, -1); - SET_OPTION(athaa_sensitivity, set->ath_sensitivity, 0); - if (set->interch > 0) { - SET_OPTION(interChRatio, set->interch, -1); - } - - /* parameters for which there is no proper set/get interface */ - if (set->safejoint > 0) { - (void) lame_set_exp_nspsytune(gfp, lame_get_exp_nspsytune(gfp) | 2); - } - if (set->sfb21mod > 0) { - int const nsp = lame_get_exp_nspsytune(gfp); - int const val = (nsp >> 20) & 63; - if (val == 0) { - int const sf21mod = (set->sfb21mod << 20) | nsp; - (void) lame_set_exp_nspsytune(gfp, sf21mod); - } - } - SET__OPTION(msfix, set->msfix, -1); - - if (enforce == 0) { - gfp->VBR_q = a; - gfp->VBR_q_frac = x; - } - gfp->internal_flags->cfg.minval = set->minval; - { /* take care of gain adjustments */ - double const x = fabs(gfp->scale); - double const y = (x > 0.f) ? (10.f * log10(x)) : 0.f; - gfp->internal_flags->cfg.ATHfixpoint = set->ath_fixpoint - y; - } -} - -static int -apply_abr_preset(lame_global_flags * gfp, int preset, int enforce) -{ - typedef struct { - int abr_kbps; - int quant_comp; - int quant_comp_s; - int safejoint; - FLOAT nsmsfix; - FLOAT st_lrm; /*short threshold */ - FLOAT st_s; - FLOAT scale; - FLOAT masking_adj; - FLOAT ath_lower; - FLOAT ath_curve; - FLOAT interch; - int sfscale; - } abr_presets_t; - - - /* *INDENT-OFF* */ - - /* - * Switch mappings for ABR mode - */ - const abr_presets_t abr_switch_map[] = { - /* kbps quant q_s safejoint nsmsfix st_lrm st_s scale msk ath_lwr ath_curve interch , sfscale */ - { 8, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -30.0, 11, 0.0012, 1}, /* 8, impossible to use in stereo */ - { 16, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -25.0, 11, 0.0010, 1}, /* 16 */ - { 24, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -20.0, 11, 0.0010, 1}, /* 24 */ - { 32, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -15.0, 11, 0.0010, 1}, /* 32 */ - { 40, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -10.0, 11, 0.0009, 1}, /* 40 */ - { 48, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -10.0, 11, 0.0009, 1}, /* 48 */ - { 56, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -6.0, 11, 0.0008, 1}, /* 56 */ - { 64, 9, 9, 0, 0, 6.60, 145, 0.95, 0, -2.0, 11, 0.0008, 1}, /* 64 */ - { 80, 9, 9, 0, 0, 6.60, 145, 0.95, 0, .0, 8, 0.0007, 1}, /* 80 */ - { 96, 9, 9, 0, 2.50, 6.60, 145, 0.95, 0, 1.0, 5.5, 0.0006, 1}, /* 96 */ - {112, 9, 9, 0, 2.25, 6.60, 145, 0.95, 0, 2.0, 4.5, 0.0005, 1}, /* 112 */ - {128, 9, 9, 0, 1.95, 6.40, 140, 0.95, 0, 3.0, 4, 0.0002, 1}, /* 128 */ - {160, 9, 9, 1, 1.79, 6.00, 135, 0.95, -2, 5.0, 3.5, 0, 1}, /* 160 */ - {192, 9, 9, 1, 1.49, 5.60, 125, 0.97, -4, 7.0, 3, 0, 0}, /* 192 */ - {224, 9, 9, 1, 1.25, 5.20, 125, 0.98, -6, 9.0, 2, 0, 0}, /* 224 */ - {256, 9, 9, 1, 0.97, 5.20, 125, 1.00, -8, 10.0, 1, 0, 0}, /* 256 */ - {320, 9, 9, 1, 0.90, 5.20, 125, 1.00, -10, 12.0, 0, 0, 0} /* 320 */ - }; - - /* *INDENT-ON* */ - - /* Variables for the ABR stuff */ - int r; - int actual_bitrate = preset; - - r = nearestBitrateFullIndex(preset); - - (void) lame_set_VBR(gfp, vbr_abr); - (void) lame_set_VBR_mean_bitrate_kbps(gfp, (actual_bitrate)); - (void) lame_set_VBR_mean_bitrate_kbps(gfp, min_int(lame_get_VBR_mean_bitrate_kbps(gfp), 320)); - (void) lame_set_VBR_mean_bitrate_kbps(gfp, max_int(lame_get_VBR_mean_bitrate_kbps(gfp), 8)); - (void) lame_set_brate(gfp, lame_get_VBR_mean_bitrate_kbps(gfp)); - - - /* parameters for which there is no proper set/get interface */ - if (abr_switch_map[r].safejoint > 0) - (void) lame_set_exp_nspsytune(gfp, lame_get_exp_nspsytune(gfp) | 2); /* safejoint */ - - if (abr_switch_map[r].sfscale > 0) - (void) lame_set_sfscale(gfp, 1); - - - SET_OPTION(quant_comp, abr_switch_map[r].quant_comp, -1.0); - SET_OPTION(quant_comp_short, abr_switch_map[r].quant_comp_s, -1.0); - - SET__OPTION(msfix, abr_switch_map[r].nsmsfix, -1); - - SET_OPTION(short_threshold_lrm, abr_switch_map[r].st_lrm, -1); - SET_OPTION(short_threshold_s, abr_switch_map[r].st_s, -1); - - /* ABR seems to have big problems with clipping, especially at low bitrates */ - /* so we compensate for that here by using a scale value depending on bitrate */ - lame_set_scale(gfp, lame_get_scale(gfp) * abr_switch_map[r].scale); - - SET_OPTION(maskingadjust, abr_switch_map[r].masking_adj, 0); - if (abr_switch_map[r].masking_adj > 0) { - SET_OPTION(maskingadjust_short, abr_switch_map[r].masking_adj * .9, 0); - } - else { - SET_OPTION(maskingadjust_short, abr_switch_map[r].masking_adj * 1.1, 0); - } - - - SET_OPTION(ATHlower, abr_switch_map[r].ath_lower, 0); - SET_OPTION(ATHcurve, abr_switch_map[r].ath_curve, -1); - - SET_OPTION(interChRatio, abr_switch_map[r].interch, -1); - - (void) abr_switch_map[r].abr_kbps; - - gfp->internal_flags->cfg.minval = 5. * (abr_switch_map[r].abr_kbps / 320.); - - return preset; -} - - - -int -apply_preset(lame_global_flags * gfp, int preset, int enforce) -{ - /*translate legacy presets */ - switch (preset) { - case R3MIX: - { - preset = V3; - (void) lame_set_VBR(gfp, vbr_mtrh); - break; - } - case MEDIUM: - case MEDIUM_FAST: - { - preset = V4; - (void) lame_set_VBR(gfp, vbr_mtrh); - break; - } - case STANDARD: - case STANDARD_FAST: - { - preset = V2; - (void) lame_set_VBR(gfp, vbr_mtrh); - break; - } - case EXTREME: - case EXTREME_FAST: - { - preset = V0; - (void) lame_set_VBR(gfp, vbr_mtrh); - break; - } - case INSANE: - { - preset = 320; - gfp->preset = preset; - (void) apply_abr_preset(gfp, preset, enforce); - lame_set_VBR(gfp, vbr_off); - return preset; - } - } - - gfp->preset = preset; - { - switch (preset) { - case V9: - apply_vbr_preset(gfp, 9, enforce); - return preset; - case V8: - apply_vbr_preset(gfp, 8, enforce); - return preset; - case V7: - apply_vbr_preset(gfp, 7, enforce); - return preset; - case V6: - apply_vbr_preset(gfp, 6, enforce); - return preset; - case V5: - apply_vbr_preset(gfp, 5, enforce); - return preset; - case V4: - apply_vbr_preset(gfp, 4, enforce); - return preset; - case V3: - apply_vbr_preset(gfp, 3, enforce); - return preset; - case V2: - apply_vbr_preset(gfp, 2, enforce); - return preset; - case V1: - apply_vbr_preset(gfp, 1, enforce); - return preset; - case V0: - apply_vbr_preset(gfp, 0, enforce); - return preset; - default: - break; - } - } - if (8 <= preset && preset <= 320) { - return apply_abr_preset(gfp, preset, enforce); - } - - gfp->preset = 0; /*no corresponding preset found */ - return preset; -} diff --git a/lib-src/lame/libmp3lame/psymodel.c b/lib-src/lame/libmp3lame/psymodel.c deleted file mode 100644 index 60076ee72..000000000 --- a/lib-src/lame/libmp3lame/psymodel.c +++ /dev/null @@ -1,2167 +0,0 @@ -/* - * psymodel.c - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 2001-2002 Naoki Shibata - * Copyright (c) 2000-2003 Takehiro Tominaga - * Copyright (c) 2000-2012 Robert Hegemann - * Copyright (c) 2000-2005 Gabriel Bouvigne - * Copyright (c) 2000-2005 Alexander Leidinger - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: psymodel.c,v 1.216 2017/09/06 19:38:23 aleidinger Exp $ */ - - -/* -PSYCHO ACOUSTICS - - -This routine computes the psycho acoustics, delayed by one granule. - -Input: buffer of PCM data (1024 samples). - -This window should be centered over the 576 sample granule window. -The routine will compute the psycho acoustics for -this granule, but return the psycho acoustics computed -for the *previous* granule. This is because the block -type of the previous granule can only be determined -after we have computed the psycho acoustics for the following -granule. - -Output: maskings and energies for each scalefactor band. -block type, PE, and some correlation measures. -The PE is used by CBR modes to determine if extra bits -from the bit reservoir should be used. The correlation -measures are used to determine mid/side or regular stereo. -*/ -/* -Notation: - -barks: a non-linear frequency scale. Mapping from frequency to - barks is given by freq2bark() - -scalefactor bands: The spectrum (frequencies) are broken into - SBMAX "scalefactor bands". Thes bands - are determined by the MPEG ISO spec. In - the noise shaping/quantization code, we allocate - bits among the partition bands to achieve the - best possible quality - -partition bands: The spectrum is also broken into about - 64 "partition bands". Each partition - band is about .34 barks wide. There are about 2-5 - partition bands for each scalefactor band. - -LAME computes all psycho acoustic information for each partition -band. Then at the end of the computations, this information -is mapped to scalefactor bands. The energy in each scalefactor -band is taken as the sum of the energy in all partition bands -which overlap the scalefactor band. The maskings can be computed -in the same way (and thus represent the average masking in that band) -or by taking the minmum value multiplied by the number of -partition bands used (which represents a minimum masking in that band). -*/ -/* -The general outline is as follows: - -1. compute the energy in each partition band -2. compute the tonality in each partition band -3. compute the strength of each partion band "masker" -4. compute the masking (via the spreading function applied to each masker) -5. Modifications for mid/side masking. - -Each partition band is considiered a "masker". The strength -of the i'th masker in band j is given by: - - s3(bark(i)-bark(j))*strength(i) - -The strength of the masker is a function of the energy and tonality. -The more tonal, the less masking. LAME uses a simple linear formula -(controlled by NMT and TMN) which says the strength is given by the -energy divided by a linear function of the tonality. -*/ -/* -s3() is the "spreading function". It is given by a formula -determined via listening tests. - -The total masking in the j'th partition band is the sum over -all maskings i. It is thus given by the convolution of -the strength with s3(), the "spreading function." - -masking(j) = sum_over_i s3(i-j)*strength(i) = s3 o strength - -where "o" = convolution operator. s3 is given by a formula determined -via listening tests. It is normalized so that s3 o 1 = 1. - -Note: instead of a simple convolution, LAME also has the -option of using "additive masking" - -The most critical part is step 2, computing the tonality of each -partition band. LAME has two tonality estimators. The first -is based on the ISO spec, and measures how predictiable the -signal is over time. The more predictable, the more tonal. -The second measure is based on looking at the spectrum of -a single granule. The more peaky the spectrum, the more -tonal. By most indications, the latter approach is better. - -Finally, in step 5, the maskings for the mid and side -channel are possibly increased. Under certain circumstances, -noise in the mid & side channels is assumed to also -be masked by strong maskers in the L or R channels. - - -Other data computed by the psy-model: - -ms_ratio side-channel / mid-channel masking ratio (for previous granule) -ms_ratio_next side-channel / mid-channel masking ratio for this granule - -percep_entropy[2] L and R values (prev granule) of PE - A measure of how - much pre-echo is in the previous granule -percep_entropy_MS[2] mid and side channel values (prev granule) of percep_entropy -energy[4] L,R,M,S energy in each channel, prev granule -blocktype_d[2] block type to use for previous granule -*/ - - - - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "psymodel.h" -#include "lame_global_flags.h" -#include "fft.h" -#include "lame-analysis.h" - - -#define NSFIRLEN 21 - -#ifdef M_LN10 -#define LN_TO_LOG10 (M_LN10/10) -#else -#define LN_TO_LOG10 0.2302585093 -#endif - - -/* - L3psycho_anal. Compute psycho acoustics. - - Data returned to the calling program must be delayed by one - granule. - - This is done in two places. - If we do not need to know the blocktype, the copying - can be done here at the top of the program: we copy the data for - the last granule (computed during the last call) before it is - overwritten with the new data. It looks like this: - - 0. static psymodel_data - 1. calling_program_data = psymodel_data - 2. compute psymodel_data - - For data which needs to know the blocktype, the copying must be - done at the end of this loop, and the old values must be saved: - - 0. static psymodel_data_old - 1. compute psymodel_data - 2. compute possible block type of this granule - 3. compute final block type of previous granule based on #2. - 4. calling_program_data = psymodel_data_old - 5. psymodel_data_old = psymodel_data -*/ - - - - - -/* psycho_loudness_approx - jd - 2001 mar 12 -in: energy - BLKSIZE/2 elements of frequency magnitudes ^ 2 - gfp - uses out_samplerate, ATHtype (also needed for ATHformula) -returns: loudness^2 approximation, a positive value roughly tuned for a value - of 1.0 for signals near clipping. -notes: When calibrated, feeding this function binary white noise at sample - values +32767 or -32768 should return values that approach 3. - ATHformula is used to approximate an equal loudness curve. -future: Data indicates that the shape of the equal loudness curve varies - with intensity. This function might be improved by using an equal - loudness curve shaped for typical playback levels (instead of the - ATH, that is shaped for the threshold). A flexible realization might - simply bend the existing ATH curve to achieve the desired shape. - However, the potential gain may not be enough to justify an effort. -*/ -static FLOAT -psycho_loudness_approx(FLOAT const *energy, FLOAT const *eql_w) -{ - int i; - FLOAT loudness_power; - - loudness_power = 0.0; - /* apply weights to power in freq. bands */ - for (i = 0; i < BLKSIZE / 2; ++i) - loudness_power += energy[i] * eql_w[i]; - loudness_power *= VO_SCALE; - - return loudness_power; -} - -/* mask_add optimization */ -/* init the limit values used to avoid computing log in mask_add when it is not necessary */ - -/* For example, with i = 10*log10(m2/m1)/10*16 (= log10(m2/m1)*16) - * - * abs(i)>8 is equivalent (as i is an integer) to - * abs(i)>=9 - * i>=9 || i<=-9 - * equivalent to (as i is the biggest integer smaller than log10(m2/m1)*16 - * or the smallest integer bigger than log10(m2/m1)*16 depending on the sign of log10(m2/m1)*16) - * log10(m2/m1)>=9/16 || log10(m2/m1)<=-9/16 - * exp10 is strictly increasing thus this is equivalent to - * m2/m1 >= 10^(9/16) || m2/m1<=10^(-9/16) which are comparisons to constants - */ - - -#define I1LIMIT 8 /* as in if(i>8) */ -#define I2LIMIT 23 /* as in if(i>24) -> changed 23 */ -#define MLIMIT 15 /* as in if(m<15) */ - -/* pow(10, (I1LIMIT + 1) / 16.0); */ -static const FLOAT ma_max_i1 = 3.6517412725483771; -/* pow(10, (I2LIMIT + 1) / 16.0); */ -static const FLOAT ma_max_i2 = 31.622776601683793; -/* pow(10, (MLIMIT) / 10.0); */ -static const FLOAT ma_max_m = 31.622776601683793; - - /*This is the masking table: - According to tonality, values are going from 0dB (TMN) - to 9.3dB (NMT). - After additive masking computation, 8dB are added, so - final values are going from 8dB to 17.3dB - */ -static const FLOAT tab[] = { - 1.0 /*pow(10, -0) */ , - 0.79433 /*pow(10, -0.1) */ , - 0.63096 /*pow(10, -0.2) */ , - 0.63096 /*pow(10, -0.2) */ , - 0.63096 /*pow(10, -0.2) */ , - 0.63096 /*pow(10, -0.2) */ , - 0.63096 /*pow(10, -0.2) */ , - 0.25119 /*pow(10, -0.6) */ , - 0.11749 /*pow(10, -0.93) */ -}; - -static const int tab_mask_add_delta[] = { 2, 2, 2, 1, 1, 1, 0, 0, -1 }; -#define STATIC_ASSERT_EQUAL_DIMENSION(A,B) enum{static_assert_##A=1/((dimension_of(A) == dimension_of(B))?1:0)} - -inline static int -mask_add_delta(int i) -{ - STATIC_ASSERT_EQUAL_DIMENSION(tab_mask_add_delta,tab); - assert(i < (int)dimension_of(tab)); - return tab_mask_add_delta[i]; -} - - -static void -init_mask_add_max_values(void) -{ -#ifndef NDEBUG - FLOAT const _ma_max_i1 = pow(10, (I1LIMIT + 1) / 16.0); - FLOAT const _ma_max_i2 = pow(10, (I2LIMIT + 1) / 16.0); - FLOAT const _ma_max_m = pow(10, (MLIMIT) / 10.0); - assert(fabs(ma_max_i1 - _ma_max_i1) <= FLT_EPSILON); - assert(fabs(ma_max_i2 - _ma_max_i2) <= FLT_EPSILON); - assert(fabs(ma_max_m - _ma_max_m ) <= FLT_EPSILON); -#endif -} - - - - -/* addition of simultaneous masking Naoki Shibata 2000/7 */ -inline static FLOAT -vbrpsy_mask_add(FLOAT m1, FLOAT m2, int b, int delta) -{ - static const FLOAT table2[] = { - 1.33352 * 1.33352, 1.35879 * 1.35879, 1.38454 * 1.38454, 1.39497 * 1.39497, - 1.40548 * 1.40548, 1.3537 * 1.3537, 1.30382 * 1.30382, 1.22321 * 1.22321, - 1.14758 * 1.14758, - 1 - }; - - FLOAT ratio; - - if (m1 < 0) { - m1 = 0; - } - if (m2 < 0) { - m2 = 0; - } - if (m1 <= 0) { - return m2; - } - if (m2 <= 0) { - return m1; - } - if (m2 > m1) { - ratio = m2 / m1; - } - else { - ratio = m1 / m2; - } - if (abs(b) <= delta) { /* approximately, 1 bark = 3 partitions */ - /* originally 'if(i > 8)' */ - if (ratio >= ma_max_i1) { - return m1 + m2; - } - else { - int i = (int) (FAST_LOG10_X(ratio, 16.0f)); - return (m1 + m2) * table2[i]; - } - } - if (ratio < ma_max_i2) { - return m1 + m2; - } - if (m1 < m2) { - m1 = m2; - } - return m1; -} - - -/* short block threshold calculation (part 2) - - partition band bo_s[sfb] is at the transition from scalefactor - band sfb to the next one sfb+1; enn and thmm have to be split - between them -*/ -static void -convert_partition2scalefac(PsyConst_CB2SB_t const *const gd, FLOAT const *eb, FLOAT const *thr, - FLOAT enn_out[], FLOAT thm_out[]) -{ - FLOAT enn, thmm; - int sb, b, n = gd->n_sb; - enn = thmm = 0.0f; - for (sb = b = 0; sb < n; ++b, ++sb) { - int const bo_sb = gd->bo[sb]; - int const npart = gd->npart; - int const b_lim = bo_sb < npart ? bo_sb : npart; - while (b < b_lim) { - assert(eb[b] >= 0); /* iff failed, it may indicate some index error elsewhere */ - assert(thr[b] >= 0); - enn += eb[b]; - thmm += thr[b]; - b++; - } - if (b >= npart) { - enn_out[sb] = enn; - thm_out[sb] = thmm; - ++sb; - break; - } - assert(eb[b] >= 0); /* iff failed, it may indicate some index error elsewhere */ - assert(thr[b] >= 0); - { - /* at transition sfb -> sfb+1 */ - FLOAT const w_curr = gd->bo_weight[sb]; - FLOAT const w_next = 1.0f - w_curr; - enn += w_curr * eb[b]; - thmm += w_curr * thr[b]; - enn_out[sb] = enn; - thm_out[sb] = thmm; - enn = w_next * eb[b]; - thmm = w_next * thr[b]; - } - } - /* zero initialize the rest */ - for (; sb < n; ++sb) { - enn_out[sb] = 0; - thm_out[sb] = 0; - } -} - -static void -convert_partition2scalefac_s(lame_internal_flags * gfc, FLOAT const *eb, FLOAT const *thr, int chn, - int sblock) -{ - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gds = &gfc->cd_psy->s; - FLOAT enn[SBMAX_s], thm[SBMAX_s]; - int sb; - convert_partition2scalefac(gds, eb, thr, enn, thm); - for (sb = 0; sb < SBMAX_s; ++sb) { - psv->en[chn].s[sb][sblock] = enn[sb]; - psv->thm[chn].s[sb][sblock] = thm[sb]; - } -} - -/* longblock threshold calculation (part 2) */ -static void -convert_partition2scalefac_l(lame_internal_flags * gfc, FLOAT const *eb, FLOAT const *thr, int chn) -{ - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gdl = &gfc->cd_psy->l; - FLOAT *enn = &psv->en[chn].l[0]; - FLOAT *thm = &psv->thm[chn].l[0]; - convert_partition2scalefac(gdl, eb, thr, enn, thm); -} - -static void -convert_partition2scalefac_l_to_s(lame_internal_flags * gfc, FLOAT const *eb, FLOAT const *thr, - int chn) -{ - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gds = &gfc->cd_psy->l_to_s; - FLOAT enn[SBMAX_s], thm[SBMAX_s]; - int sb, sblock; - convert_partition2scalefac(gds, eb, thr, enn, thm); - for (sb = 0; sb < SBMAX_s; ++sb) { - FLOAT const scale = 1. / 64.f; - FLOAT const tmp_enn = enn[sb]; - FLOAT const tmp_thm = thm[sb] * scale; - for (sblock = 0; sblock < 3; ++sblock) { - psv->en[chn].s[sb][sblock] = tmp_enn; - psv->thm[chn].s[sb][sblock] = tmp_thm; - } - } -} - - - -static inline FLOAT -NS_INTERP(FLOAT x, FLOAT y, FLOAT r) -{ - /* was pow((x),(r))*pow((y),1-(r)) */ - if (r >= 1.0f) - return x; /* 99.7% of the time */ - if (r <= 0.0f) - return y; - if (y > 0.0f) - return powf(x / y, r) * y; /* rest of the time */ - return 0.0f; /* never happens */ -} - - - -static FLOAT -pecalc_s(III_psy_ratio const *mr, FLOAT masking_lower) -{ - FLOAT pe_s; - static const FLOAT regcoef_s[] = { - 11.8, /* these values are tuned only for 44.1kHz... */ - 13.6, - 17.2, - 32, - 46.5, - 51.3, - 57.5, - 67.1, - 71.5, - 84.6, - 97.6, - 130, -/* 255.8 */ - }; - unsigned int sb, sblock; - - pe_s = 1236.28f / 4; - for (sb = 0; sb < SBMAX_s - 1; sb++) { - for (sblock = 0; sblock < 3; sblock++) { - FLOAT const thm = mr->thm.s[sb][sblock]; - assert(sb < dimension_of(regcoef_s)); - if (thm > 0.0f) { - FLOAT const x = thm * masking_lower; - FLOAT const en = mr->en.s[sb][sblock]; - if (en > x) { - if (en > x * 1e10f) { - pe_s += regcoef_s[sb] * (10.0f * LOG10); - } - else { - assert(x > 0); - pe_s += regcoef_s[sb] * FAST_LOG10(en / x); - } - } - } - } - } - - return pe_s; -} - -static FLOAT -pecalc_l(III_psy_ratio const *mr, FLOAT masking_lower) -{ - FLOAT pe_l; - static const FLOAT regcoef_l[] = { - 6.8, /* these values are tuned only for 44.1kHz... */ - 5.8, - 5.8, - 6.4, - 6.5, - 9.9, - 12.1, - 14.4, - 15, - 18.9, - 21.6, - 26.9, - 34.2, - 40.2, - 46.8, - 56.5, - 60.7, - 73.9, - 85.7, - 93.4, - 126.1, -/* 241.3 */ - }; - unsigned int sb; - - pe_l = 1124.23f / 4; - for (sb = 0; sb < SBMAX_l - 1; sb++) { - FLOAT const thm = mr->thm.l[sb]; - assert(sb < dimension_of(regcoef_l)); - if (thm > 0.0f) { - FLOAT const x = thm * masking_lower; - FLOAT const en = mr->en.l[sb]; - if (en > x) { - if (en > x * 1e10f) { - pe_l += regcoef_l[sb] * (10.0f * LOG10); - } - else { - assert(x > 0); - pe_l += regcoef_l[sb] * FAST_LOG10(en / x); - } - } - } - } - - return pe_l; -} - - -static void -calc_energy(PsyConst_CB2SB_t const *l, FLOAT const *fftenergy, FLOAT * eb, FLOAT * max, FLOAT * avg) -{ - int b, j; - - for (b = j = 0; b < l->npart; ++b) { - FLOAT ebb = 0, m = 0; - int i; - for (i = 0; i < l->numlines[b]; ++i, ++j) { - FLOAT const el = fftenergy[j]; - assert(el >= 0); - ebb += el; - if (m < el) - m = el; - } - eb[b] = ebb; - max[b] = m; - avg[b] = ebb * l->rnumlines[b]; - assert(l->rnumlines[b] >= 0); - assert(ebb >= 0); - assert(eb[b] >= 0); - assert(max[b] >= 0); - assert(avg[b] >= 0); - } -} - - -static void -calc_mask_index_l(lame_internal_flags const *gfc, FLOAT const *max, - FLOAT const *avg, unsigned char *mask_idx) -{ - PsyConst_CB2SB_t const *const gdl = &gfc->cd_psy->l; - FLOAT m, a; - int b, k; - int const last_tab_entry = sizeof(tab) / sizeof(tab[0]) - 1; - b = 0; - a = avg[b] + avg[b + 1]; - assert(a >= 0); - if (a > 0.0f) { - m = max[b]; - if (m < max[b + 1]) - m = max[b + 1]; - assert((gdl->numlines[b] + gdl->numlines[b + 1] - 1) > 0); - a = 20.0f * (m * 2.0f - a) - / (a * (gdl->numlines[b] + gdl->numlines[b + 1] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - - for (b = 1; b < gdl->npart - 1; b++) { - a = avg[b - 1] + avg[b] + avg[b + 1]; - assert(a >= 0); - if (a > 0.0f) { - m = max[b - 1]; - if (m < max[b]) - m = max[b]; - if (m < max[b + 1]) - m = max[b + 1]; - assert((gdl->numlines[b - 1] + gdl->numlines[b] + gdl->numlines[b + 1] - 1) > 0); - a = 20.0f * (m * 3.0f - a) - / (a * (gdl->numlines[b - 1] + gdl->numlines[b] + gdl->numlines[b + 1] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - } - assert(b > 0); - assert(b == gdl->npart - 1); - - a = avg[b - 1] + avg[b]; - assert(a >= 0); - if (a > 0.0f) { - m = max[b - 1]; - if (m < max[b]) - m = max[b]; - assert((gdl->numlines[b - 1] + gdl->numlines[b] - 1) > 0); - a = 20.0f * (m * 2.0f - a) - / (a * (gdl->numlines[b - 1] + gdl->numlines[b] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - assert(b == (gdl->npart - 1)); -} - - -static void -vbrpsy_compute_fft_l(lame_internal_flags * gfc, const sample_t * const buffer[2], int chn, - int gr_out, FLOAT fftenergy[HBLKSIZE], FLOAT(*wsamp_l)[BLKSIZE]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - PsyStateVar_t *psv = &gfc->sv_psy; - plotting_data *plt = cfg->analysis ? gfc->pinfo : 0; - int j; - - if (chn < 2) { - fft_long(gfc, *wsamp_l, chn, buffer); - } - else if (chn == 2) { - FLOAT const sqrt2_half = SQRT2 * 0.5f; - /* FFT data for mid and side channel is derived from L & R */ - for (j = BLKSIZE - 1; j >= 0; --j) { - FLOAT const l = wsamp_l[0][j]; - FLOAT const r = wsamp_l[1][j]; - wsamp_l[0][j] = (l + r) * sqrt2_half; - wsamp_l[1][j] = (l - r) * sqrt2_half; - } - } - - /********************************************************************* - * compute energies - *********************************************************************/ - fftenergy[0] = wsamp_l[0][0]; - fftenergy[0] *= fftenergy[0]; - - for (j = BLKSIZE / 2 - 1; j >= 0; --j) { - FLOAT const re = (*wsamp_l)[BLKSIZE / 2 - j]; - FLOAT const im = (*wsamp_l)[BLKSIZE / 2 + j]; - fftenergy[BLKSIZE / 2 - j] = (re * re + im * im) * 0.5f; - } - /* total energy */ - { - FLOAT totalenergy = 0.0f; - for (j = 11; j < HBLKSIZE; j++) - totalenergy += fftenergy[j]; - - psv->tot_ener[chn] = totalenergy; - } - - if (plt) { - for (j = 0; j < HBLKSIZE; j++) { - plt->energy[gr_out][chn][j] = plt->energy_save[chn][j]; - plt->energy_save[chn][j] = fftenergy[j]; - } - } -} - - -static void -vbrpsy_compute_fft_s(lame_internal_flags const *gfc, const sample_t * const buffer[2], int chn, - int sblock, FLOAT(*fftenergy_s)[HBLKSIZE_s], FLOAT(*wsamp_s)[3][BLKSIZE_s]) -{ - int j; - - if (sblock == 0 && chn < 2) { - fft_short(gfc, *wsamp_s, chn, buffer); - } - if (chn == 2) { - FLOAT const sqrt2_half = SQRT2 * 0.5f; - /* FFT data for mid and side channel is derived from L & R */ - for (j = BLKSIZE_s - 1; j >= 0; --j) { - FLOAT const l = wsamp_s[0][sblock][j]; - FLOAT const r = wsamp_s[1][sblock][j]; - wsamp_s[0][sblock][j] = (l + r) * sqrt2_half; - wsamp_s[1][sblock][j] = (l - r) * sqrt2_half; - } - } - - /********************************************************************* - * compute energies - *********************************************************************/ - fftenergy_s[sblock][0] = (*wsamp_s)[sblock][0]; - fftenergy_s[sblock][0] *= fftenergy_s[sblock][0]; - for (j = BLKSIZE_s / 2 - 1; j >= 0; --j) { - FLOAT const re = (*wsamp_s)[sblock][BLKSIZE_s / 2 - j]; - FLOAT const im = (*wsamp_s)[sblock][BLKSIZE_s / 2 + j]; - fftenergy_s[sblock][BLKSIZE_s / 2 - j] = (re * re + im * im) * 0.5f; - } -} - - - /********************************************************************* - * compute loudness approximation (used for ATH auto-level adjustment) - *********************************************************************/ -static void -vbrpsy_compute_loudness_approximation_l(lame_internal_flags * gfc, int gr_out, int chn, - const FLOAT fftenergy[HBLKSIZE]) -{ - PsyStateVar_t *psv = &gfc->sv_psy; - if (chn < 2) { /*no loudness for mid/side ch */ - gfc->ov_psy.loudness_sq[gr_out][chn] = psv->loudness_sq_save[chn]; - psv->loudness_sq_save[chn] = psycho_loudness_approx(fftenergy, gfc->ATH->eql_w); - } -} - - - /********************************************************************** - * Apply HPF of fs/4 to the input signal. - * This is used for attack detection / handling. - **********************************************************************/ -static void -vbrpsy_attack_detection(lame_internal_flags * gfc, const sample_t * const buffer[2], int gr_out, - III_psy_ratio masking_ratio[2][2], III_psy_ratio masking_MS_ratio[2][2], - FLOAT energy[4], FLOAT sub_short_factor[4][3], int ns_attacks[4][4], - int uselongblock[2]) -{ - FLOAT ns_hpfsmpl[2][576]; - SessionConfig_t const *const cfg = &gfc->cfg; - PsyStateVar_t *const psv = &gfc->sv_psy; - plotting_data *plt = cfg->analysis ? gfc->pinfo : 0; - int const n_chn_out = cfg->channels_out; - /* chn=2 and 3 = Mid and Side channels */ - int const n_chn_psy = (cfg->mode == JOINT_STEREO) ? 4 : n_chn_out; - int chn, i, j; - - memset(&ns_hpfsmpl[0][0], 0, sizeof(ns_hpfsmpl)); - /* Don't copy the input buffer into a temporary buffer */ - /* unroll the loop 2 times */ - for (chn = 0; chn < n_chn_out; chn++) { - static const FLOAT fircoef[] = { - -8.65163e-18 * 2, -0.00851586 * 2, -6.74764e-18 * 2, 0.0209036 * 2, - -3.36639e-17 * 2, -0.0438162 * 2, -1.54175e-17 * 2, 0.0931738 * 2, - -5.52212e-17 * 2, -0.313819 * 2 - }; - /* apply high pass filter of fs/4 */ - const sample_t *const firbuf = &buffer[chn][576 - 350 - NSFIRLEN + 192]; - assert(dimension_of(fircoef) == ((NSFIRLEN - 1) / 2)); - for (i = 0; i < 576; i++) { - FLOAT sum1, sum2; - sum1 = firbuf[i + 10]; - sum2 = 0.0; - for (j = 0; j < ((NSFIRLEN - 1) / 2) - 1; j += 2) { - sum1 += fircoef[j] * (firbuf[i + j] + firbuf[i + NSFIRLEN - j]); - sum2 += fircoef[j + 1] * (firbuf[i + j + 1] + firbuf[i + NSFIRLEN - j - 1]); - } - ns_hpfsmpl[chn][i] = sum1 + sum2; - } - masking_ratio[gr_out][chn].en = psv->en[chn]; - masking_ratio[gr_out][chn].thm = psv->thm[chn]; - if (n_chn_psy > 2) { - /* MS maskings */ - /*percep_MS_entropy [chn-2] = gfc -> pe [chn]; */ - masking_MS_ratio[gr_out][chn].en = psv->en[chn + 2]; - masking_MS_ratio[gr_out][chn].thm = psv->thm[chn + 2]; - } - } - for (chn = 0; chn < n_chn_psy; chn++) { - FLOAT attack_intensity[12]; - FLOAT en_subshort[12]; - FLOAT en_short[4] = { 0, 0, 0, 0 }; - FLOAT const *pf = ns_hpfsmpl[chn & 1]; - int ns_uselongblock = 1; - - if (chn == 2) { - for (i = 0, j = 576; j > 0; ++i, --j) { - FLOAT const l = ns_hpfsmpl[0][i]; - FLOAT const r = ns_hpfsmpl[1][i]; - ns_hpfsmpl[0][i] = l + r; - ns_hpfsmpl[1][i] = l - r; - } - } - /*************************************************************** - * determine the block type (window type) - ***************************************************************/ - /* calculate energies of each sub-shortblocks */ - for (i = 0; i < 3; i++) { - en_subshort[i] = psv->last_en_subshort[chn][i + 6]; - assert(psv->last_en_subshort[chn][i + 4] > 0); - attack_intensity[i] = en_subshort[i] / psv->last_en_subshort[chn][i + 4]; - en_short[0] += en_subshort[i]; - } - - for (i = 0; i < 9; i++) { - FLOAT const *const pfe = pf + 576 / 9; - FLOAT p = 1.; - for (; pf < pfe; pf++) - if (p < fabs(*pf)) - p = fabs(*pf); - psv->last_en_subshort[chn][i] = en_subshort[i + 3] = p; - en_short[1 + i / 3] += p; - if (p > en_subshort[i + 3 - 2]) { - assert(en_subshort[i + 3 - 2] > 0); - p = p / en_subshort[i + 3 - 2]; - } - else if (en_subshort[i + 3 - 2] > p * 10.0f) { - assert(p > 0); - p = en_subshort[i + 3 - 2] / (p * 10.0f); - } - else { - p = 0.0; - } - attack_intensity[i + 3] = p; - } - - /* pulse like signal detection for fatboy.wav and so on */ - for (i = 0; i < 3; ++i) { - FLOAT const enn = - en_subshort[i * 3 + 3] + en_subshort[i * 3 + 4] + en_subshort[i * 3 + 5]; - FLOAT factor = 1.f; - if (en_subshort[i * 3 + 5] * 6 < enn) { - factor *= 0.5f; - if (en_subshort[i * 3 + 4] * 6 < enn) { - factor *= 0.5f; - } - } - sub_short_factor[chn][i] = factor; - } - - if (plt) { - FLOAT x = attack_intensity[0]; - for (i = 1; i < 12; i++) { - if (x < attack_intensity[i]) { - x = attack_intensity[i]; - } - } - plt->ers[gr_out][chn] = plt->ers_save[chn]; - plt->ers_save[chn] = x; - } - - /* compare energies between sub-shortblocks */ - { - FLOAT x = gfc->cd_psy->attack_threshold[chn]; - for (i = 0; i < 12; i++) { - if (ns_attacks[chn][i / 3] == 0) { - if (attack_intensity[i] > x) { - ns_attacks[chn][i / 3] = (i % 3) + 1; - } - } - } - } - /* should have energy change between short blocks, in order to avoid periodic signals */ - /* Good samples to show the effect are Trumpet test songs */ - /* GB: tuned (1) to avoid too many short blocks for test sample TRUMPET */ - /* RH: tuned (2) to let enough short blocks through for test sample FSOL and SNAPS */ - for (i = 1; i < 4; i++) { - FLOAT const u = en_short[i - 1]; - FLOAT const v = en_short[i]; - FLOAT const m = Max(u, v); - if (m < 40000) { /* (2) */ - if (u < 1.7f * v && v < 1.7f * u) { /* (1) */ - if (i == 1 && ns_attacks[chn][0] <= ns_attacks[chn][i]) { - ns_attacks[chn][0] = 0; - } - ns_attacks[chn][i] = 0; - } - } - } - - if (ns_attacks[chn][0] <= psv->last_attacks[chn]) { - ns_attacks[chn][0] = 0; - } - - if (psv->last_attacks[chn] == 3 || - ns_attacks[chn][0] + ns_attacks[chn][1] + ns_attacks[chn][2] + ns_attacks[chn][3]) { - ns_uselongblock = 0; - - if (ns_attacks[chn][1] && ns_attacks[chn][0]) { - ns_attacks[chn][1] = 0; - } - if (ns_attacks[chn][2] && ns_attacks[chn][1]) { - ns_attacks[chn][2] = 0; - } - if (ns_attacks[chn][3] && ns_attacks[chn][2]) { - ns_attacks[chn][3] = 0; - } - } - - if (chn < 2) { - uselongblock[chn] = ns_uselongblock; - } - else { - if (ns_uselongblock == 0) { - uselongblock[0] = uselongblock[1] = 0; - } - } - - /* there is a one granule delay. Copy maskings computed last call - * into masking_ratio to return to calling program. - */ - energy[chn] = psv->tot_ener[chn]; - } -} - - -static void -vbrpsy_skip_masking_s(lame_internal_flags * gfc, int chn, int sblock) -{ - if (sblock == 0) { - FLOAT *nbs2 = &gfc->sv_psy.nb_s2[chn][0]; - FLOAT *nbs1 = &gfc->sv_psy.nb_s1[chn][0]; - int const n = gfc->cd_psy->s.npart; - int b; - for (b = 0; b < n; b++) { - nbs2[b] = nbs1[b]; - } - } -} - - -static void -vbrpsy_calc_mask_index_s(lame_internal_flags const *gfc, FLOAT const *max, - FLOAT const *avg, unsigned char *mask_idx) -{ - PsyConst_CB2SB_t const *const gds = &gfc->cd_psy->s; - FLOAT m, a; - int b, k; - int const last_tab_entry = dimension_of(tab) - 1; - b = 0; - a = avg[b] + avg[b + 1]; - assert(a >= 0); - if (a > 0.0f) { - m = max[b]; - if (m < max[b + 1]) - m = max[b + 1]; - assert((gds->numlines[b] + gds->numlines[b + 1] - 1) > 0); - a = 20.0f * (m * 2.0f - a) - / (a * (gds->numlines[b] + gds->numlines[b + 1] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - - for (b = 1; b < gds->npart - 1; b++) { - a = avg[b - 1] + avg[b] + avg[b + 1]; - assert(b + 1 < gds->npart); - assert(a >= 0); - if (a > 0.0) { - m = max[b - 1]; - if (m < max[b]) - m = max[b]; - if (m < max[b + 1]) - m = max[b + 1]; - assert((gds->numlines[b - 1] + gds->numlines[b] + gds->numlines[b + 1] - 1) > 0); - a = 20.0f * (m * 3.0f - a) - / (a * (gds->numlines[b - 1] + gds->numlines[b] + gds->numlines[b + 1] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - } - assert(b > 0); - assert(b == gds->npart - 1); - - a = avg[b - 1] + avg[b]; - assert(a >= 0); - if (a > 0.0f) { - m = max[b - 1]; - if (m < max[b]) - m = max[b]; - assert((gds->numlines[b - 1] + gds->numlines[b] - 1) > 0); - a = 20.0f * (m * 2.0f - a) - / (a * (gds->numlines[b - 1] + gds->numlines[b] - 1)); - k = (int) a; - if (k > last_tab_entry) - k = last_tab_entry; - mask_idx[b] = k; - } - else { - mask_idx[b] = 0; - } - assert(b == (gds->npart - 1)); -} - - -static void -vbrpsy_compute_masking_s(lame_internal_flags * gfc, const FLOAT(*fftenergy_s)[HBLKSIZE_s], - FLOAT * eb, FLOAT * thr, int chn, int sblock) -{ - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gds = &gfc->cd_psy->s; - FLOAT max[CBANDS], avg[CBANDS]; - int i, j, b; - unsigned char mask_idx_s[CBANDS]; - - memset(max, 0, sizeof(max)); - memset(avg, 0, sizeof(avg)); - - for (b = j = 0; b < gds->npart; ++b) { - FLOAT ebb = 0, m = 0; - int const n = gds->numlines[b]; - for (i = 0; i < n; ++i, ++j) { - FLOAT const el = fftenergy_s[sblock][j]; - ebb += el; - if (m < el) - m = el; - } - eb[b] = ebb; - assert(ebb >= 0); - max[b] = m; - assert(n > 0); - avg[b] = ebb * gds->rnumlines[b]; - assert(avg[b] >= 0); - } - assert(b == gds->npart); - assert(j == 129); - vbrpsy_calc_mask_index_s(gfc, max, avg, mask_idx_s); - for (j = b = 0; b < gds->npart; b++) { - int kk = gds->s3ind[b][0]; - int const last = gds->s3ind[b][1]; - int const delta = mask_add_delta(mask_idx_s[b]); - int dd, dd_n; - FLOAT x, ecb, avg_mask; - FLOAT const masking_lower = gds->masking_lower[b] * gfc->sv_qnt.masking_lower; - - dd = mask_idx_s[kk]; - dd_n = 1; - ecb = gds->s3[j] * eb[kk] * tab[mask_idx_s[kk]]; - ++j, ++kk; - while (kk <= last) { - dd += mask_idx_s[kk]; - dd_n += 1; - x = gds->s3[j] * eb[kk] * tab[mask_idx_s[kk]]; - ecb = vbrpsy_mask_add(ecb, x, kk - b, delta); - ++j, ++kk; - } - dd = (1 + 2 * dd) / (2 * dd_n); - avg_mask = tab[dd] * 0.5f; - ecb *= avg_mask; -#if 0 /* we can do PRE ECHO control now here, or do it later */ - if (psv->blocktype_old[chn & 0x01] == SHORT_TYPE) { - /* limit calculated threshold by even older granule */ - FLOAT const t1 = rpelev_s * psv->nb_s1[chn][b]; - FLOAT const t2 = rpelev2_s * psv->nb_s2[chn][b]; - FLOAT const tm = (t2 > 0) ? Min(ecb, t2) : ecb; - thr[b] = (t1 > 0) ? NS_INTERP(Min(tm, t1), ecb, 0.6) : ecb; - } - else { - /* limit calculated threshold by older granule */ - FLOAT const t1 = rpelev_s * psv->nb_s1[chn][b]; - thr[b] = (t1 > 0) ? NS_INTERP(Min(ecb, t1), ecb, 0.6) : ecb; - } -#else /* we do it later */ - thr[b] = ecb; -#endif - psv->nb_s2[chn][b] = psv->nb_s1[chn][b]; - psv->nb_s1[chn][b] = ecb; - { - /* if THR exceeds EB, the quantization routines will take the difference - * from other bands. in case of strong tonal samples (tonaltest.wav) - * this leads to heavy distortions. that's why we limit THR here. - */ - x = max[b]; - x *= gds->minval[b]; - x *= avg_mask; - if (thr[b] > x) { - thr[b] = x; - } - } - if (masking_lower > 1) { - thr[b] *= masking_lower; - } - if (thr[b] > eb[b]) { - thr[b] = eb[b]; - } - if (masking_lower < 1) { - thr[b] *= masking_lower; - } - - assert(thr[b] >= 0); - } - for (; b < CBANDS; ++b) { - eb[b] = 0; - thr[b] = 0; - } -} - - -static void -vbrpsy_compute_masking_l(lame_internal_flags * gfc, const FLOAT fftenergy[HBLKSIZE], - FLOAT eb_l[CBANDS], FLOAT thr[CBANDS], int chn) -{ - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gdl = &gfc->cd_psy->l; - FLOAT max[CBANDS], avg[CBANDS]; - unsigned char mask_idx_l[CBANDS + 2]; - int k, b; - - /********************************************************************* - * Calculate the energy and the tonality of each partition. - *********************************************************************/ - calc_energy(gdl, fftenergy, eb_l, max, avg); - calc_mask_index_l(gfc, max, avg, mask_idx_l); - - /********************************************************************* - * convolve the partitioned energy and unpredictability - * with the spreading function, s3_l[b][k] - ********************************************************************/ - k = 0; - for (b = 0; b < gdl->npart; b++) { - FLOAT x, ecb, avg_mask, t; - FLOAT const masking_lower = gdl->masking_lower[b] * gfc->sv_qnt.masking_lower; - /* convolve the partitioned energy with the spreading function */ - int kk = gdl->s3ind[b][0]; - int const last = gdl->s3ind[b][1]; - int const delta = mask_add_delta(mask_idx_l[b]); - int dd = 0, dd_n = 0; - - dd = mask_idx_l[kk]; - dd_n += 1; - ecb = gdl->s3[k] * eb_l[kk] * tab[mask_idx_l[kk]]; - ++k, ++kk; - while (kk <= last) { - dd += mask_idx_l[kk]; - dd_n += 1; - x = gdl->s3[k] * eb_l[kk] * tab[mask_idx_l[kk]]; - t = vbrpsy_mask_add(ecb, x, kk - b, delta); -#if 0 - ecb += eb_l[kk]; - if (ecb > t) { - ecb = t; - } -#else - ecb = t; -#endif - ++k, ++kk; - } - dd = (1 + 2 * dd) / (2 * dd_n); - avg_mask = tab[dd] * 0.5f; - ecb *= avg_mask; - - /**** long block pre-echo control ****/ - /* dont use long block pre-echo control if previous granule was - * a short block. This is to avoid the situation: - * frame0: quiet (very low masking) - * frame1: surge (triggers short blocks) - * frame2: regular frame. looks like pre-echo when compared to - * frame0, but all pre-echo was in frame1. - */ - /* chn=0,1 L and R channels - chn=2,3 S and M channels. - */ - if (psv->blocktype_old[chn & 0x01] == SHORT_TYPE) { - FLOAT const ecb_limit = rpelev * psv->nb_l1[chn][b]; - if (ecb_limit > 0) { - thr[b] = Min(ecb, ecb_limit); - } - else { - /* Robert 071209: - Because we don't calculate long block psy when we know a granule - should be of short blocks, we don't have any clue how the granule - before would have looked like as a long block. So we have to guess - a little bit for this END_TYPE block. - Most of the time we get away with this sloppyness. (fingers crossed :) - The speed increase is worth it. - */ - thr[b] = Min(ecb, eb_l[b] * NS_PREECHO_ATT2); - } - } - else { - FLOAT ecb_limit_2 = rpelev2 * psv->nb_l2[chn][b]; - FLOAT ecb_limit_1 = rpelev * psv->nb_l1[chn][b]; - FLOAT ecb_limit; - if (ecb_limit_2 <= 0) { - ecb_limit_2 = ecb; - } - if (ecb_limit_1 <= 0) { - ecb_limit_1 = ecb; - } - if (psv->blocktype_old[chn & 0x01] == NORM_TYPE) { - ecb_limit = Min(ecb_limit_1, ecb_limit_2); - } - else { - ecb_limit = ecb_limit_1; - } - thr[b] = Min(ecb, ecb_limit); - } - psv->nb_l2[chn][b] = psv->nb_l1[chn][b]; - psv->nb_l1[chn][b] = ecb; - { - /* if THR exceeds EB, the quantization routines will take the difference - * from other bands. in case of strong tonal samples (tonaltest.wav) - * this leads to heavy distortions. that's why we limit THR here. - */ - x = max[b]; - x *= gdl->minval[b]; - x *= avg_mask; - if (thr[b] > x) { - thr[b] = x; - } - } - if (masking_lower > 1) { - thr[b] *= masking_lower; - } - if (thr[b] > eb_l[b]) { - thr[b] = eb_l[b]; - } - if (masking_lower < 1) { - thr[b] *= masking_lower; - } - assert(thr[b] >= 0); - } - for (; b < CBANDS; ++b) { - eb_l[b] = 0; - thr[b] = 0; - } -} - - -static void -vbrpsy_compute_block_type(SessionConfig_t const *cfg, int *uselongblock) -{ - int chn; - - if (cfg->short_blocks == short_block_coupled - /* force both channels to use the same block type */ - /* this is necessary if the frame is to be encoded in ms_stereo. */ - /* But even without ms_stereo, FhG does this */ - && !(uselongblock[0] && uselongblock[1])) - uselongblock[0] = uselongblock[1] = 0; - - for (chn = 0; chn < cfg->channels_out; chn++) { - /* disable short blocks */ - if (cfg->short_blocks == short_block_dispensed) { - uselongblock[chn] = 1; - } - if (cfg->short_blocks == short_block_forced) { - uselongblock[chn] = 0; - } - } -} - - -static void -vbrpsy_apply_block_type(PsyStateVar_t * psv, int nch, int const *uselongblock, int *blocktype_d) -{ - int chn; - - /* update the blocktype of the previous granule, since it depends on what - * happend in this granule */ - for (chn = 0; chn < nch; chn++) { - int blocktype = NORM_TYPE; - /* disable short blocks */ - - if (uselongblock[chn]) { - /* no attack : use long blocks */ - assert(psv->blocktype_old[chn] != START_TYPE); - if (psv->blocktype_old[chn] == SHORT_TYPE) - blocktype = STOP_TYPE; - } - else { - /* attack : use short blocks */ - blocktype = SHORT_TYPE; - if (psv->blocktype_old[chn] == NORM_TYPE) { - psv->blocktype_old[chn] = START_TYPE; - } - if (psv->blocktype_old[chn] == STOP_TYPE) - psv->blocktype_old[chn] = SHORT_TYPE; - } - - blocktype_d[chn] = psv->blocktype_old[chn]; /* value returned to calling program */ - psv->blocktype_old[chn] = blocktype; /* save for next call to l3psy_anal */ - } -} - - -/*************************************************************** - * compute M/S thresholds from Johnston & Ferreira 1992 ICASSP paper - ***************************************************************/ - -static void -vbrpsy_compute_MS_thresholds(const FLOAT eb[4][CBANDS], FLOAT thr[4][CBANDS], - const FLOAT cb_mld[CBANDS], const FLOAT ath_cb[CBANDS], FLOAT athlower, - FLOAT msfix, int n) -{ - FLOAT const msfix2 = msfix * 2.f; - FLOAT rside, rmid; - int b; - for (b = 0; b < n; ++b) { - FLOAT const ebM = eb[2][b]; - FLOAT const ebS = eb[3][b]; - FLOAT const thmL = thr[0][b]; - FLOAT const thmR = thr[1][b]; - FLOAT thmM = thr[2][b]; - FLOAT thmS = thr[3][b]; - - /* use this fix if L & R masking differs by 2db or less */ - /* if db = 10*log10(x2/x1) < 2 */ - /* if (x2 < 1.58*x1) { */ - if (thmL <= 1.58f * thmR && thmR <= 1.58f * thmL) { - FLOAT const mld_m = cb_mld[b] * ebS; - FLOAT const mld_s = cb_mld[b] * ebM; - FLOAT const tmp_m = Min(thmS, mld_m); - FLOAT const tmp_s = Min(thmM, mld_s); - rmid = Max(thmM, tmp_m); - rside = Max(thmS, tmp_s); - } - else { - rmid = thmM; - rside = thmS; - } - if (msfix > 0.f) { - /***************************************************************/ - /* Adjust M/S maskings if user set "msfix" */ - /***************************************************************/ - /* Naoki Shibata 2000 */ - FLOAT thmLR, thmMS; - FLOAT const ath = ath_cb[b] * athlower; - FLOAT const tmp_l = Max(thmL, ath); - FLOAT const tmp_r = Max(thmR, ath); - thmLR = Min(tmp_l, tmp_r); - thmM = Max(rmid, ath); - thmS = Max(rside, ath); - thmMS = thmM + thmS; - if (thmMS > 0.f && (thmLR * msfix2) < thmMS) { - FLOAT const f = thmLR * msfix2 / thmMS; - thmM *= f; - thmS *= f; - assert(thmMS > 0.f); - } - rmid = Min(thmM, rmid); - rside = Min(thmS, rside); - } - if (rmid > ebM) { - rmid = ebM; - } - if (rside > ebS) { - rside = ebS; - } - thr[2][b] = rmid; - thr[3][b] = rside; - } -} - - -/* - * NOTE: the bitrate reduction from the inter-channel masking effect is low - * compared to the chance of getting annyoing artefacts. L3psycho_anal_vbr does - * not use this feature. (Robert 071216) -*/ - -int -L3psycho_anal_vbr(lame_internal_flags * gfc, - const sample_t * const buffer[2], int gr_out, - III_psy_ratio masking_ratio[2][2], - III_psy_ratio masking_MS_ratio[2][2], - FLOAT percep_entropy[2], FLOAT percep_MS_entropy[2], - FLOAT energy[4], int blocktype_d[2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_CB2SB_t const *const gdl = &gfc->cd_psy->l; - PsyConst_CB2SB_t const *const gds = &gfc->cd_psy->s; - plotting_data *plt = cfg->analysis ? gfc->pinfo : 0; - - III_psy_xmin last_thm[4]; - - /* fft and energy calculation */ - FLOAT(*wsamp_l)[BLKSIZE]; - FLOAT(*wsamp_s)[3][BLKSIZE_s]; - FLOAT fftenergy[HBLKSIZE]; - FLOAT fftenergy_s[3][HBLKSIZE_s]; - FLOAT wsamp_L[2][BLKSIZE]; - FLOAT wsamp_S[2][3][BLKSIZE_s]; - FLOAT eb[4][CBANDS], thr[4][CBANDS]; - - FLOAT sub_short_factor[4][3]; - FLOAT thmm; - FLOAT const pcfact = 0.6f; - FLOAT const ath_factor = - (cfg->msfix > 0.f) ? (cfg->ATH_offset_factor * gfc->ATH->adjust_factor) : 1.f; - - const FLOAT(*const_eb)[CBANDS] = (const FLOAT(*)[CBANDS]) eb; - const FLOAT(*const_fftenergy_s)[HBLKSIZE_s] = (const FLOAT(*)[HBLKSIZE_s]) fftenergy_s; - - /* block type */ - int ns_attacks[4][4] = { {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} }; - int uselongblock[2]; - - /* usual variables like loop indices, etc.. */ - int chn, sb, sblock; - - /* chn=2 and 3 = Mid and Side channels */ - int const n_chn_psy = (cfg->mode == JOINT_STEREO) ? 4 : cfg->channels_out; - - memcpy(&last_thm[0], &psv->thm[0], sizeof(last_thm)); - - vbrpsy_attack_detection(gfc, buffer, gr_out, masking_ratio, masking_MS_ratio, energy, - sub_short_factor, ns_attacks, uselongblock); - - vbrpsy_compute_block_type(cfg, uselongblock); - - /* LONG BLOCK CASE */ - { - for (chn = 0; chn < n_chn_psy; chn++) { - int const ch01 = chn & 0x01; - - wsamp_l = wsamp_L + ch01; - vbrpsy_compute_fft_l(gfc, buffer, chn, gr_out, fftenergy, wsamp_l); - vbrpsy_compute_loudness_approximation_l(gfc, gr_out, chn, fftenergy); - vbrpsy_compute_masking_l(gfc, fftenergy, eb[chn], thr[chn], chn); - } - if (cfg->mode == JOINT_STEREO) { - if ((uselongblock[0] + uselongblock[1]) == 2) { - vbrpsy_compute_MS_thresholds(const_eb, thr, gdl->mld_cb, gfc->ATH->cb_l, - ath_factor, cfg->msfix, gdl->npart); - } - } - /* TODO: apply adaptive ATH masking here ?? */ - for (chn = 0; chn < n_chn_psy; chn++) { - convert_partition2scalefac_l(gfc, eb[chn], thr[chn], chn); - convert_partition2scalefac_l_to_s(gfc, eb[chn], thr[chn], chn); - } - } - /* SHORT BLOCKS CASE */ - { - int const force_short_block_calc = gfc->cd_psy->force_short_block_calc; - for (sblock = 0; sblock < 3; sblock++) { - for (chn = 0; chn < n_chn_psy; ++chn) { - int const ch01 = chn & 0x01; - if (uselongblock[ch01] && !force_short_block_calc) { - vbrpsy_skip_masking_s(gfc, chn, sblock); - } - else { - /* compute masking thresholds for short blocks */ - wsamp_s = wsamp_S + ch01; - vbrpsy_compute_fft_s(gfc, buffer, chn, sblock, fftenergy_s, wsamp_s); - vbrpsy_compute_masking_s(gfc, const_fftenergy_s, eb[chn], thr[chn], chn, - sblock); - } - } - if (cfg->mode == JOINT_STEREO) { - if ((uselongblock[0] + uselongblock[1]) == 0) { - vbrpsy_compute_MS_thresholds(const_eb, thr, gds->mld_cb, gfc->ATH->cb_s, - ath_factor, cfg->msfix, gds->npart); - } - } - /* TODO: apply adaptive ATH masking here ?? */ - for (chn = 0; chn < n_chn_psy; ++chn) { - int const ch01 = chn & 0x01; - if (!uselongblock[ch01] || force_short_block_calc) { - convert_partition2scalefac_s(gfc, eb[chn], thr[chn], chn, sblock); - } - } - } - - /**** short block pre-echo control ****/ - for (chn = 0; chn < n_chn_psy; chn++) { - for (sb = 0; sb < SBMAX_s; sb++) { - FLOAT new_thmm[3], prev_thm, t1, t2; - for (sblock = 0; sblock < 3; sblock++) { - thmm = psv->thm[chn].s[sb][sblock]; - thmm *= NS_PREECHO_ATT0; - - t1 = t2 = thmm; - - if (sblock > 0) { - prev_thm = new_thmm[sblock - 1]; - } - else { - prev_thm = last_thm[chn].s[sb][2]; - } - if (ns_attacks[chn][sblock] >= 2 || ns_attacks[chn][sblock + 1] == 1) { - t1 = NS_INTERP(prev_thm, thmm, NS_PREECHO_ATT1 * pcfact); - } - thmm = Min(t1, thmm); - if (ns_attacks[chn][sblock] == 1) { - t2 = NS_INTERP(prev_thm, thmm, NS_PREECHO_ATT2 * pcfact); - } - else if ((sblock == 0 && psv->last_attacks[chn] == 3) - || (sblock > 0 && ns_attacks[chn][sblock - 1] == 3)) { /* 2nd preceeding block */ - switch (sblock) { - case 0: - prev_thm = last_thm[chn].s[sb][1]; - break; - case 1: - prev_thm = last_thm[chn].s[sb][2]; - break; - case 2: - prev_thm = new_thmm[0]; - break; - } - t2 = NS_INTERP(prev_thm, thmm, NS_PREECHO_ATT2 * pcfact); - } - - thmm = Min(t1, thmm); - thmm = Min(t2, thmm); - - /* pulse like signal detection for fatboy.wav and so on */ - thmm *= sub_short_factor[chn][sblock]; - - new_thmm[sblock] = thmm; - } - for (sblock = 0; sblock < 3; sblock++) { - psv->thm[chn].s[sb][sblock] = new_thmm[sblock]; - } - } - } - } - for (chn = 0; chn < n_chn_psy; chn++) { - psv->last_attacks[chn] = ns_attacks[chn][2]; - } - - - /*************************************************************** - * determine final block type - ***************************************************************/ - vbrpsy_apply_block_type(psv, cfg->channels_out, uselongblock, blocktype_d); - - /********************************************************************* - * compute the value of PE to return ... no delay and advance - *********************************************************************/ - for (chn = 0; chn < n_chn_psy; chn++) { - FLOAT *ppe; - int type; - III_psy_ratio const *mr; - - if (chn > 1) { - ppe = percep_MS_entropy - 2; - type = NORM_TYPE; - if (blocktype_d[0] == SHORT_TYPE || blocktype_d[1] == SHORT_TYPE) - type = SHORT_TYPE; - mr = &masking_MS_ratio[gr_out][chn - 2]; - } - else { - ppe = percep_entropy; - type = blocktype_d[chn]; - mr = &masking_ratio[gr_out][chn]; - } - if (type == SHORT_TYPE) { - ppe[chn] = pecalc_s(mr, gfc->sv_qnt.masking_lower); - } - else { - ppe[chn] = pecalc_l(mr, gfc->sv_qnt.masking_lower); - } - - if (plt) { - plt->pe[gr_out][chn] = ppe[chn]; - } - } - return 0; -} - - - - -/* - * The spreading function. Values returned in units of energy - */ -static FLOAT -s3_func(FLOAT bark) -{ - FLOAT tempx, x, tempy, temp; - tempx = bark; - if (tempx >= 0) - tempx *= 3; - else - tempx *= 1.5; - - if (tempx >= 0.5 && tempx <= 2.5) { - temp = tempx - 0.5; - x = 8.0 * (temp * temp - 2.0 * temp); - } - else - x = 0.0; - tempx += 0.474; - tempy = 15.811389 + 7.5 * tempx - 17.5 * sqrt(1.0 + tempx * tempx); - - if (tempy <= -60.0) - return 0.0; - - tempx = exp((x + tempy) * LN_TO_LOG10); - - /* Normalization. The spreading function should be normalized so that: - +inf - / - | s3 [ bark ] d(bark) = 1 - / - -inf - */ - tempx /= .6609193; - return tempx; -} - -#if 0 -static FLOAT -norm_s3_func(void) -{ - double lim_a = 0, lim_b = 0; - double x = 0, l, h; - for (x = 0; s3_func(x) > 1e-20; x -= 1); - l = x; - h = 0; - while (fabs(h - l) > 1e-12) { - x = (h + l) / 2; - if (s3_func(x) > 0) { - h = x; - } - else { - l = x; - } - } - lim_a = l; - for (x = 0; s3_func(x) > 1e-20; x += 1); - l = 0; - h = x; - while (fabs(h - l) > 1e-12) { - x = (h + l) / 2; - if (s3_func(x) > 0) { - l = x; - } - else { - h = x; - } - } - lim_b = h; - { - double sum = 0; - int const m = 1000; - int i; - for (i = 0; i <= m; ++i) { - double x = lim_a + i * (lim_b - lim_a) / m; - double y = s3_func(x); - sum += y; - } - { - double norm = (m + 1) / (sum * (lim_b - lim_a)); - /*printf( "norm = %lf\n",norm); */ - return norm; - } - } -} -#endif - -static FLOAT -stereo_demask(double f) -{ - /* setup stereo demasking thresholds */ - /* formula reverse enginerred from plot in paper */ - double arg = freq2bark(f); - arg = (Min(arg, 15.5) / 15.5); - - return pow(10.0, 1.25 * (1 - cos(PI * arg)) - 2.5); -} - -static void -init_numline(PsyConst_CB2SB_t * gd, FLOAT sfreq, int fft_size, - int mdct_size, int sbmax, int const *scalepos) -{ - FLOAT b_frq[CBANDS + 1]; - FLOAT const mdct_freq_frac = sfreq / (2.0f * mdct_size); - FLOAT const deltafreq = fft_size / (2.0f * mdct_size); - int partition[HBLKSIZE] = { 0 }; - int i, j, ni; - int sfb; - sfreq /= fft_size; - j = 0; - ni = 0; - /* compute numlines, the number of spectral lines in each partition band */ - /* each partition band should be about DELBARK wide. */ - for (i = 0; i < CBANDS; i++) { - FLOAT bark1; - int j2, nl; - bark1 = freq2bark(sfreq * j); - - b_frq[i] = sfreq * j; - - for (j2 = j; freq2bark(sfreq * j2) - bark1 < DELBARK && j2 <= fft_size / 2; j2++); - - nl = j2 - j; - gd->numlines[i] = nl; - gd->rnumlines[i] = (nl > 0) ? (1.0f / nl) : 0; - - ni = i + 1; - - while (j < j2) { - assert(j < HBLKSIZE); - partition[j++] = i; - } - if (j > fft_size / 2) { - j = fft_size / 2; - ++i; - break; - } - } - assert(i < CBANDS); - b_frq[i] = sfreq * j; - - gd->n_sb = sbmax; - gd->npart = ni; - - { - j = 0; - for (i = 0; i < gd->npart; i++) { - int const nl = gd->numlines[i]; - FLOAT const freq = sfreq * (j + nl / 2); - gd->mld_cb[i] = stereo_demask(freq); - j += nl; - } - for (; i < CBANDS; ++i) { - gd->mld_cb[i] = 1; - } - } - for (sfb = 0; sfb < sbmax; sfb++) { - int i1, i2, bo; - int start = scalepos[sfb]; - int end = scalepos[sfb + 1]; - - i1 = floor(.5 + deltafreq * (start - .5)); - if (i1 < 0) - i1 = 0; - i2 = floor(.5 + deltafreq * (end - .5)); - - if (i2 > fft_size / 2) - i2 = fft_size / 2; - - bo = partition[i2]; - gd->bm[sfb] = (partition[i1] + partition[i2]) / 2; - gd->bo[sfb] = bo; - - /* calculate how much of this band belongs to current scalefactor band */ - { - FLOAT const f_tmp = mdct_freq_frac * end; - FLOAT bo_w = (f_tmp - b_frq[bo]) / (b_frq[bo + 1] - b_frq[bo]); - if (bo_w < 0) { - bo_w = 0; - } - else { - if (bo_w > 1) { - bo_w = 1; - } - } - gd->bo_weight[sfb] = bo_w; - } - gd->mld[sfb] = stereo_demask(mdct_freq_frac * start); - } -} - -static void -compute_bark_values(PsyConst_CB2SB_t const *gd, FLOAT sfreq, int fft_size, - FLOAT * bval, FLOAT * bval_width) -{ - /* compute bark values of each critical band */ - int k, j = 0, ni = gd->npart; - sfreq /= fft_size; - for (k = 0; k < ni; k++) { - int const w = gd->numlines[k]; - FLOAT bark1, bark2; - - bark1 = freq2bark(sfreq * (j)); - bark2 = freq2bark(sfreq * (j + w - 1)); - bval[k] = .5 * (bark1 + bark2); - - bark1 = freq2bark(sfreq * (j - .5)); - bark2 = freq2bark(sfreq * (j + w - .5)); - bval_width[k] = bark2 - bark1; - j += w; - } -} - -static int -init_s3_values(FLOAT ** p, int (*s3ind)[2], int npart, - FLOAT const *bval, FLOAT const *bval_width, FLOAT const *norm) -{ - FLOAT s3[CBANDS][CBANDS]; - /* The s3 array is not linear in the bark scale. - * bval[x] should be used to get the bark value. - */ - int i, j, k; - int numberOfNoneZero = 0; - - memset(&s3[0][0], 0, sizeof(s3)); - - /* s[i][j], the value of the spreading function, - * centered at band j (masker), for band i (maskee) - * - * i.e.: sum over j to spread into signal barkval=i - * NOTE: i and j are used opposite as in the ISO docs - */ - for (i = 0; i < npart; i++) { - for (j = 0; j < npart; j++) { - FLOAT v = s3_func(bval[i] - bval[j]) * bval_width[j]; - s3[i][j] = v * norm[i]; - } - } - for (i = 0; i < npart; i++) { - for (j = 0; j < npart; j++) { - if (s3[i][j] > 0.0f) - break; - } - s3ind[i][0] = j; - - for (j = npart - 1; j > 0; j--) { - if (s3[i][j] > 0.0f) - break; - } - s3ind[i][1] = j; - numberOfNoneZero += (s3ind[i][1] - s3ind[i][0] + 1); - } - *p = lame_calloc(FLOAT, numberOfNoneZero); - if (!*p) - return -1; - - k = 0; - for (i = 0; i < npart; i++) - for (j = s3ind[i][0]; j <= s3ind[i][1]; j++) - (*p)[k++] = s3[i][j]; - - return 0; -} - -int -psymodel_init(lame_global_flags const *gfp) -{ - lame_internal_flags *const gfc = gfp->internal_flags; - SessionConfig_t *const cfg = &gfc->cfg; - PsyStateVar_t *const psv = &gfc->sv_psy; - PsyConst_t *gd; - int i, j, b, sb, k; - FLOAT bvl_a = 13, bvl_b = 24; - FLOAT snr_l_a = 0, snr_l_b = 0; - FLOAT snr_s_a = -8.25, snr_s_b = -4.5; - - FLOAT bval[CBANDS]; - FLOAT bval_width[CBANDS]; - FLOAT norm[CBANDS]; - FLOAT const sfreq = cfg->samplerate_out; - - FLOAT xav = 10, xbv = 12; - FLOAT const minval_low = (0.f - cfg->minval); - - if (gfc->cd_psy != 0) { - return 0; - } - memset(norm, 0, sizeof(norm)); - - gd = lame_calloc(PsyConst_t, 1); - gfc->cd_psy = gd; - - gd->force_short_block_calc = gfp->experimentalZ; - - psv->blocktype_old[0] = psv->blocktype_old[1] = NORM_TYPE; /* the vbr header is long blocks */ - - for (i = 0; i < 4; ++i) { - for (j = 0; j < CBANDS; ++j) { - psv->nb_l1[i][j] = 1e20; - psv->nb_l2[i][j] = 1e20; - psv->nb_s1[i][j] = psv->nb_s2[i][j] = 1.0; - } - for (sb = 0; sb < SBMAX_l; sb++) { - psv->en[i].l[sb] = 1e20; - psv->thm[i].l[sb] = 1e20; - } - for (j = 0; j < 3; ++j) { - for (sb = 0; sb < SBMAX_s; sb++) { - psv->en[i].s[sb][j] = 1e20; - psv->thm[i].s[sb][j] = 1e20; - } - psv->last_attacks[i] = 0; - } - for (j = 0; j < 9; j++) - psv->last_en_subshort[i][j] = 10.; - } - - - /* init. for loudness approx. -jd 2001 mar 27 */ - psv->loudness_sq_save[0] = psv->loudness_sq_save[1] = 0.0; - - - - /************************************************************************* - * now compute the psychoacoustic model specific constants - ************************************************************************/ - /* compute numlines, bo, bm, bval, bval_width, mld */ - init_numline(&gd->l, sfreq, BLKSIZE, 576, SBMAX_l, gfc->scalefac_band.l); - assert(gd->l.npart < CBANDS); - compute_bark_values(&gd->l, sfreq, BLKSIZE, bval, bval_width); - - /* compute the spreading function */ - for (i = 0; i < gd->l.npart; i++) { - double snr = snr_l_a; - if (bval[i] >= bvl_a) { - snr = snr_l_b * (bval[i] - bvl_a) / (bvl_b - bvl_a) - + snr_l_a * (bvl_b - bval[i]) / (bvl_b - bvl_a); - } - norm[i] = pow(10.0, snr / 10.0); - } - i = init_s3_values(&gd->l.s3, gd->l.s3ind, gd->l.npart, bval, bval_width, norm); - if (i) - return i; - - /* compute long block specific values, ATH and MINVAL */ - j = 0; - for (i = 0; i < gd->l.npart; i++) { - double x; - - /* ATH */ - x = FLOAT_MAX; - for (k = 0; k < gd->l.numlines[i]; k++, j++) { - FLOAT const freq = sfreq * j / (1000.0 * BLKSIZE); - FLOAT level; - /* freq = Min(.1,freq); *//* ATH below 100 Hz constant, not further climbing */ - level = ATHformula(cfg, freq * 1000) - 20; /* scale to FFT units; returned value is in dB */ - level = pow(10., 0.1 * level); /* convert from dB -> energy */ - level *= gd->l.numlines[i]; - if (x > level) - x = level; - } - gfc->ATH->cb_l[i] = x; - - /* MINVAL. - For low freq, the strength of the masking is limited by minval - this is an ISO MPEG1 thing, dont know if it is really needed */ - /* FIXME: it does work to reduce low-freq problems in S53-Wind-Sax - and lead-voice samples, but introduces some 3 kbps bit bloat too. - TODO: Further refinement of the shape of this hack. - */ - x = 20.0 * (bval[i] / xav - 1.0); - if (x > 6) { - x = 30; - } - if (x < minval_low) { - x = minval_low; - } - if (cfg->samplerate_out < 44000) { - x = 30; - } - x -= 8.; - gd->l.minval[i] = pow(10.0, x / 10.) * gd->l.numlines[i]; - } - - /************************************************************************ - * do the same things for short blocks - ************************************************************************/ - init_numline(&gd->s, sfreq, BLKSIZE_s, 192, SBMAX_s, gfc->scalefac_band.s); - assert(gd->s.npart < CBANDS); - compute_bark_values(&gd->s, sfreq, BLKSIZE_s, bval, bval_width); - - /* SNR formula. short block is normalized by SNR. is it still right ? */ - j = 0; - for (i = 0; i < gd->s.npart; i++) { - double x; - double snr = snr_s_a; - if (bval[i] >= bvl_a) { - snr = snr_s_b * (bval[i] - bvl_a) / (bvl_b - bvl_a) - + snr_s_a * (bvl_b - bval[i]) / (bvl_b - bvl_a); - } - norm[i] = pow(10.0, snr / 10.0); - - /* ATH */ - x = FLOAT_MAX; - for (k = 0; k < gd->s.numlines[i]; k++, j++) { - FLOAT const freq = sfreq * j / (1000.0 * BLKSIZE_s); - FLOAT level; - /* freq = Min(.1,freq); *//* ATH below 100 Hz constant, not further climbing */ - level = ATHformula(cfg, freq * 1000) - 20; /* scale to FFT units; returned value is in dB */ - level = pow(10., 0.1 * level); /* convert from dB -> energy */ - level *= gd->s.numlines[i]; - if (x > level) - x = level; - } - gfc->ATH->cb_s[i] = x; - - /* MINVAL. - For low freq, the strength of the masking is limited by minval - this is an ISO MPEG1 thing, dont know if it is really needed */ - x = 7.0 * (bval[i] / xbv - 1.0); - if (bval[i] > xbv) { - x *= 1 + log(1 + x) * 3.1; - } - if (bval[i] < xbv) { - x *= 1 + log(1 - x) * 2.3; - } - if (x > 6) { - x = 30; - } - if (x < minval_low) { - x = minval_low; - } - if (cfg->samplerate_out < 44000) { - x = 30; - } - x -= 8; - gd->s.minval[i] = pow(10.0, x / 10) * gd->s.numlines[i]; - } - - i = init_s3_values(&gd->s.s3, gd->s.s3ind, gd->s.npart, bval, bval_width, norm); - if (i) - return i; - - - init_mask_add_max_values(); - init_fft(gfc); - - /* setup temporal masking */ - gd->decay = exp(-1.0 * LOG10 / (temporalmask_sustain_sec * sfreq / 192.0)); - - { - FLOAT msfix; - msfix = NS_MSFIX; - if (cfg->use_safe_joint_stereo) - msfix = 1.0; - if (fabs(cfg->msfix) > 0.0) - msfix = cfg->msfix; - cfg->msfix = msfix; - - /* spread only from npart_l bands. Normally, we use the spreading - * function to convolve from npart_l down to npart_l bands - */ - for (b = 0; b < gd->l.npart; b++) - if (gd->l.s3ind[b][1] > gd->l.npart - 1) - gd->l.s3ind[b][1] = gd->l.npart - 1; - } - - /* prepare for ATH auto adjustment: - * we want to decrease the ATH by 12 dB per second - */ -#define frame_duration (576. * cfg->mode_gr / sfreq) - gfc->ATH->decay = pow(10., -12. / 10. * frame_duration); - gfc->ATH->adjust_factor = 0.01; /* minimum, for leading low loudness */ - gfc->ATH->adjust_limit = 1.0; /* on lead, allow adjust up to maximum */ -#undef frame_duration - - assert(gd->l.bo[SBMAX_l - 1] <= gd->l.npart); - assert(gd->s.bo[SBMAX_s - 1] <= gd->s.npart); - - if (cfg->ATHtype != -1) { - /* compute equal loudness weights (eql_w) */ - FLOAT freq; - FLOAT const freq_inc = (FLOAT) cfg->samplerate_out / (FLOAT) (BLKSIZE); - FLOAT eql_balance = 0.0; - freq = 0.0; - for (i = 0; i < BLKSIZE / 2; ++i) { - /* convert ATH dB to relative power (not dB) */ - /* to determine eql_w */ - freq += freq_inc; - gfc->ATH->eql_w[i] = 1. / pow(10, ATHformula(cfg, freq) / 10); - eql_balance += gfc->ATH->eql_w[i]; - } - eql_balance = 1.0 / eql_balance; - for (i = BLKSIZE / 2; --i >= 0;) { /* scale weights */ - gfc->ATH->eql_w[i] *= eql_balance; - } - } - { - for (b = j = 0; b < gd->s.npart; ++b) { - for (i = 0; i < gd->s.numlines[b]; ++i) { - ++j; - } - } - assert(j == 129); - for (b = j = 0; b < gd->l.npart; ++b) { - for (i = 0; i < gd->l.numlines[b]; ++i) { - ++j; - } - } - assert(j == 513); - } - /* short block attack threshold */ - { - float x = gfp->attackthre; - float y = gfp->attackthre_s; - if (x < 0) { - x = NSATTACKTHRE; - } - if (y < 0) { - y = NSATTACKTHRE_S; - } - gd->attack_threshold[0] = gd->attack_threshold[1] = gd->attack_threshold[2] = x; - gd->attack_threshold[3] = y; - } - { - float sk_s = -10.f, sk_l = -4.7f; - static float const sk[] = - { -7.4, -7.4, -7.4, -9.5, -7.4, -6.1, -5.5, -4.7, -4.7, -4.7, -4.7 }; - if (gfp->VBR_q < 4) { - sk_l = sk_s = sk[0]; - } - else { - sk_l = sk_s = sk[gfp->VBR_q] + gfp->VBR_q_frac * (sk[gfp->VBR_q] - sk[gfp->VBR_q + 1]); - } - b = 0; - for (; b < gd->s.npart; b++) { - float m = (float) (gd->s.npart - b) / gd->s.npart; - gd->s.masking_lower[b] = powf(10.f, sk_s * m * 0.1f); - } - for (; b < CBANDS; ++b) { - gd->s.masking_lower[b] = 1.f; - } - b = 0; - for (; b < gd->l.npart; b++) { - float m = (float) (gd->l.npart - b) / gd->l.npart; - gd->l.masking_lower[b] = powf(10.f, sk_l * m * 0.1f); - } - for (; b < CBANDS; ++b) { - gd->l.masking_lower[b] = 1.f; - } - } - memcpy(&gd->l_to_s, &gd->l, sizeof(gd->l_to_s)); - init_numline(&gd->l_to_s, sfreq, BLKSIZE, 192, SBMAX_s, gfc->scalefac_band.s); - return 0; -} diff --git a/lib-src/lame/libmp3lame/psymodel.h b/lib-src/lame/libmp3lame/psymodel.h deleted file mode 100644 index f46083cd8..000000000 --- a/lib-src/lame/libmp3lame/psymodel.h +++ /dev/null @@ -1,64 +0,0 @@ -/* - * psymodel.h - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_PSYMODEL_H -#define LAME_PSYMODEL_H - - -int L3psycho_anal_ns(lame_internal_flags * gfc, - const sample_t *const buffer[2], int gr, - III_psy_ratio ratio[2][2], - III_psy_ratio MS_ratio[2][2], - FLOAT pe[2], FLOAT pe_MS[2], FLOAT ener[2], int blocktype_d[2]); - -int L3psycho_anal_vbr(lame_internal_flags * gfc, - const sample_t *const buffer[2], int gr, - III_psy_ratio ratio[2][2], - III_psy_ratio MS_ratio[2][2], - FLOAT pe[2], FLOAT pe_MS[2], FLOAT ener[2], int blocktype_d[2]); - - -int psymodel_init(lame_global_flags const* gfp); - - -#define rpelev 2 -#define rpelev2 16 -#define rpelev_s 2 -#define rpelev2_s 16 - -/* size of each partition band, in barks: */ -#define DELBARK .34 - - -/* tuned for output level (sensitive to energy scale) */ -#define VO_SCALE (1./( 14752*14752 )/(BLKSIZE/2)) - -#define temporalmask_sustain_sec 0.01 - -#define NS_PREECHO_ATT0 0.8 -#define NS_PREECHO_ATT1 0.6 -#define NS_PREECHO_ATT2 0.3 - -#define NS_MSFIX 3.5 -#define NSATTACKTHRE 4.4 -#define NSATTACKTHRE_S 25 - -#endif /* LAME_PSYMODEL_H */ diff --git a/lib-src/lame/libmp3lame/quantize.c b/lib-src/lame/libmp3lame/quantize.c deleted file mode 100644 index 9ba9c16d6..000000000 --- a/lib-src/lame/libmp3lame/quantize.c +++ /dev/null @@ -1,2050 +0,0 @@ -/* - * MP3 quantization - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 1999-2003 Takehiro Tominaga - * Copyright (c) 2000-2011 Robert Hegemann - * Copyright (c) 2001-2005 Gabriel Bouvigne - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: quantize.c,v 1.219 2017/08/02 19:48:05 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "quantize_pvt.h" -#include "reservoir.h" -#include "bitstream.h" -#include "vbrquantize.h" -#include "quantize.h" -#ifdef HAVE_XMMINTRIN_H -#include "vector/lame_intrin.h" -#endif - - - - -/* convert from L/R <-> Mid/Side */ -static void -ms_convert(III_side_info_t * l3_side, int gr) -{ - int i; - for (i = 0; i < 576; ++i) { - FLOAT l, r; - l = l3_side->tt[gr][0].xr[i]; - r = l3_side->tt[gr][1].xr[i]; - l3_side->tt[gr][0].xr[i] = (l + r) * (FLOAT) (SQRT2 * 0.5); - l3_side->tt[gr][1].xr[i] = (l - r) * (FLOAT) (SQRT2 * 0.5); - } -} - -/************************************************************************ - * - * init_outer_loop() - * mt 6/99 - * - * initializes cod_info, scalefac and xrpow - * - * returns 0 if all energies in xr are zero, else 1 - * - ************************************************************************/ - -static void -init_xrpow_core_c(gr_info * const cod_info, FLOAT xrpow[576], int upper, FLOAT * sum) -{ - int i; - FLOAT tmp; - *sum = 0; - for (i = 0; i <= upper; ++i) { - tmp = fabs(cod_info->xr[i]); - *sum += tmp; - xrpow[i] = sqrt(tmp * sqrt(tmp)); - - if (xrpow[i] > cod_info->xrpow_max) - cod_info->xrpow_max = xrpow[i]; - } -} - - - - - -void -init_xrpow_core_init(lame_internal_flags * const gfc) -{ - gfc->init_xrpow_core = init_xrpow_core_c; - -#if defined(HAVE_XMMINTRIN_H) - if (gfc->CPU_features.SSE) - gfc->init_xrpow_core = init_xrpow_core_sse; -#endif -#ifndef HAVE_NASM -#ifdef MIN_ARCH_SSE - gfc->init_xrpow_core = init_xrpow_core_sse; -#endif -#endif -} - - - -static int -init_xrpow(lame_internal_flags * gfc, gr_info * const cod_info, FLOAT xrpow[576]) -{ - FLOAT sum = 0; - int i; - int const upper = cod_info->max_nonzero_coeff; - - assert(xrpow != NULL); - cod_info->xrpow_max = 0; - - /* check if there is some energy we have to quantize - * and calculate xrpow matching our fresh scalefactors - */ - assert(0 <= upper && upper <= 575); - memset(&(xrpow[upper]), 0, (576 - upper) * sizeof(xrpow[0])); - - - gfc->init_xrpow_core(cod_info, xrpow, upper, &sum); - - /* return 1 if we have something to quantize, else 0 - */ - if (sum > (FLOAT) 1E-20) { - int j = 0; - if (gfc->sv_qnt.substep_shaping & 2) - j = 1; - - for (i = 0; i < cod_info->psymax; i++) - gfc->sv_qnt.pseudohalf[i] = j; - - return 1; - } - - memset(&cod_info->l3_enc[0], 0, sizeof(int) * 576); - return 0; -} - - - - - -/* -Gabriel Bouvigne feb/apr 2003 -Analog silence detection in partitionned sfb21 -or sfb12 for short blocks - -From top to bottom of sfb, changes to 0 -coeffs which are below ath. It stops on the first -coeff higher than ath. -*/ -static void -psfb21_analogsilence(lame_internal_flags const *gfc, gr_info * const cod_info) -{ - ATH_t const *const ATH = gfc->ATH; - FLOAT *const xr = cod_info->xr; - - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type, but not SHORT blocks */ - int gsfb; - int stop = 0; - for (gsfb = PSFB21 - 1; gsfb >= 0 && !stop; gsfb--) { - int const start = gfc->scalefac_band.psfb21[gsfb]; - int const end = gfc->scalefac_band.psfb21[gsfb + 1]; - int j; - FLOAT ath21; - ath21 = athAdjust(ATH->adjust_factor, ATH->psfb21[gsfb], ATH->floor, 0); - - if (gfc->sv_qnt.longfact[21] > 1e-12f) - ath21 *= gfc->sv_qnt.longfact[21]; - - for (j = end - 1; j >= start; j--) { - if (fabs(xr[j]) < ath21) - xr[j] = 0; - else { - stop = 1; - break; - } - } - } - } - else { - /*note: short blocks coeffs are reordered */ - int block; - for (block = 0; block < 3; block++) { - - int gsfb; - int stop = 0; - for (gsfb = PSFB12 - 1; gsfb >= 0 && !stop; gsfb--) { - int const start = gfc->scalefac_band.s[12] * 3 + - (gfc->scalefac_band.s[13] - gfc->scalefac_band.s[12]) * block + - (gfc->scalefac_band.psfb12[gsfb] - gfc->scalefac_band.psfb12[0]); - int const end = - start + (gfc->scalefac_band.psfb12[gsfb + 1] - gfc->scalefac_band.psfb12[gsfb]); - int j; - FLOAT ath12; - ath12 = athAdjust(ATH->adjust_factor, ATH->psfb12[gsfb], ATH->floor, 0); - - if (gfc->sv_qnt.shortfact[12] > 1e-12f) - ath12 *= gfc->sv_qnt.shortfact[12]; - - for (j = end - 1; j >= start; j--) { - if (fabs(xr[j]) < ath12) - xr[j] = 0; - else { - stop = 1; - break; - } - } - } - } - } - -} - - - - - -static void -init_outer_loop(lame_internal_flags const *gfc, gr_info * const cod_info) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int sfb, j; - /* initialize fresh cod_info - */ - cod_info->part2_3_length = 0; - cod_info->big_values = 0; - cod_info->count1 = 0; - cod_info->global_gain = 210; - cod_info->scalefac_compress = 0; - /* mixed_block_flag, block_type was set in psymodel.c */ - cod_info->table_select[0] = 0; - cod_info->table_select[1] = 0; - cod_info->table_select[2] = 0; - cod_info->subblock_gain[0] = 0; - cod_info->subblock_gain[1] = 0; - cod_info->subblock_gain[2] = 0; - cod_info->subblock_gain[3] = 0; /* this one is always 0 */ - cod_info->region0_count = 0; - cod_info->region1_count = 0; - cod_info->preflag = 0; - cod_info->scalefac_scale = 0; - cod_info->count1table_select = 0; - cod_info->part2_length = 0; - if (cfg->samplerate_out <= 8000) { - cod_info->sfb_lmax = 17; - cod_info->sfb_smin = 9; - cod_info->psy_lmax = 17; - } - else { - cod_info->sfb_lmax = SBPSY_l; - cod_info->sfb_smin = SBPSY_s; - cod_info->psy_lmax = gfc->sv_qnt.sfb21_extra ? SBMAX_l : SBPSY_l; - } - cod_info->psymax = cod_info->psy_lmax; - cod_info->sfbmax = cod_info->sfb_lmax; - cod_info->sfbdivide = 11; - for (sfb = 0; sfb < SBMAX_l; sfb++) { - cod_info->width[sfb] - = gfc->scalefac_band.l[sfb + 1] - gfc->scalefac_band.l[sfb]; - cod_info->window[sfb] = 3; /* which is always 0. */ - } - if (cod_info->block_type == SHORT_TYPE) { - FLOAT ixwork[576]; - FLOAT *ix; - - cod_info->sfb_smin = 0; - cod_info->sfb_lmax = 0; - if (cod_info->mixed_block_flag) { - /* - * MPEG-1: sfbs 0-7 long block, 3-12 short blocks - * MPEG-2(.5): sfbs 0-5 long block, 3-12 short blocks - */ - cod_info->sfb_smin = 3; - cod_info->sfb_lmax = cfg->mode_gr * 2 + 4; - } - if (cfg->samplerate_out <= 8000) { - cod_info->psymax - = cod_info->sfb_lmax - + 3 * (9 - cod_info->sfb_smin); - cod_info->sfbmax = cod_info->sfb_lmax + 3 * (9 - cod_info->sfb_smin); - } - else { - cod_info->psymax - = cod_info->sfb_lmax - + 3 * ((gfc->sv_qnt.sfb21_extra ? SBMAX_s : SBPSY_s) - cod_info->sfb_smin); - cod_info->sfbmax = cod_info->sfb_lmax + 3 * (SBPSY_s - cod_info->sfb_smin); - } - cod_info->sfbdivide = cod_info->sfbmax - 18; - cod_info->psy_lmax = cod_info->sfb_lmax; - /* re-order the short blocks, for more efficient encoding below */ - /* By Takehiro TOMINAGA */ - /* - Within each scalefactor band, data is given for successive - time windows, beginning with window 0 and ending with window 2. - Within each window, the quantized values are then arranged in - order of increasing frequency... - */ - ix = &cod_info->xr[gfc->scalefac_band.l[cod_info->sfb_lmax]]; - memcpy(ixwork, cod_info->xr, 576 * sizeof(FLOAT)); - for (sfb = cod_info->sfb_smin; sfb < SBMAX_s; sfb++) { - int const start = gfc->scalefac_band.s[sfb]; - int const end = gfc->scalefac_band.s[sfb + 1]; - int window, l; - for (window = 0; window < 3; window++) { - for (l = start; l < end; l++) { - *ix++ = ixwork[3 * l + window]; - } - } - } - - j = cod_info->sfb_lmax; - for (sfb = cod_info->sfb_smin; sfb < SBMAX_s; sfb++) { - cod_info->width[j] = cod_info->width[j + 1] = cod_info->width[j + 2] - = gfc->scalefac_band.s[sfb + 1] - gfc->scalefac_band.s[sfb]; - cod_info->window[j] = 0; - cod_info->window[j + 1] = 1; - cod_info->window[j + 2] = 2; - j += 3; - } - } - - cod_info->count1bits = 0; - cod_info->sfb_partition_table = nr_of_sfb_block[0][0]; - cod_info->slen[0] = 0; - cod_info->slen[1] = 0; - cod_info->slen[2] = 0; - cod_info->slen[3] = 0; - - cod_info->max_nonzero_coeff = 575; - - /* fresh scalefactors are all zero - */ - memset(cod_info->scalefac, 0, sizeof(cod_info->scalefac)); - - if (cfg->vbr != vbr_mt && cfg->vbr != vbr_mtrh && cfg->vbr != vbr_abr && cfg->vbr != vbr_off) { - psfb21_analogsilence(gfc, cod_info); - } -} - - - -/************************************************************************ - * - * bin_search_StepSize() - * - * author/date?? - * - * binary step size search - * used by outer_loop to get a quantizer step size to start with - * - ************************************************************************/ - -typedef enum { - BINSEARCH_NONE, - BINSEARCH_UP, - BINSEARCH_DOWN -} binsearchDirection_t; - -static int -bin_search_StepSize(lame_internal_flags * const gfc, gr_info * const cod_info, - int desired_rate, const int ch, const FLOAT xrpow[576]) -{ - int nBits; - int CurrentStep = gfc->sv_qnt.CurrentStep[ch]; - int flag_GoneOver = 0; - int const start = gfc->sv_qnt.OldValue[ch]; - binsearchDirection_t Direction = BINSEARCH_NONE; - cod_info->global_gain = start; - desired_rate -= cod_info->part2_length; - - assert(CurrentStep); - for (;;) { - int step; - nBits = count_bits(gfc, xrpow, cod_info, 0); - - if (CurrentStep == 1 || nBits == desired_rate) - break; /* nothing to adjust anymore */ - - if (nBits > desired_rate) { - /* increase Quantize_StepSize */ - if (Direction == BINSEARCH_DOWN) - flag_GoneOver = 1; - - if (flag_GoneOver) - CurrentStep /= 2; - Direction = BINSEARCH_UP; - step = CurrentStep; - } - else { - /* decrease Quantize_StepSize */ - if (Direction == BINSEARCH_UP) - flag_GoneOver = 1; - - if (flag_GoneOver) - CurrentStep /= 2; - Direction = BINSEARCH_DOWN; - step = -CurrentStep; - } - cod_info->global_gain += step; - if (cod_info->global_gain < 0) { - cod_info->global_gain = 0; - flag_GoneOver = 1; - } - if (cod_info->global_gain > 255) { - cod_info->global_gain = 255; - flag_GoneOver = 1; - } - } - - assert(cod_info->global_gain >= 0); - assert(cod_info->global_gain < 256); - - while (nBits > desired_rate && cod_info->global_gain < 255) { - cod_info->global_gain++; - nBits = count_bits(gfc, xrpow, cod_info, 0); - } - gfc->sv_qnt.CurrentStep[ch] = (start - cod_info->global_gain >= 4) ? 4 : 2; - gfc->sv_qnt.OldValue[ch] = cod_info->global_gain; - cod_info->part2_3_length = nBits; - return nBits; -} - - - - -/************************************************************************ - * - * trancate_smallspectrums() - * - * Takehiro TOMINAGA 2002-07-21 - * - * trancate smaller nubmers into 0 as long as the noise threshold is allowed. - * - ************************************************************************/ -static int -floatcompare(const void *v1, const void *v2) -{ - const FLOAT *const a = v1, *const b = v2; - if (*a > *b) - return 1; - if (*a < *b) - return -1; - return 0; -} - -static void -trancate_smallspectrums(lame_internal_flags const *gfc, - gr_info * const gi, const FLOAT * const l3_xmin, FLOAT * const work) -{ - int sfb, j, width; - FLOAT distort[SFBMAX]; - calc_noise_result dummy; - - if ((!(gfc->sv_qnt.substep_shaping & 4) && gi->block_type == SHORT_TYPE) - || gfc->sv_qnt.substep_shaping & 0x80) - return; - (void) calc_noise(gi, l3_xmin, distort, &dummy, 0); - for (j = 0; j < 576; j++) { - FLOAT xr = 0.0; - if (gi->l3_enc[j] != 0) - xr = fabs(gi->xr[j]); - work[j] = xr; - } - - j = 0; - sfb = 8; - if (gi->block_type == SHORT_TYPE) - sfb = 6; - do { - FLOAT allowedNoise, trancateThreshold; - int nsame, start; - - width = gi->width[sfb]; - j += width; - if (distort[sfb] >= 1.0) - continue; - - qsort(&work[j - width], width, sizeof(FLOAT), floatcompare); - if (EQ(work[j - 1], 0.0)) - continue; /* all zero sfb */ - - allowedNoise = (1.0 - distort[sfb]) * l3_xmin[sfb]; - trancateThreshold = 0.0; - start = 0; - do { - FLOAT noise; - for (nsame = 1; start + nsame < width; nsame++) - if (NEQ(work[start + j - width], work[start + j + nsame - width])) - break; - - noise = work[start + j - width] * work[start + j - width] * nsame; - if (allowedNoise < noise) { - if (start != 0) - trancateThreshold = work[start + j - width - 1]; - break; - } - allowedNoise -= noise; - start += nsame; - } while (start < width); - if (EQ(trancateThreshold, 0.0)) - continue; - -/* printf("%e %e %e\n", */ -/* trancateThreshold/l3_xmin[sfb], */ -/* trancateThreshold/(l3_xmin[sfb]*start), */ -/* trancateThreshold/(l3_xmin[sfb]*(start+width)) */ -/* ); */ -/* if (trancateThreshold > 1000*l3_xmin[sfb]*start) */ -/* trancateThreshold = 1000*l3_xmin[sfb]*start; */ - - do { - if (fabs(gi->xr[j - width]) <= trancateThreshold) - gi->l3_enc[j - width] = 0; - } while (--width > 0); - } while (++sfb < gi->psymax); - - gi->part2_3_length = noquant_count_bits(gfc, gi, 0); -} - - -/************************************************************************* - * - * loop_break() - * - * author/date?? - * - * Function: Returns zero if there is a scalefac which has not been - * amplified. Otherwise it returns one. - * - *************************************************************************/ - -inline static int -loop_break(const gr_info * const cod_info) -{ - int sfb; - - for (sfb = 0; sfb < cod_info->sfbmax; sfb++) - if (cod_info->scalefac[sfb] - + cod_info->subblock_gain[cod_info->window[sfb]] == 0) - return 0; - - return 1; -} - - - - -/* mt 5/99: Function: Improved calc_noise for a single channel */ - -/************************************************************************* - * - * quant_compare() - * - * author/date?? - * - * several different codes to decide which quantization is better - * - *************************************************************************/ - -static double -penalties(double noise) -{ - return FAST_LOG10(0.368 + 0.632 * noise * noise * noise); -} - -static double -get_klemm_noise(const FLOAT * distort, const gr_info * const gi) -{ - int sfb; - double klemm_noise = 1E-37; - for (sfb = 0; sfb < gi->psymax; sfb++) - klemm_noise += penalties(distort[sfb]); - - return Max(1e-20, klemm_noise); -} - -inline static int -quant_compare(const int quant_comp, - const calc_noise_result * const best, - calc_noise_result * const calc, const gr_info * const gi, const FLOAT * distort) -{ - /* - noise is given in decibels (dB) relative to masking thesholds. - - over_noise: ??? (the previous comment is fully wrong) - tot_noise: ??? (the previous comment is fully wrong) - max_noise: max quantization noise - - */ - int better; - - switch (quant_comp) { - default: - case 9:{ - if (best->over_count > 0) { - /* there are distorted sfb */ - better = calc->over_SSD <= best->over_SSD; - if (calc->over_SSD == best->over_SSD) - better = calc->bits < best->bits; - } - else { - /* no distorted sfb */ - better = ((calc->max_noise < 0) && - ((calc->max_noise * 10 + calc->bits) <= - (best->max_noise * 10 + best->bits))); - } - break; - } - - case 0: - better = calc->over_count < best->over_count - || (calc->over_count == best->over_count && calc->over_noise < best->over_noise) - || (calc->over_count == best->over_count && - EQ(calc->over_noise, best->over_noise) && calc->tot_noise < best->tot_noise); - break; - - case 8: - calc->max_noise = get_klemm_noise(distort, gi); - /*lint --fallthrough */ - case 1: - better = calc->max_noise < best->max_noise; - break; - case 2: - better = calc->tot_noise < best->tot_noise; - break; - case 3: - better = (calc->tot_noise < best->tot_noise) - && (calc->max_noise < best->max_noise); - break; - case 4: - better = (calc->max_noise <= 0.0 && best->max_noise > 0.2) - || (calc->max_noise <= 0.0 && - best->max_noise < 0.0 && - best->max_noise > calc->max_noise - 0.2 && calc->tot_noise < best->tot_noise) - || (calc->max_noise <= 0.0 && - best->max_noise > 0.0 && - best->max_noise > calc->max_noise - 0.2 && - calc->tot_noise < best->tot_noise + best->over_noise) - || (calc->max_noise > 0.0 && - best->max_noise > -0.05 && - best->max_noise > calc->max_noise - 0.1 && - calc->tot_noise + calc->over_noise < best->tot_noise + best->over_noise) - || (calc->max_noise > 0.0 && - best->max_noise > -0.1 && - best->max_noise > calc->max_noise - 0.15 && - calc->tot_noise + calc->over_noise + calc->over_noise < - best->tot_noise + best->over_noise + best->over_noise); - break; - case 5: - better = calc->over_noise < best->over_noise - || (EQ(calc->over_noise, best->over_noise) && calc->tot_noise < best->tot_noise); - break; - case 6: - better = calc->over_noise < best->over_noise - || (EQ(calc->over_noise, best->over_noise) && - (calc->max_noise < best->max_noise - || (EQ(calc->max_noise, best->max_noise) && calc->tot_noise <= best->tot_noise) - )); - break; - case 7: - better = calc->over_count < best->over_count || calc->over_noise < best->over_noise; - break; - } - - - if (best->over_count == 0) { - /* - If no distorted bands, only use this quantization - if it is better, and if it uses less bits. - Unfortunately, part2_3_length is sometimes a poor - estimator of the final size at low bitrates. - */ - better = better && calc->bits < best->bits; - } - - - return better; -} - - - -/************************************************************************* - * - * amp_scalefac_bands() - * - * author/date?? - * - * Amplify the scalefactor bands that violate the masking threshold. - * See ISO 11172-3 Section C.1.5.4.3.5 - * - * distort[] = noise/masking - * distort[] > 1 ==> noise is not masked - * distort[] < 1 ==> noise is masked - * max_dist = maximum value of distort[] - * - * Three algorithms: - * noise_shaping_amp - * 0 Amplify all bands with distort[]>1. - * - * 1 Amplify all bands with distort[] >= max_dist^(.5); - * ( 50% in the db scale) - * - * 2 Amplify first band with distort[] >= max_dist; - * - * - * For algorithms 0 and 1, if max_dist < 1, then amplify all bands - * with distort[] >= .95*max_dist. This is to make sure we always - * amplify at least one band. - * - * - *************************************************************************/ -static void -amp_scalefac_bands(lame_internal_flags * gfc, - gr_info * const cod_info, FLOAT const *distort, FLOAT xrpow[576], int bRefine) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int j, sfb; - FLOAT ifqstep34, trigger; - int noise_shaping_amp; - - if (cod_info->scalefac_scale == 0) { - ifqstep34 = 1.29683955465100964055; /* 2**(.75*.5) */ - } - else { - ifqstep34 = 1.68179283050742922612; /* 2**(.75*1) */ - } - - /* compute maximum value of distort[] */ - trigger = 0; - for (sfb = 0; sfb < cod_info->sfbmax; sfb++) { - if (trigger < distort[sfb]) - trigger = distort[sfb]; - } - - noise_shaping_amp = cfg->noise_shaping_amp; - if (noise_shaping_amp == 3) { - if (bRefine == 1) - noise_shaping_amp = 2; - else - noise_shaping_amp = 1; - } - switch (noise_shaping_amp) { - case 2: - /* amplify exactly 1 band */ - break; - - case 1: - /* amplify bands within 50% of max (on db scale) */ - if (trigger > 1.0) - trigger = pow(trigger, .5); - else - trigger *= .95; - break; - - case 0: - default: - /* ISO algorithm. amplify all bands with distort>1 */ - if (trigger > 1.0) - trigger = 1.0; - else - trigger *= .95; - break; - } - - j = 0; - for (sfb = 0; sfb < cod_info->sfbmax; sfb++) { - int const width = cod_info->width[sfb]; - int l; - j += width; - if (distort[sfb] < trigger) - continue; - - if (gfc->sv_qnt.substep_shaping & 2) { - gfc->sv_qnt.pseudohalf[sfb] = !gfc->sv_qnt.pseudohalf[sfb]; - if (!gfc->sv_qnt.pseudohalf[sfb] && cfg->noise_shaping_amp == 2) - return; - } - cod_info->scalefac[sfb]++; - for (l = -width; l < 0; l++) { - xrpow[j + l] *= ifqstep34; - if (xrpow[j + l] > cod_info->xrpow_max) - cod_info->xrpow_max = xrpow[j + l]; - } - - if (cfg->noise_shaping_amp == 2) - return; - } -} - -/************************************************************************* - * - * inc_scalefac_scale() - * - * Takehiro Tominaga 2000-xx-xx - * - * turns on scalefac scale and adjusts scalefactors - * - *************************************************************************/ - -static void -inc_scalefac_scale(gr_info * const cod_info, FLOAT xrpow[576]) -{ - int l, j, sfb; - const FLOAT ifqstep34 = 1.29683955465100964055; - - j = 0; - for (sfb = 0; sfb < cod_info->sfbmax; sfb++) { - int const width = cod_info->width[sfb]; - int s = cod_info->scalefac[sfb]; - if (cod_info->preflag) - s += pretab[sfb]; - j += width; - if (s & 1) { - s++; - for (l = -width; l < 0; l++) { - xrpow[j + l] *= ifqstep34; - if (xrpow[j + l] > cod_info->xrpow_max) - cod_info->xrpow_max = xrpow[j + l]; - } - } - cod_info->scalefac[sfb] = s >> 1; - } - cod_info->preflag = 0; - cod_info->scalefac_scale = 1; -} - - - -/************************************************************************* - * - * inc_subblock_gain() - * - * Takehiro Tominaga 2000-xx-xx - * - * increases the subblock gain and adjusts scalefactors - * - *************************************************************************/ - -static int -inc_subblock_gain(const lame_internal_flags * const gfc, gr_info * const cod_info, FLOAT xrpow[576]) -{ - int sfb, window; - int *const scalefac = cod_info->scalefac; - - /* subbloc_gain can't do anything in the long block region */ - for (sfb = 0; sfb < cod_info->sfb_lmax; sfb++) { - if (scalefac[sfb] >= 16) - return 1; - } - - for (window = 0; window < 3; window++) { - int s1, s2, l, j; - s1 = s2 = 0; - - for (sfb = cod_info->sfb_lmax + window; sfb < cod_info->sfbdivide; sfb += 3) { - if (s1 < scalefac[sfb]) - s1 = scalefac[sfb]; - } - for (; sfb < cod_info->sfbmax; sfb += 3) { - if (s2 < scalefac[sfb]) - s2 = scalefac[sfb]; - } - - if (s1 < 16 && s2 < 8) - continue; - - if (cod_info->subblock_gain[window] >= 7) - return 1; - - /* even though there is no scalefactor for sfb12 - * subblock gain affects upper frequencies too, that's why - * we have to go up to SBMAX_s - */ - cod_info->subblock_gain[window]++; - j = gfc->scalefac_band.l[cod_info->sfb_lmax]; - for (sfb = cod_info->sfb_lmax + window; sfb < cod_info->sfbmax; sfb += 3) { - FLOAT amp; - int const width = cod_info->width[sfb]; - int s = scalefac[sfb]; - assert(s >= 0); - s = s - (4 >> cod_info->scalefac_scale); - if (s >= 0) { - scalefac[sfb] = s; - j += width * 3; - continue; - } - - scalefac[sfb] = 0; - { - int const gain = 210 + (s << (cod_info->scalefac_scale + 1)); - amp = IPOW20(gain); - } - j += width * (window + 1); - for (l = -width; l < 0; l++) { - xrpow[j + l] *= amp; - if (xrpow[j + l] > cod_info->xrpow_max) - cod_info->xrpow_max = xrpow[j + l]; - } - j += width * (3 - window - 1); - } - - { - FLOAT const amp = IPOW20(202); - j += cod_info->width[sfb] * (window + 1); - for (l = -cod_info->width[sfb]; l < 0; l++) { - xrpow[j + l] *= amp; - if (xrpow[j + l] > cod_info->xrpow_max) - cod_info->xrpow_max = xrpow[j + l]; - } - } - } - return 0; -} - - - -/******************************************************************** - * - * balance_noise() - * - * Takehiro Tominaga /date?? - * Robert Hegemann 2000-09-06: made a function of it - * - * amplifies scalefactor bands, - * - if all are already amplified returns 0 - * - if some bands are amplified too much: - * * try to increase scalefac_scale - * * if already scalefac_scale was set - * try on short blocks to increase subblock gain - * - ********************************************************************/ -inline static int -balance_noise(lame_internal_flags * gfc, - gr_info * const cod_info, FLOAT const *distort, FLOAT xrpow[576], int bRefine) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int status; - - amp_scalefac_bands(gfc, cod_info, distort, xrpow, bRefine); - - /* check to make sure we have not amplified too much - * loop_break returns 0 if there is an unamplified scalefac - * scale_bitcount returns 0 if no scalefactors are too large - */ - - status = loop_break(cod_info); - - if (status) - return 0; /* all bands amplified */ - - /* not all scalefactors have been amplified. so these - * scalefacs are possibly valid. encode them: - */ - status = scale_bitcount(gfc, cod_info); - - if (!status) - return 1; /* amplified some bands not exceeding limits */ - - /* some scalefactors are too large. - * lets try setting scalefac_scale=1 - */ - if (cfg->noise_shaping > 1) { - memset(&gfc->sv_qnt.pseudohalf[0], 0, sizeof(gfc->sv_qnt.pseudohalf)); - if (!cod_info->scalefac_scale) { - inc_scalefac_scale(cod_info, xrpow); - status = 0; - } - else { - if (cod_info->block_type == SHORT_TYPE && cfg->subblock_gain > 0) { - status = inc_subblock_gain(gfc, cod_info, xrpow) - || loop_break(cod_info); - } - } - } - - if (!status) { - status = scale_bitcount(gfc, cod_info); - } - return !status; -} - - - -/************************************************************************ - * - * outer_loop () - * - * Function: The outer iteration loop controls the masking conditions - * of all scalefactorbands. It computes the best scalefac and - * global gain. This module calls the inner iteration loop - * - * mt 5/99 completely rewritten to allow for bit reservoir control, - * mid/side channels with L/R or mid/side masking thresholds, - * and chooses best quantization instead of last quantization when - * no distortion free quantization can be found. - * - * added VBR support mt 5/99 - * - * some code shuffle rh 9/00 - ************************************************************************/ - -static int -outer_loop(lame_internal_flags * gfc, gr_info * const cod_info, const FLOAT * const l3_xmin, /* allowed distortion */ - FLOAT xrpow[576], /* coloured magnitudes of spectral */ - const int ch, const int targ_bits) -{ /* maximum allowed bits */ - SessionConfig_t const *const cfg = &gfc->cfg; - gr_info cod_info_w; - FLOAT save_xrpow[576]; - FLOAT distort[SFBMAX]; - calc_noise_result best_noise_info; - int huff_bits; - int better; - int age; - calc_noise_data prev_noise; - int best_part2_3_length = 9999999; - int bEndOfSearch = 0; - int bRefine = 0; - int best_ggain_pass1 = 0; - - (void) bin_search_StepSize(gfc, cod_info, targ_bits, ch, xrpow); - - if (!cfg->noise_shaping) - /* fast mode, no noise shaping, we are ready */ - return 100; /* default noise_info.over_count */ - - memset(&prev_noise, 0, sizeof(calc_noise_data)); - - - /* compute the distortion in this quantization */ - /* coefficients and thresholds both l/r (or both mid/side) */ - (void) calc_noise(cod_info, l3_xmin, distort, &best_noise_info, &prev_noise); - best_noise_info.bits = cod_info->part2_3_length; - - cod_info_w = *cod_info; - age = 0; - /* if (cfg->vbr == vbr_rh || cfg->vbr == vbr_mtrh) */ - memcpy(save_xrpow, xrpow, sizeof(FLOAT) * 576); - - while (!bEndOfSearch) { - /* BEGIN MAIN LOOP */ - do { - calc_noise_result noise_info; - int search_limit; - int maxggain = 255; - - /* When quantization with no distorted bands is found, - * allow up to X new unsuccesful tries in serial. This - * gives us more possibilities for different quant_compare modes. - * Much more than 3 makes not a big difference, it is only slower. - */ - - if (gfc->sv_qnt.substep_shaping & 2) { - search_limit = 20; - } - else { - search_limit = 3; - } - - - - /* Check if the last scalefactor band is distorted. - * in VBR mode we can't get rid of the distortion, so quit now - * and VBR mode will try again with more bits. - * (makes a 10% speed increase, the files I tested were - * binary identical, 2000/05/20 Robert Hegemann) - * distort[] > 1 means noise > allowed noise - */ - if (gfc->sv_qnt.sfb21_extra) { - if (distort[cod_info_w.sfbmax] > 1.0) - break; - if (cod_info_w.block_type == SHORT_TYPE - && (distort[cod_info_w.sfbmax + 1] > 1.0 - || distort[cod_info_w.sfbmax + 2] > 1.0)) - break; - } - - /* try a new scalefactor conbination on cod_info_w */ - if (balance_noise(gfc, &cod_info_w, distort, xrpow, bRefine) == 0) - break; - if (cod_info_w.scalefac_scale) - maxggain = 254; - - /* inner_loop starts with the initial quantization step computed above - * and slowly increases until the bits < huff_bits. - * Thus it is important not to start with too large of an inital - * quantization step. Too small is ok, but inner_loop will take longer - */ - huff_bits = targ_bits - cod_info_w.part2_length; - if (huff_bits <= 0) - break; - - /* increase quantizer stepsize until needed bits are below maximum - */ - while ((cod_info_w.part2_3_length - = count_bits(gfc, xrpow, &cod_info_w, &prev_noise)) > huff_bits - && cod_info_w.global_gain <= maxggain) - cod_info_w.global_gain++; - - if (cod_info_w.global_gain > maxggain) - break; - - if (best_noise_info.over_count == 0) { - - while ((cod_info_w.part2_3_length - = count_bits(gfc, xrpow, &cod_info_w, &prev_noise)) > best_part2_3_length - && cod_info_w.global_gain <= maxggain) - cod_info_w.global_gain++; - - if (cod_info_w.global_gain > maxggain) - break; - } - - /* compute the distortion in this quantization */ - (void) calc_noise(&cod_info_w, l3_xmin, distort, &noise_info, &prev_noise); - noise_info.bits = cod_info_w.part2_3_length; - - /* check if this quantization is better - * than our saved quantization */ - if (cod_info->block_type != SHORT_TYPE) /* NORM, START or STOP type */ - better = cfg->quant_comp; - else - better = cfg->quant_comp_short; - - - better = quant_compare(better, &best_noise_info, &noise_info, &cod_info_w, distort); - - - /* save data so we can restore this quantization later */ - if (better) { - best_part2_3_length = cod_info->part2_3_length; - best_noise_info = noise_info; - *cod_info = cod_info_w; - age = 0; - /* save data so we can restore this quantization later */ - /*if (cfg->vbr == vbr_rh || cfg->vbr == vbr_mtrh) */ { - /* store for later reuse */ - memcpy(save_xrpow, xrpow, sizeof(FLOAT) * 576); - } - } - else { - /* early stop? */ - if (cfg->full_outer_loop == 0) { - if (++age > search_limit && best_noise_info.over_count == 0) - break; - if ((cfg->noise_shaping_amp == 3) && bRefine && age > 30) - break; - if ((cfg->noise_shaping_amp == 3) && bRefine && - (cod_info_w.global_gain - best_ggain_pass1) > 15) - break; - } - } - } - while ((cod_info_w.global_gain + cod_info_w.scalefac_scale) < 255); - - if (cfg->noise_shaping_amp == 3) { - if (!bRefine) { - /* refine search */ - cod_info_w = *cod_info; - memcpy(xrpow, save_xrpow, sizeof(FLOAT) * 576); - age = 0; - best_ggain_pass1 = cod_info_w.global_gain; - - bRefine = 1; - } - else { - /* search already refined, stop */ - bEndOfSearch = 1; - } - - } - else { - bEndOfSearch = 1; - } - } - - assert((cod_info->global_gain + cod_info->scalefac_scale) <= 255); - /* finish up - */ - if (cfg->vbr == vbr_rh || cfg->vbr == vbr_mtrh || cfg->vbr == vbr_mt) - /* restore for reuse on next try */ - memcpy(xrpow, save_xrpow, sizeof(FLOAT) * 576); - /* do the 'substep shaping' - */ - else if (gfc->sv_qnt.substep_shaping & 1) - trancate_smallspectrums(gfc, cod_info, l3_xmin, xrpow); - - return best_noise_info.over_count; -} - - - - - -/************************************************************************ - * - * iteration_finish_one() - * - * Robert Hegemann 2000-09-06 - * - * update reservoir status after FINAL quantization/bitrate - * - ************************************************************************/ - -static void -iteration_finish_one(lame_internal_flags * gfc, int gr, int ch) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - III_side_info_t *const l3_side = &gfc->l3_side; - gr_info *const cod_info = &l3_side->tt[gr][ch]; - - /* try some better scalefac storage - */ - best_scalefac_store(gfc, gr, ch, l3_side); - - /* best huffman_divide may save some bits too - */ - if (cfg->use_best_huffman == 1) - best_huffman_divide(gfc, cod_info); - - /* update reservoir status after FINAL quantization/bitrate - */ - ResvAdjust(gfc, cod_info); -} - - - -/********************************************************************* - * - * VBR_encode_granule() - * - * 2000-09-04 Robert Hegemann - * - *********************************************************************/ - -static void -VBR_encode_granule(lame_internal_flags * gfc, gr_info * const cod_info, const FLOAT * const l3_xmin, /* allowed distortion of the scalefactor */ - FLOAT xrpow[576], /* coloured magnitudes of spectral values */ - const int ch, int min_bits, int max_bits) -{ - gr_info bst_cod_info; - FLOAT bst_xrpow[576]; - int const Max_bits = max_bits; - int real_bits = max_bits + 1; - int this_bits = (max_bits + min_bits) / 2; - int dbits, over, found = 0; - int const sfb21_extra = gfc->sv_qnt.sfb21_extra; - - assert(Max_bits <= MAX_BITS_PER_CHANNEL); - memset(bst_cod_info.l3_enc, 0, sizeof(bst_cod_info.l3_enc)); - - /* search within round about 40 bits of optimal - */ - do { - assert(this_bits >= min_bits); - assert(this_bits <= max_bits); - assert(min_bits <= max_bits); - - if (this_bits > Max_bits - 42) - gfc->sv_qnt.sfb21_extra = 0; - else - gfc->sv_qnt.sfb21_extra = sfb21_extra; - - over = outer_loop(gfc, cod_info, l3_xmin, xrpow, ch, this_bits); - - /* is quantization as good as we are looking for ? - * in this case: is no scalefactor band distorted? - */ - if (over <= 0) { - found = 1; - /* now we know it can be done with "real_bits" - * and maybe we can skip some iterations - */ - real_bits = cod_info->part2_3_length; - - /* store best quantization so far - */ - bst_cod_info = *cod_info; - memcpy(bst_xrpow, xrpow, sizeof(FLOAT) * 576); - - /* try with fewer bits - */ - max_bits = real_bits - 32; - dbits = max_bits - min_bits; - this_bits = (max_bits + min_bits) / 2; - } - else { - /* try with more bits - */ - min_bits = this_bits + 32; - dbits = max_bits - min_bits; - this_bits = (max_bits + min_bits) / 2; - - if (found) { - found = 2; - /* start again with best quantization so far - */ - *cod_info = bst_cod_info; - memcpy(xrpow, bst_xrpow, sizeof(FLOAT) * 576); - } - } - } while (dbits > 12); - - gfc->sv_qnt.sfb21_extra = sfb21_extra; - - /* found=0 => nothing found, use last one - * found=1 => we just found the best and left the loop - * found=2 => we restored a good one and have now l3_enc to restore too - */ - if (found == 2) { - memcpy(cod_info->l3_enc, bst_cod_info.l3_enc, sizeof(int) * 576); - } - assert(cod_info->part2_3_length <= Max_bits); - -} - - - -/************************************************************************ - * - * get_framebits() - * - * Robert Hegemann 2000-09-05 - * - * calculates - * * how many bits are available for analog silent granules - * * how many bits to use for the lowest allowed bitrate - * * how many bits each bitrate would provide - * - ************************************************************************/ - -static void -get_framebits(lame_internal_flags * gfc, int frameBits[15]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - int bitsPerFrame, i; - - /* always use at least this many bits per granule per channel - * unless we detect analog silence, see below - */ - eov->bitrate_index = cfg->vbr_min_bitrate_index; - bitsPerFrame = getframebits(gfc); - - /* bits for analog silence - */ - eov->bitrate_index = 1; - bitsPerFrame = getframebits(gfc); - - for (i = 1; i <= cfg->vbr_max_bitrate_index; i++) { - eov->bitrate_index = i; - frameBits[i] = ResvFrameBegin(gfc, &bitsPerFrame); - } -} - - - -/********************************************************************* - * - * VBR_prepare() - * - * 2000-09-04 Robert Hegemann - * - * * converts LR to MS coding when necessary - * * calculates allowed/adjusted quantization noise amounts - * * detects analog silent frames - * - * some remarks: - * - lower masking depending on Quality setting - * - quality control together with adjusted ATH MDCT scaling - * on lower quality setting allocate more noise from - * ATH masking, and on higher quality setting allocate - * less noise from ATH masking. - * - experiments show that going more than 2dB over GPSYCHO's - * limits ends up in very annoying artefacts - * - *********************************************************************/ - -/* RH: this one needs to be overhauled sometime */ - -static int -VBR_old_prepare(lame_internal_flags * gfc, - const FLOAT pe[2][2], FLOAT const ms_ener_ratio[2], - const III_psy_ratio ratio[2][2], - FLOAT l3_xmin[2][2][SFBMAX], - int frameBits[16], int min_bits[2][2], int max_bits[2][2], int bands[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - - FLOAT masking_lower_db, adjust = 0.0; - int gr, ch; - int analog_silence = 1; - int avg, mxb, bits = 0; - - eov->bitrate_index = cfg->vbr_max_bitrate_index; - avg = ResvFrameBegin(gfc, &avg) / cfg->mode_gr; - - get_framebits(gfc, frameBits); - - for (gr = 0; gr < cfg->mode_gr; gr++) { - mxb = on_pe(gfc, pe, max_bits[gr], avg, gr, 0); - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - ms_convert(&gfc->l3_side, gr); - reduce_side(max_bits[gr], ms_ener_ratio[gr], avg, mxb); - } - for (ch = 0; ch < cfg->channels_out; ++ch) { - gr_info *const cod_info = &gfc->l3_side.tt[gr][ch]; - - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type */ - adjust = 1.28 / (1 + exp(3.5 - pe[gr][ch] / 300.)) - 0.05; - masking_lower_db = gfc->sv_qnt.mask_adjust - adjust; - } - else { - adjust = 2.56 / (1 + exp(3.5 - pe[gr][ch] / 300.)) - 0.14; - masking_lower_db = gfc->sv_qnt.mask_adjust_short - adjust; - } - gfc->sv_qnt.masking_lower = pow(10.0, masking_lower_db * 0.1); - - init_outer_loop(gfc, cod_info); - bands[gr][ch] = calc_xmin(gfc, &ratio[gr][ch], cod_info, l3_xmin[gr][ch]); - if (bands[gr][ch]) - analog_silence = 0; - - min_bits[gr][ch] = 126; - - bits += max_bits[gr][ch]; - } - } - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - if (bits > frameBits[cfg->vbr_max_bitrate_index] && bits > 0) { - max_bits[gr][ch] *= frameBits[cfg->vbr_max_bitrate_index]; - max_bits[gr][ch] /= bits; - } - if (min_bits[gr][ch] > max_bits[gr][ch]) - min_bits[gr][ch] = max_bits[gr][ch]; - - } /* for ch */ - } /* for gr */ - - return analog_silence; -} - -static void -bitpressure_strategy(lame_internal_flags const *gfc, - FLOAT l3_xmin[2][2][SFBMAX], const int min_bits[2][2], int max_bits[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int gr, ch, sfb; - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info const *const gi = &gfc->l3_side.tt[gr][ch]; - FLOAT *pxmin = l3_xmin[gr][ch]; - for (sfb = 0; sfb < gi->psy_lmax; sfb++) - *pxmin++ *= 1. + .029 * sfb * sfb / SBMAX_l / SBMAX_l; - - if (gi->block_type == SHORT_TYPE) { - for (sfb = gi->sfb_smin; sfb < SBMAX_s; sfb++) { - *pxmin++ *= 1. + .029 * sfb * sfb / SBMAX_s / SBMAX_s; - *pxmin++ *= 1. + .029 * sfb * sfb / SBMAX_s / SBMAX_s; - *pxmin++ *= 1. + .029 * sfb * sfb / SBMAX_s / SBMAX_s; - } - } - max_bits[gr][ch] = Max(min_bits[gr][ch], 0.9 * max_bits[gr][ch]); - } - } -} - -/************************************************************************ - * - * VBR_iteration_loop() - * - * tries to find out how many bits are needed for each granule and channel - * to get an acceptable quantization. An appropriate bitrate will then be - * choosed for quantization. rh 8/99 - * - * Robert Hegemann 2000-09-06 rewrite - * - ************************************************************************/ - -void -VBR_old_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ener_ratio[2], const III_psy_ratio ratio[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - FLOAT l3_xmin[2][2][SFBMAX]; - - FLOAT xrpow[576]; - int bands[2][2]; - int frameBits[15]; - int used_bits; - int bits; - int min_bits[2][2], max_bits[2][2]; - int mean_bits; - int ch, gr, analog_silence; - III_side_info_t *const l3_side = &gfc->l3_side; - - analog_silence = VBR_old_prepare(gfc, pe, ms_ener_ratio, ratio, - l3_xmin, frameBits, min_bits, max_bits, bands); - - /*---------------------------------*/ - for (;;) { - - /* quantize granules with lowest possible number of bits - */ - - used_bits = 0; - - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - int ret; - gr_info *const cod_info = &l3_side->tt[gr][ch]; - - /* init_outer_loop sets up cod_info, scalefac and xrpow - */ - ret = init_xrpow(gfc, cod_info, xrpow); - if (ret == 0 || max_bits[gr][ch] == 0) { - /* xr contains no energy - * l3_enc, our encoding data, will be quantized to zero - */ - continue; /* with next channel */ - } - - VBR_encode_granule(gfc, cod_info, l3_xmin[gr][ch], xrpow, - ch, min_bits[gr][ch], max_bits[gr][ch]); - - /* do the 'substep shaping' - */ - if (gfc->sv_qnt.substep_shaping & 1) { - trancate_smallspectrums(gfc, &l3_side->tt[gr][ch], l3_xmin[gr][ch], xrpow); - } - - ret = cod_info->part2_3_length + cod_info->part2_length; - used_bits += ret; - } /* for ch */ - } /* for gr */ - - /* find lowest bitrate able to hold used bits - */ - if (analog_silence && !cfg->enforce_min_bitrate) - /* we detected analog silence and the user did not specify - * any hard framesize limit, so start with smallest possible frame - */ - eov->bitrate_index = 1; - else - eov->bitrate_index = cfg->vbr_min_bitrate_index; - - for (; eov->bitrate_index < cfg->vbr_max_bitrate_index; eov->bitrate_index++) { - if (used_bits <= frameBits[eov->bitrate_index]) - break; - } - bits = ResvFrameBegin(gfc, &mean_bits); - - if (used_bits <= bits) - break; - - bitpressure_strategy(gfc, l3_xmin, (const int (*)[2])min_bits, max_bits); - - } /* breaks adjusted */ - /*--------------------------------------*/ - - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - iteration_finish_one(gfc, gr, ch); - } /* for ch */ - } /* for gr */ - ResvFrameEnd(gfc, mean_bits); -} - - - -static int -VBR_new_prepare(lame_internal_flags * gfc, - const FLOAT pe[2][2], const III_psy_ratio ratio[2][2], - FLOAT l3_xmin[2][2][SFBMAX], int frameBits[16], int max_bits[2][2], - int* max_resv) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - - int gr, ch; - int analog_silence = 1; - int avg, bits = 0; - int maximum_framebits; - - if (!cfg->free_format) { - eov->bitrate_index = cfg->vbr_max_bitrate_index; - (void) ResvFrameBegin(gfc, &avg); - *max_resv = gfc->sv_enc.ResvMax; - - get_framebits(gfc, frameBits); - maximum_framebits = frameBits[cfg->vbr_max_bitrate_index]; - } - else { - eov->bitrate_index = 0; - maximum_framebits = ResvFrameBegin(gfc, &avg); - frameBits[0] = maximum_framebits; - *max_resv = gfc->sv_enc.ResvMax; - } - - for (gr = 0; gr < cfg->mode_gr; gr++) { - (void) on_pe(gfc, pe, max_bits[gr], avg, gr, 0); - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - ms_convert(&gfc->l3_side, gr); - } - for (ch = 0; ch < cfg->channels_out; ++ch) { - gr_info *const cod_info = &gfc->l3_side.tt[gr][ch]; - - gfc->sv_qnt.masking_lower = pow(10.0, gfc->sv_qnt.mask_adjust * 0.1); - - init_outer_loop(gfc, cod_info); - if (0 != calc_xmin(gfc, &ratio[gr][ch], cod_info, l3_xmin[gr][ch])) - analog_silence = 0; - - bits += max_bits[gr][ch]; - } - } - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - if (bits > maximum_framebits && bits > 0) { - max_bits[gr][ch] *= maximum_framebits; - max_bits[gr][ch] /= bits; - } - - } /* for ch */ - } /* for gr */ - if (analog_silence) { - *max_resv = 0; - } - return analog_silence; -} - - - -void -VBR_new_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ener_ratio[2], const III_psy_ratio ratio[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - FLOAT l3_xmin[2][2][SFBMAX]; - - FLOAT xrpow[2][2][576]; - int frameBits[15]; - int used_bits; - int max_bits[2][2]; - int ch, gr, analog_silence, pad; - III_side_info_t *const l3_side = &gfc->l3_side; - - const FLOAT (*const_l3_xmin)[2][SFBMAX] = (const FLOAT (*)[2][SFBMAX])l3_xmin; - const FLOAT (*const_xrpow)[2][576] = (const FLOAT (*)[2][576])xrpow; - const int (*const_max_bits)[2] = (const int (*)[2])max_bits; - - (void) ms_ener_ratio; /* not used */ - - memset(xrpow, 0, sizeof(xrpow)); - - analog_silence = VBR_new_prepare(gfc, pe, ratio, l3_xmin, frameBits, max_bits, &pad); - - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info *const cod_info = &l3_side->tt[gr][ch]; - - /* init_outer_loop sets up cod_info, scalefac and xrpow - */ - if (0 == init_xrpow(gfc, cod_info, xrpow[gr][ch])) { - max_bits[gr][ch] = 0; /* silent granule needs no bits */ - } - } /* for ch */ - } /* for gr */ - - /* quantize granules with lowest possible number of bits - */ - - used_bits = VBR_encode_frame(gfc, const_xrpow, const_l3_xmin, const_max_bits); - - if (!cfg->free_format) { - int i, j; - - /* find lowest bitrate able to hold used bits - */ - if (analog_silence && !cfg->enforce_min_bitrate) { - /* we detected analog silence and the user did not specify - * any hard framesize limit, so start with smallest possible frame - */ - i = 1; - } - else { - i = cfg->vbr_min_bitrate_index; - } - - for (; i < cfg->vbr_max_bitrate_index; i++) { - if (used_bits <= frameBits[i]) - break; - } - if (i > cfg->vbr_max_bitrate_index) { - i = cfg->vbr_max_bitrate_index; - } - if (pad > 0) { - for (j = cfg->vbr_max_bitrate_index; j > i; --j) { - int const unused = frameBits[j] - used_bits; - if (unused <= pad) - break; - } - eov->bitrate_index = j; - } - else { - eov->bitrate_index = i; - } - } - else { -#if 0 - static int mmm = 0; - int fff = getFramesize_kbps(gfc, used_bits); - int hhh = getFramesize_kbps(gfc, MAX_BITS_PER_GRANULE * cfg->mode_gr); - if (mmm < fff) - mmm = fff; - printf("demand=%3d kbps max=%3d kbps limit=%3d kbps\n", fff, mmm, hhh); -#endif - eov->bitrate_index = 0; - } - if (used_bits <= frameBits[eov->bitrate_index]) { - /* update Reservoire status */ - int mean_bits, fullframebits; - fullframebits = ResvFrameBegin(gfc, &mean_bits); - assert(used_bits <= fullframebits); - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info const *const cod_info = &l3_side->tt[gr][ch]; - ResvAdjust(gfc, cod_info); - } - } - ResvFrameEnd(gfc, mean_bits); - } - else { - /* SHOULD NOT HAPPEN INTERNAL ERROR - */ - ERRORF(gfc, "INTERNAL ERROR IN VBR NEW CODE, please send bug report\n"); - exit(-1); - } -} - - - - - -/******************************************************************** - * - * calc_target_bits() - * - * calculates target bits for ABR encoding - * - * mt 2000/05/31 - * - ********************************************************************/ - -static void -calc_target_bits(lame_internal_flags * gfc, - const FLOAT pe[2][2], - FLOAT const ms_ener_ratio[2], - int targ_bits[2][2], int *analog_silence_bits, int *max_frame_bits) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - III_side_info_t const *const l3_side = &gfc->l3_side; - FLOAT res_factor; - int gr, ch, totbits, mean_bits; - int framesize = 576 * cfg->mode_gr; - - eov->bitrate_index = cfg->vbr_max_bitrate_index; - *max_frame_bits = ResvFrameBegin(gfc, &mean_bits); - - eov->bitrate_index = 1; - mean_bits = getframebits(gfc) - cfg->sideinfo_len * 8; - *analog_silence_bits = mean_bits / (cfg->mode_gr * cfg->channels_out); - - mean_bits = cfg->vbr_avg_bitrate_kbps * framesize * 1000; - if (gfc->sv_qnt.substep_shaping & 1) - mean_bits *= 1.09; - mean_bits /= cfg->samplerate_out; - mean_bits -= cfg->sideinfo_len * 8; - mean_bits /= (cfg->mode_gr * cfg->channels_out); - - /* - res_factor is the percentage of the target bitrate that should - be used on average. the remaining bits are added to the - bitreservoir and used for difficult to encode frames. - - Since we are tracking the average bitrate, we should adjust - res_factor "on the fly", increasing it if the average bitrate - is greater than the requested bitrate, and decreasing it - otherwise. Reasonable ranges are from .9 to 1.0 - - Until we get the above suggestion working, we use the following - tuning: - compression ratio res_factor - 5.5 (256kbps) 1.0 no need for bitreservoir - 11 (128kbps) .93 7% held for reservoir - - with linear interpolation for other values. - - */ - res_factor = .93 + .07 * (11.0 - cfg->compression_ratio) / (11.0 - 5.5); - if (res_factor < .90) - res_factor = .90; - if (res_factor > 1.00) - res_factor = 1.00; - - for (gr = 0; gr < cfg->mode_gr; gr++) { - int sum = 0; - for (ch = 0; ch < cfg->channels_out; ch++) { - targ_bits[gr][ch] = res_factor * mean_bits; - - if (pe[gr][ch] > 700) { - int add_bits = (pe[gr][ch] - 700) / 1.4; - - gr_info const *const cod_info = &l3_side->tt[gr][ch]; - targ_bits[gr][ch] = res_factor * mean_bits; - - /* short blocks use a little extra, no matter what the pe */ - if (cod_info->block_type == SHORT_TYPE) { - if (add_bits < mean_bits / 2) - add_bits = mean_bits / 2; - } - /* at most increase bits by 1.5*average */ - if (add_bits > mean_bits * 3 / 2) - add_bits = mean_bits * 3 / 2; - else if (add_bits < 0) - add_bits = 0; - - targ_bits[gr][ch] += add_bits; - } - if (targ_bits[gr][ch] > MAX_BITS_PER_CHANNEL) { - targ_bits[gr][ch] = MAX_BITS_PER_CHANNEL; - } - sum += targ_bits[gr][ch]; - } /* for ch */ - if (sum > MAX_BITS_PER_GRANULE) { - for (ch = 0; ch < cfg->channels_out; ++ch) { - targ_bits[gr][ch] *= MAX_BITS_PER_GRANULE; - targ_bits[gr][ch] /= sum; - } - } - } /* for gr */ - - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) - for (gr = 0; gr < cfg->mode_gr; gr++) { - reduce_side(targ_bits[gr], ms_ener_ratio[gr], mean_bits * cfg->channels_out, - MAX_BITS_PER_GRANULE); - } - - /* sum target bits - */ - totbits = 0; - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - if (targ_bits[gr][ch] > MAX_BITS_PER_CHANNEL) - targ_bits[gr][ch] = MAX_BITS_PER_CHANNEL; - totbits += targ_bits[gr][ch]; - } - } - - /* repartion target bits if needed - */ - if (totbits > *max_frame_bits && totbits > 0) { - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - targ_bits[gr][ch] *= *max_frame_bits; - targ_bits[gr][ch] /= totbits; - } - } - } -} - - - - - - -/******************************************************************** - * - * ABR_iteration_loop() - * - * encode a frame with a disired average bitrate - * - * mt 2000/05/31 - * - ********************************************************************/ - -void -ABR_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ener_ratio[2], const III_psy_ratio ratio[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncResult_t *const eov = &gfc->ov_enc; - FLOAT l3_xmin[SFBMAX]; - FLOAT xrpow[576]; - int targ_bits[2][2]; - int mean_bits, max_frame_bits; - int ch, gr, ath_over; - int analog_silence_bits; - gr_info *cod_info; - III_side_info_t *const l3_side = &gfc->l3_side; - - mean_bits = 0; - - calc_target_bits(gfc, pe, ms_ener_ratio, targ_bits, &analog_silence_bits, &max_frame_bits); - - /* encode granules - */ - for (gr = 0; gr < cfg->mode_gr; gr++) { - - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - ms_convert(&gfc->l3_side, gr); - } - for (ch = 0; ch < cfg->channels_out; ch++) { - FLOAT adjust, masking_lower_db; - cod_info = &l3_side->tt[gr][ch]; - - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type */ - /* adjust = 1.28/(1+exp(3.5-pe[gr][ch]/300.))-0.05; */ - adjust = 0; - masking_lower_db = gfc->sv_qnt.mask_adjust - adjust; - } - else { - /* adjust = 2.56/(1+exp(3.5-pe[gr][ch]/300.))-0.14; */ - adjust = 0; - masking_lower_db = gfc->sv_qnt.mask_adjust_short - adjust; - } - gfc->sv_qnt.masking_lower = pow(10.0, masking_lower_db * 0.1); - - - /* cod_info, scalefac and xrpow get initialized in init_outer_loop - */ - init_outer_loop(gfc, cod_info); - if (init_xrpow(gfc, cod_info, xrpow)) { - /* xr contains energy we will have to encode - * calculate the masking abilities - * find some good quantization in outer_loop - */ - ath_over = calc_xmin(gfc, &ratio[gr][ch], cod_info, l3_xmin); - if (0 == ath_over) /* analog silence */ - targ_bits[gr][ch] = analog_silence_bits; - - (void) outer_loop(gfc, cod_info, l3_xmin, xrpow, ch, targ_bits[gr][ch]); - } - iteration_finish_one(gfc, gr, ch); - } /* ch */ - } /* gr */ - - /* find a bitrate which can refill the resevoir to positive size. - */ - for (eov->bitrate_index = cfg->vbr_min_bitrate_index; - eov->bitrate_index <= cfg->vbr_max_bitrate_index; eov->bitrate_index++) { - if (ResvFrameBegin(gfc, &mean_bits) >= 0) - break; - } - assert(eov->bitrate_index <= cfg->vbr_max_bitrate_index); - - ResvFrameEnd(gfc, mean_bits); -} - - - - - - -/************************************************************************ - * - * CBR_iteration_loop() - * - * author/date?? - * - * encodes one frame of MP3 data with constant bitrate - * - ************************************************************************/ - -void -CBR_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ener_ratio[2], const III_psy_ratio ratio[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - FLOAT l3_xmin[SFBMAX]; - FLOAT xrpow[576]; - int targ_bits[2]; - int mean_bits, max_bits; - int gr, ch; - III_side_info_t *const l3_side = &gfc->l3_side; - gr_info *cod_info; - - (void) ResvFrameBegin(gfc, &mean_bits); - - /* quantize! */ - for (gr = 0; gr < cfg->mode_gr; gr++) { - - /* calculate needed bits - */ - max_bits = on_pe(gfc, pe, targ_bits, mean_bits, gr, gr); - - if (gfc->ov_enc.mode_ext == MPG_MD_MS_LR) { - ms_convert(&gfc->l3_side, gr); - reduce_side(targ_bits, ms_ener_ratio[gr], mean_bits, max_bits); - } - - for (ch = 0; ch < cfg->channels_out; ch++) { - FLOAT adjust, masking_lower_db; - cod_info = &l3_side->tt[gr][ch]; - - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type */ - /* adjust = 1.28/(1+exp(3.5-pe[gr][ch]/300.))-0.05; */ - adjust = 0; - masking_lower_db = gfc->sv_qnt.mask_adjust - adjust; - } - else { - /* adjust = 2.56/(1+exp(3.5-pe[gr][ch]/300.))-0.14; */ - adjust = 0; - masking_lower_db = gfc->sv_qnt.mask_adjust_short - adjust; - } - gfc->sv_qnt.masking_lower = pow(10.0, masking_lower_db * 0.1); - - /* init_outer_loop sets up cod_info, scalefac and xrpow - */ - init_outer_loop(gfc, cod_info); - if (init_xrpow(gfc, cod_info, xrpow)) { - /* xr contains energy we will have to encode - * calculate the masking abilities - * find some good quantization in outer_loop - */ - (void) calc_xmin(gfc, &ratio[gr][ch], cod_info, l3_xmin); - (void) outer_loop(gfc, cod_info, l3_xmin, xrpow, ch, targ_bits[ch]); - } - - iteration_finish_one(gfc, gr, ch); - assert(cod_info->part2_3_length <= MAX_BITS_PER_CHANNEL); - assert(cod_info->part2_3_length <= targ_bits[ch]); - } /* for ch */ - } /* for gr */ - - ResvFrameEnd(gfc, mean_bits); -} diff --git a/lib-src/lame/libmp3lame/quantize.h b/lib-src/lame/libmp3lame/quantize.h deleted file mode 100644 index 56edcc703..000000000 --- a/lib-src/lame/libmp3lame/quantize.h +++ /dev/null @@ -1,38 +0,0 @@ -/* - * MP3 quantization - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_QUANTIZE_H -#define LAME_QUANTIZE_H - -void CBR_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ratio[2], const III_psy_ratio ratio[2][2]); - -void VBR_old_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ratio[2], const III_psy_ratio ratio[2][2]); - -void VBR_new_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ratio[2], const III_psy_ratio ratio[2][2]); - -void ABR_iteration_loop(lame_internal_flags * gfc, const FLOAT pe[2][2], - const FLOAT ms_ratio[2], const III_psy_ratio ratio[2][2]); - - -#endif /* LAME_QUANTIZE_H */ diff --git a/lib-src/lame/libmp3lame/quantize_pvt.c b/lib-src/lame/libmp3lame/quantize_pvt.c deleted file mode 100644 index d8d6447ee..000000000 --- a/lib-src/lame/libmp3lame/quantize_pvt.c +++ /dev/null @@ -1,1074 +0,0 @@ -/* - * quantize_pvt source file - * - * Copyright (c) 1999-2002 Takehiro Tominaga - * Copyright (c) 2000-2012 Robert Hegemann - * Copyright (c) 2001 Naoki Shibata - * Copyright (c) 2002-2005 Gabriel Bouvigne - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: quantize_pvt.c,v 1.175 2017/09/06 15:07:30 robert Exp $ */ -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "quantize_pvt.h" -#include "reservoir.h" -#include "lame-analysis.h" -#include - - -#define NSATHSCALE 100 /* Assuming dynamic range=96dB, this value should be 92 */ - -/* - The following table is used to implement the scalefactor - partitioning for MPEG2 as described in section - 2.4.3.2 of the IS. The indexing corresponds to the - way the tables are presented in the IS: - - [table_number][row_in_table][column of nr_of_sfb] -*/ -const int nr_of_sfb_block[6][3][4] = { - { - {6, 5, 5, 5}, - {9, 9, 9, 9}, - {6, 9, 9, 9} - }, - { - {6, 5, 7, 3}, - {9, 9, 12, 6}, - {6, 9, 12, 6} - }, - { - {11, 10, 0, 0}, - {18, 18, 0, 0}, - {15, 18, 0, 0} - }, - { - {7, 7, 7, 0}, - {12, 12, 12, 0}, - {6, 15, 12, 0} - }, - { - {6, 6, 6, 3}, - {12, 9, 9, 6}, - {6, 12, 9, 6} - }, - { - {8, 8, 5, 0}, - {15, 12, 9, 0}, - {6, 18, 9, 0} - } -}; - - -/* Table B.6: layer3 preemphasis */ -const int pretab[SBMAX_l] = { - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 1, 1, 1, 1, 2, 2, 3, 3, 3, 2, 0 -}; - -/* - Here are MPEG1 Table B.8 and MPEG2 Table B.1 - -- Layer III scalefactor bands. - Index into this using a method such as: - idx = fr_ps->header->sampling_frequency - + (fr_ps->header->version * 3) -*/ - - -const scalefac_struct sfBandIndex[9] = { - { /* Table B.2.b: 22.05 kHz */ - {0, 6, 12, 18, 24, 30, 36, 44, 54, 66, 80, 96, 116, 140, 168, 200, 238, 284, 336, 396, 464, - 522, 576}, - {0, 4, 8, 12, 18, 24, 32, 42, 56, 74, 100, 132, 174, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* Table B.2.c: 24 kHz */ /* docs: 332. mpg123(broken): 330 */ - {0, 6, 12, 18, 24, 30, 36, 44, 54, 66, 80, 96, 114, 136, 162, 194, 232, 278, 332, 394, 464, - 540, 576}, - {0, 4, 8, 12, 18, 26, 36, 48, 62, 80, 104, 136, 180, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* Table B.2.a: 16 kHz */ - {0, 6, 12, 18, 24, 30, 36, 44, 54, 66, 80, 96, 116, 140, 168, 200, 238, 284, 336, 396, 464, - 522, 576}, - {0, 4, 8, 12, 18, 26, 36, 48, 62, 80, 104, 134, 174, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* Table B.8.b: 44.1 kHz */ - {0, 4, 8, 12, 16, 20, 24, 30, 36, 44, 52, 62, 74, 90, 110, 134, 162, 196, 238, 288, 342, 418, - 576}, - {0, 4, 8, 12, 16, 22, 30, 40, 52, 66, 84, 106, 136, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* Table B.8.c: 48 kHz */ - {0, 4, 8, 12, 16, 20, 24, 30, 36, 42, 50, 60, 72, 88, 106, 128, 156, 190, 230, 276, 330, 384, - 576}, - {0, 4, 8, 12, 16, 22, 28, 38, 50, 64, 80, 100, 126, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* Table B.8.a: 32 kHz */ - {0, 4, 8, 12, 16, 20, 24, 30, 36, 44, 54, 66, 82, 102, 126, 156, 194, 240, 296, 364, 448, 550, - 576}, - {0, 4, 8, 12, 16, 22, 30, 42, 58, 78, 104, 138, 180, 192} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* MPEG-2.5 11.025 kHz */ - {0, 6, 12, 18, 24, 30, 36, 44, 54, 66, 80, 96, 116, 140, 168, 200, 238, 284, 336, 396, 464, - 522, 576}, - {0 / 3, 12 / 3, 24 / 3, 36 / 3, 54 / 3, 78 / 3, 108 / 3, 144 / 3, 186 / 3, 240 / 3, 312 / 3, - 402 / 3, 522 / 3, 576 / 3} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* MPEG-2.5 12 kHz */ - {0, 6, 12, 18, 24, 30, 36, 44, 54, 66, 80, 96, 116, 140, 168, 200, 238, 284, 336, 396, 464, - 522, 576}, - {0 / 3, 12 / 3, 24 / 3, 36 / 3, 54 / 3, 78 / 3, 108 / 3, 144 / 3, 186 / 3, 240 / 3, 312 / 3, - 402 / 3, 522 / 3, 576 / 3} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - }, - { /* MPEG-2.5 8 kHz */ - {0, 12, 24, 36, 48, 60, 72, 88, 108, 132, 160, 192, 232, 280, 336, 400, 476, 566, 568, 570, - 572, 574, 576}, - {0 / 3, 24 / 3, 48 / 3, 72 / 3, 108 / 3, 156 / 3, 216 / 3, 288 / 3, 372 / 3, 480 / 3, 486 / 3, - 492 / 3, 498 / 3, 576 / 3} - , {0, 0, 0, 0, 0, 0, 0} /* sfb21 pseudo sub bands */ - , {0, 0, 0, 0, 0, 0, 0} /* sfb12 pseudo sub bands */ - } -}; - - -/* FIXME: move global variables in some struct */ - -FLOAT pow20[Q_MAX + Q_MAX2 + 1]; -FLOAT ipow20[Q_MAX]; -FLOAT pow43[PRECALC_SIZE]; -/* initialized in first call to iteration_init */ -#ifdef TAKEHIRO_IEEE754_HACK -FLOAT adj43asm[PRECALC_SIZE]; -#else -FLOAT adj43[PRECALC_SIZE]; -#endif - -/* -compute the ATH for each scalefactor band -cd range: 0..96db - -Input: 3.3kHz signal 32767 amplitude (3.3kHz is where ATH is smallest = -5db) -longblocks: sfb=12 en0/bw=-11db max_en0 = 1.3db -shortblocks: sfb=5 -9db 0db - -Input: 1 1 1 1 1 1 1 -1 -1 -1 -1 -1 -1 -1 (repeated) -longblocks: amp=1 sfb=12 en0/bw=-103 db max_en0 = -92db - amp=32767 sfb=12 -12 db -1.4db - -Input: 1 1 1 1 1 1 1 -1 -1 -1 -1 -1 -1 -1 (repeated) -shortblocks: amp=1 sfb=5 en0/bw= -99 -86 - amp=32767 sfb=5 -9 db 4db - - -MAX energy of largest wave at 3.3kHz = 1db -AVE energy of largest wave at 3.3kHz = -11db -Let's take AVE: -11db = maximum signal in sfb=12. -Dynamic range of CD: 96db. Therefor energy of smallest audible wave -in sfb=12 = -11 - 96 = -107db = ATH at 3.3kHz. - -ATH formula for this wave: -5db. To adjust to LAME scaling, we need -ATH = ATH_formula - 103 (db) -ATH = ATH * 2.5e-10 (ener) - -*/ - -static FLOAT -ATHmdct(SessionConfig_t const *cfg, FLOAT f) -{ - FLOAT ath; - - ath = ATHformula(cfg, f); - - if (cfg->ATHfixpoint > 0) { - ath -= cfg->ATHfixpoint; - } - else { - ath -= NSATHSCALE; - } - ath += cfg->ATH_offset_db; - - /* modify the MDCT scaling for the ATH and convert to energy */ - ath = powf(10.0f, ath * 0.1f); - return ath; -} - -static void -compute_ath(lame_internal_flags const* gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - FLOAT *const ATH_l = gfc->ATH->l; - FLOAT *const ATH_psfb21 = gfc->ATH->psfb21; - FLOAT *const ATH_s = gfc->ATH->s; - FLOAT *const ATH_psfb12 = gfc->ATH->psfb12; - int sfb, i, start, end; - FLOAT ATH_f; - FLOAT const samp_freq = cfg->samplerate_out; - - for (sfb = 0; sfb < SBMAX_l; sfb++) { - start = gfc->scalefac_band.l[sfb]; - end = gfc->scalefac_band.l[sfb + 1]; - ATH_l[sfb] = FLOAT_MAX; - for (i = start; i < end; i++) { - FLOAT const freq = i * samp_freq / (2 * 576); - ATH_f = ATHmdct(cfg, freq); /* freq in kHz */ - ATH_l[sfb] = Min(ATH_l[sfb], ATH_f); - } - } - - for (sfb = 0; sfb < PSFB21; sfb++) { - start = gfc->scalefac_band.psfb21[sfb]; - end = gfc->scalefac_band.psfb21[sfb + 1]; - ATH_psfb21[sfb] = FLOAT_MAX; - for (i = start; i < end; i++) { - FLOAT const freq = i * samp_freq / (2 * 576); - ATH_f = ATHmdct(cfg, freq); /* freq in kHz */ - ATH_psfb21[sfb] = Min(ATH_psfb21[sfb], ATH_f); - } - } - - for (sfb = 0; sfb < SBMAX_s; sfb++) { - start = gfc->scalefac_band.s[sfb]; - end = gfc->scalefac_band.s[sfb + 1]; - ATH_s[sfb] = FLOAT_MAX; - for (i = start; i < end; i++) { - FLOAT const freq = i * samp_freq / (2 * 192); - ATH_f = ATHmdct(cfg, freq); /* freq in kHz */ - ATH_s[sfb] = Min(ATH_s[sfb], ATH_f); - } - ATH_s[sfb] *= (gfc->scalefac_band.s[sfb + 1] - gfc->scalefac_band.s[sfb]); - } - - for (sfb = 0; sfb < PSFB12; sfb++) { - start = gfc->scalefac_band.psfb12[sfb]; - end = gfc->scalefac_band.psfb12[sfb + 1]; - ATH_psfb12[sfb] = FLOAT_MAX; - for (i = start; i < end; i++) { - FLOAT const freq = i * samp_freq / (2 * 192); - ATH_f = ATHmdct(cfg, freq); /* freq in kHz */ - ATH_psfb12[sfb] = Min(ATH_psfb12[sfb], ATH_f); - } - /*not sure about the following */ - ATH_psfb12[sfb] *= (gfc->scalefac_band.s[13] - gfc->scalefac_band.s[12]); - } - - - /* no-ATH mode: - * reduce ATH to -200 dB - */ - - if (cfg->noATH) { - for (sfb = 0; sfb < SBMAX_l; sfb++) { - ATH_l[sfb] = 1E-20; - } - for (sfb = 0; sfb < PSFB21; sfb++) { - ATH_psfb21[sfb] = 1E-20; - } - for (sfb = 0; sfb < SBMAX_s; sfb++) { - ATH_s[sfb] = 1E-20; - } - for (sfb = 0; sfb < PSFB12; sfb++) { - ATH_psfb12[sfb] = 1E-20; - } - } - - /* work in progress, don't rely on it too much - */ - gfc->ATH->floor = 10. * log10(ATHmdct(cfg, -1.)); - - /* - { FLOAT g=10000, t=1e30, x; - for ( f = 100; f < 10000; f++ ) { - x = ATHmdct( cfg, f ); - if ( t > x ) t = x, g = f; - } - printf("min=%g\n", g); - } */ -} - - -static float const payload_long[2][4] = -{ {-0.000f, -0.000f, -0.000f, +0.000f} -, {-0.500f, -0.250f, -0.025f, +0.500f} -}; -static float const payload_short[2][4] = -{ {-0.000f, -0.000f, -0.000f, +0.000f} -, {-2.000f, -1.000f, -0.050f, +0.500f} -}; - -/************************************************************************/ -/* initialization for iteration_loop */ -/************************************************************************/ -void -iteration_init(lame_internal_flags * gfc) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - III_side_info_t *const l3_side = &gfc->l3_side; - FLOAT adjust, db; - int i, sel; - - if (gfc->iteration_init_init == 0) { - gfc->iteration_init_init = 1; - - l3_side->main_data_begin = 0; - compute_ath(gfc); - - pow43[0] = 0.0; - for (i = 1; i < PRECALC_SIZE; i++) - pow43[i] = pow((FLOAT) i, 4.0 / 3.0); - -#ifdef TAKEHIRO_IEEE754_HACK - adj43asm[0] = 0.0; - for (i = 1; i < PRECALC_SIZE; i++) - adj43asm[i] = i - 0.5 - pow(0.5 * (pow43[i - 1] + pow43[i]), 0.75); -#else - for (i = 0; i < PRECALC_SIZE - 1; i++) - adj43[i] = (i + 1) - pow(0.5 * (pow43[i] + pow43[i + 1]), 0.75); - adj43[i] = 0.5; -#endif - for (i = 0; i < Q_MAX; i++) - ipow20[i] = pow(2.0, (double) (i - 210) * -0.1875); - for (i = 0; i <= Q_MAX + Q_MAX2; i++) - pow20[i] = pow(2.0, (double) (i - 210 - Q_MAX2) * 0.25); - - huffman_init(gfc); - init_xrpow_core_init(gfc); - - sel = 1;/* RH: all modes like vbr-new (cfg->vbr == vbr_mt || cfg->vbr == vbr_mtrh) ? 1 : 0;*/ - - /* long */ - db = cfg->adjust_bass_db + payload_long[sel][0]; - adjust = powf(10.f, db * 0.1f); - for (i = 0; i <= 6; ++i) { - gfc->sv_qnt.longfact[i] = adjust; - } - db = cfg->adjust_alto_db + payload_long[sel][1]; - adjust = powf(10.f, db * 0.1f); - for (; i <= 13; ++i) { - gfc->sv_qnt.longfact[i] = adjust; - } - db = cfg->adjust_treble_db + payload_long[sel][2]; - adjust = powf(10.f, db * 0.1f); - for (; i <= 20; ++i) { - gfc->sv_qnt.longfact[i] = adjust; - } - db = cfg->adjust_sfb21_db + payload_long[sel][3]; - adjust = powf(10.f, db * 0.1f); - for (; i < SBMAX_l; ++i) { - gfc->sv_qnt.longfact[i] = adjust; - } - - /* short */ - db = cfg->adjust_bass_db + payload_short[sel][0]; - adjust = powf(10.f, db * 0.1f); - for (i = 0; i <= 2; ++i) { - gfc->sv_qnt.shortfact[i] = adjust; - } - db = cfg->adjust_alto_db + payload_short[sel][1]; - adjust = powf(10.f, db * 0.1f); - for (; i <= 6; ++i) { - gfc->sv_qnt.shortfact[i] = adjust; - } - db = cfg->adjust_treble_db + payload_short[sel][2]; - adjust = powf(10.f, db * 0.1f); - for (; i <= 11; ++i) { - gfc->sv_qnt.shortfact[i] = adjust; - } - db = cfg->adjust_sfb21_db + payload_short[sel][3]; - adjust = powf(10.f, db * 0.1f); - for (; i < SBMAX_s; ++i) { - gfc->sv_qnt.shortfact[i] = adjust; - } - } -} - - - - - -/************************************************************************ - * allocate bits among 2 channels based on PE - * mt 6/99 - * bugfixes rh 8/01: often allocated more than the allowed 4095 bits - ************************************************************************/ -int -on_pe(lame_internal_flags * gfc, const FLOAT pe[][2], int targ_bits[2], int mean_bits, int gr, int cbr) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int extra_bits = 0, tbits, bits; - int add_bits[2] = {0, 0}; - int max_bits; /* maximum allowed bits for this granule */ - int ch; - - /* allocate targ_bits for granule */ - ResvMaxBits(gfc, mean_bits, &tbits, &extra_bits, cbr); - max_bits = tbits + extra_bits; - if (max_bits > MAX_BITS_PER_GRANULE) /* hard limit per granule */ - max_bits = MAX_BITS_PER_GRANULE; - - for (bits = 0, ch = 0; ch < cfg->channels_out; ++ch) { - /****************************************************************** - * allocate bits for each channel - ******************************************************************/ - targ_bits[ch] = Min(MAX_BITS_PER_CHANNEL, tbits / cfg->channels_out); - - add_bits[ch] = targ_bits[ch] * pe[gr][ch] / 700.0 - targ_bits[ch]; - - /* at most increase bits by 1.5*average */ - if (add_bits[ch] > mean_bits * 3 / 4) - add_bits[ch] = mean_bits * 3 / 4; - if (add_bits[ch] < 0) - add_bits[ch] = 0; - - if (add_bits[ch] + targ_bits[ch] > MAX_BITS_PER_CHANNEL) - add_bits[ch] = Max(0, MAX_BITS_PER_CHANNEL - targ_bits[ch]); - - bits += add_bits[ch]; - } - if (bits > extra_bits && bits > 0) { - for (ch = 0; ch < cfg->channels_out; ++ch) { - add_bits[ch] = extra_bits * add_bits[ch] / bits; - } - } - - for (ch = 0; ch < cfg->channels_out; ++ch) { - targ_bits[ch] += add_bits[ch]; - extra_bits -= add_bits[ch]; - } - - for (bits = 0, ch = 0; ch < cfg->channels_out; ++ch) { - bits += targ_bits[ch]; - } - if (bits > MAX_BITS_PER_GRANULE) { - int sum = 0; - for (ch = 0; ch < cfg->channels_out; ++ch) { - targ_bits[ch] *= MAX_BITS_PER_GRANULE; - targ_bits[ch] /= bits; - sum += targ_bits[ch]; - } - assert(sum <= MAX_BITS_PER_GRANULE); - } - - return max_bits; -} - - - - -void -reduce_side(int targ_bits[2], FLOAT ms_ener_ratio, int mean_bits, int max_bits) -{ - int move_bits; - FLOAT fac; - - assert(max_bits <= MAX_BITS_PER_GRANULE); - assert(targ_bits[0] + targ_bits[1] <= MAX_BITS_PER_GRANULE); - - /* ms_ener_ratio = 0: allocate 66/33 mid/side fac=.33 - * ms_ener_ratio =.5: allocate 50/50 mid/side fac= 0 */ - /* 75/25 split is fac=.5 */ - /* float fac = .50*(.5-ms_ener_ratio[gr])/.5; */ - fac = .33 * (.5 - ms_ener_ratio) / .5; - if (fac < 0) - fac = 0; - if (fac > .5) - fac = .5; - - /* number of bits to move from side channel to mid channel */ - /* move_bits = fac*targ_bits[1]; */ - move_bits = fac * .5 * (targ_bits[0] + targ_bits[1]); - - if (move_bits > MAX_BITS_PER_CHANNEL - targ_bits[0]) { - move_bits = MAX_BITS_PER_CHANNEL - targ_bits[0]; - } - if (move_bits < 0) - move_bits = 0; - - if (targ_bits[1] >= 125) { - /* dont reduce side channel below 125 bits */ - if (targ_bits[1] - move_bits > 125) { - - /* if mid channel already has 2x more than average, dont bother */ - /* mean_bits = bits per granule (for both channels) */ - if (targ_bits[0] < mean_bits) - targ_bits[0] += move_bits; - targ_bits[1] -= move_bits; - } - else { - targ_bits[0] += targ_bits[1] - 125; - targ_bits[1] = 125; - } - } - - move_bits = targ_bits[0] + targ_bits[1]; - if (move_bits > max_bits) { - targ_bits[0] = (max_bits * targ_bits[0]) / move_bits; - targ_bits[1] = (max_bits * targ_bits[1]) / move_bits; - } - assert(targ_bits[0] <= MAX_BITS_PER_CHANNEL); - assert(targ_bits[1] <= MAX_BITS_PER_CHANNEL); - assert(targ_bits[0] + targ_bits[1] <= MAX_BITS_PER_GRANULE); -} - - -/** - * Robert Hegemann 2001-04-27: - * this adjusts the ATH, keeping the original noise floor - * affects the higher frequencies more than the lower ones - */ - -FLOAT -athAdjust(FLOAT a, FLOAT x, FLOAT athFloor, float ATHfixpoint) -{ - /* work in progress - */ - FLOAT const o = 90.30873362f; - FLOAT const p = (ATHfixpoint < 1.f) ? 94.82444863f : ATHfixpoint; - FLOAT u = FAST_LOG10_X(x, 10.0f); - FLOAT const v = a * a; - FLOAT w = 0.0f; - u -= athFloor; /* undo scaling */ - if (v > 1E-20f) - w = 1.f + FAST_LOG10_X(v, 10.0f / o); - if (w < 0) - w = 0.f; - u *= w; - u += athFloor + o - p; /* redo scaling */ - - return powf(10.f, 0.1f * u); -} - - - -/*************************************************************************/ -/* calc_xmin */ -/*************************************************************************/ - -/* - Calculate the allowed distortion for each scalefactor band, - as determined by the psychoacoustic model. - xmin(sb) = ratio(sb) * en(sb) / bw(sb) - - returns number of sfb's with energy > ATH -*/ - -int -calc_xmin(lame_internal_flags const *gfc, - III_psy_ratio const *const ratio, gr_info * const cod_info, FLOAT * pxmin) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int sfb, gsfb, j = 0, ath_over = 0, k; - ATH_t const *const ATH = gfc->ATH; - const FLOAT *const xr = cod_info->xr; - int max_nonzero; - - for (gsfb = 0; gsfb < cod_info->psy_lmax; gsfb++) { - FLOAT en0, xmin; - FLOAT rh1, rh2, rh3; - int width, l; - - xmin = athAdjust(ATH->adjust_factor, ATH->l[gsfb], ATH->floor, cfg->ATHfixpoint); - xmin *= gfc->sv_qnt.longfact[gsfb]; - - width = cod_info->width[gsfb]; - rh1 = xmin / width; -#ifdef DBL_EPSILON - rh2 = DBL_EPSILON; -#else - rh2 = 2.2204460492503131e-016; -#endif - en0 = 0.0; - for (l = 0; l < width; ++l) { - FLOAT const xa = xr[j++]; - FLOAT const x2 = xa * xa; - en0 += x2; - rh2 += (x2 < rh1) ? x2 : rh1; - } - if (en0 > xmin) - ath_over++; - - if (en0 < xmin) { - rh3 = en0; - } - else if (rh2 < xmin) { - rh3 = xmin; - } - else { - rh3 = rh2; - } - xmin = rh3; - { - FLOAT const e = ratio->en.l[gsfb]; - if (e > 1e-12f) { - FLOAT x; - x = en0 * ratio->thm.l[gsfb] / e; - x *= gfc->sv_qnt.longfact[gsfb]; - if (xmin < x) - xmin = x; - } - } - xmin = Max(xmin, DBL_EPSILON); - cod_info->energy_above_cutoff[gsfb] = (en0 > xmin+1e-14f) ? 1 : 0; - *pxmin++ = xmin; - } /* end of long block loop */ - - - - - /*use this function to determine the highest non-zero coeff */ - max_nonzero = 0; - for (k = 575; k > 0; --k) { - if (fabs(xr[k]) > 1e-12f) { - max_nonzero = k; - break; - } - } - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type, but not SHORT */ - max_nonzero |= 1; /* only odd numbers */ - } - else { - max_nonzero /= 6; /* 3 short blocks */ - max_nonzero *= 6; - max_nonzero += 5; - } - - if (gfc->sv_qnt.sfb21_extra == 0 && cfg->samplerate_out < 44000) { - int const sfb_l = (cfg->samplerate_out <= 8000) ? 17 : 21; - int const sfb_s = (cfg->samplerate_out <= 8000) ? 9 : 12; - int limit = 575; - if (cod_info->block_type != SHORT_TYPE) { /* NORM, START or STOP type, but not SHORT */ - limit = gfc->scalefac_band.l[sfb_l]-1; - } - else { - limit = 3*gfc->scalefac_band.s[sfb_s]-1; - } - if (max_nonzero > limit) { - max_nonzero = limit; - } - } - cod_info->max_nonzero_coeff = max_nonzero; - - - - for (sfb = cod_info->sfb_smin; gsfb < cod_info->psymax; sfb++, gsfb += 3) { - int width, b, l; - FLOAT tmpATH; - - tmpATH = athAdjust(ATH->adjust_factor, ATH->s[sfb], ATH->floor, cfg->ATHfixpoint); - tmpATH *= gfc->sv_qnt.shortfact[sfb]; - - width = cod_info->width[gsfb]; - for (b = 0; b < 3; b++) { - FLOAT en0 = 0.0, xmin = tmpATH; - FLOAT rh1, rh2, rh3; - - rh1 = tmpATH / width; -#ifdef DBL_EPSILON - rh2 = DBL_EPSILON; -#else - rh2 = 2.2204460492503131e-016; -#endif - for (l = 0; l < width; ++l) { - FLOAT const xa = xr[j++]; - FLOAT const x2 = xa * xa; - en0 += x2; - rh2 += (x2 < rh1) ? x2 : rh1; - } - if (en0 > tmpATH) - ath_over++; - - if (en0 < tmpATH) { - rh3 = en0; - } - else if (rh2 < tmpATH) { - rh3 = tmpATH; - } - else { - rh3 = rh2; - } - xmin = rh3; - { - FLOAT const e = ratio->en.s[sfb][b]; - if (e > 1e-12f) { - FLOAT x; - x = en0 * ratio->thm.s[sfb][b] / e; - x *= gfc->sv_qnt.shortfact[sfb]; - if (xmin < x) - xmin = x; - } - } - xmin = Max(xmin, DBL_EPSILON); - cod_info->energy_above_cutoff[gsfb+b] = (en0 > xmin+1e-14f) ? 1 : 0; - *pxmin++ = xmin; - } /* b */ - if (cfg->use_temporal_masking_effect) { - if (pxmin[-3] > pxmin[-3 + 1]) - pxmin[-3 + 1] += (pxmin[-3] - pxmin[-3 + 1]) * gfc->cd_psy->decay; - if (pxmin[-3 + 1] > pxmin[-3 + 2]) - pxmin[-3 + 2] += (pxmin[-3 + 1] - pxmin[-3 + 2]) * gfc->cd_psy->decay; - } - } /* end of short block sfb loop */ - - return ath_over; -} - - -static FLOAT -calc_noise_core_c(const gr_info * const cod_info, int *startline, int l, FLOAT step) -{ - FLOAT noise = 0; - int j = *startline; - const int *const ix = cod_info->l3_enc; - - if (j > cod_info->count1) { - while (l--) { - FLOAT temp; - temp = cod_info->xr[j]; - j++; - noise += temp * temp; - temp = cod_info->xr[j]; - j++; - noise += temp * temp; - } - } - else if (j > cod_info->big_values) { - FLOAT ix01[2]; - ix01[0] = 0; - ix01[1] = step; - while (l--) { - FLOAT temp; - temp = fabs(cod_info->xr[j]) - ix01[ix[j]]; - j++; - noise += temp * temp; - temp = fabs(cod_info->xr[j]) - ix01[ix[j]]; - j++; - noise += temp * temp; - } - } - else { - while (l--) { - FLOAT temp; - temp = fabs(cod_info->xr[j]) - pow43[ix[j]] * step; - j++; - noise += temp * temp; - temp = fabs(cod_info->xr[j]) - pow43[ix[j]] * step; - j++; - noise += temp * temp; - } - } - - *startline = j; - return noise; -} - - -/*************************************************************************/ -/* calc_noise */ -/*************************************************************************/ - -/* -oo dB => -1.00 */ -/* - 6 dB => -0.97 */ -/* - 3 dB => -0.80 */ -/* - 2 dB => -0.64 */ -/* - 1 dB => -0.38 */ -/* 0 dB => 0.00 */ -/* + 1 dB => +0.49 */ -/* + 2 dB => +1.06 */ -/* + 3 dB => +1.68 */ -/* + 6 dB => +3.69 */ -/* +10 dB => +6.45 */ - -int -calc_noise(gr_info const *const cod_info, - FLOAT const *l3_xmin, - FLOAT * distort, calc_noise_result * const res, calc_noise_data * prev_noise) -{ - int sfb, l, over = 0; - FLOAT over_noise_db = 0; - FLOAT tot_noise_db = 0; /* 0 dB relative to masking */ - FLOAT max_noise = -20.0; /* -200 dB relative to masking */ - int j = 0; - const int *scalefac = cod_info->scalefac; - - res->over_SSD = 0; - - - for (sfb = 0; sfb < cod_info->psymax; sfb++) { - int const s = - cod_info->global_gain - (((*scalefac++) + (cod_info->preflag ? pretab[sfb] : 0)) - << (cod_info->scalefac_scale + 1)) - - cod_info->subblock_gain[cod_info->window[sfb]] * 8; - FLOAT const r_l3_xmin = 1.f / *l3_xmin++; - FLOAT distort_ = 0.0f; - FLOAT noise = 0.0f; - - if (prev_noise && (prev_noise->step[sfb] == s)) { - - /* use previously computed values */ - j += cod_info->width[sfb]; - distort_ = r_l3_xmin * prev_noise->noise[sfb]; - - noise = prev_noise->noise_log[sfb]; - - } - else { - FLOAT const step = POW20(s); - l = cod_info->width[sfb] >> 1; - - if ((j + cod_info->width[sfb]) > cod_info->max_nonzero_coeff) { - int usefullsize; - usefullsize = cod_info->max_nonzero_coeff - j + 1; - - if (usefullsize > 0) - l = usefullsize >> 1; - else - l = 0; - } - - noise = calc_noise_core_c(cod_info, &j, l, step); - - - if (prev_noise) { - /* save noise values */ - prev_noise->step[sfb] = s; - prev_noise->noise[sfb] = noise; - } - - distort_ = r_l3_xmin * noise; - - /* multiplying here is adding in dB, but can overflow */ - noise = FAST_LOG10(Max(distort_, 1E-20f)); - - if (prev_noise) { - /* save noise values */ - prev_noise->noise_log[sfb] = noise; - } - } - *distort++ = distort_; - - if (prev_noise) { - /* save noise values */ - prev_noise->global_gain = cod_info->global_gain;; - } - - - /*tot_noise *= Max(noise, 1E-20); */ - tot_noise_db += noise; - - if (noise > 0.0) { - int tmp; - - tmp = Max((int) (noise * 10 + .5), 1); - res->over_SSD += tmp * tmp; - - over++; - /* multiplying here is adding in dB -but can overflow */ - /*over_noise *= noise; */ - over_noise_db += noise; - } - max_noise = Max(max_noise, noise); - - } - - res->over_count = over; - res->tot_noise = tot_noise_db; - res->over_noise = over_noise_db; - res->max_noise = max_noise; - - return over; -} - - - - - - - - -/************************************************************************ - * - * set_pinfo() - * - * updates plotting data - * - * Mark Taylor 2000-??-?? - * - * Robert Hegemann: moved noise/distortion calc into it - * - ************************************************************************/ - -static void -set_pinfo(lame_internal_flags const *gfc, - gr_info * const cod_info, const III_psy_ratio * const ratio, const int gr, const int ch) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int sfb, sfb2; - int j, i, l, start, end, bw; - FLOAT en0, en1; - FLOAT const ifqstep = (cod_info->scalefac_scale == 0) ? .5 : 1.0; - int const *const scalefac = cod_info->scalefac; - - FLOAT l3_xmin[SFBMAX], xfsf[SFBMAX]; - calc_noise_result noise; - - (void) calc_xmin(gfc, ratio, cod_info, l3_xmin); - (void) calc_noise(cod_info, l3_xmin, xfsf, &noise, 0); - - j = 0; - sfb2 = cod_info->sfb_lmax; - if (cod_info->block_type != SHORT_TYPE && !cod_info->mixed_block_flag) - sfb2 = 22; - for (sfb = 0; sfb < sfb2; sfb++) { - start = gfc->scalefac_band.l[sfb]; - end = gfc->scalefac_band.l[sfb + 1]; - bw = end - start; - for (en0 = 0.0; j < end; j++) - en0 += cod_info->xr[j] * cod_info->xr[j]; - en0 /= bw; - /* convert to MDCT units */ - en1 = 1e15; /* scaling so it shows up on FFT plot */ - gfc->pinfo->en[gr][ch][sfb] = en1 * en0; - gfc->pinfo->xfsf[gr][ch][sfb] = en1 * l3_xmin[sfb] * xfsf[sfb] / bw; - - if (ratio->en.l[sfb] > 0 && !cfg->ATHonly) - en0 = en0 / ratio->en.l[sfb]; - else - en0 = 0.0; - - gfc->pinfo->thr[gr][ch][sfb] = en1 * Max(en0 * ratio->thm.l[sfb], gfc->ATH->l[sfb]); - - /* there is no scalefactor bands >= SBPSY_l */ - gfc->pinfo->LAMEsfb[gr][ch][sfb] = 0; - if (cod_info->preflag && sfb >= 11) - gfc->pinfo->LAMEsfb[gr][ch][sfb] = -ifqstep * pretab[sfb]; - - if (sfb < SBPSY_l) { - assert(scalefac[sfb] >= 0); /* scfsi should be decoded by caller side */ - gfc->pinfo->LAMEsfb[gr][ch][sfb] -= ifqstep * scalefac[sfb]; - } - } /* for sfb */ - - if (cod_info->block_type == SHORT_TYPE) { - sfb2 = sfb; - for (sfb = cod_info->sfb_smin; sfb < SBMAX_s; sfb++) { - start = gfc->scalefac_band.s[sfb]; - end = gfc->scalefac_band.s[sfb + 1]; - bw = end - start; - for (i = 0; i < 3; i++) { - for (en0 = 0.0, l = start; l < end; l++) { - en0 += cod_info->xr[j] * cod_info->xr[j]; - j++; - } - en0 = Max(en0 / bw, 1e-20); - /* convert to MDCT units */ - en1 = 1e15; /* scaling so it shows up on FFT plot */ - - gfc->pinfo->en_s[gr][ch][3 * sfb + i] = en1 * en0; - gfc->pinfo->xfsf_s[gr][ch][3 * sfb + i] = en1 * l3_xmin[sfb2] * xfsf[sfb2] / bw; - if (ratio->en.s[sfb][i] > 0) - en0 = en0 / ratio->en.s[sfb][i]; - else - en0 = 0.0; - if (cfg->ATHonly || cfg->ATHshort) - en0 = 0; - - gfc->pinfo->thr_s[gr][ch][3 * sfb + i] = - en1 * Max(en0 * ratio->thm.s[sfb][i], gfc->ATH->s[sfb]); - - /* there is no scalefactor bands >= SBPSY_s */ - gfc->pinfo->LAMEsfb_s[gr][ch][3 * sfb + i] - = -2.0 * cod_info->subblock_gain[i]; - if (sfb < SBPSY_s) { - gfc->pinfo->LAMEsfb_s[gr][ch][3 * sfb + i] -= ifqstep * scalefac[sfb2]; - } - sfb2++; - } - } - } /* block type short */ - gfc->pinfo->LAMEqss[gr][ch] = cod_info->global_gain; - gfc->pinfo->LAMEmainbits[gr][ch] = cod_info->part2_3_length + cod_info->part2_length; - gfc->pinfo->LAMEsfbits[gr][ch] = cod_info->part2_length; - - gfc->pinfo->over[gr][ch] = noise.over_count; - gfc->pinfo->max_noise[gr][ch] = noise.max_noise * 10.0; - gfc->pinfo->over_noise[gr][ch] = noise.over_noise * 10.0; - gfc->pinfo->tot_noise[gr][ch] = noise.tot_noise * 10.0; - gfc->pinfo->over_SSD[gr][ch] = noise.over_SSD; -} - - -/************************************************************************ - * - * set_frame_pinfo() - * - * updates plotting data for a whole frame - * - * Robert Hegemann 2000-10-21 - * - ************************************************************************/ - -void -set_frame_pinfo(lame_internal_flags * gfc, const III_psy_ratio ratio[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int ch; - int gr; - - /* for every granule and channel patch l3_enc and set info - */ - for (gr = 0; gr < cfg->mode_gr; gr++) { - for (ch = 0; ch < cfg->channels_out; ch++) { - gr_info *const cod_info = &gfc->l3_side.tt[gr][ch]; - int scalefac_sav[SFBMAX]; - memcpy(scalefac_sav, cod_info->scalefac, sizeof(scalefac_sav)); - - /* reconstruct the scalefactors in case SCFSI was used - */ - if (gr == 1) { - int sfb; - for (sfb = 0; sfb < cod_info->sfb_lmax; sfb++) { - if (cod_info->scalefac[sfb] < 0) /* scfsi */ - cod_info->scalefac[sfb] = gfc->l3_side.tt[0][ch].scalefac[sfb]; - } - } - - set_pinfo(gfc, cod_info, &ratio[gr][ch], gr, ch); - memcpy(cod_info->scalefac, scalefac_sav, sizeof(scalefac_sav)); - } /* for ch */ - } /* for gr */ -} diff --git a/lib-src/lame/libmp3lame/quantize_pvt.h b/lib-src/lame/libmp3lame/quantize_pvt.h deleted file mode 100644 index b8333e7e9..000000000 --- a/lib-src/lame/libmp3lame/quantize_pvt.h +++ /dev/null @@ -1,128 +0,0 @@ -/* - * quantize_pvt include file - * - * Copyright (c) 1999 Takehiro TOMINAGA - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_QUANTIZE_PVT_H -#define LAME_QUANTIZE_PVT_H - -#define IXMAX_VAL 8206 /* ix always <= 8191+15. see count_bits() */ - -/* buggy Winamp decoder cannot handle values > 8191 */ -/* #define IXMAX_VAL 8191 */ - -#define PRECALC_SIZE (IXMAX_VAL+2) - - -extern const int nr_of_sfb_block[6][3][4]; -extern const int pretab[SBMAX_l]; -extern const int slen1_tab[16]; -extern const int slen2_tab[16]; - -extern const scalefac_struct sfBandIndex[9]; - -extern FLOAT pow43[PRECALC_SIZE]; -#ifdef TAKEHIRO_IEEE754_HACK -extern FLOAT adj43asm[PRECALC_SIZE]; -#else -extern FLOAT adj43[PRECALC_SIZE]; -#endif - -#define Q_MAX (256+1) -#define Q_MAX2 116 /* minimum possible number of - -cod_info->global_gain - + ((scalefac[] + (cod_info->preflag ? pretab[sfb] : 0)) - << (cod_info->scalefac_scale + 1)) - + cod_info->subblock_gain[cod_info->window[sfb]] * 8; - - for long block, 0+((15+3)<<2) = 18*4 = 72 - for short block, 0+(15<<2)+7*8 = 15*4+56 = 116 - */ - -extern FLOAT pow20[Q_MAX + Q_MAX2 + 1]; -extern FLOAT ipow20[Q_MAX]; - -typedef struct calc_noise_result_t { - FLOAT over_noise; /* sum of quantization noise > masking */ - FLOAT tot_noise; /* sum of all quantization noise */ - FLOAT max_noise; /* max quantization noise */ - int over_count; /* number of quantization noise > masking */ - int over_SSD; /* SSD-like cost of distorted bands */ - int bits; -} calc_noise_result; - - -/** -* allows re-use of previously -* computed noise values -*/ -typedef struct calc_noise_data_t { - int global_gain; - int sfb_count1; - int step[39]; - FLOAT noise[39]; - FLOAT noise_log[39]; -} calc_noise_data; - - -int on_pe(lame_internal_flags * gfc, const FLOAT pe[2][2], - int targ_bits[2], int mean_bits, int gr, int cbr); - -void reduce_side(int targ_bits[2], FLOAT ms_ener_ratio, int mean_bits, int max_bits); - - -void iteration_init(lame_internal_flags * gfc); - - -int calc_xmin(lame_internal_flags const *gfc, - III_psy_ratio const *const ratio, gr_info * const cod_info, FLOAT * l3_xmin); - -int calc_noise(const gr_info * const cod_info, - const FLOAT * l3_xmin, - FLOAT * distort, calc_noise_result * const res, calc_noise_data * prev_noise); - -void set_frame_pinfo(lame_internal_flags * gfc, const III_psy_ratio ratio[2][2]); - - - - -/* takehiro.c */ - -int count_bits(lame_internal_flags const *const gfc, const FLOAT * const xr, - gr_info * const cod_info, calc_noise_data * prev_noise); -int noquant_count_bits(lame_internal_flags const *const gfc, - gr_info * const cod_info, calc_noise_data * prev_noise); - - -void best_huffman_divide(const lame_internal_flags * const gfc, gr_info * const cod_info); - -void best_scalefac_store(const lame_internal_flags * gfc, const int gr, const int ch, - III_side_info_t * const l3_side); - -int scale_bitcount(const lame_internal_flags * gfc, gr_info * cod_info); - -void huffman_init(lame_internal_flags * const gfc); - -void init_xrpow_core_init(lame_internal_flags * const gfc); - -FLOAT athAdjust(FLOAT a, FLOAT x, FLOAT athFloor, float ATHfixpoint); - -#define LARGE_BITS 100000 - -#endif /* LAME_QUANTIZE_PVT_H */ diff --git a/lib-src/lame/libmp3lame/reservoir.c b/lib-src/lame/libmp3lame/reservoir.c deleted file mode 100644 index 4fdaa8d33..000000000 --- a/lib-src/lame/libmp3lame/reservoir.c +++ /dev/null @@ -1,293 +0,0 @@ -/* - * bit reservoir source file - * - * Copyright (c) 1999-2000 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: reservoir.c,v 1.45 2011/05/07 16:05:17 rbrito Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "reservoir.h" - -#include "bitstream.h" -#include "lame-analysis.h" -#include "lame_global_flags.h" - - -/* - ResvFrameBegin: - Called (repeatedly) at the beginning of a frame. Updates the maximum - size of the reservoir, and checks to make sure main_data_begin - was set properly by the formatter -*/ - -/* - * Background information: - * - * This is the original text from the ISO standard. Because of - * sooo many bugs and irritations correcting comments are added - * in brackets []. A '^W' means you should remove the last word. - * - * 1) The following rule can be used to calculate the maximum - * number of bits used for one granule [^W frame]: - * At the highest possible bitrate of Layer III (320 kbps - * per stereo signal [^W^W^W], 48 kHz) the frames must be of - * [^W^W^W are designed to have] constant length, i.e. - * one buffer [^W^W the frame] length is: - * - * 320 kbps * 1152/48 kHz = 7680 bit = 960 byte - * - * This value is used as the maximum buffer per channel [^W^W] at - * lower bitrates [than 320 kbps]. At 64 kbps mono or 128 kbps - * stereo the main granule length is 64 kbps * 576/48 kHz = 768 bit - * [per granule and channel] at 48 kHz sampling frequency. - * This means that there is a maximum deviation (short time buffer - * [= reservoir]) of 7680 - 2*2*768 = 4608 bits is allowed at 64 kbps. - * The actual deviation is equal to the number of bytes [with the - * meaning of octets] denoted by the main_data_end offset pointer. - * The actual maximum deviation is (2^9-1)*8 bit = 4088 bits - * [for MPEG-1 and (2^8-1)*8 bit for MPEG-2, both are hard limits]. - * ... The xchange of buffer bits between the left and right channel - * is allowed without restrictions [exception: dual channel]. - * Because of the [constructed] constraint on the buffer size - * main_data_end is always set to 0 in the case of bit_rate_index==14, - * i.e. data rate 320 kbps per stereo signal [^W^W^W]. In this case - * all data are allocated between adjacent header [^W sync] words - * [, i.e. there is no buffering at all]. - */ - -int -ResvFrameBegin(lame_internal_flags * gfc, int *mean_bits) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int fullFrameBits; - int resvLimit; - int maxmp3buf; - III_side_info_t *const l3_side = &gfc->l3_side; - int frameLength; - int meanBits; - - frameLength = getframebits(gfc); - meanBits = (frameLength - cfg->sideinfo_len * 8) / cfg->mode_gr; - -/* - * Meaning of the variables: - * resvLimit: (0, 8, ..., 8*255 (MPEG-2), 8*511 (MPEG-1)) - * Number of bits can be stored in previous frame(s) due to - * counter size constaints - * maxmp3buf: ( ??? ... 8*1951 (MPEG-1 and 2), 8*2047 (MPEG-2.5)) - * Number of bits allowed to encode one frame (you can take 8*511 bit - * from the bit reservoir and at most 8*1440 bit from the current - * frame (320 kbps, 32 kHz), so 8*1951 bit is the largest possible - * value for MPEG-1 and -2) - * - * maximum allowed granule/channel size times 4 = 8*2047 bits., - * so this is the absolute maximum supported by the format. - * - * - * fullFrameBits: maximum number of bits available for encoding - * the current frame. - * - * mean_bits: target number of bits per granule. - * - * frameLength: - * - * gfc->ResvMax: maximum allowed reservoir - * - * gfc->ResvSize: current reservoir size - * - * l3_side->resvDrain_pre: - * ancillary data to be added to previous frame: - * (only usefull in VBR modes if it is possible to have - * maxmp3buf < fullFrameBits)). Currently disabled, - * see #define NEW_DRAIN - * 2010-02-13: RH now enabled, it seems to be needed for CBR too, - * as there exists one example, where the FhG decoder - * can't decode a -b320 CBR file anymore. - * - * l3_side->resvDrain_post: - * ancillary data to be added to this frame: - * - */ - - /* main_data_begin has 9 bits in MPEG-1, 8 bits MPEG-2 */ - resvLimit = (8 * 256) * cfg->mode_gr - 8; - - /* maximum allowed frame size. dont use more than this number of - bits, even if the frame has the space for them: */ - maxmp3buf = cfg->buffer_constraint; - esv->ResvMax = maxmp3buf - frameLength; - if (esv->ResvMax > resvLimit) - esv->ResvMax = resvLimit; - if (esv->ResvMax < 0 || cfg->disable_reservoir) - esv->ResvMax = 0; - - fullFrameBits = meanBits * cfg->mode_gr + Min(esv->ResvSize, esv->ResvMax); - - if (fullFrameBits > maxmp3buf) - fullFrameBits = maxmp3buf; - - assert(0 == esv->ResvMax % 8); - assert(esv->ResvMax >= 0); - - l3_side->resvDrain_pre = 0; - - if (gfc->pinfo != NULL) { - gfc->pinfo->mean_bits = meanBits / 2; /* expected bits per channel per granule [is this also right for mono/stereo, MPEG-1/2 ?] */ - gfc->pinfo->resvsize = esv->ResvSize; - } - *mean_bits = meanBits; - return fullFrameBits; -} - - -/* - ResvMaxBits - returns targ_bits: target number of bits to use for 1 granule - extra_bits: amount extra available from reservoir - Mark Taylor 4/99 -*/ -void -ResvMaxBits(lame_internal_flags * gfc, int mean_bits, int *targ_bits, int *extra_bits, int cbr) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - int add_bits, targBits, extraBits; - int ResvSize = esv->ResvSize, ResvMax = esv->ResvMax; - - /* conpensate the saved bits used in the 1st granule */ - if (cbr) - ResvSize += mean_bits; - - if (gfc->sv_qnt.substep_shaping & 1) - ResvMax *= 0.9; - - targBits = mean_bits; - - /* extra bits if the reservoir is almost full */ - if (ResvSize * 10 > ResvMax * 9) { - add_bits = ResvSize - (ResvMax * 9) / 10; - targBits += add_bits; - gfc->sv_qnt.substep_shaping |= 0x80; - } - else { - add_bits = 0; - gfc->sv_qnt.substep_shaping &= 0x7f; - /* build up reservoir. this builds the reservoir a little slower - * than FhG. It could simple be mean_bits/15, but this was rigged - * to always produce 100 (the old value) at 128kbs */ - /* *targ_bits -= (int) (mean_bits/15.2); */ - if (!cfg->disable_reservoir && !(gfc->sv_qnt.substep_shaping & 1)) - targBits -= .1 * mean_bits; - } - - - /* amount from the reservoir we are allowed to use. ISO says 6/10 */ - extraBits = (ResvSize < (esv->ResvMax * 6) / 10 ? ResvSize : (esv->ResvMax * 6) / 10); - extraBits -= add_bits; - - if (extraBits < 0) - extraBits = 0; - - *targ_bits = targBits; - *extra_bits = extraBits; -} - -/* - ResvAdjust: - Called after a granule's bit allocation. Readjusts the size of - the reservoir to reflect the granule's usage. -*/ -void -ResvAdjust(lame_internal_flags * gfc, gr_info const *gi) -{ - gfc->sv_enc.ResvSize -= gi->part2_3_length + gi->part2_length; -} - - -/* - ResvFrameEnd: - Called after all granules in a frame have been allocated. Makes sure - that the reservoir size is within limits, possibly by adding stuffing - bits. -*/ -void -ResvFrameEnd(lame_internal_flags * gfc, int mean_bits) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *const esv = &gfc->sv_enc; - III_side_info_t *const l3_side = &gfc->l3_side; - int stuffingBits; - int over_bits; - - esv->ResvSize += mean_bits * cfg->mode_gr; - stuffingBits = 0; - l3_side->resvDrain_post = 0; - l3_side->resvDrain_pre = 0; - - /* we must be byte aligned */ - if ((over_bits = esv->ResvSize % 8) != 0) - stuffingBits += over_bits; - - - over_bits = (esv->ResvSize - stuffingBits) - esv->ResvMax; - if (over_bits > 0) { - assert(0 == over_bits % 8); - assert(over_bits >= 0); - stuffingBits += over_bits; - } - - - /* NOTE: enabling the NEW_DRAIN code fixes some problems with FhG decoder - shipped with MS Windows operating systems. Using this, it is even - possible to use Gabriel's lax buffer consideration again, which - assumes, any decoder should have a buffer large enough - for a 320 kbps frame at 32 kHz sample rate. - - old drain code: - lame -b320 BlackBird.wav ---> does not play with GraphEdit.exe using FhG decoder V1.5 Build 50 - - new drain code: - lame -b320 BlackBird.wav ---> plays fine with GraphEdit.exe using FhG decoder V1.5 Build 50 - - Robert Hegemann, 2010-02-13. - */ - /* drain as many bits as possible into previous frame ancillary data - * In particular, in VBR mode ResvMax may have changed, and we have - * to make sure main_data_begin does not create a reservoir bigger - * than ResvMax mt 4/00*/ - { - int mdb_bytes = Min(l3_side->main_data_begin * 8, stuffingBits) / 8; - l3_side->resvDrain_pre += 8 * mdb_bytes; - stuffingBits -= 8 * mdb_bytes; - esv->ResvSize -= 8 * mdb_bytes; - l3_side->main_data_begin -= mdb_bytes; - } - /* drain the rest into this frames ancillary data */ - l3_side->resvDrain_post += stuffingBits; - esv->ResvSize -= stuffingBits; -} diff --git a/lib-src/lame/libmp3lame/reservoir.h b/lib-src/lame/libmp3lame/reservoir.h deleted file mode 100644 index 7c5859364..000000000 --- a/lib-src/lame/libmp3lame/reservoir.h +++ /dev/null @@ -1,31 +0,0 @@ -/* - * bit reservoir include file - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_RESERVOIR_H -#define LAME_RESERVOIR_H - -int ResvFrameBegin(lame_internal_flags * gfc, int *mean_bits); -void ResvMaxBits(lame_internal_flags * gfc, int mean_bits, int *targ_bits, int *max_bits, - int cbr); -void ResvAdjust(lame_internal_flags * gfc, gr_info const *gi); -void ResvFrameEnd(lame_internal_flags * gfc, int mean_bits); - -#endif /* LAME_RESERVOIR_H */ diff --git a/lib-src/lame/libmp3lame/set_get.c b/lib-src/lame/libmp3lame/set_get.c deleted file mode 100644 index eeb73a647..000000000 --- a/lib-src/lame/libmp3lame/set_get.c +++ /dev/null @@ -1,2346 +0,0 @@ -/* -*- mode: C; mode: fold -*- */ -/* - * set/get functions for lame_global_flags - * - * Copyright (c) 2001-2005 Alexander Leidinger - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: set_get.c,v 1.104 2017/09/06 15:07:30 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "bitstream.h" /* because of compute_flushbits */ - -#include "set_get.h" -#include "lame_global_flags.h" - -/* - * input stream description - */ - - -/* number of samples */ -/* it's unlikely for this function to return an error */ -int -lame_set_num_samples(lame_global_flags * gfp, unsigned long num_samples) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 2^32-1 */ - gfp->num_samples = num_samples; - return 0; - } - return -1; -} - -unsigned long -lame_get_num_samples(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->num_samples; - } - return 0; -} - - -/* input samplerate */ -int -lame_set_in_samplerate(lame_global_flags * gfp, int in_samplerate) -{ - if (is_lame_global_flags_valid(gfp)) { - if (in_samplerate < 1) - return -1; - /* input sample rate in Hz, default = 44100 Hz */ - gfp->samplerate_in = in_samplerate; - return 0; - } - return -1; -} - -int -lame_get_in_samplerate(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->samplerate_in; - } - return 0; -} - - -/* number of channels in input stream */ -int -lame_set_num_channels(lame_global_flags * gfp, int num_channels) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 2 */ - if (2 < num_channels || 0 >= num_channels) { - return -1; /* we don't support more than 2 channels */ - } - gfp->num_channels = num_channels; - return 0; - } - return -1; -} - -int -lame_get_num_channels(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->num_channels; - } - return 0; -} - - -/* scale the input by this amount before encoding (not used for decoding) */ -int -lame_set_scale(lame_global_flags * gfp, float scale) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 */ - gfp->scale = scale; - return 0; - } - return -1; -} - -float -lame_get_scale(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->scale; - } - return 0; -} - - -/* scale the channel 0 (left) input by this amount before - encoding (not used for decoding) */ -int -lame_set_scale_left(lame_global_flags * gfp, float scale) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 */ - gfp->scale_left = scale; - return 0; - } - return -1; -} - -float -lame_get_scale_left(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->scale_left; - } - return 0; -} - - -/* scale the channel 1 (right) input by this amount before - encoding (not used for decoding) */ -int -lame_set_scale_right(lame_global_flags * gfp, float scale) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 */ - gfp->scale_right = scale; - return 0; - } - return -1; -} - -float -lame_get_scale_right(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->scale_right; - } - return 0; -} - - -/* output sample rate in Hz */ -int -lame_set_out_samplerate(lame_global_flags * gfp, int out_samplerate) -{ - if (is_lame_global_flags_valid(gfp)) { - /* - * default = 0: LAME picks best value based on the amount - * of compression - * MPEG only allows: - * MPEG1 32, 44.1, 48khz - * MPEG2 16, 22.05, 24 - * MPEG2.5 8, 11.025, 12 - * - * (not used by decoding routines) - */ - if (out_samplerate != 0) { - int v=0; - if (SmpFrqIndex(out_samplerate, &v) < 0) - return -1; - } - gfp->samplerate_out = out_samplerate; - return 0; - } - return -1; -} - -int -lame_get_out_samplerate(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->samplerate_out; - } - return 0; -} - - - - -/* - * general control parameters - */ - -/* collect data for an MP3 frame analzyer */ -int -lame_set_analysis(lame_global_flags * gfp, int analysis) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > analysis || 1 < analysis) - return -1; - gfp->analysis = analysis; - return 0; - } - return -1; -} - -int -lame_get_analysis(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->analysis && 1 >= gfp->analysis); - return gfp->analysis; - } - return 0; -} - - -/* write a Xing VBR header frame */ -int -lame_set_bWriteVbrTag(lame_global_flags * gfp, int bWriteVbrTag) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 (on) for VBR/ABR modes, 0 (off) for CBR mode */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > bWriteVbrTag || 1 < bWriteVbrTag) - return -1; - gfp->write_lame_tag = bWriteVbrTag; - return 0; - } - return -1; -} - -int -lame_get_bWriteVbrTag(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->write_lame_tag && 1 >= gfp->write_lame_tag); - return gfp->write_lame_tag; - } - return 0; -} - - - -/* decode only, use lame/mpglib to convert mp3 to wav */ -int -lame_set_decode_only(lame_global_flags * gfp, int decode_only) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > decode_only || 1 < decode_only) - return -1; - gfp->decode_only = decode_only; - return 0; - } - return -1; -} - -int -lame_get_decode_only(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->decode_only && 1 >= gfp->decode_only); - return gfp->decode_only; - } - return 0; -} - - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -/* 1=encode a Vorbis .ogg file. default=0 */ -/* DEPRECATED */ -int CDECL lame_set_ogg(lame_global_flags *, int); -int CDECL lame_get_ogg(const lame_global_flags *); -#else -#endif - -/* encode a Vorbis .ogg file */ -/* DEPRECATED */ -int -lame_set_ogg(lame_global_flags * gfp, int ogg) -{ - (void) gfp; - (void) ogg; - return -1; -} - -int -lame_get_ogg(const lame_global_flags * gfp) -{ - (void) gfp; - return 0; -} - - -/* - * Internal algorithm selection. - * True quality is determined by the bitrate but this variable will effect - * quality by selecting expensive or cheap algorithms. - * quality=0..9. 0=best (very slow). 9=worst. - * recommended: 3 near-best quality, not too slow - * 5 good quality, fast - * 7 ok quality, really fast - */ -int -lame_set_quality(lame_global_flags * gfp, int quality) -{ - if (is_lame_global_flags_valid(gfp)) { - if (quality < 0) { - gfp->quality = 0; - } - else if (quality > 9) { - gfp->quality = 9; - } - else { - gfp->quality = quality; - } - return 0; - } - return -1; -} - -int -lame_get_quality(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->quality; - } - return 0; -} - - -/* mode = STEREO, JOINT_STEREO, DUAL_CHANNEL (not supported), MONO */ -int -lame_set_mode(lame_global_flags * gfp, MPEG_mode mode) -{ - if (is_lame_global_flags_valid(gfp)) { - int mpg_mode = mode; - /* default: lame chooses based on compression ratio and input channels */ - if (mpg_mode < 0 || MAX_INDICATOR <= mpg_mode) - return -1; /* Unknown MPEG mode! */ - gfp->mode = mode; - return 0; - } - return -1; -} - -MPEG_mode -lame_get_mode(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(gfp->mode < MAX_INDICATOR); - return gfp->mode; - } - return NOT_SET; -} - - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -/* - mode_automs. Use a M/S mode with a switching threshold based on - compression ratio - DEPRECATED -*/ -int CDECL lame_set_mode_automs(lame_global_flags *, int); -int CDECL lame_get_mode_automs(const lame_global_flags *); -#else -#endif - -/* Us a M/S mode with a switching threshold based on compression ratio */ -/* DEPRECATED */ -int -lame_set_mode_automs(lame_global_flags * gfp, int mode_automs) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > mode_automs || 1 < mode_automs) - return -1; - lame_set_mode(gfp, JOINT_STEREO); - return 0; - } - return -1; -} - -int -lame_get_mode_automs(const lame_global_flags * gfp) -{ - (void) gfp; - return 1; -} - - -/* - * Force M/S for all frames. For testing only. - * Requires mode = 1. - */ -int -lame_set_force_ms(lame_global_flags * gfp, int force_ms) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > force_ms || 1 < force_ms) - return -1; - gfp->force_ms = force_ms; - return 0; - } - return -1; -} - -int -lame_get_force_ms(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->force_ms && 1 >= gfp->force_ms); - return gfp->force_ms; - } - return 0; -} - - -/* Use free_format. */ -int -lame_set_free_format(lame_global_flags * gfp, int free_format) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > free_format || 1 < free_format) - return -1; - gfp->free_format = free_format; - return 0; - } - return -1; -} - -int -lame_get_free_format(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->free_format && 1 >= gfp->free_format); - return gfp->free_format; - } - return 0; -} - - - -/* Perform ReplayGain analysis */ -int -lame_set_findReplayGain(lame_global_flags * gfp, int findReplayGain) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > findReplayGain || 1 < findReplayGain) - return -1; - gfp->findReplayGain = findReplayGain; - return 0; - } - return -1; -} - -int -lame_get_findReplayGain(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->findReplayGain && 1 >= gfp->findReplayGain); - return gfp->findReplayGain; - } - return 0; -} - - -/* Decode on the fly. Find the peak sample. If ReplayGain analysis is - enabled then perform it on the decoded data. */ -int -lame_set_decode_on_the_fly(lame_global_flags * gfp, int decode_on_the_fly) -{ - if (is_lame_global_flags_valid(gfp)) { -#ifndef DECODE_ON_THE_FLY - return -1; -#else - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > decode_on_the_fly || 1 < decode_on_the_fly) - return -1; - - gfp->decode_on_the_fly = decode_on_the_fly; - - return 0; -#endif - } - return -1; -} - -int -lame_get_decode_on_the_fly(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->decode_on_the_fly && 1 >= gfp->decode_on_the_fly); - return gfp->decode_on_the_fly; - } - return 0; -} - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -/* DEPRECATED: now does the same as lame_set_findReplayGain() - default = 0 (disabled) */ -int CDECL lame_set_ReplayGain_input(lame_global_flags *, int); -int CDECL lame_get_ReplayGain_input(const lame_global_flags *); - -/* DEPRECATED: now does the same as - lame_set_decode_on_the_fly() && lame_set_findReplayGain() - default = 0 (disabled) */ -int CDECL lame_set_ReplayGain_decode(lame_global_flags *, int); -int CDECL lame_get_ReplayGain_decode(const lame_global_flags *); - -/* DEPRECATED: now does the same as lame_set_decode_on_the_fly() - default = 0 (disabled) */ -int CDECL lame_set_findPeakSample(lame_global_flags *, int); -int CDECL lame_get_findPeakSample(const lame_global_flags *); -#else -#endif - -/* DEPRECATED. same as lame_set_decode_on_the_fly() */ -int -lame_set_findPeakSample(lame_global_flags * gfp, int arg) -{ - return lame_set_decode_on_the_fly(gfp, arg); -} - -int -lame_get_findPeakSample(const lame_global_flags * gfp) -{ - return lame_get_decode_on_the_fly(gfp); -} - -/* DEPRECATED. same as lame_set_findReplayGain() */ -int -lame_set_ReplayGain_input(lame_global_flags * gfp, int arg) -{ - return lame_set_findReplayGain(gfp, arg); -} - -int -lame_get_ReplayGain_input(const lame_global_flags * gfp) -{ - return lame_get_findReplayGain(gfp); -} - -/* DEPRECATED. same as lame_set_decode_on_the_fly() && - lame_set_findReplayGain() */ -int -lame_set_ReplayGain_decode(lame_global_flags * gfp, int arg) -{ - if (lame_set_decode_on_the_fly(gfp, arg) < 0 || lame_set_findReplayGain(gfp, arg) < 0) - return -1; - else - return 0; -} - -int -lame_get_ReplayGain_decode(const lame_global_flags * gfp) -{ - if (lame_get_decode_on_the_fly(gfp) > 0 && lame_get_findReplayGain(gfp) > 0) - return 1; - else - return 0; -} - - -/* set and get some gapless encoding flags */ - -int -lame_set_nogap_total(lame_global_flags * gfp, int the_nogap_total) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->nogap_total = the_nogap_total; - return 0; - } - return -1; -} - -int -lame_get_nogap_total(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->nogap_total; - } - return 0; -} - -int -lame_set_nogap_currentindex(lame_global_flags * gfp, int the_nogap_index) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->nogap_current = the_nogap_index; - return 0; - } - return -1; -} - -int -lame_get_nogap_currentindex(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->nogap_current; - } - return 0; -} - - -/* message handlers */ -int -lame_set_errorf(lame_global_flags * gfp, void (*func) (const char *, va_list)) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->report.errorf = func; - return 0; - } - return -1; -} - -int -lame_set_debugf(lame_global_flags * gfp, void (*func) (const char *, va_list)) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->report.debugf = func; - return 0; - } - return -1; -} - -int -lame_set_msgf(lame_global_flags * gfp, void (*func) (const char *, va_list)) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->report.msgf = func; - return 0; - } - return -1; -} - - -/* - * Set one of - * - brate - * - compression ratio. - * - * Default is compression ratio of 11. - */ -int -lame_set_brate(lame_global_flags * gfp, int brate) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->brate = brate; - if (brate > 320) { - gfp->disable_reservoir = 1; - } - return 0; - } - return -1; -} - -int -lame_get_brate(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->brate; - } - return 0; -} - -int -lame_set_compression_ratio(lame_global_flags * gfp, float compression_ratio) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->compression_ratio = compression_ratio; - return 0; - } - return -1; -} - -float -lame_get_compression_ratio(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->compression_ratio; - } - return 0; -} - - - - -/* - * frame parameters - */ - -/* Mark as copyright protected. */ -int -lame_set_copyright(lame_global_flags * gfp, int copyright) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > copyright || 1 < copyright) - return -1; - gfp->copyright = copyright; - return 0; - } - return -1; -} - -int -lame_get_copyright(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->copyright && 1 >= gfp->copyright); - return gfp->copyright; - } - return 0; -} - - -/* Mark as original. */ -int -lame_set_original(lame_global_flags * gfp, int original) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 (enabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > original || 1 < original) - return -1; - gfp->original = original; - return 0; - } - return -1; -} - -int -lame_get_original(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->original && 1 >= gfp->original); - return gfp->original; - } - return 0; -} - - -/* - * error_protection. - * Use 2 bytes from each frame for CRC checksum. - */ -int -lame_set_error_protection(lame_global_flags * gfp, int error_protection) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > error_protection || 1 < error_protection) - return -1; - gfp->error_protection = error_protection; - return 0; - } - return -1; -} - -int -lame_get_error_protection(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->error_protection && 1 >= gfp->error_protection); - return gfp->error_protection; - } - return 0; -} - - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -/* padding_type. 0=pad no frames 1=pad all frames 2=adjust padding(default) */ -int CDECL lame_set_padding_type(lame_global_flags *, Padding_type); -Padding_type CDECL lame_get_padding_type(const lame_global_flags *); -#else -#endif - -/* - * padding_type. - * PAD_NO = pad no frames - * PAD_ALL = pad all frames - * PAD_ADJUST = adjust padding - */ -int -lame_set_padding_type(lame_global_flags * gfp, Padding_type padding_type) -{ - (void) gfp; - (void) padding_type; - return 0; -} - -Padding_type -lame_get_padding_type(const lame_global_flags * gfp) -{ - (void) gfp; - return PAD_ADJUST; -} - - -/* MP3 'private extension' bit. Meaningless. */ -int -lame_set_extension(lame_global_flags * gfp, int extension) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > extension || 1 < extension) - return -1; - gfp->extension = extension; - return 0; - } - return -1; -} - -int -lame_get_extension(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->extension && 1 >= gfp->extension); - return gfp->extension; - } - return 0; -} - - -/* Enforce strict ISO compliance. */ -int -lame_set_strict_ISO(lame_global_flags * gfp, int val) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (val < MDB_DEFAULT || MDB_MAXIMUM < val) - return -1; - gfp->strict_ISO = val; - return 0; - } - return -1; -} - -int -lame_get_strict_ISO(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->strict_ISO; - } - return 0; -} - - - - -/******************************************************************** - * quantization/noise shaping - ***********************************************************************/ - -/* Disable the bit reservoir. For testing only. */ -int -lame_set_disable_reservoir(lame_global_flags * gfp, int disable_reservoir) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > disable_reservoir || 1 < disable_reservoir) - return -1; - gfp->disable_reservoir = disable_reservoir; - return 0; - } - return -1; -} - -int -lame_get_disable_reservoir(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->disable_reservoir && 1 >= gfp->disable_reservoir); - return gfp->disable_reservoir; - } - return 0; -} - - - - -int -lame_set_experimentalX(lame_global_flags * gfp, int experimentalX) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_set_quant_comp(gfp, experimentalX); - lame_set_quant_comp_short(gfp, experimentalX); - return 0; - } - return -1; -} - -int -lame_get_experimentalX(const lame_global_flags * gfp) -{ - return lame_get_quant_comp(gfp); -} - - -/* Select a different "best quantization" function. default = 0 */ -int -lame_set_quant_comp(lame_global_flags * gfp, int quant_type) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->quant_comp = quant_type; - return 0; - } - return -1; -} - -int -lame_get_quant_comp(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->quant_comp; - } - return 0; -} - - -/* Select a different "best quantization" function. default = 0 */ -int -lame_set_quant_comp_short(lame_global_flags * gfp, int quant_type) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->quant_comp_short = quant_type; - return 0; - } - return -1; -} - -int -lame_get_quant_comp_short(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->quant_comp_short; - } - return 0; -} - - -/* Another experimental option. For testing only. */ -int -lame_set_experimentalY(lame_global_flags * gfp, int experimentalY) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->experimentalY = experimentalY; - return 0; - } - return -1; -} - -int -lame_get_experimentalY(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->experimentalY; - } - return 0; -} - - -int -lame_set_experimentalZ(lame_global_flags * gfp, int experimentalZ) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->experimentalZ = experimentalZ; - return 0; - } - return -1; -} - -int -lame_get_experimentalZ(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->experimentalZ; - } - return 0; -} - - -/* Naoki's psycho acoustic model. */ -int -lame_set_exp_nspsytune(lame_global_flags * gfp, int exp_nspsytune) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - gfp->exp_nspsytune = exp_nspsytune; - return 0; - } - return -1; -} - -int -lame_get_exp_nspsytune(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->exp_nspsytune; - } - return 0; -} - - - - -/******************************************************************** - * VBR control - ***********************************************************************/ - -/* Types of VBR. default = vbr_off = CBR */ -int -lame_set_VBR(lame_global_flags * gfp, vbr_mode VBR) -{ - if (is_lame_global_flags_valid(gfp)) { - int vbr_q = VBR; - if (0 > vbr_q || vbr_max_indicator <= vbr_q) - return -1; /* Unknown VBR mode! */ - gfp->VBR = VBR; - return 0; - } - return -1; -} - -vbr_mode -lame_get_VBR(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(gfp->VBR < vbr_max_indicator); - return gfp->VBR; - } - return vbr_off; -} - - -/* - * VBR quality level. - * 0 = highest - * 9 = lowest - */ -int -lame_set_VBR_q(lame_global_flags * gfp, int VBR_q) -{ - if (is_lame_global_flags_valid(gfp)) { - int ret = 0; - - if (0 > VBR_q) { - ret = -1; /* Unknown VBR quality level! */ - VBR_q = 0; - } - if (9 < VBR_q) { - ret = -1; - VBR_q = 9; - } - gfp->VBR_q = VBR_q; - gfp->VBR_q_frac = 0; - return ret; - } - return -1; -} - -int -lame_get_VBR_q(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->VBR_q && 10 > gfp->VBR_q); - return gfp->VBR_q; - } - return 0; -} - -int -lame_set_VBR_quality(lame_global_flags * gfp, float VBR_q) -{ - if (is_lame_global_flags_valid(gfp)) { - int ret = 0; - - if (0 > VBR_q) { - ret = -1; /* Unknown VBR quality level! */ - VBR_q = 0; - } - if (9.999 < VBR_q) { - ret = -1; - VBR_q = 9.999; - } - - gfp->VBR_q = (int) VBR_q; - gfp->VBR_q_frac = VBR_q - gfp->VBR_q; - - return ret; - } - return -1; -} - -float -lame_get_VBR_quality(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->VBR_q + gfp->VBR_q_frac; - } - return 0; -} - - -/* Ignored except for VBR = vbr_abr (ABR mode) */ -int -lame_set_VBR_mean_bitrate_kbps(lame_global_flags * gfp, int VBR_mean_bitrate_kbps) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->VBR_mean_bitrate_kbps = VBR_mean_bitrate_kbps; - return 0; - } - return -1; -} - -int -lame_get_VBR_mean_bitrate_kbps(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->VBR_mean_bitrate_kbps; - } - return 0; -} - -int -lame_set_VBR_min_bitrate_kbps(lame_global_flags * gfp, int VBR_min_bitrate_kbps) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->VBR_min_bitrate_kbps = VBR_min_bitrate_kbps; - return 0; - } - return -1; -} - -int -lame_get_VBR_min_bitrate_kbps(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->VBR_min_bitrate_kbps; - } - return 0; -} - -int -lame_set_VBR_max_bitrate_kbps(lame_global_flags * gfp, int VBR_max_bitrate_kbps) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->VBR_max_bitrate_kbps = VBR_max_bitrate_kbps; - return 0; - } - return -1; -} - -int -lame_get_VBR_max_bitrate_kbps(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->VBR_max_bitrate_kbps; - } - return 0; -} - - -/* - * Strictly enforce VBR_min_bitrate. - * Normally it will be violated for analog silence. - */ -int -lame_set_VBR_hard_min(lame_global_flags * gfp, int VBR_hard_min) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 (disabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > VBR_hard_min || 1 < VBR_hard_min) - return -1; - - gfp->VBR_hard_min = VBR_hard_min; - - return 0; - } - return -1; -} - -int -lame_get_VBR_hard_min(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->VBR_hard_min && 1 >= gfp->VBR_hard_min); - return gfp->VBR_hard_min; - } - return 0; -} - - -/******************************************************************** - * Filtering control - ***********************************************************************/ - -/* - * Freqency in Hz to apply lowpass. - * 0 = default = lame chooses - * -1 = disabled - */ -int -lame_set_lowpassfreq(lame_global_flags * gfp, int lowpassfreq) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->lowpassfreq = lowpassfreq; - return 0; - } - return -1; -} - -int -lame_get_lowpassfreq(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->lowpassfreq; - } - return 0; -} - - -/* - * Width of transition band (in Hz). - * default = one polyphase filter band - */ -int -lame_set_lowpasswidth(lame_global_flags * gfp, int lowpasswidth) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->lowpasswidth = lowpasswidth; - return 0; - } - return -1; -} - -int -lame_get_lowpasswidth(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->lowpasswidth; - } - return 0; -} - - -/* - * Frequency in Hz to apply highpass. - * 0 = default = lame chooses - * -1 = disabled - */ -int -lame_set_highpassfreq(lame_global_flags * gfp, int highpassfreq) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->highpassfreq = highpassfreq; - return 0; - } - return -1; -} - -int -lame_get_highpassfreq(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->highpassfreq; - } - return 0; -} - - -/* - * Width of transition band (in Hz). - * default = one polyphase filter band - */ -int -lame_set_highpasswidth(lame_global_flags * gfp, int highpasswidth) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->highpasswidth = highpasswidth; - return 0; - } - return -1; -} - -int -lame_get_highpasswidth(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->highpasswidth; - } - return 0; -} - - - - -/* - * psycho acoustics and other arguments which you should not change - * unless you know what you are doing - */ - - -/* Adjust masking values. */ -int -lame_set_maskingadjust(lame_global_flags * gfp, float adjust) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->maskingadjust = adjust; - return 0; - } - return -1; -} - -float -lame_get_maskingadjust(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->maskingadjust; - } - return 0; -} - -int -lame_set_maskingadjust_short(lame_global_flags * gfp, float adjust) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->maskingadjust_short = adjust; - return 0; - } - return -1; -} - -float -lame_get_maskingadjust_short(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->maskingadjust_short; - } - return 0; -} - -/* Only use ATH for masking. */ -int -lame_set_ATHonly(lame_global_flags * gfp, int ATHonly) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->ATHonly = ATHonly; - return 0; - } - return -1; -} - -int -lame_get_ATHonly(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->ATHonly; - } - return 0; -} - - -/* Only use ATH for short blocks. */ -int -lame_set_ATHshort(lame_global_flags * gfp, int ATHshort) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->ATHshort = ATHshort; - return 0; - } - return -1; -} - -int -lame_get_ATHshort(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->ATHshort; - } - return 0; -} - - -/* Disable ATH. */ -int -lame_set_noATH(lame_global_flags * gfp, int noATH) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->noATH = noATH; - return 0; - } - return -1; -} - -int -lame_get_noATH(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->noATH; - } - return 0; -} - - -/* Select ATH formula. */ -int -lame_set_ATHtype(lame_global_flags * gfp, int ATHtype) -{ - if (is_lame_global_flags_valid(gfp)) { - /* XXX: ATHtype should be converted to an enum. */ - gfp->ATHtype = ATHtype; - return 0; - } - return -1; -} - -int -lame_get_ATHtype(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->ATHtype; - } - return 0; -} - - -/* Select ATH formula 4 shape. */ -int -lame_set_ATHcurve(lame_global_flags * gfp, float ATHcurve) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->ATHcurve = ATHcurve; - return 0; - } - return -1; -} - -float -lame_get_ATHcurve(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->ATHcurve; - } - return 0; -} - - -/* Lower ATH by this many db. */ -int -lame_set_ATHlower(lame_global_flags * gfp, float ATHlower) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->ATH_lower_db = ATHlower; - return 0; - } - return -1; -} - -float -lame_get_ATHlower(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->ATH_lower_db; - } - return 0; -} - - -/* Select ATH adaptive adjustment scheme. */ -int -lame_set_athaa_type(lame_global_flags * gfp, int athaa_type) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->athaa_type = athaa_type; - return 0; - } - return -1; -} - -int -lame_get_athaa_type(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->athaa_type; - } - return 0; -} - - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -int CDECL lame_set_athaa_loudapprox(lame_global_flags * gfp, int athaa_loudapprox); -int CDECL lame_get_athaa_loudapprox(const lame_global_flags * gfp); -#else -#endif - -/* Select the loudness approximation used by the ATH adaptive auto-leveling. */ -int -lame_set_athaa_loudapprox(lame_global_flags * gfp, int athaa_loudapprox) -{ - (void) gfp; - (void) athaa_loudapprox; - return 0; -} - -int -lame_get_athaa_loudapprox(const lame_global_flags * gfp) -{ - (void) gfp; - /* obsolete, the type known under number 2 is the only survival */ - return 2; -} - - -/* Adjust (in dB) the point below which adaptive ATH level adjustment occurs. */ -int -lame_set_athaa_sensitivity(lame_global_flags * gfp, float athaa_sensitivity) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->athaa_sensitivity = athaa_sensitivity; - return 0; - } - return -1; -} - -float -lame_get_athaa_sensitivity(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->athaa_sensitivity; - } - return 0; -} - - -/* Predictability limit (ISO tonality formula) */ -int lame_set_cwlimit(lame_global_flags * gfp, int cwlimit); -int lame_get_cwlimit(const lame_global_flags * gfp); - -int -lame_set_cwlimit(lame_global_flags * gfp, int cwlimit) -{ - (void) gfp; - (void) cwlimit; - return 0; -} - -int -lame_get_cwlimit(const lame_global_flags * gfp) -{ - (void) gfp; - return 0; -} - - - -/* - * Allow blocktypes to differ between channels. - * default: - * 0 for jstereo => block types coupled - * 1 for stereo => block types may differ - */ -int -lame_set_allow_diff_short(lame_global_flags * gfp, int allow_diff_short) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->short_blocks = allow_diff_short ? short_block_allowed : short_block_coupled; - return 0; - } - return -1; -} - -int -lame_get_allow_diff_short(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - if (gfp->short_blocks == short_block_allowed) - return 1; /* short blocks allowed to differ */ - else - return 0; /* not set, dispensed, forced or coupled */ - } - return 0; -} - - -/* Use temporal masking effect */ -int -lame_set_useTemporal(lame_global_flags * gfp, int useTemporal) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 1 (enabled) */ - - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 <= useTemporal && useTemporal <= 1) { - gfp->useTemporal = useTemporal; - return 0; - } - } - return -1; -} - -int -lame_get_useTemporal(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->useTemporal && 1 >= gfp->useTemporal); - return gfp->useTemporal; - } - return 0; -} - - -/* Use inter-channel masking effect */ -int -lame_set_interChRatio(lame_global_flags * gfp, float ratio) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0.0 (no inter-channel maskin) */ - if (0 <= ratio && ratio <= 1.0) { - gfp->interChRatio = ratio; - return 0; - } - } - return -1; -} - -float -lame_get_interChRatio(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert((0 <= gfp->interChRatio && gfp->interChRatio <= 1.0) || EQ(gfp->interChRatio, -1.0)); - return gfp->interChRatio; - } - return 0; -} - - -/* Use pseudo substep shaping method */ -int -lame_set_substep(lame_global_flags * gfp, int method) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0.0 (no substep noise shaping) */ - if (0 <= method && method <= 7) { - gfp->substep_shaping = method; - return 0; - } - } - return -1; -} - -int -lame_get_substep(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->substep_shaping && gfp->substep_shaping <= 7); - return gfp->substep_shaping; - } - return 0; -} - -/* scalefactors scale */ -int -lame_set_sfscale(lame_global_flags * gfp, int val) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->noise_shaping = (val != 0) ? 2 : 1; - return 0; - } - return -1; -} - -int -lame_get_sfscale(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return (gfp->noise_shaping == 2) ? 1 : 0; - } - return 0; -} - -/* subblock gain */ -int -lame_set_subblock_gain(lame_global_flags * gfp, int sbgain) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->subblock_gain = sbgain; - return 0; - } - return -1; -} - -int -lame_get_subblock_gain(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->subblock_gain; - } - return 0; -} - - -/* Disable short blocks. */ -int -lame_set_no_short_blocks(lame_global_flags * gfp, int no_short_blocks) -{ - if (is_lame_global_flags_valid(gfp)) { - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 <= no_short_blocks && no_short_blocks <= 1) { - gfp->short_blocks = no_short_blocks ? short_block_dispensed : short_block_allowed; - return 0; - } - } - return -1; -} - -int -lame_get_no_short_blocks(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - switch (gfp->short_blocks) { - default: - case short_block_not_set: - return -1; - case short_block_dispensed: - return 1; - case short_block_allowed: - case short_block_coupled: - case short_block_forced: - return 0; - } - } - return -1; -} - - -/* Force short blocks. */ -int -lame_set_force_short_blocks(lame_global_flags * gfp, int short_blocks) -{ - if (is_lame_global_flags_valid(gfp)) { - /* enforce disable/enable meaning, if we need more than two values - we need to switch to an enum to have an apropriate representation - of the possible meanings of the value */ - if (0 > short_blocks || 1 < short_blocks) - return -1; - - if (short_blocks == 1) - gfp->short_blocks = short_block_forced; - else if (gfp->short_blocks == short_block_forced) - gfp->short_blocks = short_block_allowed; - - return 0; - } - return -1; -} - -int -lame_get_force_short_blocks(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - switch (gfp->short_blocks) { - default: - case short_block_not_set: - return -1; - case short_block_dispensed: - case short_block_allowed: - case short_block_coupled: - return 0; - case short_block_forced: - return 1; - } - } - return -1; -} - -int -lame_set_short_threshold_lrm(lame_global_flags * gfp, float lrm) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->attackthre = lrm; - return 0; - } - return -1; -} - -float -lame_get_short_threshold_lrm(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->attackthre; - } - return 0; -} - -int -lame_set_short_threshold_s(lame_global_flags * gfp, float s) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->attackthre_s = s; - return 0; - } - return -1; -} - -float -lame_get_short_threshold_s(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->attackthre_s; - } - return 0; -} - -int -lame_set_short_threshold(lame_global_flags * gfp, float lrm, float s) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_set_short_threshold_lrm(gfp, lrm); - lame_set_short_threshold_s(gfp, s); - return 0; - } - return -1; -} - - -/* - * Input PCM is emphased PCM - * (for instance from one of the rarely emphased CDs). - * - * It is STRONGLY not recommended to use this, because psycho does not - * take it into account, and last but not least many decoders - * ignore these bits - */ -int -lame_set_emphasis(lame_global_flags * gfp, int emphasis) -{ - if (is_lame_global_flags_valid(gfp)) { - /* XXX: emphasis should be converted to an enum */ - if (0 <= emphasis && emphasis < 4) { - gfp->emphasis = emphasis; - return 0; - } - } - return -1; -} - -int -lame_get_emphasis(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - assert(0 <= gfp->emphasis && gfp->emphasis < 4); - return gfp->emphasis; - } - return 0; -} - - - - -/***************************************************************/ -/* internal variables, cannot be set... */ -/* provided because they may be of use to calling application */ -/***************************************************************/ - -/* MPEG version. - * 0 = MPEG-2 - * 1 = MPEG-1 - * (2 = MPEG-2.5) - */ -int -lame_get_version(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->cfg.version; - } - } - return 0; -} - - -/* Encoder delay. */ -int -lame_get_encoder_delay(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_enc.encoder_delay; - } - } - return 0; -} - -/* padding added to the end of the input */ -int -lame_get_encoder_padding(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_enc.encoder_padding; - } - } - return 0; -} - - -/* Size of MPEG frame. */ -int -lame_get_framesize(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - return 576 * cfg->mode_gr; - } - } - return 0; -} - - -/* Number of frames encoded so far. */ -int -lame_get_frameNum(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_enc.frame_number; - } - } - return 0; -} - -int -lame_get_mf_samples_to_encode(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->sv_enc.mf_samples_to_encode; - } - } - return 0; -} - -int CDECL -lame_get_size_mp3buffer(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - int size; - compute_flushbits(gfc, &size); - return size; - } - } - return 0; -} - -int -lame_get_RadioGain(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_rpg.RadioGain; - } - } - return 0; -} - -int -lame_get_AudiophileGain(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return 0; - } - } - return 0; -} - -float -lame_get_PeakSample(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return (float) gfc->ov_rpg.PeakSample; - } - } - return 0; -} - -int -lame_get_noclipGainChange(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_rpg.noclipGainChange; - } - } - return 0; -} - -float -lame_get_noclipScale(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return gfc->ov_rpg.noclipScale; - } - } - return 0; -} - - -/* - * LAME's estimate of the total number of frames to be encoded. - * Only valid if calling program set num_samples. - */ -int -lame_get_totalframes(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - SessionConfig_t const *const cfg = &gfc->cfg; - unsigned long const pcm_samples_per_frame = 576 * cfg->mode_gr; - unsigned long pcm_samples_to_encode = gfp->num_samples; - unsigned long end_padding = 0; - int frames = 0; - - if (pcm_samples_to_encode == (0ul-1ul)) - return 0; /* unknown */ - - /* estimate based on user set num_samples: */ - if (cfg->samplerate_in != cfg->samplerate_out) { - /* resampling, estimate new samples_to_encode */ - double resampled_samples_to_encode = 0.0, frames_f = 0.0; - if (cfg->samplerate_in > 0) { - resampled_samples_to_encode = pcm_samples_to_encode; - resampled_samples_to_encode *= cfg->samplerate_out; - resampled_samples_to_encode /= cfg->samplerate_in; - } - if (resampled_samples_to_encode <= 0.0) - return 0; /* unlikely to happen, so what, no estimate! */ - frames_f = floor(resampled_samples_to_encode / pcm_samples_per_frame); - if (frames_f >= (INT_MAX-2)) - return 0; /* overflow, happens eventually, no estimate! */ - frames = frames_f; - resampled_samples_to_encode -= frames * pcm_samples_per_frame; - pcm_samples_to_encode = ceil(resampled_samples_to_encode); - } - else { - frames = pcm_samples_to_encode / pcm_samples_per_frame; - pcm_samples_to_encode -= frames * pcm_samples_per_frame; - } - pcm_samples_to_encode += 576ul; - end_padding = pcm_samples_per_frame - (pcm_samples_to_encode % pcm_samples_per_frame); - if (end_padding < 576ul) { - end_padding += pcm_samples_per_frame; - } - pcm_samples_to_encode += end_padding; - frames += (pcm_samples_to_encode / pcm_samples_per_frame); - /* check to see if we underestimated totalframes */ - /* if (totalframes < gfp->frameNum) */ - /* totalframes = gfp->frameNum; */ - return frames; - } - } - return 0; -} - - - - - -int -lame_set_preset(lame_global_flags * gfp, int preset) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->preset = preset; - return apply_preset(gfp, preset, 1); - } - return -1; -} - - - -int -lame_set_asm_optimizations(lame_global_flags * gfp, int optim, int mode) -{ - if (is_lame_global_flags_valid(gfp)) { - mode = (mode == 1 ? 1 : 0); - switch (optim) { - case MMX:{ - gfp->asm_optimizations.mmx = mode; - return optim; - } - case AMD_3DNOW:{ - gfp->asm_optimizations.amd3dnow = mode; - return optim; - } - case SSE:{ - gfp->asm_optimizations.sse = mode; - return optim; - } - default: - return optim; - } - } - return -1; -} - - -void -lame_set_write_id3tag_automatic(lame_global_flags * gfp, int v) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->write_id3tag_automatic = v; - } -} - - -int -lame_get_write_id3tag_automatic(lame_global_flags const *gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->write_id3tag_automatic; - } - return 1; -} - - -/* - -UNDOCUMENTED, experimental settings. These routines are not prototyped -in lame.h. You should not use them, they are experimental and may -change. - -*/ - - -/* - * just another daily changing developer switch - */ -void CDECL lame_set_tune(lame_global_flags *, float); - -void -lame_set_tune(lame_global_flags * gfp, float val) -{ - if (is_lame_global_flags_valid(gfp)) { - gfp->tune_value_a = val; - gfp->tune = 1; - } -} - -/* Custom msfix hack */ -void -lame_set_msfix(lame_global_flags * gfp, double msfix) -{ - if (is_lame_global_flags_valid(gfp)) { - /* default = 0 */ - gfp->msfix = msfix; - } -} - -float -lame_get_msfix(const lame_global_flags * gfp) -{ - if (is_lame_global_flags_valid(gfp)) { - return gfp->msfix; - } - return 0; -} - -#if DEPRECATED_OR_OBSOLETE_CODE_REMOVED -int CDECL lame_set_preset_expopts(lame_global_flags *, int); -#else -#endif - -int -lame_set_preset_expopts(lame_global_flags * gfp, int preset_expopts) -{ - (void) gfp; - (void) preset_expopts; - return 0; -} - - -int -lame_set_preset_notune(lame_global_flags * gfp, int preset_notune) -{ - (void) gfp; - (void) preset_notune; - return 0; -} - -static int -calc_maximum_input_samples_for_buffer_size(lame_internal_flags const* gfc, size_t buffer_size) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int const pcm_samples_per_frame = 576 * cfg->mode_gr; - int frames_per_buffer = 0, input_samples_per_buffer = 0; - int kbps = 320; - - if (cfg->samplerate_out < 16000) - kbps = 64; - else if (cfg->samplerate_out < 32000) - kbps = 160; - else - kbps = 320; - if (cfg->free_format) - kbps = cfg->avg_bitrate; - else if (cfg->vbr == vbr_off) { - kbps = cfg->avg_bitrate; - } - { - int const pad = 1; - int const bpf = ((cfg->version + 1) * 72000 * kbps / cfg->samplerate_out + pad); - frames_per_buffer = buffer_size / bpf; - } - { - double ratio = (double) cfg->samplerate_in / cfg->samplerate_out; - input_samples_per_buffer = pcm_samples_per_frame * frames_per_buffer * ratio; - } - return input_samples_per_buffer; -} - -int -lame_get_maximum_number_of_samples(lame_t gfp, size_t buffer_size) -{ - if (is_lame_global_flags_valid(gfp)) { - lame_internal_flags const *const gfc = gfp->internal_flags; - if (is_lame_internal_flags_valid(gfc)) { - return calc_maximum_input_samples_for_buffer_size(gfc, buffer_size); - } - } - return LAME_GENERICERROR; -} diff --git a/lib-src/lame/libmp3lame/set_get.h b/lib-src/lame/libmp3lame/set_get.h deleted file mode 100644 index 37e4bcdbe..000000000 --- a/lib-src/lame/libmp3lame/set_get.h +++ /dev/null @@ -1,76 +0,0 @@ -/* - * set_get.h -- Internal set/get definitions - * - * Copyright (C) 2003 Gabriel Bouvigne / Lame project - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. - */ - -#ifndef __SET_GET_H__ -#define __SET_GET_H__ - -#include - -#if defined(__cplusplus) -extern "C" { -#endif - -/* select psychoacoustic model */ - -/* manage short blocks */ - int CDECL lame_set_short_threshold(lame_global_flags *, float, float); - int CDECL lame_set_short_threshold_lrm(lame_global_flags *, float); - float CDECL lame_get_short_threshold_lrm(const lame_global_flags *); - int CDECL lame_set_short_threshold_s(lame_global_flags *, float); - float CDECL lame_get_short_threshold_s(const lame_global_flags *); - - - int CDECL lame_set_maskingadjust(lame_global_flags *, float); - float CDECL lame_get_maskingadjust(const lame_global_flags *); - - int CDECL lame_set_maskingadjust_short(lame_global_flags *, float); - float CDECL lame_get_maskingadjust_short(const lame_global_flags *); - -/* select ATH formula 4 shape */ - int CDECL lame_set_ATHcurve(lame_global_flags *, float); - float CDECL lame_get_ATHcurve(const lame_global_flags *); - - int CDECL lame_set_preset_notune(lame_global_flags *, int); - -/* substep shaping method */ - int CDECL lame_set_substep(lame_global_flags *, int); - int CDECL lame_get_substep(const lame_global_flags *); - -/* scalefactors scale */ - int CDECL lame_set_sfscale(lame_global_flags *, int); - int CDECL lame_get_sfscale(const lame_global_flags *); - -/* subblock gain */ - int CDECL lame_set_subblock_gain(lame_global_flags *, int); - int CDECL lame_get_subblock_gain(const lame_global_flags *); - - - -/*presets*/ - int apply_preset(lame_global_flags *, int preset, int enforce); - - void CDECL lame_set_tune(lame_t, float); /* FOR INTERNAL USE ONLY */ - void CDECL lame_set_msfix(lame_t gfp, double msfix); - - -#if defined(__cplusplus) -} -#endif -#endif diff --git a/lib-src/lame/libmp3lame/tables.c b/lib-src/lame/libmp3lame/tables.c deleted file mode 100644 index a0230999f..000000000 --- a/lib-src/lame/libmp3lame/tables.c +++ /dev/null @@ -1,564 +0,0 @@ -/* - * MPEG layer 3 tables source file - * - * Copyright (c) 1999 Albert L Faber - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: tables.c,v 1.29 2011/05/07 16:05:17 rbrito Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "machine.h" - -#include "lame.h" -#include "tables.h" - - -static const uint16_t t1HB[] = { - 1, 1, - 1, 0 -}; - -static const uint16_t t2HB[] = { - 1, 2, 1, - 3, 1, 1, - 3, 2, 0 -}; - -static const uint16_t t3HB[] = { - 3, 2, 1, - 1, 1, 1, - 3, 2, 0 -}; - -static const uint16_t t5HB[] = { - 1, 2, 6, 5, - 3, 1, 4, 4, - 7, 5, 7, 1, - 6, 1, 1, 0 -}; - -static const uint16_t t6HB[] = { - 7, 3, 5, 1, - 6, 2, 3, 2, - 5, 4, 4, 1, - 3, 3, 2, 0 -}; - -static const uint16_t t7HB[] = { - 1, 2, 10, 19, 16, 10, - 3, 3, 7, 10, 5, 3, - 11, 4, 13, 17, 8, 4, - 12, 11, 18, 15, 11, 2, - 7, 6, 9, 14, 3, 1, - 6, 4, 5, 3, 2, 0 -}; - -static const uint16_t t8HB[] = { - 3, 4, 6, 18, 12, 5, - 5, 1, 2, 16, 9, 3, - 7, 3, 5, 14, 7, 3, - 19, 17, 15, 13, 10, 4, - 13, 5, 8, 11, 5, 1, - 12, 4, 4, 1, 1, 0 -}; - -static const uint16_t t9HB[] = { - 7, 5, 9, 14, 15, 7, - 6, 4, 5, 5, 6, 7, - 7, 6, 8, 8, 8, 5, - 15, 6, 9, 10, 5, 1, - 11, 7, 9, 6, 4, 1, - 14, 4, 6, 2, 6, 0 -}; - -static const uint16_t t10HB[] = { - 1, 2, 10, 23, 35, 30, 12, 17, - 3, 3, 8, 12, 18, 21, 12, 7, - 11, 9, 15, 21, 32, 40, 19, 6, - 14, 13, 22, 34, 46, 23, 18, 7, - 20, 19, 33, 47, 27, 22, 9, 3, - 31, 22, 41, 26, 21, 20, 5, 3, - 14, 13, 10, 11, 16, 6, 5, 1, - 9, 8, 7, 8, 4, 4, 2, 0 -}; - -static const uint16_t t11HB[] = { - 3, 4, 10, 24, 34, 33, 21, 15, - 5, 3, 4, 10, 32, 17, 11, 10, - 11, 7, 13, 18, 30, 31, 20, 5, - 25, 11, 19, 59, 27, 18, 12, 5, - 35, 33, 31, 58, 30, 16, 7, 5, - 28, 26, 32, 19, 17, 15, 8, 14, - 14, 12, 9, 13, 14, 9, 4, 1, - 11, 4, 6, 6, 6, 3, 2, 0 -}; - -static const uint16_t t12HB[] = { - 9, 6, 16, 33, 41, 39, 38, 26, - 7, 5, 6, 9, 23, 16, 26, 11, - 17, 7, 11, 14, 21, 30, 10, 7, - 17, 10, 15, 12, 18, 28, 14, 5, - 32, 13, 22, 19, 18, 16, 9, 5, - 40, 17, 31, 29, 17, 13, 4, 2, - 27, 12, 11, 15, 10, 7, 4, 1, - 27, 12, 8, 12, 6, 3, 1, 0 -}; - -static const uint16_t t13HB[] = { - 1, 5, 14, 21, 34, 51, 46, 71, 42, 52, 68, 52, 67, 44, 43, 19, - 3, 4, 12, 19, 31, 26, 44, 33, 31, 24, 32, 24, 31, 35, 22, 14, - 15, 13, 23, 36, 59, 49, 77, 65, 29, 40, 30, 40, 27, 33, 42, 16, - 22, 20, 37, 61, 56, 79, 73, 64, 43, 76, 56, 37, 26, 31, 25, 14, - 35, 16, 60, 57, 97, 75, 114, 91, 54, 73, 55, 41, 48, 53, 23, 24, - 58, 27, 50, 96, 76, 70, 93, 84, 77, 58, 79, 29, 74, 49, 41, 17, - 47, 45, 78, 74, 115, 94, 90, 79, 69, 83, 71, 50, 59, 38, 36, 15, - 72, 34, 56, 95, 92, 85, 91, 90, 86, 73, 77, 65, 51, 44, 43, 42, - 43, 20, 30, 44, 55, 78, 72, 87, 78, 61, 46, 54, 37, 30, 20, 16, - 53, 25, 41, 37, 44, 59, 54, 81, 66, 76, 57, 54, 37, 18, 39, 11, - 35, 33, 31, 57, 42, 82, 72, 80, 47, 58, 55, 21, 22, 26, 38, 22, - 53, 25, 23, 38, 70, 60, 51, 36, 55, 26, 34, 23, 27, 14, 9, 7, - 34, 32, 28, 39, 49, 75, 30, 52, 48, 40, 52, 28, 18, 17, 9, 5, - 45, 21, 34, 64, 56, 50, 49, 45, 31, 19, 12, 15, 10, 7, 6, 3, - 48, 23, 20, 39, 36, 35, 53, 21, 16, 23, 13, 10, 6, 1, 4, 2, - 16, 15, 17, 27, 25, 20, 29, 11, 17, 12, 16, 8, 1, 1, 0, 1 -}; - -static const uint16_t t15HB[] = { - 7, 12, 18, 53, 47, 76, 124, 108, 89, 123, 108, 119, 107, 81, 122, 63, - 13, 5, 16, 27, 46, 36, 61, 51, 42, 70, 52, 83, 65, 41, 59, 36, - 19, 17, 15, 24, 41, 34, 59, 48, 40, 64, 50, 78, 62, 80, 56, 33, - 29, 28, 25, 43, 39, 63, 55, 93, 76, 59, 93, 72, 54, 75, 50, 29, - 52, 22, 42, 40, 67, 57, 95, 79, 72, 57, 89, 69, 49, 66, 46, 27, - 77, 37, 35, 66, 58, 52, 91, 74, 62, 48, 79, 63, 90, 62, 40, 38, - 125, 32, 60, 56, 50, 92, 78, 65, 55, 87, 71, 51, 73, 51, 70, 30, - 109, 53, 49, 94, 88, 75, 66, 122, 91, 73, 56, 42, 64, 44, 21, 25, - 90, 43, 41, 77, 73, 63, 56, 92, 77, 66, 47, 67, 48, 53, 36, 20, - 71, 34, 67, 60, 58, 49, 88, 76, 67, 106, 71, 54, 38, 39, 23, 15, - 109, 53, 51, 47, 90, 82, 58, 57, 48, 72, 57, 41, 23, 27, 62, 9, - 86, 42, 40, 37, 70, 64, 52, 43, 70, 55, 42, 25, 29, 18, 11, 11, - 118, 68, 30, 55, 50, 46, 74, 65, 49, 39, 24, 16, 22, 13, 14, 7, - 91, 44, 39, 38, 34, 63, 52, 45, 31, 52, 28, 19, 14, 8, 9, 3, - 123, 60, 58, 53, 47, 43, 32, 22, 37, 24, 17, 12, 15, 10, 2, 1, - 71, 37, 34, 30, 28, 20, 17, 26, 21, 16, 10, 6, 8, 6, 2, 0 -}; - -static const uint16_t t16HB[] = { - 1, 5, 14, 44, 74, 63, 110, 93, 172, 149, 138, 242, 225, 195, 376, 17, - 3, 4, 12, 20, 35, 62, 53, 47, 83, 75, 68, 119, 201, 107, 207, 9, - 15, 13, 23, 38, 67, 58, 103, 90, 161, 72, 127, 117, 110, 209, 206, 16, - 45, 21, 39, 69, 64, 114, 99, 87, 158, 140, 252, 212, 199, 387, 365, 26, - 75, 36, 68, 65, 115, 101, 179, 164, 155, 264, 246, 226, 395, 382, 362, 9, - 66, 30, 59, 56, 102, 185, 173, 265, 142, 253, 232, 400, 388, 378, 445, 16, - 111, 54, 52, 100, 184, 178, 160, 133, 257, 244, 228, 217, 385, 366, 715, 10, - 98, 48, 91, 88, 165, 157, 148, 261, 248, 407, 397, 372, 380, 889, 884, 8, - 85, 84, 81, 159, 156, 143, 260, 249, 427, 401, 392, 383, 727, 713, 708, 7, - 154, 76, 73, 141, 131, 256, 245, 426, 406, 394, 384, 735, 359, 710, 352, 11, - 139, 129, 67, 125, 247, 233, 229, 219, 393, 743, 737, 720, 885, 882, 439, 4, - 243, 120, 118, 115, 227, 223, 396, 746, 742, 736, 721, 712, 706, 223, 436, 6, - 202, 224, 222, 218, 216, 389, 386, 381, 364, 888, 443, 707, 440, 437, 1728, 4, - 747, 211, 210, 208, 370, 379, 734, 723, 714, 1735, 883, 877, 876, 3459, 865, 2, - 377, 369, 102, 187, 726, 722, 358, 711, 709, 866, 1734, 871, 3458, 870, 434, 0, - 12, 10, 7, 11, 10, 17, 11, 9, 13, 12, 10, 7, 5, 3, 1, 3 -}; - -static const uint16_t t24HB[] = { - 15, 13, 46, 80, 146, 262, 248, 434, 426, 669, 653, 649, 621, 517, 1032, 88, - 14, 12, 21, 38, 71, 130, 122, 216, 209, 198, 327, 345, 319, 297, 279, 42, - 47, 22, 41, 74, 68, 128, 120, 221, 207, 194, 182, 340, 315, 295, 541, 18, - 81, 39, 75, 70, 134, 125, 116, 220, 204, 190, 178, 325, 311, 293, 271, 16, - 147, 72, 69, 135, 127, 118, 112, 210, 200, 188, 352, 323, 306, 285, 540, 14, - 263, 66, 129, 126, 119, 114, 214, 202, 192, 180, 341, 317, 301, 281, 262, 12, - 249, 123, 121, 117, 113, 215, 206, 195, 185, 347, 330, 308, 291, 272, 520, 10, - 435, 115, 111, 109, 211, 203, 196, 187, 353, 332, 313, 298, 283, 531, 381, 17, - 427, 212, 208, 205, 201, 193, 186, 177, 169, 320, 303, 286, 268, 514, 377, 16, - 335, 199, 197, 191, 189, 181, 174, 333, 321, 305, 289, 275, 521, 379, 371, 11, - 668, 184, 183, 179, 175, 344, 331, 314, 304, 290, 277, 530, 383, 373, 366, 10, - 652, 346, 171, 168, 164, 318, 309, 299, 287, 276, 263, 513, 375, 368, 362, 6, - 648, 322, 316, 312, 307, 302, 292, 284, 269, 261, 512, 376, 370, 364, 359, 4, - 620, 300, 296, 294, 288, 282, 273, 266, 515, 380, 374, 369, 365, 361, 357, 2, - 1033, 280, 278, 274, 267, 264, 259, 382, 378, 372, 367, 363, 360, 358, 356, 0, - 43, 20, 19, 17, 15, 13, 11, 9, 7, 6, 4, 7, 5, 3, 1, 3 -}; - -static const uint16_t t32HB[] = { - 1 << 0, 5 << 1, 4 << 1, 5 << 2, 6 << 1, 5 << 2, 4 << 2, 4 << 3, - 7 << 1, 3 << 2, 6 << 2, 0 << 3, 7 << 2, 2 << 3, 3 << 3, 1 << 4 -}; - -static const uint16_t t33HB[] = { - 15 << 0, 14 << 1, 13 << 1, 12 << 2, 11 << 1, 10 << 2, 9 << 2, 8 << 3, - 7 << 1, 6 << 2, 5 << 2, 4 << 3, 3 << 2, 2 << 3, 1 << 3, 0 << 4 -}; - - -const uint8_t t1l[] = { - 1, 4, - 3, 5 -}; - -static const uint8_t t2l[] = { - 1, 4, 7, - 4, 5, 7, - 6, 7, 8 -}; - -static const uint8_t t3l[] = { - 2, 3, 7, - 4, 4, 7, - 6, 7, 8 -}; - -static const uint8_t t5l[] = { - 1, 4, 7, 8, - 4, 5, 8, 9, - 7, 8, 9, 10, - 8, 8, 9, 10 -}; - -static const uint8_t t6l[] = { - 3, 4, 6, 8, - 4, 4, 6, 7, - 5, 6, 7, 8, - 7, 7, 8, 9 -}; - -static const uint8_t t7l[] = { - 1, 4, 7, 9, 9, 10, - 4, 6, 8, 9, 9, 10, - 7, 7, 9, 10, 10, 11, - 8, 9, 10, 11, 11, 11, - 8, 9, 10, 11, 11, 12, - 9, 10, 11, 12, 12, 12 -}; - -static const uint8_t t8l[] = { - 2, 4, 7, 9, 9, 10, - 4, 4, 6, 10, 10, 10, - 7, 6, 8, 10, 10, 11, - 9, 10, 10, 11, 11, 12, - 9, 9, 10, 11, 12, 12, - 10, 10, 11, 11, 13, 13 -}; - -static const uint8_t t9l[] = { - 3, 4, 6, 7, 9, 10, - 4, 5, 6, 7, 8, 10, - 5, 6, 7, 8, 9, 10, - 7, 7, 8, 9, 9, 10, - 8, 8, 9, 9, 10, 11, - 9, 9, 10, 10, 11, 11 -}; - -static const uint8_t t10l[] = { - 1, 4, 7, 9, 10, 10, 10, 11, - 4, 6, 8, 9, 10, 11, 10, 10, - 7, 8, 9, 10, 11, 12, 11, 11, - 8, 9, 10, 11, 12, 12, 11, 12, - 9, 10, 11, 12, 12, 12, 12, 12, - 10, 11, 12, 12, 13, 13, 12, 13, - 9, 10, 11, 12, 12, 12, 13, 13, - 10, 10, 11, 12, 12, 13, 13, 13 -}; - -static const uint8_t t11l[] = { - 2, 4, 6, 8, 9, 10, 9, 10, - 4, 5, 6, 8, 10, 10, 9, 10, - 6, 7, 8, 9, 10, 11, 10, 10, - 8, 8, 9, 11, 10, 12, 10, 11, - 9, 10, 10, 11, 11, 12, 11, 12, - 9, 10, 11, 12, 12, 13, 12, 13, - 9, 9, 9, 10, 11, 12, 12, 12, - 9, 9, 10, 11, 12, 12, 12, 12 -}; - -static const uint8_t t12l[] = { - 4, 4, 6, 8, 9, 10, 10, 10, - 4, 5, 6, 7, 9, 9, 10, 10, - 6, 6, 7, 8, 9, 10, 9, 10, - 7, 7, 8, 8, 9, 10, 10, 10, - 8, 8, 9, 9, 10, 10, 10, 11, - 9, 9, 10, 10, 10, 11, 10, 11, - 9, 9, 9, 10, 10, 11, 11, 12, - 10, 10, 10, 11, 11, 11, 11, 12 -}; - -static const uint8_t t13l[] = { - 1, 5, 7, 8, 9, 10, 10, 11, 10, 11, 12, 12, 13, 13, 14, 14, - 4, 6, 8, 9, 10, 10, 11, 11, 11, 11, 12, 12, 13, 14, 14, 14, - 7, 8, 9, 10, 11, 11, 12, 12, 11, 12, 12, 13, 13, 14, 15, 15, - 8, 9, 10, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14, 15, 15, - 9, 9, 11, 11, 12, 12, 13, 13, 12, 13, 13, 14, 14, 15, 15, 16, - 10, 10, 11, 12, 12, 12, 13, 13, 13, 13, 14, 13, 15, 15, 16, 16, - 10, 11, 12, 12, 13, 13, 13, 13, 13, 14, 14, 14, 15, 15, 16, 16, - 11, 11, 12, 13, 13, 13, 14, 14, 14, 14, 15, 15, 15, 16, 18, 18, - 10, 10, 11, 12, 12, 13, 13, 14, 14, 14, 14, 15, 15, 16, 17, 17, - 11, 11, 12, 12, 13, 13, 13, 15, 14, 15, 15, 16, 16, 16, 18, 17, - 11, 12, 12, 13, 13, 14, 14, 15, 14, 15, 16, 15, 16, 17, 18, 19, - 12, 12, 12, 13, 14, 14, 14, 14, 15, 15, 15, 16, 17, 17, 17, 18, - 12, 13, 13, 14, 14, 15, 14, 15, 16, 16, 17, 17, 17, 18, 18, 18, - 13, 13, 14, 15, 15, 15, 16, 16, 16, 16, 16, 17, 18, 17, 18, 18, - 14, 14, 14, 15, 15, 15, 17, 16, 16, 19, 17, 17, 17, 19, 18, 18, - 13, 14, 15, 16, 16, 16, 17, 16, 17, 17, 18, 18, 21, 20, 21, 18 -}; - -static const uint8_t t15l[] = { - 3, 5, 6, 8, 8, 9, 10, 10, 10, 11, 11, 12, 12, 12, 13, 14, - 5, 5, 7, 8, 9, 9, 10, 10, 10, 11, 11, 12, 12, 12, 13, 13, - 6, 7, 7, 8, 9, 9, 10, 10, 10, 11, 11, 12, 12, 13, 13, 13, - 7, 8, 8, 9, 9, 10, 10, 11, 11, 11, 12, 12, 12, 13, 13, 13, - 8, 8, 9, 9, 10, 10, 11, 11, 11, 11, 12, 12, 12, 13, 13, 13, - 9, 9, 9, 10, 10, 10, 11, 11, 11, 11, 12, 12, 13, 13, 13, 14, - 10, 9, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 13, 13, 14, 14, - 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 13, 14, - 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 14, 14, 14, - 10, 10, 11, 11, 11, 11, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, - 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 13, 13, 14, 15, 14, - 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, 15, - 12, 12, 11, 12, 12, 12, 13, 13, 13, 13, 13, 13, 14, 14, 15, 15, - 12, 12, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, 14, 14, 15, 15, - 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 14, 15, - 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 15, 15, 15, 15 -}; - -static const uint8_t t16_5l[] = { - 1, 5, 7, 9, 10, 10, 11, 11, 12, 12, 12, 13, 13, 13, 14, 11, - 4, 6, 8, 9, 10, 11, 11, 11, 12, 12, 12, 13, 14, 13, 14, 11, - 7, 8, 9, 10, 11, 11, 12, 12, 13, 12, 13, 13, 13, 14, 14, 12, - 9, 9, 10, 11, 11, 12, 12, 12, 13, 13, 14, 14, 14, 15, 15, 13, - 10, 10, 11, 11, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 12, - 10, 10, 11, 11, 12, 13, 13, 14, 13, 14, 14, 15, 15, 15, 16, 13, - 11, 11, 11, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 16, 13, - 11, 11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 15, 15, 17, 17, 13, - 11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 15, 15, 16, 16, 16, 13, - 12, 12, 12, 13, 13, 14, 14, 15, 15, 15, 15, 16, 15, 16, 15, 14, - 12, 13, 12, 13, 14, 14, 14, 14, 15, 16, 16, 16, 17, 17, 16, 13, - 13, 13, 13, 13, 14, 14, 15, 16, 16, 16, 16, 16, 16, 15, 16, 14, - 13, 14, 14, 14, 14, 15, 15, 15, 15, 17, 16, 16, 16, 16, 18, 14, - 15, 14, 14, 14, 15, 15, 16, 16, 16, 18, 17, 17, 17, 19, 17, 14, - 14, 15, 13, 14, 16, 16, 15, 16, 16, 17, 18, 17, 19, 17, 16, 14, - 11, 11, 11, 12, 12, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 12 -}; - -static const uint8_t t16l[] = { - 1, 5, 7, 9, 10, 10, 11, 11, 12, 12, 12, 13, 13, 13, 14, 10, - 4, 6, 8, 9, 10, 11, 11, 11, 12, 12, 12, 13, 14, 13, 14, 10, - 7, 8, 9, 10, 11, 11, 12, 12, 13, 12, 13, 13, 13, 14, 14, 11, - 9, 9, 10, 11, 11, 12, 12, 12, 13, 13, 14, 14, 14, 15, 15, 12, - 10, 10, 11, 11, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 11, - 10, 10, 11, 11, 12, 13, 13, 14, 13, 14, 14, 15, 15, 15, 16, 12, - 11, 11, 11, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 16, 12, - 11, 11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 15, 15, 17, 17, 12, - 11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 15, 15, 16, 16, 16, 12, - 12, 12, 12, 13, 13, 14, 14, 15, 15, 15, 15, 16, 15, 16, 15, 13, - 12, 13, 12, 13, 14, 14, 14, 14, 15, 16, 16, 16, 17, 17, 16, 12, - 13, 13, 13, 13, 14, 14, 15, 16, 16, 16, 16, 16, 16, 15, 16, 13, - 13, 14, 14, 14, 14, 15, 15, 15, 15, 17, 16, 16, 16, 16, 18, 13, - 15, 14, 14, 14, 15, 15, 16, 16, 16, 18, 17, 17, 17, 19, 17, 13, - 14, 15, 13, 14, 16, 16, 15, 16, 16, 17, 18, 17, 19, 17, 16, 13, - 10, 10, 10, 11, 11, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 10 -}; - -static const uint8_t t24l[] = { - 4, 5, 7, 8, 9, 10, 10, 11, 11, 12, 12, 12, 12, 12, 13, 10, - 5, 6, 7, 8, 9, 10, 10, 11, 11, 11, 12, 12, 12, 12, 12, 10, - 7, 7, 8, 9, 9, 10, 10, 11, 11, 11, 11, 12, 12, 12, 13, 9, - 8, 8, 9, 9, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 9, - 9, 9, 9, 10, 10, 10, 10, 11, 11, 11, 12, 12, 12, 12, 13, 9, - 10, 9, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 12, 9, - 10, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 9, - 11, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 10, - 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 10, - 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 13, 10, - 12, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 10, - 12, 12, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 10, - 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 10, - 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 10, - 13, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 10, - 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 6 -}; - -const uint8_t t32l[] = { - 1 + 0, 4 + 1, 4 + 1, 5 + 2, 4 + 1, 6 + 2, 5 + 2, 6 + 3, - 4 + 1, 5 + 2, 5 + 2, 6 + 3, 5 + 2, 6 + 3, 6 + 3, 6 + 4 -}; - -const uint8_t t33l[] = { - 4 + 0, 4 + 1, 4 + 1, 4 + 2, 4 + 1, 4 + 2, 4 + 2, 4 + 3, - 4 + 1, 4 + 2, 4 + 2, 4 + 3, 4 + 2, 4 + 3, 4 + 3, 4 + 4 -}; - - -const struct huffcodetab ht[HTN] = { - /* xlen, linmax, table, hlen */ - {0, 0, NULL, NULL}, - {2, 0, t1HB, t1l}, - {3, 0, t2HB, t2l}, - {3, 0, t3HB, t3l}, - {0, 0, NULL, NULL}, /* Apparently not used */ - {4, 0, t5HB, t5l}, - {4, 0, t6HB, t6l}, - {6, 0, t7HB, t7l}, - {6, 0, t8HB, t8l}, - {6, 0, t9HB, t9l}, - {8, 0, t10HB, t10l}, - {8, 0, t11HB, t11l}, - {8, 0, t12HB, t12l}, - {16, 0, t13HB, t13l}, - {0, 0, NULL, t16_5l}, /* Apparently not used */ - {16, 0, t15HB, t15l}, - - {1, 1, t16HB, t16l}, - {2, 3, t16HB, t16l}, - {3, 7, t16HB, t16l}, - {4, 15, t16HB, t16l}, - {6, 63, t16HB, t16l}, - {8, 255, t16HB, t16l}, - {10, 1023, t16HB, t16l}, - {13, 8191, t16HB, t16l}, - - {4, 15, t24HB, t24l}, - {5, 31, t24HB, t24l}, - {6, 63, t24HB, t24l}, - {7, 127, t24HB, t24l}, - {8, 255, t24HB, t24l}, - {9, 511, t24HB, t24l}, - {11, 2047, t24HB, t24l}, - {13, 8191, t24HB, t24l}, - - {0, 0, t32HB, t32l}, - {0, 0, t33HB, t33l}, -}; - - - - - -/* for (i = 0; i < 16*16; i++) { - * largetbl[i] = ((ht[16].hlen[i]) << 16) + ht[24].hlen[i]; - * } - */ -const uint32_t largetbl[16 * 16] = { - 0x010004, 0x050005, 0x070007, 0x090008, 0x0a0009, 0x0a000a, 0x0b000a, 0x0b000b, - 0x0c000b, 0x0c000c, 0x0c000c, 0x0d000c, 0x0d000c, 0x0d000c, 0x0e000d, 0x0a000a, - 0x040005, 0x060006, 0x080007, 0x090008, 0x0a0009, 0x0b000a, 0x0b000a, 0x0b000b, - 0x0c000b, 0x0c000b, 0x0c000c, 0x0d000c, 0x0e000c, 0x0d000c, 0x0e000c, 0x0a000a, - 0x070007, 0x080007, 0x090008, 0x0a0009, 0x0b0009, 0x0b000a, 0x0c000a, 0x0c000b, - 0x0d000b, 0x0c000b, 0x0d000b, 0x0d000c, 0x0d000c, 0x0e000c, 0x0e000d, 0x0b0009, - 0x090008, 0x090008, 0x0a0009, 0x0b0009, 0x0b000a, 0x0c000a, 0x0c000a, 0x0c000b, - 0x0d000b, 0x0d000b, 0x0e000b, 0x0e000c, 0x0e000c, 0x0f000c, 0x0f000c, 0x0c0009, - 0x0a0009, 0x0a0009, 0x0b0009, 0x0b000a, 0x0c000a, 0x0c000a, 0x0d000a, 0x0d000b, - 0x0d000b, 0x0e000b, 0x0e000c, 0x0e000c, 0x0f000c, 0x0f000c, 0x0f000d, 0x0b0009, - 0x0a000a, 0x0a0009, 0x0b000a, 0x0b000a, 0x0c000a, 0x0d000a, 0x0d000b, 0x0e000b, - 0x0d000b, 0x0e000b, 0x0e000c, 0x0f000c, 0x0f000c, 0x0f000c, 0x10000c, 0x0c0009, - 0x0b000a, 0x0b000a, 0x0b000a, 0x0c000a, 0x0d000a, 0x0d000b, 0x0d000b, 0x0d000b, - 0x0e000b, 0x0e000c, 0x0e000c, 0x0e000c, 0x0f000c, 0x0f000c, 0x10000d, 0x0c0009, - 0x0b000b, 0x0b000a, 0x0c000a, 0x0c000a, 0x0d000b, 0x0d000b, 0x0d000b, 0x0e000b, - 0x0e000c, 0x0f000c, 0x0f000c, 0x0f000c, 0x0f000c, 0x11000d, 0x11000d, 0x0c000a, - 0x0b000b, 0x0c000b, 0x0c000b, 0x0d000b, 0x0d000b, 0x0d000b, 0x0e000b, 0x0e000b, - 0x0f000b, 0x0f000c, 0x0f000c, 0x0f000c, 0x10000c, 0x10000d, 0x10000d, 0x0c000a, - 0x0c000b, 0x0c000b, 0x0c000b, 0x0d000b, 0x0d000b, 0x0e000b, 0x0e000b, 0x0f000c, - 0x0f000c, 0x0f000c, 0x0f000c, 0x10000c, 0x0f000d, 0x10000d, 0x0f000d, 0x0d000a, - 0x0c000c, 0x0d000b, 0x0c000b, 0x0d000b, 0x0e000b, 0x0e000c, 0x0e000c, 0x0e000c, - 0x0f000c, 0x10000c, 0x10000c, 0x10000d, 0x11000d, 0x11000d, 0x10000d, 0x0c000a, - 0x0d000c, 0x0d000c, 0x0d000b, 0x0d000b, 0x0e000b, 0x0e000c, 0x0f000c, 0x10000c, - 0x10000c, 0x10000c, 0x10000c, 0x10000d, 0x10000d, 0x0f000d, 0x10000d, 0x0d000a, - 0x0d000c, 0x0e000c, 0x0e000c, 0x0e000c, 0x0e000c, 0x0f000c, 0x0f000c, 0x0f000c, - 0x0f000c, 0x11000c, 0x10000d, 0x10000d, 0x10000d, 0x10000d, 0x12000d, 0x0d000a, - 0x0f000c, 0x0e000c, 0x0e000c, 0x0e000c, 0x0f000c, 0x0f000c, 0x10000c, 0x10000c, - 0x10000d, 0x12000d, 0x11000d, 0x11000d, 0x11000d, 0x13000d, 0x11000d, 0x0d000a, - 0x0e000d, 0x0f000c, 0x0d000c, 0x0e000c, 0x10000c, 0x10000c, 0x0f000c, 0x10000d, - 0x10000d, 0x11000d, 0x12000d, 0x11000d, 0x13000d, 0x11000d, 0x10000d, 0x0d000a, - 0x0a0009, 0x0a0009, 0x0a0009, 0x0b0009, 0x0b0009, 0x0c0009, 0x0c0009, 0x0c0009, - 0x0d0009, 0x0d0009, 0x0d0009, 0x0d000a, 0x0d000a, 0x0d000a, 0x0d000a, 0x0a0006 -}; - -/* for (i = 0; i < 3*3; i++) { - * table23[i] = ((ht[2].hlen[i]) << 16) + ht[3].hlen[i]; - * } - */ -const uint32_t table23[3 * 3] = { - 0x010002, 0x040003, 0x070007, - 0x040004, 0x050004, 0x070007, - 0x060006, 0x070007, 0x080008 -}; - -/* for (i = 0; i < 4*4; i++) { - * table56[i] = ((ht[5].hlen[i]) << 16) + ht[6].hlen[i]; - * } - */ -const uint32_t table56[4 * 4] = { - 0x010003, 0x040004, 0x070006, 0x080008, 0x040004, 0x050004, 0x080006, 0x090007, - 0x070005, 0x080006, 0x090007, 0x0a0008, 0x080007, 0x080007, 0x090008, 0x0a0009 -}; - - - -/* - * 0: MPEG-2 LSF - * 1: MPEG-1 - * 2: MPEG-2.5 LSF FhG extention (1995-07-11 shn) - */ - -typedef enum { - MPEG_2 = 0, - MPEG_1 = 1, - MPEG_25 = 2 -} MPEG_t; - -const int bitrate_table[3][16] = { - {0, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 144, 160, -1}, /* MPEG 2 */ - {0, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, -1}, /* MPEG 1 */ - {0, 8, 16, 24, 32, 40, 48, 56, 64, -1, -1, -1, -1, -1, -1, -1}, /* MPEG 2.5 */ -}; - -const int samplerate_table[3][4] = { - {22050, 24000, 16000, -1}, /* MPEG 2 */ - {44100, 48000, 32000, -1}, /* MPEG 1 */ - {11025, 12000, 8000, -1}, /* MPEG 2.5 */ -}; - -int -lame_get_bitrate(int mpeg_version, int table_index) -{ - if (0 <= mpeg_version && mpeg_version <= 2) { - if (0 <= table_index && table_index <= 15) { - return bitrate_table[mpeg_version][table_index]; - } - } - return -1; -} - -int -lame_get_samplerate(int mpeg_version, int table_index) -{ - if (0 <= mpeg_version && mpeg_version <= 2) { - if (0 <= table_index && table_index <= 3) { - return samplerate_table[mpeg_version][table_index]; - } - } - return -1; -} - - -/* This is the scfsi_band table from 2.4.2.7 of the IS */ -const int scfsi_band[5] = { 0, 6, 11, 16, 21 }; - -/* end of tables.c */ diff --git a/lib-src/lame/libmp3lame/tables.h b/lib-src/lame/libmp3lame/tables.h deleted file mode 100644 index 0dd7deb20..000000000 --- a/lib-src/lame/libmp3lame/tables.h +++ /dev/null @@ -1,95 +0,0 @@ -/* - * MPEG layer 3 tables include file - * - * Copyright (c) 1999 Albert L Faber - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_TABLES_H -#define LAME_TABLES_H - -#if 0 -typedef struct { - unsigned char no; - unsigned char width; - unsigned char minval_2; - float quiet_thr; - float norm; - float bark; -} type1_t; - -typedef struct { - unsigned char no; - unsigned char width; - float quiet_thr; - float norm; - float SNR; - float bark; -} type2_t; - -typedef struct { - unsigned int no:5; - unsigned int cbw:3; - unsigned int bu:6; - unsigned int bo:6; - unsigned int w1_576:10; - unsigned int w2_576:10; -} type34_t; - -typedef struct { - size_t len1; - const type1_t *const tab1; - size_t len2; - const type2_t *const tab2; - size_t len3; - const type34_t *const tab3; - size_t len4; - const type34_t *const tab4; -} type5_t; - -extern const type5_t table5[6]; - -#endif - -#define HTN 34 - -struct huffcodetab { - const unsigned int xlen; /* max. x-index+ */ - const unsigned int linmax; /* max number to be stored in linbits */ - const uint16_t *table; /* pointer to array[xlen][ylen] */ - const uint8_t *hlen; /* pointer to array[xlen][ylen] */ -}; - -extern const struct huffcodetab ht[HTN]; - /* global memory block */ - /* array of all huffcodtable headers */ - /* 0..31 Huffman code table 0..31 */ - /* 32,33 count1-tables */ - -extern const uint8_t t32l[]; -extern const uint8_t t33l[]; - -extern const uint32_t largetbl[16 * 16]; -extern const uint32_t table23[3 * 3]; -extern const uint32_t table56[4 * 4]; - -extern const int scfsi_band[5]; - -extern const int bitrate_table [3][16]; -extern const int samplerate_table [3][ 4]; - -#endif /* LAME_TABLES_H */ diff --git a/lib-src/lame/libmp3lame/takehiro.c b/lib-src/lame/libmp3lame/takehiro.c deleted file mode 100644 index 67aba1be2..000000000 --- a/lib-src/lame/libmp3lame/takehiro.c +++ /dev/null @@ -1,1375 +0,0 @@ -/* - * MP3 huffman table selecting and bit counting - * - * Copyright (c) 1999-2005 Takehiro TOMINAGA - * Copyright (c) 2002-2005 Gabriel Bouvigne - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: takehiro.c,v 1.80 2017/09/06 15:07:30 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "quantize_pvt.h" -#include "tables.h" - - -static const struct { - const int region0_count; - const int region1_count; -} subdv_table[23] = { - { - 0, 0}, /* 0 bands */ - { - 0, 0}, /* 1 bands */ - { - 0, 0}, /* 2 bands */ - { - 0, 0}, /* 3 bands */ - { - 0, 0}, /* 4 bands */ - { - 0, 1}, /* 5 bands */ - { - 1, 1}, /* 6 bands */ - { - 1, 1}, /* 7 bands */ - { - 1, 2}, /* 8 bands */ - { - 2, 2}, /* 9 bands */ - { - 2, 3}, /* 10 bands */ - { - 2, 3}, /* 11 bands */ - { - 3, 4}, /* 12 bands */ - { - 3, 4}, /* 13 bands */ - { - 3, 4}, /* 14 bands */ - { - 4, 5}, /* 15 bands */ - { - 4, 5}, /* 16 bands */ - { - 4, 6}, /* 17 bands */ - { - 5, 6}, /* 18 bands */ - { - 5, 6}, /* 19 bands */ - { - 5, 7}, /* 20 bands */ - { - 6, 7}, /* 21 bands */ - { - 6, 7}, /* 22 bands */ -}; - - - - - -/********************************************************************* - * nonlinear quantization of xr - * More accurate formula than the ISO formula. Takes into account - * the fact that we are quantizing xr -> ix, but we want ix^4/3 to be - * as close as possible to x^4/3. (taking the nearest int would mean - * ix is as close as possible to xr, which is different.) - * - * From Segher Boessenkool 11/1999 - * - * 09/2000: ASM code removed in favor of IEEE754 hack by Takehiro - * Tominaga. If you need the ASM code, check CVS circa Aug 2000. - * - * 01/2004: Optimizations by Gabriel Bouvigne - *********************************************************************/ - - - - - -static void -quantize_lines_xrpow_01(unsigned int l, FLOAT istep, const FLOAT * xr, int *ix) -{ - const FLOAT compareval0 = (1.0f - 0.4054f) / istep; - unsigned int i; - - assert(l > 0); - assert(l % 2 == 0); - for (i = 0; i < l; i += 2) { - FLOAT const xr_0 = xr[i+0]; - FLOAT const xr_1 = xr[i+1]; - int const ix_0 = (compareval0 > xr_0) ? 0 : 1; - int const ix_1 = (compareval0 > xr_1) ? 0 : 1; - ix[i+0] = ix_0; - ix[i+1] = ix_1; - } -} - - - -#ifdef TAKEHIRO_IEEE754_HACK - -typedef union { - float f; - int i; -} fi_union; - -#define MAGIC_FLOAT (65536*(128)) -#define MAGIC_INT 0x4b000000 - - -static void -quantize_lines_xrpow(unsigned int l, FLOAT istep, const FLOAT * xp, int *pi) -{ - fi_union *fi; - unsigned int remaining; - - assert(l > 0); - - fi = (fi_union *) pi; - - l = l >> 1; - remaining = l % 2; - l = l >> 1; - while (l--) { - double x0 = istep * xp[0]; - double x1 = istep * xp[1]; - double x2 = istep * xp[2]; - double x3 = istep * xp[3]; - - x0 += MAGIC_FLOAT; - fi[0].f = x0; - x1 += MAGIC_FLOAT; - fi[1].f = x1; - x2 += MAGIC_FLOAT; - fi[2].f = x2; - x3 += MAGIC_FLOAT; - fi[3].f = x3; - - fi[0].f = x0 + adj43asm[fi[0].i - MAGIC_INT]; - fi[1].f = x1 + adj43asm[fi[1].i - MAGIC_INT]; - fi[2].f = x2 + adj43asm[fi[2].i - MAGIC_INT]; - fi[3].f = x3 + adj43asm[fi[3].i - MAGIC_INT]; - - fi[0].i -= MAGIC_INT; - fi[1].i -= MAGIC_INT; - fi[2].i -= MAGIC_INT; - fi[3].i -= MAGIC_INT; - fi += 4; - xp += 4; - }; - if (remaining) { - double x0 = istep * xp[0]; - double x1 = istep * xp[1]; - - x0 += MAGIC_FLOAT; - fi[0].f = x0; - x1 += MAGIC_FLOAT; - fi[1].f = x1; - - fi[0].f = x0 + adj43asm[fi[0].i - MAGIC_INT]; - fi[1].f = x1 + adj43asm[fi[1].i - MAGIC_INT]; - - fi[0].i -= MAGIC_INT; - fi[1].i -= MAGIC_INT; - } - -} - - -#else - -/********************************************************************* - * XRPOW_FTOI is a macro to convert floats to ints. - * if XRPOW_FTOI(x) = nearest_int(x), then QUANTFAC(x)=adj43asm[x] - * ROUNDFAC= -0.0946 - * - * if XRPOW_FTOI(x) = floor(x), then QUANTFAC(x)=asj43[x] - * ROUNDFAC=0.4054 - * - * Note: using floor() or (int) is extremely slow. On machines where - * the TAKEHIRO_IEEE754_HACK code above does not work, it is worthwile - * to write some ASM for XRPOW_FTOI(). - *********************************************************************/ -#define XRPOW_FTOI(src,dest) ((dest) = (int)(src)) -#define QUANTFAC(rx) adj43[rx] -#define ROUNDFAC 0.4054 - - -static void -quantize_lines_xrpow(unsigned int l, FLOAT istep, const FLOAT * xr, int *ix) -{ - unsigned int remaining; - - assert(l > 0); - - l = l >> 1; - remaining = l % 2; - l = l >> 1; - while (l--) { - FLOAT x0, x1, x2, x3; - int rx0, rx1, rx2, rx3; - - x0 = *xr++ * istep; - x1 = *xr++ * istep; - XRPOW_FTOI(x0, rx0); - x2 = *xr++ * istep; - XRPOW_FTOI(x1, rx1); - x3 = *xr++ * istep; - XRPOW_FTOI(x2, rx2); - x0 += QUANTFAC(rx0); - XRPOW_FTOI(x3, rx3); - x1 += QUANTFAC(rx1); - XRPOW_FTOI(x0, *ix++); - x2 += QUANTFAC(rx2); - XRPOW_FTOI(x1, *ix++); - x3 += QUANTFAC(rx3); - XRPOW_FTOI(x2, *ix++); - XRPOW_FTOI(x3, *ix++); - }; - if (remaining) { - FLOAT x0, x1; - int rx0, rx1; - - x0 = *xr++ * istep; - x1 = *xr++ * istep; - XRPOW_FTOI(x0, rx0); - XRPOW_FTOI(x1, rx1); - x0 += QUANTFAC(rx0); - x1 += QUANTFAC(rx1); - XRPOW_FTOI(x0, *ix++); - XRPOW_FTOI(x1, *ix++); - } - -} - - - -#endif - - - -/********************************************************************* - * Quantization function - * This function will select which lines to quantize and call the - * proper quantization function - *********************************************************************/ - -static void -quantize_xrpow(const FLOAT * xp, int *pi, FLOAT istep, gr_info const *const cod_info, - calc_noise_data const *prev_noise) -{ - /* quantize on xr^(3/4) instead of xr */ - int sfb; - int sfbmax; - int j = 0; - int prev_data_use; - int *iData; - int accumulate = 0; - int accumulate01 = 0; - int *acc_iData; - const FLOAT *acc_xp; - - iData = pi; - acc_xp = xp; - acc_iData = iData; - - - /* Reusing previously computed data does not seems to work if global gain - is changed. Finding why it behaves this way would allow to use a cache of - previously computed values (let's 10 cached values per sfb) that would - probably provide a noticeable speedup */ - prev_data_use = (prev_noise && (cod_info->global_gain == prev_noise->global_gain)); - - if (cod_info->block_type == SHORT_TYPE) - sfbmax = 38; - else - sfbmax = 21; - - for (sfb = 0; sfb <= sfbmax; sfb++) { - int step = -1; - - if (prev_data_use || cod_info->block_type == NORM_TYPE) { - step = - cod_info->global_gain - - ((cod_info->scalefac[sfb] + (cod_info->preflag ? pretab[sfb] : 0)) - << (cod_info->scalefac_scale + 1)) - - cod_info->subblock_gain[cod_info->window[sfb]] * 8; - } - assert(cod_info->width[sfb] >= 0); - if (prev_data_use && (prev_noise->step[sfb] == step)) { - /* do not recompute this part, - but compute accumulated lines */ - if (accumulate) { - quantize_lines_xrpow(accumulate, istep, acc_xp, acc_iData); - accumulate = 0; - } - if (accumulate01) { - quantize_lines_xrpow_01(accumulate01, istep, acc_xp, acc_iData); - accumulate01 = 0; - } - } - else { /*should compute this part */ - int l; - l = cod_info->width[sfb]; - - if ((j + cod_info->width[sfb]) > cod_info->max_nonzero_coeff) { - /*do not compute upper zero part */ - int usefullsize; - usefullsize = cod_info->max_nonzero_coeff - j + 1; - memset(&pi[cod_info->max_nonzero_coeff], 0, - sizeof(int) * (576 - cod_info->max_nonzero_coeff)); - l = usefullsize; - - if (l < 0) { - l = 0; - } - - /* no need to compute higher sfb values */ - sfb = sfbmax + 1; - } - - /*accumulate lines to quantize */ - if (!accumulate && !accumulate01) { - acc_iData = iData; - acc_xp = xp; - } - if (prev_noise && - prev_noise->sfb_count1 > 0 && - sfb >= prev_noise->sfb_count1 && - prev_noise->step[sfb] > 0 && step >= prev_noise->step[sfb]) { - - if (accumulate) { - quantize_lines_xrpow(accumulate, istep, acc_xp, acc_iData); - accumulate = 0; - acc_iData = iData; - acc_xp = xp; - } - accumulate01 += l; - } - else { - if (accumulate01) { - quantize_lines_xrpow_01(accumulate01, istep, acc_xp, acc_iData); - accumulate01 = 0; - acc_iData = iData; - acc_xp = xp; - } - accumulate += l; - } - - if (l <= 0) { - /* rh: 20040215 - * may happen due to "prev_data_use" optimization - */ - if (accumulate01) { - quantize_lines_xrpow_01(accumulate01, istep, acc_xp, acc_iData); - accumulate01 = 0; - } - if (accumulate) { - quantize_lines_xrpow(accumulate, istep, acc_xp, acc_iData); - accumulate = 0; - } - - break; /* ends for-loop */ - } - } - if (sfb <= sfbmax) { - iData += cod_info->width[sfb]; - xp += cod_info->width[sfb]; - j += cod_info->width[sfb]; - } - } - if (accumulate) { /*last data part */ - quantize_lines_xrpow(accumulate, istep, acc_xp, acc_iData); - accumulate = 0; - } - if (accumulate01) { /*last data part */ - quantize_lines_xrpow_01(accumulate01, istep, acc_xp, acc_iData); - accumulate01 = 0; - } - -} - - - - -/*************************************************************************/ -/* ix_max */ -/*************************************************************************/ - -static int -ix_max(const int *ix, const int *end) -{ - int max1 = 0, max2 = 0; - - do { - int const x1 = *ix++; - int const x2 = *ix++; - if (max1 < x1) - max1 = x1; - - if (max2 < x2) - max2 = x2; - } while (ix < end); - if (max1 < max2) - max1 = max2; - return max1; -} - - - - - - - - -static int -count_bit_ESC(const int *ix, const int *const end, int t1, const int t2, unsigned int *const s) -{ - /* ESC-table is used */ - unsigned int const linbits = ht[t1].xlen * 65536u + ht[t2].xlen; - unsigned int sum = 0, sum2; - - do { - unsigned int x = *ix++; - unsigned int y = *ix++; - - if (x >= 15u) { - x = 15u; - sum += linbits; - } - if (y >= 15u) { - y = 15u; - sum += linbits; - } - x <<= 4u; - x += y; - sum += largetbl[x]; - } while (ix < end); - - sum2 = sum & 0xffffu; - sum >>= 16u; - - if (sum > sum2) { - sum = sum2; - t1 = t2; - } - - *s += sum; - return t1; -} - - -static int -count_bit_noESC(const int *ix, const int *end, int mx, unsigned int *s) -{ - /* No ESC-words */ - unsigned int sum1 = 0; - const uint8_t *const hlen1 = ht[1].hlen; - (void) mx; - - do { - unsigned int const x0 = *ix++; - unsigned int const x1 = *ix++; - sum1 += hlen1[ x0+x0 + x1 ]; - } while (ix < end); - - *s += sum1; - return 1; -} - - -static const int huf_tbl_noESC[] = { - 1, 2, 5, 7, 7, 10, 10, 13, 13, 13, 13, 13, 13, 13, 13 -}; - - -static int -count_bit_noESC_from2(const int *ix, const int *end, int max, unsigned int *s) -{ - int t1 = huf_tbl_noESC[max - 1]; - /* No ESC-words */ - const unsigned int xlen = ht[t1].xlen; - uint32_t const* table = (t1 == 2) ? &table23[0] : &table56[0]; - unsigned int sum = 0, sum2; - - do { - unsigned int const x0 = *ix++; - unsigned int const x1 = *ix++; - sum += table[ x0 * xlen + x1 ]; - } while (ix < end); - - sum2 = sum & 0xffffu; - sum >>= 16u; - - if (sum > sum2) { - sum = sum2; - t1++; - } - - *s += sum; - return t1; -} - - -inline static int -count_bit_noESC_from3(const int *ix, const int *end, int max, unsigned int * s) -{ - int t1 = huf_tbl_noESC[max - 1]; - /* No ESC-words */ - unsigned int sum1 = 0; - unsigned int sum2 = 0; - unsigned int sum3 = 0; - const unsigned int xlen = ht[t1].xlen; - const uint8_t *const hlen1 = ht[t1].hlen; - const uint8_t *const hlen2 = ht[t1 + 1].hlen; - const uint8_t *const hlen3 = ht[t1 + 2].hlen; - int t; - - do { - unsigned int x0 = *ix++; - unsigned int x1 = *ix++; - unsigned int x = x0 * xlen + x1; - sum1 += hlen1[x]; - sum2 += hlen2[x]; - sum3 += hlen3[x]; - } while (ix < end); - - t = t1; - if (sum1 > sum2) { - sum1 = sum2; - t++; - } - if (sum1 > sum3) { - sum1 = sum3; - t = t1 + 2; - } - *s += sum1; - - return t; -} - - -/*************************************************************************/ -/* choose table */ -/*************************************************************************/ - -/* - Choose the Huffman table that will encode ix[begin..end] with - the fewest bits. - - Note: This code contains knowledge about the sizes and characteristics - of the Huffman tables as defined in the IS (Table B.7), and will not work - with any arbitrary tables. -*/ -static int count_bit_null(const int* ix, const int* end, int max, unsigned int* s) -{ - (void) ix; - (void) end; - (void) max; - (void) s; - return 0; -} - -typedef int (*count_fnc)(const int* ix, const int* end, int max, unsigned int* s); - -static const count_fnc count_fncs[] = -{ &count_bit_null -, &count_bit_noESC -, &count_bit_noESC_from2 -, &count_bit_noESC_from2 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -, &count_bit_noESC_from3 -}; - -static int -choose_table_nonMMX(const int *ix, const int *const end, int *const _s) -{ - unsigned int* s = (unsigned int*)_s; - unsigned int max; - int choice, choice2; - max = ix_max(ix, end); - - if (max <= 15) { - return count_fncs[max](ix, end, max, s); - } - /* try tables with linbits */ - if (max > IXMAX_VAL) { - *s = LARGE_BITS; - return -1; - } - max -= 15u; - for (choice2 = 24; choice2 < 32; choice2++) { - if (ht[choice2].linmax >= max) { - break; - } - } - - for (choice = choice2 - 8; choice < 24; choice++) { - if (ht[choice].linmax >= max) { - break; - } - } - return count_bit_ESC(ix, end, choice, choice2, s); -} - - - -/*************************************************************************/ -/* count_bit */ -/*************************************************************************/ -int -noquant_count_bits(lame_internal_flags const *const gfc, - gr_info * const gi, calc_noise_data * prev_noise) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int bits = 0; - int i, a1, a2; - int const *const ix = gi->l3_enc; - - i = Min(576, ((gi->max_nonzero_coeff + 2) >> 1) << 1); - - if (prev_noise) - prev_noise->sfb_count1 = 0; - - /* Determine count1 region */ - for (; i > 1; i -= 2) - if (ix[i - 1] | ix[i - 2]) - break; - gi->count1 = i; - - /* Determines the number of bits to encode the quadruples. */ - a1 = a2 = 0; - for (; i > 3; i -= 4) { - int x4 = ix[i-4]; - int x3 = ix[i-3]; - int x2 = ix[i-2]; - int x1 = ix[i-1]; - int p; - /* hack to check if all values <= 1 */ - if ((unsigned int) (x4 | x3 | x2 | x1) > 1) - break; - - p = ((x4 * 2 + x3) * 2 + x2) * 2 + x1; - a1 += t32l[p]; - a2 += t33l[p]; - } - - bits = a1; - gi->count1table_select = 0; - if (a1 > a2) { - bits = a2; - gi->count1table_select = 1; - } - - gi->count1bits = bits; - gi->big_values = i; - if (i == 0) - return bits; - - if (gi->block_type == SHORT_TYPE) { - a1 = 3 * gfc->scalefac_band.s[3]; - if (a1 > gi->big_values) - a1 = gi->big_values; - a2 = gi->big_values; - - } - else if (gi->block_type == NORM_TYPE) { - assert(i <= 576); /* bv_scf has 576 entries (0..575) */ - a1 = gi->region0_count = gfc->sv_qnt.bv_scf[i - 2]; - a2 = gi->region1_count = gfc->sv_qnt.bv_scf[i - 1]; - - assert(a1 + a2 + 2 < SBPSY_l); - a2 = gfc->scalefac_band.l[a1 + a2 + 2]; - a1 = gfc->scalefac_band.l[a1 + 1]; - if (a2 < i) - gi->table_select[2] = gfc->choose_table(ix + a2, ix + i, &bits); - - } - else { - gi->region0_count = 7; - /*gi->region1_count = SBPSY_l - 7 - 1; */ - gi->region1_count = SBMAX_l - 1 - 7 - 1; - a1 = gfc->scalefac_band.l[7 + 1]; - a2 = i; - if (a1 > a2) { - a1 = a2; - } - } - - - /* have to allow for the case when bigvalues < region0 < region1 */ - /* (and region0, region1 are ignored) */ - a1 = Min(a1, i); - a2 = Min(a2, i); - - assert(a1 >= 0); - assert(a2 >= 0); - - /* Count the number of bits necessary to code the bigvalues region. */ - if (0 < a1) - gi->table_select[0] = gfc->choose_table(ix, ix + a1, &bits); - if (a1 < a2) - gi->table_select[1] = gfc->choose_table(ix + a1, ix + a2, &bits); - if (cfg->use_best_huffman == 2) { - gi->part2_3_length = bits; - best_huffman_divide(gfc, gi); - bits = gi->part2_3_length; - } - - - if (prev_noise) { - if (gi->block_type == NORM_TYPE) { - int sfb = 0; - while (gfc->scalefac_band.l[sfb] < gi->big_values) { - sfb++; - } - prev_noise->sfb_count1 = sfb; - } - } - - return bits; -} - -int -count_bits(lame_internal_flags const *const gfc, - const FLOAT * const xr, gr_info * const gi, calc_noise_data * prev_noise) -{ - int *const ix = gi->l3_enc; - - /* since quantize_xrpow uses table lookup, we need to check this first: */ - FLOAT const w = (IXMAX_VAL) / IPOW20(gi->global_gain); - - if (gi->xrpow_max > w) - return LARGE_BITS; - - quantize_xrpow(xr, ix, IPOW20(gi->global_gain), gi, prev_noise); - - if (gfc->sv_qnt.substep_shaping & 2) { - int sfb, j = 0; - /* 0.634521682242439 = 0.5946*2**(.5*0.1875) */ - int const gain = gi->global_gain + gi->scalefac_scale; - const FLOAT roundfac = 0.634521682242439 / IPOW20(gain); - for (sfb = 0; sfb < gi->sfbmax; sfb++) { - int const width = gi->width[sfb]; - assert(width >= 0); - if (!gfc->sv_qnt.pseudohalf[sfb]) { - j += width; - } - else { - int k; - for (k = j, j += width; k < j; ++k) { - ix[k] = (xr[k] >= roundfac) ? ix[k] : 0; - } - } - } - } - return noquant_count_bits(gfc, gi, prev_noise); -} - -/*********************************************************************** - re-calculate the best scalefac_compress using scfsi - the saved bits are kept in the bit reservoir. - **********************************************************************/ - - -inline static void -recalc_divide_init(const lame_internal_flags * const gfc, - gr_info const *cod_info, - int const *const ix, int r01_bits[], int r01_div[], int r0_tbl[], int r1_tbl[]) -{ - int r0, r1, bigv, r0t, r1t, bits; - - bigv = cod_info->big_values; - - for (r0 = 0; r0 <= 7 + 15; r0++) { - r01_bits[r0] = LARGE_BITS; - } - - for (r0 = 0; r0 < 16; r0++) { - int const a1 = gfc->scalefac_band.l[r0 + 1]; - int r0bits; - if (a1 >= bigv) - break; - r0bits = 0; - r0t = gfc->choose_table(ix, ix + a1, &r0bits); - - for (r1 = 0; r1 < 8; r1++) { - int const a2 = gfc->scalefac_band.l[r0 + r1 + 2]; - if (a2 >= bigv) - break; - - bits = r0bits; - r1t = gfc->choose_table(ix + a1, ix + a2, &bits); - if (r01_bits[r0 + r1] > bits) { - r01_bits[r0 + r1] = bits; - r01_div[r0 + r1] = r0; - r0_tbl[r0 + r1] = r0t; - r1_tbl[r0 + r1] = r1t; - } - } - } -} - -inline static void -recalc_divide_sub(const lame_internal_flags * const gfc, - const gr_info * cod_info2, - gr_info * const gi, - const int *const ix, - const int r01_bits[], const int r01_div[], const int r0_tbl[], const int r1_tbl[]) -{ - int bits, r2, a2, bigv, r2t; - - bigv = cod_info2->big_values; - - for (r2 = 2; r2 < SBMAX_l + 1; r2++) { - a2 = gfc->scalefac_band.l[r2]; - if (a2 >= bigv) - break; - - bits = r01_bits[r2 - 2] + cod_info2->count1bits; - if (gi->part2_3_length <= bits) - break; - - r2t = gfc->choose_table(ix + a2, ix + bigv, &bits); - if (gi->part2_3_length <= bits) - continue; - - memcpy(gi, cod_info2, sizeof(gr_info)); - gi->part2_3_length = bits; - gi->region0_count = r01_div[r2 - 2]; - gi->region1_count = r2 - 2 - r01_div[r2 - 2]; - gi->table_select[0] = r0_tbl[r2 - 2]; - gi->table_select[1] = r1_tbl[r2 - 2]; - gi->table_select[2] = r2t; - } -} - - - - -void -best_huffman_divide(const lame_internal_flags * const gfc, gr_info * const gi) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int i, a1, a2; - gr_info cod_info2; - int const *const ix = gi->l3_enc; - - int r01_bits[7 + 15 + 1]; - int r01_div[7 + 15 + 1]; - int r0_tbl[7 + 15 + 1]; - int r1_tbl[7 + 15 + 1]; - - - /* SHORT BLOCK stuff fails for MPEG2 */ - if (gi->block_type == SHORT_TYPE && cfg->mode_gr == 1) - return; - - - memcpy(&cod_info2, gi, sizeof(gr_info)); - if (gi->block_type == NORM_TYPE) { - recalc_divide_init(gfc, gi, ix, r01_bits, r01_div, r0_tbl, r1_tbl); - recalc_divide_sub(gfc, &cod_info2, gi, ix, r01_bits, r01_div, r0_tbl, r1_tbl); - } - - i = cod_info2.big_values; - if (i == 0 || (unsigned int) (ix[i - 2] | ix[i - 1]) > 1) - return; - - i = gi->count1 + 2; - if (i > 576) - return; - - /* Determines the number of bits to encode the quadruples. */ - memcpy(&cod_info2, gi, sizeof(gr_info)); - cod_info2.count1 = i; - a1 = a2 = 0; - - assert(i <= 576); - - for (; i > cod_info2.big_values; i -= 4) { - int const p = ((ix[i - 4] * 2 + ix[i - 3]) * 2 + ix[i - 2]) * 2 + ix[i - 1]; - a1 += t32l[p]; - a2 += t33l[p]; - } - cod_info2.big_values = i; - - cod_info2.count1table_select = 0; - if (a1 > a2) { - a1 = a2; - cod_info2.count1table_select = 1; - } - - cod_info2.count1bits = a1; - - if (cod_info2.block_type == NORM_TYPE) - recalc_divide_sub(gfc, &cod_info2, gi, ix, r01_bits, r01_div, r0_tbl, r1_tbl); - else { - /* Count the number of bits necessary to code the bigvalues region. */ - cod_info2.part2_3_length = a1; - a1 = gfc->scalefac_band.l[7 + 1]; - if (a1 > i) { - a1 = i; - } - if (a1 > 0) - cod_info2.table_select[0] = - gfc->choose_table(ix, ix + a1, (int *) &cod_info2.part2_3_length); - if (i > a1) - cod_info2.table_select[1] = - gfc->choose_table(ix + a1, ix + i, (int *) &cod_info2.part2_3_length); - if (gi->part2_3_length > cod_info2.part2_3_length) - memcpy(gi, &cod_info2, sizeof(gr_info)); - } -} - -static const int slen1_n[16] = { 1, 1, 1, 1, 8, 2, 2, 2, 4, 4, 4, 8, 8, 8, 16, 16 }; -static const int slen2_n[16] = { 1, 2, 4, 8, 1, 2, 4, 8, 2, 4, 8, 2, 4, 8, 4, 8 }; -const int slen1_tab[16] = { 0, 0, 0, 0, 3, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4 }; -const int slen2_tab[16] = { 0, 1, 2, 3, 0, 1, 2, 3, 1, 2, 3, 1, 2, 3, 2, 3 }; - -static void -scfsi_calc(int ch, III_side_info_t * l3_side) -{ - unsigned int i; - int s1, s2, c1, c2; - int sfb; - gr_info *const gi = &l3_side->tt[1][ch]; - gr_info const *const g0 = &l3_side->tt[0][ch]; - - for (i = 0; i < (sizeof(scfsi_band) / sizeof(int)) - 1; i++) { - for (sfb = scfsi_band[i]; sfb < scfsi_band[i + 1]; sfb++) { - if (g0->scalefac[sfb] != gi->scalefac[sfb] - && gi->scalefac[sfb] >= 0) - break; - } - if (sfb == scfsi_band[i + 1]) { - for (sfb = scfsi_band[i]; sfb < scfsi_band[i + 1]; sfb++) { - gi->scalefac[sfb] = -1; - } - l3_side->scfsi[ch][i] = 1; - } - } - - s1 = c1 = 0; - for (sfb = 0; sfb < 11; sfb++) { - if (gi->scalefac[sfb] == -1) - continue; - c1++; - if (s1 < gi->scalefac[sfb]) - s1 = gi->scalefac[sfb]; - } - - s2 = c2 = 0; - for (; sfb < SBPSY_l; sfb++) { - if (gi->scalefac[sfb] == -1) - continue; - c2++; - if (s2 < gi->scalefac[sfb]) - s2 = gi->scalefac[sfb]; - } - - for (i = 0; i < 16; i++) { - if (s1 < slen1_n[i] && s2 < slen2_n[i]) { - int const c = slen1_tab[i] * c1 + slen2_tab[i] * c2; - if (gi->part2_length > c) { - gi->part2_length = c; - gi->scalefac_compress = (int)i; - } - } - } -} - -/* -Find the optimal way to store the scalefactors. -Only call this routine after final scalefactors have been -chosen and the channel/granule will not be re-encoded. - */ -void -best_scalefac_store(const lame_internal_flags * gfc, - const int gr, const int ch, III_side_info_t * const l3_side) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - /* use scalefac_scale if we can */ - gr_info *const gi = &l3_side->tt[gr][ch]; - int sfb, i, j, l; - int recalc = 0; - - /* remove scalefacs from bands with ix=0. This idea comes - * from the AAC ISO docs. added mt 3/00 */ - /* check if l3_enc=0 */ - j = 0; - for (sfb = 0; sfb < gi->sfbmax; sfb++) { - int const width = gi->width[sfb]; - assert(width >= 0); - for (l = j, j += width; l < j; ++l) { - if (gi->l3_enc[l] != 0) - break; - } - if (l == j) - gi->scalefac[sfb] = recalc = -2; /* anything goes. */ - /* only best_scalefac_store and calc_scfsi - * know--and only they should know--about the magic number -2. - */ - } - - if (!gi->scalefac_scale && !gi->preflag) { - int s = 0; - for (sfb = 0; sfb < gi->sfbmax; sfb++) - if (gi->scalefac[sfb] > 0) - s |= gi->scalefac[sfb]; - - if (!(s & 1) && s != 0) { - for (sfb = 0; sfb < gi->sfbmax; sfb++) - if (gi->scalefac[sfb] > 0) - gi->scalefac[sfb] >>= 1; - - gi->scalefac_scale = recalc = 1; - } - } - - if (!gi->preflag && gi->block_type != SHORT_TYPE && cfg->mode_gr == 2) { - for (sfb = 11; sfb < SBPSY_l; sfb++) - if (gi->scalefac[sfb] < pretab[sfb] && gi->scalefac[sfb] != -2) - break; - if (sfb == SBPSY_l) { - for (sfb = 11; sfb < SBPSY_l; sfb++) - if (gi->scalefac[sfb] > 0) - gi->scalefac[sfb] -= pretab[sfb]; - - gi->preflag = recalc = 1; - } - } - - for (i = 0; i < 4; i++) - l3_side->scfsi[ch][i] = 0; - - if (cfg->mode_gr == 2 && gr == 1 - && l3_side->tt[0][ch].block_type != SHORT_TYPE - && l3_side->tt[1][ch].block_type != SHORT_TYPE) { - scfsi_calc(ch, l3_side); - recalc = 0; - } - for (sfb = 0; sfb < gi->sfbmax; sfb++) { - if (gi->scalefac[sfb] == -2) { - gi->scalefac[sfb] = 0; /* if anything goes, then 0 is a good choice */ - } - } - if (recalc) { - (void) scale_bitcount(gfc, gi); - } -} - - -#ifndef NDEBUG -static int -all_scalefactors_not_negative(int const *scalefac, int n) -{ - int i; - for (i = 0; i < n; ++i) { - if (scalefac[i] < 0) - return 0; - } - return 1; -} -#endif - - -/* number of bits used to encode scalefacs */ - -/* 18*slen1_tab[i] + 18*slen2_tab[i] */ -static const int scale_short[16] = { - 0, 18, 36, 54, 54, 36, 54, 72, 54, 72, 90, 72, 90, 108, 108, 126 -}; - -/* 17*slen1_tab[i] + 18*slen2_tab[i] */ -static const int scale_mixed[16] = { - 0, 18, 36, 54, 51, 35, 53, 71, 52, 70, 88, 69, 87, 105, 104, 122 -}; - -/* 11*slen1_tab[i] + 10*slen2_tab[i] */ -static const int scale_long[16] = { - 0, 10, 20, 30, 33, 21, 31, 41, 32, 42, 52, 43, 53, 63, 64, 74 -}; - - -/*************************************************************************/ -/* scale_bitcount */ -/*************************************************************************/ - -/* Also calculates the number of bits necessary to code the scalefactors. */ - -static int -mpeg1_scale_bitcount(const lame_internal_flags * gfc, gr_info * const cod_info) -{ - int k, sfb, max_slen1 = 0, max_slen2 = 0; - - /* maximum values */ - const int *tab; - int *const scalefac = cod_info->scalefac; - - (void) gfc; - assert(all_scalefactors_not_negative(scalefac, cod_info->sfbmax)); - - if (cod_info->block_type == SHORT_TYPE) { - tab = scale_short; - if (cod_info->mixed_block_flag) - tab = scale_mixed; - } - else { /* block_type == 1,2,or 3 */ - tab = scale_long; - if (!cod_info->preflag) { - for (sfb = 11; sfb < SBPSY_l; sfb++) - if (scalefac[sfb] < pretab[sfb]) - break; - - if (sfb == SBPSY_l) { - cod_info->preflag = 1; - for (sfb = 11; sfb < SBPSY_l; sfb++) - scalefac[sfb] -= pretab[sfb]; - } - } - } - - for (sfb = 0; sfb < cod_info->sfbdivide; sfb++) - if (max_slen1 < scalefac[sfb]) - max_slen1 = scalefac[sfb]; - - for (; sfb < cod_info->sfbmax; sfb++) - if (max_slen2 < scalefac[sfb]) - max_slen2 = scalefac[sfb]; - - /* from Takehiro TOMINAGA 10/99 - * loop over *all* posible values of scalefac_compress to find the - * one which uses the smallest number of bits. ISO would stop - * at first valid index */ - cod_info->part2_length = LARGE_BITS; - for (k = 0; k < 16; k++) { - if (max_slen1 < slen1_n[k] && max_slen2 < slen2_n[k] - && cod_info->part2_length > tab[k]) { - cod_info->part2_length = tab[k]; - cod_info->scalefac_compress = k; - } - } - return cod_info->part2_length == LARGE_BITS; -} - - - -/* - table of largest scalefactor values for MPEG2 -*/ -static const int max_range_sfac_tab[6][4] = { - {15, 15, 7, 7}, - {15, 15, 7, 0}, - {7, 3, 0, 0}, - {15, 31, 31, 0}, - {7, 7, 7, 0}, - {3, 3, 0, 0} -}; - - - - -/*************************************************************************/ -/* scale_bitcount_lsf */ -/*************************************************************************/ - -/* Also counts the number of bits to encode the scalefacs but for MPEG 2 */ -/* Lower sampling frequencies (24, 22.05 and 16 kHz.) */ - -/* This is reverse-engineered from section 2.4.3.2 of the MPEG2 IS, */ -/* "Audio Decoding Layer III" */ - -static int -mpeg2_scale_bitcount(const lame_internal_flags * gfc, gr_info * const cod_info) -{ - int table_number, row_in_table, partition, nr_sfb, window, over; - int i, sfb, max_sfac[4]; - const int *partition_table; - int const *const scalefac = cod_info->scalefac; - - /* - Set partition table. Note that should try to use table one, - but do not yet... - */ - if (cod_info->preflag) - table_number = 2; - else - table_number = 0; - - for (i = 0; i < 4; i++) - max_sfac[i] = 0; - - if (cod_info->block_type == SHORT_TYPE) { - row_in_table = 1; - partition_table = &nr_of_sfb_block[table_number][row_in_table][0]; - for (sfb = 0, partition = 0; partition < 4; partition++) { - nr_sfb = partition_table[partition] / 3; - for (i = 0; i < nr_sfb; i++, sfb++) - for (window = 0; window < 3; window++) - if (scalefac[sfb * 3 + window] > max_sfac[partition]) - max_sfac[partition] = scalefac[sfb * 3 + window]; - } - } - else { - row_in_table = 0; - partition_table = &nr_of_sfb_block[table_number][row_in_table][0]; - for (sfb = 0, partition = 0; partition < 4; partition++) { - nr_sfb = partition_table[partition]; - for (i = 0; i < nr_sfb; i++, sfb++) - if (scalefac[sfb] > max_sfac[partition]) - max_sfac[partition] = scalefac[sfb]; - } - } - - for (over = 0, partition = 0; partition < 4; partition++) { - if (max_sfac[partition] > max_range_sfac_tab[table_number][partition]) - over++; - } - if (!over) { - /* - Since no bands have been over-amplified, we can set scalefac_compress - and slen[] for the formatter - */ - static const int log2tab[] = { 0, 1, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4 }; - - int slen1, slen2, slen3, slen4; - - cod_info->sfb_partition_table = nr_of_sfb_block[table_number][row_in_table]; - for (partition = 0; partition < 4; partition++) - cod_info->slen[partition] = log2tab[max_sfac[partition]]; - - /* set scalefac_compress */ - slen1 = cod_info->slen[0]; - slen2 = cod_info->slen[1]; - slen3 = cod_info->slen[2]; - slen4 = cod_info->slen[3]; - - switch (table_number) { - case 0: - cod_info->scalefac_compress = (((slen1 * 5) + slen2) << 4) - + (slen3 << 2) - + slen4; - break; - - case 1: - cod_info->scalefac_compress = 400 + (((slen1 * 5) + slen2) << 2) - + slen3; - break; - - case 2: - cod_info->scalefac_compress = 500 + (slen1 * 3) + slen2; - break; - - default: - ERRORF(gfc, "intensity stereo not implemented yet\n"); - break; - } - } -#ifdef DEBUG - if (over) - ERRORF(gfc, "---WARNING !! Amplification of some bands over limits\n"); -#endif - if (!over) { - assert(cod_info->sfb_partition_table); - cod_info->part2_length = 0; - for (partition = 0; partition < 4; partition++) - cod_info->part2_length += - cod_info->slen[partition] * cod_info->sfb_partition_table[partition]; - } - return over; -} - - -int -scale_bitcount(const lame_internal_flags * gfc, gr_info * cod_info) -{ - if (gfc->cfg.mode_gr == 2) { - return mpeg1_scale_bitcount(gfc, cod_info); - } - else { - return mpeg2_scale_bitcount(gfc, cod_info); - } -} - - -#ifdef MMX_choose_table -extern int choose_table_MMX(const int *ix, const int *const end, int *const s); -#endif - -void -huffman_init(lame_internal_flags * const gfc) -{ - int i; - - gfc->choose_table = choose_table_nonMMX; - -#ifdef MMX_choose_table - if (gfc->CPU_features.MMX) { - gfc->choose_table = choose_table_MMX; - } -#endif - - for (i = 2; i <= 576; i += 2) { - int scfb_anz = 0, bv_index; - while (gfc->scalefac_band.l[++scfb_anz] < i); - - bv_index = subdv_table[scfb_anz].region0_count; - while (gfc->scalefac_band.l[bv_index + 1] > i) - bv_index--; - - if (bv_index < 0) { - /* this is an indication that everything is going to - be encoded as region0: bigvalues < region0 < region1 - so lets set region0, region1 to some value larger - than bigvalues */ - bv_index = subdv_table[scfb_anz].region0_count; - } - - gfc->sv_qnt.bv_scf[i - 2] = bv_index; - - bv_index = subdv_table[scfb_anz].region1_count; - while (gfc->scalefac_band.l[bv_index + gfc->sv_qnt.bv_scf[i - 2] + 2] > i) - bv_index--; - - if (bv_index < 0) { - bv_index = subdv_table[scfb_anz].region1_count; - } - - gfc->sv_qnt.bv_scf[i - 1] = bv_index; - } -} diff --git a/lib-src/lame/libmp3lame/util.c b/lib-src/lame/libmp3lame/util.c deleted file mode 100644 index 43b457cd3..000000000 --- a/lib-src/lame/libmp3lame/util.c +++ /dev/null @@ -1,1018 +0,0 @@ -/* - * lame utility library source file - * - * Copyright (c) 1999 Albert L Faber - * Copyright (c) 2000-2005 Alexander Leidinger - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: util.c,v 1.159 2017/09/06 15:07:30 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "tables.h" - -#define PRECOMPUTE -#if defined(__FreeBSD__) && !defined(__alpha__) -# include -#endif - - -/*********************************************************************** -* -* Global Function Definitions -* -***********************************************************************/ -/*empty and close mallocs in gfc */ - -void -free_id3tag(lame_internal_flags * const gfc) -{ - gfc->tag_spec.language[0] = 0; - if (gfc->tag_spec.title != 0) { - free(gfc->tag_spec.title); - gfc->tag_spec.title = 0; - } - if (gfc->tag_spec.artist != 0) { - free(gfc->tag_spec.artist); - gfc->tag_spec.artist = 0; - } - if (gfc->tag_spec.album != 0) { - free(gfc->tag_spec.album); - gfc->tag_spec.album = 0; - } - if (gfc->tag_spec.comment != 0) { - free(gfc->tag_spec.comment); - gfc->tag_spec.comment = 0; - } - - if (gfc->tag_spec.albumart != 0) { - free(gfc->tag_spec.albumart); - gfc->tag_spec.albumart = 0; - gfc->tag_spec.albumart_size = 0; - gfc->tag_spec.albumart_mimetype = MIMETYPE_NONE; - } - if (gfc->tag_spec.v2_head != 0) { - FrameDataNode *node = gfc->tag_spec.v2_head; - do { - void *p = node->dsc.ptr.b; - void *q = node->txt.ptr.b; - void *r = node; - node = node->nxt; - free(p); - free(q); - free(r); - } while (node != 0); - gfc->tag_spec.v2_head = 0; - gfc->tag_spec.v2_tail = 0; - } -} - - -static void -free_global_data(lame_internal_flags * gfc) -{ - if (gfc && gfc->cd_psy) { - if (gfc->cd_psy->l.s3) { - /* XXX allocated in psymodel_init() */ - free(gfc->cd_psy->l.s3); - } - if (gfc->cd_psy->s.s3) { - /* XXX allocated in psymodel_init() */ - free(gfc->cd_psy->s.s3); - } - free(gfc->cd_psy); - gfc->cd_psy = 0; - } -} - - -void -freegfc(lame_internal_flags * const gfc) -{ /* bit stream structure */ - int i; - - if (gfc == 0) return; - - for (i = 0; i <= 2 * BPC; i++) - if (gfc->sv_enc.blackfilt[i] != NULL) { - free(gfc->sv_enc.blackfilt[i]); - gfc->sv_enc.blackfilt[i] = NULL; - } - if (gfc->sv_enc.inbuf_old[0]) { - free(gfc->sv_enc.inbuf_old[0]); - gfc->sv_enc.inbuf_old[0] = NULL; - } - if (gfc->sv_enc.inbuf_old[1]) { - free(gfc->sv_enc.inbuf_old[1]); - gfc->sv_enc.inbuf_old[1] = NULL; - } - - if (gfc->bs.buf != NULL) { - free(gfc->bs.buf); - gfc->bs.buf = NULL; - } - - if (gfc->VBR_seek_table.bag) { - free(gfc->VBR_seek_table.bag); - gfc->VBR_seek_table.bag = NULL; - gfc->VBR_seek_table.size = 0; - } - if (gfc->ATH) { - free(gfc->ATH); - } - if (gfc->sv_rpg.rgdata) { - free(gfc->sv_rpg.rgdata); - } - if (gfc->sv_enc.in_buffer_0) { - free(gfc->sv_enc.in_buffer_0); - } - if (gfc->sv_enc.in_buffer_1) { - free(gfc->sv_enc.in_buffer_1); - } - free_id3tag(gfc); - -#ifdef DECODE_ON_THE_FLY - if (gfc->hip) { - hip_decode_exit(gfc->hip); - gfc->hip = 0; - } -#endif - - free_global_data(gfc); - - free(gfc); -} - -void -calloc_aligned(aligned_pointer_t * ptr, unsigned int size, unsigned int bytes) -{ - if (ptr) { - if (!ptr->pointer) { - ptr->pointer = malloc(size + bytes); - if (ptr->pointer != 0) { - memset(ptr->pointer, 0, size + bytes); - if (bytes > 0) { - ptr->aligned = (void *) ((((size_t) ptr->pointer + bytes - 1) / bytes) * bytes); - } - else { - ptr->aligned = ptr->pointer; - } - } - else { - ptr->aligned = 0; - } - } - } -} - -void -free_aligned(aligned_pointer_t * ptr) -{ - if (ptr) { - if (ptr->pointer) { - free(ptr->pointer); - ptr->pointer = 0; - ptr->aligned = 0; - } - } -} - -/*those ATH formulas are returning -their minimum value for input = -1*/ - -static FLOAT -ATHformula_GB(FLOAT f, FLOAT value, FLOAT f_min, FLOAT f_max) -{ - /* from Painter & Spanias - modified by Gabriel Bouvigne to better fit the reality - ath = 3.640 * pow(f,-0.8) - - 6.800 * exp(-0.6*pow(f-3.4,2.0)) - + 6.000 * exp(-0.15*pow(f-8.7,2.0)) - + 0.6* 0.001 * pow(f,4.0); - - - In the past LAME was using the Painter &Spanias formula. - But we had some recurrent problems with HF content. - We measured real ATH values, and found the older formula - to be inacurate in the higher part. So we made this new - formula and this solved most of HF problematic testcases. - The tradeoff is that in VBR mode it increases a lot the - bitrate. */ - - -/*this curve can be udjusted according to the VBR scale: -it adjusts from something close to Painter & Spanias -on V9 up to Bouvigne's formula for V0. This way the VBR -bitrate is more balanced according to the -V value.*/ - - FLOAT ath; - - /* the following Hack allows to ask for the lowest value */ - if (f < -.3) - f = 3410; - - f /= 1000; /* convert to khz */ - f = Max(f_min, f); - f = Min(f_max, f); - - ath = 3.640 * pow(f, -0.8) - - 6.800 * exp(-0.6 * pow(f - 3.4, 2.0)) - + 6.000 * exp(-0.15 * pow(f - 8.7, 2.0)) - + (0.6 + 0.04 * value) * 0.001 * pow(f, 4.0); - return ath; -} - - - -FLOAT -ATHformula(SessionConfig_t const *cfg, FLOAT f) -{ - FLOAT ath; - switch (cfg->ATHtype) { - case 0: - ath = ATHformula_GB(f, 9, 0.1f, 24.0f); - break; - case 1: - ath = ATHformula_GB(f, -1, 0.1f, 24.0f); /*over sensitive, should probably be removed */ - break; - case 2: - ath = ATHformula_GB(f, 0, 0.1f, 24.0f); - break; - case 3: - ath = ATHformula_GB(f, 1, 0.1f, 24.0f) + 6; /*modification of GB formula by Roel */ - break; - case 4: - ath = ATHformula_GB(f, cfg->ATHcurve, 0.1f, 24.0f); - break; - case 5: - ath = ATHformula_GB(f, cfg->ATHcurve, 3.41f, 16.1f); - break; - default: - ath = ATHformula_GB(f, 0, 0.1f, 24.0f); - break; - } - return ath; -} - -/* see for example "Zwicker: Psychoakustik, 1982; ISBN 3-540-11401-7 */ -FLOAT -freq2bark(FLOAT freq) -{ - /* input: freq in hz output: barks */ - if (freq < 0) - freq = 0; - freq = freq * 0.001; - return 13.0 * atan(.76 * freq) + 3.5 * atan(freq * freq / (7.5 * 7.5)); -} - -#if 0 -extern FLOAT freq2cbw(FLOAT freq); - -/* see for example "Zwicker: Psychoakustik, 1982; ISBN 3-540-11401-7 */ -FLOAT -freq2cbw(FLOAT freq) -{ - /* input: freq in hz output: critical band width */ - freq = freq * 0.001; - return 25 + 75 * pow(1 + 1.4 * (freq * freq), 0.69); -} - -#endif - - - - -#define ABS(A) (((A)>0) ? (A) : -(A)) - -int -FindNearestBitrate(int bRate, /* legal rates from 8 to 320 */ - int version, int samplerate) -{ /* MPEG-1 or MPEG-2 LSF */ - int bitrate; - int i; - - if (samplerate < 16000) - version = 2; - - bitrate = bitrate_table[version][1]; - - for (i = 2; i <= 14; i++) { - if (bitrate_table[version][i] > 0) { - if (ABS(bitrate_table[version][i] - bRate) < ABS(bitrate - bRate)) - bitrate = bitrate_table[version][i]; - } - } - return bitrate; -} - - - - - -#ifndef Min -#define Min(A, B) ((A) < (B) ? (A) : (B)) -#endif -#ifndef Max -#define Max(A, B) ((A) > (B) ? (A) : (B)) -#endif - - -/* Used to find table index when - * we need bitrate-based values - * determined using tables - * - * bitrate in kbps - * - * Gabriel Bouvigne 2002-11-03 - */ -int -nearestBitrateFullIndex(uint16_t bitrate) -{ - /* borrowed from DM abr presets */ - - const int full_bitrate_table[] = - { 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320 }; - - - int lower_range = 0, lower_range_kbps = 0, upper_range = 0, upper_range_kbps = 0; - - - int b; - - - /* We assume specified bitrate will be 320kbps */ - upper_range_kbps = full_bitrate_table[16]; - upper_range = 16; - lower_range_kbps = full_bitrate_table[16]; - lower_range = 16; - - /* Determine which significant bitrates the value specified falls between, - * if loop ends without breaking then we were correct above that the value was 320 - */ - for (b = 0; b < 16; b++) { - if ((Max(bitrate, full_bitrate_table[b + 1])) != bitrate) { - upper_range_kbps = full_bitrate_table[b + 1]; - upper_range = b + 1; - lower_range_kbps = full_bitrate_table[b]; - lower_range = (b); - break; /* We found upper range */ - } - } - - /* Determine which range the value specified is closer to */ - if ((upper_range_kbps - bitrate) > (bitrate - lower_range_kbps)) { - return lower_range; - } - return upper_range; -} - - - - - -/* map frequency to a valid MP3 sample frequency - * - * Robert Hegemann 2000-07-01 - */ -int -map2MP3Frequency(int freq) -{ - if (freq <= 8000) - return 8000; - if (freq <= 11025) - return 11025; - if (freq <= 12000) - return 12000; - if (freq <= 16000) - return 16000; - if (freq <= 22050) - return 22050; - if (freq <= 24000) - return 24000; - if (freq <= 32000) - return 32000; - if (freq <= 44100) - return 44100; - - return 48000; -} - -int -BitrateIndex(int bRate, /* legal rates from 32 to 448 kbps */ - int version, /* MPEG-1 or MPEG-2/2.5 LSF */ - int samplerate) -{ /* convert bitrate in kbps to index */ - int i; - if (samplerate < 16000) - version = 2; - for (i = 0; i <= 14; i++) { - if (bitrate_table[version][i] > 0) { - if (bitrate_table[version][i] == bRate) { - return i; - } - } - } - return -1; -} - -/* convert samp freq in Hz to index */ - -int -SmpFrqIndex(int sample_freq, int *const version) -{ - switch (sample_freq) { - case 44100: - *version = 1; - return 0; - case 48000: - *version = 1; - return 1; - case 32000: - *version = 1; - return 2; - case 22050: - *version = 0; - return 0; - case 24000: - *version = 0; - return 1; - case 16000: - *version = 0; - return 2; - case 11025: - *version = 0; - return 0; - case 12000: - *version = 0; - return 1; - case 8000: - *version = 0; - return 2; - default: - *version = 0; - return -1; - } -} - - -/***************************************************************************** -* -* End of bit_stream.c package -* -*****************************************************************************/ - - - - - - - - - - -/* resampling via FIR filter, blackman window */ -inline static FLOAT -blackman(FLOAT x, FLOAT fcn, int l) -{ - /* This algorithm from: - SIGNAL PROCESSING ALGORITHMS IN FORTRAN AND C - S.D. Stearns and R.A. David, Prentice-Hall, 1992 - */ - FLOAT bkwn, x2; - FLOAT const wcn = (PI * fcn); - - x /= l; - if (x < 0) - x = 0; - if (x > 1) - x = 1; - x2 = x - .5; - - bkwn = 0.42 - 0.5 * cos(2 * x * PI) + 0.08 * cos(4 * x * PI); - if (fabs(x2) < 1e-9) - return wcn / PI; - else - return (bkwn * sin(l * wcn * x2) / (PI * l * x2)); - - -} - - - - -/* gcd - greatest common divisor */ -/* Joint work of Euclid and M. Hendry */ - -static int -gcd(int i, int j) -{ - /* assert ( i > 0 && j > 0 ); */ - return j ? gcd(j, i % j) : i; -} - - - -static int -fill_buffer_resample(lame_internal_flags * gfc, - sample_t * outbuf, - int desired_len, sample_t const *inbuf, int len, int *num_used, int ch) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - EncStateVar_t *esv = &gfc->sv_enc; - double resample_ratio = (double)cfg->samplerate_in / (double)cfg->samplerate_out; - int BLACKSIZE; - FLOAT offset, xvalue; - int i, j = 0, k; - int filter_l; - FLOAT fcn, intratio; - FLOAT *inbuf_old; - int bpc; /* number of convolution functions to pre-compute */ - bpc = cfg->samplerate_out / gcd(cfg->samplerate_out, cfg->samplerate_in); - if (bpc > BPC) - bpc = BPC; - - intratio = (fabs(resample_ratio - floor(.5 + resample_ratio)) < FLT_EPSILON); - fcn = 1.00 / resample_ratio; - if (fcn > 1.00) - fcn = 1.00; - filter_l = 31; /* must be odd */ - filter_l += intratio; /* unless resample_ratio=int, it must be even */ - - - BLACKSIZE = filter_l + 1; /* size of data needed for FIR */ - - if (gfc->fill_buffer_resample_init == 0) { - esv->inbuf_old[0] = lame_calloc(sample_t, BLACKSIZE); - esv->inbuf_old[1] = lame_calloc(sample_t, BLACKSIZE); - for (i = 0; i <= 2 * bpc; ++i) - esv->blackfilt[i] = lame_calloc(sample_t, BLACKSIZE); - - esv->itime[0] = 0; - esv->itime[1] = 0; - - /* precompute blackman filter coefficients */ - for (j = 0; j <= 2 * bpc; j++) { - FLOAT sum = 0.; - offset = (j - bpc) / (2. * bpc); - for (i = 0; i <= filter_l; i++) - sum += esv->blackfilt[j][i] = blackman(i - offset, fcn, filter_l); - for (i = 0; i <= filter_l; i++) - esv->blackfilt[j][i] /= sum; - } - gfc->fill_buffer_resample_init = 1; - } - - inbuf_old = esv->inbuf_old[ch]; - - /* time of j'th element in inbuf = itime + j/ifreq; */ - /* time of k'th element in outbuf = j/ofreq */ - for (k = 0; k < desired_len; k++) { - double time0 = k * resample_ratio; /* time of k'th output sample */ - int joff; - - j = floor(time0 - esv->itime[ch]); - - /* check if we need more input data */ - if ((filter_l + j - filter_l / 2) >= len) - break; - - /* blackman filter. by default, window centered at j+.5(filter_l%2) */ - /* but we want a window centered at time0. */ - offset = (time0 - esv->itime[ch] - (j + .5 * (filter_l % 2))); - assert(fabs(offset) <= .501); - - /* find the closest precomputed window for this offset: */ - joff = floor((offset * 2 * bpc) + bpc + .5); - - xvalue = 0.; - for (i = 0; i <= filter_l; ++i) { - int const j2 = i + j - filter_l / 2; - sample_t y; - assert(j2 < len); - assert(j2 + BLACKSIZE >= 0); - y = (j2 < 0) ? inbuf_old[BLACKSIZE + j2] : inbuf[j2]; -#ifdef PRECOMPUTE - xvalue += y * esv->blackfilt[joff][i]; -#else - xvalue += y * blackman(i - offset, fcn, filter_l); /* very slow! */ -#endif - } - outbuf[k] = xvalue; - } - - - /* k = number of samples added to outbuf */ - /* last k sample used data from [j-filter_l/2,j+filter_l-filter_l/2] */ - - /* how many samples of input data were used: */ - *num_used = Min(len, filter_l + j - filter_l / 2); - - /* adjust our input time counter. Incriment by the number of samples used, - * then normalize so that next output sample is at time 0, next - * input buffer is at time itime[ch] */ - esv->itime[ch] += *num_used - k * resample_ratio; - - /* save the last BLACKSIZE samples into the inbuf_old buffer */ - if (*num_used >= BLACKSIZE) { - for (i = 0; i < BLACKSIZE; i++) - inbuf_old[i] = inbuf[*num_used + i - BLACKSIZE]; - } - else { - /* shift in *num_used samples into inbuf_old */ - int const n_shift = BLACKSIZE - *num_used; /* number of samples to shift */ - - /* shift n_shift samples by *num_used, to make room for the - * num_used new samples */ - for (i = 0; i < n_shift; ++i) - inbuf_old[i] = inbuf_old[i + *num_used]; - - /* shift in the *num_used samples */ - for (j = 0; i < BLACKSIZE; ++i, ++j) - inbuf_old[i] = inbuf[j]; - - assert(j == *num_used); - } - return k; /* return the number samples created at the new samplerate */ -} - -int -isResamplingNecessary(SessionConfig_t const* cfg) -{ - int const l = cfg->samplerate_out * 0.9995f; - int const h = cfg->samplerate_out * 1.0005f; - return (cfg->samplerate_in < l) || (h < cfg->samplerate_in) ? 1 : 0; -} - -/* copy in new samples from in_buffer into mfbuf, with resampling - if necessary. n_in = number of samples from the input buffer that - were used. n_out = number of samples copied into mfbuf */ - -void -fill_buffer(lame_internal_flags * gfc, - sample_t * const mfbuf[2], sample_t const * const in_buffer[2], int nsamples, int *n_in, int *n_out) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int mf_size = gfc->sv_enc.mf_size; - int framesize = 576 * cfg->mode_gr; - int nout, ch = 0; - int nch = cfg->channels_out; - - /* copy in new samples into mfbuf, with resampling if necessary */ - if (isResamplingNecessary(cfg)) { - do { - nout = - fill_buffer_resample(gfc, &mfbuf[ch][mf_size], - framesize, in_buffer[ch], nsamples, n_in, ch); - } while (++ch < nch); - *n_out = nout; - } - else { - nout = Min(framesize, nsamples); - do { - memcpy(&mfbuf[ch][mf_size], &in_buffer[ch][0], nout * sizeof(mfbuf[0][0])); - } while (++ch < nch); - *n_out = nout; - *n_in = nout; - } -} - - - - - - - -/*********************************************************************** -* -* Message Output -* -***********************************************************************/ - -void -lame_report_def(const char *format, va_list args) -{ - (void) vfprintf(stderr, format, args); - fflush(stderr); /* an debug function should flush immediately */ -} - -void -lame_report_fnc(lame_report_function print_f, const char *format, ...) -{ - if (print_f) { - va_list args; - va_start(args, format); - print_f(format, args); - va_end(args); - } -} - - -void -lame_debugf(const lame_internal_flags* gfc, const char *format, ...) -{ - if (gfc && gfc->report_dbg) { - va_list args; - va_start(args, format); - gfc->report_dbg(format, args); - va_end(args); - } -} - - -void -lame_msgf(const lame_internal_flags* gfc, const char *format, ...) -{ - if (gfc && gfc->report_msg) { - va_list args; - va_start(args, format); - gfc->report_msg(format, args); - va_end(args); - } -} - - -void -lame_errorf(const lame_internal_flags* gfc, const char *format, ...) -{ - if (gfc && gfc->report_err) { - va_list args; - va_start(args, format); - gfc->report_err(format, args); - va_end(args); - } -} - - - -/*********************************************************************** - * - * routines to detect CPU specific features like 3DNow, MMX, SSE - * - * donated by Frank Klemm - * added Robert Hegemann 2000-10-10 - * - ***********************************************************************/ - -#ifdef HAVE_NASM -extern int has_MMX_nasm(void); -extern int has_3DNow_nasm(void); -extern int has_SSE_nasm(void); -extern int has_SSE2_nasm(void); -#endif - -int -has_MMX(void) -{ -#ifdef HAVE_NASM - return has_MMX_nasm(); -#else - return 0; /* don't know, assume not */ -#endif -} - -int -has_3DNow(void) -{ -#ifdef HAVE_NASM - return has_3DNow_nasm(); -#else - return 0; /* don't know, assume not */ -#endif -} - -int -has_SSE(void) -{ -#ifdef HAVE_NASM - return has_SSE_nasm(); -#else -#if defined( _M_X64 ) || defined( MIN_ARCH_SSE ) - return 1; -#else - return 0; /* don't know, assume not */ -#endif -#endif -} - -int -has_SSE2(void) -{ -#ifdef HAVE_NASM - return has_SSE2_nasm(); -#else -#if defined( _M_X64 ) || defined( MIN_ARCH_SSE ) - return 1; -#else - return 0; /* don't know, assume not */ -#endif -#endif -} - -void -disable_FPE(void) -{ -/* extremly system dependent stuff, move to a lib to make the code readable */ -/*==========================================================================*/ - - - - /* - * Disable floating point exceptions - */ - - - - -#if defined(__FreeBSD__) && !defined(__alpha__) - { - /* seet floating point mask to the Linux default */ - fp_except_t mask; - mask = fpgetmask(); - /* if bit is set, we get SIGFPE on that error! */ - fpsetmask(mask & ~(FP_X_INV | FP_X_DZ)); - /* DEBUGF("FreeBSD mask is 0x%x\n",mask); */ - } -#endif - -#if defined(__riscos__) && !defined(ABORTFP) - /* Disable FPE's under RISC OS */ - /* if bit is set, we disable trapping that error! */ - /* _FPE_IVO : invalid operation */ - /* _FPE_DVZ : divide by zero */ - /* _FPE_OFL : overflow */ - /* _FPE_UFL : underflow */ - /* _FPE_INX : inexact */ - DisableFPETraps(_FPE_IVO | _FPE_DVZ | _FPE_OFL); -#endif - - /* - * Debugging stuff - * The default is to ignore FPE's, unless compiled with -DABORTFP - * so add code below to ENABLE FPE's. - */ - -#if defined(ABORTFP) -#if defined(_MSC_VER) - { -#if 0 - /* rh 061207 - the following fix seems to be a workaround for a problem in the - parent process calling LAME. It would be better to fix the broken - application => code disabled. - */ - - /* set affinity to a single CPU. Fix for EAC/lame on SMP systems from - "Todd Richmond" */ - SYSTEM_INFO si; - GetSystemInfo(&si); - SetProcessAffinityMask(GetCurrentProcess(), si.dwActiveProcessorMask); -#endif -#include - unsigned int mask; - mask = _controlfp(0, 0); - mask &= ~(_EM_OVERFLOW | _EM_UNDERFLOW | _EM_ZERODIVIDE | _EM_INVALID); - mask = _controlfp(mask, _MCW_EM); - } -#elif defined(__CYGWIN__) -# define _FPU_GETCW(cw) __asm__ ("fnstcw %0" : "=m" (*&cw)) -# define _FPU_SETCW(cw) __asm__ ("fldcw %0" : : "m" (*&cw)) - -# define _EM_INEXACT 0x00000020 /* inexact (precision) */ -# define _EM_UNDERFLOW 0x00000010 /* underflow */ -# define _EM_OVERFLOW 0x00000008 /* overflow */ -# define _EM_ZERODIVIDE 0x00000004 /* zero divide */ -# define _EM_INVALID 0x00000001 /* invalid */ - { - unsigned int mask; - _FPU_GETCW(mask); - /* Set the FPU control word to abort on most FPEs */ - mask &= ~(_EM_OVERFLOW | _EM_ZERODIVIDE | _EM_INVALID); - _FPU_SETCW(mask); - } -# elif defined(__linux__) - { - -# include -# ifndef _FPU_GETCW -# define _FPU_GETCW(cw) __asm__ ("fnstcw %0" : "=m" (*&cw)) -# endif -# ifndef _FPU_SETCW -# define _FPU_SETCW(cw) __asm__ ("fldcw %0" : : "m" (*&cw)) -# endif - - /* - * Set the Linux mask to abort on most FPE's - * if bit is set, we _mask_ SIGFPE on that error! - * mask &= ~( _FPU_MASK_IM | _FPU_MASK_ZM | _FPU_MASK_OM | _FPU_MASK_UM ); - */ - - unsigned int mask; - _FPU_GETCW(mask); - mask &= ~(_FPU_MASK_IM | _FPU_MASK_ZM | _FPU_MASK_OM); - _FPU_SETCW(mask); - } -#endif -#endif /* ABORTFP */ -} - - - - - -#ifdef USE_FAST_LOG -/*********************************************************************** - * - * Fast Log Approximation for log2, used to approximate every other log - * (log10 and log) - * maximum absolute error for log10 is around 10-6 - * maximum *relative* error can be high when x is almost 1 because error/log10(x) tends toward x/e - * - * use it if typical RESULT values are > 1e-5 (for example if x>1.00001 or x<0.99999) - * or if the relative precision in the domain around 1 is not important (result in 1 is exact and 0) - * - ***********************************************************************/ - - -#define LOG2_SIZE (512) -#define LOG2_SIZE_L2 (9) - -static ieee754_float32_t log_table[LOG2_SIZE + 1]; - - - -void -init_log_table(void) -{ - int j; - static int init = 0; - - /* Range for log2(x) over [1,2[ is [0,1[ */ - assert((1 << LOG2_SIZE_L2) == LOG2_SIZE); - - if (!init) { - for (j = 0; j < LOG2_SIZE + 1; j++) - log_table[j] = log(1.0f + j / (ieee754_float32_t) LOG2_SIZE) / log(2.0f); - } - init = 1; -} - - - -ieee754_float32_t -fast_log2(ieee754_float32_t x) -{ - ieee754_float32_t log2val, partial; - union { - ieee754_float32_t f; - int i; - } fi; - int mantisse; - fi.f = x; - mantisse = fi.i & 0x7fffff; - log2val = ((fi.i >> 23) & 0xFF) - 0x7f; - partial = (mantisse & ((1 << (23 - LOG2_SIZE_L2)) - 1)); - partial *= 1.0f / ((1 << (23 - LOG2_SIZE_L2))); - - - mantisse >>= (23 - LOG2_SIZE_L2); - - /* log2val += log_table[mantisse]; without interpolation the results are not good */ - log2val += log_table[mantisse] * (1.0f - partial) + log_table[mantisse + 1] * partial; - - return log2val; -} - -#else /* Don't use FAST_LOG */ - - -void -init_log_table(void) -{ -} - - -#endif - -/* end of util.c */ diff --git a/lib-src/lame/libmp3lame/util.h b/lib-src/lame/libmp3lame/util.h deleted file mode 100644 index 13f0cd42a..000000000 --- a/lib-src/lame/libmp3lame/util.h +++ /dev/null @@ -1,616 +0,0 @@ -/* - * lame utility library include file - * - * Copyright (c) 1999 Albert L Faber - * Copyright (c) 2008 Robert Hegemann - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_UTIL_H -#define LAME_UTIL_H - -#include "l3side.h" -#include "id3tag.h" -#include "lame_global_flags.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/*********************************************************************** -* -* Global Definitions -* -***********************************************************************/ - -#ifndef FALSE -#define FALSE 0 -#endif - -#ifndef TRUE -#define TRUE (!FALSE) -#endif - -#ifdef UINT_MAX -# define MAX_U_32_NUM UINT_MAX -#else -# define MAX_U_32_NUM 0xFFFFFFFF -#endif - -#ifndef PI -# ifdef M_PI -# define PI M_PI -# else -# define PI 3.14159265358979323846 -# endif -#endif - - -#ifdef M_LN2 -# define LOG2 M_LN2 -#else -# define LOG2 0.69314718055994530942 -#endif - -#ifdef M_LN10 -# define LOG10 M_LN10 -#else -# define LOG10 2.30258509299404568402 -#endif - - -#ifdef M_SQRT2 -# define SQRT2 M_SQRT2 -#else -# define SQRT2 1.41421356237309504880 -#endif - - -#define CRC16_POLYNOMIAL 0x8005 - -#define MAX_BITS_PER_CHANNEL 4095 -#define MAX_BITS_PER_GRANULE 7680 - -/* "bit_stream.h" Definitions */ -#define BUFFER_SIZE LAME_MAXMP3BUFFER - -#define Min(A, B) ((A) < (B) ? (A) : (B)) -#define Max(A, B) ((A) > (B) ? (A) : (B)) - -/* log/log10 approximations */ -#ifdef USE_FAST_LOG -#define FAST_LOG10(x) (fast_log2(x)*(LOG2/LOG10)) -#define FAST_LOG(x) (fast_log2(x)*LOG2) -#define FAST_LOG10_X(x,y) (fast_log2(x)*(LOG2/LOG10*(y))) -#define FAST_LOG_X(x,y) (fast_log2(x)*(LOG2*(y))) -#else -#define FAST_LOG10(x) log10(x) -#define FAST_LOG(x) log(x) -#define FAST_LOG10_X(x,y) (log10(x)*(y)) -#define FAST_LOG_X(x,y) (log(x)*(y)) -#endif - - - struct replaygain_data; -#ifndef replaygain_data_defined -#define replaygain_data_defined - typedef struct replaygain_data replaygain_t; -#endif - struct plotting_data; -#ifndef plotting_data_defined -#define plotting_data_defined - typedef struct plotting_data plotting_data; -#endif - -/*********************************************************************** -* -* Global Type Definitions -* -***********************************************************************/ - - typedef struct { - void *aligned; /* pointer to ie. 128 bit aligned memory */ - void *pointer; /* to use with malloc/free */ - } aligned_pointer_t; - - void calloc_aligned(aligned_pointer_t * ptr, unsigned int size, unsigned int bytes); - void free_aligned(aligned_pointer_t * ptr); - - - /* "bit_stream.h" Type Definitions */ - - typedef struct bit_stream_struc { - unsigned char *buf; /* bit stream buffer */ - int buf_size; /* size of buffer (in number of bytes) */ - int totbit; /* bit counter of bit stream */ - int buf_byte_idx; /* pointer to top byte in buffer */ - int buf_bit_idx; /* pointer to top bit of top byte in buffer */ - - /* format of file in rd mode (BINARY/ASCII) */ - } Bit_stream_struc; - - - - typedef struct { - int sum; /* what we have seen so far */ - int seen; /* how many frames we have seen in this chunk */ - int want; /* how many frames we want to collect into one chunk */ - int pos; /* actual position in our bag */ - int size; /* size of our bag */ - int *bag; /* pointer to our bag */ - unsigned int nVbrNumFrames; - unsigned long nBytesWritten; - /* VBR tag data */ - unsigned int TotalFrameSize; - } VBR_seek_info_t; - - - /** - * ATH related stuff, if something new ATH related has to be added, - * please plugg it here into the ATH_t struct - */ - typedef struct { - int use_adjust; /* method for the auto adjustment */ - FLOAT aa_sensitivity_p; /* factor for tuning the (sample power) - point below which adaptive threshold - of hearing adjustment occurs */ - FLOAT adjust_factor; /* lowering based on peak volume, 1 = no lowering */ - FLOAT adjust_limit; /* limit for dynamic ATH adjust */ - FLOAT decay; /* determined to lower x dB each second */ - FLOAT floor; /* lowest ATH value */ - FLOAT l[SBMAX_l]; /* ATH for sfbs in long blocks */ - FLOAT s[SBMAX_s]; /* ATH for sfbs in short blocks */ - FLOAT psfb21[PSFB21]; /* ATH for partitionned sfb21 in long blocks */ - FLOAT psfb12[PSFB12]; /* ATH for partitionned sfb12 in short blocks */ - FLOAT cb_l[CBANDS]; /* ATH for long block convolution bands */ - FLOAT cb_s[CBANDS]; /* ATH for short block convolution bands */ - FLOAT eql_w[BLKSIZE / 2]; /* equal loudness weights (based on ATH) */ - } ATH_t; - - /** - * PSY Model related stuff - */ - - typedef struct { - FLOAT masking_lower[CBANDS]; - FLOAT minval[CBANDS]; - FLOAT rnumlines[CBANDS]; - FLOAT mld_cb[CBANDS]; - FLOAT mld[Max(SBMAX_l,SBMAX_s)]; - FLOAT bo_weight[Max(SBMAX_l,SBMAX_s)]; /* band weight long scalefactor bands, at transition */ - FLOAT attack_threshold; /* short block tuning */ - int s3ind[CBANDS][2]; - int numlines[CBANDS]; - int bm[Max(SBMAX_l,SBMAX_s)]; - int bo[Max(SBMAX_l,SBMAX_s)]; - int npart; - int n_sb; /* SBMAX_l or SBMAX_s */ - FLOAT *s3; - } PsyConst_CB2SB_t; - - - /** - * global data constants - */ - typedef struct { - FLOAT window[BLKSIZE], window_s[BLKSIZE_s / 2]; - PsyConst_CB2SB_t l; - PsyConst_CB2SB_t s; - PsyConst_CB2SB_t l_to_s; - FLOAT attack_threshold[4]; - FLOAT decay; - int force_short_block_calc; - } PsyConst_t; - - - typedef struct { - - FLOAT nb_l1[4][CBANDS], nb_l2[4][CBANDS]; - FLOAT nb_s1[4][CBANDS], nb_s2[4][CBANDS]; - - III_psy_xmin thm[4]; - III_psy_xmin en[4]; - - /* loudness calculation (for adaptive threshold of hearing) */ - FLOAT loudness_sq_save[2]; /* account for granule delay of L3psycho_anal */ - - FLOAT tot_ener[4]; - - FLOAT last_en_subshort[4][9]; - int last_attacks[4]; - - int blocktype_old[2]; - } PsyStateVar_t; - - - typedef struct { - /* loudness calculation (for adaptive threshold of hearing) */ - FLOAT loudness_sq[2][2]; /* loudness^2 approx. per granule and channel */ - } PsyResult_t; - - - /* variables used by encoder.c */ - typedef struct { - /* variables for newmdct.c */ - FLOAT sb_sample[2][2][18][SBLIMIT]; - FLOAT amp_filter[32]; - - /* variables used by util.c */ - /* BPC = maximum number of filter convolution windows to precompute */ -#define BPC 320 - double itime[2]; /* float precision seems to be not enough */ - sample_t *inbuf_old[2]; - sample_t *blackfilt[2 * BPC + 1]; - - FLOAT pefirbuf[19]; - - /* used for padding */ - int frac_SpF; - int slot_lag; - - /* variables for bitstream.c */ - /* mpeg1: buffer=511 bytes smallest frame: 96-38(sideinfo)=58 - * max number of frames in reservoir: 8 - * mpeg2: buffer=255 bytes. smallest frame: 24-23bytes=1 - * with VBR, if you are encoding all silence, it is possible to - * have 8kbs/24khz frames with 1byte of data each, which means we need - * to buffer up to 255 headers! */ - /* also, max_header_buf has to be a power of two */ -#define MAX_HEADER_BUF 256 -#define MAX_HEADER_LEN 40 /* max size of header is 38 */ - struct { - int write_timing; - int ptr; - char buf[MAX_HEADER_LEN]; - } header[MAX_HEADER_BUF]; - - int h_ptr; - int w_ptr; - int ancillary_flag; - - /* variables for reservoir.c */ - int ResvSize; /* in bits */ - int ResvMax; /* in bits */ - - int in_buffer_nsamples; - sample_t *in_buffer_0; - sample_t *in_buffer_1; - -#ifndef MFSIZE -# define MFSIZE ( 3*1152 + ENCDELAY - MDCTDELAY ) -#endif - sample_t mfbuf[2][MFSIZE]; - - int mf_samples_to_encode; - int mf_size; - - } EncStateVar_t; - - - typedef struct { - /* simple statistics */ - int bitrate_channelmode_hist[16][4 + 1]; - int bitrate_blocktype_hist[16][4 + 1 + 1]; /*norm/start/short/stop/mixed(short)/sum */ - - int bitrate_index; - int frame_number; /* number of frames encoded */ - int padding; /* padding for the current frame? */ - int mode_ext; - int encoder_delay; - int encoder_padding; /* number of samples of padding appended to input */ - } EncResult_t; - - - /* variables used by quantize.c */ - typedef struct { - /* variables for nspsytune */ - FLOAT longfact[SBMAX_l]; - FLOAT shortfact[SBMAX_s]; - FLOAT masking_lower; - FLOAT mask_adjust; /* the dbQ stuff */ - FLOAT mask_adjust_short; /* the dbQ stuff */ - int OldValue[2]; - int CurrentStep[2]; - int pseudohalf[SFBMAX]; - int sfb21_extra; /* will be set in lame_init_params */ - int substep_shaping; /* 0 = no substep - 1 = use substep shaping at last step(VBR only) - (not implemented yet) - 2 = use substep inside loop - 3 = use substep inside loop and last step - */ - - - char bv_scf[576]; - } QntStateVar_t; - - - typedef struct { - replaygain_t *rgdata; - /* ReplayGain */ - } RpgStateVar_t; - - - typedef struct { - FLOAT noclipScale; /* user-specified scale factor required for preventing clipping */ - sample_t PeakSample; - int RadioGain; - int noclipGainChange; /* gain change required for preventing clipping */ - } RpgResult_t; - - - typedef struct { - int version; /* 0=MPEG-2/2.5 1=MPEG-1 */ - int samplerate_index; - int sideinfo_len; - - int noise_shaping; /* 0 = none - 1 = ISO AAC model - 2 = allow scalefac_select=1 - */ - - int subblock_gain; /* 0 = no, 1 = yes */ - int use_best_huffman; /* 0 = no. 1=outside loop 2=inside loop(slow) */ - int noise_shaping_amp; /* 0 = ISO model: amplify all distorted bands - 1 = amplify within 50% of max (on db scale) - 2 = amplify only most distorted band - 3 = method 1 and refine with method 2 - */ - - int noise_shaping_stop; /* 0 = stop at over=0, all scalefacs amplified or - a scalefac has reached max value - 1 = stop when all scalefacs amplified or - a scalefac has reached max value - 2 = stop when all scalefacs amplified - */ - - - int full_outer_loop; /* 0 = stop early after 0 distortion found. 1 = full search */ - - int lowpassfreq; - int highpassfreq; - int samplerate_in; /* input_samp_rate in Hz. default=44.1 kHz */ - int samplerate_out; /* output_samp_rate. */ - int channels_in; /* number of channels in the input data stream (PCM or decoded PCM) */ - int channels_out; /* number of channels in the output data stream (not used for decoding) */ - int mode_gr; /* granules per frame */ - int force_ms; /* force M/S mode. requires mode=1 */ - - int quant_comp; - int quant_comp_short; - - int use_temporal_masking_effect; - int use_safe_joint_stereo; - - int preset; - - vbr_mode vbr; - int vbr_avg_bitrate_kbps; - int vbr_min_bitrate_index; /* min bitrate index */ - int vbr_max_bitrate_index; /* max bitrate index */ - int avg_bitrate; - int enforce_min_bitrate; /* strictly enforce VBR_min_bitrate normaly, it will be violated for analog silence */ - - int findReplayGain; /* find the RG value? default=0 */ - int findPeakSample; - int decode_on_the_fly; /* decode on the fly? default=0 */ - int analysis; - int disable_reservoir; - int buffer_constraint; /* enforce ISO spec as much as possible */ - int free_format; - int write_lame_tag; /* add Xing VBR tag? */ - - int error_protection; /* use 2 bytes per frame for a CRC checksum. default=0 */ - int copyright; /* mark as copyright. default=0 */ - int original; /* mark as original. default=1 */ - int extension; /* the MP3 'private extension' bit. Meaningless */ - int emphasis; /* Input PCM is emphased PCM (for - instance from one of the rarely - emphased CDs), it is STRONGLY not - recommended to use this, because - psycho does not take it into account, - and last but not least many decoders - don't care about these bits */ - - - MPEG_mode mode; - short_block_t short_blocks; - - float interChRatio; - float msfix; /* Naoki's adjustment of Mid/Side maskings */ - float ATH_offset_db;/* add to ATH this many db */ - float ATH_offset_factor;/* change ATH by this factor, derived from ATH_offset_db */ - float ATHcurve; /* change ATH formula 4 shape */ - int ATHtype; - int ATHonly; /* only use ATH */ - int ATHshort; /* only use ATH for short blocks */ - int noATH; /* disable ATH */ - - float ATHfixpoint; - - float adjust_alto_db; - float adjust_bass_db; - float adjust_treble_db; - float adjust_sfb21_db; - - float compression_ratio; /* sizeof(wav file)/sizeof(mp3 file) */ - - /* lowpass and highpass filter control */ - FLOAT lowpass1, lowpass2; /* normalized frequency bounds of passband */ - FLOAT highpass1, highpass2; /* normalized frequency bounds of passband */ - - /* scale input by this amount before encoding at least not used for MP3 decoding */ - FLOAT pcm_transform[2][2]; - - FLOAT minval; - } SessionConfig_t; - - - struct lame_internal_flags { - - /******************************************************************** - * internal variables NOT set by calling program, and should not be * - * modified by the calling program * - ********************************************************************/ - - /* - * Some remarks to the Class_ID field: - * The Class ID is an Identifier for a pointer to this struct. - * It is very unlikely that a pointer to lame_global_flags has the same 32 bits - * in it's structure (large and other special properties, for instance prime). - * - * To test that the structure is right and initialized, use: - * if ( gfc -> Class_ID == LAME_ID ) ... - * Other remark: - * If you set a flag to 0 for uninit data and 1 for init data, the right test - * should be "if (flag == 1)" and NOT "if (flag)". Unintended modification - * of this element will be otherwise misinterpreted as an init. - */ -# define LAME_ID 0xFFF88E3B - unsigned long class_id; - - int lame_init_params_successful; - int lame_encode_frame_init; - int iteration_init_init; - int fill_buffer_resample_init; - - SessionConfig_t cfg; - - /* variables used by lame.c */ - Bit_stream_struc bs; - III_side_info_t l3_side; - - scalefac_struct scalefac_band; - - PsyStateVar_t sv_psy; /* DATA FROM PSYMODEL.C */ - PsyResult_t ov_psy; - EncStateVar_t sv_enc; /* DATA FROM ENCODER.C */ - EncResult_t ov_enc; - QntStateVar_t sv_qnt; /* DATA FROM QUANTIZE.C */ - - RpgStateVar_t sv_rpg; - RpgResult_t ov_rpg; - - /* optional ID3 tags, used in id3tag.c */ - struct id3tag_spec tag_spec; - uint16_t nMusicCRC; - - uint16_t _unused; - - /* CPU features */ - struct { - unsigned int MMX:1; /* Pentium MMX, Pentium II...IV, K6, K6-2, - K6-III, Athlon */ - unsigned int AMD_3DNow:1; /* K6-2, K6-III, Athlon */ - unsigned int SSE:1; /* Pentium III, Pentium 4 */ - unsigned int SSE2:1; /* Pentium 4, K8 */ - unsigned int _unused:28; - } CPU_features; - - - VBR_seek_info_t VBR_seek_table; /* used for Xing VBR header */ - - ATH_t *ATH; /* all ATH related stuff */ - - PsyConst_t *cd_psy; - - /* used by the frame analyzer */ - plotting_data *pinfo; - hip_t hip; - - /* functions to replace with CPU feature optimized versions in takehiro.c */ - int (*choose_table) (const int *ix, const int *const end, int *const s); - void (*fft_fht) (FLOAT *, int); - void (*init_xrpow_core) (gr_info * const cod_info, FLOAT xrpow[576], int upper, - FLOAT * sum); - - lame_report_function report_msg; - lame_report_function report_dbg; - lame_report_function report_err; - }; - -#ifndef lame_internal_flags_defined -#define lame_internal_flags_defined - typedef struct lame_internal_flags lame_internal_flags; -#endif - - -/*********************************************************************** -* -* Global Function Prototype Declarations -* -***********************************************************************/ - void freegfc(lame_internal_flags * const gfc); - void free_id3tag(lame_internal_flags * const gfc); - extern int BitrateIndex(int, int, int); - extern int FindNearestBitrate(int, int, int); - extern int map2MP3Frequency(int freq); - extern int SmpFrqIndex(int, int *const); - extern int nearestBitrateFullIndex(uint16_t brate); - extern FLOAT ATHformula(SessionConfig_t const *cfg, FLOAT freq); - extern FLOAT freq2bark(FLOAT freq); - void disable_FPE(void); - -/* log/log10 approximations */ - extern void init_log_table(void); - extern ieee754_float32_t fast_log2(ieee754_float32_t x); - - int isResamplingNecessary(SessionConfig_t const* cfg); - - void fill_buffer(lame_internal_flags * gfc, - sample_t *const mfbuf[2], - sample_t const *const in_buffer[2], int nsamples, int *n_in, int *n_out); - -/* same as lame_decode1 (look in lame.h), but returns - unclipped raw floating-point samples. It is declared - here, not in lame.h, because it returns LAME's - internal type sample_t. No more than 1152 samples - per channel are allowed. */ - int hip_decode1_unclipped(hip_t hip, unsigned char *mp3buf, - size_t len, sample_t pcm_l[], sample_t pcm_r[]); - - - extern int has_MMX(void); - extern int has_3DNow(void); - extern int has_SSE(void); - extern int has_SSE2(void); - - - -/*********************************************************************** -* -* Macros about Message Printing and Exit -* -***********************************************************************/ - - extern void lame_report_def(const char* format, va_list args); - extern void lame_report_fnc(lame_report_function print_f, const char *, ...); - extern void lame_errorf(const lame_internal_flags * gfc, const char *, ...); - extern void lame_debugf(const lame_internal_flags * gfc, const char *, ...); - extern void lame_msgf(const lame_internal_flags * gfc, const char *, ...); -#define DEBUGF lame_debugf -#define ERRORF lame_errorf -#define MSGF lame_msgf - - int is_lame_internal_flags_valid(const lame_internal_flags * gfp); - - extern void hip_set_pinfo(hip_t hip, plotting_data* pinfo); - -#ifdef __cplusplus -} -#endif -#endif /* LAME_UTIL_H */ diff --git a/lib-src/lame/libmp3lame/vbrquantize.c b/lib-src/lame/libmp3lame/vbrquantize.c deleted file mode 100644 index 0f703b754..000000000 --- a/lib-src/lame/libmp3lame/vbrquantize.c +++ /dev/null @@ -1,1580 +0,0 @@ -/* - * MP3 quantization - * - * Copyright (c) 1999-2000 Mark Taylor - * Copyright (c) 2000-2012 Robert Hegemann - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* $Id: vbrquantize.c,v 1.142 2012/02/07 13:36:35 robert Exp $ */ - -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "vbrquantize.h" -#include "quantize_pvt.h" - - - - -struct algo_s; -typedef struct algo_s algo_t; - -typedef void (*alloc_sf_f) (const algo_t *, const int *, const int *, int); -typedef uint8_t (*find_sf_f) (const FLOAT *, const FLOAT *, FLOAT, unsigned int, uint8_t); - -struct algo_s { - alloc_sf_f alloc; - find_sf_f find; - const FLOAT *xr34orig; - lame_internal_flags *gfc; - gr_info *cod_info; - int mingain_l; - int mingain_s[3]; -}; - - - -/* Remarks on optimizing compilers: - * - * the MSVC compiler may get into aliasing problems when accessing - * memory through the fi_union. declaring it volatile does the trick here - * - * the calc_sfb_noise_* functions are not inlined because the intel compiler - * optimized executeables won't work as expected anymore - */ - -#ifdef _MSC_VER -# if _MSC_VER < 1400 -# define VOLATILE volatile -# else -# define VOLATILE -# endif -#else -# define VOLATILE -#endif - -typedef VOLATILE union { - float f; - int i; -} fi_union; - - - -#ifdef TAKEHIRO_IEEE754_HACK -#define DOUBLEX double -#else -#define DOUBLEX FLOAT -#endif - -#define MAGIC_FLOAT_def (65536*(128)) -#define MAGIC_INT_def 0x4b000000 - -#ifdef TAKEHIRO_IEEE754_HACK -#else -/********************************************************************* - * XRPOW_FTOI is a macro to convert floats to ints. - * if XRPOW_FTOI(x) = nearest_int(x), then QUANTFAC(x)=adj43asm[x] - * ROUNDFAC= -0.0946 - * - * if XRPOW_FTOI(x) = floor(x), then QUANTFAC(x)=asj43[x] - * ROUNDFAC=0.4054 - *********************************************************************/ -# define QUANTFAC(rx) adj43[rx] -# define ROUNDFAC_def 0.4054f -# define XRPOW_FTOI(src,dest) ((dest) = (int)(src)) -#endif - -static int const MAGIC_INT = MAGIC_INT_def; -#ifndef TAKEHIRO_IEEE754_HACK -static DOUBLEX const ROUNDFAC = ROUNDFAC_def; -#endif -static DOUBLEX const MAGIC_FLOAT = MAGIC_FLOAT_def; - - -inline static float -vec_max_c(const float * xr34, unsigned int bw) -{ - float xfsf = 0; - unsigned int i = bw >> 2u; - unsigned int const remaining = (bw & 0x03u); - - while (i-- > 0) { - if (xfsf < xr34[0]) { - xfsf = xr34[0]; - } - if (xfsf < xr34[1]) { - xfsf = xr34[1]; - } - if (xfsf < xr34[2]) { - xfsf = xr34[2]; - } - if (xfsf < xr34[3]) { - xfsf = xr34[3]; - } - xr34 += 4; - } - switch( remaining ) { - case 3: if (xfsf < xr34[2]) xfsf = xr34[2]; - case 2: if (xfsf < xr34[1]) xfsf = xr34[1]; - case 1: if (xfsf < xr34[0]) xfsf = xr34[0]; - default: break; - } - return xfsf; -} - - -inline static uint8_t -find_lowest_scalefac(const FLOAT xr34) -{ - uint8_t sf_ok = 255; - uint8_t sf = 128, delsf = 64; - uint8_t i; - FLOAT const ixmax_val = IXMAX_VAL; - for (i = 0; i < 8; ++i) { - FLOAT const xfsf = ipow20[sf] * xr34; - if (xfsf <= ixmax_val) { - sf_ok = sf; - sf -= delsf; - } - else { - sf += delsf; - } - delsf >>= 1; - } - return sf_ok; -} - - -inline static void -k_34_4(DOUBLEX x[4], int l3[4]) -{ -#ifdef TAKEHIRO_IEEE754_HACK - fi_union fi[4]; - - assert(x[0] <= IXMAX_VAL && x[1] <= IXMAX_VAL && x[2] <= IXMAX_VAL && x[3] <= IXMAX_VAL); - x[0] += MAGIC_FLOAT; - fi[0].f = x[0]; - x[1] += MAGIC_FLOAT; - fi[1].f = x[1]; - x[2] += MAGIC_FLOAT; - fi[2].f = x[2]; - x[3] += MAGIC_FLOAT; - fi[3].f = x[3]; - fi[0].f = x[0] + adj43asm[fi[0].i - MAGIC_INT]; - fi[1].f = x[1] + adj43asm[fi[1].i - MAGIC_INT]; - fi[2].f = x[2] + adj43asm[fi[2].i - MAGIC_INT]; - fi[3].f = x[3] + adj43asm[fi[3].i - MAGIC_INT]; - l3[0] = fi[0].i - MAGIC_INT; - l3[1] = fi[1].i - MAGIC_INT; - l3[2] = fi[2].i - MAGIC_INT; - l3[3] = fi[3].i - MAGIC_INT; -#else - assert(x[0] <= IXMAX_VAL && x[1] <= IXMAX_VAL && x[2] <= IXMAX_VAL && x[3] <= IXMAX_VAL); - XRPOW_FTOI(x[0], l3[0]); - XRPOW_FTOI(x[1], l3[1]); - XRPOW_FTOI(x[2], l3[2]); - XRPOW_FTOI(x[3], l3[3]); - x[0] += QUANTFAC(l3[0]); - x[1] += QUANTFAC(l3[1]); - x[2] += QUANTFAC(l3[2]); - x[3] += QUANTFAC(l3[3]); - XRPOW_FTOI(x[0], l3[0]); - XRPOW_FTOI(x[1], l3[1]); - XRPOW_FTOI(x[2], l3[2]); - XRPOW_FTOI(x[3], l3[3]); -#endif -} - - - - - -/* do call the calc_sfb_noise_* functions only with sf values - * for which holds: sfpow34*xr34 <= IXMAX_VAL - */ - -static FLOAT -calc_sfb_noise_x34(const FLOAT * xr, const FLOAT * xr34, unsigned int bw, uint8_t sf) -{ - DOUBLEX x[4]; - int l3[4]; - const FLOAT sfpow = pow20[sf + Q_MAX2]; /*pow(2.0,sf/4.0); */ - const FLOAT sfpow34 = ipow20[sf]; /*pow(sfpow,-3.0/4.0); */ - - FLOAT xfsf = 0; - unsigned int i = bw >> 2u; - unsigned int const remaining = (bw & 0x03u); - - while (i-- > 0) { - x[0] = sfpow34 * xr34[0]; - x[1] = sfpow34 * xr34[1]; - x[2] = sfpow34 * xr34[2]; - x[3] = sfpow34 * xr34[3]; - - k_34_4(x, l3); - - x[0] = fabsf(xr[0]) - sfpow * pow43[l3[0]]; - x[1] = fabsf(xr[1]) - sfpow * pow43[l3[1]]; - x[2] = fabsf(xr[2]) - sfpow * pow43[l3[2]]; - x[3] = fabsf(xr[3]) - sfpow * pow43[l3[3]]; - xfsf += (x[0] * x[0] + x[1] * x[1]) + (x[2] * x[2] + x[3] * x[3]); - - xr += 4; - xr34 += 4; - } - if (remaining) { - x[0] = x[1] = x[2] = x[3] = 0; - switch( remaining ) { - case 3: x[2] = sfpow34 * xr34[2]; - case 2: x[1] = sfpow34 * xr34[1]; - case 1: x[0] = sfpow34 * xr34[0]; - } - - k_34_4(x, l3); - x[0] = x[1] = x[2] = x[3] = 0; - - switch( remaining ) { - case 3: x[2] = fabsf(xr[2]) - sfpow * pow43[l3[2]]; - case 2: x[1] = fabsf(xr[1]) - sfpow * pow43[l3[1]]; - case 1: x[0] = fabsf(xr[0]) - sfpow * pow43[l3[0]]; - } - xfsf += (x[0] * x[0] + x[1] * x[1]) + (x[2] * x[2] + x[3] * x[3]); - } - return xfsf; -} - - - -struct calc_noise_cache { - int valid; - FLOAT value; -}; - -typedef struct calc_noise_cache calc_noise_cache_t; - - -static uint8_t -tri_calc_sfb_noise_x34(const FLOAT * xr, const FLOAT * xr34, FLOAT l3_xmin, unsigned int bw, - uint8_t sf, calc_noise_cache_t * did_it) -{ - if (did_it[sf].valid == 0) { - did_it[sf].valid = 1; - did_it[sf].value = calc_sfb_noise_x34(xr, xr34, bw, sf); - } - if (l3_xmin < did_it[sf].value) { - return 1; - } - if (sf < 255) { - uint8_t const sf_x = sf + 1; - if (did_it[sf_x].valid == 0) { - did_it[sf_x].valid = 1; - did_it[sf_x].value = calc_sfb_noise_x34(xr, xr34, bw, sf_x); - } - if (l3_xmin < did_it[sf_x].value) { - return 1; - } - } - if (sf > 0) { - uint8_t const sf_x = sf - 1; - if (did_it[sf_x].valid == 0) { - did_it[sf_x].valid = 1; - did_it[sf_x].value = calc_sfb_noise_x34(xr, xr34, bw, sf_x); - } - if (l3_xmin < did_it[sf_x].value) { - return 1; - } - } - return 0; -} - - -/** - * Robert Hegemann 2001-05-01 - * calculates quantization step size determined by allowed masking - */ -static int -calc_scalefac(FLOAT l3_xmin, int bw) -{ - FLOAT const c = 5.799142446; /* 10 * 10^(2/3) * log10(4/3) */ - return 210 + (int) (c * log10f(l3_xmin / bw) - .5f); -} - -static uint8_t -guess_scalefac_x34(const FLOAT * xr, const FLOAT * xr34, FLOAT l3_xmin, unsigned int bw, uint8_t sf_min) -{ - int const guess = calc_scalefac(l3_xmin, bw); - if (guess < sf_min) return sf_min; - if (guess >= 255) return 255; - (void) xr; - (void) xr34; - return guess; -} - - -/* the find_scalefac* routines calculate - * a quantization step size which would - * introduce as much noise as is allowed. - * The larger the step size the more - * quantization noise we'll get. The - * scalefactors are there to lower the - * global step size, allowing limited - * differences in quantization step sizes - * per band (shaping the noise). - */ - -static uint8_t -find_scalefac_x34(const FLOAT * xr, const FLOAT * xr34, FLOAT l3_xmin, unsigned int bw, - uint8_t sf_min) -{ - calc_noise_cache_t did_it[256]; - uint8_t sf = 128, sf_ok = 255, delsf = 128, seen_good_one = 0, i; - memset(did_it, 0, sizeof(did_it)); - for (i = 0; i < 8; ++i) { - delsf >>= 1; - if (sf <= sf_min) { - sf += delsf; - } - else { - uint8_t const bad = tri_calc_sfb_noise_x34(xr, xr34, l3_xmin, bw, sf, did_it); - if (bad) { /* distortion. try a smaller scalefactor */ - sf -= delsf; - } - else { - sf_ok = sf; - sf += delsf; - seen_good_one = 1; - } - } - } - /* returning a scalefac without distortion, if possible - */ - if (seen_good_one > 0) { - sf = sf_ok; - } - if (sf <= sf_min) { - sf = sf_min; - } - return sf; -} - - - -/*********************************************************************** - * - * calc_short_block_vbr_sf() - * calc_long_block_vbr_sf() - * - * Mark Taylor 2000-??-?? - * Robert Hegemann 2000-10-25 made functions of it - * - ***********************************************************************/ - -/* a variation for vbr-mtrh */ -static int -block_sf(algo_t * that, const FLOAT l3_xmin[SFBMAX], int vbrsf[SFBMAX], int vbrsfmin[SFBMAX]) -{ - FLOAT max_xr34; - const FLOAT *const xr = &that->cod_info->xr[0]; - const FLOAT *const xr34_orig = &that->xr34orig[0]; - const int *const width = &that->cod_info->width[0]; - const char *const energy_above_cutoff = &that->cod_info->energy_above_cutoff[0]; - unsigned int const max_nonzero_coeff = (unsigned int) that->cod_info->max_nonzero_coeff; - uint8_t maxsf = 0; - int sfb = 0, m_o = -1; - unsigned int j = 0, i = 0; - int const psymax = that->cod_info->psymax; - - assert(that->cod_info->max_nonzero_coeff >= 0); - - that->mingain_l = 0; - that->mingain_s[0] = 0; - that->mingain_s[1] = 0; - that->mingain_s[2] = 0; - while (j <= max_nonzero_coeff) { - unsigned int const w = (unsigned int) width[sfb]; - unsigned int const m = (unsigned int) (max_nonzero_coeff - j + 1); - unsigned int l = w; - uint8_t m1, m2; - if (l > m) { - l = m; - } - max_xr34 = vec_max_c(&xr34_orig[j], l); - - m1 = find_lowest_scalefac(max_xr34); - vbrsfmin[sfb] = m1; - if (that->mingain_l < m1) { - that->mingain_l = m1; - } - if (that->mingain_s[i] < m1) { - that->mingain_s[i] = m1; - } - if (++i > 2) { - i = 0; - } - if (sfb < psymax && w > 2) { /* mpeg2.5 at 8 kHz doesn't use all scalefactors, unused have width 2 */ - if (energy_above_cutoff[sfb]) { - m2 = that->find(&xr[j], &xr34_orig[j], l3_xmin[sfb], l, m1); -#if 0 - if (0) { - /** Robert Hegemann 2007-09-29: - * It seems here is some more potential for speed improvements. - * Current find method does 11-18 quantization calculations. - * Using a "good guess" may help to reduce this amount. - */ - uint8_t guess = calc_scalefac(l3_xmin[sfb], l); - DEBUGF(that->gfc, "sfb=%3d guess=%3d found=%3d diff=%3d\n", sfb, guess, m2, - m2 - guess); - } -#endif - if (maxsf < m2) { - maxsf = m2; - } - if (m_o < m2 && m2 < 255) { - m_o = m2; - } - } - else { - m2 = 255; - maxsf = 255; - } - } - else { - if (maxsf < m1) { - maxsf = m1; - } - m2 = maxsf; - } - vbrsf[sfb] = m2; - ++sfb; - j += w; - } - for (; sfb < SFBMAX; ++sfb) { - vbrsf[sfb] = maxsf; - vbrsfmin[sfb] = 0; - } - if (m_o > -1) { - maxsf = m_o; - for (sfb = 0; sfb < SFBMAX; ++sfb) { - if (vbrsf[sfb] == 255) { - vbrsf[sfb] = m_o; - } - } - } - return maxsf; -} - - - -/*********************************************************************** - * - * quantize xr34 based on scalefactors - * - * block_xr34 - * - * Mark Taylor 2000-??-?? - * Robert Hegemann 2000-10-20 made functions of them - * - ***********************************************************************/ - -static void -quantize_x34(const algo_t * that) -{ - DOUBLEX x[4]; - const FLOAT *xr34_orig = that->xr34orig; - gr_info *const cod_info = that->cod_info; - int const ifqstep = (cod_info->scalefac_scale == 0) ? 2 : 4; - int *l3 = cod_info->l3_enc; - unsigned int j = 0, sfb = 0; - unsigned int const max_nonzero_coeff = (unsigned int) cod_info->max_nonzero_coeff; - - assert(cod_info->max_nonzero_coeff >= 0); - assert(cod_info->max_nonzero_coeff < 576); - - while (j <= max_nonzero_coeff) { - int const s = - (cod_info->scalefac[sfb] + (cod_info->preflag ? pretab[sfb] : 0)) * ifqstep - + cod_info->subblock_gain[cod_info->window[sfb]] * 8; - uint8_t const sfac = (uint8_t) (cod_info->global_gain - s); - FLOAT const sfpow34 = ipow20[sfac]; - unsigned int const w = (unsigned int) cod_info->width[sfb]; - unsigned int const m = (unsigned int) (max_nonzero_coeff - j + 1); - unsigned int i, remaining; - - assert((cod_info->global_gain - s) >= 0); - assert(cod_info->width[sfb] >= 0); - j += w; - ++sfb; - - i = (w <= m) ? w : m; - remaining = (i & 0x03u); - i >>= 2u; - - while (i-- > 0) { - x[0] = sfpow34 * xr34_orig[0]; - x[1] = sfpow34 * xr34_orig[1]; - x[2] = sfpow34 * xr34_orig[2]; - x[3] = sfpow34 * xr34_orig[3]; - - k_34_4(x, l3); - - l3 += 4; - xr34_orig += 4; - } - if (remaining) { - int tmp_l3[4]; - x[0] = x[1] = x[2] = x[3] = 0; - switch( remaining ) { - case 3: x[2] = sfpow34 * xr34_orig[2]; - case 2: x[1] = sfpow34 * xr34_orig[1]; - case 1: x[0] = sfpow34 * xr34_orig[0]; - } - - k_34_4(x, tmp_l3); - - switch( remaining ) { - case 3: l3[2] = tmp_l3[2]; - case 2: l3[1] = tmp_l3[1]; - case 1: l3[0] = tmp_l3[0]; - } - - l3 += remaining; - xr34_orig += remaining; - } - } -} - - - -static const uint8_t max_range_short[SBMAX_s * 3] = { - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, - 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, - 0, 0, 0 -}; - -static const uint8_t max_range_long[SBMAX_l] = { - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 0 -}; - -static const uint8_t max_range_long_lsf_pretab[SBMAX_l] = { - 7, 7, 7, 7, 7, 7, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 -}; - - - -/* - sfb=0..5 scalefac < 16 - sfb>5 scalefac < 8 - - ifqstep = ( cod_info->scalefac_scale == 0 ) ? 2 : 4; - ol_sf = (cod_info->global_gain-210.0); - ol_sf -= 8*cod_info->subblock_gain[i]; - ol_sf -= ifqstep*scalefac[gr][ch].s[sfb][i]; -*/ - -static void -set_subblock_gain(gr_info * cod_info, const int mingain_s[3], int sf[]) -{ - const int maxrange1 = 15, maxrange2 = 7; - const int ifqstepShift = (cod_info->scalefac_scale == 0) ? 1 : 2; - int *const sbg = cod_info->subblock_gain; - unsigned int const psymax = (unsigned int) cod_info->psymax; - unsigned int psydiv = 18; - int sbg0, sbg1, sbg2; - unsigned int sfb, i; - int min_sbg = 7; - - if (psydiv > psymax) { - psydiv = psymax; - } - for (i = 0; i < 3; ++i) { - int maxsf1 = 0, maxsf2 = 0, minsf = 1000; - /* see if we should use subblock gain */ - for (sfb = i; sfb < psydiv; sfb += 3) { /* part 1 */ - int const v = -sf[sfb]; - if (maxsf1 < v) { - maxsf1 = v; - } - if (minsf > v) { - minsf = v; - } - } - for (; sfb < SFBMAX; sfb += 3) { /* part 2 */ - int const v = -sf[sfb]; - if (maxsf2 < v) { - maxsf2 = v; - } - if (minsf > v) { - minsf = v; - } - } - - /* boost subblock gain as little as possible so we can - * reach maxsf1 with scalefactors - * 8*sbg >= maxsf1 - */ - { - int const m1 = maxsf1 - (maxrange1 << ifqstepShift); - int const m2 = maxsf2 - (maxrange2 << ifqstepShift); - - maxsf1 = Max(m1, m2); - } - if (minsf > 0) { - sbg[i] = minsf >> 3; - } - else { - sbg[i] = 0; - } - if (maxsf1 > 0) { - int const m1 = sbg[i]; - int const m2 = (maxsf1 + 7) >> 3; - sbg[i] = Max(m1, m2); - } - if (sbg[i] > 0 && mingain_s[i] > (cod_info->global_gain - sbg[i] * 8)) { - sbg[i] = (cod_info->global_gain - mingain_s[i]) >> 3; - } - if (sbg[i] > 7) { - sbg[i] = 7; - } - if (min_sbg > sbg[i]) { - min_sbg = sbg[i]; - } - } - sbg0 = sbg[0] * 8; - sbg1 = sbg[1] * 8; - sbg2 = sbg[2] * 8; - for (sfb = 0; sfb < SFBMAX; sfb += 3) { - sf[sfb + 0] += sbg0; - sf[sfb + 1] += sbg1; - sf[sfb + 2] += sbg2; - } - if (min_sbg > 0) { - for (i = 0; i < 3; ++i) { - sbg[i] -= min_sbg; - } - cod_info->global_gain -= min_sbg * 8; - } -} - - - -/* - ifqstep = ( cod_info->scalefac_scale == 0 ) ? 2 : 4; - ol_sf = (cod_info->global_gain-210.0); - ol_sf -= ifqstep*scalefac[gr][ch].l[sfb]; - if (cod_info->preflag && sfb>=11) - ol_sf -= ifqstep*pretab[sfb]; -*/ -static void -set_scalefacs(gr_info * cod_info, const int *vbrsfmin, int sf[], const uint8_t * max_range) -{ - const int ifqstep = (cod_info->scalefac_scale == 0) ? 2 : 4; - const int ifqstepShift = (cod_info->scalefac_scale == 0) ? 1 : 2; - int *const scalefac = cod_info->scalefac; - int const sfbmax = cod_info->sfbmax; - int sfb; - int const *const sbg = cod_info->subblock_gain; - int const *const window = cod_info->window; - int const preflag = cod_info->preflag; - - if (preflag) { - for (sfb = 11; sfb < sfbmax; ++sfb) { - sf[sfb] += pretab[sfb] * ifqstep; - } - } - for (sfb = 0; sfb < sfbmax; ++sfb) { - int const gain = cod_info->global_gain - (sbg[window[sfb]] * 8) - - ((preflag ? pretab[sfb] : 0) * ifqstep); - - if (sf[sfb] < 0) { - int const m = gain - vbrsfmin[sfb]; - /* ifqstep*scalefac >= -sf[sfb], so round UP */ - scalefac[sfb] = (ifqstep - 1 - sf[sfb]) >> ifqstepShift; - - if (scalefac[sfb] > max_range[sfb]) { - scalefac[sfb] = max_range[sfb]; - } - if (scalefac[sfb] > 0 && (scalefac[sfb] << ifqstepShift) > m) { - scalefac[sfb] = m >> ifqstepShift; - } - } - else { - scalefac[sfb] = 0; - } - } - for (; sfb < SFBMAX; ++sfb) { - scalefac[sfb] = 0; /* sfb21 */ - } -} - - -#ifndef NDEBUG -static int -checkScalefactor(const gr_info * cod_info, const int vbrsfmin[SFBMAX]) -{ - int const ifqstep = cod_info->scalefac_scale == 0 ? 2 : 4; - int sfb; - for (sfb = 0; sfb < cod_info->psymax; ++sfb) { - const int s = - ((cod_info->scalefac[sfb] + - (cod_info->preflag ? pretab[sfb] : 0)) * ifqstep) + - cod_info->subblock_gain[cod_info->window[sfb]] * 8; - - if ((cod_info->global_gain - s) < vbrsfmin[sfb]) { - /* - fprintf( stdout, "sf %d\n", sfb ); - fprintf( stdout, "min %d\n", vbrsfmin[sfb] ); - fprintf( stdout, "ggain %d\n", cod_info->global_gain ); - fprintf( stdout, "scalefac %d\n", cod_info->scalefac[sfb] ); - fprintf( stdout, "pretab %d\n", (cod_info->preflag ? pretab[sfb] : 0) ); - fprintf( stdout, "scale %d\n", (cod_info->scalefac_scale + 1) ); - fprintf( stdout, "subgain %d\n", cod_info->subblock_gain[cod_info->window[sfb]] * 8 ); - fflush( stdout ); - exit(-1); - */ - return 0; - } - } - return 1; -} -#endif - - -/****************************************************************** - * - * short block scalefacs - * - ******************************************************************/ - -static void -short_block_constrain(const algo_t * that, const int vbrsf[SFBMAX], - const int vbrsfmin[SFBMAX], int vbrmax) -{ - gr_info *const cod_info = that->cod_info; - lame_internal_flags const *const gfc = that->gfc; - SessionConfig_t const *const cfg = &gfc->cfg; - int const maxminsfb = that->mingain_l; - int mover, maxover0 = 0, maxover1 = 0, delta = 0; - int v, v0, v1; - int sfb; - int const psymax = cod_info->psymax; - - for (sfb = 0; sfb < psymax; ++sfb) { - assert(vbrsf[sfb] >= vbrsfmin[sfb]); - v = vbrmax - vbrsf[sfb]; - if (delta < v) { - delta = v; - } - v0 = v - (4 * 14 + 2 * max_range_short[sfb]); - v1 = v - (4 * 14 + 4 * max_range_short[sfb]); - if (maxover0 < v0) { - maxover0 = v0; - } - if (maxover1 < v1) { - maxover1 = v1; - } - } - if (cfg->noise_shaping == 2) { - /* allow scalefac_scale=1 */ - mover = Min(maxover0, maxover1); - } - else { - mover = maxover0; - } - if (delta > mover) { - delta = mover; - } - vbrmax -= delta; - maxover0 -= mover; - maxover1 -= mover; - - if (maxover0 == 0) { - cod_info->scalefac_scale = 0; - } - else if (maxover1 == 0) { - cod_info->scalefac_scale = 1; - } - if (vbrmax < maxminsfb) { - vbrmax = maxminsfb; - } - cod_info->global_gain = vbrmax; - - if (cod_info->global_gain < 0) { - cod_info->global_gain = 0; - } - else if (cod_info->global_gain > 255) { - cod_info->global_gain = 255; - } - { - int sf_temp[SFBMAX]; - for (sfb = 0; sfb < SFBMAX; ++sfb) { - sf_temp[sfb] = vbrsf[sfb] - vbrmax; - } - set_subblock_gain(cod_info, &that->mingain_s[0], sf_temp); - set_scalefacs(cod_info, vbrsfmin, sf_temp, max_range_short); - } - assert(checkScalefactor(cod_info, vbrsfmin)); -} - - - -/****************************************************************** - * - * long block scalefacs - * - ******************************************************************/ - -static void -long_block_constrain(const algo_t * that, const int vbrsf[SFBMAX], const int vbrsfmin[SFBMAX], - int vbrmax) -{ - gr_info *const cod_info = that->cod_info; - lame_internal_flags const *const gfc = that->gfc; - SessionConfig_t const *const cfg = &gfc->cfg; - uint8_t const *max_rangep; - int const maxminsfb = that->mingain_l; - int sfb; - int maxover0, maxover1, maxover0p, maxover1p, mover, delta = 0; - int v, v0, v1, v0p, v1p, vm0p = 1, vm1p = 1; - int const psymax = cod_info->psymax; - - max_rangep = cfg->mode_gr == 2 ? max_range_long : max_range_long_lsf_pretab; - - maxover0 = 0; - maxover1 = 0; - maxover0p = 0; /* pretab */ - maxover1p = 0; /* pretab */ - - for (sfb = 0; sfb < psymax; ++sfb) { - assert(vbrsf[sfb] >= vbrsfmin[sfb]); - v = vbrmax - vbrsf[sfb]; - if (delta < v) { - delta = v; - } - v0 = v - 2 * max_range_long[sfb]; - v1 = v - 4 * max_range_long[sfb]; - v0p = v - 2 * (max_rangep[sfb] + pretab[sfb]); - v1p = v - 4 * (max_rangep[sfb] + pretab[sfb]); - if (maxover0 < v0) { - maxover0 = v0; - } - if (maxover1 < v1) { - maxover1 = v1; - } - if (maxover0p < v0p) { - maxover0p = v0p; - } - if (maxover1p < v1p) { - maxover1p = v1p; - } - } - if (vm0p == 1) { - int gain = vbrmax - maxover0p; - if (gain < maxminsfb) { - gain = maxminsfb; - } - for (sfb = 0; sfb < psymax; ++sfb) { - int const a = (gain - vbrsfmin[sfb]) - 2 * pretab[sfb]; - if (a <= 0) { - vm0p = 0; - vm1p = 0; - break; - } - } - } - if (vm1p == 1) { - int gain = vbrmax - maxover1p; - if (gain < maxminsfb) { - gain = maxminsfb; - } - for (sfb = 0; sfb < psymax; ++sfb) { - int const b = (gain - vbrsfmin[sfb]) - 4 * pretab[sfb]; - if (b <= 0) { - vm1p = 0; - break; - } - } - } - if (vm0p == 0) { - maxover0p = maxover0; - } - if (vm1p == 0) { - maxover1p = maxover1; - } - if (cfg->noise_shaping != 2) { - maxover1 = maxover0; - maxover1p = maxover0p; - } - mover = Min(maxover0, maxover0p); - mover = Min(mover, maxover1); - mover = Min(mover, maxover1p); - - if (delta > mover) { - delta = mover; - } - vbrmax -= delta; - if (vbrmax < maxminsfb) { - vbrmax = maxminsfb; - } - maxover0 -= mover; - maxover0p -= mover; - maxover1 -= mover; - maxover1p -= mover; - - if (maxover0 == 0) { - cod_info->scalefac_scale = 0; - cod_info->preflag = 0; - max_rangep = max_range_long; - } - else if (maxover0p == 0) { - cod_info->scalefac_scale = 0; - cod_info->preflag = 1; - } - else if (maxover1 == 0) { - cod_info->scalefac_scale = 1; - cod_info->preflag = 0; - max_rangep = max_range_long; - } - else if (maxover1p == 0) { - cod_info->scalefac_scale = 1; - cod_info->preflag = 1; - } - else { - assert(0); /* this should not happen */ - } - cod_info->global_gain = vbrmax; - if (cod_info->global_gain < 0) { - cod_info->global_gain = 0; - } - else if (cod_info->global_gain > 255) { - cod_info->global_gain = 255; - } - { - int sf_temp[SFBMAX]; - for (sfb = 0; sfb < SFBMAX; ++sfb) { - sf_temp[sfb] = vbrsf[sfb] - vbrmax; - } - set_scalefacs(cod_info, vbrsfmin, sf_temp, max_rangep); - } - assert(checkScalefactor(cod_info, vbrsfmin)); -} - - - -static void -bitcount(const algo_t * that) -{ - int rc = scale_bitcount(that->gfc, that->cod_info); - - if (rc == 0) { - return; - } - /* this should not happen due to the way the scalefactors are selected */ - ERRORF(that->gfc, "INTERNAL ERROR IN VBR NEW CODE (986), please send bug report\n"); - exit(-1); -} - - - -static int -quantizeAndCountBits(const algo_t * that) -{ - quantize_x34(that); - that->cod_info->part2_3_length = noquant_count_bits(that->gfc, that->cod_info, 0); - return that->cod_info->part2_3_length; -} - - - - - -static int -tryGlobalStepsize(const algo_t * that, const int sfwork[SFBMAX], - const int vbrsfmin[SFBMAX], int delta) -{ - FLOAT const xrpow_max = that->cod_info->xrpow_max; - int sftemp[SFBMAX], i, nbits; - int gain, vbrmax = 0; - for (i = 0; i < SFBMAX; ++i) { - gain = sfwork[i] + delta; - if (gain < vbrsfmin[i]) { - gain = vbrsfmin[i]; - } - if (gain > 255) { - gain = 255; - } - if (vbrmax < gain) { - vbrmax = gain; - } - sftemp[i] = gain; - } - that->alloc(that, sftemp, vbrsfmin, vbrmax); - bitcount(that); - nbits = quantizeAndCountBits(that); - that->cod_info->xrpow_max = xrpow_max; - return nbits; -} - - - -static void -searchGlobalStepsizeMax(const algo_t * that, const int sfwork[SFBMAX], - const int vbrsfmin[SFBMAX], int target) -{ - gr_info const *const cod_info = that->cod_info; - const int gain = cod_info->global_gain; - int curr = gain; - int gain_ok = 1024; - int nbits = LARGE_BITS; - int l = gain, r = 512; - - assert(gain >= 0); - while (l <= r) { - curr = (l + r) >> 1; - nbits = tryGlobalStepsize(that, sfwork, vbrsfmin, curr - gain); - if (nbits == 0 || (nbits + cod_info->part2_length) < target) { - r = curr - 1; - gain_ok = curr; - } - else { - l = curr + 1; - if (gain_ok == 1024) { - gain_ok = curr; - } - } - } - if (gain_ok != curr) { - curr = gain_ok; - nbits = tryGlobalStepsize(that, sfwork, vbrsfmin, curr - gain); - } -} - - - -static int -sfDepth(const int sfwork[SFBMAX]) -{ - int m = 0; - unsigned int i, j; - for (j = SFBMAX, i = 0; j > 0; --j, ++i) { - int const di = 255 - sfwork[i]; - if (m < di) { - m = di; - } - assert(sfwork[i] >= 0); - assert(sfwork[i] <= 255); - } - assert(m >= 0); - assert(m <= 255); - return m; -} - - -static void -cutDistribution(const int sfwork[SFBMAX], int sf_out[SFBMAX], int cut) -{ - unsigned int i, j; - for (j = SFBMAX, i = 0; j > 0; --j, ++i) { - int const x = sfwork[i]; - sf_out[i] = x < cut ? x : cut; - } -} - - -static int -flattenDistribution(const int sfwork[SFBMAX], int sf_out[SFBMAX], int dm, int k, int p) -{ - unsigned int i, j; - int x, sfmax = 0; - if (dm > 0) { - for (j = SFBMAX, i = 0; j > 0; --j, ++i) { - int const di = p - sfwork[i]; - x = sfwork[i] + (k * di) / dm; - if (x < 0) { - x = 0; - } - else { - if (x > 255) { - x = 255; - } - } - sf_out[i] = x; - if (sfmax < x) { - sfmax = x; - } - } - } - else { - for (j = SFBMAX, i = 0; j > 0u; --j, ++i) { - x = sfwork[i]; - sf_out[i] = x; - if (sfmax < x) { - sfmax = x; - } - } - } - return sfmax; -} - - -static int -tryThatOne(algo_t const* that, const int sftemp[SFBMAX], const int vbrsfmin[SFBMAX], int vbrmax) -{ - FLOAT const xrpow_max = that->cod_info->xrpow_max; - int nbits = LARGE_BITS; - that->alloc(that, sftemp, vbrsfmin, vbrmax); - bitcount(that); - nbits = quantizeAndCountBits(that); - nbits += that->cod_info->part2_length; - that->cod_info->xrpow_max = xrpow_max; - return nbits; -} - - -static void -outOfBitsStrategy(algo_t const* that, const int sfwork[SFBMAX], const int vbrsfmin[SFBMAX], int target) -{ - int wrk[SFBMAX]; - int const dm = sfDepth(sfwork); - int const p = that->cod_info->global_gain; - int nbits; - - /* PART 1 */ - { - int bi = dm / 2; - int bi_ok = -1; - int bu = 0; - int bo = dm; - for (;;) { - int const sfmax = flattenDistribution(sfwork, wrk, dm, bi, p); - nbits = tryThatOne(that, wrk, vbrsfmin, sfmax); - if (nbits <= target) { - bi_ok = bi; - bo = bi - 1; - } - else { - bu = bi + 1; - } - if (bu <= bo) { - bi = (bu + bo) / 2; - } - else { - break; - } - } - if (bi_ok >= 0) { - if (bi != bi_ok) { - int const sfmax = flattenDistribution(sfwork, wrk, dm, bi_ok, p); - nbits = tryThatOne(that, wrk, vbrsfmin, sfmax); - } - return; - } - } - - /* PART 2: */ - { - int bi = (255 + p) / 2; - int bi_ok = -1; - int bu = p; - int bo = 255; - for (;;) { - int const sfmax = flattenDistribution(sfwork, wrk, dm, dm, bi); - nbits = tryThatOne(that, wrk, vbrsfmin, sfmax); - if (nbits <= target) { - bi_ok = bi; - bo = bi - 1; - } - else { - bu = bi + 1; - } - if (bu <= bo) { - bi = (bu + bo) / 2; - } - else { - break; - } - } - if (bi_ok >= 0) { - if (bi != bi_ok) { - int const sfmax = flattenDistribution(sfwork, wrk, dm, dm, bi_ok); - nbits = tryThatOne(that, wrk, vbrsfmin, sfmax); - } - return; - } - } - - /* fall back to old code, likely to be never called */ - searchGlobalStepsizeMax(that, wrk, vbrsfmin, target); -} - - -static int -reduce_bit_usage(lame_internal_flags * gfc, int gr, int ch -#if 0 - , const FLOAT xr34orig[576], const FLOAT l3_xmin[SFBMAX], int maxbits -#endif - ) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - gr_info *const cod_info = &gfc->l3_side.tt[gr][ch]; - /* try some better scalefac storage - */ - best_scalefac_store(gfc, gr, ch, &gfc->l3_side); - - /* best huffman_divide may save some bits too - */ - if (cfg->use_best_huffman == 1) - best_huffman_divide(gfc, cod_info); - return cod_info->part2_3_length + cod_info->part2_length; -} - - - - -int -VBR_encode_frame(lame_internal_flags * gfc, const FLOAT xr34orig[2][2][576], - const FLOAT l3_xmin[2][2][SFBMAX], const int max_bits[2][2]) -{ - SessionConfig_t const *const cfg = &gfc->cfg; - int sfwork_[2][2][SFBMAX]; - int vbrsfmin_[2][2][SFBMAX]; - algo_t that_[2][2]; - int const ngr = cfg->mode_gr; - int const nch = cfg->channels_out; - int max_nbits_ch[2][2] = {{0, 0}, {0 ,0}}; - int max_nbits_gr[2] = {0, 0}; - int max_nbits_fr = 0; - int use_nbits_ch[2][2] = {{MAX_BITS_PER_CHANNEL+1, MAX_BITS_PER_CHANNEL+1} - ,{MAX_BITS_PER_CHANNEL+1, MAX_BITS_PER_CHANNEL+1}}; - int use_nbits_gr[2] = { MAX_BITS_PER_GRANULE+1, MAX_BITS_PER_GRANULE+1 }; - int use_nbits_fr = MAX_BITS_PER_GRANULE+MAX_BITS_PER_GRANULE; - int gr, ch; - int ok, sum_fr; - - /* set up some encoding parameters - */ - for (gr = 0; gr < ngr; ++gr) { - max_nbits_gr[gr] = 0; - for (ch = 0; ch < nch; ++ch) { - max_nbits_ch[gr][ch] = max_bits[gr][ch]; - use_nbits_ch[gr][ch] = 0; - max_nbits_gr[gr] += max_bits[gr][ch]; - max_nbits_fr += max_bits[gr][ch]; - that_[gr][ch].find = (cfg->full_outer_loop < 0) ? guess_scalefac_x34 : find_scalefac_x34; - that_[gr][ch].gfc = gfc; - that_[gr][ch].cod_info = &gfc->l3_side.tt[gr][ch]; - that_[gr][ch].xr34orig = xr34orig[gr][ch]; - if (that_[gr][ch].cod_info->block_type == SHORT_TYPE) { - that_[gr][ch].alloc = short_block_constrain; - } - else { - that_[gr][ch].alloc = long_block_constrain; - } - } /* for ch */ - } - /* searches scalefactors - */ - for (gr = 0; gr < ngr; ++gr) { - for (ch = 0; ch < nch; ++ch) { - if (max_bits[gr][ch] > 0) { - algo_t *that = &that_[gr][ch]; - int *sfwork = sfwork_[gr][ch]; - int *vbrsfmin = vbrsfmin_[gr][ch]; - int vbrmax; - - vbrmax = block_sf(that, l3_xmin[gr][ch], sfwork, vbrsfmin); - that->alloc(that, sfwork, vbrsfmin, vbrmax); - bitcount(that); - } - else { - /* xr contains no energy - * l3_enc, our encoding data, will be quantized to zero - * continue with next channel - */ - } - } /* for ch */ - } - /* encode 'as is' - */ - use_nbits_fr = 0; - for (gr = 0; gr < ngr; ++gr) { - use_nbits_gr[gr] = 0; - for (ch = 0; ch < nch; ++ch) { - algo_t const *that = &that_[gr][ch]; - if (max_bits[gr][ch] > 0) { - memset(&that->cod_info->l3_enc[0], 0, sizeof(that->cod_info->l3_enc)); - (void) quantizeAndCountBits(that); - } - else { - /* xr contains no energy - * l3_enc, our encoding data, will be quantized to zero - * continue with next channel - */ - } - use_nbits_ch[gr][ch] = reduce_bit_usage(gfc, gr, ch); - use_nbits_gr[gr] += use_nbits_ch[gr][ch]; - } /* for ch */ - use_nbits_fr += use_nbits_gr[gr]; - } - - /* check bit constrains - */ - if (use_nbits_fr <= max_nbits_fr) { - ok = 1; - for (gr = 0; gr < ngr; ++gr) { - if (use_nbits_gr[gr] > MAX_BITS_PER_GRANULE) { - /* violates the rule that every granule has to use no more - * bits than MAX_BITS_PER_GRANULE - */ - ok = 0; - } - for (ch = 0; ch < nch; ++ch) { - if (use_nbits_ch[gr][ch] > MAX_BITS_PER_CHANNEL) { - /* violates the rule that every gr_ch has to use no more - * bits than MAX_BITS_PER_CHANNEL - * - * This isn't explicitly stated in the ISO docs, but the - * part2_3_length field has only 12 bits, that makes it - * up to a maximum size of 4095 bits!!! - */ - ok = 0; - } - } - } - if (ok) { - return use_nbits_fr; - } - } - - /* OK, we are in trouble and have to define how many bits are - * to be used for each granule - */ - { - ok = 1; - sum_fr = 0; - - for (gr = 0; gr < ngr; ++gr) { - max_nbits_gr[gr] = 0; - for (ch = 0; ch < nch; ++ch) { - if (use_nbits_ch[gr][ch] > MAX_BITS_PER_CHANNEL) { - max_nbits_ch[gr][ch] = MAX_BITS_PER_CHANNEL; - } - else { - max_nbits_ch[gr][ch] = use_nbits_ch[gr][ch]; - } - max_nbits_gr[gr] += max_nbits_ch[gr][ch]; - } - if (max_nbits_gr[gr] > MAX_BITS_PER_GRANULE) { - float f[2] = {0.0f, 0.0f}, s = 0.0f; - for (ch = 0; ch < nch; ++ch) { - if (max_nbits_ch[gr][ch] > 0) { - f[ch] = sqrt(sqrt(max_nbits_ch[gr][ch])); - s += f[ch]; - } - else { - f[ch] = 0; - } - } - for (ch = 0; ch < nch; ++ch) { - if (s > 0) { - max_nbits_ch[gr][ch] = MAX_BITS_PER_GRANULE * f[ch] / s; - } - else { - max_nbits_ch[gr][ch] = 0; - } - } - if (nch > 1) { - if (max_nbits_ch[gr][0] > use_nbits_ch[gr][0] + 32) { - max_nbits_ch[gr][1] += max_nbits_ch[gr][0]; - max_nbits_ch[gr][1] -= use_nbits_ch[gr][0] + 32; - max_nbits_ch[gr][0] = use_nbits_ch[gr][0] + 32; - } - if (max_nbits_ch[gr][1] > use_nbits_ch[gr][1] + 32) { - max_nbits_ch[gr][0] += max_nbits_ch[gr][1]; - max_nbits_ch[gr][0] -= use_nbits_ch[gr][1] + 32; - max_nbits_ch[gr][1] = use_nbits_ch[gr][1] + 32; - } - if (max_nbits_ch[gr][0] > MAX_BITS_PER_CHANNEL) { - max_nbits_ch[gr][0] = MAX_BITS_PER_CHANNEL; - } - if (max_nbits_ch[gr][1] > MAX_BITS_PER_CHANNEL) { - max_nbits_ch[gr][1] = MAX_BITS_PER_CHANNEL; - } - } - max_nbits_gr[gr] = 0; - for (ch = 0; ch < nch; ++ch) { - max_nbits_gr[gr] += max_nbits_ch[gr][ch]; - } - } - sum_fr += max_nbits_gr[gr]; - } - if (sum_fr > max_nbits_fr) { - { - float f[2] = {0.0f, 0.0f}, s = 0.0f; - for (gr = 0; gr < ngr; ++gr) { - if (max_nbits_gr[gr] > 0) { - f[gr] = sqrt(max_nbits_gr[gr]); - s += f[gr]; - } - else { - f[gr] = 0; - } - } - for (gr = 0; gr < ngr; ++gr) { - if (s > 0) { - max_nbits_gr[gr] = max_nbits_fr * f[gr] / s; - } - else { - max_nbits_gr[gr] = 0; - } - } - } - if (ngr > 1) { - if (max_nbits_gr[0] > use_nbits_gr[0] + 125) { - max_nbits_gr[1] += max_nbits_gr[0]; - max_nbits_gr[1] -= use_nbits_gr[0] + 125; - max_nbits_gr[0] = use_nbits_gr[0] + 125; - } - if (max_nbits_gr[1] > use_nbits_gr[1] + 125) { - max_nbits_gr[0] += max_nbits_gr[1]; - max_nbits_gr[0] -= use_nbits_gr[1] + 125; - max_nbits_gr[1] = use_nbits_gr[1] + 125; - } - for (gr = 0; gr < ngr; ++gr) { - if (max_nbits_gr[gr] > MAX_BITS_PER_GRANULE) { - max_nbits_gr[gr] = MAX_BITS_PER_GRANULE; - } - } - } - for (gr = 0; gr < ngr; ++gr) { - float f[2] = {0.0f, 0.0f}, s = 0.0f; - for (ch = 0; ch < nch; ++ch) { - if (max_nbits_ch[gr][ch] > 0) { - f[ch] = sqrt(max_nbits_ch[gr][ch]); - s += f[ch]; - } - else { - f[ch] = 0; - } - } - for (ch = 0; ch < nch; ++ch) { - if (s > 0) { - max_nbits_ch[gr][ch] = max_nbits_gr[gr] * f[ch] / s; - } - else { - max_nbits_ch[gr][ch] = 0; - } - } - if (nch > 1) { - if (max_nbits_ch[gr][0] > use_nbits_ch[gr][0] + 32) { - max_nbits_ch[gr][1] += max_nbits_ch[gr][0]; - max_nbits_ch[gr][1] -= use_nbits_ch[gr][0] + 32; - max_nbits_ch[gr][0] = use_nbits_ch[gr][0] + 32; - } - if (max_nbits_ch[gr][1] > use_nbits_ch[gr][1] + 32) { - max_nbits_ch[gr][0] += max_nbits_ch[gr][1]; - max_nbits_ch[gr][0] -= use_nbits_ch[gr][1] + 32; - max_nbits_ch[gr][1] = use_nbits_ch[gr][1] + 32; - } - for (ch = 0; ch < nch; ++ch) { - if (max_nbits_ch[gr][ch] > MAX_BITS_PER_CHANNEL) { - max_nbits_ch[gr][ch] = MAX_BITS_PER_CHANNEL; - } - } - } - } - } - /* sanity check */ - sum_fr = 0; - for (gr = 0; gr < ngr; ++gr) { - int sum_gr = 0; - for (ch = 0; ch < nch; ++ch) { - sum_gr += max_nbits_ch[gr][ch]; - if (max_nbits_ch[gr][ch] > MAX_BITS_PER_CHANNEL) { - ok = 0; - } - } - sum_fr += sum_gr; - if (sum_gr > MAX_BITS_PER_GRANULE) { - ok = 0; - } - } - if (sum_fr > max_nbits_fr) { - ok = 0; - } - if (!ok) { - /* we must have done something wrong, fallback to 'on_pe' based constrain */ - for (gr = 0; gr < ngr; ++gr) { - for (ch = 0; ch < nch; ++ch) { - max_nbits_ch[gr][ch] = max_bits[gr][ch]; - } - } - } - } - - /* we already called the 'best_scalefac_store' function, so we need to reset some - * variables before we can do it again. - */ - for (ch = 0; ch < nch; ++ch) { - gfc->l3_side.scfsi[ch][0] = 0; - gfc->l3_side.scfsi[ch][1] = 0; - gfc->l3_side.scfsi[ch][2] = 0; - gfc->l3_side.scfsi[ch][3] = 0; - } - for (gr = 0; gr < ngr; ++gr) { - for (ch = 0; ch < nch; ++ch) { - gfc->l3_side.tt[gr][ch].scalefac_compress = 0; - } - } - - /* alter our encoded data, until it fits into the target bitrate - */ - use_nbits_fr = 0; - for (gr = 0; gr < ngr; ++gr) { - use_nbits_gr[gr] = 0; - for (ch = 0; ch < nch; ++ch) { - algo_t const *that = &that_[gr][ch]; - use_nbits_ch[gr][ch] = 0; - if (max_bits[gr][ch] > 0) { - int *sfwork = sfwork_[gr][ch]; - int const *vbrsfmin = vbrsfmin_[gr][ch]; - cutDistribution(sfwork, sfwork, that->cod_info->global_gain); - outOfBitsStrategy(that, sfwork, vbrsfmin, max_nbits_ch[gr][ch]); - } - use_nbits_ch[gr][ch] = reduce_bit_usage(gfc, gr, ch); - assert(use_nbits_ch[gr][ch] <= max_nbits_ch[gr][ch]); - use_nbits_gr[gr] += use_nbits_ch[gr][ch]; - } /* for ch */ - use_nbits_fr += use_nbits_gr[gr]; - } - - /* check bit constrains, but it should always be ok, iff there are no bugs ;-) - */ - if (use_nbits_fr <= max_nbits_fr) { - return use_nbits_fr; - } - - ERRORF(gfc, "INTERNAL ERROR IN VBR NEW CODE (1313), please send bug report\n" - "maxbits=%d usedbits=%d\n", max_nbits_fr, use_nbits_fr); - exit(-1); -} diff --git a/lib-src/lame/libmp3lame/vbrquantize.h b/lib-src/lame/libmp3lame/vbrquantize.h deleted file mode 100644 index 1c0d18f07..000000000 --- a/lib-src/lame/libmp3lame/vbrquantize.h +++ /dev/null @@ -1,28 +0,0 @@ -/* - * MP3 VBR quantization - * - * Copyright (c) 1999 Mark Taylor - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_VBRQUANTIZE_H -#define LAME_VBRQUANTIZE_H - -int VBR_encode_frame(lame_internal_flags * gfc, const FLOAT xr34orig[2][2][576], - const FLOAT l3_xmin[2][2][SFBMAX], const int maxbits[2][2]); - -#endif /* LAME_VBRQUANTIZE_H */ diff --git a/lib-src/lame/libmp3lame/vector/Makefile.am b/lib-src/lame/libmp3lame/vector/Makefile.am deleted file mode 100644 index ac595b1f6..000000000 --- a/lib-src/lame/libmp3lame/vector/Makefile.am +++ /dev/null @@ -1,49 +0,0 @@ -## $Id: Makefile.am,v 1.1 2007/01/09 10:15:53 aleidinger Exp $ - -include $(top_srcdir)/Makefile.am.global - -if WITH_XMM -noinst_LTLIBRARIES = liblamevectorroutines.la -endif - -##liblamecpuroutines_la_LIBADD = -##liblamecpuroutines_la_LDFLAGS = - -INCLUDES = @INCLUDES@ \ - -I$(top_srcdir)/libmp3lame \ - -I$(top_srcdir)/mpglib \ - -I$(top_builddir) - -DEFS = @DEFS@ @CONFIG_DEFS@ - -xmm_sources = xmm_quantize_sub.c - -if WITH_XMM -liblamevectorroutines_la_SOURCES = $(xmm_sources) -endif - -noinst_HEADERS = lame_intrin.h - -EXTRA_liblamevectorroutines_la_SOURCES = $(xmm_sources) - -CLEANFILES = lclint.txt - -LCLINTFLAGS= \ - +posixlib \ - +showsummary \ - +showalluses \ - +whichlib \ - +forcehints \ - -fixedformalarray \ - +matchanyintegral \ - -Dlint - -lclint.txt: ${liblamecpuroutines_la_SOURCES} ${noinst_HEADERS} - @lclint ${LCLINTFLAGS} ${INCLUDES} ${DEFS} ${liblamecpuroutines_la_SOURCES} 2>&1 >lclint.txt || true - -lclint: lclint.txt - more lclint.txt - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck diff --git a/lib-src/lame/libmp3lame/vector/Makefile.in b/lib-src/lame/libmp3lame/vector/Makefile.in deleted file mode 100644 index c15a0cfb0..000000000 --- a/lib-src/lame/libmp3lame/vector/Makefile.in +++ /dev/null @@ -1,656 +0,0 @@ -# Makefile.in generated by automake 1.15.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2017 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# global section for every Makefile.am - - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = libmp3lame/vector -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ - $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ - $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -LTLIBRARIES = $(noinst_LTLIBRARIES) -liblamevectorroutines_la_LIBADD = -am__liblamevectorroutines_la_SOURCES_DIST = xmm_quantize_sub.c -am__objects_1 = xmm_quantize_sub.lo -@WITH_XMM_TRUE@am_liblamevectorroutines_la_OBJECTS = $(am__objects_1) -liblamevectorroutines_la_OBJECTS = \ - $(am_liblamevectorroutines_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -@WITH_XMM_TRUE@am_liblamevectorroutines_la_rpath = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(liblamevectorroutines_la_SOURCES) \ - $(EXTRA_liblamevectorroutines_la_SOURCES) -DIST_SOURCES = $(am__liblamevectorroutines_la_SOURCES_DIST) \ - $(EXTRA_liblamevectorroutines_la_SOURCES) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -HEADERS = $(noinst_HEADERS) -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/Makefile.am.global $(top_srcdir)/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -ALLOCA = @ALLOCA@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CONFIG_DEFS = @CONFIG_DEFS@ -CONFIG_MATH_LIB = @CONFIG_MATH_LIB@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CPUCCODE = @CPUCCODE@ -CPUTYPE = @CPUTYPE@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ @CONFIG_DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FRONTEND_CFLAGS = @FRONTEND_CFLAGS@ -FRONTEND_LDADD = @FRONTEND_LDADD@ -FRONTEND_LDFLAGS = @FRONTEND_LDFLAGS@ -GREP = @GREP@ -GTK_CFLAGS = @GTK_CFLAGS@ -GTK_CONFIG = @GTK_CONFIG@ -GTK_LIBS = @GTK_LIBS@ -INCLUDES = @INCLUDES@ \ - -I$(top_srcdir)/libmp3lame \ - -I$(top_srcdir)/mpglib \ - -I$(top_builddir) - -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDADD = @LDADD@ -LDFLAGS = @LDFLAGS@ -LIBICONV = @LIBICONV@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIB_MAJOR_VERSION = @LIB_MAJOR_VERSION@ -LIB_MINOR_VERSION = @LIB_MINOR_VERSION@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBICONV = @LTLIBICONV@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAINT = @MAINT@ -MAKEDEP = @MAKEDEP@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NASM = @NASM@ -NASM_FORMAT = @NASM_FORMAT@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -RANLIB = @RANLIB@ -RM_F = @RM_F@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SNDFILE_CFLAGS = @SNDFILE_CFLAGS@ -SNDFILE_LIBS = @SNDFILE_LIBS@ -STRIP = @STRIP@ -VERSION = @VERSION@ -WITH_FRONTEND = @WITH_FRONTEND@ -WITH_MP3RTP = @WITH_MP3RTP@ -WITH_MP3X = @WITH_MP3X@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = 1.15 foreign -@WITH_XMM_TRUE@noinst_LTLIBRARIES = liblamevectorroutines.la -xmm_sources = xmm_quantize_sub.c -@WITH_XMM_TRUE@liblamevectorroutines_la_SOURCES = $(xmm_sources) -noinst_HEADERS = lame_intrin.h -EXTRA_liblamevectorroutines_la_SOURCES = $(xmm_sources) -CLEANFILES = lclint.txt -LCLINTFLAGS = \ - +posixlib \ - +showsummary \ - +showalluses \ - +whichlib \ - +forcehints \ - -fixedformalarray \ - +matchanyintegral \ - -Dlint - -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/Makefile.am.global $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libmp3lame/vector/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign libmp3lame/vector/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; -$(top_srcdir)/Makefile.am.global $(am__empty): - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -liblamevectorroutines.la: $(liblamevectorroutines_la_OBJECTS) $(liblamevectorroutines_la_DEPENDENCIES) $(EXTRA_liblamevectorroutines_la_DEPENDENCIES) - $(AM_V_CCLD)$(LINK) $(am_liblamevectorroutines_la_rpath) $(liblamevectorroutines_la_OBJECTS) $(liblamevectorroutines_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xmm_quantize_sub.Plo@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LTLIBRARIES) $(HEADERS) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ - mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ - ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# end global section - -lclint.txt: ${liblamecpuroutines_la_SOURCES} ${noinst_HEADERS} - @lclint ${LCLINTFLAGS} ${INCLUDES} ${DEFS} ${liblamecpuroutines_la_SOURCES} 2>&1 >lclint.txt || true - -lclint: lclint.txt - more lclint.txt - -#$(OBJECTS): libtool -#libtool: $(LIBTOOL_DEPS) -# $(SHELL) $(top_builddir)/config.status --recheck - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/lame/libmp3lame/vector/lame_intrin.h b/lib-src/lame/libmp3lame/vector/lame_intrin.h deleted file mode 100644 index bc4c18996..000000000 --- a/lib-src/lame/libmp3lame/vector/lame_intrin.h +++ /dev/null @@ -1,33 +0,0 @@ -/* - * lame_intrin.h include file - * - * Copyright (c) 2006 Gabriel Bouvigne - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - - -#ifndef LAME_INTRIN_H -#define LAME_INTRIN_H - - -void -init_xrpow_core_sse(gr_info * const cod_info, FLOAT xrpow[576], int upper, FLOAT * sum); - -void -fht_SSE2(FLOAT* , int); - -#endif diff --git a/lib-src/lame/libmp3lame/vector/xmm_quantize_sub.c b/lib-src/lame/libmp3lame/vector/xmm_quantize_sub.c deleted file mode 100644 index d68f7618a..000000000 --- a/lib-src/lame/libmp3lame/vector/xmm_quantize_sub.c +++ /dev/null @@ -1,240 +0,0 @@ -/* - * MP3 quantization, intrinsics functions - * - * Copyright (c) 2005-2006 Gabriel Bouvigne - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "lame.h" -#include "machine.h" -#include "encoder.h" -#include "util.h" -#include "lame_intrin.h" - - - -#ifdef HAVE_XMMINTRIN_H - -#include - -typedef union { - int32_t _i_32[4]; /* unions are initialized by its first member */ - float _float[4]; - __m128 _m128; -} vecfloat_union; - -#define TRI_SIZE (5-1) /* 1024 = 4**5 */ -static const FLOAT costab[TRI_SIZE * 2] = { - 9.238795325112867e-01, 3.826834323650898e-01, - 9.951847266721969e-01, 9.801714032956060e-02, - 9.996988186962042e-01, 2.454122852291229e-02, - 9.999811752826011e-01, 6.135884649154475e-03 -}; - - -/* make sure functions with SSE instructions maintain their own properly aligned stack */ -#if defined (__GNUC__) && ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 2))) -#define SSE_FUNCTION __attribute__((force_align_arg_pointer)) -#else -#define SSE_FUNCTION -#endif - - -SSE_FUNCTION void -init_xrpow_core_sse(gr_info * const cod_info, FLOAT xrpow[576], int upper, FLOAT * sum) -{ - int i; - float tmp_max = 0; - float tmp_sum = 0; - int upper4 = (upper / 4) * 4; - int rest = upper-upper4; - - const vecfloat_union fabs_mask = {{ 0x7FFFFFFF, 0x7FFFFFFF, 0x7FFFFFFF, 0x7FFFFFFF }}; - const __m128 vec_fabs_mask = _mm_loadu_ps(&fabs_mask._float[0]); - vecfloat_union vec_xrpow_max; - vecfloat_union vec_sum; - vecfloat_union vec_tmp; - - _mm_prefetch((char *) cod_info->xr, _MM_HINT_T0); - _mm_prefetch((char *) xrpow, _MM_HINT_T0); - - vec_xrpow_max._m128 = _mm_set_ps1(0); - vec_sum._m128 = _mm_set_ps1(0); - - for (i = 0; i < upper4; i += 4) { - vec_tmp._m128 = _mm_loadu_ps(&(cod_info->xr[i])); /* load */ - vec_tmp._m128 = _mm_and_ps(vec_tmp._m128, vec_fabs_mask); /* fabs */ - vec_sum._m128 = _mm_add_ps(vec_sum._m128, vec_tmp._m128); - vec_tmp._m128 = _mm_sqrt_ps(_mm_mul_ps(vec_tmp._m128, _mm_sqrt_ps(vec_tmp._m128))); - vec_xrpow_max._m128 = _mm_max_ps(vec_xrpow_max._m128, vec_tmp._m128); /* retrieve max */ - _mm_storeu_ps(&(xrpow[i]), vec_tmp._m128); /* store into xrpow[] */ - } - vec_tmp._m128 = _mm_set_ps1(0); - switch (rest) { - case 3: vec_tmp._float[2] = cod_info->xr[upper4+2]; - case 2: vec_tmp._float[1] = cod_info->xr[upper4+1]; - case 1: vec_tmp._float[0] = cod_info->xr[upper4+0]; - vec_tmp._m128 = _mm_and_ps(vec_tmp._m128, vec_fabs_mask); /* fabs */ - vec_sum._m128 = _mm_add_ps(vec_sum._m128, vec_tmp._m128); - vec_tmp._m128 = _mm_sqrt_ps(_mm_mul_ps(vec_tmp._m128, _mm_sqrt_ps(vec_tmp._m128))); - vec_xrpow_max._m128 = _mm_max_ps(vec_xrpow_max._m128, vec_tmp._m128); /* retrieve max */ - switch (rest) { - case 3: xrpow[upper4+2] = vec_tmp._float[2]; - case 2: xrpow[upper4+1] = vec_tmp._float[1]; - case 1: xrpow[upper4+0] = vec_tmp._float[0]; - default: - break; - } - default: - break; - } - tmp_sum = vec_sum._float[0] + vec_sum._float[1] + vec_sum._float[2] + vec_sum._float[3]; - { - float ma = vec_xrpow_max._float[0] > vec_xrpow_max._float[1] - ? vec_xrpow_max._float[0] : vec_xrpow_max._float[1]; - float mb = vec_xrpow_max._float[2] > vec_xrpow_max._float[3] - ? vec_xrpow_max._float[2] : vec_xrpow_max._float[3]; - tmp_max = ma > mb ? ma : mb; - } - cod_info->xrpow_max = tmp_max; - *sum = tmp_sum; -} - - -SSE_FUNCTION static void -store4(__m128 v, float* f0, float* f1, float* f2, float* f3) -{ - vecfloat_union r; - r._m128 = v; - *f0 = r._float[0]; - *f1 = r._float[1]; - *f2 = r._float[2]; - *f3 = r._float[3]; -} - - -SSE_FUNCTION void -fht_SSE2(FLOAT * fz, int n) -{ - const FLOAT *tri = costab; - int k4; - FLOAT *fi, *gi; - FLOAT const *fn; - - n <<= 1; /* to get BLKSIZE, because of 3DNow! ASM routine */ - fn = fz + n; - k4 = 4; - do { - FLOAT s1, c1; - int i, k1, k2, k3, kx; - kx = k4 >> 1; - k1 = k4; - k2 = k4 << 1; - k3 = k2 + k1; - k4 = k2 << 1; - fi = fz; - gi = fi + kx; - do { - FLOAT f0, f1, f2, f3; - f1 = fi[0] - fi[k1]; - f0 = fi[0] + fi[k1]; - f3 = fi[k2] - fi[k3]; - f2 = fi[k2] + fi[k3]; - fi[k2] = f0 - f2; - fi[0] = f0 + f2; - fi[k3] = f1 - f3; - fi[k1] = f1 + f3; - f1 = gi[0] - gi[k1]; - f0 = gi[0] + gi[k1]; - f3 = SQRT2 * gi[k3]; - f2 = SQRT2 * gi[k2]; - gi[k2] = f0 - f2; - gi[0] = f0 + f2; - gi[k3] = f1 - f3; - gi[k1] = f1 + f3; - gi += k4; - fi += k4; - } while (fi < fn); - c1 = tri[0]; - s1 = tri[1]; - for (i = 1; i < kx; i++) { - __m128 v_s2; - __m128 v_c2; - __m128 v_c1; - __m128 v_s1; - FLOAT c2, s2, s1_2 = s1+s1; - c2 = 1 - s1_2 * s1; - s2 = s1_2 * c1; - fi = fz + i; - gi = fz + k1 - i; - v_c1 = _mm_set_ps1(c1); - v_s1 = _mm_set_ps1(s1); - v_c2 = _mm_set_ps1(c2); - v_s2 = _mm_set_ps1(s2); - { - static const vecfloat_union sign_mask = {{0x80000000,0,0,0}}; - v_c1 = _mm_xor_ps(sign_mask._m128, v_c1); /* v_c1 := {-c1, +c1, +c1, +c1} */ - } - { - static const vecfloat_union sign_mask = {{0,0x80000000,0,0}}; - v_s1 = _mm_xor_ps(sign_mask._m128, v_s1); /* v_s1 := {+s1, -s1, +s1, +s1} */ - } - { - static const vecfloat_union sign_mask = {{0,0,0x80000000,0x80000000}}; - v_c2 = _mm_xor_ps(sign_mask._m128, v_c2); /* v_c2 := {+c2, +c2, -c2, -c2} */ - } - do { - __m128 p, q, r; - - q = _mm_setr_ps(fi[k1], fi[k3], gi[k1], gi[k3]); /* Q := {fi_k1,fi_k3,gi_k1,gi_k3}*/ - p = _mm_mul_ps(_mm_set_ps1(s2), q); /* P := s2 * Q */ - q = _mm_mul_ps(v_c2, q); /* Q := c2 * Q */ - q = _mm_shuffle_ps(q, q, _MM_SHUFFLE(1,0,3,2)); /* Q := {-c2*gi_k1,-c2*gi_k3,c2*fi_k1,c2*fi_k3} */ - p = _mm_add_ps(p, q); - - r = _mm_setr_ps(gi[0], gi[k2], fi[0], fi[k2]); /* R := {gi_0,gi_k2,fi_0,fi_k2} */ - q = _mm_sub_ps(r, p); /* Q := {gi_0-p0,gi_k2-p1,fi_0-p2,fi_k2-p3} */ - r = _mm_add_ps(r, p); /* R := {gi_0+p0,gi_k2+p1,fi_0+p2,fi_k2+p3} */ - p = _mm_shuffle_ps(q, r, _MM_SHUFFLE(2,0,2,0)); /* P := {q0,q2,r0,r2} */ - p = _mm_shuffle_ps(p, p, _MM_SHUFFLE(3,1,2,0)); /* P := {q0,r0,q2,r2} */ - q = _mm_shuffle_ps(q, r, _MM_SHUFFLE(3,1,3,1)); /* Q := {q1,q3,r1,r3} */ - r = _mm_mul_ps(v_c1, q); - q = _mm_mul_ps(v_s1, q); - q = _mm_shuffle_ps(q, q, _MM_SHUFFLE(0,1,2,3)); /* Q := {q3,q2,q1,q0} */ - q = _mm_add_ps(q, r); - - store4(_mm_sub_ps(p, q), &gi[k3], &gi[k2], &fi[k3], &fi[k2]); - store4(_mm_add_ps(p, q), &gi[k1], &gi[ 0], &fi[k1], &fi[ 0]); - - gi += k4; - fi += k4; - } while (fi < fn); - c2 = c1; - c1 = c2 * tri[0] - s1 * tri[1]; - s1 = c2 * tri[1] + s1 * tri[0]; - } - tri += 2; - } while (k4 < n); -} - -#endif /* HAVE_XMMINTRIN_H */ - diff --git a/lib-src/lame/libmp3lame/version.c b/lib-src/lame/libmp3lame/version.c deleted file mode 100644 index 29434062a..000000000 --- a/lib-src/lame/libmp3lame/version.c +++ /dev/null @@ -1,254 +0,0 @@ -/* - * Version numbering for LAME. - * - * Copyright (c) 1999 A.L. Faber - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/*! - \file version.c - \brief Version numbering for LAME. - - Contains functions which describe the version of LAME. - - \author A.L. Faber - \version \$Id: version.c,v 1.34 2011/11/18 09:51:02 robert Exp $ - \ingroup libmp3lame -*/ - - -#ifdef HAVE_CONFIG_H -# include -#endif - - -#include "lame.h" -#include "machine.h" - -#include "version.h" /* macros of version numbers */ - - - - - -/*! Get the LAME version string. */ -/*! - \param void - \return a pointer to a string which describes the version of LAME. -*/ -const char * -get_lame_version(void) -{ /* primary to write screen reports */ - /* Here we can also add informations about compile time configurations */ - -#if LAME_ALPHA_VERSION - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) " " - "(alpha " STR(LAME_PATCH_VERSION) ", " __DATE__ " " __TIME__ ")"; -#elif LAME_BETA_VERSION - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) " " - "(beta " STR(LAME_PATCH_VERSION) ", " __DATE__ ")"; -#elif LAME_RELEASE_VERSION && (LAME_PATCH_VERSION > 0) - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) "." STR(LAME_PATCH_VERSION); -#else - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION); -#endif - - return str; -} - - -/*! Get the short LAME version string. */ -/*! - It's mainly for inclusion into the MP3 stream. - - \param void - \return a pointer to the short version of the LAME version string. -*/ -const char * -get_lame_short_version(void) -{ - /* adding date and time to version string makes it harder for output - validation */ - -#if LAME_ALPHA_VERSION - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) " (alpha " STR(LAME_PATCH_VERSION) ")"; -#elif LAME_BETA_VERSION - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) " (beta " STR(LAME_PATCH_VERSION) ")"; -#elif LAME_RELEASE_VERSION && (LAME_PATCH_VERSION > 0) - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) "." STR(LAME_PATCH_VERSION); -#else - static /*@observer@ */ const char *const str = - STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION); -#endif - - return str; -} - -/*! Get the _very_ short LAME version string. */ -/*! - It's used in the LAME VBR tag only. - - \param void - \return a pointer to the short version of the LAME version string. -*/ -const char * -get_lame_very_short_version(void) -{ - /* adding date and time to version string makes it harder for output - validation */ -#if LAME_ALPHA_VERSION -#define P "a" -#elif LAME_BETA_VERSION -#define P "b" -#elif LAME_RELEASE_VERSION && (LAME_PATCH_VERSION > 0) -#define P "r" -#else -#define P " " -#endif - static /*@observer@ */ const char *const str = -#if (LAME_PATCH_VERSION > 0) - "LAME" STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) P STR(LAME_PATCH_VERSION) -#else - "LAME" STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) P -#endif - ; - return str; -} - -/*! Get the _very_ short LAME version string. */ -/*! - It's used in the LAME VBR tag only, limited to 9 characters max. - Due to some 3rd party HW/SW decoders, it has to start with LAME. - - \param void - \return a pointer to the short version of the LAME version string. - */ -const char* -get_lame_tag_encoder_short_version(void) -{ - static /*@observer@ */ const char *const str = - /* FIXME: new scheme / new version counting / drop versioning here ? */ - "LAME" STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) P - ; - return str; -} - -/*! Get the version string for GPSYCHO. */ -/*! - \param void - \return a pointer to a string which describes the version of GPSYCHO. -*/ -const char * -get_psy_version(void) -{ -#if PSY_ALPHA_VERSION > 0 - static /*@observer@ */ const char *const str = - STR(PSY_MAJOR_VERSION) "." STR(PSY_MINOR_VERSION) - " (alpha " STR(PSY_ALPHA_VERSION) ", " __DATE__ " " __TIME__ ")"; -#elif PSY_BETA_VERSION > 0 - static /*@observer@ */ const char *const str = - STR(PSY_MAJOR_VERSION) "." STR(PSY_MINOR_VERSION) - " (beta " STR(PSY_BETA_VERSION) ", " __DATE__ ")"; -#else - static /*@observer@ */ const char *const str = - STR(PSY_MAJOR_VERSION) "." STR(PSY_MINOR_VERSION); -#endif - - return str; -} - - -/*! Get the URL for the LAME website. */ -/*! - \param void - \return a pointer to a string which is a URL for the LAME website. -*/ -const char * -get_lame_url(void) -{ - static /*@observer@ */ const char *const str = LAME_URL; - - return str; -} - - -/*! Get the numerical representation of the version. */ -/*! - Writes the numerical representation of the version of LAME and - GPSYCHO into lvp. - - \param lvp -*/ -void -get_lame_version_numerical(lame_version_t * lvp) -{ - static /*@observer@ */ const char *const features = ""; /* obsolete */ - - /* generic version */ - lvp->major = LAME_MAJOR_VERSION; - lvp->minor = LAME_MINOR_VERSION; -#if LAME_ALPHA_VERSION - lvp->alpha = LAME_PATCH_VERSION; - lvp->beta = 0; -#elif LAME_BETA_VERSION - lvp->alpha = 0; - lvp->beta = LAME_PATCH_VERSION; -#else - lvp->alpha = 0; - lvp->beta = 0; -#endif - - /* psy version */ - lvp->psy_major = PSY_MAJOR_VERSION; - lvp->psy_minor = PSY_MINOR_VERSION; - lvp->psy_alpha = PSY_ALPHA_VERSION; - lvp->psy_beta = PSY_BETA_VERSION; - - /* compile time features */ - /*@-mustfree@ */ - lvp->features = features; - /*@=mustfree@ */ -} - - -const char * -get_lame_os_bitness(void) -{ - static /*@observer@ */ const char *const strXX = ""; - static /*@observer@ */ const char *const str32 = "32bits"; - static /*@observer@ */ const char *const str64 = "64bits"; - - switch (sizeof(void *)) { - case 4: - return str32; - - case 8: - return str64; - - default: - return strXX; - } -} - -/* end of version.c */ diff --git a/lib-src/lame/libmp3lame/version.h b/lib-src/lame/libmp3lame/version.h deleted file mode 100644 index f5fef508a..000000000 --- a/lib-src/lame/libmp3lame/version.h +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Version numbering for LAME. - * - * Copyright (c) 1999 A.L. Faber - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef LAME_VERSION_H -#define LAME_VERSION_H - - -/* - * To make a string from a token, use the # operator: - */ -#ifndef STR -# define __STR(x) #x -# define STR(x) __STR(x) -#endif - -# define LAME_URL "http://lame.sf.net" - - -# define LAME_MAJOR_VERSION 3 /* Major version number */ -# define LAME_MINOR_VERSION 100 /* Minor version number */ -# define LAME_TYPE_VERSION 2 /* 0:alpha 1:beta 2:release */ -# define LAME_PATCH_VERSION 0 /* Patch level */ -# define LAME_ALPHA_VERSION (LAME_TYPE_VERSION==0) -# define LAME_BETA_VERSION (LAME_TYPE_VERSION==1) -# define LAME_RELEASE_VERSION (LAME_TYPE_VERSION==2) - -# define PSY_MAJOR_VERSION 1 /* Major version number */ -# define PSY_MINOR_VERSION 0 /* Minor version number */ -# define PSY_ALPHA_VERSION 0 /* Set number if this is an alpha version, otherwise zero */ -# define PSY_BETA_VERSION 0 /* Set number if this is a beta version, otherwise zero */ - -#if LAME_ALPHA_VERSION -#define LAME_PATCH_LEVEL_STRING " alpha " STR(LAME_PATCH_VERSION) -#endif -#if LAME_BETA_VERSION -#define LAME_PATCH_LEVEL_STRING " beta " STR(LAME_PATCH_VERSION) -#endif -#if LAME_RELEASE_VERSION -#if LAME_PATCH_VERSION -#define LAME_PATCH_LEVEL_STRING " release " STR(LAME_PATCH_VERSION) -#else -#define LAME_PATCH_LEVEL_STRING "" -#endif -#endif - -# define LAME_VERSION_STRING STR(LAME_MAJOR_VERSION) "." STR(LAME_MINOR_VERSION) LAME_PATCH_LEVEL_STRING - -#endif /* LAME_VERSION_H */ - -/* End of version.h */ diff --git a/lib-src/libid3tag/CHANGES b/lib-src/libid3tag/CHANGES deleted file mode 100644 index fc6b51a2d..000000000 --- a/lib-src/libid3tag/CHANGES +++ /dev/null @@ -1,83 +0,0 @@ - - libid3tag - ID3 tag manipulation library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: CHANGES,v 1.2 2004-06-08 06:38:14 dmazzoni Exp $ - -=============================================================================== - -Version 0.15.1 (beta) - - * Updated to autoconf 2.59, automake 1.8.2, libtool 1.5.2. - - * Fixed a potential problem in file.c when writing empty ID3v2 tags. - - * Added new id3_field_gettextencoding() API routine. - -Version 0.15.0 (beta) - - * Updated to autoconf 2.57, automake 1.7.5, libtool 1.4.3. - - * Added new id3_tag_version(), id3_tag_options(), id3_tag_setlength(), - id3_frame_field(), id3_field_getlatin1(), id3_field_getfulllatin1(), - id3_genre_index(), id3_genre_number(), id3_latin1_ucs4duplicate(), - id3_utf16_ucs4duplicate(), and id3_utf8_ucs4duplicate() API routines. - - * Properly exposed the id3_frame_new(), id3_frame_delete(), and - id3_field_type() API routines. - - * Fixed a possible segmentation fault rendering ID3v1 tags when a tag - field exceeds the field length limit. - - * Fixed a problem whereby the file interface could try to seek and read - data from a non-seekable stream, unrecoverably losing data from the - stream. (N.B. the fix does not work under Win32.) - - * Fixed a problem reading ID3v2.2 frames which corrupted their frame IDs - and caused them not to be re-rendered. - - * Improved rendering of the ID3v1 genre field from ID3v2 genre - names/numbers. The genre "Other" is used in place of non-translatable - genres. - - * Rendering an empty ID3v1 tag now properly returns 0 length even when a - null buffer pointer is passed. - - * Changed the file implementation to maintain information about present - but unparseable tags, instead of ignoring all tags and returning an - error. - - * Added an external dependency on zlib (libz), which is no longer - included. - - * Changed to build a shared library by default. - - * Changed to use native Cygwin build by default; give --host=mingw32 to - `configure' to use MinGW (and avoid a dependency on the Cygwin DLL). - -Version 0.14.2 (beta) - - * Changed Cygwin builds to use MinGW; resulting Win32 executables no - longer have a dependency on Cygwin DLLs. - -Version 0.14.1 (beta) - - * Updated config.guess and config.sub to latest upstream versions. - - * Enabled libtool versioning rather than release numbering. - - * Renamed `libid3' to `libid3tag' and enabled installation as a separate - library. - - * Several other small fixes. - -Version 0.14.0 (beta) - - * Added a new ID3 tag manipulation library (libid3). The required zlib - support is provided either by the host system or by the included static - library implementation (libz). - - * Improved MSVC++ portability and added MSVC++ project files. - -=============================================================================== - diff --git a/lib-src/libid3tag/COPYING b/lib-src/libid3tag/COPYING deleted file mode 100644 index d60c31a97..000000000 --- a/lib-src/libid3tag/COPYING +++ /dev/null @@ -1,340 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc. - 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Library General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - - Gnomovision version 69, Copyright (C) year name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - , 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Library General -Public License instead of this License. diff --git a/lib-src/libid3tag/COPYRIGHT b/lib-src/libid3tag/COPYRIGHT deleted file mode 100644 index 072f7e247..000000000 --- a/lib-src/libid3tag/COPYRIGHT +++ /dev/null @@ -1,21 +0,0 @@ - - libid3tag - ID3 tag manipulation library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - If you would like to negotiate alternate licensing terms, you may do - so by contacting: Underbit Technologies, Inc. - diff --git a/lib-src/libid3tag/CREDITS b/lib-src/libid3tag/CREDITS deleted file mode 100644 index f69cfa4ba..000000000 --- a/lib-src/libid3tag/CREDITS +++ /dev/null @@ -1,28 +0,0 @@ - - libid3tag - ID3 tag manipulation library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: CREDITS,v 1.2 2004-06-08 06:38:14 dmazzoni Exp $ - -=============================================================================== - -AUTHOR - - Except where otherwise noted, all code was authored by: - - Robert Leslie - -CONTRIBUTORS - - Significant contributions have been incorporated with thanks to: - - Mark Malson - 2002/10/09: frame.c - - Reported problem reading ID3v2.2 tag frames. - - Brett Paterson - 2001/10/28: global.h - - Reported missing et al. under MS Embedded Visual C. - -=============================================================================== - diff --git a/lib-src/libid3tag/INSTALL b/lib-src/libid3tag/INSTALL deleted file mode 100644 index 50dbe439d..000000000 --- a/lib-src/libid3tag/INSTALL +++ /dev/null @@ -1,183 +0,0 @@ -Basic Installation -================== - - These are generic installation instructions. - - The `configure' shell script attempts to guess correct values for -various system-dependent variables used during compilation. It uses -those values to create a `Makefile' in each directory of the package. -It may also create one or more `.h' files containing system-dependent -definitions. Finally, it creates a shell script `config.status' that -you can run in the future to recreate the current configuration, a file -`config.cache' that saves the results of its tests to speed up -reconfiguring, and a file `config.log' containing compiler output -(useful mainly for debugging `configure'). - - If you need to do unusual things to compile the package, please try -to figure out how `configure' could check whether to do them, and mail -diffs or instructions to the address given in the `README' so they can -be considered for the next release. If at some point `config.cache' -contains results you don't want to keep, you may remove or edit it. - - The file `configure.in' is used to create `configure' by a program -called `autoconf'. You only need `configure.in' if you want to change -it or regenerate `configure' using a newer version of `autoconf'. - -The simplest way to compile this package is: - - 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. If you're - using `csh' on an old version of System V, you might need to type - `sh ./configure' instead to prevent `csh' from trying to execute - `configure' itself. - - Running `configure' takes awhile. While running, it prints some - messages telling which features it is checking for. - - 2. Type `make' to compile the package. - - 3. Optionally, type `make check' to run any self-tests that come with - the package. - - 4. Type `make install' to install the programs and any data files and - documentation. - - 5. You can remove the program binaries and object files from the - source code directory by typing `make clean'. To also remove the - files that `configure' created (so you can compile the package for - a different kind of computer), type `make distclean'. There is - also a `make maintainer-clean' target, but that is intended mainly - for the package's developers. If you use it, you may have to get - all sorts of other programs in order to regenerate files that came - with the distribution. - -Compilers and Options -===================== - - Some systems require unusual options for compilation or linking that -the `configure' script does not know about. You can give `configure' -initial values for variables by setting them in the environment. Using -a Bourne-compatible shell, you can do that on the command line like -this: - CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure - -Or on systems that have the `env' program, you can do it like this: - env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure - -Compiling For Multiple Architectures -==================================== - - You can compile the package for more than one kind of computer at the -same time, by placing the object files for each architecture in their -own directory. To do this, you must use a version of `make' that -supports the `VPATH' variable, such as GNU `make'. `cd' to the -directory where you want the object files and executables to go and run -the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. - - If you have to use a `make' that does not supports the `VPATH' -variable, you have to compile the package for one architecture at a time -in the source code directory. After you have installed the package for -one architecture, use `make distclean' before reconfiguring for another -architecture. - -Installation Names -================== - - By default, `make install' will install the package's files in -`/usr/local/bin', `/usr/local/man', etc. You can specify an -installation prefix other than `/usr/local' by giving `configure' the -option `--prefix=PATH'. - - You can specify separate installation prefixes for -architecture-specific files and architecture-independent files. If you -give `configure' the option `--exec-prefix=PATH', the package will use -PATH as the prefix for installing programs and libraries. -Documentation and other data files will still use the regular prefix. - - In addition, if you use an unusual directory layout you can give -options like `--bindir=PATH' to specify different values for particular -kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. - - If the package supports it, you can cause programs to be installed -with an extra prefix or suffix on their names by giving `configure' the -option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. - -Optional Features -================= - - Some packages pay attention to `--enable-FEATURE' options to -`configure', where FEATURE indicates an optional part of the package. -They may also pay attention to `--with-PACKAGE' options, where PACKAGE -is something like `gnu-as' or `x' (for the X Window System). The -`README' should mention any `--enable-' and `--with-' options that the -package recognizes. - - For packages that use the X Window System, `configure' can usually -find the X include and library files automatically, but if it doesn't, -you can use the `configure' options `--x-includes=DIR' and -`--x-libraries=DIR' to specify their locations. - -Specifying the System Type -========================== - - There may be some features `configure' can not figure out -automatically, but needs to determine by the type of host the package -will run on. Usually `configure' can figure that out, but if it prints -a message saying it can not guess the host type, give it the -`--host=TYPE' option. TYPE can either be a short name for the system -type, such as `sun4', or a canonical name with three fields: - CPU-COMPANY-SYSTEM - -See the file `config.sub' for the possible values of each field. If -`config.sub' isn't included in this package, then this package doesn't -need to know the host type. - - If you are building compiler tools for cross-compiling, you can also -use the `--target=TYPE' option to select the type of system they will -produce code for and the `--build=TYPE' option to select the type of -system on which you are compiling the package. - -Sharing Defaults -================ - - If you want to set default values for `configure' scripts to share, -you can create a site shell script called `config.site' that gives -default values for variables like `CC', `cache_file', and `prefix'. -`configure' looks for `PREFIX/share/config.site' if it exists, then -`PREFIX/etc/config.site' if it exists. Or, you can set the -`CONFIG_SITE' environment variable to the location of the site script. -A warning: not all `configure' scripts look for a site script. - -Operation Controls -================== - - `configure' recognizes the following options to control how it -operates. - -`--cache-file=FILE' - Use and save the results of the tests in FILE instead of - `./config.cache'. Set FILE to `/dev/null' to disable caching, for - debugging `configure'. - -`--help' - Print a summary of the options to `configure', and exit. - -`--quiet' -`--silent' -`-q' - Do not print messages saying which checks are being made. To - suppress all normal output, redirect it to `/dev/null' (any error - messages will still be shown). - -`--srcdir=DIR' - Look for the package's source code in directory DIR. Usually - `configure' can determine that directory automatically. - -`--version' - Print the version of Autoconf used to generate the `configure' - script, and exit. - -`configure' also accepts some other, not widely useful, options. - diff --git a/lib-src/libid3tag/Makefile.am b/lib-src/libid3tag/Makefile.am deleted file mode 100644 index 310722f08..000000000 --- a/lib-src/libid3tag/Makefile.am +++ /dev/null @@ -1,126 +0,0 @@ -## -## libid3tag - ID3 tag manipulation library -## Copyright (C) 2000-2004 Underbit Technologies, Inc. -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License -## along with this program; if not, write to the Free Software -## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -## -## $Id: Makefile.am,v 1.4 2009-01-23 23:39:44 richardash1981 Exp $ -## - -## Process this file with automake to produce Makefile.in - -# tell aclocal that extra macros can be found in m4/ -ACLOCAL_AMFLAGS = -I m4 - -SUBDIRS = -DIST_SUBDIRS = msvc++ - -lib_LTLIBRARIES = libid3tag.la -include_HEADERS = id3tag.h - -## From the libtool documentation on library versioning: -## -## CURRENT -## The most recent interface number that this library implements. -## -## REVISION -## The implementation number of the CURRENT interface. -## -## AGE -## The difference between the newest and oldest interfaces that this -## library implements. In other words, the library implements all the -## interface numbers in the range from number `CURRENT - AGE' to -## `CURRENT'. -## -## If two libraries have identical CURRENT and AGE numbers, then the -## dynamic linker chooses the library with the greater REVISION number. -## -## 1. Start with version information of `0:0:0' for each libtool library. -## -## 2. Update the version information only immediately before a public -## release of your software. More frequent updates are unnecessary, -## and only guarantee that the current interface number gets larger -## faster. -## -## 3. If the library source code has changed at all since the last -## update, then increment REVISION (`C:R:A' becomes `C:r+1:A'). -## -## 4. If any interfaces have been added, removed, or changed since the -## last update, increment CURRENT, and set REVISION to 0. -## -## 5. If any interfaces have been added since the last public release, -## then increment AGE. -## -## 6. If any interfaces have been removed since the last public release, -## then set AGE to 0. - -version_current = 3 -version_revision = 0 -version_age = 3 - -version_info = $(version_current):$(version_revision):$(version_age) - -EXTRA_DIST = genre.dat.sed \ - CHANGES COPYRIGHT CREDITS README TODO VERSION - -if DEBUG -debug = debug.c debug.h -else -debug = -endif - -libid3tag_la_SOURCES = version.c ucs4.c latin1.c utf16.c utf8.c \ - parse.c render.c field.c frametype.c compat.c \ - genre.c frame.c crc.c util.c tag.c file.c \ - version.h ucs4.h latin1.h utf16.h utf8.h \ - parse.h render.h field.h frametype.h compat.h \ - genre.h frame.h crc.h util.h tag.h file.h \ - id3tag.h global.h genre.dat $(debug) - -EXTRA_libid3tag_la_SOURCES = \ - frametype.gperf compat.gperf genre.dat.in \ - debug.c debug.h - -libid3tag_la_LDFLAGS = -version-info $(version_info) - -#BUILT_SOURCES = frametype.c compat.c genre.dat -# -#$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -# cd $(srcdir) && \ -# gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -# frametype.gperf | \ -# sed -e 's/\(struct id3_frametype\);/\1/' | \ -# sed -e '/\$$''Id: /s/\$$//g' >frametype.c -# -#$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -# cd $(srcdir) && \ -# gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -# compat.gperf | \ -# sed -e 's/\(struct id3_compat\);/\1/' | \ -# sed -e '/\$$''Id: /s/\$$//g' >compat.c -# -#$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -# cd $(srcdir) && \ -# sed -n -f genre.dat.sed genre.dat.in | \ -# sed -e '/\$$''Id: /s/\$$//g' >genre.dat - -libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - -again: - $(MAKE) clean - $(MAKE) - -.PHONY: again diff --git a/lib-src/libid3tag/Makefile.in b/lib-src/libid3tag/Makefile.in deleted file mode 100644 index 4070ad3e4..000000000 --- a/lib-src/libid3tag/Makefile.in +++ /dev/null @@ -1,1048 +0,0 @@ -# Makefile.in generated by automake 1.14.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2013 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - -VPATH = @srcdir@ -am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = . -DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ - $(top_srcdir)/configure $(am__configure_deps) \ - $(srcdir)/config.h.in mkinstalldirs \ - $(srcdir)/libid3tag.list.in depcomp $(include_HEADERS) COPYING \ - INSTALL README TODO compile config.guess config.sub install-sh \ - missing ltmain.sh ltconfig -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ - $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ - $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs -CONFIG_HEADER = config.h -CONFIG_CLEAN_FILES = libid3tag.list -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)" -LTLIBRARIES = $(lib_LTLIBRARIES) -libid3tag_la_LIBADD = -am__libid3tag_la_SOURCES_DIST = version.c ucs4.c latin1.c utf16.c \ - utf8.c parse.c render.c field.c frametype.c compat.c genre.c \ - frame.c crc.c util.c tag.c file.c version.h ucs4.h latin1.h \ - utf16.h utf8.h parse.h render.h field.h frametype.h compat.h \ - genre.h frame.h crc.h util.h tag.h file.h id3tag.h global.h \ - genre.dat debug.c debug.h -@DEBUG_TRUE@am__objects_1 = debug.lo -am_libid3tag_la_OBJECTS = version.lo ucs4.lo latin1.lo utf16.lo \ - utf8.lo parse.lo render.lo field.lo frametype.lo compat.lo \ - genre.lo frame.lo crc.lo util.lo tag.lo file.lo \ - $(am__objects_1) -libid3tag_la_OBJECTS = $(am_libid3tag_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libid3tag_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(libid3tag_la_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(libid3tag_la_SOURCES) $(EXTRA_libid3tag_la_SOURCES) -DIST_SOURCES = $(am__libid3tag_la_SOURCES_DIST) \ - $(EXTRA_libid3tag_la_SOURCES) -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -HEADERS = $(include_HEADERS) -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - cscope distdir dist dist-all distcheck -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ - $(LISP)config.h.in -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -CSCOPE = cscope -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - if test -d "$(distdir)"; then \ - find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -rf "$(distdir)" \ - || { sleep 5 && rm -rf "$(distdir)"; }; \ - else :; fi -am__post_remove_distdir = $(am__remove_distdir) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -DIST_ARCHIVES = $(distdir).tar.gz -GZIP_ENV = --best -DIST_TARGETS = dist-gzip -distuninstallcheck_listfiles = find . -type f -print -am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ - | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ - -# tell aclocal that extra macros can be found in m4/ -ACLOCAL_AMFLAGS = -I m4 -SUBDIRS = -DIST_SUBDIRS = msvc++ -lib_LTLIBRARIES = libid3tag.la -include_HEADERS = id3tag.h -version_current = 3 -version_revision = 0 -version_age = 3 -version_info = $(version_current):$(version_revision):$(version_age) -EXTRA_DIST = genre.dat.sed \ - CHANGES COPYRIGHT CREDITS README TODO VERSION - -@DEBUG_FALSE@debug = -@DEBUG_TRUE@debug = debug.c debug.h -libid3tag_la_SOURCES = version.c ucs4.c latin1.c utf16.c utf8.c \ - parse.c render.c field.c frametype.c compat.c \ - genre.c frame.c crc.c util.c tag.c file.c \ - version.h ucs4.h latin1.h utf16.h utf8.h \ - parse.h render.h field.h frametype.h compat.h \ - genre.h frame.h crc.h util.h tag.h file.h \ - id3tag.h global.h genre.dat $(debug) - -EXTRA_libid3tag_la_SOURCES = \ - frametype.gperf compat.gperf genre.dat.in \ - debug.c debug.h - -libid3tag_la_LDFLAGS = -version-info $(version_info) -all: config.h - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -am--refresh: Makefile - @: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ - $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - $(am__cd) $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) -$(am__aclocal_m4_deps): - -config.h: stamp-h1 - @test -f $@ || rm -f stamp-h1 - @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 - -stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status - @rm -f stamp-h1 - cd $(top_builddir) && $(SHELL) ./config.status config.h -$(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) - rm -f stamp-h1 - touch $@ - -distclean-hdr: - -rm -f config.h stamp-h1 -libid3tag.list: $(top_builddir)/config.status $(srcdir)/libid3tag.list.in - cd $(top_builddir) && $(SHELL) ./config.status $@ - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libid3tag.la: $(libid3tag_la_OBJECTS) $(libid3tag_la_DEPENDENCIES) $(EXTRA_libid3tag_la_DEPENDENCIES) - $(AM_V_CCLD)$(libid3tag_la_LINK) -rpath $(libdir) $(libid3tag_la_OBJECTS) $(libid3tag_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/compat.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/crc.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/debug.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/field.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/file.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/frame.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/frametype.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/genre.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/latin1.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/render.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tag.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ucs4.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utf16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utf8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Plo@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -distclean-libtool: - -rm -f libtool config.lt -install-includeHEADERS: $(include_HEADERS) - @$(NORMAL_INSTALL) - @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ - fi; \ - for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; \ - done | $(am__base_list) | \ - while read files; do \ - echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \ - $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \ - done - -uninstall-includeHEADERS: - @$(NORMAL_UNINSTALL) - @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ - files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ - dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscope: cscope.files - test ! -s cscope.files \ - || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) -clean-cscope: - -rm -f cscope.files -cscope.files: clean-cscope cscopelist -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -rm -f cscope.out cscope.in.out cscope.po.out cscope.files - -distdir: $(DISTFILES) - $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done - -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -755 \ - -exec chmod u+rwx,go+rx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r "$(distdir)" -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__post_remove_distdir) - -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 - $(am__post_remove_distdir) - -dist-lzip: distdir - tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz - $(am__post_remove_distdir) - -dist-xz: distdir - tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz - $(am__post_remove_distdir) - -dist-tarZ: distdir - @echo WARNING: "Support for shar distribution archives is" \ - "deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__post_remove_distdir) - -dist-shar: distdir - @echo WARNING: "Support for distribution archives compressed with" \ - "legacy program 'compress' is deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__post_remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__post_remove_distdir) - -dist dist-all: - $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' - $(am__post_remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lz*) \ - lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ - *.tar.xz*) \ - xz -dc $(distdir).tar.xz | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - esac - chmod -R a-w $(distdir) - chmod u+w $(distdir) - mkdir $(distdir)/_build $(distdir)/_inst - chmod a-w $(distdir) - test -d $(distdir)/_build || exit 0; \ - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure \ - $(AM_DISTCHECK_CONFIGURE_FLAGS) \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - --srcdir=.. --prefix="$$dc_install_base" \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ - && cd "$$am__cwd" \ - || exit 1 - $(am__post_remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @test -n '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: trying to run $@ with an empty' \ - '$$(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - $(am__cd) '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: check-recursive -all-am: Makefile $(LTLIBRARIES) $(HEADERS) config.h -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ - mostlyclean-am - -distclean: distclean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-hdr distclean-libtool distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: install-includeHEADERS - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: install-libLTLIBRARIES - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES - -.MAKE: $(am__recursive_targets) all install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--refresh check check-am clean clean-cscope clean-generic \ - clean-libLTLIBRARIES clean-libtool cscope cscopelist-am ctags \ - ctags-am dist dist-all dist-bzip2 dist-gzip dist-lzip \ - dist-shar dist-tarZ dist-xz dist-zip distcheck distclean \ - distclean-compile distclean-generic distclean-hdr \ - distclean-libtool distclean-tags distcleancheck distdir \ - distuninstallcheck dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-includeHEADERS install-info \ - install-info-am install-libLTLIBRARIES install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-includeHEADERS uninstall-libLTLIBRARIES - - -#BUILT_SOURCES = frametype.c compat.c genre.dat -# -#$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -# cd $(srcdir) && \ -# gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -# frametype.gperf | \ -# sed -e 's/\(struct id3_frametype\);/\1/' | \ -# sed -e '/\$$''Id: /s/\$$//g' >frametype.c -# -#$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -# cd $(srcdir) && \ -# gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -# compat.gperf | \ -# sed -e 's/\(struct id3_compat\);/\1/' | \ -# sed -e '/\$$''Id: /s/\$$//g' >compat.c -# -#$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -# cd $(srcdir) && \ -# sed -n -f genre.dat.sed genre.dat.in | \ -# sed -e '/\$$''Id: /s/\$$//g' >genre.dat - -libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - -again: - $(MAKE) clean - $(MAKE) - -.PHONY: again - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/libid3tag/README b/lib-src/libid3tag/README deleted file mode 100644 index fb48faa79..000000000 --- a/lib-src/libid3tag/README +++ /dev/null @@ -1,102 +0,0 @@ - - libid3tag - ID3 tag manipulation library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: README,v 1.2 2004-06-08 06:38:14 dmazzoni Exp $ - -=============================================================================== - -INTRODUCTION - - libid3tag is a library for reading and (eventually) writing ID3 tags, both - ID3v1 and the various versions of ID3v2. - - See the file `id3tag.h' for the current library interface. - - This package uses GNU libtool to arrange for zlib to be linked - automatically when you link your programs with this library. If you aren't - using GNU libtool, in some cases you may need to link with zlib - explicitly: - - ${link_command} ... -lid3tag -lz - -=============================================================================== - -BUILDING AND INSTALLING - - Note that this library depends on zlib 1.1.4 or later. If you don't have - zlib already, you can obtain it from: - - http://www.gzip.org/zlib/ - - You must have zlib installed before you can build this package. - -Windows Platforms - - libid3tag can be built under Windows using either MSVC++ or Cygwin. A - MSVC++ project file can be found under the `msvc++' subdirectory. - - To build libid3tag using Cygwin, you will first need to install the Cygwin - tools: - - http://www.cygwin.com/ - - You may then proceed with the following POSIX instructions within the - Cygwin shell. - - Note that by default Cygwin will build a library that depends on the - Cygwin DLL. You can use MinGW to build a library that does not depend on - the Cygwin DLL. To do so, give the option --host=mingw32 to `configure'. - Be certain you also link with a MinGW version of zlib. - -POSIX Platforms (including Cygwin) - - The code is distributed with a `configure' script that will generate for - you a `Makefile' and a `config.h' for your platform. See the file - `INSTALL' for generic instructions. - - The specific options you may want to give `configure' are: - - --disable-debugging do not compile with debugging support, and - use more optimizations - - --disable-shared do not build a shared library - - By default the package will build a shared library if possible for your - platform. If you want only a static library, use --disable-shared. - - If zlib is installed in an unusual place or `configure' can't find it, you - may need to indicate where it is: - - ./configure ... CPPFLAGS="-I${include_dir}" LDFLAGS="-L${lib_dir}" - - where ${include_dir} and ${lib_dir} are the locations of the installed - header and library files, respectively. - -Experimenting and Developing - - Further options for `configure' that may be useful to developers and - experimenters are: - - --enable-debugging enable diagnostic debugging support and - debugging symbols - - --enable-profiling generate `gprof' profiling code - -=============================================================================== - -COPYRIGHT - - Please read the `COPYRIGHT' file for copyright and warranty information. - Also, the file `COPYING' contains the full text of the GNU GPL. - - Send inquiries, comments, bug reports, suggestions, patches, etc. to: - - Underbit Technologies, Inc. - - See also the MAD home page on the Web: - - http://www.underbit.com/products/mad/ - -=============================================================================== - diff --git a/lib-src/libid3tag/TODO b/lib-src/libid3tag/TODO deleted file mode 100644 index 176fd48b0..000000000 --- a/lib-src/libid3tag/TODO +++ /dev/null @@ -1,12 +0,0 @@ - - libid3tag - ID3 tag manipulation library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: TODO,v 1.2 2004-06-08 06:38:14 dmazzoni Exp $ - -=============================================================================== - -libid3tag: - - finish file API - - fix API headers - diff --git a/lib-src/libid3tag/VERSION b/lib-src/libid3tag/VERSION deleted file mode 100644 index 574a7327f..000000000 --- a/lib-src/libid3tag/VERSION +++ /dev/null @@ -1,6 +0,0 @@ -0.15.1b -configure.ac:24 -id3tag.h:338-341 -msvc++/config.h:59,65,71 - -Makefile.am:63-65 diff --git a/lib-src/libid3tag/compat.c b/lib-src/libid3tag/compat.c deleted file mode 100644 index 62720e647..000000000 --- a/lib-src/libid3tag/compat.c +++ /dev/null @@ -1,506 +0,0 @@ -/* C code produced by gperf version 3.0.3 */ -/* Command-line: gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' compat.gperf */ - -#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ - && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ - && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ - && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ - && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ - && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ - && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ - && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ - && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ - && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ - && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ - && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ - && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ - && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ - && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ - && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ - && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ - && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ - && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ - && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ - && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ - && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ - && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) -/* The character set is not based on ISO-646. */ -error "gperf generated tables don't work with this execution character set. Please report a bug to ." -#endif - -#line 1 "compat.gperf" - -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Id: compat.gperf,v 1.3 2004/06/08 06:38:14 dmazzoni Exp - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "compat.h" -# include "frame.h" -# include "field.h" -# include "parse.h" -# include "ucs4.h" - -# define EQ(id) #id, 0 -# define OBSOLETE 0, 0 -# define TX(id) #id, translate_##id - -static id3_compat_func_t translate_TCON; - -#define TOTAL_KEYWORDS 73 -#define MIN_WORD_LENGTH 3 -#define MAX_WORD_LENGTH 4 -#define MIN_HASH_VALUE 6 -#define MAX_HASH_VALUE 127 -/* maximum key range = 122, duplicates = 0 */ - -#ifdef __GNUC__ -__inline -#else -#ifdef __cplusplus -inline -#endif -#endif -static unsigned int -hash (str, len) - register const char *str; - register unsigned int len; -{ - static const unsigned char asso_values[] = - { - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 64, - 58, 20, 15, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 10, 18, 3, 6, 1, - 47, 0, 128, 42, 62, 30, 31, 0, 19, 52, - 10, 24, 8, 30, 5, 3, 30, 8, 25, 47, - 3, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128 - }; - register int hval = 0; - - switch (len) - { - default: - hval += asso_values[(unsigned char)str[3]]; - /*FALLTHROUGH*/ - case 3: - hval += asso_values[(unsigned char)str[2]]; - /*FALLTHROUGH*/ - case 2: - hval += asso_values[(unsigned char)str[1]+1]; - /*FALLTHROUGH*/ - case 1: - hval += asso_values[(unsigned char)str[0]]; - break; - } - return hval; -} - -#ifdef __GNUC__ -__inline -#ifdef __GNUC_STDC_INLINE__ -__attribute__ ((__gnu_inline__)) -#endif -#endif -const struct id3_compat * -id3_compat_lookup (str, len) - register const char *str; - register unsigned int len; -{ - static const struct id3_compat wordlist[] = - { -#line 97 "compat.gperf" - {"TLE", EQ(TLEN) /* Length */}, -#line 68 "compat.gperf" - {"ETC", EQ(ETCO) /* Event timing codes */}, -#line 126 "compat.gperf" - {"ULT", EQ(USLT) /* Unsynchronised lyric/text transcription */}, -#line 123 "compat.gperf" - {"TYE", OBSOLETE /* Year [obsolete] */}, -#line 92 "compat.gperf" - {"TFT", EQ(TFLT) /* File type */}, -#line 84 "compat.gperf" - {"TCM", EQ(TCOM) /* Composer */}, -#line 66 "compat.gperf" - {"EQU", OBSOLETE /* Equalization [obsolete] */}, -#line 63 "compat.gperf" - {"COM", EQ(COMM) /* Comments */}, -#line 130 "compat.gperf" - {"WCM", EQ(WCOM) /* Commercial information */}, -#line 96 "compat.gperf" - {"TLA", EQ(TLAN) /* Language(s) */}, -#line 88 "compat.gperf" - {"TDA", OBSOLETE /* Date [obsolete] */}, -#line 124 "compat.gperf" - {"TYER", OBSOLETE /* Year [obsolete] */}, -#line 83 "compat.gperf" - {"TBP", EQ(TBPM) /* BPM (beats per minute) */}, -#line 87 "compat.gperf" - {"TCR", EQ(TCOP) /* Copyright message */}, -#line 104 "compat.gperf" - {"TOT", EQ(TOAL) /* Original album/movie/show title */}, -#line 89 "compat.gperf" - {"TDAT", OBSOLETE /* Date [obsolete] */}, -#line 67 "compat.gperf" - {"EQUA", OBSOLETE /* Equalization [obsolete] */}, -#line 102 "compat.gperf" - {"TOR", EQ(TDOR) /* Original release year [obsolete] */}, -#line 131 "compat.gperf" - {"WCP", EQ(WCOP) /* Copyright/legal information */}, -#line 99 "compat.gperf" - {"TOA", EQ(TOPE) /* Original artist(s)/performer(s) */}, -#line 78 "compat.gperf" - {"RVA", OBSOLETE /* Relative volume adjustment [obsolete] */}, -#line 120 "compat.gperf" - {"TT3", EQ(TIT3) /* Subtitle/description refinement */}, -#line 98 "compat.gperf" - {"TMT", EQ(TMED) /* Media type */}, -#line 76 "compat.gperf" - {"POP", EQ(POPM) /* Popularimeter */}, -#line 74 "compat.gperf" - {"MLL", EQ(MLLT) /* MPEG location lookup table */}, -#line 79 "compat.gperf" - {"RVAD", OBSOLETE /* Relative volume adjustment [obsolete] */}, -#line 65 "compat.gperf" - {"CRM", OBSOLETE /* Encrypted meta frame [obsolete] */}, -#line 128 "compat.gperf" - {"WAR", EQ(WOAR) /* Official artist/performer webpage */}, -#line 80 "compat.gperf" - {"SLT", EQ(SYLT) /* Synchronised lyric/text */}, -#line 81 "compat.gperf" - {"STC", EQ(SYTC) /* Synchronised tempo codes */}, -#line 95 "compat.gperf" - {"TKE", EQ(TKEY) /* Initial key */}, -#line 111 "compat.gperf" - {"TRC", EQ(TSRC) /* ISRC (international standard recording code) */}, -#line 109 "compat.gperf" - {"TPA", EQ(TPOS) /* Part of a set */}, -#line 117 "compat.gperf" - {"TSS", EQ(TSSE) /* Software/hardware and settings used for encoding */}, -#line 112 "compat.gperf" - {"TRD", OBSOLETE /* Recording dates [obsolete] */}, -#line 64 "compat.gperf" - {"CRA", EQ(AENC) /* Audio encryption */}, -#line 108 "compat.gperf" - {"TP4", EQ(TPE4) /* Interpreted, remixed, or otherwise modified by */}, -#line 125 "compat.gperf" - {"UFI", EQ(UFID) /* Unique file identifier */}, -#line 101 "compat.gperf" - {"TOL", EQ(TOLY) /* Original lyricist(s)/text writer(s) */}, -#line 110 "compat.gperf" - {"TPB", EQ(TPUB) /* Publisher */}, -#line 73 "compat.gperf" - {"MCI", EQ(MCDI) /* Music CD identifier */}, -#line 107 "compat.gperf" - {"TP3", EQ(TPE3) /* Conductor/performer refinement */}, -#line 132 "compat.gperf" - {"WPB", EQ(WPUB) /* Publishers official webpage */}, -#line 113 "compat.gperf" - {"TRDA", OBSOLETE /* Recording dates [obsolete] */}, -#line 115 "compat.gperf" - {"TSI", OBSOLETE /* Size [obsolete] */}, -#line 90 "compat.gperf" - {"TDY", EQ(TDLY) /* Playlist delay */}, -#line 82 "compat.gperf" - {"TAL", EQ(TALB) /* Album/movie/show title */}, -#line 116 "compat.gperf" - {"TSIZ", OBSOLETE /* Size [obsolete] */}, -#line 129 "compat.gperf" - {"WAS", EQ(WOAS) /* Official audio source webpage */}, -#line 121 "compat.gperf" - {"TXT", EQ(TEXT) /* Lyricist/text writer */}, -#line 62 "compat.gperf" - {"CNT", EQ(PCNT) /* Play counter */}, -#line 100 "compat.gperf" - {"TOF", EQ(TOFN) /* Original filename */}, -#line 85 "compat.gperf" - {"TCO", TX(TCON) /* Content type */}, -#line 114 "compat.gperf" - {"TRK", EQ(TRCK) /* Track number/position in set */}, -#line 119 "compat.gperf" - {"TT2", EQ(TIT2) /* Title/songname/content description */}, -#line 93 "compat.gperf" - {"TIM", OBSOLETE /* Time [obsolete] */}, -#line 94 "compat.gperf" - {"TIME", OBSOLETE /* Time [obsolete] */}, -#line 103 "compat.gperf" - {"TORY", EQ(TDOR) /* Original release year [obsolete] */}, -#line 91 "compat.gperf" - {"TEN", EQ(TENC) /* Encoded by */}, -#line 118 "compat.gperf" - {"TT1", EQ(TIT1) /* Content group description */}, -#line 127 "compat.gperf" - {"WAF", EQ(WOAF) /* Official audio file webpage */}, -#line 75 "compat.gperf" - {"PIC", EQ(APIC) /* Attached picture */}, -#line 122 "compat.gperf" - {"TXX", EQ(TXXX) /* User defined text information frame */}, -#line 133 "compat.gperf" - {"WXX", EQ(WXXX) /* User defined URL link frame */}, -#line 86 "compat.gperf" - {"TCON", TX(TCON) /* Content type */}, -#line 77 "compat.gperf" - {"REV", EQ(RVRB) /* Reverb */}, -#line 106 "compat.gperf" - {"TP2", EQ(TPE2) /* Band/orchestra/accompaniment */}, -#line 105 "compat.gperf" - {"TP1", EQ(TPE1) /* Lead performer(s)/soloist(s) */}, -#line 61 "compat.gperf" - {"BUF", EQ(RBUF) /* Recommended buffer size */}, -#line 70 "compat.gperf" - {"IPL", EQ(TIPL) /* Involved people list */}, -#line 69 "compat.gperf" - {"GEO", EQ(GEOB) /* General encapsulated object */}, -#line 72 "compat.gperf" - {"LNK", EQ(LINK) /* Linked information */}, -#line 71 "compat.gperf" - {"IPLS", EQ(TIPL) /* Involved people list */} - }; - - static const short lookup[] = - { - -1, -1, -1, -1, -1, -1, 0, 1, 2, 3, 4, 5, 6, 7, - 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, -1, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, - -1, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, - 48, 49, -1, -1, 50, -1, 51, 52, -1, 53, 54, 55, 56, -1, - 57, 58, 59, 60, -1, 61, -1, 62, -1, -1, 63, -1, 64, -1, - -1, 65, -1, 66, -1, -1, -1, -1, -1, 67, -1, 68, -1, 69, - -1, 70, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 71, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 72 - }; - - if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) - { - register int key = hash (str, len); - - if (key <= MAX_HASH_VALUE && key >= 0) - { - register int index = lookup[key]; - - if (index >= 0) - { - register const char *s = wordlist[index].id; - - if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') - return &wordlist[index]; - } - } - } - return 0; -} -#line 134 "compat.gperf" - - -static -int translate_TCON(struct id3_frame *frame, char const *oldid, - id3_byte_t const *data, id3_length_t length) -{ - id3_byte_t const *end; - enum id3_field_textencoding encoding; - id3_ucs4_t *string = 0, *ptr, *endptr; - int result = 0; - - /* translate old TCON syntax into multiple strings */ - - assert(frame->nfields == 2); - - encoding = ID3_FIELD_TEXTENCODING_ISO_8859_1; - - end = data + length; - - if (id3_field_parse(&frame->fields[0], &data, end - data, &encoding) == -1) - goto fail; - - string = id3_parse_string(&data, end - data, encoding, 0); - if (string == 0) - goto fail; - - ptr = string; - while (*ptr == '(') { - if (*++ptr == '(') - break; - - endptr = ptr; - while (*endptr && *endptr != ')') - ++endptr; - - if (*endptr) - *endptr++ = 0; - - if (id3_field_addstring(&frame->fields[1], ptr) == -1) - goto fail; - - ptr = endptr; - } - - if (*ptr && id3_field_addstring(&frame->fields[1], ptr) == -1) - goto fail; - - if (0) { - fail: - result = -1; - } - - if (string) - free(string); - - return result; -} - -/* - * NAME: compat->fixup() - * DESCRIPTION: finish compatibility translations - */ -int id3_compat_fixup(struct id3_tag *tag) -{ - struct id3_frame *frame; - unsigned int index; - id3_ucs4_t timestamp[17] = { 0 }; - int result = 0; - - /* create a TDRC frame from obsolete TYER/TDAT/TIME frames */ - - /* - * TYE/TYER: YYYY - * TDA/TDAT: DDMM - * TIM/TIME: HHMM - * - * TDRC: yyyy-MM-ddTHH:mm - */ - - index = 0; - while ((frame = id3_tag_findframe(tag, ID3_FRAME_OBSOLETE, index++))) { - char const *id; - id3_byte_t const *data, *end; - id3_length_t length; - enum id3_field_textencoding encoding; - id3_ucs4_t *string; - - id = id3_field_getframeid(&frame->fields[0]); - assert(id); - - if (strcmp(id, "TYER") != 0 && strcmp(id, "YTYE") != 0 && - strcmp(id, "TDAT") != 0 && strcmp(id, "YTDA") != 0 && - strcmp(id, "TIME") != 0 && strcmp(id, "YTIM") != 0) - continue; - - data = id3_field_getbinarydata(&frame->fields[1], &length); - assert(data); - - if (length < 1) - continue; - - end = data + length; - - encoding = id3_parse_uint(&data, 1); - string = id3_parse_string(&data, end - data, encoding, 0); - - if (id3_ucs4_length(string) < 4) { - free(string); - continue; - } - - if (strcmp(id, "TYER") == 0 || - strcmp(id, "YTYE") == 0) { - timestamp[0] = string[0]; - timestamp[1] = string[1]; - timestamp[2] = string[2]; - timestamp[3] = string[3]; - } - else if (strcmp(id, "TDAT") == 0 || - strcmp(id, "YTDA") == 0) { - timestamp[4] = '-'; - timestamp[5] = string[2]; - timestamp[6] = string[3]; - timestamp[7] = '-'; - timestamp[8] = string[0]; - timestamp[9] = string[1]; - } - else { /* TIME or YTIM */ - timestamp[10] = 'T'; - timestamp[11] = string[0]; - timestamp[12] = string[1]; - timestamp[13] = ':'; - timestamp[14] = string[2]; - timestamp[15] = string[3]; - } - - free(string); - } - - if (timestamp[0]) { - id3_ucs4_t *strings; - - frame = id3_frame_new("TDRC"); - if (frame == 0) - goto fail; - - strings = timestamp; - - if (id3_field_settextencoding(&frame->fields[0], - ID3_FIELD_TEXTENCODING_ISO_8859_1) == -1 || - id3_field_setstrings(&frame->fields[1], 1, &strings) == -1 || - id3_tag_attachframe(tag, frame) == -1) { - id3_frame_delete(frame); - goto fail; - } - } - - if (0) { - fail: - result = -1; - } - - return result; -} diff --git a/lib-src/libid3tag/compat.gperf b/lib-src/libid3tag/compat.gperf deleted file mode 100644 index fa7ef691f..000000000 --- a/lib-src/libid3tag/compat.gperf +++ /dev/null @@ -1,297 +0,0 @@ -%{ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: compat.gperf,v 1.3 2004-06-08 06:38:14 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "compat.h" -# include "frame.h" -# include "field.h" -# include "parse.h" -# include "ucs4.h" - -# define EQ(id) #id, 0 -# define OBSOLETE 0, 0 -# define TX(id) #id, translate_##id - -static id3_compat_func_t translate_TCON; -%} -struct id3_compat; -%% -# -# ID3v2.2 and ID3v2.3 frames -# -# Only obsolete frames or frames with an equivalent ID3v2.4 frame ID are -# listed here. If a frame ID is not listed, it is assumed that the same -# frame ID is itself the equivalent ID3v2.4 frame ID. -# -# This list may also include frames with new content interpretations; the -# translation function will rewrite the contents to comply with ID3v2.4. -# -BUF, EQ(RBUF) /* Recommended buffer size */ -CNT, EQ(PCNT) /* Play counter */ -COM, EQ(COMM) /* Comments */ -CRA, EQ(AENC) /* Audio encryption */ -CRM, OBSOLETE /* Encrypted meta frame [obsolete] */ -EQU, OBSOLETE /* Equalization [obsolete] */ -EQUA, OBSOLETE /* Equalization [obsolete] */ -ETC, EQ(ETCO) /* Event timing codes */ -GEO, EQ(GEOB) /* General encapsulated object */ -IPL, EQ(TIPL) /* Involved people list */ -IPLS, EQ(TIPL) /* Involved people list */ -LNK, EQ(LINK) /* Linked information */ -MCI, EQ(MCDI) /* Music CD identifier */ -MLL, EQ(MLLT) /* MPEG location lookup table */ -PIC, EQ(APIC) /* Attached picture */ -POP, EQ(POPM) /* Popularimeter */ -REV, EQ(RVRB) /* Reverb */ -RVA, OBSOLETE /* Relative volume adjustment [obsolete] */ -RVAD, OBSOLETE /* Relative volume adjustment [obsolete] */ -SLT, EQ(SYLT) /* Synchronised lyric/text */ -STC, EQ(SYTC) /* Synchronised tempo codes */ -TAL, EQ(TALB) /* Album/movie/show title */ -TBP, EQ(TBPM) /* BPM (beats per minute) */ -TCM, EQ(TCOM) /* Composer */ -TCO, TX(TCON) /* Content type */ -TCON, TX(TCON) /* Content type */ -TCR, EQ(TCOP) /* Copyright message */ -TDA, OBSOLETE /* Date [obsolete] */ -TDAT, OBSOLETE /* Date [obsolete] */ -TDY, EQ(TDLY) /* Playlist delay */ -TEN, EQ(TENC) /* Encoded by */ -TFT, EQ(TFLT) /* File type */ -TIM, OBSOLETE /* Time [obsolete] */ -TIME, OBSOLETE /* Time [obsolete] */ -TKE, EQ(TKEY) /* Initial key */ -TLA, EQ(TLAN) /* Language(s) */ -TLE, EQ(TLEN) /* Length */ -TMT, EQ(TMED) /* Media type */ -TOA, EQ(TOPE) /* Original artist(s)/performer(s) */ -TOF, EQ(TOFN) /* Original filename */ -TOL, EQ(TOLY) /* Original lyricist(s)/text writer(s) */ -TOR, EQ(TDOR) /* Original release year [obsolete] */ -TORY, EQ(TDOR) /* Original release year [obsolete] */ -TOT, EQ(TOAL) /* Original album/movie/show title */ -TP1, EQ(TPE1) /* Lead performer(s)/soloist(s) */ -TP2, EQ(TPE2) /* Band/orchestra/accompaniment */ -TP3, EQ(TPE3) /* Conductor/performer refinement */ -TP4, EQ(TPE4) /* Interpreted, remixed, or otherwise modified by */ -TPA, EQ(TPOS) /* Part of a set */ -TPB, EQ(TPUB) /* Publisher */ -TRC, EQ(TSRC) /* ISRC (international standard recording code) */ -TRD, OBSOLETE /* Recording dates [obsolete] */ -TRDA, OBSOLETE /* Recording dates [obsolete] */ -TRK, EQ(TRCK) /* Track number/position in set */ -TSI, OBSOLETE /* Size [obsolete] */ -TSIZ, OBSOLETE /* Size [obsolete] */ -TSS, EQ(TSSE) /* Software/hardware and settings used for encoding */ -TT1, EQ(TIT1) /* Content group description */ -TT2, EQ(TIT2) /* Title/songname/content description */ -TT3, EQ(TIT3) /* Subtitle/description refinement */ -TXT, EQ(TEXT) /* Lyricist/text writer */ -TXX, EQ(TXXX) /* User defined text information frame */ -TYE, OBSOLETE /* Year [obsolete] */ -TYER, OBSOLETE /* Year [obsolete] */ -UFI, EQ(UFID) /* Unique file identifier */ -ULT, EQ(USLT) /* Unsynchronised lyric/text transcription */ -WAF, EQ(WOAF) /* Official audio file webpage */ -WAR, EQ(WOAR) /* Official artist/performer webpage */ -WAS, EQ(WOAS) /* Official audio source webpage */ -WCM, EQ(WCOM) /* Commercial information */ -WCP, EQ(WCOP) /* Copyright/legal information */ -WPB, EQ(WPUB) /* Publishers official webpage */ -WXX, EQ(WXXX) /* User defined URL link frame */ -%% - -static -int translate_TCON(struct id3_frame *frame, char const *oldid, - id3_byte_t const *data, id3_length_t length) -{ - id3_byte_t const *end; - enum id3_field_textencoding encoding; - id3_ucs4_t *string = 0, *ptr, *endptr; - int result = 0; - - /* translate old TCON syntax into multiple strings */ - - assert(frame->nfields == 2); - - encoding = ID3_FIELD_TEXTENCODING_ISO_8859_1; - - end = data + length; - - if (id3_field_parse(&frame->fields[0], &data, end - data, &encoding) == -1) - goto fail; - - string = id3_parse_string(&data, end - data, encoding, 0); - if (string == 0) - goto fail; - - ptr = string; - while (*ptr == '(') { - if (*++ptr == '(') - break; - - endptr = ptr; - while (*endptr && *endptr != ')') - ++endptr; - - if (*endptr) - *endptr++ = 0; - - if (id3_field_addstring(&frame->fields[1], ptr) == -1) - goto fail; - - ptr = endptr; - } - - if (*ptr && id3_field_addstring(&frame->fields[1], ptr) == -1) - goto fail; - - if (0) { - fail: - result = -1; - } - - if (string) - free(string); - - return result; -} - -/* - * NAME: compat->fixup() - * DESCRIPTION: finish compatibility translations - */ -int id3_compat_fixup(struct id3_tag *tag) -{ - struct id3_frame *frame; - unsigned int index; - id3_ucs4_t timestamp[17] = { 0 }; - int result = 0; - - /* create a TDRC frame from obsolete TYER/TDAT/TIME frames */ - - /* - * TYE/TYER: YYYY - * TDA/TDAT: DDMM - * TIM/TIME: HHMM - * - * TDRC: yyyy-MM-ddTHH:mm - */ - - index = 0; - while ((frame = id3_tag_findframe(tag, ID3_FRAME_OBSOLETE, index++))) { - char const *id; - id3_byte_t const *data, *end; - id3_length_t length; - enum id3_field_textencoding encoding; - id3_ucs4_t *string; - - id = id3_field_getframeid(&frame->fields[0]); - assert(id); - - if (strcmp(id, "TYER") != 0 && strcmp(id, "YTYE") != 0 && - strcmp(id, "TDAT") != 0 && strcmp(id, "YTDA") != 0 && - strcmp(id, "TIME") != 0 && strcmp(id, "YTIM") != 0) - continue; - - data = id3_field_getbinarydata(&frame->fields[1], &length); - assert(data); - - if (length < 1) - continue; - - end = data + length; - - encoding = id3_parse_uint(&data, 1); - string = id3_parse_string(&data, end - data, encoding, 0); - - if (id3_ucs4_length(string) < 4) { - free(string); - continue; - } - - if (strcmp(id, "TYER") == 0 || - strcmp(id, "YTYE") == 0) { - timestamp[0] = string[0]; - timestamp[1] = string[1]; - timestamp[2] = string[2]; - timestamp[3] = string[3]; - } - else if (strcmp(id, "TDAT") == 0 || - strcmp(id, "YTDA") == 0) { - timestamp[4] = '-'; - timestamp[5] = string[2]; - timestamp[6] = string[3]; - timestamp[7] = '-'; - timestamp[8] = string[0]; - timestamp[9] = string[1]; - } - else { /* TIME or YTIM */ - timestamp[10] = 'T'; - timestamp[11] = string[0]; - timestamp[12] = string[1]; - timestamp[13] = ':'; - timestamp[14] = string[2]; - timestamp[15] = string[3]; - } - - free(string); - } - - if (timestamp[0]) { - id3_ucs4_t *strings; - - frame = id3_frame_new("TDRC"); - if (frame == 0) - goto fail; - - strings = timestamp; - - if (id3_field_settextencoding(&frame->fields[0], - ID3_FIELD_TEXTENCODING_ISO_8859_1) == -1 || - id3_field_setstrings(&frame->fields[1], 1, &strings) == -1 || - id3_tag_attachframe(tag, frame) == -1) { - id3_frame_delete(frame); - goto fail; - } - } - - if (0) { - fail: - result = -1; - } - - return result; -} diff --git a/lib-src/libid3tag/compat.h b/lib-src/libid3tag/compat.h deleted file mode 100644 index 11276b4fa..000000000 --- a/lib-src/libid3tag/compat.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: compat.h,v 1.3 2004-06-08 06:38:14 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_COMPAT_H -# define LIBID3TAG_COMPAT_H - -# include "id3tag.h" - -typedef int id3_compat_func_t(struct id3_frame *, char const *, - id3_byte_t const *, id3_length_t); - -struct id3_compat { - char const *id; - char const *equiv; - id3_compat_func_t *translate; -}; - -struct id3_compat const *id3_compat_lookup(register char const *, - register unsigned int); - -int id3_compat_fixup(struct id3_tag *); - -# endif diff --git a/lib-src/libid3tag/compile b/lib-src/libid3tag/compile deleted file mode 100755 index 531136b06..000000000 --- a/lib-src/libid3tag/compile +++ /dev/null @@ -1,347 +0,0 @@ -#! /bin/sh -# Wrapper for compilers which do not understand '-c -o'. - -scriptversion=2012-10-14.11; # UTC - -# Copyright (C) 1999-2013 Free Software Foundation, Inc. -# Written by Tom Tromey . -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -nl=' -' - -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent tools from complaining about whitespace usage. -IFS=" "" $nl" - -file_conv= - -# func_file_conv build_file lazy -# Convert a $build file to $host form and store it in $file -# Currently only supports Windows hosts. If the determined conversion -# type is listed in (the comma separated) LAZY, no conversion will -# take place. -func_file_conv () -{ - file=$1 - case $file in - / | /[!/]*) # absolute file, and not a UNC file - if test -z "$file_conv"; then - # lazily determine how to convert abs files - case `uname -s` in - MINGW*) - file_conv=mingw - ;; - CYGWIN*) - file_conv=cygwin - ;; - *) - file_conv=wine - ;; - esac - fi - case $file_conv/,$2, in - *,$file_conv,*) - ;; - mingw/*) - file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` - ;; - cygwin/*) - file=`cygpath -m "$file" || echo "$file"` - ;; - wine/*) - file=`winepath -w "$file" || echo "$file"` - ;; - esac - ;; - esac -} - -# func_cl_dashL linkdir -# Make cl look for libraries in LINKDIR -func_cl_dashL () -{ - func_file_conv "$1" - if test -z "$lib_path"; then - lib_path=$file - else - lib_path="$lib_path;$file" - fi - linker_opts="$linker_opts -LIBPATH:$file" -} - -# func_cl_dashl library -# Do a library search-path lookup for cl -func_cl_dashl () -{ - lib=$1 - found=no - save_IFS=$IFS - IFS=';' - for dir in $lib_path $LIB - do - IFS=$save_IFS - if $shared && test -f "$dir/$lib.dll.lib"; then - found=yes - lib=$dir/$lib.dll.lib - break - fi - if test -f "$dir/$lib.lib"; then - found=yes - lib=$dir/$lib.lib - break - fi - if test -f "$dir/lib$lib.a"; then - found=yes - lib=$dir/lib$lib.a - break - fi - done - IFS=$save_IFS - - if test "$found" != yes; then - lib=$lib.lib - fi -} - -# func_cl_wrapper cl arg... -# Adjust compile command to suit cl -func_cl_wrapper () -{ - # Assume a capable shell - lib_path= - shared=: - linker_opts= - for arg - do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - eat=1 - case $2 in - *.o | *.[oO][bB][jJ]) - func_file_conv "$2" - set x "$@" -Fo"$file" - shift - ;; - *) - func_file_conv "$2" - set x "$@" -Fe"$file" - shift - ;; - esac - ;; - -I) - eat=1 - func_file_conv "$2" mingw - set x "$@" -I"$file" - shift - ;; - -I*) - func_file_conv "${1#-I}" mingw - set x "$@" -I"$file" - shift - ;; - -l) - eat=1 - func_cl_dashl "$2" - set x "$@" "$lib" - shift - ;; - -l*) - func_cl_dashl "${1#-l}" - set x "$@" "$lib" - shift - ;; - -L) - eat=1 - func_cl_dashL "$2" - ;; - -L*) - func_cl_dashL "${1#-L}" - ;; - -static) - shared=false - ;; - -Wl,*) - arg=${1#-Wl,} - save_ifs="$IFS"; IFS=',' - for flag in $arg; do - IFS="$save_ifs" - linker_opts="$linker_opts $flag" - done - IFS="$save_ifs" - ;; - -Xlinker) - eat=1 - linker_opts="$linker_opts $2" - ;; - -*) - set x "$@" "$1" - shift - ;; - *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) - func_file_conv "$1" - set x "$@" -Tp"$file" - shift - ;; - *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) - func_file_conv "$1" mingw - set x "$@" "$file" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift - done - if test -n "$linker_opts"; then - linker_opts="-link$linker_opts" - fi - exec "$@" $linker_opts - exit 1 -} - -eat= - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: compile [--help] [--version] PROGRAM [ARGS] - -Wrapper for compilers which do not understand '-c -o'. -Remove '-o dest.o' from ARGS, run PROGRAM with the remaining -arguments, and rename the output as expected. - -If you are trying to build a whole package this is not the -right script to run: please start by reading the file 'INSTALL'. - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "compile $scriptversion" - exit $? - ;; - cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) - func_cl_wrapper "$@" # Doesn't return... - ;; -esac - -ofile= -cfile= - -for arg -do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - # So we strip '-o arg' only if arg is an object. - eat=1 - case $2 in - *.o | *.obj) - ofile=$2 - ;; - *) - set x "$@" -o "$2" - shift - ;; - esac - ;; - *.c) - cfile=$1 - set x "$@" "$1" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift -done - -if test -z "$ofile" || test -z "$cfile"; then - # If no '-o' option was seen then we might have been invoked from a - # pattern rule where we don't need one. That is ok -- this is a - # normal compilation that the losing compiler can handle. If no - # '.c' file was seen then we are probably linking. That is also - # ok. - exec "$@" -fi - -# Name of file we expect compiler to create. -cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` - -# Create the lock directory. -# Note: use '[/\\:.-]' here to ensure that we don't use the same name -# that we are using for the .o file. Also, base the name on the expected -# object file name, since that is what matters with a parallel build. -lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d -while true; do - if mkdir "$lockdir" >/dev/null 2>&1; then - break - fi - sleep 1 -done -# FIXME: race condition here if user kills between mkdir and trap. -trap "rmdir '$lockdir'; exit 1" 1 2 15 - -# Run the compile. -"$@" -ret=$? - -if test -f "$cofile"; then - test "$cofile" = "$ofile" || mv "$cofile" "$ofile" -elif test -f "${cofile}bj"; then - test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" -fi - -rmdir "$lockdir" -exit $ret - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libid3tag/config.guess b/lib-src/libid3tag/config.guess deleted file mode 100755 index b79252d6b..000000000 --- a/lib-src/libid3tag/config.guess +++ /dev/null @@ -1,1558 +0,0 @@ -#! /bin/sh -# Attempt to guess a canonical system name. -# Copyright 1992-2013 Free Software Foundation, Inc. - -timestamp='2013-06-10' - -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). -# -# Originally written by Per Bothner. -# -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD -# -# Please send patches with a ChangeLog entry to config-patches@gnu.org. - - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] - -Output the configuration name of the system \`$me' is run on. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.guess ($timestamp) - -Originally written by Per Bothner. -Copyright 1992-2013 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" >&2 - exit 1 ;; - * ) - break ;; - esac -done - -if test $# != 0; then - echo "$me: too many arguments$help" >&2 - exit 1 -fi - -trap 'exit 1' 1 2 15 - -# CC_FOR_BUILD -- compiler used by this script. Note that the use of a -# compiler to aid in system detection is discouraged as it requires -# temporary files to be created and, as you can see below, it is a -# headache to deal with in a portable fashion. - -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. - -# Portable tmp directory creation inspired by the Autoconf team. - -set_cc_for_build=' -trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; -trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; -: ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || - { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || - { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || - { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; -dummy=$tmp/dummy ; -tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; -case $CC_FOR_BUILD,$HOST_CC,$CC in - ,,) echo "int x;" > $dummy.c ; - for c in cc gcc c89 c99 ; do - if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then - CC_FOR_BUILD="$c"; break ; - fi ; - done ; - if test x"$CC_FOR_BUILD" = x ; then - CC_FOR_BUILD=no_compiler_found ; - fi - ;; - ,,*) CC_FOR_BUILD=$CC ;; - ,*,*) CC_FOR_BUILD=$HOST_CC ;; -esac ; set_cc_for_build= ;' - -# This is needed to find uname on a Pyramid OSx when run in the BSD universe. -# (ghazi@noc.rutgers.edu 1994-08-24) -if (test -f /.attbin/uname) >/dev/null 2>&1 ; then - PATH=$PATH:/.attbin ; export PATH -fi - -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown - -case "${UNAME_SYSTEM}" in -Linux|GNU|GNU/*) - # If the system lacks a compiler, then just pick glibc. - # We could probably try harder. - LIBC=gnu - - eval $set_cc_for_build - cat <<-EOF > $dummy.c - #include - #if defined(__UCLIBC__) - LIBC=uclibc - #elif defined(__dietlibc__) - LIBC=dietlibc - #else - LIBC=gnu - #endif - EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` - ;; -esac - -# Note: order is significant - the case branches are not exclusive. - -case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in - *:NetBSD:*:*) - # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, - # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently - # switched to ELF, *-*-netbsd* would select the old - # object file format. This provides both forward - # compatibility and a consistent mechanism for selecting the - # object file format. - # - # Note: NetBSD doesn't particularly care about the vendor - # portion of the name. We always set it to "unknown". - sysctl="sysctl -n hw.machine_arch" - UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ - /usr/sbin/$sysctl 2>/dev/null || echo unknown)` - case "${UNAME_MACHINE_ARCH}" in - armeb) machine=armeb-unknown ;; - arm*) machine=arm-unknown ;; - sh3el) machine=shl-unknown ;; - sh3eb) machine=sh-unknown ;; - sh5el) machine=sh5le-unknown ;; - *) machine=${UNAME_MACHINE_ARCH}-unknown ;; - esac - # The Operating System including object format, if it has switched - # to ELF recently, or will in the future. - case "${UNAME_MACHINE_ARCH}" in - arm*|i386|m68k|ns32k|sh3*|sparc|vax) - eval $set_cc_for_build - if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ELF__ - then - # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). - # Return netbsd for either. FIX? - os=netbsd - else - os=netbsdelf - fi - ;; - *) - os=netbsd - ;; - esac - # The OS release - # Debian GNU/NetBSD machines have a different userland, and - # thus, need a distinct triplet. However, they do not need - # kernel version information, so it can be replaced with a - # suitable tag, in the style of linux-gnu. - case "${UNAME_VERSION}" in - Debian*) - release='-gnu' - ;; - *) - release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` - ;; - esac - # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: - # contains redundant information, the shorter form: - # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "${machine}-${os}${release}" - exit ;; - *:Bitrig:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} - exit ;; - *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} - exit ;; - *:ekkoBSD:*:*) - echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} - exit ;; - *:SolidBSD:*:*) - echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} - exit ;; - macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd${UNAME_RELEASE} - exit ;; - *:MirBSD:*:*) - echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} - exit ;; - alpha:OSF1:*:*) - case $UNAME_RELEASE in - *4.0) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` - ;; - *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` - ;; - esac - # According to Compaq, /usr/sbin/psrinfo has been available on - # OSF/1 and Tru64 systems produced since 1995. I hope that - # covers most systems running today. This code pipes the CPU - # types through head -n 1, so we only detect the type of CPU 0. - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` - case "$ALPHA_CPU_TYPE" in - "EV4 (21064)") - UNAME_MACHINE="alpha" ;; - "EV4.5 (21064)") - UNAME_MACHINE="alpha" ;; - "LCA4 (21066/21068)") - UNAME_MACHINE="alpha" ;; - "EV5 (21164)") - UNAME_MACHINE="alphaev5" ;; - "EV5.6 (21164A)") - UNAME_MACHINE="alphaev56" ;; - "EV5.6 (21164PC)") - UNAME_MACHINE="alphapca56" ;; - "EV5.7 (21164PC)") - UNAME_MACHINE="alphapca57" ;; - "EV6 (21264)") - UNAME_MACHINE="alphaev6" ;; - "EV6.7 (21264A)") - UNAME_MACHINE="alphaev67" ;; - "EV6.8CB (21264C)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8AL (21264B)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8CX (21264D)") - UNAME_MACHINE="alphaev68" ;; - "EV6.9A (21264/EV69A)") - UNAME_MACHINE="alphaev69" ;; - "EV7 (21364)") - UNAME_MACHINE="alphaev7" ;; - "EV7.9 (21364A)") - UNAME_MACHINE="alphaev79" ;; - esac - # A Pn.n version is a patched version. - # A Vn.n version is a released version. - # A Tn.n version is a released field test version. - # A Xn.n version is an unreleased experimental baselevel. - # 1.2 uses "1.2" for uname -r. - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; - Alpha\ *:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # Should we change UNAME_MACHINE based on the output of uname instead - # of the specific Alpha model? - echo alpha-pc-interix - exit ;; - 21064:Windows_NT:50:3) - echo alpha-dec-winnt3.5 - exit ;; - Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; - *:[Aa]miga[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-amigaos - exit ;; - *:[Mm]orph[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-morphos - exit ;; - *:OS/390:*:*) - echo i370-ibm-openedition - exit ;; - *:z/VM:*:*) - echo s390-ibm-zvmoe - exit ;; - *:OS400:*:*) - echo powerpc-ibm-os400 - exit ;; - arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix${UNAME_RELEASE} - exit ;; - arm*:riscos:*:*|arm*:RISCOS:*:*) - echo arm-unknown-riscos - exit ;; - SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - echo hppa1.1-hitachi-hiuxmpp - exit ;; - Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) - # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - if test "`(/bin/universe) 2>/dev/null`" = att ; then - echo pyramid-pyramid-sysv3 - else - echo pyramid-pyramid-bsd - fi - exit ;; - NILE*:*:*:dcosx) - echo pyramid-pyramid-svr4 - exit ;; - DRS?6000:unix:4.0:6*) - echo sparc-icl-nx6 - exit ;; - DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) - case `/usr/bin/uname -p` in - sparc) echo sparc-icl-nx7; exit ;; - esac ;; - s390x:SunOS:*:*) - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux${UNAME_RELEASE} - exit ;; - i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - eval $set_cc_for_build - SUN_ARCH="i386" - # If there is a compiler, see if it is configured for 64-bit objects. - # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. - # This test works for both compilers. - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - SUN_ARCH="x86_64" - fi - fi - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:6*:*) - # According to config.sub, this is the proper way to canonicalize - # SunOS6. Hard to guess exactly what SunOS6 will be like, but - # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:*:*) - case "`/usr/bin/arch -k`" in - Series*|S4*) - UNAME_RELEASE=`uname -v` - ;; - esac - # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` - exit ;; - sun3*:SunOS:*:*) - echo m68k-sun-sunos${UNAME_RELEASE} - exit ;; - sun*:*:4.2BSD:*) - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 - case "`/bin/arch`" in - sun3) - echo m68k-sun-sunos${UNAME_RELEASE} - ;; - sun4) - echo sparc-sun-sunos${UNAME_RELEASE} - ;; - esac - exit ;; - aushp:SunOS:*:*) - echo sparc-auspex-sunos${UNAME_RELEASE} - exit ;; - # The situation for MiNT is a little confusing. The machine name - # can be virtually everything (everything which is not - # "atarist" or "atariste" at least should have a processor - # > m68000). The system name ranges from "MiNT" over "FreeMiNT" - # to the lowercase version "mint" (or "freemint"). Finally - # the system name "TOS" denotes a system which is actually not - # MiNT. But MiNT is downward compatible to TOS, so this should - # be no problem. - atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; - hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; - *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; - m68k:machten:*:*) - echo m68k-apple-machten${UNAME_RELEASE} - exit ;; - powerpc:machten:*:*) - echo powerpc-apple-machten${UNAME_RELEASE} - exit ;; - RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; - RISC*:ULTRIX:*:*) - echo mips-dec-ultrix${UNAME_RELEASE} - exit ;; - VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix${UNAME_RELEASE} - exit ;; - 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix${UNAME_RELEASE} - exit ;; - mips:*:*:UMIPS | mips:*:*:RISCos) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c -#ifdef __cplusplus -#include /* for printf() prototype */ - int main (int argc, char *argv[]) { -#else - int main (argc, argv) int argc; char *argv[]; { -#endif - #if defined (host_mips) && defined (MIPSEB) - #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); - #endif - #endif - exit (-1); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && - dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`$dummy $dummyarg` && - { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos${UNAME_RELEASE} - exit ;; - Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax - exit ;; - Motorola:*:4.3:PL8-*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:Power_UNIX:*:*) - echo powerpc-harris-powerunix - exit ;; - m88k:CX/UX:7*:*) - echo m88k-harris-cxux7 - exit ;; - m88k:*:4*:R4*) - echo m88k-motorola-sysv4 - exit ;; - m88k:*:3*:R3*) - echo m88k-motorola-sysv3 - exit ;; - AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] - then - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ - [ ${TARGET_BINARY_INTERFACE}x = x ] - then - echo m88k-dg-dgux${UNAME_RELEASE} - else - echo m88k-dg-dguxbcs${UNAME_RELEASE} - fi - else - echo i586-dg-dgux${UNAME_RELEASE} - fi - exit ;; - M88*:DolphinOS:*:*) # DolphinOS (SVR3) - echo m88k-dolphin-sysv3 - exit ;; - M88*:*:R3*:*) - # Delta 88k system running SVR3 - echo m88k-motorola-sysv3 - exit ;; - XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - echo m88k-tektronix-sysv3 - exit ;; - Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - echo m68k-tektronix-bsd - exit ;; - *:IRIX*:*:*) - echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` - exit ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' - i*86:AIX:*:*) - echo i386-ibm-aix - exit ;; - ia64:AIX:*:*) - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} - exit ;; - *:AIX:2:3) - if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - - main() - { - if (!__power_pc()) - exit(1); - puts("powerpc-ibm-aix3.2.5"); - exit(0); - } -EOF - if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` - then - echo "$SYSTEM_NAME" - else - echo rs6000-ibm-aix3.2.5 - fi - elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - echo rs6000-ibm-aix3.2.4 - else - echo rs6000-ibm-aix3.2 - fi - exit ;; - *:AIX:*:[4567]) - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then - IBM_ARCH=rs6000 - else - IBM_ARCH=powerpc - fi - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${IBM_ARCH}-ibm-aix${IBM_REV} - exit ;; - *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; - ibmrt:4.4BSD:*|romp-ibm:BSD:*) - echo romp-ibm-bsd4.4 - exit ;; - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 - *:BOSX:*:*) - echo rs6000-bull-bosx - exit ;; - DPX/2?00:B.O.S.:*:*) - echo m68k-bull-sysv3 - exit ;; - 9000/[34]??:4.3bsd:1.*:*) - echo m68k-hp-bsd - exit ;; - hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - echo m68k-hp-bsd4.4 - exit ;; - 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - case "${UNAME_MACHINE}" in - 9000/31? ) HP_ARCH=m68000 ;; - 9000/[34]?? ) HP_ARCH=m68k ;; - 9000/[678][0-9][0-9]) - if [ -x /usr/bin/getconf ]; then - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; - '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac - fi - if [ "${HP_ARCH}" = "" ]; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - - #define _HPUX_SOURCE - #include - #include - - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); - - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } -EOF - (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` - test -z "$HP_ARCH" && HP_ARCH=hppa - fi ;; - esac - if [ ${HP_ARCH} = "hppa2.0w" ] - then - eval $set_cc_for_build - - # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating - # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler - # generating 64-bit code. GNU and HP use different nomenclature: - # - # $ CC_FOR_BUILD=cc ./config.guess - # => hppa2.0w-hp-hpux11.23 - # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess - # => hppa64-hp-hpux11.23 - - if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep -q __LP64__ - then - HP_ARCH="hppa2.0w" - else - HP_ARCH="hppa64" - fi - fi - echo ${HP_ARCH}-hp-hpux${HPUX_REV} - exit ;; - ia64:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux${HPUX_REV} - exit ;; - 3050*:HI-UX:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - int - main () - { - long cpu = sysconf (_SC_CPU_VERSION); - /* The order matters, because CPU_IS_HP_MC68K erroneously returns - true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct - results, however. */ - if (CPU_IS_PA_RISC (cpu)) - { - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; - case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; - default: puts ("hppa-hitachi-hiuxwe2"); break; - } - } - else if (CPU_IS_HP_MC68K (cpu)) - puts ("m68k-hitachi-hiuxwe2"); - else puts ("unknown-hitachi-hiuxwe2"); - exit (0); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) - echo hppa1.1-hp-bsd - exit ;; - 9000/8??:4.3bsd:*:*) - echo hppa1.0-hp-bsd - exit ;; - *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) - echo hppa1.1-hp-osf - exit ;; - hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; - i*86:OSF1:*:*) - if [ -x /usr/sbin/sysversion ] ; then - echo ${UNAME_MACHINE}-unknown-osf1mk - else - echo ${UNAME_MACHINE}-unknown-osf1 - fi - exit ;; - parisc*:Lites*:*:*) - echo hppa1.1-hp-lites - exit ;; - C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - echo c1-convex-bsd - exit ;; - C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - echo c34-convex-bsd - exit ;; - C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - echo c38-convex-bsd - exit ;; - C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - echo c4-convex-bsd - exit ;; - CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*[A-Z]90:*:*:*) - echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ - | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ - -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ - -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*TS:*:*:*) - echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*SV1:*:*:*) - echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) - FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} - exit ;; - sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:BSD/OS:*:*) - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` - case ${UNAME_PROCESSOR} in - amd64) - echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - *) - echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - esac - exit ;; - i*:CYGWIN*:*) - echo ${UNAME_MACHINE}-pc-cygwin - exit ;; - *:MINGW64*:*) - echo ${UNAME_MACHINE}-pc-mingw64 - exit ;; - *:MINGW*:*) - echo ${UNAME_MACHINE}-pc-mingw32 - exit ;; - i*:MSYS*:*) - echo ${UNAME_MACHINE}-pc-msys - exit ;; - i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 - exit ;; - i*:PW*:*) - echo ${UNAME_MACHINE}-pc-pw32 - exit ;; - *:Interix*:*) - case ${UNAME_MACHINE} in - x86) - echo i586-pc-interix${UNAME_RELEASE} - exit ;; - authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix${UNAME_RELEASE} - exit ;; - IA64) - echo ia64-unknown-interix${UNAME_RELEASE} - exit ;; - esac ;; - [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) - echo i${UNAME_MACHINE}-pc-mks - exit ;; - 8664:Windows_NT:*) - echo x86_64-pc-mks - exit ;; - i*:Windows_NT*:* | Pentium*:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we - # UNAME_MACHINE based on the output of uname instead of i386? - echo i586-pc-interix - exit ;; - i*:UWIN*:*) - echo ${UNAME_MACHINE}-pc-uwin - exit ;; - amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - echo x86_64-unknown-cygwin - exit ;; - p*:CYGWIN*:*) - echo powerpcle-unknown-cygwin - exit ;; - prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - *:GNU:*:*) - # the GNU system - echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` - exit ;; - *:GNU/*:*:*) - # other systems with GNU libc and userland - echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} - exit ;; - i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix - exit ;; - aarch64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - aarch64_be:Linux:*:*) - UNAME_MACHINE=aarch64_be - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep -q ld.so.1 - if test "$?" = 0 ; then LIBC="gnulibc1" ; fi - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - arc:Linux:*:* | arceb:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - arm*:Linux:*:*) - eval $set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_EABI__ - then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - else - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi - else - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf - fi - fi - exit ;; - avr32*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - cris:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} - exit ;; - crisv32:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} - exit ;; - frv:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - hexagon:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - i*86:Linux:*:*) - echo ${UNAME_MACHINE}-pc-linux-${LIBC} - exit ;; - ia64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - m32r*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - m68*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - mips:Linux:*:* | mips64:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef ${UNAME_MACHINE} - #undef ${UNAME_MACHINE}el - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=${UNAME_MACHINE}el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=${UNAME_MACHINE} - #else - CPU= - #endif - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } - ;; - or1k:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - or32:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - padre:Linux:*:*) - echo sparc-unknown-linux-${LIBC} - exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-${LIBC} - exit ;; - parisc:Linux:*:* | hppa:Linux:*:*) - # Look for CPU level - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; - PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; - *) echo hppa-unknown-linux-${LIBC} ;; - esac - exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-${LIBC} - exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-${LIBC} - exit ;; - ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-${LIBC} - exit ;; - ppcle:Linux:*:*) - echo powerpcle-unknown-linux-${LIBC} - exit ;; - s390:Linux:*:* | s390x:Linux:*:*) - echo ${UNAME_MACHINE}-ibm-linux-${LIBC} - exit ;; - sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - sh*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - sparc:Linux:*:* | sparc64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - tile*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - vax:Linux:*:*) - echo ${UNAME_MACHINE}-dec-linux-${LIBC} - exit ;; - x86_64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - xtensa*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - i*86:DYNIX/ptx:4*:*) - # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. - # earlier versions are messed up and put the nodename in both - # sysname and nodename. - echo i386-sequent-sysv4 - exit ;; - i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, - # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. - echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} - exit ;; - i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility - # is probably installed. - echo ${UNAME_MACHINE}-pc-os2-emx - exit ;; - i*86:XTS-300:*:STOP) - echo ${UNAME_MACHINE}-unknown-stop - exit ;; - i*86:atheos:*:*) - echo ${UNAME_MACHINE}-unknown-atheos - exit ;; - i*86:syllable:*:*) - echo ${UNAME_MACHINE}-pc-syllable - exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos${UNAME_RELEASE} - exit ;; - i*86:*DOS:*:*) - echo ${UNAME_MACHINE}-pc-msdosdjgpp - exit ;; - i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) - UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` - if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} - else - echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} - fi - exit ;; - i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. - case `/bin/uname -X | grep "^Machine"` in - *486*) UNAME_MACHINE=i486 ;; - *Pentium) UNAME_MACHINE=i586 ;; - *Pent*|*Celeron) UNAME_MACHINE=i686 ;; - esac - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} - exit ;; - i*86:*:3.2:*) - if test -f /usr/options/cb.name; then - UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` - (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 - (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ - && UNAME_MACHINE=i586 - (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ - && UNAME_MACHINE=i686 - (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ - && UNAME_MACHINE=i686 - echo ${UNAME_MACHINE}-pc-sco$UNAME_REL - else - echo ${UNAME_MACHINE}-pc-sysv32 - fi - exit ;; - pc:*:*:*) - # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i586. - # Note: whatever this is, it MUST be the same as what config.sub - # prints for the "djgpp" host, or else GDB configury will decide that - # this is a cross-build. - echo i586-pc-msdosdjgpp - exit ;; - Intel:Mach:3*:*) - echo i386-pc-mach3 - exit ;; - paragon:*:*:*) - echo i860-intel-osf1 - exit ;; - i860:*:4.*:*) # i860-SVR4 - if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 - else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 - fi - exit ;; - mini*:CTIX:SYS*5:*) - # "miniframe" - echo m68010-convergent-sysv - exit ;; - mc68k:UNIX:SYSTEM5:3.51m) - echo m68k-convergent-sysv - exit ;; - M680?0:D-NIX:5.3:*) - echo m68k-diab-dnix - exit ;; - M68*:*:R3V[5678]*:*) - test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; - 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) - OS_REL='' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; - NCR*:*:4.2:* | MPRAS*:*:4.2:*) - OS_REL='.3' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos${UNAME_RELEASE} - exit ;; - mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; - TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos${UNAME_RELEASE} - exit ;; - rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos${UNAME_RELEASE} - exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos${UNAME_RELEASE} - exit ;; - SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv${UNAME_RELEASE} - exit ;; - RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - RM*:SINIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - *:SINIX-*:*:*) - if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo ${UNAME_MACHINE}-sni-sysv4 - else - echo ns32k-sni-sysv - fi - exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; - *:UNIX_System_V:4*:FTX*) - # From Gerald Hewes . - # How about differentiating between stratus architectures? -djm - echo hppa1.1-stratus-sysv4 - exit ;; - *:*:*:FTX*) - # From seanf@swdc.stratus.com. - echo i860-stratus-sysv4 - exit ;; - i*86:VOS:*:*) - # From Paul.Green@stratus.com. - echo ${UNAME_MACHINE}-stratus-vos - exit ;; - *:VOS:*:*) - # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; - mc68*:A/UX:*:*) - echo m68k-apple-aux${UNAME_RELEASE} - exit ;; - news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; - R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) - if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} - else - echo mips-unknown-sysv${UNAME_RELEASE} - fi - exit ;; - BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - echo powerpc-be-beos - exit ;; - BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - echo powerpc-apple-beos - exit ;; - BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - echo i586-pc-beos - exit ;; - BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; - x86_64:Haiku:*:*) - echo x86_64-unknown-haiku - exit ;; - SX-4:SUPER-UX:*:*) - echo sx4-nec-superux${UNAME_RELEASE} - exit ;; - SX-5:SUPER-UX:*:*) - echo sx5-nec-superux${UNAME_RELEASE} - exit ;; - SX-6:SUPER-UX:*:*) - echo sx6-nec-superux${UNAME_RELEASE} - exit ;; - SX-7:SUPER-UX:*:*) - echo sx7-nec-superux${UNAME_RELEASE} - exit ;; - SX-8:SUPER-UX:*:*) - echo sx8-nec-superux${UNAME_RELEASE} - exit ;; - SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux${UNAME_RELEASE} - exit ;; - Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Rhapsody:*:*) - echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Darwin:*:*) - UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown - eval $set_cc_for_build - if test "$UNAME_PROCESSOR" = unknown ; then - UNAME_PROCESSOR=powerpc - fi - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - case $UNAME_PROCESSOR in - i386) UNAME_PROCESSOR=x86_64 ;; - powerpc) UNAME_PROCESSOR=powerpc64 ;; - esac - fi - fi - echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} - exit ;; - *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=`uname -p` - if test "$UNAME_PROCESSOR" = "x86"; then - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc - fi - echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} - exit ;; - *:QNX:*:4*) - echo i386-pc-qnx - exit ;; - NEO-?:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk${UNAME_RELEASE} - exit ;; - NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk${UNAME_RELEASE} - exit ;; - NSR-?:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk${UNAME_RELEASE} - exit ;; - *:NonStop-UX:*:*) - echo mips-compaq-nonstopux - exit ;; - BS2000:POSIX*:*:*) - echo bs2000-siemens-sysv - exit ;; - DS/*:UNIX_System_V:*:*) - echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} - exit ;; - *:Plan9:*:*) - # "uname -m" is not consistent, so use $cputype instead. 386 - # is converted to i386 for consistency with other x86 - # operating systems. - if test "$cputype" = "386"; then - UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" - fi - echo ${UNAME_MACHINE}-unknown-plan9 - exit ;; - *:TOPS-10:*:*) - echo pdp10-unknown-tops10 - exit ;; - *:TENEX:*:*) - echo pdp10-unknown-tenex - exit ;; - KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - echo pdp10-dec-tops20 - exit ;; - XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - echo pdp10-xkl-tops20 - exit ;; - *:TOPS-20:*:*) - echo pdp10-unknown-tops20 - exit ;; - *:ITS:*:*) - echo pdp10-unknown-its - exit ;; - SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} - exit ;; - *:DragonFly:*:*) - echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` - exit ;; - *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "${UNAME_MACHINE}" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; - esac ;; - *:XENIX:*:SysV) - echo i386-pc-xenix - exit ;; - i*86:skyos:*:*) - echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' - exit ;; - i*86:rdos:*:*) - echo ${UNAME_MACHINE}-pc-rdos - exit ;; - i*86:AROS:*:*) - echo ${UNAME_MACHINE}-pc-aros - exit ;; - x86_64:VMkernel:*:*) - echo ${UNAME_MACHINE}-unknown-esx - exit ;; -esac - -eval $set_cc_for_build -cat >$dummy.c < -# include -#endif -main () -{ -#if defined (sony) -#if defined (MIPSEB) - /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, - I don't know.... */ - printf ("mips-sony-bsd\n"); exit (0); -#else -#include - printf ("m68k-sony-newsos%s\n", -#ifdef NEWSOS4 - "4" -#else - "" -#endif - ); exit (0); -#endif -#endif - -#if defined (__arm) && defined (__acorn) && defined (__unix) - printf ("arm-acorn-riscix\n"); exit (0); -#endif - -#if defined (hp300) && !defined (hpux) - printf ("m68k-hp-bsd\n"); exit (0); -#endif - -#if defined (NeXT) -#if !defined (__ARCHITECTURE__) -#define __ARCHITECTURE__ "m68k" -#endif - int version; - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; - if (version < 4) - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); - else - printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); - exit (0); -#endif - -#if defined (MULTIMAX) || defined (n16) -#if defined (UMAXV) - printf ("ns32k-encore-sysv\n"); exit (0); -#else -#if defined (CMU) - printf ("ns32k-encore-mach\n"); exit (0); -#else - printf ("ns32k-encore-bsd\n"); exit (0); -#endif -#endif -#endif - -#if defined (__386BSD__) - printf ("i386-pc-bsd\n"); exit (0); -#endif - -#if defined (sequent) -#if defined (i386) - printf ("i386-sequent-dynix\n"); exit (0); -#endif -#if defined (ns32000) - printf ("ns32k-sequent-dynix\n"); exit (0); -#endif -#endif - -#if defined (_SEQUENT_) - struct utsname un; - - uname(&un); - - if (strncmp(un.version, "V2", 2) == 0) { - printf ("i386-sequent-ptx2\n"); exit (0); - } - if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ - printf ("i386-sequent-ptx1\n"); exit (0); - } - printf ("i386-sequent-ptx\n"); exit (0); - -#endif - -#if defined (vax) -# if !defined (ultrix) -# include -# if defined (BSD) -# if BSD == 43 - printf ("vax-dec-bsd4.3\n"); exit (0); -# else -# if BSD == 199006 - printf ("vax-dec-bsd4.3reno\n"); exit (0); -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# endif -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# else - printf ("vax-dec-ultrix\n"); exit (0); -# endif -#endif - -#if defined (alliant) && defined (i860) - printf ("i860-alliant-bsd\n"); exit (0); -#endif - - exit (1); -} -EOF - -$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - -# Apollos put the system type in the environment. - -test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } - -# Convex versions that predate uname can use getsysinfo(1) - -if [ -x /usr/convex/getsysinfo ] -then - case `getsysinfo -f cpu_type` in - c1*) - echo c1-convex-bsd - exit ;; - c2*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - c34*) - echo c34-convex-bsd - exit ;; - c38*) - echo c38-convex-bsd - exit ;; - c4*) - echo c4-convex-bsd - exit ;; - esac -fi - -cat >&2 < in order to provide the needed -information to handle your system. - -config.guess timestamp = $timestamp - -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null` - -hostinfo = `(hostinfo) 2>/dev/null` -/bin/universe = `(/bin/universe) 2>/dev/null` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` -/bin/arch = `(/bin/arch) 2>/dev/null` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` - -UNAME_MACHINE = ${UNAME_MACHINE} -UNAME_RELEASE = ${UNAME_RELEASE} -UNAME_SYSTEM = ${UNAME_SYSTEM} -UNAME_VERSION = ${UNAME_VERSION} -EOF - -exit 1 - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/libid3tag/config.h.in b/lib-src/libid3tag/config.h.in deleted file mode 100644 index 4f930cb9c..000000000 --- a/lib-src/libid3tag/config.h.in +++ /dev/null @@ -1,86 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to enable diagnostic debugging support. */ -#undef DEBUG - -/* Define to 1 if you have the header file. */ -#undef HAVE_ASSERT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the `ftruncate' function. */ -#undef HAVE_FTRUNCATE - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* Define to 1 if you have the `z' library (-lz). */ -#undef HAVE_LIBZ - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#undef LT_OBJDIR - -/* Define to disable debugging assertions. */ -#undef NDEBUG - -/* Name of package */ -#undef PACKAGE - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* Version number of package */ -#undef VERSION - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#undef inline -#endif diff --git a/lib-src/libid3tag/config.sub b/lib-src/libid3tag/config.sub deleted file mode 100755 index 9633db704..000000000 --- a/lib-src/libid3tag/config.sub +++ /dev/null @@ -1,1791 +0,0 @@ -#! /bin/sh -# Configuration validation subroutine script. -# Copyright 1992-2013 Free Software Foundation, Inc. - -timestamp='2013-08-10' - -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). - - -# Please send patches with a ChangeLog entry to config-patches@gnu.org. -# -# Configuration subroutine to validate and canonicalize a configuration type. -# Supply the specified configuration type as an argument. -# If it is invalid, we print an error message on stderr and exit with code 1. -# Otherwise, we print the canonical config type on stdout and succeed. - -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD - -# This file is supposed to be the same for all GNU packages -# and recognize all the CPU types, system types and aliases -# that are meaningful with *any* GNU software. -# Each package is responsible for reporting which valid configurations -# it does not support. The user should be able to distinguish -# a failure to support a valid configuration from a meaningless -# configuration. - -# The goal of this file is to map all the various variations of a given -# machine specification into a single specification in the form: -# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM -# or in some cases, the newer four-part form: -# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM -# It is wrong to echo any other type of specification. - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] CPU-MFR-OPSYS - $0 [OPTION] ALIAS - -Canonicalize a configuration name. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.sub ($timestamp) - -Copyright 1992-2013 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" - exit 1 ;; - - *local*) - # First pass through any local machine types. - echo $1 - exit ;; - - * ) - break ;; - esac -done - -case $# in - 0) echo "$me: missing argument$help" >&2 - exit 1;; - 1) ;; - *) echo "$me: too many arguments$help" >&2 - exit 1;; -esac - -# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). -# Here we must recognize all the valid KERNEL-OS combinations. -maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` -case $maybe_os in - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ - linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ - knetbsd*-gnu* | netbsd*-gnu* | \ - kopensolaris*-gnu* | \ - storm-chaos* | os2-emx* | rtmk-nova*) - os=-$maybe_os - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` - ;; - android-linux) - os=-linux-android - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown - ;; - *) - basic_machine=`echo $1 | sed 's/-[^-]*$//'` - if [ $basic_machine != $1 ] - then os=`echo $1 | sed 's/.*-/-/'` - else os=; fi - ;; -esac - -### Let's recognize common machines as not being operating systems so -### that things like config.sub decstation-3100 work. We also -### recognize some manufacturers as not being operating systems, so we -### can provide default operating systems below. -case $os in - -sun*os*) - # Prevent following clause from handling this invalid input. - ;; - -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ - -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ - -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ - -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ - -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ - -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray | -microblaze*) - os= - basic_machine=$1 - ;; - -bluegene*) - os=-cnk - ;; - -sim | -cisco | -oki | -wec | -winbond) - os= - basic_machine=$1 - ;; - -scout) - ;; - -wrs) - os=-vxworks - basic_machine=$1 - ;; - -chorusos*) - os=-chorusos - basic_machine=$1 - ;; - -chorusrdb) - os=-chorusrdb - basic_machine=$1 - ;; - -hiux*) - os=-hiuxwe2 - ;; - -sco6) - os=-sco5v6 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5) - os=-sco3.2v5 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco4) - os=-sco3.2v4 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2.[4-9]*) - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2v[4-9]*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5v6*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco*) - os=-sco3.2v2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -udk*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -isc) - os=-isc2.2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -clix*) - basic_machine=clipper-intergraph - ;; - -isc*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -lynx*178) - os=-lynxos178 - ;; - -lynx*5) - os=-lynxos5 - ;; - -lynx*) - os=-lynxos - ;; - -ptx*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` - ;; - -windowsnt*) - os=`echo $os | sed -e 's/windowsnt/winnt/'` - ;; - -psos*) - os=-psos - ;; - -mint | -mint[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; -esac - -# Decode aliases for certain CPU-COMPANY combinations. -case $basic_machine in - # Recognize the basic CPU types without company name. - # Some are omitted here because they have special meanings below. - 1750a | 580 \ - | a29k \ - | aarch64 | aarch64_be \ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ - | am33_2.0 \ - | arc | arceb \ - | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ - | avr | avr32 \ - | be32 | be64 \ - | bfin \ - | c4x | c8051 | clipper \ - | d10v | d30v | dlx | dsp16xx \ - | epiphany \ - | fido | fr30 | frv \ - | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ - | hexagon \ - | i370 | i860 | i960 | ia64 \ - | ip2k | iq2000 \ - | le32 | le64 \ - | lm32 \ - | m32c | m32r | m32rle | m68000 | m68k | m88k \ - | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ - | mips | mipsbe | mipseb | mipsel | mipsle \ - | mips16 \ - | mips64 | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ - | mips64vr | mips64vrel \ - | mips64vr4100 | mips64vr4100el \ - | mips64vr4300 | mips64vr4300el \ - | mips64vr5000 | mips64vr5000el \ - | mips64vr5900 | mips64vr5900el \ - | mipsisa32 | mipsisa32el \ - | mipsisa32r2 | mipsisa32r2el \ - | mipsisa64 | mipsisa64el \ - | mipsisa64r2 | mipsisa64r2el \ - | mipsisa64sb1 | mipsisa64sb1el \ - | mipsisa64sr71k | mipsisa64sr71kel \ - | mipsr5900 | mipsr5900el \ - | mipstx39 | mipstx39el \ - | mn10200 | mn10300 \ - | moxie \ - | mt \ - | msp430 \ - | nds32 | nds32le | nds32be \ - | nios | nios2 | nios2eb | nios2el \ - | ns16k | ns32k \ - | open8 \ - | or1k | or32 \ - | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle \ - | pyramid \ - | rl78 | rx \ - | score \ - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ - | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ - | spu \ - | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ - | ubicom32 \ - | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ - | we32k \ - | x86 | xc16x | xstormy16 | xtensa \ - | z8k | z80) - basic_machine=$basic_machine-unknown - ;; - c54x) - basic_machine=tic54x-unknown - ;; - c55x) - basic_machine=tic55x-unknown - ;; - c6x) - basic_machine=tic6x-unknown - ;; - m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip) - basic_machine=$basic_machine-unknown - os=-none - ;; - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) - ;; - ms1) - basic_machine=mt-unknown - ;; - - strongarm | thumb | xscale) - basic_machine=arm-unknown - ;; - xgate) - basic_machine=$basic_machine-unknown - os=-none - ;; - xscaleeb) - basic_machine=armeb-unknown - ;; - - xscaleel) - basic_machine=armel-unknown - ;; - - # We use `pc' rather than `unknown' - # because (1) that's what they normally are, and - # (2) the word "unknown" tends to confuse beginning users. - i*86 | x86_64) - basic_machine=$basic_machine-pc - ;; - # Object if more than one company name word. - *-*-*) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; - # Recognize the basic CPU types with company name. - 580-* \ - | a29k-* \ - | aarch64-* | aarch64_be-* \ - | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ - | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ - | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ - | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* | avr32-* \ - | be32-* | be64-* \ - | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* \ - | c8051-* | clipper-* | craynv-* | cydra-* \ - | d10v-* | d30v-* | dlx-* \ - | elxsi-* \ - | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ - | h8300-* | h8500-* \ - | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ - | hexagon-* \ - | i*86-* | i860-* | i960-* | ia64-* \ - | ip2k-* | iq2000-* \ - | le32-* | le64-* \ - | lm32-* \ - | m32c-* | m32r-* | m32rle-* \ - | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ - | microblaze-* | microblazeel-* \ - | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ - | mips16-* \ - | mips64-* | mips64el-* \ - | mips64octeon-* | mips64octeonel-* \ - | mips64orion-* | mips64orionel-* \ - | mips64r5900-* | mips64r5900el-* \ - | mips64vr-* | mips64vrel-* \ - | mips64vr4100-* | mips64vr4100el-* \ - | mips64vr4300-* | mips64vr4300el-* \ - | mips64vr5000-* | mips64vr5000el-* \ - | mips64vr5900-* | mips64vr5900el-* \ - | mipsisa32-* | mipsisa32el-* \ - | mipsisa32r2-* | mipsisa32r2el-* \ - | mipsisa64-* | mipsisa64el-* \ - | mipsisa64r2-* | mipsisa64r2el-* \ - | mipsisa64sb1-* | mipsisa64sb1el-* \ - | mipsisa64sr71k-* | mipsisa64sr71kel-* \ - | mipsr5900-* | mipsr5900el-* \ - | mipstx39-* | mipstx39el-* \ - | mmix-* \ - | mt-* \ - | msp430-* \ - | nds32-* | nds32le-* | nds32be-* \ - | nios-* | nios2-* | nios2eb-* | nios2el-* \ - | none-* | np1-* | ns16k-* | ns32k-* \ - | open8-* \ - | orion-* \ - | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ - | pyramid-* \ - | rl78-* | romp-* | rs6000-* | rx-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ - | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ - | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ - | tahoe-* \ - | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ - | tile*-* \ - | tron-* \ - | ubicom32-* \ - | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ - | vax-* \ - | we32k-* \ - | x86-* | x86_64-* | xc16x-* | xps100-* \ - | xstormy16-* | xtensa*-* \ - | ymp-* \ - | z8k-* | z80-*) - ;; - # Recognize the basic CPU types without company name, with glob match. - xtensa*) - basic_machine=$basic_machine-unknown - ;; - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. - 386bsd) - basic_machine=i386-unknown - os=-bsd - ;; - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) - basic_machine=m68000-att - ;; - 3b*) - basic_machine=we32k-att - ;; - a29khif) - basic_machine=a29k-amd - os=-udi - ;; - abacus) - basic_machine=abacus-unknown - ;; - adobe68k) - basic_machine=m68010-adobe - os=-scout - ;; - alliant | fx80) - basic_machine=fx80-alliant - ;; - altos | altos3068) - basic_machine=m68k-altos - ;; - am29k) - basic_machine=a29k-none - os=-bsd - ;; - amd64) - basic_machine=x86_64-pc - ;; - amd64-*) - basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - amdahl) - basic_machine=580-amdahl - os=-sysv - ;; - amiga | amiga-*) - basic_machine=m68k-unknown - ;; - amigaos | amigados) - basic_machine=m68k-unknown - os=-amigaos - ;; - amigaunix | amix) - basic_machine=m68k-unknown - os=-sysv4 - ;; - apollo68) - basic_machine=m68k-apollo - os=-sysv - ;; - apollo68bsd) - basic_machine=m68k-apollo - os=-bsd - ;; - aros) - basic_machine=i386-pc - os=-aros - ;; - aux) - basic_machine=m68k-apple - os=-aux - ;; - balance) - basic_machine=ns32k-sequent - os=-dynix - ;; - blackfin) - basic_machine=bfin-unknown - os=-linux - ;; - blackfin-*) - basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - bluegene*) - basic_machine=powerpc-ibm - os=-cnk - ;; - c54x-*) - basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c55x-*) - basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c6x-*) - basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c90) - basic_machine=c90-cray - os=-unicos - ;; - cegcc) - basic_machine=arm-unknown - os=-cegcc - ;; - convex-c1) - basic_machine=c1-convex - os=-bsd - ;; - convex-c2) - basic_machine=c2-convex - os=-bsd - ;; - convex-c32) - basic_machine=c32-convex - os=-bsd - ;; - convex-c34) - basic_machine=c34-convex - os=-bsd - ;; - convex-c38) - basic_machine=c38-convex - os=-bsd - ;; - cray | j90) - basic_machine=j90-cray - os=-unicos - ;; - craynv) - basic_machine=craynv-cray - os=-unicosmp - ;; - cr16 | cr16-*) - basic_machine=cr16-unknown - os=-elf - ;; - crds | unos) - basic_machine=m68k-crds - ;; - crisv32 | crisv32-* | etraxfs*) - basic_machine=crisv32-axis - ;; - cris | cris-* | etrax*) - basic_machine=cris-axis - ;; - crx) - basic_machine=crx-unknown - os=-elf - ;; - da30 | da30-*) - basic_machine=m68k-da30 - ;; - decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) - basic_machine=mips-dec - ;; - decsystem10* | dec10*) - basic_machine=pdp10-dec - os=-tops10 - ;; - decsystem20* | dec20*) - basic_machine=pdp10-dec - os=-tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) - basic_machine=m68k-motorola - ;; - delta88) - basic_machine=m88k-motorola - os=-sysv3 - ;; - dicos) - basic_machine=i686-pc - os=-dicos - ;; - djgpp) - basic_machine=i586-pc - os=-msdosdjgpp - ;; - dpx20 | dpx20-*) - basic_machine=rs6000-bull - os=-bosx - ;; - dpx2* | dpx2*-bull) - basic_machine=m68k-bull - os=-sysv3 - ;; - ebmon29k) - basic_machine=a29k-amd - os=-ebmon - ;; - elxsi) - basic_machine=elxsi-elxsi - os=-bsd - ;; - encore | umax | mmax) - basic_machine=ns32k-encore - ;; - es1800 | OSE68k | ose68k | ose | OSE) - basic_machine=m68k-ericsson - os=-ose - ;; - fx2800) - basic_machine=i860-alliant - ;; - genix) - basic_machine=ns32k-ns - ;; - gmicro) - basic_machine=tron-gmicro - os=-sysv - ;; - go32) - basic_machine=i386-pc - os=-go32 - ;; - h3050r* | hiux*) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - h8300hms) - basic_machine=h8300-hitachi - os=-hms - ;; - h8300xray) - basic_machine=h8300-hitachi - os=-xray - ;; - h8500hms) - basic_machine=h8500-hitachi - os=-hms - ;; - harris) - basic_machine=m88k-harris - os=-sysv3 - ;; - hp300-*) - basic_machine=m68k-hp - ;; - hp300bsd) - basic_machine=m68k-hp - os=-bsd - ;; - hp300hpux) - basic_machine=m68k-hp - os=-hpux - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) - basic_machine=m68000-hp - ;; - hp9k3[2-9][0-9]) - basic_machine=m68k-hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) - basic_machine=hppa1.1-hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hppa-next) - os=-nextstep3 - ;; - hppaosf) - basic_machine=hppa1.1-hp - os=-osf - ;; - hppro) - basic_machine=hppa1.1-hp - os=-proelf - ;; - i370-ibm* | ibm*) - basic_machine=i370-ibm - ;; - i*86v32) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv32 - ;; - i*86v4*) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv4 - ;; - i*86v) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv - ;; - i*86sol2) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-solaris2 - ;; - i386mach) - basic_machine=i386-mach - os=-mach - ;; - i386-vsta | vsta) - basic_machine=i386-unknown - os=-vsta - ;; - iris | iris4d) - basic_machine=mips-sgi - case $os in - -irix*) - ;; - *) - os=-irix4 - ;; - esac - ;; - isi68 | isi) - basic_machine=m68k-isi - os=-sysv - ;; - m68knommu) - basic_machine=m68k-unknown - os=-linux - ;; - m68knommu-*) - basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - m88k-omron*) - basic_machine=m88k-omron - ;; - magnum | m3230) - basic_machine=mips-mips - os=-sysv - ;; - merlin) - basic_machine=ns32k-utek - os=-sysv - ;; - microblaze*) - basic_machine=microblaze-xilinx - ;; - mingw64) - basic_machine=x86_64-pc - os=-mingw64 - ;; - mingw32) - basic_machine=i686-pc - os=-mingw32 - ;; - mingw32ce) - basic_machine=arm-unknown - os=-mingw32ce - ;; - miniframe) - basic_machine=m68000-convergent - ;; - *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; - mips3*-*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` - ;; - mips3*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown - ;; - monitor) - basic_machine=m68k-rom68k - os=-coff - ;; - morphos) - basic_machine=powerpc-unknown - os=-morphos - ;; - msdos) - basic_machine=i386-pc - os=-msdos - ;; - ms1-*) - basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` - ;; - msys) - basic_machine=i686-pc - os=-msys - ;; - mvs) - basic_machine=i370-ibm - os=-mvs - ;; - nacl) - basic_machine=le32-unknown - os=-nacl - ;; - ncr3000) - basic_machine=i486-ncr - os=-sysv4 - ;; - netbsd386) - basic_machine=i386-unknown - os=-netbsd - ;; - netwinder) - basic_machine=armv4l-rebel - os=-linux - ;; - news | news700 | news800 | news900) - basic_machine=m68k-sony - os=-newsos - ;; - news1000) - basic_machine=m68030-sony - os=-newsos - ;; - news-3600 | risc-news) - basic_machine=mips-sony - os=-newsos - ;; - necv70) - basic_machine=v70-nec - os=-sysv - ;; - next | m*-next ) - basic_machine=m68k-next - case $os in - -nextstep* ) - ;; - -ns2*) - os=-nextstep2 - ;; - *) - os=-nextstep3 - ;; - esac - ;; - nh3000) - basic_machine=m68k-harris - os=-cxux - ;; - nh[45]000) - basic_machine=m88k-harris - os=-cxux - ;; - nindy960) - basic_machine=i960-intel - os=-nindy - ;; - mon960) - basic_machine=i960-intel - os=-mon960 - ;; - nonstopux) - basic_machine=mips-compaq - os=-nonstopux - ;; - np1) - basic_machine=np1-gould - ;; - neo-tandem) - basic_machine=neo-tandem - ;; - nse-tandem) - basic_machine=nse-tandem - ;; - nsr-tandem) - basic_machine=nsr-tandem - ;; - op50n-* | op60c-*) - basic_machine=hppa1.1-oki - os=-proelf - ;; - openrisc | openrisc-*) - basic_machine=or32-unknown - ;; - os400) - basic_machine=powerpc-ibm - os=-os400 - ;; - OSE68000 | ose68000) - basic_machine=m68000-ericsson - os=-ose - ;; - os68k) - basic_machine=m68k-none - os=-os68k - ;; - pa-hitachi) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - paragon) - basic_machine=i860-intel - os=-osf - ;; - parisc) - basic_machine=hppa-unknown - os=-linux - ;; - parisc-*) - basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - pbd) - basic_machine=sparc-tti - ;; - pbb) - basic_machine=m68k-tti - ;; - pc532 | pc532-*) - basic_machine=ns32k-pc532 - ;; - pc98) - basic_machine=i386-pc - ;; - pc98-*) - basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium | p5 | k5 | k6 | nexgen | viac3) - basic_machine=i586-pc - ;; - pentiumpro | p6 | 6x86 | athlon | athlon_*) - basic_machine=i686-pc - ;; - pentiumii | pentium2 | pentiumiii | pentium3) - basic_machine=i686-pc - ;; - pentium4) - basic_machine=i786-pc - ;; - pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) - basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumpro-* | p6-* | 6x86-* | athlon-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium4-*) - basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pn) - basic_machine=pn-gould - ;; - power) basic_machine=power-ibm - ;; - ppc | ppcbe) basic_machine=powerpc-unknown - ;; - ppc-* | ppcbe-*) - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppcle | powerpclittle | ppc-le | powerpc-little) - basic_machine=powerpcle-unknown - ;; - ppcle-* | powerpclittle-*) - basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64) basic_machine=powerpc64-unknown - ;; - ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64le | powerpc64little | ppc64-le | powerpc64-little) - basic_machine=powerpc64le-unknown - ;; - ppc64le-* | powerpc64little-*) - basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ps2) - basic_machine=i386-ibm - ;; - pw32) - basic_machine=i586-unknown - os=-pw32 - ;; - rdos | rdos64) - basic_machine=x86_64-pc - os=-rdos - ;; - rdos32) - basic_machine=i386-pc - os=-rdos - ;; - rom68k) - basic_machine=m68k-rom68k - os=-coff - ;; - rm[46]00) - basic_machine=mips-siemens - ;; - rtpc | rtpc-*) - basic_machine=romp-ibm - ;; - s390 | s390-*) - basic_machine=s390-ibm - ;; - s390x | s390x-*) - basic_machine=s390x-ibm - ;; - sa29200) - basic_machine=a29k-amd - os=-udi - ;; - sb1) - basic_machine=mipsisa64sb1-unknown - ;; - sb1el) - basic_machine=mipsisa64sb1el-unknown - ;; - sde) - basic_machine=mipsisa32-sde - os=-elf - ;; - sei) - basic_machine=mips-sei - os=-seiux - ;; - sequent) - basic_machine=i386-sequent - ;; - sh) - basic_machine=sh-hitachi - os=-hms - ;; - sh5el) - basic_machine=sh5le-unknown - ;; - sh64) - basic_machine=sh64-unknown - ;; - sparclite-wrs | simso-wrs) - basic_machine=sparclite-wrs - os=-vxworks - ;; - sps7) - basic_machine=m68k-bull - os=-sysv2 - ;; - spur) - basic_machine=spur-unknown - ;; - st2000) - basic_machine=m68k-tandem - ;; - stratus) - basic_machine=i860-stratus - os=-sysv4 - ;; - strongarm-* | thumb-*) - basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - sun2) - basic_machine=m68000-sun - ;; - sun2os3) - basic_machine=m68000-sun - os=-sunos3 - ;; - sun2os4) - basic_machine=m68000-sun - os=-sunos4 - ;; - sun3os3) - basic_machine=m68k-sun - os=-sunos3 - ;; - sun3os4) - basic_machine=m68k-sun - os=-sunos4 - ;; - sun4os3) - basic_machine=sparc-sun - os=-sunos3 - ;; - sun4os4) - basic_machine=sparc-sun - os=-sunos4 - ;; - sun4sol2) - basic_machine=sparc-sun - os=-solaris2 - ;; - sun3 | sun3-*) - basic_machine=m68k-sun - ;; - sun4) - basic_machine=sparc-sun - ;; - sun386 | sun386i | roadrunner) - basic_machine=i386-sun - ;; - sv1) - basic_machine=sv1-cray - os=-unicos - ;; - symmetry) - basic_machine=i386-sequent - os=-dynix - ;; - t3e) - basic_machine=alphaev5-cray - os=-unicos - ;; - t90) - basic_machine=t90-cray - os=-unicos - ;; - tile*) - basic_machine=$basic_machine-unknown - os=-linux-gnu - ;; - tx39) - basic_machine=mipstx39-unknown - ;; - tx39el) - basic_machine=mipstx39el-unknown - ;; - toad1) - basic_machine=pdp10-xkl - os=-tops20 - ;; - tower | tower-32) - basic_machine=m68k-ncr - ;; - tpf) - basic_machine=s390x-ibm - os=-tpf - ;; - udi29k) - basic_machine=a29k-amd - os=-udi - ;; - ultra3) - basic_machine=a29k-nyu - os=-sym1 - ;; - v810 | necv810) - basic_machine=v810-nec - os=-none - ;; - vaxv) - basic_machine=vax-dec - os=-sysv - ;; - vms) - basic_machine=vax-dec - os=-vms - ;; - vpp*|vx|vx-*) - basic_machine=f301-fujitsu - ;; - vxworks960) - basic_machine=i960-wrs - os=-vxworks - ;; - vxworks68) - basic_machine=m68k-wrs - os=-vxworks - ;; - vxworks29k) - basic_machine=a29k-wrs - os=-vxworks - ;; - w65*) - basic_machine=w65-wdc - os=-none - ;; - w89k-*) - basic_machine=hppa1.1-winbond - os=-proelf - ;; - xbox) - basic_machine=i686-pc - os=-mingw32 - ;; - xps | xps100) - basic_machine=xps100-honeywell - ;; - xscale-* | xscalee[bl]-*) - basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` - ;; - ymp) - basic_machine=ymp-cray - os=-unicos - ;; - z8k-*-coff) - basic_machine=z8k-unknown - os=-sim - ;; - z80-*-coff) - basic_machine=z80-unknown - os=-sim - ;; - none) - basic_machine=none-none - os=-none - ;; - -# Here we handle the default manufacturer of certain CPU types. It is in -# some cases the only manufacturer, in others, it is the most popular. - w89k) - basic_machine=hppa1.1-winbond - ;; - op50n) - basic_machine=hppa1.1-oki - ;; - op60c) - basic_machine=hppa1.1-oki - ;; - romp) - basic_machine=romp-ibm - ;; - mmix) - basic_machine=mmix-knuth - ;; - rs6000) - basic_machine=rs6000-ibm - ;; - vax) - basic_machine=vax-dec - ;; - pdp10) - # there are many clones, so DEC is not a safe bet - basic_machine=pdp10-unknown - ;; - pdp11) - basic_machine=pdp11-dec - ;; - we32k) - basic_machine=we32k-att - ;; - sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) - basic_machine=sh-unknown - ;; - sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) - basic_machine=sparc-sun - ;; - cydra) - basic_machine=cydra-cydrome - ;; - orion) - basic_machine=orion-highlevel - ;; - orion105) - basic_machine=clipper-highlevel - ;; - mac | mpw | mac-mpw) - basic_machine=m68k-apple - ;; - pmac | pmac-mpw) - basic_machine=powerpc-apple - ;; - *-unknown) - # Make sure to match an already-canonicalized machine name. - ;; - *) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; -esac - -# Here we canonicalize certain aliases for manufacturers. -case $basic_machine in - *-digital*) - basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` - ;; - *-commodore*) - basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` - ;; - *) - ;; -esac - -# Decode manufacturer-specific aliases for certain operating systems. - -if [ x"$os" != x"" ] -then -case $os in - # First match some system type aliases - # that might get confused with valid system types. - # -solaris* is a basic system type, with this one exception. - -auroraux) - os=-auroraux - ;; - -solaris1 | -solaris1.*) - os=`echo $os | sed -e 's|solaris1|sunos4|'` - ;; - -solaris) - os=-solaris2 - ;; - -svr4*) - os=-sysv4 - ;; - -unixware*) - os=-sysv4.2uw - ;; - -gnu/linux*) - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` - ;; - # First accept the basic system types. - # The portable systems comes first. - # Each alternative MUST END IN A *, to match a version number. - # -sysv* is not here because it comes later, after sysvr4. - -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ - | -sym* | -kopensolaris* | -plan9* \ - | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* | -aros* \ - | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ - | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ - | -bitrig* | -openbsd* | -solidbsd* \ - | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ - | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ - | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ - | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* | -cegcc* \ - | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ - | -linux-newlib* | -linux-musl* | -linux-uclibc* \ - | -uxpv* | -beos* | -mpeix* | -udk* \ - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ - | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ - | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ - | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ - | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) - # Remember, each alternative MUST END IN *, to match a version number. - ;; - -qnx*) - case $basic_machine in - x86-* | i*86-*) - ;; - *) - os=-nto$os - ;; - esac - ;; - -nto-qnx*) - ;; - -nto*) - os=`echo $os | sed -e 's|nto|nto-qnx|'` - ;; - -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ - | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ - | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) - ;; - -mac*) - os=`echo $os | sed -e 's|mac|macos|'` - ;; - -linux-dietlibc) - os=-linux-dietlibc - ;; - -linux*) - os=`echo $os | sed -e 's|linux|linux-gnu|'` - ;; - -sunos5*) - os=`echo $os | sed -e 's|sunos5|solaris2|'` - ;; - -sunos6*) - os=`echo $os | sed -e 's|sunos6|solaris3|'` - ;; - -opened*) - os=-openedition - ;; - -os400*) - os=-os400 - ;; - -wince*) - os=-wince - ;; - -osfrose*) - os=-osfrose - ;; - -osf*) - os=-osf - ;; - -utek*) - os=-bsd - ;; - -dynix*) - os=-bsd - ;; - -acis*) - os=-aos - ;; - -atheos*) - os=-atheos - ;; - -syllable*) - os=-syllable - ;; - -386bsd) - os=-bsd - ;; - -ctix* | -uts*) - os=-sysv - ;; - -nova*) - os=-rtmk-nova - ;; - -ns2 ) - os=-nextstep2 - ;; - -nsk*) - os=-nsk - ;; - # Preserve the version number of sinix5. - -sinix5.*) - os=`echo $os | sed -e 's|sinix|sysv|'` - ;; - -sinix*) - os=-sysv4 - ;; - -tpf*) - os=-tpf - ;; - -triton*) - os=-sysv3 - ;; - -oss*) - os=-sysv3 - ;; - -svr4) - os=-sysv4 - ;; - -svr3) - os=-sysv3 - ;; - -sysvr4) - os=-sysv4 - ;; - # This must come after -sysvr4. - -sysv*) - ;; - -ose*) - os=-ose - ;; - -es1800*) - os=-ose - ;; - -xenix) - os=-xenix - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - os=-mint - ;; - -aros*) - os=-aros - ;; - -zvmoe) - os=-zvmoe - ;; - -dicos*) - os=-dicos - ;; - -nacl*) - ;; - -none) - ;; - *) - # Get rid of the `-' at the beginning of $os. - os=`echo $os | sed 's/[^-]*-//'` - echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 - exit 1 - ;; -esac -else - -# Here we handle the default operating systems that come with various machines. -# The value should be what the vendor currently ships out the door with their -# machine or put another way, the most popular os provided with the machine. - -# Note that if you're going to try to match "-MANUFACTURER" here (say, -# "-sun"), then you have to tell the case statement up towards the top -# that MANUFACTURER isn't an operating system. Otherwise, code above -# will signal an error saying that MANUFACTURER isn't an operating -# system, and we'll never get to this point. - -case $basic_machine in - score-*) - os=-elf - ;; - spu-*) - os=-elf - ;; - *-acorn) - os=-riscix1.2 - ;; - arm*-rebel) - os=-linux - ;; - arm*-semi) - os=-aout - ;; - c4x-* | tic4x-*) - os=-coff - ;; - c8051-*) - os=-elf - ;; - hexagon-*) - os=-elf - ;; - tic54x-*) - os=-coff - ;; - tic55x-*) - os=-coff - ;; - tic6x-*) - os=-coff - ;; - # This must come before the *-dec entry. - pdp10-*) - os=-tops20 - ;; - pdp11-*) - os=-none - ;; - *-dec | vax-*) - os=-ultrix4.2 - ;; - m68*-apollo) - os=-domain - ;; - i386-sun) - os=-sunos4.0.2 - ;; - m68000-sun) - os=-sunos3 - ;; - m68*-cisco) - os=-aout - ;; - mep-*) - os=-elf - ;; - mips*-cisco) - os=-elf - ;; - mips*-*) - os=-elf - ;; - or1k-*) - os=-elf - ;; - or32-*) - os=-coff - ;; - *-tti) # must be before sparc entry or we get the wrong os. - os=-sysv3 - ;; - sparc-* | *-sun) - os=-sunos4.1.1 - ;; - *-be) - os=-beos - ;; - *-haiku) - os=-haiku - ;; - *-ibm) - os=-aix - ;; - *-knuth) - os=-mmixware - ;; - *-wec) - os=-proelf - ;; - *-winbond) - os=-proelf - ;; - *-oki) - os=-proelf - ;; - *-hp) - os=-hpux - ;; - *-hitachi) - os=-hiux - ;; - i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) - os=-sysv - ;; - *-cbm) - os=-amigaos - ;; - *-dg) - os=-dgux - ;; - *-dolphin) - os=-sysv3 - ;; - m68k-ccur) - os=-rtu - ;; - m88k-omron*) - os=-luna - ;; - *-next ) - os=-nextstep - ;; - *-sequent) - os=-ptx - ;; - *-crds) - os=-unos - ;; - *-ns) - os=-genix - ;; - i370-*) - os=-mvs - ;; - *-next) - os=-nextstep3 - ;; - *-gould) - os=-sysv - ;; - *-highlevel) - os=-bsd - ;; - *-encore) - os=-bsd - ;; - *-sgi) - os=-irix - ;; - *-siemens) - os=-sysv4 - ;; - *-masscomp) - os=-rtu - ;; - f30[01]-fujitsu | f700-fujitsu) - os=-uxpv - ;; - *-rom68k) - os=-coff - ;; - *-*bug) - os=-coff - ;; - *-apple) - os=-macos - ;; - *-atari*) - os=-mint - ;; - *) - os=-none - ;; -esac -fi - -# Here we handle the case where we know the os, and the CPU type, but not the -# manufacturer. We pick the logical manufacturer. -vendor=unknown -case $basic_machine in - *-unknown) - case $os in - -riscix*) - vendor=acorn - ;; - -sunos*) - vendor=sun - ;; - -cnk*|-aix*) - vendor=ibm - ;; - -beos*) - vendor=be - ;; - -hpux*) - vendor=hp - ;; - -mpeix*) - vendor=hp - ;; - -hiux*) - vendor=hitachi - ;; - -unos*) - vendor=crds - ;; - -dgux*) - vendor=dg - ;; - -luna*) - vendor=omron - ;; - -genix*) - vendor=ns - ;; - -mvs* | -opened*) - vendor=ibm - ;; - -os400*) - vendor=ibm - ;; - -ptx*) - vendor=sequent - ;; - -tpf*) - vendor=ibm - ;; - -vxsim* | -vxworks* | -windiss*) - vendor=wrs - ;; - -aux*) - vendor=apple - ;; - -hms*) - vendor=hitachi - ;; - -mpw* | -macos*) - vendor=apple - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - vendor=atari - ;; - -vos*) - vendor=stratus - ;; - esac - basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` - ;; -esac - -echo $basic_machine$os -exit - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/libid3tag/configure b/lib-src/libid3tag/configure deleted file mode 100755 index 485babcf3..000000000 --- a/lib-src/libid3tag/configure +++ /dev/null @@ -1,14425 +0,0 @@ -#! /bin/sh -# From configure.ac Id: configure.ac,v 1.5 2009-01-23 23:39:44 richardash1981 Exp . -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for ID3 Tag 0.15.1b. -# -# Report bugs to . -# -# -# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# Use a proper internal environment variable to ensure we don't fall - # into an infinite loop, continuously re-executing ourselves. - if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then - _as_can_reexec=no; export _as_can_reexec; - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -as_fn_exit 255 - fi - # We don't want this to propagate to other subprocesses. - { _as_can_reexec=; unset _as_can_reexec;} -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : - -else - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1 -test -x / || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 - - test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ - || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" - if (eval "$as_required") 2>/dev/null; then : - as_have_required=yes -else - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : - -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : - CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : - break 2 -fi -fi - done;; - esac - as_found=false -done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } -IFS=$as_save_IFS - - - if test "x$CONFIG_SHELL" != x; then : - export CONFIG_SHELL - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 -fi - - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." - else - $as_echo "$0: Please tell bug-autoconf@gnu.org and -$0: support@underbit.com about your system, including any -$0: error possibly output before this message. Then install -$0: a modern shell, or manually run the script under such a -$0: shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # If we had to re-execute with $CONFIG_SHELL, we're ensured to have - # already done that, so ensure we don't try to do so again and fall - # in an infinite loop. This has already happened in practice. - _as_can_reexec=no; export _as_can_reexec - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - -SHELL=${CONFIG_SHELL-/bin/sh} - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME='ID3 Tag' -PACKAGE_TARNAME='libid3tag' -PACKAGE_VERSION='0.15.1b' -PACKAGE_STRING='ID3 Tag 0.15.1b' -PACKAGE_BUGREPORT='support@underbit.com' -PACKAGE_URL='' - -ac_unique_file="id3tag.h" -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef STDC_HEADERS -# include -# include -#else -# ifdef HAVE_STDLIB_H -# include -# endif -#endif -#ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include -# endif -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_subst_vars='am__EXEEXT_FALSE -am__EXEEXT_TRUE -LTLIBOBJS -LIBOBJS -DEBUG_FALSE -DEBUG_TRUE -LIBTOOL_DEPS -CPP -OTOOL64 -OTOOL -LIPO -NMEDIT -DSYMUTIL -MANIFEST_TOOL -RANLIB -ac_ct_AR -AR -DLLTOOL -OBJDUMP -LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP -EGREP -GREP -SED -LIBTOOL -am__fastdepCC_FALSE -am__fastdepCC_TRUE -CCDEPMODE -am__nodep -AMDEPBACKSLASH -AMDEP_FALSE -AMDEP_TRUE -am__quote -am__include -DEPDIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -host_os -host_vendor -host_cpu -host -build_os -build_vendor -build_cpu -build -MAINT -MAINTAINER_MODE_FALSE -MAINTAINER_MODE_TRUE -AM_BACKSLASH -AM_DEFAULT_VERBOSITY -AM_DEFAULT_V -AM_V -am__untar -am__tar -AMTAR -am__leading_dot -SET_MAKE -AWK -mkdir_p -MKDIR_P -INSTALL_STRIP_PROGRAM -STRIP -install_sh -MAKEINFO -AUTOHEADER -AUTOMAKE -AUTOCONF -ACLOCAL -VERSION -PACKAGE -CYGPATH_W -am__isrc -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_silent_rules -enable_maintainer_mode -enable_dependency_tracking -enable_shared -enable_static -with_pic -enable_fast_install -with_gnu_ld -with_sysroot -enable_libtool_lock -enable_profiling -enable_debugging -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -CPP' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *=) ac_optarg= ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error $? "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information" - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error $? "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error $? "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error $? "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures ID3 Tag 0.15.1b to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking ...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/libid3tag] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names - -System types: - --build=BUILD configure for building on BUILD [guessed] - --host=HOST cross-compile to build programs to run on HOST [BUILD] -_ACEOF -fi - -if test -n "$ac_init_help"; then - case $ac_init_help in - short | recursive ) echo "Configuration of ID3 Tag 0.15.1b:";; - esac - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-silent-rules less verbose build output (undo: "make V=1") - --disable-silent-rules verbose build output (undo: "make V=0") - --enable-maintainer-mode - enable make rules and dependencies not useful (and - sometimes confusing) to the casual installer - --enable-dependency-tracking - do not reject slow dependency extractors - --disable-dependency-tracking - speeds up one-time build - --enable-shared[=PKGS] build shared libraries [default=yes] - --enable-static[=PKGS] build static libraries [default=yes] - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) - --enable-profiling generate profiling code - --enable-debugging enable diagnostic debugging support - --disable-debugging do not enable debugging and use more optimization - -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use - both] - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-sysroot=DIR Search for dependent libraries within DIR - (or the compiler's sysroot if not specified). - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - CPP C preprocessor - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to . -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -ID3 Tag configure 0.15.1b -generated by GNU Autoconf 2.69 - -Copyright (C) 2012 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link - -# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists and can be compiled using the include files in -# INCLUDES, setting the cache variable VAR accordingly. -ac_fn_c_check_header_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_compile - -# ac_fn_c_try_cpp LINENO -# ---------------------- -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_cpp - -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : - ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_run - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_func - -# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists, giving a warning if it cannot be compiled using -# the include files in INCLUDES and setting the cache variable VAR -# accordingly. -ac_fn_c_check_header_mongrel () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval \${$3+:} false; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 -$as_echo_n "checking $2 usability... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_header_compiler=yes -else - ac_header_compiler=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } - -# Is the header present? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 -$as_echo_n "checking $2 presence... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <$2> -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - ac_header_preproc=yes -else - ac_header_preproc=no -fi -rm -f conftest.err conftest.i conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( - yes:no: ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} - ;; - no:yes:* ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} -( $as_echo "## ----------------------------------- ## -## Report this to support@underbit.com ## -## ----------------------------------- ##" - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=\$ac_header_compiler" -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_mongrel -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by ID3 Tag $as_me 0.15.1b, which was -generated by GNU Autoconf 2.69. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - $as_echo "## ---------------- ## -## Cache variables. ## -## ---------------- ##" - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - $as_echo "## ----------------- ## -## Output variables. ## -## ----------------- ##" - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - $as_echo "## ------------------- ## -## File substitutions. ## -## ------------------- ##" - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - $as_echo "## ----------- ## -## confdefs.h. ## -## ----------- ##" - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -$as_echo "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE -if test -n "$CONFIG_SITE"; then - # We do not want a PATH search for config.site. - case $CONFIG_SITE in #(( - -*) ac_site_file1=./$CONFIG_SITE;; - */*) ac_site_file1=$CONFIG_SITE;; - *) ac_site_file1=./$CONFIG_SITE;; - esac -elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site -else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site -fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" -do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" \ - || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5; } - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - - - - - - -am__api_version='1.14' - -ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if ${ac_cv_path_install+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -$as_echo_n "checking whether build environment is sane... " >&6; } -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; -esac -case $srcdir in - *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; -esac - -# Do 'set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error $? "ls -t appears to fail. Make sure there is not a broken - alias in your environment" "$LINENO" 5 - fi - if test "$2" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error $? "newly created file is older than distributed files! -Check your system clock" "$LINENO" 5 -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -# If we didn't sleep, we still need to ensure time stamps of config.status and -# generated files are strictly newer. -am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & - am_sleep_pid=$! -fi - -rm -f conftest.file - -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. -# By default was `s,x,x', remove it if useless. -ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` - -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` - -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --is-lightweight"; then - am_missing_run="$MISSING " -else - am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} -fi - -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi - -# Installed binaries are usually stripped using 'strip' when the user -# run "make install-strip". However 'strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the 'STRIP' environment variable to overrule this program. -if test "$cross_compiling" != no; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 -$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } -if test -z "$MKDIR_P"; then - if ${ac_cv_path_mkdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in mkdir gmkdir; do - for ac_exec_ext in '' $ac_executable_extensions; do - as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue - case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir (GNU coreutils) '* | \ - 'mkdir (coreutils) '* | \ - 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext - break 3;; - esac - done - done - done -IFS=$as_save_IFS - -fi - - test -d ./--version && rmdir ./--version - if test "${ac_cv_path_mkdir+set}" = set; then - MKDIR_P="$ac_cv_path_mkdir -p" - else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AWK+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AWK" && break -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - SET_MAKE= -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null - -# Check whether --enable-silent-rules was given. -if test "${enable_silent_rules+set}" = set; then : - enableval=$enable_silent_rules; -fi - -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=1;; -esac -am_make=${MAKE-make} -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -$as_echo_n "checking whether $am_make supports nested variables... " >&6; } -if ${am_cv_make_support_nested_variables+:} false; then : - $as_echo_n "(cached) " >&6 -else - if $as_echo 'TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -$as_echo "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AM_BACKSLASH='\' - -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - am__isrc=' -I$(srcdir)' - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi - - -# Define the identity of the package. - PACKAGE='libid3tag' - VERSION='0.15.1b' - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE "$PACKAGE" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VERSION "$VERSION" -_ACEOF - -# Some tools Automake needs. - -ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} - - -AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} - - -AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} - - -AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} - - -MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} - -# For better backward compatibility. To be removed once Automake 1.9.x -# dies out for good. For more background, see: -# -# -mkdir_p='$(MKDIR_P)' - -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. Yes, it's still used -# in the wild :-( We should find a proper way to deprecate it ... -AMTAR='$${TAR-tar}' - - -# We'll loop over all known methods to create a tar archive until one works. -_am_tools='gnutar pax cpio none' - -am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' - - - - - - -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! - -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: - -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. - -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. - -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . - -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. - -END - as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 - fi -fi - -ac_config_headers="$ac_config_headers config.h" - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 -$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } - # Check whether --enable-maintainer-mode was given. -if test "${enable_maintainer_mode+set}" = set; then : - enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval -else - USE_MAINTAINER_MODE=no -fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 -$as_echo "$USE_MAINTAINER_MODE" >&6; } - if test $USE_MAINTAINER_MODE = yes; then - MAINTAINER_MODE_TRUE= - MAINTAINER_MODE_FALSE='#' -else - MAINTAINER_MODE_TRUE='#' - MAINTAINER_MODE_FALSE= -fi - - MAINT=$MAINTAINER_MODE_TRUE - - - - -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -$as_echo_n "checking build system type... " >&6; } -if ${ac_cv_build+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 -$as_echo_n "checking host system type... " >&6; } -if ${ac_cv_host+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -$as_echo "$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if ${ac_cv_objext+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if ${ac_cv_c_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 -$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } -if ${am_cv_prog_cc_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF - # Make sure it works both with $CC and with simple cc. - # Following AC_PROG_CC_C_O, we do the test twice because some - # compilers refuse to overwrite an existing .o file with -o, - # though they will create one. - am_cv_prog_cc_c_o=yes - for am_i in 1 2; do - if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 - ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } \ - && test -f conftest2.$ac_objext; then - : OK - else - am_cv_prog_cc_c_o=no - break - fi - done - rm -f core conftest* - unset am_i -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 -$as_echo "$am_cv_prog_cc_c_o" >&6; } -if test "$am_cv_prog_cc_c_o" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from 'make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf - -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' - am__nodep='_no' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - - -depcc="$CC" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CC_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - - -if test "$GCC" = yes -then - case "$host" in - *-*-mingw*) - case "$build" in - *-*-cygwin*) - CPPFLAGS="$CPPFLAGS -mno-cygwin" - LDFLAGS="$LDFLAGS -mno-cygwin" - ;; - esac - esac - -fi - - -case `pwd` in - *\ * | *\ *) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; -esac - - - -macro_version='2.4.2' -macro_revision='1.3337' - - - - - - - - - - - - - -ltmain="$ac_aux_dir/ltmain.sh" - -# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\(["`$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 -$as_echo_n "checking how to print strings... " >&6; } -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "" -} - -case "$ECHO" in - printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 -$as_echo "printf" >&6; } ;; - print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 -$as_echo "print -r" >&6; } ;; - *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 -$as_echo "cat" >&6; } ;; -esac - - - - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if ${ac_cv_path_SED+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for ac_i in 1 2 3 4 5 6 7; do - ac_script="$ac_script$as_nl$ac_script" - done - echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed - { ac_script=; unset ac_script;} - if test -z "$SED"; then - ac_path_SED_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_SED" || continue -# Check for GNU ac_path_SED and select it if it is found. - # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in -*GNU*) - ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo '' >> "conftest.nl" - "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_SED="$ac_path_SED" - ac_path_SED_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_SED_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_SED"; then - as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 - fi -else - ac_cv_path_SED=$SED -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -$as_echo "$ac_cv_path_SED" >&6; } - SED="$ac_cv_path_SED" - rm -f conftest.sed - -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if ${ac_cv_path_GREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$GREP"; then - ac_path_GREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_GREP" || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_GREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_GREP=$GREP -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if ${ac_cv_path_EGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_EGREP=$EGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 -$as_echo_n "checking for fgrep... " >&6; } -if ${ac_cv_path_FGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in fgrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_FGREP" || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in -*GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_FGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_FGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_FGREP=$FGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 -$as_echo "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - - - - - -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if ${lt_cv_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$LD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if ${lt_cv_prog_gnu_ld+:} false; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 -$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if ${lt_cv_path_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - if test -n "$ac_tool_prefix"; then - for ac_prog in dumpbin "link -dump" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DUMPBIN=$ac_cv_prog_DUMPBIN -if test -n "$DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 -$as_echo "$DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$DUMPBIN" && break - done -fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in dumpbin "link -dump" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DUMPBIN"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN -if test -n "$ac_ct_DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 -$as_echo "$ac_ct_DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_DUMPBIN" && break -done - - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DUMPBIN=$ac_ct_DUMPBIN - fi -fi - - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols" - ;; - *) - DUMPBIN=: - ;; - esac - fi - - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 -$as_echo_n "checking the name lister ($NM) interface... " >&6; } -if ${lt_cv_nm_interface+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 -$as_echo "$lt_cv_nm_interface" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } -fi - -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if ${lt_cv_sys_max_cmd_len+:} false; then : - $as_echo_n "(cached) " >&6 -else - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac - -fi - -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } -fi -max_cmd_len=$lt_cv_sys_max_cmd_len - - - - - - -: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 -$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 -$as_echo "$xsi_shell" >&6; } - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 -$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } -lt_shell_append=no -( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 -$as_echo "$lt_shell_append" >&6; } - - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi - - - - - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 -$as_echo_n "checking how to convert $build file names to $host format... " >&6; } -if ${lt_cv_to_host_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac - -fi - -to_host_file_cmd=$lt_cv_to_host_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 -$as_echo "$lt_cv_to_host_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 -$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } -if ${lt_cv_to_tool_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - #assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac - -fi - -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 -$as_echo "$lt_cv_to_tool_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if ${lt_cv_ld_reload_flag+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_reload_flag='-r' -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - if test "$GCC" != yes; then - reload_cmds=false - fi - ;; - darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 -$as_echo_n "checking how to recognize dependent libraries... " >&6; } -if ${lt_cv_deplibs_check_method+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[4-9]*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. - if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - 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]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[3-9]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - 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]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - - - - - - - - - - - - - - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" -fi - -test -z "$DLLTOOL" && DLLTOOL=dlltool - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 -$as_echo_n "checking how to associate runtime and link libraries... " >&6; } -if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 -$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - - - - - - - - -if test -n "$ac_tool_prefix"; then - for ac_prog in ar - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AR" && break - done -fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AR="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_AR" && break -done - - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -fi - -: ${AR=ar} -: ${AR_FLAGS=cru} - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 -$as_echo_n "checking for archiver @FILE support... " >&6; } -if ${lt_cv_ar_at_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ar_at_file=no - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -eq 0; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -ne 0; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 -$as_echo "$lt_cv_ar_at_file" >&6; } - -if test "x$lt_cv_ar_at_file" = xno; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -test -z "$STRIP" && STRIP=: - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - -test -z "$RANLIB" && RANLIB=: - - - - - - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if ${lt_cv_sys_global_symbol_pipe+:} false; then : - $as_echo_n "(cached) " >&6 -else - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[ABCDGISTW]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris*) - symcode='[BDRT]' - ;; -sco3.2v5*) - symcode='[DT]' - ;; -sysv4.2uw2*) - symcode='[DT]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[ABDT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" -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'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK '"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done - -fi - -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 -$as_echo_n "checking for sysroot... " >&6; } - -# Check whether --with-sysroot was given. -if test "${with_sysroot+set}" = set; then : - withval=$with_sysroot; -else - with_sysroot=no -fi - - -lt_sysroot= -case ${with_sysroot} in #( - yes) - if test "$GCC" = yes; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 -$as_echo "${with_sysroot}" >&6; } - as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 - ;; -esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 -$as_echo "${lt_sysroot:-no}" >&6; } - - - - - -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi - -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line '$LINENO' "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if ${lt_cv_cc_needs_belf+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. -set dummy ${ac_tool_prefix}mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$MANIFEST_TOOL"; then - ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL -if test -n "$MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 -$as_echo "$MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_MANIFEST_TOOL"; then - ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL - # Extract the first word of "mt", so it can be a program name with args. -set dummy mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_MANIFEST_TOOL"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL -if test -n "$ac_ct_MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 -$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_MANIFEST_TOOL" = x; then - MANIFEST_TOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL - fi -else - MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" -fi - -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 -$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } -if ${lt_cv_path_mainfest_tool+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&5 - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 -$as_echo "$lt_cv_path_mainfest_tool" >&6; } -if test "x$lt_cv_path_mainfest_tool" != xyes; then - MANIFEST_TOOL=: -fi - - - - - - - case $host_os in - rhapsody* | darwin*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. -set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DSYMUTIL=$ac_cv_prog_DSYMUTIL -if test -n "$DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 -$as_echo "$DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DSYMUTIL"; then - ac_ct_DSYMUTIL=$DSYMUTIL - # Extract the first word of "dsymutil", so it can be a program name with args. -set dummy dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL -if test -n "$ac_ct_DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 -$as_echo "$ac_ct_DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DSYMUTIL=$ac_ct_DSYMUTIL - fi -else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. -set dummy ${ac_tool_prefix}nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -NMEDIT=$ac_cv_prog_NMEDIT -if test -n "$NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 -$as_echo "$NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NMEDIT"; then - ac_ct_NMEDIT=$NMEDIT - # Extract the first word of "nmedit", so it can be a program name with args. -set dummy nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_NMEDIT"; then - ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_NMEDIT="nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT -if test -n "$ac_ct_NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 -$as_echo "$ac_ct_NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_NMEDIT" = x; then - NMEDIT=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - NMEDIT=$ac_ct_NMEDIT - fi -else - NMEDIT="$ac_cv_prog_NMEDIT" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. -set dummy ${ac_tool_prefix}lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$LIPO"; then - ac_cv_prog_LIPO="$LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_LIPO="${ac_tool_prefix}lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LIPO=$ac_cv_prog_LIPO -if test -n "$LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 -$as_echo "$LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_LIPO"; then - ac_ct_LIPO=$LIPO - # Extract the first word of "lipo", so it can be a program name with args. -set dummy lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_LIPO"; then - ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_LIPO="lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO -if test -n "$ac_ct_LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 -$as_echo "$ac_ct_LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_LIPO" = x; then - LIPO=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - LIPO=$ac_ct_LIPO - fi -else - LIPO="$ac_cv_prog_LIPO" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL"; then - ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL="${ac_tool_prefix}otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL=$ac_cv_prog_OTOOL -if test -n "$OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 -$as_echo "$OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL"; then - ac_ct_OTOOL=$OTOOL - # Extract the first word of "otool", so it can be a program name with args. -set dummy otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL"; then - ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL="otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL -if test -n "$ac_ct_OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 -$as_echo "$ac_ct_OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL" = x; then - OTOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL=$ac_ct_OTOOL - fi -else - OTOOL="$ac_cv_prog_OTOOL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL64"; then - ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL64=$ac_cv_prog_OTOOL64 -if test -n "$OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 -$as_echo "$OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL64"; then - ac_ct_OTOOL64=$OTOOL64 - # Extract the first word of "otool64", so it can be a program name with args. -set dummy otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL64"; then - ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL64="otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 -if test -n "$ac_ct_OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 -$as_echo "$ac_ct_OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL64" = x; then - OTOOL64=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL64=$ac_ct_OTOOL64 - fi -else - OTOOL64="$ac_cv_prog_OTOOL64" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 -$as_echo_n "checking for -single_module linker flag... " >&6; } -if ${lt_cv_apple_cc_single_mod+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&5 - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&5 - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 -$as_echo "$lt_cv_apple_cc_single_mod" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 -$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } -if ${lt_cv_ld_exported_symbols_list+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_ld_exported_symbols_list=yes -else - lt_cv_ld_exported_symbols_list=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 -$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 -$as_echo_n "checking for -force_load linker flag... " >&6; } -if ${lt_cv_ld_force_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 - echo "$AR cru libconftest.a conftest.o" >&5 - $AR cru libconftest.a conftest.o 2>&5 - echo "$RANLIB libconftest.a" >&5 - $RANLIB libconftest.a 2>&5 - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&5 - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&5 - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 -$as_echo "$lt_cv_ld_force_load" >&6; } - case $host_os in - rhapsody* | darwin1.[012]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[91]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[012]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if ${ac_cv_prog_CPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default -" -if test "x$ac_cv_header_dlfcn_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF - -fi - -done - - - - - -# Set options - - - - enable_dlopen=no - - - enable_win32_dll=no - - - # Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_shared=yes -fi - - - - - - - - - - # Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_static=yes -fi - - - - - - - - - - -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for lt_pkg in $withval; do - IFS="$lt_save_ifs" - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - pic_mode=default -fi - - -test -z "$pic_mode" && pic_mode=default - - - - - - - - # Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_fast_install=yes -fi - - - - - - - - - - - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -test -z "$LN_S" && LN_S="ln -s" - - - - - - - - - - - - - - -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if ${lt_cv_objdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - - - - -cat >>confdefs.h <<_ACEOF -#define LT_OBJDIR "$lt_cv_objdir/" -_ACEOF - - - - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` - - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - - - -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - else - MAGIC_CMD=: - fi -fi - - fi - ;; -esac - -# Use C for the default configuration in the libtool script - -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -objext=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - case $cc_basename in - nvcc*) - lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; - *) - lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; - esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi - -fi - - - - - - - lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= - - - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; - - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; - - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - lt_prog_compiler_wl='-Xlinker ' - if test -n "$lt_prog_compiler_pic"; then - lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='--shared' - lt_prog_compiler_static='--static' - ;; - nagfor*) - # NAG Fortran compiler - lt_prog_compiler_wl='-Wl,-Wl,,' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-qpic' - lt_prog_compiler_static='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' - ;; - *Sun\ F* | *Sun*Fortran*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Wl,' - ;; - *Intel*\ [CF]*Compiler*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - *Portland\ Group*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - - rdos*) - lt_prog_compiler_static='-non_shared' - ;; - - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; - - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; - - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; - - *) - lt_prog_compiler_can_build_shared=no - ;; - esac - fi - -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -if ${lt_cv_prog_compiler_pic+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic=$lt_prog_compiler_pic -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 -$as_echo "$lt_cv_prog_compiler_pic" >&6; } -lt_prog_compiler_pic=$lt_cv_prog_compiler_pic - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if ${lt_cv_prog_compiler_pic_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } - -if test x"$lt_cv_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac -else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no -fi - -fi - - - - - - - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if ${lt_cv_prog_compiler_static_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works=yes - fi - else - lt_cv_prog_compiler_static_works=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 -$as_echo "$lt_cv_prog_compiler_static_works" >&6; } - -if test x"$lt_cv_prog_compiler_static_works" = xyes; then - : -else - lt_prog_compiler_static= -fi - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag= - always_export_symbols=no - archive_cmds= - archive_expsym_cmds= - compiler_needs_object=no - enable_shared_with_static_runtimes=no - export_dynamic_flag_spec= - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - hardcode_automatic=no - hardcode_direct=no - hardcode_direct_absolute=no - hardcode_libdir_flag_spec= - hardcode_libdir_separator= - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - inherit_rpath=no - link_all_deplibs=unknown - module_cmds= - module_expsym_cmds= - old_archive_from_new_cmds= - old_archive_from_expsyms_cmds= - thread_safe_flag_spec= - whole_archive_flag_spec= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - linux* | k*bsd*-gnu | gnu*) - link_all_deplibs=no - ;; - esac - - ld_shlibs=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; - *\ \(GNU\ Binutils\)\ [3-9]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test "$lt_use_gnu_ld_interface" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[3-9]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - export_dynamic_flag_spec='${wl}--export-all-symbols' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - 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' - exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs=no - fi - ;; - - haiku*) - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - link_all_deplibs=yes - ;; - - interix[3-9]*) - hardcode_direct=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - 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' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - 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' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - 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' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - whole_archive_flag_spec= - tmp_sharedflag='--shared' ;; - xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - 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' - compiler_needs_object=yes - ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - 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' - compiler_needs_object=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - ld_shlibs=no - fi - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - 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' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - - aix[4-9]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - 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' - else - 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' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds='' - hardcode_direct=yes - hardcode_direct_absolute=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - file_list_spec='${wl}-f,' - - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - link_all_deplibs=no - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - export_dynamic_flag_spec='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - 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" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - 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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec='$convenience' - fi - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - 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' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl*) - # Native MSVC - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - always_export_symbols=yes - file_list_spec='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, )='true' - enable_shared_with_static_runtimes=yes - exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' - # Don't use ranlib - old_postinstall_cmds='chmod 644 $oldlib' - postlink_cmds='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC wrapper - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' - enable_shared_with_static_runtimes=yes - ;; - esac - ;; - - darwin* | rhapsody*) - - - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - 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\"`' - - else - whole_archive_flag_spec='' - fi - link_all_deplibs=yes - allow_undefined_flag="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - 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}" - 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}" - - else - ld_shlibs=no - fi - - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9*) - if test "$GCC" = yes; then - 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' - else - 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' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 -$as_echo_n "checking if $CC understands -b... " >&6; } -if ${lt_cv_prog_compiler__b+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler__b=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -b" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler__b=yes - fi - else - lt_cv_prog_compiler__b=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 -$as_echo "$lt_cv_prog_compiler__b" >&6; } - -if test x"$lt_cv_prog_compiler__b" = xyes; then - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' -else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' -fi - - ;; - esac - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - *) - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - 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' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 -$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } -if ${lt_cv_irix_exported_symbol+:} false; then : - $as_echo_n "(cached) " >&6 -else - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int foo (void) { return 0; } -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_irix_exported_symbol=yes -else - lt_cv_irix_exported_symbol=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 -$as_echo "$lt_cv_irix_exported_symbol" >&6; } - if test "$lt_cv_irix_exported_symbol" = yes; then - 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' - fi - else - 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' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - inherit_rpath=yes - link_all_deplibs=yes - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - - *nto* | *qnx*) - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - hardcode_direct=yes - hardcode_shlibpath_var=no - hardcode_direct_absolute=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - else - ld_shlibs=no - fi - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - 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' - old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - 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~ - $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' - - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - archive_cmds_need_lc='no' - hardcode_libdir_separator=: - ;; - - solaris*) - no_undefined_flag=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' - fi - ;; - esac - link_all_deplibs=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag='${wl}-z,text' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag='${wl}-z,text' - allow_undefined_flag='${wl}-z,nodefs' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-R,$libdir' - hardcode_libdir_separator=':' - link_all_deplibs=yes - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - *) - ld_shlibs=no - ;; - esac - - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - export_dynamic_flag_spec='${wl}-Blargedynsym' - ;; - esac - fi - fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no - -with_gnu_ld=$with_gnu_ld - - - - - - - - - - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } -if ${lt_cv_archive_cmds_need_lc+:} false; then : - $as_echo_n "(cached) " >&6 -else - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - pic_flag=$lt_prog_compiler_pic - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc=no - else - lt_cv_archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 -$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } - archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } - -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[lt_foo]++; } - if (lt_freq[lt_foo] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([A-Za-z]:\),\1,g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if ${lt_cv_shlibpath_overrides_runpath+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || - test -n "$runpath_var" || - test "X$hardcode_automatic" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } - -if test "$hardcode_action" = relink || - test "$inherit_rpath" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - -fi - - ;; - - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if ${ac_cv_lib_dld_shl_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes -else - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if ${ac_cv_lib_svld_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes -else - ac_cv_lib_svld_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if ${ac_cv_lib_dld_dld_link+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); -int -main () -{ -return dld_link (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes -else - ac_cv_lib_dld_dld_link=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = xyes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" -fi - - -fi - - -fi - - -fi - - -fi - - -fi - - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self_static+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi - - - - - - - - - - - - - - - - - -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac -fi - - - - - - - - - - - - - # Report which library types will actually be built - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[4-9]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } - - - - -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" - - - - - - - - - - - - - - - - ac_config_commands="$ac_config_commands libtool" - - - - -# Only expand once: - - - - - - -arch="" -debug="" -optimize="" -profile="" - -set -- $CFLAGS -CFLAGS="" - -if test "$GCC" = yes -then - CFLAGS="-Wall" -fi - -while test $# -gt 0 -do - case "$1" in - -Wall) - if test "$GCC" = yes - then - : - else - CFLAGS="$CFLAGS $1" - fi - shift - ;; - -g) - debug="-g" - shift - ;; - -mno-cygwin) - shift - ;; - -m*) - arch="$arch $1" - shift - ;; - -fomit-frame-pointer) - shift - ;; - -O*|-f*) - optimize="$1" - shift - ;; - *) - CFLAGS="$CFLAGS $1" - shift - ;; - esac -done - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - -for ac_header in assert.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" -if test "x$ac_cv_header_zlib_h" = xyes; then : - -else - - as_fn_error $? "zlib.h was not found -*** You must first install zlib (libz) before you can build this package. -*** If zlib is already installed, you may need to use the CPPFLAGS -*** environment variable to specify its installed location, e.g. -I." "$LINENO" 5 - -fi - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if ${ac_cv_c_const+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - -#ifndef __cplusplus - /* Ultrix mips cc rejects this sort of thing. */ - typedef int charset[2]; - const charset cs = { 0, 0 }; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this sort of thing. */ - char tx; - char *t = &tx; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; } bx; - struct s *b = &bx; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes -else - ac_cv_c_const=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -$as_echo "#define const /**/" >>confdefs.h - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if ${ac_cv_c_inline+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif - -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_inline=$ac_kw -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } - -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF - ;; -esac - - - -for ac_func in ftruncate -do : - ac_fn_c_check_func "$LINENO" "ftruncate" "ac_cv_func_ftruncate" -if test "x$ac_cv_func_ftruncate" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_FTRUNCATE 1 -_ACEOF - -fi -done - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress2 in -lz" >&5 -$as_echo_n "checking for compress2 in -lz... " >&6; } -if ${ac_cv_lib_z_compress2+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lz $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char compress2 (); -int -main () -{ -return compress2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_z_compress2=yes -else - ac_cv_lib_z_compress2=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress2" >&5 -$as_echo "$ac_cv_lib_z_compress2" >&6; } -if test "x$ac_cv_lib_z_compress2" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBZ 1 -_ACEOF - - LIBS="-lz $LIBS" - -else - - as_fn_error $? "libz was not found -*** You must first install zlib (libz) before you can build this package. -*** If zlib is already installed, you may need to use the LDFLAGS -*** environment variable to specify its installed location, e.g. -L." "$LINENO" 5 - -fi - - - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable profiling" >&5 -$as_echo_n "checking whether to enable profiling... " >&6; } -# Check whether --enable-profiling was given. -if test "${enable_profiling+set}" = set; then : - enableval=$enable_profiling; - case "$enableval" in - yes) profile="-pg" ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_profiling-no}" >&5 -$as_echo "${enable_profiling-no}" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable debugging" >&5 -$as_echo_n "checking whether to enable debugging... " >&6; } -# Check whether --enable-debugging was given. -if test "${enable_debugging+set}" = set; then : - enableval=$enable_debugging; - case "$enableval" in - yes) - -$as_echo "#define DEBUG 1" >>confdefs.h - - optimize="" - ;; - no) - if test -n "$profile" - then - as_fn_error $? "--enable-profiling and --disable-debugging are incompatible" "$LINENO" 5 - fi - - -$as_echo "#define NDEBUG 1" >>confdefs.h - - debug="" - if test "$GCC" = yes - then - optimize="$optimize -fomit-frame-pointer" - fi - ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_debugging-default}" >&5 -$as_echo "${enable_debugging-default}" >&6; } - if test ${enable_debugging-default} = yes; then - DEBUG_TRUE= - DEBUG_FALSE='#' -else - DEBUG_TRUE='#' - DEBUG_FALSE= -fi - - - -test -n "$arch" && CFLAGS="$CFLAGS $arch" -test -n "$debug" && CFLAGS="$CFLAGS $debug" -test -n "$optimize" && CFLAGS="$CFLAGS $optimize" -test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile" - - -ac_config_files="$ac_config_files Makefile msvc++/Makefile libid3tag.list" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -DEFS=-DHAVE_CONFIG_H - -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 -$as_echo_n "checking that generated files are newer than configure... " >&6; } - if test -n "$am_sleep_pid"; then - # Hide warnings about reused PIDs. - wait $am_sleep_pid 2>/dev/null - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 -$as_echo "done" >&6; } - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi - -if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then - as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error $? "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${DEBUG_TRUE}" && test -z "${DEBUG_FALSE}"; then - as_fn_error $? "conditional \"DEBUG\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi - -: "${CONFIG_STATUS=./config.status}" -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by ID3 Tag $as_me 0.15.1b, which was -generated by GNU Autoconf 2.69. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE - -Configuration files: -$config_files - -Configuration headers: -$config_headers - -Configuration commands: -$config_commands - -Report bugs to ." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -ID3 Tag config.status 0.15.1b -configured by $0, generated by GNU Autoconf 2.69, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2012 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=?*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - --*=) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg= - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - '') as_fn_error $? "missing file argument" ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error $? "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error $? "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" - - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' -macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' -enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' -enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' -pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' -enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' -SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' -ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' -PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' -host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' -host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' -host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' -build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' -build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' -build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' -SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' -Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' -GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' -EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' -FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' -LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' -NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' -LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' -max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' -ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' -exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' -lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' -lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' -lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' -lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' -lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' -reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' -reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' -OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' -deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' -file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' -file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' -want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' -DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' -sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' -AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' -AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' -archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' -STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' -RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' -old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' -old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' -lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' -CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' -CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' -compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' -GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' -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"`' -nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' -lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' -objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' -MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' -need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' -MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' -DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' -NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' -LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' -OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' -OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' -libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' -shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' -extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' -compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' -module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' -with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' -no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' -hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' -hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' -inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' -link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' -always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' -exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' -include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' -prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' -postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' -file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' -variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' -need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' -need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' -version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' -runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' -libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' -library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' -soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' -install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' -postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' -postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' -finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' -hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' -sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' -sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' -hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' -enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' -old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' -striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' - -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in SHELL \ -ECHO \ -PATH_SEPARATOR \ -SED \ -GREP \ -EGREP \ -FGREP \ -LD \ -NM \ -LN_S \ -lt_SP2NL \ -lt_NL2SP \ -reload_flag \ -OBJDUMP \ -deplibs_check_method \ -file_magic_cmd \ -file_magic_glob \ -want_nocaseglob \ -DLLTOOL \ -sharedlib_from_linklib_cmd \ -AR \ -AR_FLAGS \ -archiver_list_spec \ -STRIP \ -RANLIB \ -CC \ -CFLAGS \ -compiler \ -lt_cv_sys_global_symbol_pipe \ -lt_cv_sys_global_symbol_to_cdecl \ -lt_cv_sys_global_symbol_to_c_name_address \ -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ -nm_file_list_spec \ -lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_pic \ -lt_prog_compiler_wl \ -lt_prog_compiler_static \ -lt_cv_prog_compiler_c_o \ -need_locks \ -MANIFEST_TOOL \ -DSYMUTIL \ -NMEDIT \ -LIPO \ -OTOOL \ -OTOOL64 \ -shrext_cmds \ -export_dynamic_flag_spec \ -whole_archive_flag_spec \ -compiler_needs_object \ -with_gnu_ld \ -allow_undefined_flag \ -no_undefined_flag \ -hardcode_libdir_flag_spec \ -hardcode_libdir_separator \ -exclude_expsyms \ -include_expsyms \ -file_list_spec \ -variables_saved_for_relink \ -libname_spec \ -library_names_spec \ -soname_spec \ -install_override_mode \ -finish_eval \ -old_striplib \ -striplib; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in reload_cmds \ -old_postinstall_cmds \ -old_postuninstall_cmds \ -old_archive_cmds \ -extract_expsyms_cmds \ -old_archive_from_new_cmds \ -old_archive_from_expsyms_cmds \ -archive_cmds \ -archive_expsym_cmds \ -module_cmds \ -module_expsym_cmds \ -export_symbols_cmds \ -prelink_cmds \ -postlink_cmds \ -postinstall_cmds \ -postuninstall_cmds \ -finish_cmds \ -sys_lib_search_path_spec \ -sys_lib_dlsearch_path_spec; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -ac_aux_dir='$ac_aux_dir' -xsi_shell='$xsi_shell' -lt_shell_append='$lt_shell_append' - -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - - - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile' - - - - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "msvc++/Makefile") CONFIG_FILES="$CONFIG_FILES msvc++/Makefile" ;; - "libid3tag.list") CONFIG_FILES="$CONFIG_FILES libid3tag.list" ;; - - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= ac_tmp= - trap 'exit_status=$? - : "${ac_tmp:=$tmp}" - { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 -ac_tmp=$tmp - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$ac_tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ - || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove sole $(srcdir), -# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ -h -s/// -s/^/:/ -s/[ ]*$/:/ -s/:\$(srcdir):/:/g -s/:\${srcdir}:/:/g -s/:@srcdir@:/:/g -s/^:*// -s/:*$// -x -s/\(=[ ]*\).*/\1/ -G -s/\n// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$ac_tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF - -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. - -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_tt=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_tt"; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. - -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" - - -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$ac_tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$ac_tmp/stdin" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ - >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ - "$ac_tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&2;} - - rm -f "$ac_tmp/stdin" - case $ac_file in - -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; - *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; - esac \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" - } >"$ac_tmp/config.h" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$ac_tmp/config.h" "$ac_file" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error $? "could not create -" "$LINENO" 5 - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Older Autoconf quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named 'Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running 'make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "$am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} - ;; - "libtool":C) - - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - - -# The names of the tagged configurations supported by this script. -available_tags="" - -# ### BEGIN LIBTOOL CONFIG - -# Which release of libtool.m4 was used? -macro_version=$macro_version -macro_revision=$macro_revision - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# What type of objects to build. -pic_mode=$pic_mode - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# An echo program that protects backslashes. -ECHO=$lt_ECHO - -# The PATH separator for the build system. -PATH_SEPARATOR=$lt_PATH_SEPARATOR - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="\$SED -e 1s/^X//" - -# A grep program that handles long lines. -GREP=$lt_GREP - -# An ERE matcher. -EGREP=$lt_EGREP - -# A literal string matcher. -FGREP=$lt_FGREP - -# A BSD- or MS-compatible name lister. -NM=$lt_NM - -# Whether we need soft or hard links. -LN_S=$lt_LN_S - -# What is the maximum length of a command? -max_cmd_len=$max_cmd_len - -# Object file suffix (normally "o"). -objext=$ac_objext - -# Executable file suffix (normally ""). -exeext=$exeext - -# whether the shell understands "unset". -lt_unset=$lt_unset - -# turn spaces into newlines. -SP2NL=$lt_lt_SP2NL - -# turn newlines into spaces. -NL2SP=$lt_lt_NL2SP - -# convert \$build file names to \$host format. -to_host_file_cmd=$lt_cv_to_host_file_cmd - -# convert \$build files to toolchain format. -to_tool_file_cmd=$lt_cv_to_tool_file_cmd - -# An object symbol dumper. -OBJDUMP=$lt_OBJDUMP - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method = "file_magic". -file_magic_cmd=$lt_file_magic_cmd - -# How to find potential files when deplibs_check_method = "file_magic". -file_magic_glob=$lt_file_magic_glob - -# Find potential files using nocaseglob when deplibs_check_method = "file_magic". -want_nocaseglob=$lt_want_nocaseglob - -# DLL creation program. -DLLTOOL=$lt_DLLTOOL - -# Command to associate shared and link libraries. -sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd - -# The archiver. -AR=$lt_AR - -# Flags to create an archive. -AR_FLAGS=$lt_AR_FLAGS - -# How to feed a file listing to the archiver. -archiver_list_spec=$lt_archiver_list_spec - -# A symbol stripping program. -STRIP=$lt_STRIP - -# Commands used to install an old-style archive. -RANLIB=$lt_RANLIB -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Whether to use a lock for old archive extraction. -lock_old_archive_extraction=$lock_old_archive_extraction - -# A C compiler. -LTCC=$lt_CC - -# LTCC compiler flags. -LTCFLAGS=$lt_CFLAGS - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration. -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair. -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# Transform the output of nm in a C name address pair when lib prefix is needed. -global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix - -# Specify filename containing input files for \$NM. -nm_file_list_spec=$lt_nm_file_list_spec - -# The root where to search for dependent libraries,and in which our libraries should be installed. -lt_sysroot=$lt_sysroot - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# Used to examine libraries when file_magic_cmd begins with "file". -MAGIC_CMD=$MAGIC_CMD - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Manifest tool. -MANIFEST_TOOL=$lt_MANIFEST_TOOL - -# Tool to manipulate archived DWARF debug symbol files on Mac OS X. -DSYMUTIL=$lt_DSYMUTIL - -# Tool to change global to local symbols on Mac OS X. -NMEDIT=$lt_NMEDIT - -# Tool to manipulate fat objects and archives on Mac OS X. -LIPO=$lt_LIPO - -# ldd/readelf like tool for Mach-O binaries on Mac OS X. -OTOOL=$lt_OTOOL - -# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. -OTOOL64=$lt_OTOOL64 - -# Old archive suffix (normally "a"). -libext=$libext - -# Shared library suffix (normally ".so"). -shrext_cmds=$lt_shrext_cmds - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at link time. -variables_saved_for_relink=$lt_variables_saved_for_relink - -# Do we need the "lib" prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Library versioning type. -version_type=$version_type - -# Shared library runtime path variable. -runpath_var=$runpath_var - -# Shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Permission mode override for installation of shared libraries. -install_override_mode=$lt_install_override_mode - -# Command to use after installation of a shared archive. -postinstall_cmds=$lt_postinstall_cmds - -# Command to use after uninstallation of a shared archive. -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# As "finish_cmds", except a single script fragment to be evaled but -# not shown. -finish_eval=$lt_finish_eval - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Compile-time system search path for libraries. -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries. -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - - -# The linker used to build libraries. -LD=$lt_LD - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds - -# A language specific compiler. -CC=$lt_compiler - -# Is the compiler the GNU compiler? -with_gcc=$GCC - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \${shlibpath_var} if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action - -# ### END LIBTOOL CONFIG - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - -ltmain="$ac_aux_dir/ltmain.sh" - - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - if test x"$xsi_shell" = xyes; then - sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ -func_dirname ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_basename ()$/,/^} # func_basename /c\ -func_basename ()\ -{\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ -func_dirname_and_basename ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ -func_stripname ()\ -{\ -\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ -\ # positional parameters, so assign one to ordinary parameter first.\ -\ func_stripname_result=${3}\ -\ func_stripname_result=${func_stripname_result#"${1}"}\ -\ func_stripname_result=${func_stripname_result%"${2}"}\ -} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ -func_split_long_opt ()\ -{\ -\ func_split_long_opt_name=${1%%=*}\ -\ func_split_long_opt_arg=${1#*=}\ -} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ -func_split_short_opt ()\ -{\ -\ func_split_short_opt_arg=${1#??}\ -\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ -} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ -func_lo2o ()\ -{\ -\ case ${1} in\ -\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ -\ *) func_lo2o_result=${1} ;;\ -\ esac\ -} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_xform ()$/,/^} # func_xform /c\ -func_xform ()\ -{\ - func_xform_result=${1%.*}.lo\ -} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_arith ()$/,/^} # func_arith /c\ -func_arith ()\ -{\ - func_arith_result=$(( $* ))\ -} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_len ()$/,/^} # func_len /c\ -func_len ()\ -{\ - func_len_result=${#1}\ -} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - -fi - -if test x"$lt_shell_append" = xyes; then - sed -e '/^func_append ()$/,/^} # func_append /c\ -func_append ()\ -{\ - eval "${1}+=\\${2}"\ -} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ -func_append_quoted ()\ -{\ -\ func_quote_for_eval "${2}"\ -\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ -} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 -$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} -fi - - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit 1 -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - diff --git a/lib-src/libid3tag/configure.ac b/lib-src/libid3tag/configure.ac deleted file mode 100644 index 82011cdbd..000000000 --- a/lib-src/libid3tag/configure.ac +++ /dev/null @@ -1,209 +0,0 @@ -dnl -*- m4 -*- -dnl -dnl libid3tag - ID3 tag manipulation library -dnl Copyright (C) 2000-2004 Underbit Technologies, Inc. -dnl -dnl This program is free software; you can redistribute it and/or modify -dnl it under the terms of the GNU General Public License as published by -dnl the Free Software Foundation; either version 2 of the License, or -dnl (at your option) any later version. -dnl -dnl This program is distributed in the hope that it will be useful, -dnl but WITHOUT ANY WARRANTY; without even the implied warranty of -dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -dnl GNU General Public License for more details. -dnl -dnl You should have received a copy of the GNU General Public License -dnl along with this program; if not, write to the Free Software -dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -dnl -AC_REVISION([$Id: configure.ac,v 1.5 2009-01-23 23:39:44 richardash1981 Exp $])dnl - -dnl Process this file with autoconf to produce a configure script. - -AC_INIT([ID3 Tag], [0.15.1b], [support@underbit.com], [libid3tag]) -AC_PREREQ(2.53) - -AC_CONFIG_SRCDIR([id3tag.h]) - -AC_CONFIG_MACRO_DIR([m4]) - -AM_INIT_AUTOMAKE([-Wall foreign]) - -AM_CONFIG_HEADER([config.h]) - -AM_MAINTAINER_MODE - -dnl System type. - -AC_CANONICAL_HOST - -dnl Checks for programs. - -AC_PROG_CC - -if test "$GCC" = yes -then - case "$host" in - *-*-mingw*) - case "$build" in - *-*-cygwin*) - CPPFLAGS="$CPPFLAGS -mno-cygwin" - LDFLAGS="$LDFLAGS -mno-cygwin" - ;; - esac - esac - -dnl case "$host" in -dnl *-*-cygwin* | *-*-mingw*) -dnl LDFLAGS="$LDFLAGS -no-undefined -mdll" -dnl ;; -dnl esac -fi - -dnl Support for libtool. - -dnl AC_DISABLE_SHARED -dnl AC_LIBTOOL_WIN32_DLL -AC_PROG_LIBTOOL - -AC_SUBST(LIBTOOL_DEPS) - -dnl Compiler options. - -arch="" -debug="" -optimize="" -profile="" - -set -- $CFLAGS -CFLAGS="" - -if test "$GCC" = yes -then - CFLAGS="-Wall" -fi - -while test $# -gt 0 -do - case "$1" in - -Wall) - if test "$GCC" = yes - then - : - else - CFLAGS="$CFLAGS $1" - fi - shift - ;; - -g) - debug="-g" - shift - ;; - -mno-cygwin) - shift - ;; - -m*) - arch="$arch $1" - shift - ;; - -fomit-frame-pointer) - shift - ;; - -O*|-f*) - optimize="$1" - shift - ;; - *) - CFLAGS="$CFLAGS $1" - shift - ;; - esac -done - -dnl Checks for header files. - -AC_HEADER_STDC -AC_CHECK_HEADERS(assert.h unistd.h) - -AC_CHECK_HEADER(zlib.h, [], [ - AC_MSG_ERROR([zlib.h was not found -*** You must first install zlib (libz) before you can build this package. -*** If zlib is already installed, you may need to use the CPPFLAGS -*** environment variable to specify its installed location, e.g. -I.]) -]) - -dnl Checks for typedefs, structures, and compiler characteristics. - -AC_C_CONST -AC_C_INLINE - -dnl Checks for library functions. - -AC_CHECK_FUNCS(ftruncate) - -AC_CHECK_LIB(z, compress2, [], [ - AC_MSG_ERROR([libz was not found -*** You must first install zlib (libz) before you can build this package. -*** If zlib is already installed, you may need to use the LDFLAGS -*** environment variable to specify its installed location, e.g. -L.]) -]) - -dnl handle --enable and --disable options - -AC_CACHE_SAVE - -AC_MSG_CHECKING([whether to enable profiling]) -AC_ARG_ENABLE(profiling, AC_HELP_STRING([--enable-profiling], - [generate profiling code]), -[ - case "$enableval" in - yes) profile="-pg" ;; - esac -]) -AC_MSG_RESULT(${enable_profiling-no}) - -AC_MSG_CHECKING([whether to enable debugging]) -AC_ARG_ENABLE(debugging, AC_HELP_STRING([--enable-debugging], - [enable diagnostic debugging support]) -AC_HELP_STRING([--disable-debugging], - [do not enable debugging and use more optimization]), -[ - case "$enableval" in - yes) - AC_DEFINE(DEBUG, 1, - [Define to enable diagnostic debugging support.]) - optimize="" - ;; - no) - if test -n "$profile" - then - AC_MSG_ERROR(--enable-profiling and --disable-debugging are incompatible) - fi - - AC_DEFINE(NDEBUG, 1, - [Define to disable debugging assertions.]) - debug="" - if test "$GCC" = yes - then - optimize="$optimize -fomit-frame-pointer" - fi - ;; - esac -]) -AC_MSG_RESULT(${enable_debugging-default}) -AM_CONDITIONAL(DEBUG, test ${enable_debugging-default} = yes) - -dnl Create output files. - -test -n "$arch" && CFLAGS="$CFLAGS $arch" -test -n "$debug" && CFLAGS="$CFLAGS $debug" -test -n "$optimize" && CFLAGS="$CFLAGS $optimize" -test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile" - -dnl LTLIBOBJS=`echo "$LIBOBJS" | sed -e 's/\.o/.lo/g'` -dnl AC_SUBST(LTLIBOBJS) - -AC_CONFIG_FILES([Makefile msvc++/Makefile \ - libid3tag.list]) -AC_OUTPUT diff --git a/lib-src/libid3tag/crc.c b/lib-src/libid3tag/crc.c deleted file mode 100644 index 0ca884ef4..000000000 --- a/lib-src/libid3tag/crc.c +++ /dev/null @@ -1,137 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: crc.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "id3tag.h" -# include "crc.h" - -static -unsigned long const crc_table[256] = { - 0x00000000L, 0x77073096L, 0xee0e612cL, 0x990951baL, - 0x076dc419L, 0x706af48fL, 0xe963a535L, 0x9e6495a3L, - 0x0edb8832L, 0x79dcb8a4L, 0xe0d5e91eL, 0x97d2d988L, - 0x09b64c2bL, 0x7eb17cbdL, 0xe7b82d07L, 0x90bf1d91L, - 0x1db71064L, 0x6ab020f2L, 0xf3b97148L, 0x84be41deL, - 0x1adad47dL, 0x6ddde4ebL, 0xf4d4b551L, 0x83d385c7L, - 0x136c9856L, 0x646ba8c0L, 0xfd62f97aL, 0x8a65c9ecL, - 0x14015c4fL, 0x63066cd9L, 0xfa0f3d63L, 0x8d080df5L, - - 0x3b6e20c8L, 0x4c69105eL, 0xd56041e4L, 0xa2677172L, - 0x3c03e4d1L, 0x4b04d447L, 0xd20d85fdL, 0xa50ab56bL, - 0x35b5a8faL, 0x42b2986cL, 0xdbbbc9d6L, 0xacbcf940L, - 0x32d86ce3L, 0x45df5c75L, 0xdcd60dcfL, 0xabd13d59L, - 0x26d930acL, 0x51de003aL, 0xc8d75180L, 0xbfd06116L, - 0x21b4f4b5L, 0x56b3c423L, 0xcfba9599L, 0xb8bda50fL, - 0x2802b89eL, 0x5f058808L, 0xc60cd9b2L, 0xb10be924L, - 0x2f6f7c87L, 0x58684c11L, 0xc1611dabL, 0xb6662d3dL, - - 0x76dc4190L, 0x01db7106L, 0x98d220bcL, 0xefd5102aL, - 0x71b18589L, 0x06b6b51fL, 0x9fbfe4a5L, 0xe8b8d433L, - 0x7807c9a2L, 0x0f00f934L, 0x9609a88eL, 0xe10e9818L, - 0x7f6a0dbbL, 0x086d3d2dL, 0x91646c97L, 0xe6635c01L, - 0x6b6b51f4L, 0x1c6c6162L, 0x856530d8L, 0xf262004eL, - 0x6c0695edL, 0x1b01a57bL, 0x8208f4c1L, 0xf50fc457L, - 0x65b0d9c6L, 0x12b7e950L, 0x8bbeb8eaL, 0xfcb9887cL, - 0x62dd1ddfL, 0x15da2d49L, 0x8cd37cf3L, 0xfbd44c65L, - - 0x4db26158L, 0x3ab551ceL, 0xa3bc0074L, 0xd4bb30e2L, - 0x4adfa541L, 0x3dd895d7L, 0xa4d1c46dL, 0xd3d6f4fbL, - 0x4369e96aL, 0x346ed9fcL, 0xad678846L, 0xda60b8d0L, - 0x44042d73L, 0x33031de5L, 0xaa0a4c5fL, 0xdd0d7cc9L, - 0x5005713cL, 0x270241aaL, 0xbe0b1010L, 0xc90c2086L, - 0x5768b525L, 0x206f85b3L, 0xb966d409L, 0xce61e49fL, - 0x5edef90eL, 0x29d9c998L, 0xb0d09822L, 0xc7d7a8b4L, - 0x59b33d17L, 0x2eb40d81L, 0xb7bd5c3bL, 0xc0ba6cadL, - - 0xedb88320L, 0x9abfb3b6L, 0x03b6e20cL, 0x74b1d29aL, - 0xead54739L, 0x9dd277afL, 0x04db2615L, 0x73dc1683L, - 0xe3630b12L, 0x94643b84L, 0x0d6d6a3eL, 0x7a6a5aa8L, - 0xe40ecf0bL, 0x9309ff9dL, 0x0a00ae27L, 0x7d079eb1L, - 0xf00f9344L, 0x8708a3d2L, 0x1e01f268L, 0x6906c2feL, - 0xf762575dL, 0x806567cbL, 0x196c3671L, 0x6e6b06e7L, - 0xfed41b76L, 0x89d32be0L, 0x10da7a5aL, 0x67dd4accL, - 0xf9b9df6fL, 0x8ebeeff9L, 0x17b7be43L, 0x60b08ed5L, - - 0xd6d6a3e8L, 0xa1d1937eL, 0x38d8c2c4L, 0x4fdff252L, - 0xd1bb67f1L, 0xa6bc5767L, 0x3fb506ddL, 0x48b2364bL, - 0xd80d2bdaL, 0xaf0a1b4cL, 0x36034af6L, 0x41047a60L, - 0xdf60efc3L, 0xa867df55L, 0x316e8eefL, 0x4669be79L, - 0xcb61b38cL, 0xbc66831aL, 0x256fd2a0L, 0x5268e236L, - 0xcc0c7795L, 0xbb0b4703L, 0x220216b9L, 0x5505262fL, - 0xc5ba3bbeL, 0xb2bd0b28L, 0x2bb45a92L, 0x5cb36a04L, - 0xc2d7ffa7L, 0xb5d0cf31L, 0x2cd99e8bL, 0x5bdeae1dL, - - 0x9b64c2b0L, 0xec63f226L, 0x756aa39cL, 0x026d930aL, - 0x9c0906a9L, 0xeb0e363fL, 0x72076785L, 0x05005713L, - 0x95bf4a82L, 0xe2b87a14L, 0x7bb12baeL, 0x0cb61b38L, - 0x92d28e9bL, 0xe5d5be0dL, 0x7cdcefb7L, 0x0bdbdf21L, - 0x86d3d2d4L, 0xf1d4e242L, 0x68ddb3f8L, 0x1fda836eL, - 0x81be16cdL, 0xf6b9265bL, 0x6fb077e1L, 0x18b74777L, - 0x88085ae6L, 0xff0f6a70L, 0x66063bcaL, 0x11010b5cL, - 0x8f659effL, 0xf862ae69L, 0x616bffd3L, 0x166ccf45L, - - 0xa00ae278L, 0xd70dd2eeL, 0x4e048354L, 0x3903b3c2L, - 0xa7672661L, 0xd06016f7L, 0x4969474dL, 0x3e6e77dbL, - 0xaed16a4aL, 0xd9d65adcL, 0x40df0b66L, 0x37d83bf0L, - 0xa9bcae53L, 0xdebb9ec5L, 0x47b2cf7fL, 0x30b5ffe9L, - 0xbdbdf21cL, 0xcabac28aL, 0x53b39330L, 0x24b4a3a6L, - 0xbad03605L, 0xcdd70693L, 0x54de5729L, 0x23d967bfL, - 0xb3667a2eL, 0xc4614ab8L, 0x5d681b02L, 0x2a6f2b94L, - 0xb40bbe37L, 0xc30c8ea1L, 0x5a05df1bL, 0x2d02ef8dL -}; - -/* - * NAME: crc->compute() - * DESCRIPTION: calculate CRC-32 value (ISO 3309) - */ -unsigned long id3_crc_compute(id3_byte_t const *data, id3_length_t length) -{ - register unsigned long crc; - - for (crc = 0xffffffffL; length >= 8; length -= 8) { - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - } - - switch (length) { - case 7: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 6: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 5: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 4: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 3: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 2: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 1: crc = crc_table[(crc ^ *data++) & 0xff] ^ (crc >> 8); - case 0: break; - } - - return crc ^ 0xffffffffL; -} diff --git a/lib-src/libid3tag/crc.h b/lib-src/libid3tag/crc.h deleted file mode 100644 index 201d70e2a..000000000 --- a/lib-src/libid3tag/crc.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: crc.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_CRC_H -# define LIBID3TAG_CRC_H - -# include "id3tag.h" - -unsigned long id3_crc_compute(id3_byte_t const *, id3_length_t); - -# endif diff --git a/lib-src/libid3tag/debug.c b/lib-src/libid3tag/debug.c deleted file mode 100644 index 808119d7e..000000000 --- a/lib-src/libid3tag/debug.c +++ /dev/null @@ -1,222 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: debug.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# undef malloc -# undef calloc -# undef realloc -# undef free - -# include -# include -# include - -# include "debug.h" - -# if defined(DEBUG) - -# define DEBUG_MAGIC 0xdeadbeefL - -struct debug { - char const *file; - unsigned int line; - size_t size; - struct debug *next; - struct debug *prev; - long int magic; -}; - -static struct debug *allocated; -static int registered; - -static -void check(void) -{ - struct debug *debug; - - for (debug = allocated; debug; debug = debug->next) { - if (debug->magic != DEBUG_MAGIC) { - fprintf(stderr, "memory corruption\n"); - break; - } - - fprintf(stderr, "%s:%u: leaked %lu bytes\n", - debug->file, debug->line, debug->size); - } -} - -void *id3_debug_malloc(size_t size, char const *file, unsigned int line) -{ - struct debug *debug; - - if (!registered) { - atexit(check); - registered = 1; - } - - if (size == 0) - fprintf(stderr, "%s:%u: malloc(0)\n", file, line); - - debug = malloc(sizeof(*debug) + size); - if (debug == 0) { - fprintf(stderr, "%s:%u: malloc(%lu) failed\n", file, line, size); - return 0; - } - - debug->magic = DEBUG_MAGIC; - - debug->file = file; - debug->line = line; - debug->size = size; - - debug->next = allocated; - debug->prev = 0; - - if (allocated) - allocated->prev = debug; - - allocated = debug; - - return ++debug; -} - -void *id3_debug_calloc(size_t nmemb, size_t size, - char const *file, unsigned int line) -{ - void *ptr; - - ptr = id3_debug_malloc(nmemb * size, file, line); - if (ptr) - memset(ptr, 0, nmemb * size); - - return ptr; -} - -void *id3_debug_realloc(void *ptr, size_t size, - char const *file, unsigned int line) -{ - struct debug *debug, *new; - - if (size == 0) { - id3_debug_free(ptr, file, line); - return 0; - } - - if (ptr == 0) - return id3_debug_malloc(size, file, line); - - debug = ptr; - --debug; - - if (debug->magic != DEBUG_MAGIC) { - fprintf(stderr, "%s:%u: realloc(%p, %lu) memory not allocated\n", - file, line, ptr, size); - return 0; - } - - new = realloc(debug, sizeof(*debug) + size); - if (new == 0) { - fprintf(stderr, "%s:%u: realloc(%p, %lu) failed\n", file, line, ptr, size); - return 0; - } - - if (allocated == debug) - allocated = new; - - debug = new; - - debug->file = file; - debug->line = line; - debug->size = size; - - if (debug->next) - debug->next->prev = debug; - if (debug->prev) - debug->prev->next = debug; - - return ++debug; -} - -void id3_debug_free(void *ptr, char const *file, unsigned int line) -{ - struct debug *debug; - - if (ptr == 0) { - fprintf(stderr, "%s:%u: free(0)\n", file, line); - return; - } - - debug = ptr; - --debug; - - if (debug->magic != DEBUG_MAGIC) { - fprintf(stderr, "%s:%u: free(%p) memory not allocated\n", file, line, ptr); - return; - } - - debug->magic = 0; - - if (debug->next) - debug->next->prev = debug->prev; - if (debug->prev) - debug->prev->next = debug->next; - - if (allocated == debug) - allocated = debug->next; - - free(debug); -} - -void *id3_debug_release(void *ptr, char const *file, unsigned int line) -{ - struct debug *debug; - - if (ptr == 0) - return 0; - - debug = ptr; - --debug; - - if (debug->magic != DEBUG_MAGIC) { - fprintf(stderr, "%s:%u: release(%p) memory not allocated\n", - file, line, ptr); - return ptr; - } - - if (debug->next) - debug->next->prev = debug->prev; - if (debug->prev) - debug->prev->next = debug->next; - - if (allocated == debug) - allocated = debug->next; - - memmove(debug, debug + 1, debug->size); - - return debug; -} - -# endif diff --git a/lib-src/libid3tag/debug.h b/lib-src/libid3tag/debug.h deleted file mode 100644 index 32ff556fb..000000000 --- a/lib-src/libid3tag/debug.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: debug.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_DEBUG_H -# define LIBID3TAG_DEBUG_H - -# include - -void *id3_debug_malloc(size_t, char const *, unsigned int); -void *id3_debug_calloc(size_t, size_t, char const *, unsigned int); -void *id3_debug_realloc(void *, size_t, char const *, unsigned int); -void id3_debug_free(void *, char const *, unsigned int); - -void *id3_debug_release(void *, char const *, unsigned int); - -# endif diff --git a/lib-src/libid3tag/depcomp b/lib-src/libid3tag/depcomp deleted file mode 100755 index 4ebd5b3a2..000000000 --- a/lib-src/libid3tag/depcomp +++ /dev/null @@ -1,791 +0,0 @@ -#! /bin/sh -# depcomp - compile a program generating dependencies as side-effects - -scriptversion=2013-05-30.07; # UTC - -# Copyright (C) 1999-2013 Free Software Foundation, Inc. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Originally written by Alexandre Oliva . - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: depcomp [--help] [--version] PROGRAM [ARGS] - -Run PROGRAMS ARGS to compile a file, generating dependencies -as side-effects. - -Environment variables: - depmode Dependency tracking mode. - source Source file read by 'PROGRAMS ARGS'. - object Object file output by 'PROGRAMS ARGS'. - DEPDIR directory where to store dependencies. - depfile Dependency file to output. - tmpdepfile Temporary file to use when outputting dependencies. - libtool Whether libtool is used (yes/no). - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "depcomp $scriptversion" - exit $? - ;; -esac - -# Get the directory component of the given path, and save it in the -# global variables '$dir'. Note that this directory component will -# be either empty or ending with a '/' character. This is deliberate. -set_dir_from () -{ - case $1 in - */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; - *) dir=;; - esac -} - -# Get the suffix-stripped basename of the given path, and save it the -# global variable '$base'. -set_base_from () -{ - base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` -} - -# If no dependency file was actually created by the compiler invocation, -# we still have to create a dummy depfile, to avoid errors with the -# Makefile "include basename.Plo" scheme. -make_dummy_depfile () -{ - echo "#dummy" > "$depfile" -} - -# Factor out some common post-processing of the generated depfile. -# Requires the auxiliary global variable '$tmpdepfile' to be set. -aix_post_process_depfile () -{ - # If the compiler actually managed to produce a dependency file, - # post-process it. - if test -f "$tmpdepfile"; then - # Each line is of the form 'foo.o: dependency.h'. - # Do two passes, one to just change these to - # $object: dependency.h - # and one to simply output - # dependency.h: - # which is needed to avoid the deleted-header problem. - { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" - sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" - } > "$depfile" - rm -f "$tmpdepfile" - else - make_dummy_depfile - fi -} - -# A tabulation character. -tab=' ' -# A newline character. -nl=' -' -# Character ranges might be problematic outside the C locale. -# These definitions help. -upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ -lower=abcdefghijklmnopqrstuvwxyz -digits=0123456789 -alpha=${upper}${lower} - -if test -z "$depmode" || test -z "$source" || test -z "$object"; then - echo "depcomp: Variables source, object and depmode must be set" 1>&2 - exit 1 -fi - -# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. -depfile=${depfile-`echo "$object" | - sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} -tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} - -rm -f "$tmpdepfile" - -# Avoid interferences from the environment. -gccflag= dashmflag= - -# Some modes work just like other modes, but use different flags. We -# parameterize here, but still list the modes in the big case below, -# to make depend.m4 easier to write. Note that we *cannot* use a case -# here, because this file can only contain one case statement. -if test "$depmode" = hp; then - # HP compiler uses -M and no extra arg. - gccflag=-M - depmode=gcc -fi - -if test "$depmode" = dashXmstdout; then - # This is just like dashmstdout with a different argument. - dashmflag=-xM - depmode=dashmstdout -fi - -cygpath_u="cygpath -u -f -" -if test "$depmode" = msvcmsys; then - # This is just like msvisualcpp but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvisualcpp -fi - -if test "$depmode" = msvc7msys; then - # This is just like msvc7 but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvc7 -fi - -if test "$depmode" = xlc; then - # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. - gccflag=-qmakedep=gcc,-MF - depmode=gcc -fi - -case "$depmode" in -gcc3) -## gcc 3 implements dependency tracking that does exactly what -## we want. Yay! Note: for some reason libtool 1.4 doesn't like -## it if -MD -MP comes after the -MF stuff. Hmm. -## Unfortunately, FreeBSD c89 acceptance of flags depends upon -## the command line argument order; so add the flags where they -## appear in depend2.am. Note that the slowdown incurred here -## affects only configure: in makefiles, %FASTDEP% shortcuts this. - for arg - do - case $arg in - -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; - *) set fnord "$@" "$arg" ;; - esac - shift # fnord - shift # $arg - done - "$@" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - mv "$tmpdepfile" "$depfile" - ;; - -gcc) -## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. -## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. -## (see the conditional assignment to $gccflag above). -## There are various ways to get dependency output from gcc. Here's -## why we pick this rather obscure method: -## - Don't want to use -MD because we'd like the dependencies to end -## up in a subdir. Having to rename by hand is ugly. -## (We might end up doing this anyway to support other compilers.) -## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like -## -MM, not -M (despite what the docs say). Also, it might not be -## supported by the other compilers which use the 'gcc' depmode. -## - Using -M directly means running the compiler twice (even worse -## than renaming). - if test -z "$gccflag"; then - gccflag=-MD, - fi - "$@" -Wp,"$gccflag$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The second -e expression handles DOS-style file names with drive - # letters. - sed -e 's/^[^:]*: / /' \ - -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" -## This next piece of magic avoids the "deleted header file" problem. -## The problem is that when a header file which appears in a .P file -## is deleted, the dependency causes make to die (because there is -## typically no way to rebuild the header). We avoid this by adding -## dummy dependencies for each header file. Too bad gcc doesn't do -## this for us directly. -## Some versions of gcc put a space before the ':'. On the theory -## that the space means something, we add a space to the output as -## well. hp depmode also adds that space, but also prefixes the VPATH -## to the object. Take care to not repeat it in the output. -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -sgi) - if test "$libtool" = yes; then - "$@" "-Wp,-MDupdate,$tmpdepfile" - else - "$@" -MDupdate "$tmpdepfile" - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - - if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files - echo "$object : \\" > "$depfile" - # Clip off the initial element (the dependent). Don't try to be - # clever and replace this with sed code, as IRIX sed won't handle - # lines with more than a fixed number of characters (4096 in - # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; - # the IRIX cc adds comments like '#:fec' to the end of the - # dependency line. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ - | tr "$nl" ' ' >> "$depfile" - echo >> "$depfile" - # The second pass generates a dummy entry for each header file. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" - ;; - -xlc) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -aix) - # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. In older versions, this file always lives in the - # current directory. Also, the AIX compiler puts '$object:' at the - # start of each line; $object doesn't have directory information. - # Version 6 uses the directory in both cases. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.u - tmpdepfile2=$base.u - tmpdepfile3=$dir.libs/$base.u - "$@" -Wc,-M - else - tmpdepfile1=$dir$base.u - tmpdepfile2=$dir$base.u - tmpdepfile3=$dir$base.u - "$@" -M - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - aix_post_process_depfile - ;; - -tcc) - # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 - # FIXME: That version still under development at the moment of writing. - # Make that this statement remains true also for stable, released - # versions. - # It will wrap lines (doesn't matter whether long or short) with a - # trailing '\', as in: - # - # foo.o : \ - # foo.c \ - # foo.h \ - # - # It will put a trailing '\' even on the last line, and will use leading - # spaces rather than leading tabs (at least since its commit 0394caf7 - # "Emit spaces for -MD"). - "$@" -MD -MF "$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. - # We have to change lines of the first kind to '$object: \'. - sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" - # And for each line of the second kind, we have to emit a 'dep.h:' - # dummy dependency, to avoid the deleted-header problem. - sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" - rm -f "$tmpdepfile" - ;; - -## The order of this option in the case statement is important, since the -## shell code in configure will try each of these formats in the order -## listed in this file. A plain '-MD' option would be understood by many -## compilers, so we must ensure this comes after the gcc and icc options. -pgcc) - # Portland's C compiler understands '-MD'. - # Will always output deps to 'file.d' where file is the root name of the - # source file under compilation, even if file resides in a subdirectory. - # The object file name does not affect the name of the '.d' file. - # pgcc 10.2 will output - # foo.o: sub/foo.c sub/foo.h - # and will wrap long lines using '\' : - # foo.o: sub/foo.c ... \ - # sub/foo.h ... \ - # ... - set_dir_from "$object" - # Use the source, not the object, to determine the base name, since - # that's sadly what pgcc will do too. - set_base_from "$source" - tmpdepfile=$base.d - - # For projects that build the same source file twice into different object - # files, the pgcc approach of using the *source* file root name can cause - # problems in parallel builds. Use a locking strategy to avoid stomping on - # the same $tmpdepfile. - lockdir=$base.d-lock - trap " - echo '$0: caught signal, cleaning up...' >&2 - rmdir '$lockdir' - exit 1 - " 1 2 13 15 - numtries=100 - i=$numtries - while test $i -gt 0; do - # mkdir is a portable test-and-set. - if mkdir "$lockdir" 2>/dev/null; then - # This process acquired the lock. - "$@" -MD - stat=$? - # Release the lock. - rmdir "$lockdir" - break - else - # If the lock is being held by a different process, wait - # until the winning process is done or we timeout. - while test -d "$lockdir" && test $i -gt 0; do - sleep 1 - i=`expr $i - 1` - done - fi - i=`expr $i - 1` - done - trap - 1 2 13 15 - if test $i -le 0; then - echo "$0: failed to acquire lock after $numtries attempts" >&2 - echo "$0: check lockdir '$lockdir'" >&2 - exit 1 - fi - - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each line is of the form `foo.o: dependent.h', - # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp2) - # The "hp" stanza above does not work with aCC (C++) and HP's ia64 - # compilers, which have integrated preprocessors. The correct option - # to use with these is +Maked; it writes dependencies to a file named - # 'foo.d', which lands next to the object file, wherever that - # happens to be. - # Much of this is similar to the tru64 case; see comments there. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir.libs/$base.d - "$@" -Wc,+Maked - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - "$@" +Maked - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" - do - test -f "$tmpdepfile" && break - done - if test -f "$tmpdepfile"; then - sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" - # Add 'dependent.h:' lines. - sed -ne '2,${ - s/^ *// - s/ \\*$// - s/$/:/ - p - }' "$tmpdepfile" >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" "$tmpdepfile2" - ;; - -tru64) - # The Tru64 compiler uses -MD to generate dependencies as a side - # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. - # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put - # dependencies in 'foo.d' instead, so we check for that too. - # Subdirectories are respected. - set_dir_from "$object" - set_base_from "$object" - - if test "$libtool" = yes; then - # Libtool generates 2 separate objects for the 2 libraries. These - # two compilations output dependencies in $dir.libs/$base.o.d and - # in $dir$base.o.d. We have to check for both files, because - # one of the two compilations can be disabled. We should prefer - # $dir$base.o.d over $dir.libs/$base.o.d because the latter is - # automatically cleaned when .libs/ is deleted, while ignoring - # the former would cause a distcleancheck panic. - tmpdepfile1=$dir$base.o.d # libtool 1.5 - tmpdepfile2=$dir.libs/$base.o.d # Likewise. - tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 - "$@" -Wc,-MD - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - tmpdepfile3=$dir$base.d - "$@" -MD - fi - - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - # Same post-processing that is required for AIX mode. - aix_post_process_depfile - ;; - -msvc7) - if test "$libtool" = yes; then - showIncludes=-Wc,-showIncludes - else - showIncludes=-showIncludes - fi - "$@" $showIncludes > "$tmpdepfile" - stat=$? - grep -v '^Note: including file: ' "$tmpdepfile" - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The first sed program below extracts the file names and escapes - # backslashes for cygpath. The second sed program outputs the file - # name when reading, but also accumulates all include files in the - # hold buffer in order to output them again at the end. This only - # works with sed implementations that can handle large buffers. - sed < "$tmpdepfile" -n ' -/^Note: including file: *\(.*\)/ { - s//\1/ - s/\\/\\\\/g - p -}' | $cygpath_u | sort -u | sed -n ' -s/ /\\ /g -s/\(.*\)/'"$tab"'\1 \\/p -s/.\(.*\) \\/\1:/ -H -$ { - s/.*/'"$tab"'/ - G - p -}' >> "$depfile" - echo >> "$depfile" # make sure the fragment doesn't end with a backslash - rm -f "$tmpdepfile" - ;; - -msvc7msys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -#nosideeffect) - # This comment above is used by automake to tell side-effect - # dependency tracking mechanisms from slower ones. - -dashmstdout) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - test -z "$dashmflag" && dashmflag=-M - # Require at least two characters before searching for ':' - # in the target name. This is to cope with DOS-style filenames: - # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. - "$@" $dashmflag | - sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this sed invocation - # correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -dashXmstdout) - # This case only exists to satisfy depend.m4. It is never actually - # run, as this mode is specially recognized in the preamble. - exit 1 - ;; - -makedepend) - "$@" || exit $? - # Remove any Libtool call - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - # X makedepend - shift - cleared=no eat=no - for arg - do - case $cleared in - no) - set ""; shift - cleared=yes ;; - esac - if test $eat = yes; then - eat=no - continue - fi - case "$arg" in - -D*|-I*) - set fnord "$@" "$arg"; shift ;; - # Strip any option that makedepend may not understand. Remove - # the object too, otherwise makedepend will parse it as a source file. - -arch) - eat=yes ;; - -*|$object) - ;; - *) - set fnord "$@" "$arg"; shift ;; - esac - done - obj_suffix=`echo "$object" | sed 's/^.*\././'` - touch "$tmpdepfile" - ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" - rm -f "$depfile" - # makedepend may prepend the VPATH from the source file name to the object. - # No need to regex-escape $object, excess matching of '.' is harmless. - sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process the last invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed '1,2d' "$tmpdepfile" \ - | tr ' ' "$nl" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" "$tmpdepfile".bak - ;; - -cpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - "$@" -E \ - | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - | sed '$ s: \\$::' > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - cat < "$tmpdepfile" >> "$depfile" - sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvisualcpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - IFS=" " - for arg - do - case "$arg" in - -o) - shift - ;; - $object) - shift - ;; - "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") - set fnord "$@" - shift - shift - ;; - *) - set fnord "$@" "$arg" - shift - shift - ;; - esac - done - "$@" -E 2>/dev/null | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" - echo "$tab" >> "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvcmsys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -none) - exec "$@" - ;; - -*) - echo "Unknown depmode $depmode" 1>&2 - exit 1 - ;; -esac - -exit 0 - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libid3tag/field.c b/lib-src/libid3tag/field.c deleted file mode 100644 index f4156e207..000000000 --- a/lib-src/libid3tag/field.c +++ /dev/null @@ -1,890 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: field.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "field.h" -# include "frame.h" -# include "render.h" -# include "ucs4.h" -# include "latin1.h" -# include "parse.h" - -/* - * NAME: field->init() - * DESCRIPTION: initialize a field to a default value for the given type - */ -void id3_field_init(union id3_field *field, enum id3_field_type type) -{ - assert(field); - - switch (field->type = type) { - case ID3_FIELD_TYPE_TEXTENCODING: - case ID3_FIELD_TYPE_INT8: - case ID3_FIELD_TYPE_INT16: - case ID3_FIELD_TYPE_INT24: - case ID3_FIELD_TYPE_INT32: - field->number.value = 0; - break; - - case ID3_FIELD_TYPE_LATIN1: - case ID3_FIELD_TYPE_LATIN1FULL: - field->latin1.ptr = 0; - break; - - case ID3_FIELD_TYPE_LATIN1LIST: - field->latin1list.nstrings = 0; - field->latin1list.strings = 0; - - case ID3_FIELD_TYPE_STRING: - case ID3_FIELD_TYPE_STRINGFULL: - field->string.ptr = 0; - break; - - case ID3_FIELD_TYPE_STRINGLIST: - field->stringlist.nstrings = 0; - field->stringlist.strings = 0; - break; - - case ID3_FIELD_TYPE_LANGUAGE: - strcpy(field->immediate.value, "XXX"); - break; - - case ID3_FIELD_TYPE_FRAMEID: - strcpy(field->immediate.value, "XXXX"); - break; - - case ID3_FIELD_TYPE_DATE: - memset(field->immediate.value, 0, sizeof(field->immediate.value)); - break; - - case ID3_FIELD_TYPE_INT32PLUS: - case ID3_FIELD_TYPE_BINARYDATA: - field->binary.data = 0; - field->binary.length = 0; - break; - } -} - -/* - * NAME: field->finish() - * DESCRIPTION: reset a field, deallocating memory if necessary - */ -void id3_field_finish(union id3_field *field) -{ - unsigned int i; - - assert(field); - - switch (field->type) { - case ID3_FIELD_TYPE_TEXTENCODING: - case ID3_FIELD_TYPE_INT8: - case ID3_FIELD_TYPE_INT16: - case ID3_FIELD_TYPE_INT24: - case ID3_FIELD_TYPE_INT32: - case ID3_FIELD_TYPE_LANGUAGE: - case ID3_FIELD_TYPE_FRAMEID: - case ID3_FIELD_TYPE_DATE: - break; - - case ID3_FIELD_TYPE_LATIN1: - case ID3_FIELD_TYPE_LATIN1FULL: - if (field->latin1.ptr) - free(field->latin1.ptr); - break; - - case ID3_FIELD_TYPE_LATIN1LIST: - for (i = 0; i < field->latin1list.nstrings; ++i) - free(field->latin1list.strings[i]); - - if (field->latin1list.strings) - free(field->latin1list.strings); - break; - - case ID3_FIELD_TYPE_STRING: - case ID3_FIELD_TYPE_STRINGFULL: - if (field->string.ptr) - free(field->string.ptr); - break; - - case ID3_FIELD_TYPE_STRINGLIST: - for (i = 0; i < field->stringlist.nstrings; ++i) - free(field->stringlist.strings[i]); - - if (field->stringlist.strings) - free(field->stringlist.strings); - break; - - case ID3_FIELD_TYPE_INT32PLUS: - case ID3_FIELD_TYPE_BINARYDATA: - if (field->binary.data) - free(field->binary.data); - break; - } - - id3_field_init(field, field->type); -} - -/* - * NAME: field->type() - * DESCRIPTION: return the value type of a field - */ -enum id3_field_type id3_field_type(union id3_field const *field) -{ - assert(field); - - return field->type; -} - -/* - * NAME: field->parse() - * DESCRIPTION: parse a field value - */ -int id3_field_parse(union id3_field *field, id3_byte_t const **ptr, - id3_length_t length, enum id3_field_textencoding *encoding) -{ - assert(field); - - id3_field_finish(field); - - switch (field->type) { - case ID3_FIELD_TYPE_INT32: - if (length < 4) - goto fail; - - field->number.value = id3_parse_uint(ptr, 4); - break; - - case ID3_FIELD_TYPE_INT24: - if (length < 3) - goto fail; - - field->number.value = id3_parse_uint(ptr, 3); - break; - - case ID3_FIELD_TYPE_INT16: - if (length < 2) - goto fail; - - field->number.value = id3_parse_uint(ptr, 2); - break; - - case ID3_FIELD_TYPE_INT8: - case ID3_FIELD_TYPE_TEXTENCODING: - if (length < 1) - goto fail; - - field->number.value = id3_parse_uint(ptr, 1); - - if (field->type == ID3_FIELD_TYPE_TEXTENCODING) - *encoding = field->number.value; - break; - - case ID3_FIELD_TYPE_LANGUAGE: - if (length < 3) - goto fail; - - id3_parse_immediate(ptr, 3, field->immediate.value); - break; - - case ID3_FIELD_TYPE_FRAMEID: - if (length < 4) - goto fail; - - id3_parse_immediate(ptr, 4, field->immediate.value); - break; - - case ID3_FIELD_TYPE_DATE: - if (length < 8) - goto fail; - - id3_parse_immediate(ptr, 8, field->immediate.value); - break; - - case ID3_FIELD_TYPE_LATIN1: - case ID3_FIELD_TYPE_LATIN1FULL: - { - id3_latin1_t *latin1; - - latin1 = id3_parse_latin1(ptr, length, - field->type == ID3_FIELD_TYPE_LATIN1FULL); - if (latin1 == 0) - goto fail; - - field->latin1.ptr = latin1; - } - break; - - case ID3_FIELD_TYPE_LATIN1LIST: - { - id3_byte_t const *end; - id3_latin1_t *latin1, **strings; - - end = *ptr + length; - - while (end - *ptr > 0) { - latin1 = id3_parse_latin1(ptr, end - *ptr, 0); - if (latin1 == 0) - goto fail; - - strings = realloc(field->latin1list.strings, - (field->latin1list.nstrings + 1) * sizeof(*strings)); - if (strings == 0) { - free(latin1); - goto fail; - } - - field->latin1list.strings = strings; - field->latin1list.strings[field->latin1list.nstrings++] = latin1; - } - } - break; - - case ID3_FIELD_TYPE_STRING: - case ID3_FIELD_TYPE_STRINGFULL: - { - id3_ucs4_t *ucs4; - - ucs4 = id3_parse_string(ptr, length, *encoding, - field->type == ID3_FIELD_TYPE_STRINGFULL); - if (ucs4 == 0) - goto fail; - - field->string.ptr = ucs4; - } - break; - - case ID3_FIELD_TYPE_STRINGLIST: - { - id3_byte_t const *end; - id3_ucs4_t *ucs4, **strings; - - end = *ptr + length; - - while (end - *ptr > 0) { - ucs4 = id3_parse_string(ptr, end - *ptr, *encoding, 0); - if (ucs4 == 0) - goto fail; - - strings = realloc(field->stringlist.strings, - (field->stringlist.nstrings + 1) * sizeof(*strings)); - if (strings == 0) { - free(ucs4); - goto fail; - } - - field->stringlist.strings = strings; - field->stringlist.strings[field->stringlist.nstrings++] = ucs4; - } - } - break; - - case ID3_FIELD_TYPE_INT32PLUS: - case ID3_FIELD_TYPE_BINARYDATA: - { - id3_byte_t *data; - - data = id3_parse_binary(ptr, length); - if (data == 0) - goto fail; - - field->binary.data = data; - field->binary.length = length; - } - break; - } - - return 0; - - fail: - return -1; -} - -/* - * NAME: field->render() - * DESCRIPTION: render a field value - */ -id3_length_t id3_field_render(union id3_field const *field, id3_byte_t **ptr, - enum id3_field_textencoding *encoding, - int terminate) -{ - id3_length_t size; - unsigned int i; - - assert(field && encoding); - - switch (field->type) { - case ID3_FIELD_TYPE_INT32: - return id3_render_int(ptr, field->number.value, 4); - - case ID3_FIELD_TYPE_INT24: - return id3_render_int(ptr, field->number.value, 3); - - case ID3_FIELD_TYPE_INT16: - return id3_render_int(ptr, field->number.value, 2); - - case ID3_FIELD_TYPE_TEXTENCODING: - *encoding = field->number.value; - case ID3_FIELD_TYPE_INT8: - return id3_render_int(ptr, field->number.value, 1); - - case ID3_FIELD_TYPE_LATIN1: - case ID3_FIELD_TYPE_LATIN1FULL: - return id3_render_latin1(ptr, field->latin1.ptr, terminate); - - case ID3_FIELD_TYPE_LATIN1LIST: - size = 0; - for (i = 0; i < field->latin1list.nstrings; ++i) { - size += id3_render_latin1(ptr, field->latin1list.strings[i], - (i < field->latin1list.nstrings - 1) || - terminate); - } - return size; - - case ID3_FIELD_TYPE_STRING: - case ID3_FIELD_TYPE_STRINGFULL: - return id3_render_string(ptr, field->string.ptr, *encoding, terminate); - - case ID3_FIELD_TYPE_STRINGLIST: - size = 0; - for (i = 0; i < field->stringlist.nstrings; ++i) { - size += id3_render_string(ptr, field->stringlist.strings[i], *encoding, - (i < field->stringlist.nstrings - 1) || - terminate); - } - return size; - - case ID3_FIELD_TYPE_LANGUAGE: - return id3_render_immediate(ptr, field->immediate.value, 3); - - case ID3_FIELD_TYPE_FRAMEID: - return id3_render_immediate(ptr, field->immediate.value, 4); - - case ID3_FIELD_TYPE_DATE: - return id3_render_immediate(ptr, field->immediate.value, 8); - - case ID3_FIELD_TYPE_INT32PLUS: - case ID3_FIELD_TYPE_BINARYDATA: - return id3_render_binary(ptr, field->binary.data, field->binary.length); - } - - return 0; -} - -/* - * NAME: field->setint() - * DESCRIPTION: set the value of an int field - */ -int id3_field_setint(union id3_field *field, signed long number) -{ - assert(field); - - switch (field->type) { - case ID3_FIELD_TYPE_INT8: - if (number > 0x7f || number < -0x80) - return -1; - break; - - case ID3_FIELD_TYPE_INT16: - if (number > 0x7fff || number < -0x8000) - return -1; - break; - - case ID3_FIELD_TYPE_INT24: - if (number > 0x7fffffL || number < -0x800000L) - return -1; - break; - - case ID3_FIELD_TYPE_INT32: - if (number > 0x7fffffffL || number < -0x80000000L) - return -1; - break; - - default: - return -1; - } - - id3_field_finish(field); - - field->number.value = number; - - return 0; -} - -/* - * NAME: field->settextencoding() - * DESCRIPTION: set the value of a textencoding field - */ -int id3_field_settextencoding(union id3_field *field, - enum id3_field_textencoding encoding) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_TEXTENCODING) - return -1; - - id3_field_finish(field); - - field->number.value = encoding; - - return 0; -} - -static -int set_latin1(union id3_field *field, id3_latin1_t const *latin1) -{ - id3_latin1_t *data; - - if (latin1 == 0 || *latin1 == 0) - data = 0; - else { - data = id3_latin1_duplicate(latin1); - if (data == 0) - return -1; - } - - field->latin1.ptr = data; - - return 0; -} - -/* - * NAME: field->setlatin1() - * DESCRIPTION: set the value of a latin1 field - */ -int id3_field_setlatin1(union id3_field *field, id3_latin1_t const *latin1) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_LATIN1) - return -1; - - id3_field_finish(field); - - if (latin1) { - id3_latin1_t const *ptr; - - for (ptr = latin1; *ptr; ++ptr) { - if (*ptr == '\n') - return -1; - } - } - - return set_latin1(field, latin1); -} - -/* - * NAME: field->setfulllatin1() - * DESCRIPTION: set the value of a full latin1 field - */ -int id3_field_setfulllatin1(union id3_field *field, id3_latin1_t const *latin1) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_LATIN1FULL) - return -1; - - id3_field_finish(field); - - return set_latin1(field, latin1); -} - -static -int set_string(union id3_field *field, id3_ucs4_t const *string) -{ - id3_ucs4_t *data; - - if (string == 0 || *string == 0) - data = 0; - else { - data = id3_ucs4_duplicate(string); - if (data == 0) - return -1; - } - - field->string.ptr = data; - - return 0; -} - -/* - * NAME: field->setstring() - * DESCRIPTION: set the value of a string field - */ -int id3_field_setstring(union id3_field *field, id3_ucs4_t const *string) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRING) - return -1; - - id3_field_finish(field); - - if (string) { - id3_ucs4_t const *ptr; - - for (ptr = string; *ptr; ++ptr) { - if (*ptr == '\n') - return -1; - } - } - - return set_string(field, string); -} - -/* - * NAME: field->setfullstring() - * DESCRIPTION: set the value of a full string field - */ -int id3_field_setfullstring(union id3_field *field, id3_ucs4_t const *string) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGFULL) - return -1; - - id3_field_finish(field); - - return set_string(field, string); -} - -/* - * NAME: field->setstrings() - * DESCRIPTION: set the value of a stringlist field - */ -int id3_field_setstrings(union id3_field *field, - unsigned int length, id3_ucs4_t **ptrs) -{ - id3_ucs4_t **strings; - unsigned int i; - - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGLIST) - return -1; - - id3_field_finish(field); - - if (length == 0) - return 0; - - strings = malloc(length * sizeof(*strings)); - if (strings == 0) - return -1; - - for (i = 0; i < length; ++i) { - strings[i] = id3_ucs4_duplicate(ptrs[i]); - if (strings[i] == 0) { - while (i--) - free(strings[i]); - - free(strings); - return -1; - } - } - - field->stringlist.strings = strings; - field->stringlist.nstrings = length; - - return 0; -} - -/* - * NAME: field->addstring() - * DESCRIPTION: add a string to a stringlist field - */ -int id3_field_addstring(union id3_field *field, id3_ucs4_t const *string) -{ - id3_ucs4_t *new, **strings; - - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGLIST) - return -1; - - if (string == 0) - string = id3_ucs4_empty; - - new = id3_ucs4_duplicate(string); - if (new == 0) - return -1; - - strings = realloc(field->stringlist.strings, - (field->stringlist.nstrings + 1) * sizeof(*strings)); - if (strings == 0) { - free(new); - return -1; - } - - field->stringlist.strings = strings; - field->stringlist.strings[field->stringlist.nstrings++] = new; - - return 0; -} - -/* - * NAME: field->setlanguage() - * DESCRIPTION: set the value of a language field - */ -int id3_field_setlanguage(union id3_field *field, char const *language) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_LANGUAGE) - return -1; - - id3_field_finish(field); - - if (language) { - if (strlen(language) != 3) - return -1; - - strcpy(field->immediate.value, language); - } - - return 0; -} - -/* - * NAME: field->setframeid() - * DESCRIPTION: set the value of a frameid field - */ -int id3_field_setframeid(union id3_field *field, char const *id) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_FRAMEID || - !id3_frame_validid(id)) - return -1; - - id3_field_finish(field); - - field->immediate.value[0] = id[0]; - field->immediate.value[1] = id[1]; - field->immediate.value[2] = id[2]; - field->immediate.value[3] = id[3]; - field->immediate.value[4] = 0; - - return 0; -} - -/* - * NAME: field->setbinarydata() - * DESCRIPTION: set the value of a binarydata field - */ -int id3_field_setbinarydata(union id3_field *field, - id3_byte_t const *data, id3_length_t length) -{ - id3_byte_t *mem; - - assert(field); - - if (field->type != ID3_FIELD_TYPE_BINARYDATA) - return -1; - - id3_field_finish(field); - - if (length == 0) - mem = 0; - else { - mem = malloc(length); - if (mem == 0) - return -1; - - assert(data); - - memcpy(mem, data, length); - } - - field->binary.data = mem; - field->binary.length = length; - - return 0; -} - -/* - * NAME: field->getint() - * DESCRIPTION: return the value of an integer field - */ -signed long id3_field_getint(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_INT8 && - field->type != ID3_FIELD_TYPE_INT16 && - field->type != ID3_FIELD_TYPE_INT24 && - field->type != ID3_FIELD_TYPE_INT32) - return -1; - - return field->number.value; -} - -/* - * NAME: field->gettextencoding() - * DESCRIPTION: return the value of a text encoding field - */ -enum id3_field_textencoding -id3_field_gettextencoding(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_TEXTENCODING) - return -1; - - return field->number.value; -} - -/* - * NAME: field->getlatin1() - * DESCRIPTION: return the value of a latin1 field - */ -id3_latin1_t const *id3_field_getlatin1(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_LATIN1) - return 0; - - return field->latin1.ptr ? field->latin1.ptr : (id3_latin1_t const *) ""; -} - -/* - * NAME: field->getfulllatin1() - * DESCRIPTION: return the value of a full latin1 field - */ -id3_latin1_t const *id3_field_getfulllatin1(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_LATIN1FULL) - return 0; - - return field->latin1.ptr ? field->latin1.ptr : (id3_latin1_t const *) ""; -} - -/* - * NAME: field->getstring() - * DESCRIPTION: return the value of a string field - */ -id3_ucs4_t const *id3_field_getstring(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRING) - return 0; - - return field->string.ptr ? field->string.ptr : id3_ucs4_empty; -} - -/* - * NAME: field->getfullstring() - * DESCRIPTION: return the value of a fullstring field - */ -id3_ucs4_t const *id3_field_getfullstring(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGFULL) - return 0; - - return field->string.ptr ? field->string.ptr : id3_ucs4_empty; -} - -/* - * NAME: field->getnstrings() - * DESCRIPTION: return the number of strings in a stringlist field - */ -unsigned int id3_field_getnstrings(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGLIST) - return 0; - - return field->stringlist.nstrings; -} - -/* - * NAME: field->getstrings() - * DESCRIPTION: return one value of a stringlist field - */ -id3_ucs4_t const *id3_field_getstrings(union id3_field const *field, - unsigned int index) -{ - id3_ucs4_t const *string; - - assert(field); - - if (field->type != ID3_FIELD_TYPE_STRINGLIST || - index >= field->stringlist.nstrings) - return 0; - - string = field->stringlist.strings[index]; - - return string ? string : id3_ucs4_empty; -} - -/* - * NAME: field->getframeid() - * DESCRIPTION: return the value of a frameid field - */ -char const *id3_field_getframeid(union id3_field const *field) -{ - assert(field); - - if (field->type != ID3_FIELD_TYPE_FRAMEID) - return 0; - - return field->immediate.value; -} - -/* - * NAME: field->getbinarydata() - * DESCRIPTION: return the value of a binarydata field - */ -id3_byte_t const *id3_field_getbinarydata(union id3_field const *field, - id3_length_t *length) -{ - static id3_byte_t const empty; - - assert(field && length); - - if (field->type != ID3_FIELD_TYPE_BINARYDATA) - return 0; - - assert(field->binary.length == 0 || field->binary.data); - - *length = field->binary.length; - - return field->binary.data ? field->binary.data : ∅ -} diff --git a/lib-src/libid3tag/field.h b/lib-src/libid3tag/field.h deleted file mode 100644 index 386edec69..000000000 --- a/lib-src/libid3tag/field.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: field.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_FIELD_H -# define LIBID3TAG_FIELD_H - -# include "id3tag.h" - -void id3_field_init(union id3_field *, enum id3_field_type); -void id3_field_finish(union id3_field *); - -int id3_field_parse(union id3_field *, id3_byte_t const **, - id3_length_t, enum id3_field_textencoding *); - -id3_length_t id3_field_render(union id3_field const *, id3_byte_t **, - enum id3_field_textencoding *, int); - -# endif diff --git a/lib-src/libid3tag/file.c b/lib-src/libid3tag/file.c deleted file mode 100644 index 0a3f7baea..000000000 --- a/lib-src/libid3tag/file.c +++ /dev/null @@ -1,674 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: file.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include -# include - -# ifdef HAVE_UNISTD_H -# include -# endif - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "file.h" -# include "tag.h" -# include "field.h" - -struct filetag { - struct id3_tag *tag; - unsigned long location; - id3_length_t length; -}; - -struct id3_file { - FILE *iofile; - enum id3_file_mode mode; - char *path; - - int flags; - - struct id3_tag *primary; - - unsigned int ntags; - struct filetag *tags; -}; - -enum { - ID3_FILE_FLAG_ID3V1 = 0x0001 -}; - -/* - * NAME: query_tag() - * DESCRIPTION: check for a tag at a file's current position - */ -static -signed long query_tag(FILE *iofile) -{ - fpos_t save_position; - id3_byte_t query[ID3_TAG_QUERYSIZE]; - signed long size; - - if (fgetpos(iofile, &save_position) == -1) - return 0; - - size = id3_tag_query(query, fread(query, 1, sizeof(query), iofile)); - - if (fsetpos(iofile, &save_position) == -1) - return 0; - - return size; -} - -/* - * NAME: read_tag() - * DESCRIPTION: read and parse a tag at a file's current position - */ -static -struct id3_tag *read_tag(FILE *iofile, id3_length_t size) -{ - id3_byte_t *data; - struct id3_tag *tag = 0; - - data = malloc(size); - if (data) { - if (fread(data, size, 1, iofile) == 1) - tag = id3_tag_parse(data, size); - - free(data); - } - - return tag; -} - -/* - * NAME: update_primary() - * DESCRIPTION: update the primary tag with data from a new tag - */ -static -int update_primary(struct id3_tag *tag, struct id3_tag const *new) -{ - unsigned int i; - struct id3_frame *frame; - - if (new) { - if (!(new->extendedflags & ID3_TAG_EXTENDEDFLAG_TAGISANUPDATE)) - id3_tag_clearframes(tag); - - i = 0; - while ((frame = id3_tag_findframe(new, 0, i++))) { - if (id3_tag_attachframe(tag, frame) == -1) - return -1; - } - } - - return 0; -} - -/* - * NAME: tag_compare() - * DESCRIPTION: tag sort function for qsort() - */ -static -int tag_compare(const void *a, const void *b) -{ - struct filetag const *tag1 = a, *tag2 = b; - - if (tag1->location < tag2->location) - return -1; - else if (tag1->location > tag2->location) - return +1; - - return 0; -} - -/* - * NAME: add_filetag() - * DESCRIPTION: add a new file tag entry - */ -static -int add_filetag(struct id3_file *file, struct filetag const *filetag) -{ - struct filetag *tags; - - tags = realloc(file->tags, (file->ntags + 1) * sizeof(*tags)); - if (tags == 0) - return -1; - - file->tags = tags; - file->tags[file->ntags++] = *filetag; - - /* sort tags by location */ - - if (file->ntags > 1) - qsort(file->tags, file->ntags, sizeof(file->tags[0]), tag_compare); - - return 0; -} - -/* - * NAME: del_filetag() - * DESCRIPTION: delete a file tag entry - */ -static -void del_filetag(struct id3_file *file, unsigned int index) -{ - assert(index < file->ntags); - - while (index < file->ntags - 1) { - file->tags[index] = file->tags[index + 1]; - ++index; - } - - --file->ntags; -} - -/* - * NAME: add_tag() - * DESCRIPTION: read, parse, and add a tag to a file structure - */ -static -struct id3_tag *add_tag(struct id3_file *file, id3_length_t length) -{ - long location; - unsigned int i; - struct filetag filetag; - struct id3_tag *tag; - - location = ftell(file->iofile); - if (location == -1) - return 0; - - /* check for duplication/overlap */ - { - unsigned long begin1, end1, begin2, end2; - - begin1 = location; - end1 = begin1 + length; - - for (i = 0; i < file->ntags; ++i) { - begin2 = file->tags[i].location; - end2 = begin2 + file->tags[i].length; - - if (begin1 == begin2 && end1 == end2) - return file->tags[i].tag; /* duplicate */ - - if (begin1 < end2 && end1 > begin2) - return 0; /* overlap */ - } - } - - tag = read_tag(file->iofile, length); - - filetag.tag = tag; - filetag.location = location; - filetag.length = length; - - if (add_filetag(file, &filetag) == -1 || - update_primary(file->primary, tag) == -1) { - if (tag) - id3_tag_delete(tag); - return 0; - } - - if (tag) - id3_tag_addref(tag); - - return tag; -} - -/* - * NAME: search_tags() - * DESCRIPTION: search for tags in a file - */ -static -int search_tags(struct id3_file *file) -{ - fpos_t save_position; - signed long size; - - /* - * save the current seek position - * - * We also verify the stream is seekable by calling fsetpos(), since - * fgetpos() alone is not reliable enough for this purpose. - * - * [Apparently not even fsetpos() is sufficient under Win32.] - */ - - if (fgetpos(file->iofile, &save_position) == -1 || - fsetpos(file->iofile, &save_position) == -1) - return -1; - - /* look for an ID3v1 tag */ - - if (fseek(file->iofile, -128, SEEK_END) == 0) { - size = query_tag(file->iofile); - if (size > 0) { - struct id3_tag const *tag; - - tag = add_tag(file, size); - - /* if this is indeed an ID3v1 tag, mark the file so */ - - if (tag && (ID3_TAG_VERSION_MAJOR(id3_tag_version(tag)) == 1)) - file->flags |= ID3_FILE_FLAG_ID3V1; - } - } - - /* look for a tag at the beginning of the file */ - - rewind(file->iofile); - - size = query_tag(file->iofile); - if (size > 0) { - struct id3_tag const *tag; - struct id3_frame const *frame; - - tag = add_tag(file, size); - - /* locate tags indicated by SEEK frames */ - - while (tag && (frame = id3_tag_findframe(tag, "SEEK", 0))) { - long seek; - - seek = id3_field_getint(id3_frame_field(frame, 0)); - if (seek < 0 || fseek(file->iofile, seek, SEEK_CUR) == -1) - break; - - size = query_tag(file->iofile); - tag = (size > 0) ? add_tag(file, size) : 0; - } - } - - /* look for a tag at the end of the file (before any ID3v1 tag) */ - - if (fseek(file->iofile, ((file->flags & ID3_FILE_FLAG_ID3V1) ? -128 : 0) + - -10, SEEK_END) == 0) { - size = query_tag(file->iofile); - if (size < 0 && fseek(file->iofile, size, SEEK_CUR) == 0) { - size = query_tag(file->iofile); - if (size > 0) - add_tag(file, size); - } - } - - clearerr(file->iofile); - - /* restore seek position */ - - if (fsetpos(file->iofile, &save_position) == -1) - return -1; - - /* set primary tag options and target padded length for convenience */ - - if ((file->ntags > 0 && !(file->flags & ID3_FILE_FLAG_ID3V1)) || - (file->ntags > 1 && (file->flags & ID3_FILE_FLAG_ID3V1))) { - if (file->tags[0].location == 0) - id3_tag_setlength(file->primary, file->tags[0].length); - else - id3_tag_options(file->primary, ID3_TAG_OPTION_APPENDEDTAG, ~0); - } - - return 0; -} - -/* - * NAME: finish_file() - * DESCRIPTION: release memory associated with a file - */ -static -void finish_file(struct id3_file *file) -{ - unsigned int i; - - if (file->path) - free(file->path); - - if (file->primary) { - id3_tag_delref(file->primary); - id3_tag_delete(file->primary); - } - - for (i = 0; i < file->ntags; ++i) { - struct id3_tag *tag; - - tag = file->tags[i].tag; - if (tag) { - id3_tag_delref(tag); - id3_tag_delete(tag); - } - } - - if (file->tags) - free(file->tags); - - free(file); -} - -/* - * NAME: new_file() - * DESCRIPTION: create a new file structure and load tags - */ -static -struct id3_file *new_file(FILE *iofile, enum id3_file_mode mode, - char const *path) -{ - struct id3_file *file; - - file = malloc(sizeof(*file)); - if (file == 0) - goto fail; - - file->iofile = iofile; - file->mode = mode; - file->path = path ? strdup(path) : 0; - - file->flags = 0; - - file->ntags = 0; - file->tags = 0; - - file->primary = id3_tag_new(); - if (file->primary == 0) - goto fail; - - id3_tag_addref(file->primary); - - /* load tags from the file */ - - if (search_tags(file) == -1) - goto fail; - - id3_tag_options(file->primary, ID3_TAG_OPTION_ID3V1, - (file->flags & ID3_FILE_FLAG_ID3V1) ? ~0 : 0); - - if (0) { - fail: - if (file) { - finish_file(file); - file = 0; - } - } - - return file; -} - -/* - * NAME: file->open() - * DESCRIPTION: open a file given its pathname - */ -struct id3_file *id3_file_open(char const *path, enum id3_file_mode mode) -{ - FILE *iofile; - struct id3_file *file; - - assert(path); - - iofile = fopen(path, (mode == ID3_FILE_MODE_READWRITE) ? "r+b" : "rb"); - if (iofile == 0) - return 0; - - file = new_file(iofile, mode, path); - if (file == 0) - fclose(iofile); - - return file; -} - -/* - * NAME: file->fdopen() - * DESCRIPTION: open a file using an existing file descriptor - */ -struct id3_file *id3_file_fdopen(int fd, enum id3_file_mode mode) -{ -# if 1 || defined(HAVE_UNISTD_H) - FILE *iofile; - struct id3_file *file; - - iofile = fdopen(fd, (mode == ID3_FILE_MODE_READWRITE) ? "r+b" : "rb"); - if (iofile == 0) - return 0; - - file = new_file(iofile, mode, 0); - if (file == 0) { - int save_fd; - - /* close iofile without closing fd */ - - save_fd = dup(fd); - - fclose(iofile); - - dup2(save_fd, fd); - close(save_fd); - } - - return file; -# else - return 0; -# endif -} - -/* - * NAME: file->close() - * DESCRIPTION: close a file and delete its associated tags - */ -int id3_file_close(struct id3_file *file) -{ - int result = 0; - - assert(file); - - if (fclose(file->iofile) == EOF) - result = -1; - - finish_file(file); - - return result; -} - -/* - * NAME: file->tag() - * DESCRIPTION: return the primary tag structure for a file - */ -struct id3_tag *id3_file_tag(struct id3_file const *file) -{ - assert(file); - - return file->primary; -} - -/* - * NAME: v1_write() - * DESCRIPTION: write ID3v1 tag modifications to a file - */ -static -int v1_write(struct id3_file *file, - id3_byte_t const *data, id3_length_t length) -{ - assert(!data || length == 128); - - if (data) { - long location; - - if (fseek(file->iofile, (file->flags & ID3_FILE_FLAG_ID3V1) ? -128 : 0, - SEEK_END) == -1 || - (location = ftell(file->iofile)) == -1 || - fwrite(data, 128, 1, file->iofile) != 1 || - fflush(file->iofile) == EOF) - return -1; - - /* add file tag reference */ - - if (!(file->flags & ID3_FILE_FLAG_ID3V1)) { - struct filetag filetag; - - filetag.tag = 0; - filetag.location = location; - filetag.length = 128; - - if (add_filetag(file, &filetag) == -1) - return -1; - - file->flags |= ID3_FILE_FLAG_ID3V1; - } - } -# if defined(HAVE_FTRUNCATE) - else if (file->flags & ID3_FILE_FLAG_ID3V1) { - long length; - - if (fseek(file->iofile, 0, SEEK_END) == -1) - return -1; - - length = ftell(file->iofile); - if (length == -1 || - (length >= 0 && length < 128)) - return -1; - - if (ftruncate(fileno(file->iofile), length - 128) == -1) - return -1; - - /* delete file tag reference */ - - del_filetag(file, file->ntags - 1); - - file->flags &= ~ID3_FILE_FLAG_ID3V1; - } -# endif - - return 0; -} - -/* - * NAME: v2_write() - * DESCRIPTION: write ID3v2 tag modifications to a file - */ -static -int v2_write(struct id3_file *file, - id3_byte_t const *data, id3_length_t length) -{ - assert(!data || length > 0); - - if (data && - ((file->ntags == 1 && !(file->flags & ID3_FILE_FLAG_ID3V1)) || - (file->ntags == 2 && (file->flags & ID3_FILE_FLAG_ID3V1))) && - file->tags[0].length == length) { - /* easy special case: rewrite existing tag in-place */ - - if (fseek(file->iofile, file->tags[0].location, SEEK_SET) == -1 || - fwrite(data, length, 1, file->iofile) != 1 || - fflush(file->iofile) == EOF) - return -1; - - goto done; - } - - /* hard general case: rewrite entire file */ - - /* ... */ - - done: - return 0; -} - -/* - * NAME: file->update() - * DESCRIPTION: rewrite tag(s) to a file - */ -int id3_file_update(struct id3_file *file) -{ - int options, result = 0; - id3_length_t v1size = 0, v2size = 0; - id3_byte_t id3v1_data[128], *id3v1 = 0, *id3v2 = 0; - - assert(file); - - if (file->mode != ID3_FILE_MODE_READWRITE) - return -1; - - options = id3_tag_options(file->primary, 0, 0); - - /* render ID3v1 */ - - if (options & ID3_TAG_OPTION_ID3V1) { - v1size = id3_tag_render(file->primary, 0); - if (v1size) { - assert(v1size == sizeof(id3v1_data)); - - v1size = id3_tag_render(file->primary, id3v1_data); - if (v1size) { - assert(v1size == sizeof(id3v1_data)); - id3v1 = id3v1_data; - } - } - } - - /* render ID3v2 */ - - id3_tag_options(file->primary, ID3_TAG_OPTION_ID3V1, 0); - - v2size = id3_tag_render(file->primary, 0); - if (v2size) { - id3v2 = malloc(v2size); - if (id3v2 == 0) - goto fail; - - v2size = id3_tag_render(file->primary, id3v2); - if (v2size == 0) { - free(id3v2); - id3v2 = 0; - } - } - - /* write tags */ - - if (v2_write(file, id3v2, v2size) == -1 || - v1_write(file, id3v1, v1size) == -1) - goto fail; - - rewind(file->iofile); - - /* update file tags array? ... */ - - if (0) { - fail: - result = -1; - } - - /* clean up; restore tag options */ - - if (id3v2) - free(id3v2); - - id3_tag_options(file->primary, ~0, options); - - return result; -} diff --git a/lib-src/libid3tag/file.h b/lib-src/libid3tag/file.h deleted file mode 100644 index 70146efe5..000000000 --- a/lib-src/libid3tag/file.h +++ /dev/null @@ -1,25 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: file.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_FILE_H -# define LIBID3TAG_FILE_H - -# endif diff --git a/lib-src/libid3tag/frame.c b/lib-src/libid3tag/frame.c deleted file mode 100644 index 558262e48..000000000 --- a/lib-src/libid3tag/frame.c +++ /dev/null @@ -1,634 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frame.c,v 1.4 2007-04-29 05:10:24 llucius Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "frame.h" -# include "frametype.h" -# include "compat.h" -# include "field.h" -# include "render.h" -# include "parse.h" -# include "util.h" - -static -int valid_idchar(char c) -{ - return (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9'); -} - -/* - * NAME: frame->validid() - * DESCRIPTION: return true if the parameter string is a legal frame ID - */ -int id3_frame_validid(char const *id) -{ - return id && - valid_idchar(id[0]) && - valid_idchar(id[1]) && - valid_idchar(id[2]) && - valid_idchar(id[3]); -} - -/* - * NAME: frame->new() - * DESCRIPTION: allocate and return a new frame - */ -struct id3_frame *id3_frame_new(char const *id) -{ - struct id3_frametype const *frametype; - struct id3_frame *frame; - unsigned int i; - - if (!id3_frame_validid(id)) - return 0; - - frametype = id3_frametype_lookup(id, 4); - if (frametype == 0) { - switch (id[0]) { - case 'T': - frametype = &id3_frametype_text; - break; - - case 'W': - frametype = &id3_frametype_url; - break; - - case 'X': - case 'Y': - case 'Z': - frametype = &id3_frametype_experimental; - break; - - default: - frametype = &id3_frametype_unknown; - if (id3_compat_lookup(id, 4)) - frametype = &id3_frametype_obsolete; - break; - } - } - - frame = malloc(sizeof(*frame) + frametype->nfields * sizeof(*frame->fields)); - if (frame) { - frame->id[0] = id[0]; - frame->id[1] = id[1]; - frame->id[2] = id[2]; - frame->id[3] = id[3]; - frame->id[4] = 0; - - frame->description = frametype->description; - frame->refcount = 0; - frame->flags = frametype->defaultflags; - frame->group_id = 0; - frame->encryption_method = 0; - frame->encoded = 0; - frame->encoded_length = 0; - frame->decoded_length = 0; - frame->nfields = frametype->nfields; - frame->fields = (union id3_field *) &frame[1]; - - for (i = 0; i < frame->nfields; ++i) - id3_field_init(&frame->fields[i], frametype->fields[i]); - } - - return frame; -} - -void id3_frame_delete(struct id3_frame *frame) -{ - assert(frame); - - if (frame->refcount == 0) { - unsigned int i; - - for (i = 0; i < frame->nfields; ++i) - id3_field_finish(&frame->fields[i]); - - if (frame->encoded) - free(frame->encoded); - - free(frame); - } -} - -/* - * NAME: frame->addref() - * DESCRIPTION: add an external reference to a frame - */ -void id3_frame_addref(struct id3_frame *frame) -{ - assert(frame); - - ++frame->refcount; -} - -/* - * NAME: frame->delref() - * DESCRIPTION: remove an external reference to a frame - */ -void id3_frame_delref(struct id3_frame *frame) -{ - assert(frame && frame->refcount > 0); - - --frame->refcount; -} - -/* - * NAME: frame->field() - * DESCRIPTION: return a pointer to a field in a frame - */ -union id3_field *id3_frame_field(struct id3_frame const *frame, - unsigned int index) -{ - assert(frame); - - return (index < frame->nfields) ? &frame->fields[index] : 0; -} - -static -struct id3_frame *obsolete(char const *id, id3_byte_t const *data, - id3_length_t length) -{ - struct id3_frame *frame; - - frame = id3_frame_new(ID3_FRAME_OBSOLETE); - if (frame) { - if (id3_field_setframeid(&frame->fields[0], id) == -1 || - id3_field_setbinarydata(&frame->fields[1], data, length) == -1) - goto fail; - } - - if (0) { - fail: - if (frame) { - id3_frame_delete(frame); - frame = 0; - } - } - - return frame; -} - -static -struct id3_frame *unparseable(char const *id, id3_byte_t const **ptr, - id3_length_t length, int flags, - int group_id, int encryption_method, - id3_length_t decoded_length) -{ - struct id3_frame *frame = 0; - id3_byte_t *mem; - - mem = malloc(length ? length : 1); - if (mem == 0) - goto fail; - - frame = id3_frame_new(id); - if (frame == 0) - free(mem); - else { - memcpy(mem, *ptr, length); - - frame->flags = flags; - frame->group_id = group_id; - frame->encryption_method = encryption_method; - frame->encoded = mem; - frame->encoded_length = length; - frame->decoded_length = decoded_length; - } - - if (0) { - fail: - ; - } - - *ptr += length; - - return frame; -} - -static -int parse_data(struct id3_frame *frame, - id3_byte_t const *data, id3_length_t length) -{ - enum id3_field_textencoding encoding; - id3_byte_t const *end; - unsigned int i; - - encoding = ID3_FIELD_TEXTENCODING_ISO_8859_1; - - end = data + length; - - for (i = 0; i < frame->nfields; ++i) { - if (id3_field_parse(&frame->fields[i], &data, end - data, &encoding) == -1) - return -1; - } - - return 0; -} - -/* - * NAME: frame->parse() - * DESCRIPTION: parse raw frame data according to the specified ID3 tag version - */ -struct id3_frame *id3_frame_parse(id3_byte_t const **ptr, id3_length_t length, - unsigned int version) -{ - struct id3_frame *frame = 0; - id3_byte_t const *id, *end, *data; - id3_length_t size, decoded_length = 0; - int flags = 0, group_id = 0, encryption_method = 0; - struct id3_compat const *compat = 0; - id3_byte_t *mem = 0; - char xid[4]; - - id = *ptr; - end = *ptr + length; - - if (ID3_TAG_VERSION_MAJOR(version) < 4) { - switch (ID3_TAG_VERSION_MAJOR(version)) { - case 2: - if (length < 6) - goto fail; - - compat = id3_compat_lookup((char const *)id, 3); - - *ptr += 3; - size = id3_parse_uint(ptr, 3); - - if (size > end - *ptr) - goto fail; - - end = *ptr + size; - - break; - - case 3: - if (length < 10) - goto fail; - - compat = id3_compat_lookup((char const *)id, 4); - - *ptr += 4; - size = id3_parse_uint(ptr, 4); - flags = id3_parse_uint(ptr, 2); - - if (size > end - *ptr) - goto fail; - - end = *ptr + size; - - if (flags & (ID3_FRAME_FLAG_FORMATFLAGS & ~0x00e0)) { - frame = unparseable((char const *)id, ptr, end - *ptr, 0, 0, 0, 0); - goto done; - } - - flags = - ((flags >> 1) & ID3_FRAME_FLAG_STATUSFLAGS) | - ((flags >> 4) & (ID3_FRAME_FLAG_COMPRESSION | - ID3_FRAME_FLAG_ENCRYPTION)) | - ((flags << 1) & ID3_FRAME_FLAG_GROUPINGIDENTITY); - - if (flags & ID3_FRAME_FLAG_COMPRESSION) { - if (end - *ptr < 4) - goto fail; - - decoded_length = id3_parse_uint(ptr, 4); - } - - if (flags & ID3_FRAME_FLAG_ENCRYPTION) { - if (end - *ptr < 1) - goto fail; - - encryption_method = id3_parse_uint(ptr, 1); - } - - if (flags & ID3_FRAME_FLAG_GROUPINGIDENTITY) { - if (end - *ptr < 1) - goto fail; - - group_id = id3_parse_uint(ptr, 1); - } - - break; - - default: - goto fail; - } - - /* canonicalize frame ID for ID3v2.4 */ - - if (compat && compat->equiv) - id = (id3_byte_t const *)compat->equiv; - else if (ID3_TAG_VERSION_MAJOR(version) == 2) { - xid[0] = 'Y'; - xid[1] = id[0]; - xid[2] = id[1]; - xid[3] = id[2]; - - id = (id3_byte_t const *)xid; - - flags |= - ID3_FRAME_FLAG_TAGALTERPRESERVATION | - ID3_FRAME_FLAG_FILEALTERPRESERVATION; - } - } - else { /* ID3v2.4 */ - if (length < 10) - goto fail; - - *ptr += 4; - size = id3_parse_syncsafe(ptr, 4); - flags = id3_parse_uint(ptr, 2); - - if (size > end - *ptr) - goto fail; - - end = *ptr + size; - - if (flags & (ID3_FRAME_FLAG_FORMATFLAGS & ~ID3_FRAME_FLAG_KNOWNFLAGS)) { - frame = unparseable((char const *)id, ptr, end - *ptr, flags, 0, 0, 0); - goto done; - } - - if (flags & ID3_FRAME_FLAG_GROUPINGIDENTITY) { - if (end - *ptr < 1) - goto fail; - - group_id = id3_parse_uint(ptr, 1); - } - - if ((flags & ID3_FRAME_FLAG_COMPRESSION) && - !(flags & ID3_FRAME_FLAG_DATALENGTHINDICATOR)) - goto fail; - - if (flags & ID3_FRAME_FLAG_ENCRYPTION) { - if (end - *ptr < 1) - goto fail; - - encryption_method = id3_parse_uint(ptr, 1); - } - - if (flags & ID3_FRAME_FLAG_DATALENGTHINDICATOR) { - if (end - *ptr < 4) - goto fail; - - decoded_length = id3_parse_syncsafe(ptr, 4); - } - } - - data = *ptr; - *ptr = end; - - /* undo frame encodings */ - - if ((flags & ID3_FRAME_FLAG_UNSYNCHRONISATION) && end - data > 0) { - mem = malloc(end - data); - if (mem == 0) - goto fail; - - memcpy(mem, data, end - data); - - end = mem + id3_util_deunsynchronise(mem, end - data); - data = mem; - } - - if (flags & ID3_FRAME_FLAG_ENCRYPTION) { - frame = unparseable((char const *)id, &data, end - data, flags, - group_id, encryption_method, decoded_length); - goto done; - } - - if (flags & ID3_FRAME_FLAG_COMPRESSION) { - id3_byte_t *decomp; - - decomp = id3_util_decompress(data, end - data, decoded_length); - if (decomp == 0) - goto fail; - - if (mem) - free(mem); - - data = mem = decomp; - end = data + decoded_length; - } - - /* check for obsolescence */ - - if (compat && !compat->equiv) { - frame = obsolete((char const *)id, data, end - data); - goto done; - } - - /* generate the internal frame structure */ - - frame = id3_frame_new((char const *)id); - if (frame) { - frame->flags = flags; - frame->group_id = group_id; - - if (compat && compat->translate) { - if (compat->translate(frame, compat->id, data, end - data) == -1) - goto fail; - } - else { - if (parse_data(frame, data, end - data) == -1) - goto fail; - } - } - - if (0) { - fail: - if (frame) { - id3_frame_delete(frame); - frame = 0; - } - } - - done: - if (mem) - free(mem); - - return frame; -} - -static -id3_length_t render_data(id3_byte_t **ptr, - union id3_field *fields, unsigned int length) -{ - id3_length_t size = 0; - enum id3_field_textencoding encoding; - unsigned int i; - - encoding = ID3_FIELD_TEXTENCODING_ISO_8859_1; - - for (i = 0; i < length; ++i) - size += id3_field_render(&fields[i], ptr, &encoding, i < length - 1); - - return size; -} - -/* - * NAME: frame->render() - * DESCRIPTION: render a single, complete frame - */ -id3_length_t id3_frame_render(struct id3_frame const *frame, - id3_byte_t **ptr, int options) -{ - id3_length_t size = 0, decoded_length, datalen; - id3_byte_t *size_ptr = 0, *flags_ptr = 0, *data = 0; - int flags; - - assert(frame); - - if ((frame->flags & ID3_FRAME_FLAG_TAGALTERPRESERVATION) || - ((options & ID3_TAG_OPTION_FILEALTERED) && - (frame->flags & ID3_FRAME_FLAG_FILEALTERPRESERVATION))) - return 0; - - /* a frame must be at least 1 byte big, excluding the header */ - - decoded_length = render_data(0, frame->fields, frame->nfields); - if (decoded_length == 0 && frame->encoded == 0) - return 0; - - /* header */ - - size += id3_render_immediate(ptr, frame->id, 4); - - if (ptr) - size_ptr = *ptr; - - size += id3_render_syncsafe(ptr, 0, 4); - - if (ptr) - flags_ptr = *ptr; - - flags = frame->flags; - - size += id3_render_int(ptr, flags, 2); - - if (flags & (ID3_FRAME_FLAG_FORMATFLAGS & ~ID3_FRAME_FLAG_KNOWNFLAGS)) { - size += id3_render_binary(ptr, frame->encoded, frame->encoded_length); - if (size_ptr) { - if (options & ID3_TAG_OPTION_ID3V2_3) - id3_render_int(&size_ptr, size - 10, 4); - else - id3_render_syncsafe(&size_ptr, size - 10, 4); - } - - return size; - } - - flags &= ID3_FRAME_FLAG_KNOWNFLAGS; - - flags &= ~ID3_FRAME_FLAG_UNSYNCHRONISATION; - if (options & ID3_TAG_OPTION_UNSYNCHRONISATION) - flags |= ID3_FRAME_FLAG_UNSYNCHRONISATION; - - if (!(flags & ID3_FRAME_FLAG_ENCRYPTION)) { - flags &= ~ID3_FRAME_FLAG_COMPRESSION; - if (options & ID3_TAG_OPTION_COMPRESSION) - flags |= ID3_FRAME_FLAG_COMPRESSION | ID3_FRAME_FLAG_DATALENGTHINDICATOR; - } - - if (flags & ID3_FRAME_FLAG_GROUPINGIDENTITY) - size += id3_render_int(ptr, frame->group_id, 1); - if (flags & ID3_FRAME_FLAG_ENCRYPTION) - size += id3_render_int(ptr, frame->encryption_method, 1); - if (flags & ID3_FRAME_FLAG_DATALENGTHINDICATOR) { - if (flags & ID3_FRAME_FLAG_ENCRYPTION) - decoded_length = frame->decoded_length; - size += id3_render_syncsafe(ptr, decoded_length, 4); - } - - if (ptr) - data = *ptr; - - if (flags & ID3_FRAME_FLAG_ENCRYPTION) - datalen = id3_render_binary(ptr, frame->encoded, frame->encoded_length); - else { - if (ptr == 0) - datalen = decoded_length; - else { - datalen = render_data(ptr, frame->fields, frame->nfields); - - if (flags & ID3_FRAME_FLAG_COMPRESSION) { - id3_byte_t *comp; - id3_length_t complen; - - comp = id3_util_compress(data, datalen, &complen); - if (comp == 0) - flags &= ~ID3_FRAME_FLAG_COMPRESSION; - else { - *ptr = data; - datalen = id3_render_binary(ptr, comp, complen); - - free(comp); - } - } - } - } - - /* unsynchronisation */ - - if (flags & ID3_FRAME_FLAG_UNSYNCHRONISATION) { - if (data == 0) - datalen *= 2; - else { - id3_length_t newlen; - - newlen = id3_util_unsynchronise(data, datalen); - if (newlen == datalen) - flags &= ~ID3_FRAME_FLAG_UNSYNCHRONISATION; - else { - *ptr += newlen - datalen; - datalen = newlen; - } - } - } - - size += datalen; - - /* patch size and flags */ - - if (size_ptr) { - if (options & ID3_TAG_OPTION_ID3V2_3) - id3_render_int(&size_ptr, size - 10, 4); - else - id3_render_syncsafe(&size_ptr, size - 10, 4); - } - if (flags_ptr) - id3_render_int(&flags_ptr, flags, 2); - - return size; -} diff --git a/lib-src/libid3tag/frame.h b/lib-src/libid3tag/frame.h deleted file mode 100644 index 6d79a8a0c..000000000 --- a/lib-src/libid3tag/frame.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frame.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_FRAME_H -# define LIBID3TAG_FRAME_H - -# include "id3tag.h" - -int id3_frame_validid(char const *); - -void id3_frame_addref(struct id3_frame *); -void id3_frame_delref(struct id3_frame *); - -struct id3_frame *id3_frame_parse(id3_byte_t const **, id3_length_t, - unsigned int); -id3_length_t id3_frame_render(struct id3_frame const *, id3_byte_t **, int); - -# endif diff --git a/lib-src/libid3tag/frametype.c b/lib-src/libid3tag/frametype.c deleted file mode 100644 index 5e5f12ebc..000000000 --- a/lib-src/libid3tag/frametype.c +++ /dev/null @@ -1,571 +0,0 @@ -/* C code produced by gperf version 3.0.3 */ -/* Command-line: gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' frametype.gperf */ - -#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ - && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ - && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ - && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ - && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ - && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ - && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ - && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ - && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ - && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ - && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ - && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ - && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ - && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ - && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ - && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ - && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ - && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ - && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ - && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ - && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ - && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ - && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) -/* The character set is not based on ISO-646. */ -error "gperf generated tables don't work with this execution character set. Please report a bug to ." -#endif - -#line 1 "frametype.gperf" - -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Id: frametype.gperf,v 1.3 2004/06/08 06:38:15 dmazzoni Exp - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "frametype.h" - -# define FIELDS(id) static enum id3_field_type const fields_##id[] - -/* frame field descriptions */ - -FIELDS(UFID) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(TXXX) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(WXXX) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_LATIN1 -}; - -FIELDS(MCDI) = { - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ETCO) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(MLLT) = { - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SYTC) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(USLT) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRINGFULL -}; - -FIELDS(SYLT) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(COMM) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRINGFULL -}; - -FIELDS(RVA2) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(EQU2) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(RVRB) = { - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8 -}; - -FIELDS(APIC) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(GEOB) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(PCNT) = { - ID3_FIELD_TYPE_INT32PLUS -}; - -FIELDS(POPM) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT32PLUS -}; - -FIELDS(RBUF) = { - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT32 -}; - -FIELDS(AENC) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(LINK) = { - ID3_FIELD_TYPE_FRAMEID, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_LATIN1LIST -}; - -FIELDS(POSS) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(USER) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(OWNE) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_DATE, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(COMR) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_DATE, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ENCR) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(GRID) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(PRIV) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SIGN) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SEEK) = { - ID3_FIELD_TYPE_INT32 -}; - -FIELDS(ASPI) = { - ID3_FIELD_TYPE_INT32, - ID3_FIELD_TYPE_INT32, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(text) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRINGLIST -}; - -FIELDS(url) = { - ID3_FIELD_TYPE_LATIN1 -}; - -FIELDS(unknown) = { - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ZOBS) = { - ID3_FIELD_TYPE_FRAMEID, - ID3_FIELD_TYPE_BINARYDATA -}; - -# define FRAME(id) \ - sizeof(fields_##id) / sizeof(fields_##id[0]), fields_##id - -# define PRESERVE 0 -# define DISCARD ID3_FRAME_FLAG_FILEALTERPRESERVATION -# define OBSOLETE (DISCARD | ID3_FRAME_FLAG_TAGALTERPRESERVATION) - -# define FRAMETYPE(type, id, flags, desc) \ - struct id3_frametype const id3_frametype_##type = { \ - 0, FRAME(id), flags, desc \ - } - -/* static frame types */ - -FRAMETYPE(text, text, PRESERVE, "Unknown text information frame"); -FRAMETYPE(url, url, PRESERVE, "Unknown URL link frame"); -FRAMETYPE(experimental, unknown, PRESERVE, "Experimental frame"); -FRAMETYPE(unknown, unknown, PRESERVE, "Unknown frame"); -FRAMETYPE(obsolete, unknown, OBSOLETE, "Obsolete frame"); - -#define TOTAL_KEYWORDS 84 -#define MIN_WORD_LENGTH 4 -#define MAX_WORD_LENGTH 4 -#define MIN_HASH_VALUE 7 -#define MAX_HASH_VALUE 155 -/* maximum key range = 149, duplicates = 0 */ - -#ifdef __GNUC__ -__inline -#else -#ifdef __cplusplus -inline -#endif -#endif -static unsigned int -hash (str, len) - register const char *str; - register unsigned int len; -{ - static const unsigned char asso_values[] = - { - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 43, 4, 47, 49, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 31, 53, 3, 15, 3, - 24, 25, 10, 52, 69, 34, 23, 30, 1, 5, - 10, 62, 20, 0, 28, 28, 22, 19, 47, 3, - 10, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, - 156, 156, 156, 156, 156, 156, 156 - }; - return asso_values[(unsigned char)str[3]+1] + asso_values[(unsigned char)str[2]] + asso_values[(unsigned char)str[1]] + asso_values[(unsigned char)str[0]]; -} - -#ifdef __GNUC__ -__inline -#ifdef __GNUC_STDC_INLINE__ -__attribute__ ((__gnu_inline__)) -#endif -#endif -const struct id3_frametype * -id3_frametype_lookup (str, len) - register const char *str; - register unsigned int len; -{ - static const struct id3_frametype wordlist[] = - { -#line 282 "frametype.gperf" - {"ENCR", FRAME(ENCR), PRESERVE, "Encryption method registration"}, -#line 292 "frametype.gperf" - {"POPM", FRAME(POPM), PRESERVE, "Popularimeter"}, -#line 351 "frametype.gperf" - {"WCOM", FRAME(url), PRESERVE, "Commercial information"}, -#line 298 "frametype.gperf" - {"SEEK", FRAME(SEEK), DISCARD, "Seek frame"}, -#line 349 "frametype.gperf" - {"USER", FRAME(USER), PRESERVE, "Terms of use"}, -#line 285 "frametype.gperf" - {"GEOB", FRAME(GEOB), PRESERVE, "General encapsulated object"}, -#line 304 "frametype.gperf" - {"TCOM", FRAME(text), PRESERVE, "Composer"}, -#line 281 "frametype.gperf" - {"COMR", FRAME(COMR), PRESERVE, "Commercial frame"}, -#line 280 "frametype.gperf" - {"COMM", FRAME(COMM), PRESERVE, "Comments"}, -#line 305 "frametype.gperf" - {"TCON", FRAME(text), PRESERVE, "Content type"}, -#line 291 "frametype.gperf" - {"PCNT", FRAME(PCNT), PRESERVE, "Play counter"}, -#line 293 "frametype.gperf" - {"POSS", FRAME(POSS), DISCARD, "Position synchronisation frame"}, -#line 284 "frametype.gperf" - {"ETCO", FRAME(ETCO), DISCARD, "Event timing codes"}, -#line 332 "frametype.gperf" - {"TPE2", FRAME(text), PRESERVE, "Band/orchestra/accompaniment"}, -#line 301 "frametype.gperf" - {"SYTC", FRAME(SYTC), DISCARD, "Synchronised tempo codes"}, -#line 313 "frametype.gperf" - {"TENC", FRAME(text), DISCARD, "Encoded by"}, -#line 309 "frametype.gperf" - {"TDOR", FRAME(text), PRESERVE, "Original release time"}, -#line 290 "frametype.gperf" - {"OWNE", FRAME(OWNE), PRESERVE, "Ownership frame"}, -#line 277 "frametype.gperf" - {"AENC", FRAME(AENC), DISCARD, "Audio encryption"}, -#line 307 "frametype.gperf" - {"TDEN", FRAME(text), PRESERVE, "Encoding time"}, -#line 345 "frametype.gperf" - {"TSSE", FRAME(text), PRESERVE, "Software/hardware and settings used for encoding"}, -#line 339 "frametype.gperf" - {"TRSN", FRAME(text), PRESERVE, "Internet radio station name"}, -#line 300 "frametype.gperf" - {"SYLT", FRAME(SYLT), DISCARD, "Synchronised lyric/text"}, -#line 354 "frametype.gperf" - {"WOAR", FRAME(url), PRESERVE, "Official artist/performer webpage"}, -#line 346 "frametype.gperf" - {"TSST", FRAME(text), PRESERVE, "Set subtitle"}, -#line 330 "frametype.gperf" - {"TOWN", FRAME(text), PRESERVE, "File owner/licensee"}, -#line 340 "frametype.gperf" - {"TRSO", FRAME(text), PRESERVE, "Internet radio station owner"}, -#line 322 "frametype.gperf" - {"TLEN", FRAME(text), DISCARD, "Length"}, -#line 358 "frametype.gperf" - {"WPUB", FRAME(url), PRESERVE, "Publishers official webpage"}, -#line 343 "frametype.gperf" - {"TSOT", FRAME(text), PRESERVE, "Title sort order"}, -#line 327 "frametype.gperf" - {"TOFN", FRAME(text), PRESERVE, "Original filename"}, -#line 344 "frametype.gperf" - {"TSRC", FRAME(text), PRESERVE, "ISRC (international standard recording code)"}, -#line 324 "frametype.gperf" - {"TMED", FRAME(text), PRESERVE, "Media type"}, -#line 297 "frametype.gperf" - {"RVRB", FRAME(RVRB), PRESERVE, "Reverb"}, -#line 328 "frametype.gperf" - {"TOLY", FRAME(text), PRESERVE, "Original lyricist(s)/text writer(s)"}, -#line 329 "frametype.gperf" - {"TOPE", FRAME(text), PRESERVE, "Original artist(s)/performer(s)"}, -#line 336 "frametype.gperf" - {"TPRO", FRAME(text), PRESERVE, "Produced notice"}, -#line 337 "frametype.gperf" - {"TPUB", FRAME(text), PRESERVE, "Publisher"}, -#line 357 "frametype.gperf" - {"WPAY", FRAME(url), PRESERVE, "Payment"}, -#line 335 "frametype.gperf" - {"TPOS", FRAME(text), PRESERVE, "Part of a set"}, -#line 356 "frametype.gperf" - {"WORS", FRAME(url), PRESERVE, "Official Internet radio station homepage"}, -#line 325 "frametype.gperf" - {"TMOO", FRAME(text), PRESERVE, "Mood"}, -#line 338 "frametype.gperf" - {"TRCK", FRAME(text), PRESERVE, "Track number/position in set"}, -#line 320 "frametype.gperf" - {"TKEY", FRAME(text), PRESERVE, "Initial key"}, -#line 308 "frametype.gperf" - {"TDLY", FRAME(text), PRESERVE, "Playlist delay"}, -#line 296 "frametype.gperf" - {"RVA2", FRAME(RVA2), DISCARD, "Relative volume adjustment (2)"}, -#line 310 "frametype.gperf" - {"TDRC", FRAME(text), PRESERVE, "Recording time"}, -#line 350 "frametype.gperf" - {"USLT", FRAME(USLT), PRESERVE, "Unsynchronised lyric/text transcription"}, -#line 353 "frametype.gperf" - {"WOAF", FRAME(url), PRESERVE, "Official audio file webpage"}, -#line 312 "frametype.gperf" - {"TDTG", FRAME(text), PRESERVE, "Tagging time"}, -#line 299 "frametype.gperf" - {"SIGN", FRAME(SIGN), PRESERVE, "Signature frame"}, -#line 355 "frametype.gperf" - {"WOAS", FRAME(url), PRESERVE, "Official audio source webpage"}, -#line 331 "frametype.gperf" - {"TPE1", FRAME(text), PRESERVE, "Lead performer(s)/soloist(s)"}, -#line 302 "frametype.gperf" - {"TALB", FRAME(text), PRESERVE, "Album/movie/show title"}, -#line 341 "frametype.gperf" - {"TSOA", FRAME(text), PRESERVE, "Album sort order"}, -#line 321 "frametype.gperf" - {"TLAN", FRAME(text), PRESERVE, "Language(s)"}, -#line 333 "frametype.gperf" - {"TPE3", FRAME(text), PRESERVE, "Conductor/performer refinement"}, -#line 352 "frametype.gperf" - {"WCOP", FRAME(url), PRESERVE, "Copyright/legal information"}, -#line 334 "frametype.gperf" - {"TPE4", FRAME(text), PRESERVE, "Interpreted, remixed, or otherwise modified by"}, -#line 323 "frametype.gperf" - {"TMCL", FRAME(text), PRESERVE, "Musician credits list"}, -#line 303 "frametype.gperf" - {"TBPM", FRAME(text), PRESERVE, "BPM (beats per minute)"}, -#line 311 "frametype.gperf" - {"TDRL", FRAME(text), PRESERVE, "Release time"}, -#line 326 "frametype.gperf" - {"TOAL", FRAME(text), PRESERVE, "Original album/movie/show title"}, -#line 342 "frametype.gperf" - {"TSOP", FRAME(text), PRESERVE, "Performer sort order"}, -#line 363 "frametype.gperf" - {"ZOBS", FRAME(ZOBS), OBSOLETE, "Obsolete frame"}, -#line 283 "frametype.gperf" - {"EQU2", FRAME(EQU2), DISCARD, "Equalisation (2)"}, -#line 306 "frametype.gperf" - {"TCOP", FRAME(text), PRESERVE, "Copyright message"}, -#line 287 "frametype.gperf" - {"LINK", FRAME(LINK), PRESERVE, "Linked information"}, -#line 286 "frametype.gperf" - {"GRID", FRAME(GRID), PRESERVE, "Group identification registration"}, -#line 294 "frametype.gperf" - {"PRIV", FRAME(PRIV), PRESERVE, "Private frame"}, -#line 315 "frametype.gperf" - {"TFLT", FRAME(text), PRESERVE, "File type"}, -#line 289 "frametype.gperf" - {"MLLT", FRAME(MLLT), DISCARD, "MPEG location lookup table"}, -#line 314 "frametype.gperf" - {"TEXT", FRAME(text), PRESERVE, "Lyricist/text writer"}, -#line 348 "frametype.gperf" - {"UFID", FRAME(UFID), PRESERVE, "Unique file identifier"}, -#line 278 "frametype.gperf" - {"APIC", FRAME(APIC), PRESERVE, "Attached picture"}, -#line 279 "frametype.gperf" - {"ASPI", FRAME(ASPI), DISCARD, "Audio seek point index"}, -#line 318 "frametype.gperf" - {"TIT2", FRAME(text), PRESERVE, "Title/songname/content description"}, -#line 359 "frametype.gperf" - {"WXXX", FRAME(WXXX), PRESERVE, "User defined URL link frame"}, -#line 288 "frametype.gperf" - {"MCDI", FRAME(MCDI), PRESERVE, "Music CD identifier"}, -#line 316 "frametype.gperf" - {"TIPL", FRAME(text), PRESERVE, "Involved people list"}, -#line 347 "frametype.gperf" - {"TXXX", FRAME(TXXX), PRESERVE, "User defined text information frame"}, -#line 295 "frametype.gperf" - {"RBUF", FRAME(RBUF), PRESERVE, "Recommended buffer size"}, -#line 317 "frametype.gperf" - {"TIT1", FRAME(text), PRESERVE, "Content group description"}, -#line 319 "frametype.gperf" - {"TIT3", FRAME(text), PRESERVE, "Subtitle/description refinement"} - }; - - static const short lookup[] = - { - -1, -1, -1, -1, -1, -1, -1, 0, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 1, -1, - 2, 3, -1, 4, -1, -1, -1, -1, 5, 6, 7, 8, -1, 9, - 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, -1, 70, 71, -1, 72, 73, 74, -1, 75, -1, - 76, -1, -1, -1, 77, 78, -1, -1, 79, -1, -1, -1, -1, 80, - 81, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 82, -1, -1, - -1, 83 - }; - - if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) - { - register int key = hash (str, len); - - if (key <= MAX_HASH_VALUE && key >= 0) - { - register int index = lookup[key]; - - if (index >= 0) - { - register const char *s = wordlist[index].id; - - if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') - return &wordlist[index]; - } - } - } - return 0; -} diff --git a/lib-src/libid3tag/frametype.gperf b/lib-src/libid3tag/frametype.gperf deleted file mode 100644 index 806562086..000000000 --- a/lib-src/libid3tag/frametype.gperf +++ /dev/null @@ -1,363 +0,0 @@ -%{ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frametype.gperf,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "frametype.h" - -# define FIELDS(id) static enum id3_field_type const fields_##id[] - -/* frame field descriptions */ - -FIELDS(UFID) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(TXXX) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(WXXX) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_LATIN1 -}; - -FIELDS(MCDI) = { - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ETCO) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(MLLT) = { - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SYTC) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(USLT) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRINGFULL -}; - -FIELDS(SYLT) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(COMM) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRINGFULL -}; - -FIELDS(RVA2) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(EQU2) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(RVRB) = { - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT8 -}; - -FIELDS(APIC) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(GEOB) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(PCNT) = { - ID3_FIELD_TYPE_INT32PLUS -}; - -FIELDS(POPM) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT32PLUS -}; - -FIELDS(RBUF) = { - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT32 -}; - -FIELDS(AENC) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(LINK) = { - ID3_FIELD_TYPE_FRAMEID, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_LATIN1LIST -}; - -FIELDS(POSS) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(USER) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(OWNE) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_DATE, - ID3_FIELD_TYPE_STRING -}; - -FIELDS(COMR) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_DATE, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ENCR) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(GRID) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(PRIV) = { - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SIGN) = { - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(SEEK) = { - ID3_FIELD_TYPE_INT32 -}; - -FIELDS(ASPI) = { - ID3_FIELD_TYPE_INT32, - ID3_FIELD_TYPE_INT32, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(text) = { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_STRINGLIST -}; - -FIELDS(url) = { - ID3_FIELD_TYPE_LATIN1 -}; - -FIELDS(unknown) = { - ID3_FIELD_TYPE_BINARYDATA -}; - -FIELDS(ZOBS) = { - ID3_FIELD_TYPE_FRAMEID, - ID3_FIELD_TYPE_BINARYDATA -}; - -# define FRAME(id) \ - sizeof(fields_##id) / sizeof(fields_##id[0]), fields_##id - -# define PRESERVE 0 -# define DISCARD ID3_FRAME_FLAG_FILEALTERPRESERVATION -# define OBSOLETE (DISCARD | ID3_FRAME_FLAG_TAGALTERPRESERVATION) - -# define FRAMETYPE(type, id, flags, desc) \ - struct id3_frametype const id3_frametype_##type = { \ - 0, FRAME(id), flags, desc \ - } - -/* static frame types */ - -FRAMETYPE(text, text, PRESERVE, "Unknown text information frame"); -FRAMETYPE(url, url, PRESERVE, "Unknown URL link frame"); -FRAMETYPE(experimental, unknown, PRESERVE, "Experimental frame"); -FRAMETYPE(unknown, unknown, PRESERVE, "Unknown frame"); -FRAMETYPE(obsolete, unknown, OBSOLETE, "Obsolete frame"); -%} -struct id3_frametype; -%% -# -# ID3v2.4 frames -# -AENC, FRAME(AENC), DISCARD, "Audio encryption" -APIC, FRAME(APIC), PRESERVE, "Attached picture" -ASPI, FRAME(ASPI), DISCARD, "Audio seek point index" -COMM, FRAME(COMM), PRESERVE, "Comments" -COMR, FRAME(COMR), PRESERVE, "Commercial frame" -ENCR, FRAME(ENCR), PRESERVE, "Encryption method registration" -EQU2, FRAME(EQU2), DISCARD, "Equalisation (2)" -ETCO, FRAME(ETCO), DISCARD, "Event timing codes" -GEOB, FRAME(GEOB), PRESERVE, "General encapsulated object" -GRID, FRAME(GRID), PRESERVE, "Group identification registration" -LINK, FRAME(LINK), PRESERVE, "Linked information" -MCDI, FRAME(MCDI), PRESERVE, "Music CD identifier" -MLLT, FRAME(MLLT), DISCARD, "MPEG location lookup table" -OWNE, FRAME(OWNE), PRESERVE, "Ownership frame" -PCNT, FRAME(PCNT), PRESERVE, "Play counter" -POPM, FRAME(POPM), PRESERVE, "Popularimeter" -POSS, FRAME(POSS), DISCARD, "Position synchronisation frame" -PRIV, FRAME(PRIV), PRESERVE, "Private frame" -RBUF, FRAME(RBUF), PRESERVE, "Recommended buffer size" -RVA2, FRAME(RVA2), DISCARD, "Relative volume adjustment (2)" -RVRB, FRAME(RVRB), PRESERVE, "Reverb" -SEEK, FRAME(SEEK), DISCARD, "Seek frame" -SIGN, FRAME(SIGN), PRESERVE, "Signature frame" -SYLT, FRAME(SYLT), DISCARD, "Synchronised lyric/text" -SYTC, FRAME(SYTC), DISCARD, "Synchronised tempo codes" -TALB, FRAME(text), PRESERVE, "Album/movie/show title" -TBPM, FRAME(text), PRESERVE, "BPM (beats per minute)" -TCOM, FRAME(text), PRESERVE, "Composer" -TCON, FRAME(text), PRESERVE, "Content type" -TCOP, FRAME(text), PRESERVE, "Copyright message" -TDEN, FRAME(text), PRESERVE, "Encoding time" -TDLY, FRAME(text), PRESERVE, "Playlist delay" -TDOR, FRAME(text), PRESERVE, "Original release time" -TDRC, FRAME(text), PRESERVE, "Recording time" -TDRL, FRAME(text), PRESERVE, "Release time" -TDTG, FRAME(text), PRESERVE, "Tagging time" -TENC, FRAME(text), DISCARD, "Encoded by" -TEXT, FRAME(text), PRESERVE, "Lyricist/text writer" -TFLT, FRAME(text), PRESERVE, "File type" -TIPL, FRAME(text), PRESERVE, "Involved people list" -TIT1, FRAME(text), PRESERVE, "Content group description" -TIT2, FRAME(text), PRESERVE, "Title/songname/content description" -TIT3, FRAME(text), PRESERVE, "Subtitle/description refinement" -TKEY, FRAME(text), PRESERVE, "Initial key" -TLAN, FRAME(text), PRESERVE, "Language(s)" -TLEN, FRAME(text), DISCARD, "Length" -TMCL, FRAME(text), PRESERVE, "Musician credits list" -TMED, FRAME(text), PRESERVE, "Media type" -TMOO, FRAME(text), PRESERVE, "Mood" -TOAL, FRAME(text), PRESERVE, "Original album/movie/show title" -TOFN, FRAME(text), PRESERVE, "Original filename" -TOLY, FRAME(text), PRESERVE, "Original lyricist(s)/text writer(s)" -TOPE, FRAME(text), PRESERVE, "Original artist(s)/performer(s)" -TOWN, FRAME(text), PRESERVE, "File owner/licensee" -TPE1, FRAME(text), PRESERVE, "Lead performer(s)/soloist(s)" -TPE2, FRAME(text), PRESERVE, "Band/orchestra/accompaniment" -TPE3, FRAME(text), PRESERVE, "Conductor/performer refinement" -TPE4, FRAME(text), PRESERVE, "Interpreted, remixed, or otherwise modified by" -TPOS, FRAME(text), PRESERVE, "Part of a set" -TPRO, FRAME(text), PRESERVE, "Produced notice" -TPUB, FRAME(text), PRESERVE, "Publisher" -TRCK, FRAME(text), PRESERVE, "Track number/position in set" -TRSN, FRAME(text), PRESERVE, "Internet radio station name" -TRSO, FRAME(text), PRESERVE, "Internet radio station owner" -TSOA, FRAME(text), PRESERVE, "Album sort order" -TSOP, FRAME(text), PRESERVE, "Performer sort order" -TSOT, FRAME(text), PRESERVE, "Title sort order" -TSRC, FRAME(text), PRESERVE, "ISRC (international standard recording code)" -TSSE, FRAME(text), PRESERVE, "Software/hardware and settings used for encoding" -TSST, FRAME(text), PRESERVE, "Set subtitle" -TXXX, FRAME(TXXX), PRESERVE, "User defined text information frame" -UFID, FRAME(UFID), PRESERVE, "Unique file identifier" -USER, FRAME(USER), PRESERVE, "Terms of use" -USLT, FRAME(USLT), PRESERVE, "Unsynchronised lyric/text transcription" -WCOM, FRAME(url), PRESERVE, "Commercial information" -WCOP, FRAME(url), PRESERVE, "Copyright/legal information" -WOAF, FRAME(url), PRESERVE, "Official audio file webpage" -WOAR, FRAME(url), PRESERVE, "Official artist/performer webpage" -WOAS, FRAME(url), PRESERVE, "Official audio source webpage" -WORS, FRAME(url), PRESERVE, "Official Internet radio station homepage" -WPAY, FRAME(url), PRESERVE, "Payment" -WPUB, FRAME(url), PRESERVE, "Publishers official webpage" -WXXX, FRAME(WXXX), PRESERVE, "User defined URL link frame" -# -# Special frames -# -ZOBS, FRAME(ZOBS), OBSOLETE, "Obsolete frame" diff --git a/lib-src/libid3tag/frametype.h b/lib-src/libid3tag/frametype.h deleted file mode 100644 index fe0b8c757..000000000 --- a/lib-src/libid3tag/frametype.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frametype.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_FRAMETYPE_H -# define LIBID3TAG_FRAMETYPE_H - -struct id3_frametype { - char const *id; - unsigned int nfields; - enum id3_field_type const *fields; - int defaultflags; - char const *description; -}; - -extern struct id3_frametype const id3_frametype_text; -extern struct id3_frametype const id3_frametype_url; -extern struct id3_frametype const id3_frametype_experimental; -extern struct id3_frametype const id3_frametype_unknown; -extern struct id3_frametype const id3_frametype_obsolete; - -struct id3_frametype const *id3_frametype_lookup(register char const *, - register unsigned int); - -# endif diff --git a/lib-src/libid3tag/genre.c b/lib-src/libid3tag/genre.c deleted file mode 100644 index 6a5a7c122..000000000 --- a/lib-src/libid3tag/genre.c +++ /dev/null @@ -1,151 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: genre.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "id3tag.h" -# include "ucs4.h" - -/* genres are stored in ucs4 format */ -# include "genre.dat" - -# define NGENRES (sizeof(genre_table) / sizeof(genre_table[0])) - -/* - * NAME: genre->index() - * DESCRIPTION: return an ID3v1 genre string indexed by number - */ -id3_ucs4_t const *id3_genre_index(unsigned int index) -{ - return (index < NGENRES) ? genre_table[index] : 0; -} - -/* - * NAME: genre->name() - * DESCRIPTION: translate an ID3v2 genre number/keyword to its full name - */ -id3_ucs4_t const *id3_genre_name(id3_ucs4_t const *string) -{ - id3_ucs4_t const *ptr; - static id3_ucs4_t const genre_remix[] = { 'R', 'e', 'm', 'i', 'x', 0 }; - static id3_ucs4_t const genre_cover[] = { 'C', 'o', 'v', 'e', 'r', 0 }; - unsigned long number; - - if (string == 0 || *string == 0) - return id3_ucs4_empty; - - if (string[0] == 'R' && string[1] == 'X' && string[2] == 0) - return genre_remix; - if (string[0] == 'C' && string[1] == 'R' && string[2] == 0) - return genre_cover; - - for (ptr = string; *ptr; ++ptr) { - if (*ptr < '0' || *ptr > '9') - return string; - } - - number = id3_ucs4_getnumber(string); - - return (number < NGENRES) ? genre_table[number] : string; -} - -/* - * NAME: translate() - * DESCRIPTION: return a canonicalized character for testing genre equivalence - */ -static -id3_ucs4_t translate(id3_ucs4_t ch) -{ - if (ch) { - if (ch >= 'A' && ch <= 'Z') - ch += 'a' - 'A'; - - if (ch < 'a' || ch > 'z') - ch = ID3_UCS4_REPLACEMENTCHAR; - } - - return ch; -} - -/* - * NAME: compare() - * DESCRIPTION: test two ucs4 genre strings for equivalence - */ -static -int compare(id3_ucs4_t const *str1, id3_ucs4_t const *str2) -{ - id3_ucs4_t c1, c2; - - if (str1 == str2) - return 1; - - do { - do - c1 = translate(*str1++); - while (c1 == ID3_UCS4_REPLACEMENTCHAR); - - do - c2 = translate(*str2++); - while (c2 == ID3_UCS4_REPLACEMENTCHAR); - } - while (c1 && c1 == c2); - - return c1 == c2; -} - -/* - * NAME: genre->number() - * DESCRIPTION: translate an ID3v2 genre name/number to its ID3v1 index number - */ -int id3_genre_number(id3_ucs4_t const *string) -{ - id3_ucs4_t const *ptr; - int i; - - if (string == 0 || *string == 0) - return -1; - - for (ptr = string; *ptr; ++ptr) { - if (*ptr < '0' || *ptr > '9') - break; - } - - if (*ptr == 0) { - unsigned long number; - - number = id3_ucs4_getnumber(string); - - return (number <= 0xff) ? number : -1; - } - - for (i = 0; i < NGENRES; ++i) { - if (compare(string, genre_table[i])) - return i; - } - - /* no equivalent */ - - return -1; -} diff --git a/lib-src/libid3tag/genre.dat b/lib-src/libid3tag/genre.dat deleted file mode 100644 index 5eafdf2f7..000000000 --- a/lib-src/libid3tag/genre.dat +++ /dev/null @@ -1,480 +0,0 @@ -/* Automatically generated from genre.dat.in */ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Id: genre.dat.in,v 1.3 2004/06/08 06:38:15 dmazzoni Exp - */ - -/* - * These are the ID3 genre names, taken as a combination of names from ID3v1 - * (listed in Appendix A of the ID3 tag version 2.4.0 informal standard) and - * the extensions made by Winamp as of version 2.80. - */ - -/* ID3v1 names (0-79) */ - -static id3_ucs4_t const genre_BLUES[] = - { 'B', 'l', 'u', 'e', 's', 0 }; -static id3_ucs4_t const genre_CLASSIC_ROCK[] = - { 'C', 'l', 'a', 's', 's', 'i', 'c', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_COUNTRY[] = - { 'C', 'o', 'u', 'n', 't', 'r', 'y', 0 }; -static id3_ucs4_t const genre_DANCE[] = - { 'D', 'a', 'n', 'c', 'e', 0 }; -static id3_ucs4_t const genre_DISCO[] = - { 'D', 'i', 's', 'c', 'o', 0 }; -static id3_ucs4_t const genre_FUNK[] = - { 'F', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_GRUNGE[] = - { 'G', 'r', 'u', 'n', 'g', 'e', 0 }; -static id3_ucs4_t const genre_HIP_HOP[] = - { 'H', 'i', 'p', '-', 'H', 'o', 'p', 0 }; -static id3_ucs4_t const genre_JAZZ[] = - { 'J', 'a', 'z', 'z', 0 }; -static id3_ucs4_t const genre_METAL[] = - { 'M', 'e', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_NEW_AGE[] = - { 'N', 'e', 'w', ' ', 'A', 'g', 'e', 0 }; -static id3_ucs4_t const genre_OLDIES[] = - { 'O', 'l', 'd', 'i', 'e', 's', 0 }; -static id3_ucs4_t const genre_OTHER[] = - { 'O', 't', 'h', 'e', 'r', 0 }; -static id3_ucs4_t const genre_POP[] = - { 'P', 'o', 'p', 0 }; -static id3_ucs4_t const genre_R_B[] = - { 'R', '&', 'B', 0 }; -static id3_ucs4_t const genre_RAP[] = - { 'R', 'a', 'p', 0 }; -static id3_ucs4_t const genre_REGGAE[] = - { 'R', 'e', 'g', 'g', 'a', 'e', 0 }; -static id3_ucs4_t const genre_ROCK[] = - { 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_TECHNO[] = - { 'T', 'e', 'c', 'h', 'n', 'o', 0 }; -static id3_ucs4_t const genre_INDUSTRIAL[] = - { 'I', 'n', 'd', 'u', 's', 't', 'r', 'i', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ALTERNATIVE[] = - { 'A', 'l', 't', 'e', 'r', 'n', 'a', 't', 'i', 'v', 'e', 0 }; -static id3_ucs4_t const genre_SKA[] = - { 'S', 'k', 'a', 0 }; -static id3_ucs4_t const genre_DEATH_METAL[] = - { 'D', 'e', 'a', 't', 'h', ' ', 'M', 'e', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_PRANKS[] = - { 'P', 'r', 'a', 'n', 'k', 's', 0 }; -static id3_ucs4_t const genre_SOUNDTRACK[] = - { 'S', 'o', 'u', 'n', 'd', 't', 'r', 'a', 'c', 'k', 0 }; -static id3_ucs4_t const genre_EURO_TECHNO[] = - { 'E', 'u', 'r', 'o', '-', 'T', 'e', 'c', 'h', 'n', 'o', 0 }; -static id3_ucs4_t const genre_AMBIENT[] = - { 'A', 'm', 'b', 'i', 'e', 'n', 't', 0 }; -static id3_ucs4_t const genre_TRIP_HOP[] = - { 'T', 'r', 'i', 'p', '-', 'H', 'o', 'p', 0 }; -static id3_ucs4_t const genre_VOCAL[] = - { 'V', 'o', 'c', 'a', 'l', 0 }; -static id3_ucs4_t const genre_JAZZ_FUNK[] = - { 'J', 'a', 'z', 'z', '+', 'F', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_FUSION[] = - { 'F', 'u', 's', 'i', 'o', 'n', 0 }; -static id3_ucs4_t const genre_TRANCE[] = - { 'T', 'r', 'a', 'n', 'c', 'e', 0 }; -static id3_ucs4_t const genre_CLASSICAL[] = - { 'C', 'l', 'a', 's', 's', 'i', 'c', 'a', 'l', 0 }; -static id3_ucs4_t const genre_INSTRUMENTAL[] = - { 'I', 'n', 's', 't', 'r', 'u', 'm', 'e', 'n', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ACID[] = - { 'A', 'c', 'i', 'd', 0 }; -static id3_ucs4_t const genre_HOUSE[] = - { 'H', 'o', 'u', 's', 'e', 0 }; -static id3_ucs4_t const genre_GAME[] = - { 'G', 'a', 'm', 'e', 0 }; -static id3_ucs4_t const genre_SOUND_CLIP[] = - { 'S', 'o', 'u', 'n', 'd', ' ', 'C', 'l', 'i', 'p', 0 }; -static id3_ucs4_t const genre_GOSPEL[] = - { 'G', 'o', 's', 'p', 'e', 'l', 0 }; -static id3_ucs4_t const genre_NOISE[] = - { 'N', 'o', 'i', 's', 'e', 0 }; -static id3_ucs4_t const genre_ALTERNROCK[] = - { 'A', 'l', 't', 'e', 'r', 'n', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_BASS[] = - { 'B', 'a', 's', 's', 0 }; -static id3_ucs4_t const genre_SOUL[] = - { 'S', 'o', 'u', 'l', 0 }; -static id3_ucs4_t const genre_PUNK[] = - { 'P', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_SPACE[] = - { 'S', 'p', 'a', 'c', 'e', 0 }; -static id3_ucs4_t const genre_MEDITATIVE[] = - { 'M', 'e', 'd', 'i', 't', 'a', 't', 'i', 'v', 'e', 0 }; -static id3_ucs4_t const genre_INSTRUMENTAL_POP[] = - { 'I', 'n', 's', 't', 'r', 'u', 'm', 'e', 'n', 't', 'a', 'l', ' ', 'P', 'o', 'p', 0 }; -static id3_ucs4_t const genre_INSTRUMENTAL_ROCK[] = - { 'I', 'n', 's', 't', 'r', 'u', 'm', 'e', 'n', 't', 'a', 'l', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_ETHNIC[] = - { 'E', 't', 'h', 'n', 'i', 'c', 0 }; -static id3_ucs4_t const genre_GOTHIC[] = - { 'G', 'o', 't', 'h', 'i', 'c', 0 }; -static id3_ucs4_t const genre_DARKWAVE[] = - { 'D', 'a', 'r', 'k', 'w', 'a', 'v', 'e', 0 }; -static id3_ucs4_t const genre_TECHNO_INDUSTRIAL[] = - { 'T', 'e', 'c', 'h', 'n', 'o', '-', 'I', 'n', 'd', 'u', 's', 't', 'r', 'i', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ELECTRONIC[] = - { 'E', 'l', 'e', 'c', 't', 'r', 'o', 'n', 'i', 'c', 0 }; -static id3_ucs4_t const genre_POP_FOLK[] = - { 'P', 'o', 'p', '-', 'F', 'o', 'l', 'k', 0 }; -static id3_ucs4_t const genre_EURODANCE[] = - { 'E', 'u', 'r', 'o', 'd', 'a', 'n', 'c', 'e', 0 }; -static id3_ucs4_t const genre_DREAM[] = - { 'D', 'r', 'e', 'a', 'm', 0 }; -static id3_ucs4_t const genre_SOUTHERN_ROCK[] = - { 'S', 'o', 'u', 't', 'h', 'e', 'r', 'n', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_COMEDY[] = - { 'C', 'o', 'm', 'e', 'd', 'y', 0 }; -static id3_ucs4_t const genre_CULT[] = - { 'C', 'u', 'l', 't', 0 }; -static id3_ucs4_t const genre_GANGSTA[] = - { 'G', 'a', 'n', 'g', 's', 't', 'a', 0 }; -static id3_ucs4_t const genre_TOP_40[] = - { 'T', 'o', 'p', ' ', '4', '0', 0 }; -static id3_ucs4_t const genre_CHRISTIAN_RAP[] = - { 'C', 'h', 'r', 'i', 's', 't', 'i', 'a', 'n', ' ', 'R', 'a', 'p', 0 }; -static id3_ucs4_t const genre_POP_FUNK[] = - { 'P', 'o', 'p', '/', 'F', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_JUNGLE[] = - { 'J', 'u', 'n', 'g', 'l', 'e', 0 }; -static id3_ucs4_t const genre_NATIVE_AMERICAN[] = - { 'N', 'a', 't', 'i', 'v', 'e', ' ', 'A', 'm', 'e', 'r', 'i', 'c', 'a', 'n', 0 }; -static id3_ucs4_t const genre_CABARET[] = - { 'C', 'a', 'b', 'a', 'r', 'e', 't', 0 }; -static id3_ucs4_t const genre_NEW_WAVE[] = - { 'N', 'e', 'w', ' ', 'W', 'a', 'v', 'e', 0 }; -static id3_ucs4_t const genre_PSYCHEDELIC[] = - { 'P', 's', 'y', 'c', 'h', 'e', 'd', 'e', 'l', 'i', 'c', 0 }; -static id3_ucs4_t const genre_RAVE[] = - { 'R', 'a', 'v', 'e', 0 }; -static id3_ucs4_t const genre_SHOWTUNES[] = - { 'S', 'h', 'o', 'w', 't', 'u', 'n', 'e', 's', 0 }; -static id3_ucs4_t const genre_TRAILER[] = - { 'T', 'r', 'a', 'i', 'l', 'e', 'r', 0 }; -static id3_ucs4_t const genre_LO_FI[] = - { 'L', 'o', '-', 'F', 'i', 0 }; -static id3_ucs4_t const genre_TRIBAL[] = - { 'T', 'r', 'i', 'b', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ACID_PUNK[] = - { 'A', 'c', 'i', 'd', ' ', 'P', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_ACID_JAZZ[] = - { 'A', 'c', 'i', 'd', ' ', 'J', 'a', 'z', 'z', 0 }; -static id3_ucs4_t const genre_POLKA[] = - { 'P', 'o', 'l', 'k', 'a', 0 }; -static id3_ucs4_t const genre_RETRO[] = - { 'R', 'e', 't', 'r', 'o', 0 }; -static id3_ucs4_t const genre_MUSICAL[] = - { 'M', 'u', 's', 'i', 'c', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ROCK___ROLL[] = - { 'R', 'o', 'c', 'k', ' ', '&', ' ', 'R', 'o', 'l', 'l', 0 }; -static id3_ucs4_t const genre_HARD_ROCK[] = - { 'H', 'a', 'r', 'd', ' ', 'R', 'o', 'c', 'k', 0 }; - -/* Winamp extensions (80-147) */ - -static id3_ucs4_t const genre_FOLK[] = - { 'F', 'o', 'l', 'k', 0 }; -static id3_ucs4_t const genre_FOLK_ROCK[] = - { 'F', 'o', 'l', 'k', '/', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_NATIONAL_FOLK[] = - { 'N', 'a', 't', 'i', 'o', 'n', 'a', 'l', ' ', 'F', 'o', 'l', 'k', 0 }; -static id3_ucs4_t const genre_SWING[] = - { 'S', 'w', 'i', 'n', 'g', 0 }; -static id3_ucs4_t const genre_FAST_FUSION[] = - { 'F', 'a', 's', 't', '-', 'F', 'u', 's', 'i', 'o', 'n', 0 }; -static id3_ucs4_t const genre_BEBOB[] = - { 'B', 'e', 'b', 'o', 'b', 0 }; -static id3_ucs4_t const genre_LATIN[] = - { 'L', 'a', 't', 'i', 'n', 0 }; -static id3_ucs4_t const genre_REVIVAL[] = - { 'R', 'e', 'v', 'i', 'v', 'a', 'l', 0 }; -static id3_ucs4_t const genre_CELTIC[] = - { 'C', 'e', 'l', 't', 'i', 'c', 0 }; -static id3_ucs4_t const genre_BLUEGRASS[] = - { 'B', 'l', 'u', 'e', 'g', 'r', 'a', 's', 's', 0 }; -static id3_ucs4_t const genre_AVANTGARDE[] = - { 'A', 'v', 'a', 'n', 't', 'g', 'a', 'r', 'd', 'e', 0 }; -static id3_ucs4_t const genre_GOTHIC_ROCK[] = - { 'G', 'o', 't', 'h', 'i', 'c', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_PROGRESSIVE_ROCK[] = - { 'P', 'r', 'o', 'g', 'r', 'e', 's', 's', 'i', 'v', 'e', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_PSYCHEDELIC_ROCK[] = - { 'P', 's', 'y', 'c', 'h', 'e', 'd', 'e', 'l', 'i', 'c', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_SYMPHONIC_ROCK[] = - { 'S', 'y', 'm', 'p', 'h', 'o', 'n', 'i', 'c', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_SLOW_ROCK[] = - { 'S', 'l', 'o', 'w', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_BIG_BAND[] = - { 'B', 'i', 'g', ' ', 'B', 'a', 'n', 'd', 0 }; -static id3_ucs4_t const genre_CHORUS[] = - { 'C', 'h', 'o', 'r', 'u', 's', 0 }; -static id3_ucs4_t const genre_EASY_LISTENING[] = - { 'E', 'a', 's', 'y', ' ', 'L', 'i', 's', 't', 'e', 'n', 'i', 'n', 'g', 0 }; -static id3_ucs4_t const genre_ACOUSTIC[] = - { 'A', 'c', 'o', 'u', 's', 't', 'i', 'c', 0 }; -static id3_ucs4_t const genre_HUMOUR[] = - { 'H', 'u', 'm', 'o', 'u', 'r', 0 }; -static id3_ucs4_t const genre_SPEECH[] = - { 'S', 'p', 'e', 'e', 'c', 'h', 0 }; -static id3_ucs4_t const genre_CHANSON[] = - { 'C', 'h', 'a', 'n', 's', 'o', 'n', 0 }; -static id3_ucs4_t const genre_OPERA[] = - { 'O', 'p', 'e', 'r', 'a', 0 }; -static id3_ucs4_t const genre_CHAMBER_MUSIC[] = - { 'C', 'h', 'a', 'm', 'b', 'e', 'r', ' ', 'M', 'u', 's', 'i', 'c', 0 }; -static id3_ucs4_t const genre_SONATA[] = - { 'S', 'o', 'n', 'a', 't', 'a', 0 }; -static id3_ucs4_t const genre_SYMPHONY[] = - { 'S', 'y', 'm', 'p', 'h', 'o', 'n', 'y', 0 }; -static id3_ucs4_t const genre_BOOTY_BASS[] = - { 'B', 'o', 'o', 't', 'y', ' ', 'B', 'a', 's', 's', 0 }; -static id3_ucs4_t const genre_PRIMUS[] = - { 'P', 'r', 'i', 'm', 'u', 's', 0 }; -static id3_ucs4_t const genre_PORN_GROOVE[] = - { 'P', 'o', 'r', 'n', ' ', 'G', 'r', 'o', 'o', 'v', 'e', 0 }; -static id3_ucs4_t const genre_SATIRE[] = - { 'S', 'a', 't', 'i', 'r', 'e', 0 }; -static id3_ucs4_t const genre_SLOW_JAM[] = - { 'S', 'l', 'o', 'w', ' ', 'J', 'a', 'm', 0 }; -static id3_ucs4_t const genre_CLUB[] = - { 'C', 'l', 'u', 'b', 0 }; -static id3_ucs4_t const genre_TANGO[] = - { 'T', 'a', 'n', 'g', 'o', 0 }; -static id3_ucs4_t const genre_SAMBA[] = - { 'S', 'a', 'm', 'b', 'a', 0 }; -static id3_ucs4_t const genre_FOLKLORE[] = - { 'F', 'o', 'l', 'k', 'l', 'o', 'r', 'e', 0 }; -static id3_ucs4_t const genre_BALLAD[] = - { 'B', 'a', 'l', 'l', 'a', 'd', 0 }; -static id3_ucs4_t const genre_POWER_BALLAD[] = - { 'P', 'o', 'w', 'e', 'r', ' ', 'B', 'a', 'l', 'l', 'a', 'd', 0 }; -static id3_ucs4_t const genre_RHYTHMIC_SOUL[] = - { 'R', 'h', 'y', 't', 'h', 'm', 'i', 'c', ' ', 'S', 'o', 'u', 'l', 0 }; -static id3_ucs4_t const genre_FREESTYLE[] = - { 'F', 'r', 'e', 'e', 's', 't', 'y', 'l', 'e', 0 }; -static id3_ucs4_t const genre_DUET[] = - { 'D', 'u', 'e', 't', 0 }; -static id3_ucs4_t const genre_PUNK_ROCK[] = - { 'P', 'u', 'n', 'k', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_DRUM_SOLO[] = - { 'D', 'r', 'u', 'm', ' ', 'S', 'o', 'l', 'o', 0 }; -static id3_ucs4_t const genre_A_CAPPELLA[] = - { 'A', ' ', 'C', 'a', 'p', 'p', 'e', 'l', 'l', 'a', 0 }; -static id3_ucs4_t const genre_EURO_HOUSE[] = - { 'E', 'u', 'r', 'o', '-', 'H', 'o', 'u', 's', 'e', 0 }; -static id3_ucs4_t const genre_DANCE_HALL[] = - { 'D', 'a', 'n', 'c', 'e', ' ', 'H', 'a', 'l', 'l', 0 }; -static id3_ucs4_t const genre_GOA[] = - { 'G', 'o', 'a', 0 }; -static id3_ucs4_t const genre_DRUM___BASS[] = - { 'D', 'r', 'u', 'm', ' ', '&', ' ', 'B', 'a', 's', 's', 0 }; -static id3_ucs4_t const genre_CLUB_HOUSE[] = - { 'C', 'l', 'u', 'b', '-', 'H', 'o', 'u', 's', 'e', 0 }; -static id3_ucs4_t const genre_HARDCORE[] = - { 'H', 'a', 'r', 'd', 'c', 'o', 'r', 'e', 0 }; -static id3_ucs4_t const genre_TERROR[] = - { 'T', 'e', 'r', 'r', 'o', 'r', 0 }; -static id3_ucs4_t const genre_INDIE[] = - { 'I', 'n', 'd', 'i', 'e', 0 }; -static id3_ucs4_t const genre_BRITPOP[] = - { 'B', 'r', 'i', 't', 'P', 'o', 'p', 0 }; -static id3_ucs4_t const genre_NEGERPUNK[] = - { 'N', 'e', 'g', 'e', 'r', 'p', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_POLSK_PUNK[] = - { 'P', 'o', 'l', 's', 'k', ' ', 'P', 'u', 'n', 'k', 0 }; -static id3_ucs4_t const genre_BEAT[] = - { 'B', 'e', 'a', 't', 0 }; -static id3_ucs4_t const genre_CHRISTIAN_GANGSTA_RAP[] = - { 'C', 'h', 'r', 'i', 's', 't', 'i', 'a', 'n', ' ', 'G', 'a', 'n', 'g', 's', 't', 'a', ' ', 'R', 'a', 'p', 0 }; -static id3_ucs4_t const genre_HEAVY_METAL[] = - { 'H', 'e', 'a', 'v', 'y', ' ', 'M', 'e', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_BLACK_METAL[] = - { 'B', 'l', 'a', 'c', 'k', ' ', 'M', 'e', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_CROSSOVER[] = - { 'C', 'r', 'o', 's', 's', 'o', 'v', 'e', 'r', 0 }; -static id3_ucs4_t const genre_CONTEMPORARY_CHRISTIAN[] = - { 'C', 'o', 'n', 't', 'e', 'm', 'p', 'o', 'r', 'a', 'r', 'y', ' ', 'C', 'h', 'r', 'i', 's', 't', 'i', 'a', 'n', 0 }; -static id3_ucs4_t const genre_CHRISTIAN_ROCK[] = - { 'C', 'h', 'r', 'i', 's', 't', 'i', 'a', 'n', ' ', 'R', 'o', 'c', 'k', 0 }; -static id3_ucs4_t const genre_MERENGUE[] = - { 'M', 'e', 'r', 'e', 'n', 'g', 'u', 'e', 0 }; -static id3_ucs4_t const genre_SALSA[] = - { 'S', 'a', 'l', 's', 'a', 0 }; -static id3_ucs4_t const genre_THRASH_METAL[] = - { 'T', 'h', 'r', 'a', 's', 'h', ' ', 'M', 'e', 't', 'a', 'l', 0 }; -static id3_ucs4_t const genre_ANIME[] = - { 'A', 'n', 'i', 'm', 'e', 0 }; -static id3_ucs4_t const genre_JPOP[] = - { 'J', 'P', 'o', 'p', 0 }; -static id3_ucs4_t const genre_SYNTHPOP[] = - { 'S', 'y', 'n', 't', 'h', 'p', 'o', 'p', 0 }; - -static id3_ucs4_t const *const genre_table[] = { - genre_BLUES, - genre_CLASSIC_ROCK, - genre_COUNTRY, - genre_DANCE, - genre_DISCO, - genre_FUNK, - genre_GRUNGE, - genre_HIP_HOP, - genre_JAZZ, - genre_METAL, - genre_NEW_AGE, - genre_OLDIES, - genre_OTHER, - genre_POP, - genre_R_B, - genre_RAP, - genre_REGGAE, - genre_ROCK, - genre_TECHNO, - genre_INDUSTRIAL, - genre_ALTERNATIVE, - genre_SKA, - genre_DEATH_METAL, - genre_PRANKS, - genre_SOUNDTRACK, - genre_EURO_TECHNO, - genre_AMBIENT, - genre_TRIP_HOP, - genre_VOCAL, - genre_JAZZ_FUNK, - genre_FUSION, - genre_TRANCE, - genre_CLASSICAL, - genre_INSTRUMENTAL, - genre_ACID, - genre_HOUSE, - genre_GAME, - genre_SOUND_CLIP, - genre_GOSPEL, - genre_NOISE, - genre_ALTERNROCK, - genre_BASS, - genre_SOUL, - genre_PUNK, - genre_SPACE, - genre_MEDITATIVE, - genre_INSTRUMENTAL_POP, - genre_INSTRUMENTAL_ROCK, - genre_ETHNIC, - genre_GOTHIC, - genre_DARKWAVE, - genre_TECHNO_INDUSTRIAL, - genre_ELECTRONIC, - genre_POP_FOLK, - genre_EURODANCE, - genre_DREAM, - genre_SOUTHERN_ROCK, - genre_COMEDY, - genre_CULT, - genre_GANGSTA, - genre_TOP_40, - genre_CHRISTIAN_RAP, - genre_POP_FUNK, - genre_JUNGLE, - genre_NATIVE_AMERICAN, - genre_CABARET, - genre_NEW_WAVE, - genre_PSYCHEDELIC, - genre_RAVE, - genre_SHOWTUNES, - genre_TRAILER, - genre_LO_FI, - genre_TRIBAL, - genre_ACID_PUNK, - genre_ACID_JAZZ, - genre_POLKA, - genre_RETRO, - genre_MUSICAL, - genre_ROCK___ROLL, - genre_HARD_ROCK, - genre_FOLK, - genre_FOLK_ROCK, - genre_NATIONAL_FOLK, - genre_SWING, - genre_FAST_FUSION, - genre_BEBOB, - genre_LATIN, - genre_REVIVAL, - genre_CELTIC, - genre_BLUEGRASS, - genre_AVANTGARDE, - genre_GOTHIC_ROCK, - genre_PROGRESSIVE_ROCK, - genre_PSYCHEDELIC_ROCK, - genre_SYMPHONIC_ROCK, - genre_SLOW_ROCK, - genre_BIG_BAND, - genre_CHORUS, - genre_EASY_LISTENING, - genre_ACOUSTIC, - genre_HUMOUR, - genre_SPEECH, - genre_CHANSON, - genre_OPERA, - genre_CHAMBER_MUSIC, - genre_SONATA, - genre_SYMPHONY, - genre_BOOTY_BASS, - genre_PRIMUS, - genre_PORN_GROOVE, - genre_SATIRE, - genre_SLOW_JAM, - genre_CLUB, - genre_TANGO, - genre_SAMBA, - genre_FOLKLORE, - genre_BALLAD, - genre_POWER_BALLAD, - genre_RHYTHMIC_SOUL, - genre_FREESTYLE, - genre_DUET, - genre_PUNK_ROCK, - genre_DRUM_SOLO, - genre_A_CAPPELLA, - genre_EURO_HOUSE, - genre_DANCE_HALL, - genre_GOA, - genre_DRUM___BASS, - genre_CLUB_HOUSE, - genre_HARDCORE, - genre_TERROR, - genre_INDIE, - genre_BRITPOP, - genre_NEGERPUNK, - genre_POLSK_PUNK, - genre_BEAT, - genre_CHRISTIAN_GANGSTA_RAP, - genre_HEAVY_METAL, - genre_BLACK_METAL, - genre_CROSSOVER, - genre_CONTEMPORARY_CHRISTIAN, - genre_CHRISTIAN_ROCK, - genre_MERENGUE, - genre_SALSA, - genre_THRASH_METAL, - genre_ANIME, - genre_JPOP, - genre_SYNTHPOP -}; diff --git a/lib-src/libid3tag/genre.dat.in b/lib-src/libid3tag/genre.dat.in deleted file mode 100644 index 593fc50c3..000000000 --- a/lib-src/libid3tag/genre.dat.in +++ /dev/null @@ -1,180 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: genre.dat.in,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -/* - * These are the ID3 genre names, taken as a combination of names from ID3v1 - * (listed in Appendix A of the ID3 tag version 2.4.0 informal standard) and - * the extensions made by Winamp as of version 2.80. - */ - -/* ID3v1 names (0-79) */ - -Blues -Classic Rock -Country -Dance -Disco -Funk -Grunge -Hip-Hop -Jazz -Metal -New Age -Oldies -Other -Pop -R&B -Rap -Reggae -Rock -Techno -Industrial -Alternative -Ska -Death Metal -Pranks -Soundtrack -Euro-Techno -Ambient -Trip-Hop -Vocal -Jazz+Funk -Fusion -Trance -Classical -Instrumental -Acid -House -Game -Sound Clip -Gospel -Noise -AlternRock -Bass -Soul -Punk -Space -Meditative -Instrumental Pop -Instrumental Rock -Ethnic -Gothic -Darkwave -Techno-Industrial -Electronic -Pop-Folk -Eurodance -Dream -Southern Rock -Comedy -Cult -Gangsta -Top 40 -Christian Rap -Pop/Funk -Jungle -Native American -Cabaret -New Wave -Psychedelic -Rave -Showtunes -Trailer -Lo-Fi -Tribal -Acid Punk -Acid Jazz -Polka -Retro -Musical -Rock & Roll -Hard Rock - -/* Winamp extensions (80-147) */ - -Folk -Folk/Rock -National Folk -Swing -Fast-Fusion -Bebob -Latin -Revival -Celtic -Bluegrass -Avantgarde -Gothic Rock -Progressive Rock -Psychedelic Rock -Symphonic Rock -Slow Rock -Big Band -Chorus -Easy Listening -Acoustic -Humour -Speech -Chanson -Opera -Chamber Music -Sonata -Symphony -Booty Bass -Primus -Porn Groove -Satire -Slow Jam -Club -Tango -Samba -Folklore -Ballad -Power Ballad -Rhythmic Soul -Freestyle -Duet -Punk Rock -Drum Solo -A Cappella -Euro-House -Dance Hall -Goa -Drum & Bass -Club-House -Hardcore -Terror -Indie -BritPop -Negerpunk -Polsk Punk -Beat -Christian Gangsta Rap -Heavy Metal -Black Metal -Crossover -Contemporary Christian -Christian Rock -Merengue -Salsa -Thrash Metal -Anime -JPop -Synthpop diff --git a/lib-src/libid3tag/genre.dat.sed b/lib-src/libid3tag/genre.dat.sed deleted file mode 100644 index 8f6452b30..000000000 --- a/lib-src/libid3tag/genre.dat.sed +++ /dev/null @@ -1,54 +0,0 @@ -# -# libid3tag - ID3 tag manipulation library -# Copyright (C) 2000-2004 Underbit Technologies, Inc. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -# -# $Id: genre.dat.sed,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ -# - -1i\ -/* Automatically generated from genre.dat.in */ - -# generate an array from a string -/^[A-Za-z]/{ -H -y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/ -s/[^A-Z0-9]/_/g -s/.*/static id3_ucs4_t const genre_&[] =/p -g -s/.*\n// -s/./'&', /g -s/.*/ { &0 };/ -} - -# write the final table of arrays -${ -p -i\ -\ -static id3_ucs4_t const *const genre_table[] = { -g -s/^\(\n\)\(.*\)$/\2\1/ -y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/ -s/[^A-Z0-9\n]/_/g -s/\([^\n]*\)\(\n\)/ genre_\1,\2/g -s/,\n$// -a\ -}; -} - -# print the pattern space (assumes -n) -p diff --git a/lib-src/libid3tag/genre.h b/lib-src/libid3tag/genre.h deleted file mode 100644 index a8e5dd2cc..000000000 --- a/lib-src/libid3tag/genre.h +++ /dev/null @@ -1,27 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: genre.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_GENRE_H -# define LIBID3TAG_GENRE_H - -# define ID3_GENRE_OTHER 12 - -# endif diff --git a/lib-src/libid3tag/global.h b/lib-src/libid3tag/global.h deleted file mode 100644 index 2acdeccf1..000000000 --- a/lib-src/libid3tag/global.h +++ /dev/null @@ -1,53 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: global.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_GLOBAL_H -# define LIBID3TAG_GLOBAL_H - -/* conditional debugging */ - -# if defined(DEBUG) && defined(NDEBUG) -# error "cannot define both DEBUG and NDEBUG" -# endif - -# if defined(DEBUG) -# include -# include "debug.h" -# define malloc(sz) id3_debug_malloc(sz, __FILE__, __LINE__) -# define calloc(n, sz) id3_debug_calloc(n, sz, __FILE__, __LINE__) -# define realloc(ptr, sz) id3_debug_realloc(ptr, sz, __FILE__, __LINE__) -# define free(ptr) id3_debug_free(ptr, __FILE__, __LINE__) -# define release(ptr) id3_debug_release(ptr, __FILE__, __LINE__) -# else -# define release(ptr) (ptr) -# endif - -/* conditional features */ - -# if !defined(HAVE_ASSERT_H) -# if defined(NDEBUG) -# define assert(x) /* nothing */ -# else -# define assert(x) do { if (!(x)) abort(); } while (0) -# endif -# endif - -# endif diff --git a/lib-src/libid3tag/id3tag.h b/lib-src/libid3tag/id3tag.h deleted file mode 100644 index 6990bc162..000000000 --- a/lib-src/libid3tag/id3tag.h +++ /dev/null @@ -1,367 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * If you would like to negotiate alternate licensing terms, you may do - * so by contacting: Underbit Technologies, Inc. - * - * $Id: id3tag.h,v 1.4 2007-04-29 05:10:24 llucius Exp $ - */ - -# ifndef LIBID3TAG_ID3TAG_H -# define LIBID3TAG_ID3TAG_H - -# ifdef __cplusplus -extern "C" { -# endif - -# define ID3_TAG_VERSION 0x0400 -# define ID3_TAG_VERSION_MAJOR(x) (((x) >> 8) & 0xff) -# define ID3_TAG_VERSION_MINOR(x) (((x) >> 0) & 0xff) - -typedef unsigned char id3_byte_t; -typedef unsigned long id3_length_t; - -typedef unsigned long id3_ucs4_t; - -typedef unsigned char id3_latin1_t; -typedef unsigned short id3_utf16_t; -typedef signed char id3_utf8_t; - -struct id3_tag { - unsigned int refcount; - unsigned int version; - int flags; - int extendedflags; - int restrictions; - int options; - unsigned int nframes; - struct id3_frame **frames; - id3_length_t paddedsize; -}; - -# define ID3_TAG_QUERYSIZE 10 - -/* ID3v1 field frames */ - -# define ID3_FRAME_TITLE "TIT2" -# define ID3_FRAME_ARTIST "TPE1" -# define ID3_FRAME_ALBUM "TALB" -# define ID3_FRAME_TRACK "TRCK" -# define ID3_FRAME_YEAR "TDRC" -# define ID3_FRAME_GENRE "TCON" -# define ID3_FRAME_COMMENT "COMM" - -/* special frames */ - -# define ID3_FRAME_OBSOLETE "ZOBS" /* with apologies to the French */ - -/* tag flags */ - -enum { - ID3_TAG_FLAG_UNSYNCHRONISATION = 0x80, - ID3_TAG_FLAG_EXTENDEDHEADER = 0x40, - ID3_TAG_FLAG_EXPERIMENTALINDICATOR = 0x20, - ID3_TAG_FLAG_FOOTERPRESENT = 0x10, - - ID3_TAG_FLAG_KNOWNFLAGS = 0xf0 -}; - -/* tag extended flags */ - -enum { - ID3_TAG_EXTENDEDFLAG_TAGISANUPDATE = 0x40, - ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT = 0x20, - ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS = 0x10, - - ID3_TAG_EXTENDEDFLAG_KNOWNFLAGS = 0x70 -}; - -/* tag restrictions */ - -enum { - ID3_TAG_RESTRICTION_TAGSIZE_MASK = 0xc0, - ID3_TAG_RESTRICTION_TAGSIZE_128_FRAMES_1_MB = 0x00, - ID3_TAG_RESTRICTION_TAGSIZE_64_FRAMES_128_KB = 0x40, - ID3_TAG_RESTRICTION_TAGSIZE_32_FRAMES_40_KB = 0x80, - ID3_TAG_RESTRICTION_TAGSIZE_32_FRAMES_4_KB = 0xc0 -}; - -enum { - ID3_TAG_RESTRICTION_TEXTENCODING_MASK = 0x20, - ID3_TAG_RESTRICTION_TEXTENCODING_NONE = 0x00, - ID3_TAG_RESTRICTION_TEXTENCODING_LATIN1_UTF8 = 0x20 -}; - -enum { - ID3_TAG_RESTRICTION_TEXTSIZE_MASK = 0x18, - ID3_TAG_RESTRICTION_TEXTSIZE_NONE = 0x00, - ID3_TAG_RESTRICTION_TEXTSIZE_1024_CHARS = 0x08, - ID3_TAG_RESTRICTION_TEXTSIZE_128_CHARS = 0x10, - ID3_TAG_RESTRICTION_TEXTSIZE_30_CHARS = 0x18 -}; - -enum { - ID3_TAG_RESTRICTION_IMAGEENCODING_MASK = 0x04, - ID3_TAG_RESTRICTION_IMAGEENCODING_NONE = 0x00, - ID3_TAG_RESTRICTION_IMAGEENCODING_PNG_JPEG = 0x04 -}; - -enum { - ID3_TAG_RESTRICTION_IMAGESIZE_MASK = 0x03, - ID3_TAG_RESTRICTION_IMAGESIZE_NONE = 0x00, - ID3_TAG_RESTRICTION_IMAGESIZE_256_256 = 0x01, - ID3_TAG_RESTRICTION_IMAGESIZE_64_64 = 0x02, - ID3_TAG_RESTRICTION_IMAGESIZE_64_64_EXACT = 0x03 -}; - -/* library options */ - -#define ID3_TAG_HAS_TAG_OPTION_ID3V2_3 - -enum { - ID3_TAG_OPTION_UNSYNCHRONISATION = 0x0001, /* use unsynchronisation */ - ID3_TAG_OPTION_COMPRESSION = 0x0002, /* use compression */ - ID3_TAG_OPTION_CRC = 0x0004, /* use CRC */ - - ID3_TAG_OPTION_APPENDEDTAG = 0x0010, /* tag will be appended */ - ID3_TAG_OPTION_FILEALTERED = 0x0020, /* audio data was altered */ - - ID3_TAG_OPTION_ID3V1 = 0x0100,/* render ID3v1/ID3v1.1 tag */ - ID3_TAG_OPTION_ID3V2_3 = 0x0200 /* render ID3v2.3 tag */ -}; - -struct id3_frame { - char id[5]; - char const *description; - unsigned int refcount; - int flags; - int group_id; - int encryption_method; - id3_byte_t *encoded; - id3_length_t encoded_length; - id3_length_t decoded_length; - unsigned int nfields; - union id3_field *fields; -}; - -enum { - /* frame status flags */ - ID3_FRAME_FLAG_TAGALTERPRESERVATION = 0x4000, - ID3_FRAME_FLAG_FILEALTERPRESERVATION = 0x2000, - ID3_FRAME_FLAG_READONLY = 0x1000, - - ID3_FRAME_FLAG_STATUSFLAGS = 0xff00, - - /* frame format flags */ - ID3_FRAME_FLAG_GROUPINGIDENTITY = 0x0040, - ID3_FRAME_FLAG_COMPRESSION = 0x0008, - ID3_FRAME_FLAG_ENCRYPTION = 0x0004, - ID3_FRAME_FLAG_UNSYNCHRONISATION = 0x0002, - ID3_FRAME_FLAG_DATALENGTHINDICATOR = 0x0001, - - ID3_FRAME_FLAG_FORMATFLAGS = 0x00ff, - - ID3_FRAME_FLAG_KNOWNFLAGS = 0x704f -}; - -enum id3_field_type { - ID3_FIELD_TYPE_TEXTENCODING, - ID3_FIELD_TYPE_LATIN1, - ID3_FIELD_TYPE_LATIN1FULL, - ID3_FIELD_TYPE_LATIN1LIST, - ID3_FIELD_TYPE_STRING, - ID3_FIELD_TYPE_STRINGFULL, - ID3_FIELD_TYPE_STRINGLIST, - ID3_FIELD_TYPE_LANGUAGE, - ID3_FIELD_TYPE_FRAMEID, - ID3_FIELD_TYPE_DATE, - ID3_FIELD_TYPE_INT8, - ID3_FIELD_TYPE_INT16, - ID3_FIELD_TYPE_INT24, - ID3_FIELD_TYPE_INT32, - ID3_FIELD_TYPE_INT32PLUS, - ID3_FIELD_TYPE_BINARYDATA -}; - -enum id3_field_textencoding { - ID3_FIELD_TEXTENCODING_ISO_8859_1 = 0x00, - ID3_FIELD_TEXTENCODING_UTF_16 = 0x01, - ID3_FIELD_TEXTENCODING_UTF_16BE = 0x02, - ID3_FIELD_TEXTENCODING_UTF_8 = 0x03 -}; - -union id3_field { - enum id3_field_type type; - struct { - enum id3_field_type type; - signed long value; - } number; - struct { - enum id3_field_type type; - id3_latin1_t *ptr; - } latin1; - struct { - enum id3_field_type type; - unsigned int nstrings; - id3_latin1_t **strings; - } latin1list; - struct { - enum id3_field_type type; - id3_ucs4_t *ptr; - } string; - struct { - enum id3_field_type type; - unsigned int nstrings; - id3_ucs4_t **strings; - } stringlist; - struct { - enum id3_field_type type; - char value[9]; - } immediate; - struct { - enum id3_field_type type; - id3_byte_t *data; - id3_length_t length; - } binary; -}; - -/* file interface */ - -enum id3_file_mode { - ID3_FILE_MODE_READONLY = 0, - ID3_FILE_MODE_READWRITE -}; - -struct id3_file *id3_file_open(char const *, enum id3_file_mode); -struct id3_file *id3_file_fdopen(int, enum id3_file_mode); -int id3_file_close(struct id3_file *); - -struct id3_tag *id3_file_tag(struct id3_file const *); - -int id3_file_update(struct id3_file *); - -/* tag interface */ - -struct id3_tag *id3_tag_new(void); -void id3_tag_delete(struct id3_tag *); - -unsigned int id3_tag_version(struct id3_tag const *); - -int id3_tag_options(struct id3_tag *, int, int); -void id3_tag_setlength(struct id3_tag *, id3_length_t); - -void id3_tag_clearframes(struct id3_tag *); - -int id3_tag_attachframe(struct id3_tag *, struct id3_frame *); -int id3_tag_detachframe(struct id3_tag *, struct id3_frame *); - -struct id3_frame *id3_tag_findframe(struct id3_tag const *, - char const *, unsigned int); - -signed long id3_tag_query(id3_byte_t const *, id3_length_t); - -struct id3_tag *id3_tag_parse(id3_byte_t const *, id3_length_t); -id3_length_t id3_tag_render(struct id3_tag const *, id3_byte_t *); - -/* frame interface */ - -struct id3_frame *id3_frame_new(char const *); -void id3_frame_delete(struct id3_frame *); - -union id3_field *id3_frame_field(struct id3_frame const *, unsigned int); - -/* field interface */ - -enum id3_field_type id3_field_type(union id3_field const *); - -int id3_field_setint(union id3_field *, signed long); -int id3_field_settextencoding(union id3_field *, enum id3_field_textencoding); -int id3_field_setstrings(union id3_field *, unsigned int, id3_ucs4_t **); -int id3_field_addstring(union id3_field *, id3_ucs4_t const *); -int id3_field_setlanguage(union id3_field *, char const *); -int id3_field_setlatin1(union id3_field *, id3_latin1_t const *); -int id3_field_setfulllatin1(union id3_field *, id3_latin1_t const *); -int id3_field_setstring(union id3_field *, id3_ucs4_t const *); -int id3_field_setfullstring(union id3_field *, id3_ucs4_t const *); -int id3_field_setframeid(union id3_field *, char const *); -int id3_field_setbinarydata(union id3_field *, - id3_byte_t const *, id3_length_t); - -signed long id3_field_getint(union id3_field const *); -enum id3_field_textencoding id3_field_gettextencoding(union id3_field const *); -id3_latin1_t const *id3_field_getlatin1(union id3_field const *); -id3_latin1_t const *id3_field_getfulllatin1(union id3_field const *); -id3_ucs4_t const *id3_field_getstring(union id3_field const *); -id3_ucs4_t const *id3_field_getfullstring(union id3_field const *); -unsigned int id3_field_getnstrings(union id3_field const *); -id3_ucs4_t const *id3_field_getstrings(union id3_field const *, - unsigned int); -char const *id3_field_getframeid(union id3_field const *); -id3_byte_t const *id3_field_getbinarydata(union id3_field const *, - id3_length_t *); - -/* genre interface */ - -id3_ucs4_t const *id3_genre_index(unsigned int); -id3_ucs4_t const *id3_genre_name(id3_ucs4_t const *); -int id3_genre_number(id3_ucs4_t const *); - -/* ucs4 interface */ - -id3_latin1_t *id3_ucs4_latin1duplicate(id3_ucs4_t const *); -id3_utf16_t *id3_ucs4_utf16duplicate(id3_ucs4_t const *); -id3_utf8_t *id3_ucs4_utf8duplicate(id3_ucs4_t const *); - -void id3_ucs4_putnumber(id3_ucs4_t *, unsigned long); -unsigned long id3_ucs4_getnumber(id3_ucs4_t const *); - -/* latin1/utf16/utf8 interfaces */ - -id3_ucs4_t *id3_latin1_ucs4duplicate(id3_latin1_t const *); -id3_ucs4_t *id3_utf16_ucs4duplicate(id3_utf16_t const *); -id3_ucs4_t *id3_utf8_ucs4duplicate(id3_utf8_t const *); - -/* version interface */ - -# define ID3_VERSION_MAJOR 0 -# define ID3_VERSION_MINOR 15 -# define ID3_VERSION_PATCH 1 -# define ID3_VERSION_EXTRA " (beta)" - -# define ID3_VERSION_STRINGIZE(str) #str -# define ID3_VERSION_STRING(num) ID3_VERSION_STRINGIZE(num) - -# define ID3_VERSION ID3_VERSION_STRING(ID3_VERSION_MAJOR) "." \ - ID3_VERSION_STRING(ID3_VERSION_MINOR) "." \ - ID3_VERSION_STRING(ID3_VERSION_PATCH) \ - ID3_VERSION_EXTRA - -# define ID3_PUBLISHYEAR "2000-2004" -# define ID3_AUTHOR "Underbit Technologies, Inc." -# define ID3_EMAIL "info@underbit.com" - -extern char const id3_version[]; -extern char const id3_copyright[]; -extern char const id3_author[]; -extern char const id3_build[]; - -# ifdef __cplusplus -} -# endif - -# endif diff --git a/lib-src/libid3tag/install-sh b/lib-src/libid3tag/install-sh deleted file mode 100755 index 377bb8687..000000000 --- a/lib-src/libid3tag/install-sh +++ /dev/null @@ -1,527 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2011-11-20.07; # UTC - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# 'make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. - -nl=' -' -IFS=" "" $nl" - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit=${DOITPROG-} -if test -z "$doit"; then - doit_exec=exec -else - doit_exec=$doit -fi - -# Put in absolute file names if you don't have them in your path; -# or use environment vars. - -chgrpprog=${CHGRPPROG-chgrp} -chmodprog=${CHMODPROG-chmod} -chownprog=${CHOWNPROG-chown} -cmpprog=${CMPPROG-cmp} -cpprog=${CPPROG-cp} -mkdirprog=${MKDIRPROG-mkdir} -mvprog=${MVPROG-mv} -rmprog=${RMPROG-rm} -stripprog=${STRIPPROG-strip} - -posix_glob='?' -initialize_posix_glob=' - test "$posix_glob" != "?" || { - if (set -f) 2>/dev/null; then - posix_glob= - else - posix_glob=: - fi - } -' - -posix_mkdir= - -# Desired mode of installed file. -mode=0755 - -chgrpcmd= -chmodcmd=$chmodprog -chowncmd= -mvcmd=$mvprog -rmcmd="$rmprog -f" -stripcmd= - -src= -dst= -dir_arg= -dst_arg= - -copy_on_change=false -no_target_directory= - -usage="\ -Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: - --help display this help and exit. - --version display version info and exit. - - -c (ignored) - -C install only if different (preserve the last data modification time) - -d create directories instead of installing files. - -g GROUP $chgrpprog installed files to GROUP. - -m MODE $chmodprog installed files to MODE. - -o USER $chownprog installed files to USER. - -s $stripprog installed files. - -t DIRECTORY install into DIRECTORY. - -T report an error if DSTFILE is a directory. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG - RMPROG STRIPPROG -" - -while test $# -ne 0; do - case $1 in - -c) ;; - - -C) copy_on_change=true;; - - -d) dir_arg=true;; - - -g) chgrpcmd="$chgrpprog $2" - shift;; - - --help) echo "$usage"; exit $?;; - - -m) mode=$2 - case $mode in - *' '* | *' '* | *' -'* | *'*'* | *'?'* | *'['*) - echo "$0: invalid mode: $mode" >&2 - exit 1;; - esac - shift;; - - -o) chowncmd="$chownprog $2" - shift;; - - -s) stripcmd=$stripprog;; - - -t) dst_arg=$2 - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - shift;; - - -T) no_target_directory=true;; - - --version) echo "$0 $scriptversion"; exit $?;; - - --) shift - break;; - - -*) echo "$0: invalid option: $1" >&2 - exit 1;; - - *) break;; - esac - shift -done - -if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then - # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dst_arg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dst_arg" - shift # fnord - fi - shift # arg - dst_arg=$arg - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - done -fi - -if test $# -eq 0; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call 'install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -if test -z "$dir_arg"; then - do_exit='(exit $ret); exit $ret' - trap "ret=129; $do_exit" 1 - trap "ret=130; $do_exit" 2 - trap "ret=141; $do_exit" 13 - trap "ret=143; $do_exit" 15 - - # Set umask so as not to create temps with too-generous modes. - # However, 'strip' requires both read and write access to temps. - case $mode in - # Optimize common cases. - *644) cp_umask=133;; - *755) cp_umask=22;; - - *[0-7]) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw='% 200' - fi - cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; - *) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw=,u+rw - fi - cp_umask=$mode$u_plus_rw;; - esac -fi - -for src -do - # Protect names problematic for 'test' and other utilities. - case $src in - -* | [=\(\)!]) src=./$src;; - esac - - if test -n "$dir_arg"; then - dst=$src - dstdir=$dst - test -d "$dstdir" - dstdir_status=$? - else - - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dst_arg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - dst=$dst_arg - - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. - if test -d "$dst"; then - if test -n "$no_target_directory"; then - echo "$0: $dst_arg: Is a directory" >&2 - exit 1 - fi - dstdir=$dst - dst=$dstdir/`basename "$src"` - dstdir_status=0 - else - # Prefer dirname, but fall back on a substitute if dirname fails. - dstdir=` - (dirname "$dst") 2>/dev/null || - expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$dst" : 'X\(//\)[^/]' \| \ - X"$dst" : 'X\(//\)$' \| \ - X"$dst" : 'X\(/\)' \| . 2>/dev/null || - echo X"$dst" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q' - ` - - test -d "$dstdir" - dstdir_status=$? - fi - fi - - obsolete_mkdir_used=false - - if test $dstdir_status != 0; then - case $posix_mkdir in - '') - # Create intermediate dirs using mode 755 as modified by the umask. - # This is like FreeBSD 'install' as of 1997-10-28. - umask=`umask` - case $stripcmd.$umask in - # Optimize common cases. - *[2367][2367]) mkdir_umask=$umask;; - .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; - - *[0-7]) - mkdir_umask=`expr $umask + 22 \ - - $umask % 100 % 40 + $umask % 20 \ - - $umask % 10 % 4 + $umask % 2 - `;; - *) mkdir_umask=$umask,go-w;; - esac - - # With -d, create the new directory with the user-specified mode. - # Otherwise, rely on $mkdir_umask. - if test -n "$dir_arg"; then - mkdir_mode=-m$mode - else - mkdir_mode= - fi - - posix_mkdir=false - case $umask in - *[123567][0-7][0-7]) - # POSIX mkdir -p sets u+wx bits regardless of umask, which - # is incompatible with FreeBSD 'install' when (umask & 300) != 0. - ;; - *) - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 - - if (umask $mkdir_umask && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 - then - if test -z "$dir_arg" || { - # Check for POSIX incompatibilities with -m. - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or - # other-writable bit of parent directory when it shouldn't. - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. - ls_ld_tmpdir=`ls -ld "$tmpdir"` - case $ls_ld_tmpdir in - d????-?r-*) different_mode=700;; - d????-?--*) different_mode=755;; - *) false;; - esac && - $mkdirprog -m$different_mode -p -- "$tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$tmpdir"` - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" - } - } - then posix_mkdir=: - fi - rmdir "$tmpdir/d" "$tmpdir" - else - # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null - fi - trap '' 0;; - esac;; - esac - - if - $posix_mkdir && ( - umask $mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" - ) - then : - else - - # The umask is ridiculous, or mkdir does not conform to POSIX, - # or it failed possibly due to a race condition. Create the - # directory the slow way, step by step, checking for races as we go. - - case $dstdir in - /*) prefix='/';; - [-=\(\)!]*) prefix='./';; - *) prefix='';; - esac - - eval "$initialize_posix_glob" - - oIFS=$IFS - IFS=/ - $posix_glob set -f - set fnord $dstdir - shift - $posix_glob set +f - IFS=$oIFS - - prefixes= - - for d - do - test X"$d" = X && continue - - prefix=$prefix$d - if test -d "$prefix"; then - prefixes= - else - if $posix_mkdir; then - (umask=$mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break - # Don't fail if two instances are running concurrently. - test -d "$prefix" || exit 1 - else - case $prefix in - *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; - *) qprefix=$prefix;; - esac - prefixes="$prefixes '$qprefix'" - fi - fi - prefix=$prefix/ - done - - if test -n "$prefixes"; then - # Don't fail if two instances are running concurrently. - (umask $mkdir_umask && - eval "\$doit_exec \$mkdirprog $prefixes") || - test -d "$dstdir" || exit 1 - obsolete_mkdir_used=true - fi - fi - fi - - if test -n "$dir_arg"; then - { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && - { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || - test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 - else - - # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - - # Copy the file name to the temp name. - (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && - { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && - { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && - - # If -C, don't bother to copy if it wouldn't change the file. - if $copy_on_change && - old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && - new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && - - eval "$initialize_posix_glob" && - $posix_glob set -f && - set X $old && old=:$2:$4:$5:$6 && - set X $new && new=:$2:$4:$5:$6 && - $posix_glob set +f && - - test "$old" = "$new" && - $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 - then - rm -f "$dsttmp" - else - # Rename the file to the real destination. - $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || - - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - { - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - test ! -f "$dst" || - $doit $rmcmd -f "$dst" 2>/dev/null || - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && - { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } - } || - { echo "$0: cannot unlink or rename $dst" >&2 - (exit 1); exit 1 - } - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dst" - } - fi || exit 1 - - trap '' 0 - fi -done - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libid3tag/latin1.c b/lib-src/libid3tag/latin1.c deleted file mode 100644 index db26d7a16..000000000 --- a/lib-src/libid3tag/latin1.c +++ /dev/null @@ -1,217 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: latin1.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "latin1.h" -# include "ucs4.h" - -/* - * NAME: latin1->length() - * DESCRIPTION: return the number of ucs4 chars represented by a latin1 string - */ -id3_length_t id3_latin1_length(id3_latin1_t const *latin1) -{ - id3_latin1_t const *ptr = latin1; - - while (*ptr) - ++ptr; - - return ptr - latin1; -} - -/* - * NAME: latin1->size() - * DESCRIPTION: return the encoding size of a latin1 string - */ -id3_length_t id3_latin1_size(id3_latin1_t const *latin1) -{ - return id3_latin1_length(latin1) + 1; -} - -/* - * NAME: latin1->copy() - * DESCRIPTION: copy a latin1 string - */ -void id3_latin1_copy(id3_latin1_t *dest, id3_latin1_t const *src) -{ - while ((*dest++ = *src++)) - ; -} - -/* - * NAME: latin1->duplicate() - * DESCRIPTION: duplicate a latin1 string - */ -id3_latin1_t *id3_latin1_duplicate(id3_latin1_t const *src) -{ - id3_latin1_t *latin1; - - latin1 = malloc(id3_latin1_size(src) * sizeof(*latin1)); - if (latin1) - id3_latin1_copy(latin1, src); - - return latin1; -} - -/* - * NAME: latin1->ucs4duplicate() - * DESCRIPTION: duplicate and decode a latin1 string into ucs4 - */ -id3_ucs4_t *id3_latin1_ucs4duplicate(id3_latin1_t const *latin1) -{ - id3_ucs4_t *ucs4; - - ucs4 = malloc((id3_latin1_length(latin1) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_latin1_decode(latin1, ucs4); - - return release(ucs4); -} - -/* - * NAME: latin1->decodechar() - * DESCRIPTION: decode a (single) latin1 char into a single ucs4 char - */ -id3_length_t id3_latin1_decodechar(id3_latin1_t const *latin1, - id3_ucs4_t *ucs4) -{ - *ucs4 = *latin1; - - return 1; -} - -/* - * NAME: latin1->encodechar() - * DESCRIPTION: encode a single ucs4 char into a (single) latin1 char - */ -id3_length_t id3_latin1_encodechar(id3_latin1_t *latin1, id3_ucs4_t ucs4) -{ - *latin1 = ucs4; - if (ucs4 > 0x000000ffL) - *latin1 = ID3_UCS4_REPLACEMENTCHAR; - - return 1; -} - -/* - * NAME: latin1->decode() - * DESCRIPTION: decode a complete latin1 string into a ucs4 string - */ -void id3_latin1_decode(id3_latin1_t const *latin1, id3_ucs4_t *ucs4) -{ - do - latin1 += id3_latin1_decodechar(latin1, ucs4); - while (*ucs4++); -} - -/* - * NAME: latin1->encode() - * DESCRIPTION: encode a complete ucs4 string into a latin1 string - */ -void id3_latin1_encode(id3_latin1_t *latin1, id3_ucs4_t const *ucs4) -{ - do - latin1 += id3_latin1_encodechar(latin1, *ucs4); - while (*ucs4++); -} - -/* - * NAME: latin1->put() - * DESCRIPTION: serialize a single latin1 character - */ -id3_length_t id3_latin1_put(id3_byte_t **ptr, id3_latin1_t latin1) -{ - if (ptr) - *(*ptr)++ = latin1; - - return 1; -} - -/* - * NAME: latin1->get() - * DESCRIPTION: deserialize a single latin1 character - */ -id3_latin1_t id3_latin1_get(id3_byte_t const **ptr) -{ - return *(*ptr)++; -} - -/* - * NAME: latin1->serialize() - * DESCRIPTION: serialize a ucs4 string using latin1 encoding - */ -id3_length_t id3_latin1_serialize(id3_byte_t **ptr, id3_ucs4_t const *ucs4, - int terminate) -{ - id3_length_t size = 0; - id3_latin1_t latin1[1], *out; - - while (*ucs4) { - switch (id3_latin1_encodechar(out = latin1, *ucs4++)) { - case 1: size += id3_latin1_put(ptr, *out++); - case 0: break; - } - } - - if (terminate) - size += id3_latin1_put(ptr, 0); - - return size; -} - -/* - * NAME: latin1->deserialize() - * DESCRIPTION: deserialize a ucs4 string using latin1 encoding - */ -id3_ucs4_t *id3_latin1_deserialize(id3_byte_t const **ptr, id3_length_t length) -{ - id3_byte_t const *end; - id3_latin1_t *latin1ptr, *latin1; - id3_ucs4_t *ucs4; - - end = *ptr + length; - - latin1 = malloc((length + 1) * sizeof(*latin1)); - if (latin1 == 0) - return 0; - - latin1ptr = latin1; - while (end - *ptr > 0 && (*latin1ptr = id3_latin1_get(ptr))) - ++latin1ptr; - - *latin1ptr = 0; - - ucs4 = malloc((id3_latin1_length(latin1) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_latin1_decode(latin1, ucs4); - - free(latin1); - - return ucs4; -} diff --git a/lib-src/libid3tag/latin1.h b/lib-src/libid3tag/latin1.h deleted file mode 100644 index 127850f2e..000000000 --- a/lib-src/libid3tag/latin1.h +++ /dev/null @@ -1,45 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: latin1.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_LATIN1_H -# define LIBID3TAG_LATIN1_H - -# include "id3tag.h" - -id3_length_t id3_latin1_length(id3_latin1_t const *); -id3_length_t id3_latin1_size(id3_latin1_t const *); - -void id3_latin1_copy(id3_latin1_t *, id3_latin1_t const *); -id3_latin1_t *id3_latin1_duplicate(id3_latin1_t const *); - -id3_length_t id3_latin1_decodechar(id3_latin1_t const *, id3_ucs4_t *); -id3_length_t id3_latin1_encodechar(id3_latin1_t *, id3_ucs4_t); - -void id3_latin1_decode(id3_latin1_t const *, id3_ucs4_t *); -void id3_latin1_encode(id3_latin1_t *, id3_ucs4_t const *); - -id3_length_t id3_latin1_put(id3_byte_t **, id3_latin1_t); -id3_latin1_t id3_latin1_get(id3_byte_t const **); - -id3_length_t id3_latin1_serialize(id3_byte_t **, id3_ucs4_t const *, int); -id3_ucs4_t *id3_latin1_deserialize(id3_byte_t const **, id3_length_t); - -# endif diff --git a/lib-src/libid3tag/libid3tag-srcdir.patch b/lib-src/libid3tag/libid3tag-srcdir.patch deleted file mode 100644 index d8b17ff80..000000000 --- a/lib-src/libid3tag/libid3tag-srcdir.patch +++ /dev/null @@ -1,150 +0,0 @@ -Index: lib-src/libid3tag/Makefile.am -=================================================================== ---- lib-src/libid3tag/Makefile.am (revision 13510) -+++ lib-src/libid3tag/Makefile.am (working copy) -@@ -95,27 +95,27 @@ - - libid3tag_la_LDFLAGS = -version-info $(version_info) - --BUILT_SOURCES = frametype.c compat.c genre.dat -+#BUILT_SOURCES = frametype.c compat.c genre.dat -+# -+#$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -+# cd $(srcdir) && \ -+# gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -+# frametype.gperf | \ -+# sed -e 's/\(struct id3_frametype\);/\1/' | \ -+# sed -e '/\$$''Id: /s/\$$//g' >frametype.c -+# -+#$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -+# cd $(srcdir) && \ -+# gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -+# compat.gperf | \ -+# sed -e 's/\(struct id3_compat\);/\1/' | \ -+# sed -e '/\$$''Id: /s/\$$//g' >compat.c -+# -+#$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -+# cd $(srcdir) && \ -+# sed -n -f genre.dat.sed genre.dat.in | \ -+# sed -e '/\$$''Id: /s/\$$//g' >genre.dat - --$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -- cd $(srcdir) && \ -- gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -- frametype.gperf | \ -- sed -e 's/\(struct id3_frametype\);/\1/' | \ -- sed -e '/\$$''Id: /s/\$$//g' >frametype.c -- --$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -- cd $(srcdir) && \ -- gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -- compat.gperf | \ -- sed -e 's/\(struct id3_compat\);/\1/' | \ -- sed -e '/\$$''Id: /s/\$$//g' >compat.c -- --$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -- cd $(srcdir) && \ -- sed -n -f genre.dat.sed genre.dat.in | \ -- sed -e '/\$$''Id: /s/\$$//g' >genre.dat -- - libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - -Index: lib-src/libid3tag/Makefile.in -=================================================================== ---- lib-src/libid3tag/Makefile.in (revision 13510) -+++ lib-src/libid3tag/Makefile.in (working copy) -@@ -415,8 +415,7 @@ - debug.c debug.h - - libid3tag_la_LDFLAGS = -version-info $(version_info) --BUILT_SOURCES = frametype.c compat.c genre.dat --all: $(BUILT_SOURCES) config.h -+all: config.h - $(MAKE) $(AM_MAKEFLAGS) all-recursive - - .SUFFIXES: -@@ -874,8 +873,7 @@ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 - check-am: all-am --check: $(BUILT_SOURCES) -- $(MAKE) $(AM_MAKEFLAGS) check-recursive -+check: check-recursive - all-am: Makefile $(LTLIBRARIES) $(HEADERS) config.h - installdirs: installdirs-recursive - installdirs-am: -@@ -882,8 +880,7 @@ - for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done --install: $(BUILT_SOURCES) -- $(MAKE) $(AM_MAKEFLAGS) install-recursive -+install: install-recursive - install-exec: install-exec-recursive - install-data: install-data-recursive - uninstall: uninstall-recursive -@@ -913,7 +910,6 @@ - maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -- -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) - clean: clean-recursive - - clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ -@@ -988,8 +984,7 @@ - - uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES - --.MAKE: $(am__recursive_targets) all check install install-am \ -- install-strip -+.MAKE: $(am__recursive_targets) all install-am install-strip - - .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--refresh check check-am clean clean-cscope clean-generic \ -@@ -1011,25 +1006,27 @@ - uninstall-includeHEADERS uninstall-libLTLIBRARIES - - --$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -- cd $(srcdir) && \ -- gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -- frametype.gperf | \ -- sed -e 's/\(struct id3_frametype\);/\1/' | \ -- sed -e '/\$$''Id: /s/\$$//g' >frametype.c -+#BUILT_SOURCES = frametype.c compat.c genre.dat -+# -+#$(srcdir)/frametype.c: $(srcdir)/frametype.gperf Makefile.am -+# cd $(srcdir) && \ -+# gperf -tCcTonD -K id -N id3_frametype_lookup -s -3 -k '*' \ -+# frametype.gperf | \ -+# sed -e 's/\(struct id3_frametype\);/\1/' | \ -+# sed -e '/\$$''Id: /s/\$$//g' >frametype.c -+# -+#$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -+# cd $(srcdir) && \ -+# gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -+# compat.gperf | \ -+# sed -e 's/\(struct id3_compat\);/\1/' | \ -+# sed -e '/\$$''Id: /s/\$$//g' >compat.c -+# -+#$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -+# cd $(srcdir) && \ -+# sed -n -f genre.dat.sed genre.dat.in | \ -+# sed -e '/\$$''Id: /s/\$$//g' >genre.dat - --$(srcdir)/compat.c: $(srcdir)/compat.gperf Makefile.am -- cd $(srcdir) && \ -- gperf -tCcTonD -K id -N id3_compat_lookup -s -3 -k '*' \ -- compat.gperf | \ -- sed -e 's/\(struct id3_compat\);/\1/' | \ -- sed -e '/\$$''Id: /s/\$$//g' >compat.c -- --$(srcdir)/genre.dat: $(srcdir)/genre.dat.in $(srcdir)/genre.dat.sed Makefile.am -- cd $(srcdir) && \ -- sed -n -f genre.dat.sed genre.dat.in | \ -- sed -e '/\$$''Id: /s/\$$//g' >genre.dat -- - libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - diff --git a/lib-src/libid3tag/libid3tag.list.in b/lib-src/libid3tag/libid3tag.list.in deleted file mode 100644 index 65731c2d8..000000000 --- a/lib-src/libid3tag/libid3tag.list.in +++ /dev/null @@ -1,21 +0,0 @@ -# @configure_input@ - -# Directories... -$prefix=@prefix@ -$exec_prefix=@exec_prefix@ -$srcdir=@srcdir@ - -# Product information -%product @PACKAGE@ -%copyright GPL -%vendor Underbit Technologies, Inc. -%license @srcdir@/COPYING -%readme @srcdir@/README -%description libid3tag is an ID3 tag manipulation library. -%version @VERSION@ -%packager Giuseppe "Cowo" Corbelli - -%system all -f 0755 root root @libdir@/libid3tag.la .libs/libid3tag.lai -f 0644 root root @libdir@/libid3tag.a .libs/libid3tag.a -f 0644 root root @includedir@/id3tag.h @srcdir@/id3tag.h diff --git a/lib-src/libid3tag/libid3tag.vcproj b/lib-src/libid3tag/libid3tag.vcproj deleted file mode 100644 index 0c6e914ec..000000000 --- a/lib-src/libid3tag/libid3tag.vcproj +++ /dev/null @@ -1,1971 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/lib-src/libid3tag/ltconfig b/lib-src/libid3tag/ltconfig deleted file mode 100755 index 65ec6f65d..000000000 --- a/lib-src/libid3tag/ltconfig +++ /dev/null @@ -1,3017 +0,0 @@ -#! /bin/sh - -# ltconfig - Create a system-specific libtool. -# Copyright (C) 1996-1999 Free Software Foundation, Inc. -# Originally by Gordon Matzigkeit , 1996 -# -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A lot of this script is taken from autoconf-2.10. - -# Check that we are running under the correct shell. -SHELL=${CONFIG_SHELL-/bin/sh} -echo=echo -if test "X$1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X$1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec "$SHELL" "$0" --no-reexec ${1+"$@"} -fi - -if test "X$1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null`} - case X$UNAME in - *-DOS) PATH_SEPARATOR=';' ;; - *) PATH_SEPARATOR=':' ;; - esac -fi - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -if test "${CDPATH+set}" = set; then CDPATH=; export CDPATH; fi - -if test "X${echo_test_string+set}" != "Xset"; then - # find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string="`eval $cmd`") 2>/dev/null && - echo_test_string="`eval $cmd`" && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null; then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" != 'X\t' || - test "X`($echo "$echo_test_string") 2>/dev/null`" != X"$echo_test_string"; then - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - for dir in $PATH /usr/ucb; do - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - test "X`($dir/echo "$echo_test_string") 2>/dev/null`" = X"$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - test "X`(print -r "$echo_test_string") 2>/dev/null`" = X"$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running ltconfig again with it. - ORIGINAL_CONFIG_SHELL="${CONFIG_SHELL-/bin/sh}" - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$0" --no-reexec ${1+"$@"} - else - # Try using printf. - echo='printf "%s\n"' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - test "X`($echo "$echo_test_string") 2>/dev/null`" = X"$echo_test_string"; then - # Cool, printf works - : - elif test "X`("$ORIGINAL_CONFIG_SHELL" "$0" --fallback-echo '\t') 2>/dev/null`" = 'X\t' && - test "X`("$ORIGINAL_CONFIG_SHELL" "$0" --fallback-echo "$echo_test_string") 2>/dev/null`" = X"$echo_test_string"; then - CONFIG_SHELL="$ORIGINAL_CONFIG_SHELL" - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL $0 --fallback-echo" - elif test "X`("$CONFIG_SHELL" "$0" --fallback-echo '\t') 2>/dev/null`" = 'X\t' && - test "X`("$CONFIG_SHELL" "$0" --fallback-echo "$echo_test_string") 2>/dev/null`" = X"$echo_test_string"; then - echo="$CONFIG_SHELL $0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null; then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "$0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec "${ORIGINAL_CONFIG_SHELL}" "$0" ${1+"$@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e s/^X//' -sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# The name of this program. -progname=`$echo "X$0" | $Xsed -e 's%^.*/%%'` - -# Constants: -PROGRAM=ltconfig -PACKAGE=libtool -VERSION=1.3.3 -TIMESTAMP=" (1.385.2.181 1999/07/02 15:49:11)" -ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.c 1>&5' -ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.c $LIBS 1>&5' -rm="rm -f" - -help="Try \`$progname --help' for more information." - -# Global variables: -default_ofile=libtool -can_build_shared=yes -enable_shared=yes -# All known linkers require a `.a' archive for static linking (except M$VC, -# which needs '.lib'). -enable_static=yes -enable_fast_install=yes -enable_dlopen=unknown -enable_win32_dll=no -ltmain= -silent= -srcdir= -ac_config_guess= -ac_config_sub= -host= -nonopt= -ofile="$default_ofile" -verify_host=yes -with_gcc=no -with_gnu_ld=no -need_locks=yes -ac_ext=c -objext=o -libext=a -exeext= -cache_file= - -old_AR="$AR" -old_CC="$CC" -old_CFLAGS="$CFLAGS" -old_CPPFLAGS="$CPPFLAGS" -old_LDFLAGS="$LDFLAGS" -old_LD="$LD" -old_LN_S="$LN_S" -old_LIBS="$LIBS" -old_NM="$NM" -old_RANLIB="$RANLIB" -old_DLLTOOL="$DLLTOOL" -old_OBJDUMP="$OBJDUMP" -old_AS="$AS" - -# Parse the command line options. -args= -prev= -for option -do - case "$option" in - -*=*) optarg=`echo "$option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; - *) optarg= ;; - esac - - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - eval "$prev=\$option" - prev= - continue - fi - - case "$option" in - --help) cat <&2 - echo "$help" 1>&2 - exit 1 - ;; - - *) - if test -z "$ltmain"; then - ltmain="$option" - elif test -z "$host"; then -# This generates an unnecessary warning for sparc-sun-solaris4.1.3_U1 -# if test -n "`echo $option| sed 's/[-a-z0-9.]//g'`"; then -# echo "$progname: warning \`$option' is not a valid host type" 1>&2 -# fi - host="$option" - else - echo "$progname: too many arguments" 1>&2 - echo "$help" 1>&2 - exit 1 - fi ;; - esac -done - -if test -z "$ltmain"; then - echo "$progname: you must specify a LTMAIN file" 1>&2 - echo "$help" 1>&2 - exit 1 -fi - -if test ! -f "$ltmain"; then - echo "$progname: \`$ltmain' does not exist" 1>&2 - echo "$help" 1>&2 - exit 1 -fi - -# Quote any args containing shell metacharacters. -ltconfig_args= -for arg -do - case "$arg" in - *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) - ltconfig_args="$ltconfig_args '$arg'" ;; - *) ltconfig_args="$ltconfig_args $arg" ;; - esac -done - -# A relevant subset of AC_INIT. - -# File descriptor usage: -# 0 standard input -# 1 file creation -# 2 errors and warnings -# 3 some systems may open it to /dev/tty -# 4 used on the Kubota Titan -# 5 compiler messages saved in config.log -# 6 checking for... messages and results -if test "$silent" = yes; then - exec 6>/dev/null -else - exec 6>&1 -fi -exec 5>>./config.log - -# NLS nuisances. -# Only set LANG and LC_ALL to C if already set. -# These must not be set unconditionally because not all systems understand -# e.g. LANG=C (notably SCO). -if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi -if test "${LANG+set}" = set; then LANG=C; export LANG; fi - -if test -n "$cache_file" && test -r "$cache_file"; then - echo "loading cache $cache_file within ltconfig" - . $cache_file -fi - -if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then - # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. - if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then - ac_n= ac_c=' -' ac_t=' ' - else - ac_n=-n ac_c= ac_t= - fi -else - ac_n= ac_c='\c' ac_t= -fi - -if test -z "$srcdir"; then - # Assume the source directory is the same one as the path to LTMAIN. - srcdir=`$echo "X$ltmain" | $Xsed -e 's%/[^/]*$%%'` - test "$srcdir" = "$ltmain" && srcdir=. -fi - -trap "$rm conftest*; exit 1" 1 2 15 -if test "$verify_host" = yes; then - # Check for config.guess and config.sub. - ac_aux_dir= - for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do - if test -f $ac_dir/config.guess; then - ac_aux_dir=$ac_dir - break - fi - done - if test -z "$ac_aux_dir"; then - echo "$progname: cannot find config.guess in $srcdir $srcdir/.. $srcdir/../.." 1>&2 - echo "$help" 1>&2 - exit 1 - fi - ac_config_guess=$ac_aux_dir/config.guess - ac_config_sub=$ac_aux_dir/config.sub - - # Make sure we can run config.sub. - if $SHELL $ac_config_sub sun4 >/dev/null 2>&1; then : - else - echo "$progname: cannot run $ac_config_sub" 1>&2 - echo "$help" 1>&2 - exit 1 - fi - - echo $ac_n "checking host system type""... $ac_c" 1>&6 - - host_alias=$host - case "$host_alias" in - "") - if host_alias=`$SHELL $ac_config_guess`; then : - else - echo "$progname: cannot guess host type; you must specify one" 1>&2 - echo "$help" 1>&2 - exit 1 - fi ;; - esac - host=`$SHELL $ac_config_sub $host_alias` - echo "$ac_t$host" 1>&6 - - # Make sure the host verified. - test -z "$host" && exit 1 - -elif test -z "$host"; then - echo "$progname: you must specify a host type if you use \`--no-verify'" 1>&2 - echo "$help" 1>&2 - exit 1 -else - host_alias=$host -fi - -# Transform linux* to *-*-linux-gnu*, to support old configure scripts. -case "$host_os" in -linux-gnu*) ;; -linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` -esac - -host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` -host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` -host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` - -case "$host_os" in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "${COLLECT_NAMES+set}" != set; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR cru $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -# Set a sane default for `AR'. -test -z "$AR" && AR=ar - -# Set a sane default for `OBJDUMP'. -test -z "$OBJDUMP" && OBJDUMP=objdump - -# If RANLIB is not set, then run the test. -if test "${RANLIB+set}" != "set"; then - result=no - - echo $ac_n "checking for ranlib... $ac_c" 1>&6 - IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - for dir in $PATH; do - test -z "$dir" && dir=. - if test -f $dir/ranlib || test -f $dir/ranlib$ac_exeext; then - RANLIB="ranlib" - result="ranlib" - break - fi - done - IFS="$save_ifs" - - echo "$ac_t$result" 1>&6 -fi - -if test -n "$RANLIB"; then - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" -fi - -# Set sane defaults for `DLLTOOL', `OBJDUMP', and `AS', used on cygwin. -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$AS" && AS=as - -# Check to see if we are using GCC. -if test "$with_gcc" != yes || test -z "$CC"; then - # If CC is not set, then try to find GCC or a usable CC. - if test -z "$CC"; then - echo $ac_n "checking for gcc... $ac_c" 1>&6 - IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - for dir in $PATH; do - test -z "$dir" && dir=. - if test -f $dir/gcc || test -f $dir/gcc$ac_exeext; then - CC="gcc" - break - fi - done - IFS="$save_ifs" - - if test -n "$CC"; then - echo "$ac_t$CC" 1>&6 - else - echo "$ac_t"no 1>&6 - fi - fi - - # Not "gcc", so try "cc", rejecting "/usr/ucb/cc". - if test -z "$CC"; then - echo $ac_n "checking for cc... $ac_c" 1>&6 - IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - cc_rejected=no - for dir in $PATH; do - test -z "$dir" && dir=. - if test -f $dir/cc || test -f $dir/cc$ac_exeext; then - if test "$dir/cc" = "/usr/ucb/cc"; then - cc_rejected=yes - continue - fi - CC="cc" - break - fi - done - IFS="$save_ifs" - if test $cc_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $CC - shift - if test $# -gt 0; then - # We chose a different compiler from the bogus one. - # However, it has the same name, so the bogon will be chosen - # first if we set CC to just the name; use the full file name. - shift - set dummy "$dir/cc" "$@" - shift - CC="$@" - fi - fi - - if test -n "$CC"; then - echo "$ac_t$CC" 1>&6 - else - echo "$ac_t"no 1>&6 - fi - - if test -z "$CC"; then - echo "$progname: error: no acceptable cc found in \$PATH" 1>&2 - exit 1 - fi - fi - - # Now see if the compiler is really GCC. - with_gcc=no - echo $ac_n "checking whether we are using GNU C... $ac_c" 1>&6 - echo "$progname:581: checking whether we are using GNU C" >&5 - - $rm conftest.c - cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then - with_gcc=yes - fi - $rm conftest.c - echo "$ac_t$with_gcc" 1>&6 -fi - -# Allow CC to be a program name with arguments. -set dummy $CC -compiler="$2" - -echo $ac_n "checking for object suffix... $ac_c" 1>&6 -$rm conftest* -echo 'int i = 1;' > conftest.c -echo "$progname:603: checking for object suffix" >& 5 -if { (eval echo $progname:604: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; }; then - # Append any warnings to the config.log. - cat conftest.err 1>&5 - - for ac_file in conftest.*; do - case $ac_file in - *.c) ;; - *) objext=`echo $ac_file | sed -e s/conftest.//` ;; - esac - done -else - cat conftest.err 1>&5 - echo "$progname: failed program was:" >&5 - cat conftest.c >&5 -fi -$rm conftest* -echo "$ac_t$objext" 1>&6 - -echo $ac_n "checking for executable suffix... $ac_c" 1>&6 -if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - ac_cv_exeext="no" - $rm conftest* - echo 'main () { return 0; }' > conftest.c - echo "$progname:629: checking for executable suffix" >& 5 - if { (eval echo $progname:630: \"$ac_link\") 1>&5; (eval $ac_link) 2>conftest.err; }; then - # Append any warnings to the config.log. - cat conftest.err 1>&5 - - for ac_file in conftest.*; do - case $ac_file in - *.c | *.err | *.$objext ) ;; - *) ac_cv_exeext=.`echo $ac_file | sed -e s/conftest.//` ;; - esac - done - else - cat conftest.err 1>&5 - echo "$progname: failed program was:" >&5 - cat conftest.c >&5 - fi - $rm conftest* -fi -if test "X$ac_cv_exeext" = Xno; then - exeext="" -else - exeext="$ac_cv_exeext" -fi -echo "$ac_t$ac_cv_exeext" 1>&6 - -echo $ac_n "checking for $compiler option to produce PIC... $ac_c" 1>&6 -pic_flag= -special_shlib_compile_flags= -wl= -link_static_flag= -no_builtin_flag= - -if test "$with_gcc" = yes; then - wl='-Wl,' - link_static_flag='-static' - - case "$host_os" in - beos* | irix5* | irix6* | osf3* | osf4*) - # PIC is the default for these OSes. - ;; - aix*) - # Below there is a dirty hack to force normal static linking with -ldl - # The problem is because libdl dynamically linked with both libc and - # libC (AIX C++ library), which obviously doesn't included in libraries - # list by gcc. This cause undefined symbols with -static flags. - # This hack allows C programs to be linked with "-static -ldl", but - # we not sure about C++ programs. - link_static_flag="$link_static_flag ${wl}-lC" - ;; - cygwin* | mingw* | os2*) - # We can build DLLs from non-PIC. - ;; - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - pic_flag='-m68020 -resident32 -malways-restore-a4' - ;; - sysv4*MP*) - if test -d /usr/nec; then - pic_flag=-Kconform_pic - fi - ;; - *) - pic_flag='-fPIC' - ;; - esac -else - # PORTME Check for PIC flags for the system compiler. - case "$host_os" in - aix3* | aix4*) - # All AIX code is PIC. - link_static_flag='-bnso -bI:/lib/syscalls.exp' - ;; - - hpux9* | hpux10* | hpux11*) - # Is there a better link_static_flag that works with the bundled CC? - wl='-Wl,' - link_static_flag="${wl}-a ${wl}archive" - pic_flag='+Z' - ;; - - irix5* | irix6*) - wl='-Wl,' - link_static_flag='-non_shared' - # PIC (with -KPIC) is the default. - ;; - - cygwin* | mingw* | os2*) - # We can build DLLs from non-PIC. - ;; - - osf3* | osf4*) - # All OSF/1 code is PIC. - wl='-Wl,' - link_static_flag='-non_shared' - ;; - - sco3.2v5*) - pic_flag='-Kpic' - link_static_flag='-dn' - special_shlib_compile_flags='-belf' - ;; - - solaris*) - pic_flag='-KPIC' - link_static_flag='-Bstatic' - wl='-Wl,' - ;; - - sunos4*) - pic_flag='-PIC' - link_static_flag='-Bstatic' - wl='-Qoption ld ' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - pic_flag='-KPIC' - link_static_flag='-Bstatic' - wl='-Wl,' - ;; - - uts4*) - pic_flag='-pic' - link_static_flag='-Bstatic' - ;; - sysv4*MP*) - if test -d /usr/nec ;then - pic_flag='-Kconform_pic' - link_static_flag='-Bstatic' - fi - ;; - *) - can_build_shared=no - ;; - esac -fi - -if test -n "$pic_flag"; then - echo "$ac_t$pic_flag" 1>&6 - - # Check to make sure the pic_flag actually works. - echo $ac_n "checking if $compiler PIC flag $pic_flag works... $ac_c" 1>&6 - $rm conftest* - echo "int some_variable = 0;" > conftest.c - save_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS $pic_flag -DPIC" - echo "$progname:776: checking if $compiler PIC flag $pic_flag works" >&5 - if { (eval echo $progname:777: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; } && test -s conftest.$objext; then - # Append any warnings to the config.log. - cat conftest.err 1>&5 - - case "$host_os" in - hpux9* | hpux10* | hpux11*) - # On HP-UX, both CC and GCC only warn that PIC is supported... then they - # create non-PIC objects. So, if there were any warnings, we assume that - # PIC is not supported. - if test -s conftest.err; then - echo "$ac_t"no 1>&6 - can_build_shared=no - pic_flag= - else - echo "$ac_t"yes 1>&6 - pic_flag=" $pic_flag" - fi - ;; - *) - echo "$ac_t"yes 1>&6 - pic_flag=" $pic_flag" - ;; - esac - else - # Append any errors to the config.log. - cat conftest.err 1>&5 - can_build_shared=no - pic_flag= - echo "$ac_t"no 1>&6 - fi - CFLAGS="$save_CFLAGS" - $rm conftest* -else - echo "$ac_t"none 1>&6 -fi - -# Check to see if options -o and -c are simultaneously supported by compiler -echo $ac_n "checking if $compiler supports -c -o file.o... $ac_c" 1>&6 -$rm -r conftest 2>/dev/null -mkdir conftest -cd conftest -$rm conftest* -echo "int some_variable = 0;" > conftest.c -mkdir out -# According to Tom Tromey, Ian Lance Taylor reported there are C compilers -# that will create temporary files in the current directory regardless of -# the output directory. Thus, making CWD read-only will cause this test -# to fail, enabling locking or at least warning the user not to do parallel -# builds. -chmod -w . -save_CFLAGS="$CFLAGS" -CFLAGS="$CFLAGS -o out/conftest2.o" -echo "$progname:829: checking if $compiler supports -c -o file.o" >&5 -if { (eval echo $progname:830: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.o; then - - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s out/conftest.err; then - echo "$ac_t"no 1>&6 - compiler_c_o=no - else - echo "$ac_t"yes 1>&6 - compiler_c_o=yes - fi -else - # Append any errors to the config.log. - cat out/conftest.err 1>&5 - compiler_c_o=no - echo "$ac_t"no 1>&6 -fi -CFLAGS="$save_CFLAGS" -chmod u+w . -$rm conftest* out/* -rmdir out -cd .. -rmdir conftest -$rm -r conftest 2>/dev/null - -if test x"$compiler_c_o" = x"yes"; then - # Check to see if we can write to a .lo - echo $ac_n "checking if $compiler supports -c -o file.lo... $ac_c" 1>&6 - $rm conftest* - echo "int some_variable = 0;" > conftest.c - save_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -c -o conftest.lo" - echo "$progname:862: checking if $compiler supports -c -o file.lo" >&5 -if { (eval echo $progname:863: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; } && test -s conftest.lo; then - - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - echo "$ac_t"no 1>&6 - compiler_o_lo=no - else - echo "$ac_t"yes 1>&6 - compiler_o_lo=yes - fi - else - # Append any errors to the config.log. - cat conftest.err 1>&5 - compiler_o_lo=no - echo "$ac_t"no 1>&6 - fi - CFLAGS="$save_CFLAGS" - $rm conftest* -else - compiler_o_lo=no -fi - -# Check to see if we can do hard links to lock some files if needed -hard_links="nottested" -if test "$compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - echo $ac_n "checking if we can lock with hard links... $ac_c" 1>&6 - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - echo "$ac_t$hard_links" 1>&6 - $rm conftest* - if test "$hard_links" = no; then - echo "*** WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2 - need_locks=warn - fi -else - need_locks=no -fi - -if test "$with_gcc" = yes; then - # Check to see if options -fno-rtti -fno-exceptions are supported by compiler - echo $ac_n "checking if $compiler supports -fno-rtti -fno-exceptions ... $ac_c" 1>&6 - $rm conftest* - echo "int some_variable = 0;" > conftest.c - save_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.c" - echo "$progname:914: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 - if { (eval echo $progname:915: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; } && test -s conftest.o; then - - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - echo "$ac_t"no 1>&6 - compiler_rtti_exceptions=no - else - echo "$ac_t"yes 1>&6 - compiler_rtti_exceptions=yes - fi - else - # Append any errors to the config.log. - cat conftest.err 1>&5 - compiler_rtti_exceptions=no - echo "$ac_t"no 1>&6 - fi - CFLAGS="$save_CFLAGS" - $rm conftest* - - if test "$compiler_rtti_exceptions" = "yes"; then - no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions' - else - no_builtin_flag=' -fno-builtin' - fi - -fi - -# Check for any special shared library compilation flags. -if test -n "$special_shlib_compile_flags"; then - echo "$progname: warning: \`$CC' requires \`$special_shlib_compile_flags' to build shared libraries" 1>&2 - if echo "$old_CC $old_CFLAGS " | egrep -e "[ ]$special_shlib_compile_flags[ ]" >/dev/null; then : - else - echo "$progname: add \`$special_shlib_compile_flags' to the CC or CFLAGS env variable and reconfigure" 1>&2 - can_build_shared=no - fi -fi - -echo $ac_n "checking if $compiler static flag $link_static_flag works... $ac_c" 1>&6 -$rm conftest* -echo 'main(){return(0);}' > conftest.c -save_LDFLAGS="$LDFLAGS" -LDFLAGS="$LDFLAGS $link_static_flag" -echo "$progname:958: checking if $compiler static flag $link_static_flag works" >&5 -if { (eval echo $progname:959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then - echo "$ac_t$link_static_flag" 1>&6 -else - echo "$ac_t"none 1>&6 - link_static_flag= -fi -LDFLAGS="$save_LDFLAGS" -$rm conftest* - -if test -z "$LN_S"; then - # Check to see if we can use ln -s, or we need hard links. - echo $ac_n "checking whether ln -s works... $ac_c" 1>&6 - $rm conftest.dat - if ln -s X conftest.dat 2>/dev/null; then - $rm conftest.dat - LN_S="ln -s" - else - LN_S=ln - fi - if test "$LN_S" = "ln -s"; then - echo "$ac_t"yes 1>&6 - else - echo "$ac_t"no 1>&6 - fi -fi - -# Make sure LD is an absolute path. -if test -z "$LD"; then - ac_prog=ld - if test "$with_gcc" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - echo $ac_n "checking for ld used by GCC... $ac_c" 1>&6 - echo "$progname:991: checking for ld used by GCC" >&5 - ac_prog=`($CC -print-prog-name=ld) 2>&5` - case "$ac_prog" in - # Accept absolute paths. - [\\/]* | [A-Za-z]:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the path of ld - ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we are not using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac - elif test "$with_gnu_ld" = yes; then - echo $ac_n "checking for GNU ld... $ac_c" 1>&6 - echo "$progname:1015: checking for GNU ld" >&5 - else - echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6 - echo "$progname:1018: checking for non-GNU ld" >&5 - fi - - if test -z "$LD"; then - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - for ac_dir in $PATH; do - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some GNU ld's only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - if "$LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then - test "$with_gnu_ld" != no && break - else - test "$with_gnu_ld" != yes && break - fi - fi - done - IFS="$ac_save_ifs" - fi - - if test -n "$LD"; then - echo "$ac_t$LD" 1>&6 - else - echo "$ac_t"no 1>&6 - fi - - if test -z "$LD"; then - echo "$progname: error: no acceptable ld found in \$PATH" 1>&2 - exit 1 - fi -fi - -# Check to see if it really is or is not GNU ld. -echo $ac_n "checking if the linker ($LD) is GNU ld... $ac_c" 1>&6 -# I'd rather use --version here, but apparently some GNU ld's only accept -v. -if $LD -v 2>&1 &5; then - with_gnu_ld=yes -else - with_gnu_ld=no -fi -echo "$ac_t$with_gnu_ld" 1>&6 - -# See if the linker supports building shared libraries. -echo $ac_n "checking whether the linker ($LD) supports shared libraries... $ac_c" 1>&6 - -allow_undefined_flag= -no_undefined_flag= -need_lib_prefix=unknown -need_version=unknown -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -archive_cmds= -archive_expsym_cmds= -old_archive_from_new_cmds= -export_dynamic_flag_spec= -whole_archive_flag_spec= -thread_safe_flag_spec= -hardcode_libdir_flag_spec= -hardcode_libdir_separator= -hardcode_direct=no -hardcode_minus_L=no -hardcode_shlibpath_var=unsupported -runpath_var= -always_export_symbols=no -export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols' -# include_expsyms should be a list of space-separated symbols to be *always* -# included in the symbol list -include_expsyms= -# exclude_expsyms can be an egrep regular expression of symbols to exclude -# it will be wrapped by ` (' and `)$', so one must not match beginning or -# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', -# as well as any symbol that contains `d'. -exclude_expsyms="_GLOBAL_OFFSET_TABLE_" -# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out -# platforms (ab)use it in PIC code, but their linkers get confused if -# the symbol is explicitly referenced. Since portable code cannot -# rely on this symbol name, it's probably fine to never include it in -# preloaded symbol tables. - -case "$host_os" in -cygwin* | mingw*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$with_gcc" != yes; then - with_gnu_ld=no - fi - ;; - -esac - -ld_shlibs=yes -if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # See if GNU ld supports shared libraries. - case "$host_os" in - aix3* | aix4*) - # On AIX, the GNU linker is very broken - ld_shlibs=no - cat <&2 - -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. - -EOF - ;; - - amigaos*) - archive_cmds='$rm $objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $objdir/a2ixlibrary.data~$AR cru $lib $libobjs~$RANLIB $lib~(cd $objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can use - # them. - ld_shlibs=no - ;; - - beos*) - if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - - cygwin* | mingw*) - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - allow_undefined_flag=unsupported - always_export_symbols=yes - - # Extract the symbol export list from an `--export-all' def file, - # then regenerate the def file from the symbol export list, so that - # the compiled dll only exports the symbol export list. - export_symbols_cmds='test -f $objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < $0 > $objdir/$soname-ltdll.c~ - test -f $objdir/$soname-ltdll.$objext || (cd $objdir && $CC -c $soname-ltdll.c)~ - $DLLTOOL --export-all --exclude-symbols DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12 --output-def $objdir/$soname-def $objdir/$soname-ltdll.$objext $libobjs $convenience~ - sed -e "1,/EXPORTS/d" -e "s/ @ [0-9]* ; *//" < $objdir/$soname-def > $export_symbols' - - archive_expsym_cmds='echo EXPORTS > $objdir/$soname-def~ - _lt_hint=1; - for symbol in `cat $export_symbols`; do - echo " \$symbol @ \$_lt_hint ; " >> $objdir/$soname-def; - _lt_hint=`expr 1 + \$_lt_hint`; - done~ - test -f $objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < $0 > $objdir/$soname-ltdll.c~ - test -f $objdir/$soname-ltdll.$objext || (cd $objdir && $CC -c $soname-ltdll.c)~ - $CC -Wl,--base-file,$objdir/$soname-base -Wl,--dll -nostartfiles -Wl,-e,__cygwin_dll_entry@12 -o $lib $objdir/$soname-ltdll.$objext $libobjs $deplibs $linkopts~ - $DLLTOOL --as=$AS --dllname $soname --exclude-symbols DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12 --def $objdir/$soname-def --base-file $objdir/$soname-base --output-exp $objdir/$soname-exp~ - $CC -Wl,--base-file,$objdir/$soname-base $objdir/$soname-exp -Wl,--dll -nostartfiles -Wl,-e,__cygwin_dll_entry@12 -o $lib $objdir/$soname-ltdll.$objext $libobjs $deplibs $linkopts~ - $DLLTOOL --as=$AS --dllname $soname --exclude-symbols DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12 --def $objdir/$soname-def --base-file $objdir/$soname-base --output-exp $objdir/$soname-exp~ - $CC $objdir/$soname-exp -Wl,--dll -nostartfiles -Wl,-e,__cygwin_dll_entry@12 -o $lib $objdir/$soname-ltdll.$objext $libobjs $deplibs $linkopts' - - old_archive_from_new_cmds='$DLLTOOL --as=$AS --dllname $soname --def $objdir/$soname-def --output-lib $objdir/$libname.a' - ;; - - netbsd*) - if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - archive_cmds='$LD -Bshareable $libobjs $deplibs $linkopts -o $lib' - # can we support soname and/or expsyms with a.out? -oliva - fi - ;; - - solaris*) - if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -EOF - elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linkopts' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - *) - if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - - if test "$ld_shlibs" = yes; then - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - case $host_os in - cygwin* | mingw*) - # dlltool doesn't understand --whole-archive et. al. - whole_archive_flag_spec= - ;; - *) - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - ;; - esac - fi -else - # PORTME fill in a description of your system's linker (not GNU ld) - case "$host_os" in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $objdir/$soname $libobjs $deplibs $linkopts -bE:$export_symbols -T512 -H512 -bM:SRE~$AR cru $lib $objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$with_gcc" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - - aix4*) - hardcode_libdir_flag_spec='${wl}-b ${wl}nolibpath ${wl}-b ${wl}libpath:$libdir:/usr/lib:/lib' - hardcode_libdir_separator=':' - if test "$with_gcc" = yes; then - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct=yes - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - shared_flag='-shared' - else - shared_flag='${wl}-bM:SRE' - hardcode_direct=yes - fi - allow_undefined_flag=' ${wl}-berok' - archive_cmds="\$CC $shared_flag"' -o $objdir/$soname $libobjs $deplibs $linkopts ${wl}-bexpall ${wl}-bnoentry${allow_undefined_flag}' - archive_expsym_cmds="\$CC $shared_flag"' -o $objdir/$soname $libobjs $deplibs $linkopts ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}' - case "$host_os" in aix4.[01]|aix4.[01].*) - # According to Greg Wooledge, -bexpall is only supported from AIX 4.2 on - always_export_symbols=yes ;; - esac - ;; - - amigaos*) - archive_cmds='$rm $objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $objdir/a2ixlibrary.data~$AR cru $lib $libobjs~$RANLIB $lib~(cd $objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - # see comment about different semantics on the GNU ld section - ld_shlibs=no - ;; - - cygwin* | mingw*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $linkopts `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib /OUT:$oldlib$oldobjs' - fix_srcfile_path='`cygpath -w $srcfile`' - ;; - - freebsd1*) - ld_shlibs=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $linkopts' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9* | hpux10* | hpux11*) - case "$host_os" in - hpux9*) archive_cmds='$rm $objdir/$soname~$LD -b +b $install_libdir -o $objdir/$soname $libobjs $deplibs $linkopts~test $objdir/$soname = $lib || mv $objdir/$soname $lib' ;; - *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linkopts' ;; - esac - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_minus_L=yes # Not in the search PATH, but as the default - # location of the library. - export_dynamic_flag_spec='${wl}-E' - ;; - - irix5* | irix6*) - if test "$with_gcc" = yes; then - archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib' - else - archive_cmds='$LD -shared $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linkopts' # ELF - fi - hardcode_libdir_flag_spec='${wl}-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - openbsd*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linkopts' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $objdir/$libname.def~$echo DATA >> $objdir/$libname.def~$echo " SINGLE NONSHARED" >> $objdir/$libname.def~$echo EXPORTS >> $objdir/$libname.def~emxexp $libobjs >> $objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $linkopts $objdir/$libname.def' - old_archive_from_new_cmds='emximp -o $objdir/$libname.a $objdir/$libname.def' - ;; - - osf3* | osf4*) - if test "$with_gcc" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - - sco3.2v5*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - - solaris*) - no_undefined_flag=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linkopts' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linkopts~$rm $lib.exp' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case "$host_os" in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) # Supported since Solaris 2.6 (maybe 2.5.1?) - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; - esac - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linkopts' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - sysv4) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts' - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - # archive_cmds='$LD -G -z text -h $soname -o $lib$libobjs$deplibs' - archive_cmds='$LD -G -h $soname -o $lib$libobjs$deplibs' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - *) - ld_shlibs=no - ;; - esac -fi -echo "$ac_t$ld_shlibs" 1>&6 -test "$ld_shlibs" = no && can_build_shared=no - -if test -z "$NM"; then - echo $ac_n "checking for BSD-compatible nm... $ac_c" 1>&6 - case "$NM" in - [\\/]* | [A-Za-z]:[\\/]*) ;; # Let the user override the test with a path. - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" - for ac_dir in $PATH /usr/ucb /usr/ccs/bin /bin; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then - NM="$ac_dir/nm -B" - break - elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then - NM="$ac_dir/nm -p" - break - else - NM=${NM="$ac_dir/nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - fi - fi - done - IFS="$ac_save_ifs" - test -z "$NM" && NM=nm - ;; - esac - echo "$ac_t$NM" 1>&6 -fi - -# Check for command to grab the raw symbol name followed by C symbol from nm. -echo $ac_n "checking command to parse $NM output... $ac_c" 1>&6 - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - -# Transform the above into a raw symbol and a C symbol. -symxfrm='\1 \2\3 \3' - -# Transform an extracted symbol line into a proper C declaration -global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'" - -# Define system-specific variables. -case "$host_os" in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw*) - symcode='[ABCDGISTW]' - ;; -hpux*) # Its linker distinguishes data from code symbols - global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^. .* \(.*\)$/extern char \1;/p'" - ;; -irix*) - symcode='[BCDEGRST]' - ;; -solaris*) - symcode='[BDT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then - symcode='[ABCDGISTW]' -fi - -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Write the raw and C identifiers. - global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode\)[ ][ ]*\($ac_symprfx\)$sympat$/$symxfrm/p'" - - # Check to see that the pipe works correctly. - pipe_works=no - $rm conftest* - cat > conftest.c <&5 - if { (eval echo $progname:1593: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } && test -s conftest.$objext; then - # Now try to grab the symbols. - nlist=conftest.nm - if { echo "$progname:1596: eval \"$NM conftest.$objext | $global_symbol_pipe > $nlist\"" >&5; eval "$NM conftest.$objext | $global_symbol_pipe > $nlist 2>&5"; } && test -s "$nlist"; then - - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if egrep ' nm_test_var$' "$nlist" >/dev/null; then - if egrep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.c -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$global_symbol_to_cdecl"' < "$nlist" >> conftest.c' - - cat <> conftest.c -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[] = -{ -EOF - sed 's/^. \(.*\) \(.*\)$/ {"\2", (lt_ptr_t) \&\2},/' < "$nlist" >> conftest.c - cat <<\EOF >> conftest.c - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$objext conftstm.$objext - save_LIBS="$LIBS" - save_CFLAGS="$CFLAGS" - LIBS="conftstm.$objext" - CFLAGS="$CFLAGS$no_builtin_flag" - if { (eval echo $progname:1648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then - pipe_works=yes - else - echo "$progname: failed program was:" >&5 - cat conftest.c >&5 - fi - LIBS="$save_LIBS" - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.c >&5 - fi - $rm conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - global_symbol_pipe= - fi -done -if test "$pipe_works" = yes; then - echo "${ac_t}ok" 1>&6 -else - echo "${ac_t}failed" 1>&6 -fi - -if test -z "$global_symbol_pipe"; then - global_symbol_to_cdecl= -fi - -# Check hardcoding attributes. -echo $ac_n "checking how to hardcode library paths into programs... $ac_c" 1>&6 -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || \ - test -n "$runpath_var"; then - - # We can hardcode non-existant directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$hardcode_shlibpath_var" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -echo "$ac_t$hardcode_action" 1>&6 - - -reload_flag= -reload_cmds='$LD$reload_flag -o $output$reload_objs' -echo $ac_n "checking for $LD option to reload object files... $ac_c" 1>&6 -# PORTME Some linkers may need a different reload flag. -reload_flag='-r' -echo "$ac_t$reload_flag" 1>&6 -test -n "$reload_flag" && reload_flag=" $reload_flag" - -# PORTME Fill in your ld.so characteristics -library_names_spec= -libname_spec='lib$name' -soname_spec= -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -file_magic_cmd= -file_magic_test_file= -deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [regex]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given egrep regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. -echo $ac_n "checking dynamic linker characteristics... $ac_c" 1>&6 -case "$host_os" in -aix3*) - version_type=linux - library_names_spec='${libname}${release}.so$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}.so$major' - ;; - -aix4*) - version_type=linux - # AIX has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - # We preserve .a as extension for shared libraries though AIX4.2 - # and later linker supports .so - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.a' - shlibpath_var=LIBPATH - deplibs_check_method=pass_all - ;; - -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "(cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a)"; (cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a) || exit 1; done' - ;; - -beos*) - library_names_spec='${libname}.so' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - deplibs_check_method=pass_all - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - -bsdi4*) - version_type=linux - library_names_spec='${libname}.so$major ${libname}.so' - soname_spec='${libname}.so' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - file_magic_cmd=/usr/bin/file - file_magic_test_file=/shlib/libc.so - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw*) - version_type=windows - need_version=no - need_lib_prefix=no - if test "$with_gcc" = yes; then - library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll $libname.a' - else - library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll $libname.lib' - fi - dynamic_linker='Win32 ld.exe' - deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - file_magic_cmd='${OBJDUMP} -f' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - -freebsd1*) - dynamic_linker=no - ;; - -freebsd*) - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case "$version_type" in - freebsd-elf*) - deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object' - file_magic_cmd=/usr/bin/file - file_magic_test_file=`echo /usr/lib/libc.so*` - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - deplibs_check_method=unknown - library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix' - need_version=yes - ;; - esac - finish_cmds='PATH="\$PATH:/sbin" OBJFORMAT="'"$objformat"'" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - case "$host_os" in - freebsd2* | freebsd3.[01]*) - shlibpath_overrides_runpath=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - ;; - esac - ;; - -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so' - soname_spec='${libname}${release}.so$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - dynamic_linker="$host_os dld.sl" - version_type=sunos - need_lib_prefix=no - need_version=no - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl' - soname_spec='${libname}${release}.sl$major' - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; - -irix5* | irix6*) - version_type=irix - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}.so.$major' - library_names_spec='${libname}${release}.so.$versuffix ${libname}${release}.so.$major ${libname}${release}.so $libname.so' - case "$host_os" in - irix5*) - libsuff= shlibsuff= - # this will be overridden with pass_all, but let us keep it just in case - deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1" - ;; - *) - case "$LD" in # libtool.m4 will add one of these switches to LD - *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - # this will be overridden with pass_all, but let us keep it just in case - deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1" - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - file_magic_cmd=/usr/bin/file - file_magic_test_file=`echo /lib${libsuff}/libc.so*` - deplibs_check_method='pass_all' - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*) - dynamic_linker=no - ;; - -# This must be Linux ELF. -linux-gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - soname_spec='${libname}${release}.so$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - file_magic_cmd=/usr/bin/file - file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` - - if test -f /lib/ld.so.1; then - dynamic_linker='GNU ld.so' - else - # Only the GNU ld.so supports shared libraries on MkLinux. - case "$host_cpu" in - powerpc*) dynamic_linker=no ;; - *) dynamic_linker='Linux ld.so' ;; - esac - fi - ;; - -netbsd*) - version_type=sunos - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so' - soname_spec='${libname}${release}.so$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - ;; - -openbsd*) - version_type=sunos - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - need_version=no - fi - library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - ;; - -os2*) - libname_spec='$name' - need_lib_prefix=no - library_names_spec='$libname.dll $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4*) - version_type=osf - need_version=no - soname_spec='${libname}${release}.so' - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so' - shlibpath_var=LD_LIBRARY_PATH - # this will be overridden with pass_all, but let us keep it just in case - deplibs_check_method='file_magic COFF format alpha shared library' - file_magic_cmd=/usr/bin/file - file_magic_test_file=/shlib/libc.so - deplibs_check_method='pass_all' - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}.so$major' - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - shlibpath_var=LD_LIBRARY_PATH - ;; - -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - soname_spec='${libname}${release}.so$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - deplibs_check_method="file_magic ELF [0-9][0-9]-bit [LM]SB dynamic lib" - file_magic_cmd=/usr/bin/file - file_magic_test_file=/lib/libc.so - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - soname_spec='${libname}${release}.so$major' - shlibpath_var=LD_LIBRARY_PATH - case "$host_vendor" in - ncr) - deplibs_check_method='pass_all' - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - 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]' - file_magic_cmd=/usr/bin/file - file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - esac - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - soname_spec='${libname}${release}.so$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' - soname_spec='${libname}${release}.so$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so' - soname_spec='$libname.so.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -*) - dynamic_linker=no - ;; -esac -echo "$ac_t$dynamic_linker" 1>&6 -test "$dynamic_linker" = no && can_build_shared=no - -# Report the final consequences. -echo "checking if libtool supports shared libraries... $can_build_shared" 1>&6 - -# Only try to build win32 dlls if AC_LIBTOOL_WIN32_DLL was used in -# configure.in, otherwise build static only libraries. -case "$host_os" in -cygwin* | mingw* | os2*) - if test x$can_build_shared = xyes; then - test x$enable_win32_dll = xno && can_build_shared=no - echo "checking if package supports dlls... $can_build_shared" 1>&6 - fi -;; -esac - -if test -n "$file_magic_test_file" && test -n "$file_magic_cmd"; then - case "$deplibs_check_method" in - "file_magic "*) - file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - egrep "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac -fi - -echo $ac_n "checking whether to build shared libraries... $ac_c" 1>&6 -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case "$host_os" in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - -aix4*) - test "$enable_shared" = yes && enable_static=no - ;; -esac - -echo "$ac_t$enable_shared" 1>&6 - -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes - -echo "checking whether to build static libraries... $enable_static" 1>&6 - -if test "$hardcode_action" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi - -echo $ac_n "checking for objdir... $ac_c" 1>&6 -rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - objdir=_libs -fi -rmdir .libs 2>/dev/null -echo "$ac_t$objdir" 1>&6 - -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else -if eval "test \"`echo '$''{'lt_cv_dlopen'+set}'`\" != set"; then - lt_cv_dlopen=no lt_cv_dlopen_libs= -echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "$progname:2170: checking for dlopen in -ldl" >&5 -ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - ac_save_LIBS="$LIBS" -LIBS="-ldl $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - echo "$ac_t""no" 1>&6 -echo $ac_n "checking for dlopen""... $ac_c" 1>&6 -echo "$progname:2207: checking for dlopen" >&5 -if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char dlopen(); - -int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_dlopen) || defined (__stub___dlopen) -choke me -#else -dlopen(); -#endif - -; return 0; } -EOF -if { (eval echo $progname:2234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_func_dlopen=yes" -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_dlopen=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then - echo "$ac_t""yes" 1>&6 - lt_cv_dlopen="dlopen" -else - echo "$ac_t""no" 1>&6 -echo $ac_n "checking for dld_link in -ldld""... $ac_c" 1>&6 -echo "$progname:2251: checking for dld_link in -ldld" >&5 -ac_lib_var=`echo dld'_'dld_link | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - ac_save_LIBS="$LIBS" -LIBS="-ldld $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" -else - echo "$ac_t""no" 1>&6 -echo $ac_n "checking for shl_load""... $ac_c" 1>&6 -echo "$progname:2288: checking for shl_load" >&5 -if eval "test \"`echo '$''{'ac_cv_func_shl_load'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char shl_load(); - -int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_shl_load) || defined (__stub___shl_load) -choke me -#else -shl_load(); -#endif - -; return 0; } -EOF -if { (eval echo $progname:2315: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_func_shl_load=yes" -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_shl_load=no" -fi -rm -f conftest* -fi - -if eval "test \"`echo '$ac_cv_func_'shl_load`\" = yes"; then - echo "$ac_t""yes" 1>&6 - lt_cv_dlopen="shl_load" -else - echo "$ac_t""no" 1>&6 -echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "$progname:2333: checking for shl_load in -ldld" >&5 -ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - ac_save_LIBS="$LIBS" -LIBS="-ldld $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" -else - echo "$ac_t""no" 1>&6 -fi - - -fi - - -fi - - -fi - - -fi - -fi - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - fi - - case "$lt_cv_dlopen" in - dlopen) -for ac_hdr in dlfcn.h; do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "$progname:2395: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < -int fnord = 0; -EOF -ac_try="$ac_compile conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo $progname:2405: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi -done - - if test "x$ac_cv_header_dlfcn_h" = xyes; then - CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - fi - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - LIBS="$lt_cv_dlopen_libs $LIBS" - - echo $ac_n "checking whether a program can dlopen itself""... $ac_c" 1>&6 -echo "$progname:2433: checking whether a program can dlopen itself" >&5 -if test "${lt_cv_dlopen_self+set}" = set; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - if test "$cross_compiling" = yes; then - lt_cv_dlopen_self=cross - else - cat > conftest.c < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LTDL_GLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LTDL_GLOBAL DL_GLOBAL -# else -# define LTDL_GLOBAL 0 -# endif -#endif - -/* We may have to define LTDL_LAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LTDL_LAZY_OR_NOW -# ifdef RTLD_LAZY -# define LTDL_LAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LTDL_LAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LTDL_LAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LTDL_LAZY_OR_NOW DL_NOW -# else -# define LTDL_LAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -fnord() { int i=42;} -main() { void *self, *ptr1, *ptr2; self=dlopen(0,LTDL_GLOBAL|LTDL_LAZY_OR_NOW); - if(self) { ptr1=dlsym(self,"fnord"); ptr2=dlsym(self,"_fnord"); - if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); } - -EOF -if { (eval echo $progname:2487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null -then - lt_cv_dlopen_self=yes -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -fr conftest* - lt_cv_dlopen_self=no -fi -rm -fr conftest* -fi - -fi - -echo "$ac_t""$lt_cv_dlopen_self" 1>&6 - - if test "$lt_cv_dlopen_self" = yes; then - LDFLAGS="$LDFLAGS $link_static_flag" - echo $ac_n "checking whether a statically linked program can dlopen itself""... $ac_c" 1>&6 -echo "$progname:2506: checking whether a statically linked program can dlopen itself" >&5 -if test "${lt_cv_dlopen_self_static+set}" = set; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - if test "$cross_compiling" = yes; then - lt_cv_dlopen_self_static=cross - else - cat > conftest.c < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LTDL_GLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LTDL_GLOBAL DL_GLOBAL -# else -# define LTDL_GLOBAL 0 -# endif -#endif - -/* We may have to define LTDL_LAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LTDL_LAZY_OR_NOW -# ifdef RTLD_LAZY -# define LTDL_LAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LTDL_LAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LTDL_LAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LTDL_LAZY_OR_NOW DL_NOW -# else -# define LTDL_LAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -fnord() { int i=42;} -main() { void *self, *ptr1, *ptr2; self=dlopen(0,LTDL_GLOBAL|LTDL_LAZY_OR_NOW); - if(self) { ptr1=dlsym(self,"fnord"); ptr2=dlsym(self,"_fnord"); - if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); } - -EOF -if { (eval echo $progname:2560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null -then - lt_cv_dlopen_self_static=yes -else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -fr conftest* - lt_cv_dlopen_self_static=no -fi -rm -fr conftest* -fi - -fi - -echo "$ac_t""$lt_cv_dlopen_self_static" 1>&6 -fi - ;; - esac - - case "$lt_cv_dlopen_self" in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case "$lt_cv_dlopen_self_static" in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi - -# Copy echo and quote the copy, instead of the original, because it is -# used later. -ltecho="$echo" -if test "X$ltecho" = "X$CONFIG_SHELL $0 --fallback-echo"; then - ltecho="$CONFIG_SHELL \$0 --fallback-echo" -fi -LTSHELL="$SHELL" - -LTCONFIG_VERSION="$VERSION" - -# Only quote variables if we're using ltmain.sh. -case "$ltmain" in -*.sh) - # Now quote all the things that may contain metacharacters. - for var in ltecho old_CC old_CFLAGS old_CPPFLAGS \ - old_LD old_LDFLAGS old_LIBS \ - old_NM old_RANLIB old_LN_S old_DLLTOOL old_OBJDUMP old_AS \ - AR CC LD LN_S NM LTSHELL LTCONFIG_VERSION \ - reload_flag reload_cmds wl \ - pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \ - thread_safe_flag_spec whole_archive_flag_spec libname_spec \ - library_names_spec soname_spec \ - RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \ - old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds postuninstall_cmds \ - file_magic_cmd export_symbols_cmds deplibs_check_method allow_undefined_flag no_undefined_flag \ - finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \ - hardcode_libdir_flag_spec hardcode_libdir_separator \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do - - case "$var" in - reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - export_symbols_cmds | archive_cmds | archive_expsym_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done - - case "$ltecho" in - *'\$0 --fallback-echo"') - ltecho=`$echo "X$ltecho" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac - - trap "$rm \"$ofile\"; exit 1" 1 2 15 - echo "creating $ofile" - $rm "$ofile" - cat < "$ofile" -#! $SHELL - -# `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltconfig or ltmain.sh. -# -# Copyright (C) 1996-1999 Free Software Foundation, Inc. -# Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="sed -e s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -if test "\${CDPATH+set}" = set; then CDPATH=; export CDPATH; fi - -### BEGIN LIBTOOL CONFIG -EOF - cfgfile="$ofile" - ;; - -*) - # Double-quote the variables that need it (for aesthetics). - for var in old_CC old_CFLAGS old_CPPFLAGS \ - old_LD old_LDFLAGS old_LIBS \ - old_NM old_RANLIB old_LN_S old_DLLTOOL old_OBJDUMP old_AS; do - eval "$var=\\\"\$var\\\"" - done - - # Just create a config file. - cfgfile="$ofile.cfg" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - echo "creating $cfgfile" - $rm "$cfgfile" - cat < "$cfgfile" -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Libtool configuration file. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -EOF - ;; -esac - -cat <> "$cfgfile" -# Libtool was configured as follows, on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# -# CC=$old_CC CFLAGS=$old_CFLAGS CPPFLAGS=$old_CPPFLAGS \\ -# LD=$old_LD LDFLAGS=$old_LDFLAGS LIBS=$old_LIBS \\ -# NM=$old_NM RANLIB=$old_RANLIB LN_S=$old_LN_S \\ -# DLLTOOL=$old_DLLTOOL OBJDUMP=$old_OBJDUMP AS=$old_AS \\ -# $0$ltconfig_args -# -# Compiler and other test output produced by $progname, useful for -# debugging $progname, is in ./config.log if it exists. - -# The version of $progname that generated this script. -LTCONFIG_VERSION=$LTCONFIG_VERSION - -# Shell to use when invoking shell scripts. -SHELL=$LTSHELL - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# The host system. -host_alias=$host_alias -host=$host - -# An echo program that does not interpret backslashes. -echo=$ltecho - -# The archiver. -AR=$AR - -# The default C compiler. -CC=$CC - -# The linker used to build libraries. -LD=$LD - -# Whether we need hard or soft links. -LN_S=$LN_S - -# A BSD-compatible nm program. -NM=$NM - -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" - -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" - -# Used on cygwin: assembler. -AS="$AS" - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# How to create reloadable object files. -reload_flag=$reload_flag -reload_cmds=$reload_cmds - -# How to pass a linker flag through the compiler. -wl=$wl - -# Object file suffix (normally "o"). -objext="$objext" - -# Old archive suffix (normally "a"). -libext="$libext" - -# Executable file suffix (normally ""). -exeext="$exeext" - -# Additional compiler flags for building library objects. -pic_flag=$pic_flag - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$compiler_c_o - -# Can we write directly to a .lo ? -compiler_o_lo=$compiler_o_lo - -# Must we lock files when doing compilation ? -need_locks=$need_locks - -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Whether dlopen is supported. -dlopen=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Compiler flag to prevent dynamic linking. -link_static_flag=$link_static_flag - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$no_builtin_flag - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$export_dynamic_flag_spec - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$whole_archive_flag_spec - -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$thread_safe_flag_spec - -# Library versioning type. -version_type=$version_type - -# Format of library name prefix. -libname_spec=$libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$soname_spec - -# Commands used to build and install an old-style archive. -RANLIB=$RANLIB -old_archive_cmds=$old_archive_cmds -old_postinstall_cmds=$old_postinstall_cmds -old_postuninstall_cmds=$old_postuninstall_cmds - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$old_archive_from_new_cmds - -# Commands used to build and install a shared archive. -archive_cmds=$archive_cmds -archive_expsym_cmds=$archive_expsym_cmds -postinstall_cmds=$postinstall_cmds -postuninstall_cmds=$postuninstall_cmds - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$deplibs_check_method - -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$file_magic_cmd - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$allow_undefined_flag - -# Flag that forces no undefined symbols. -no_undefined_flag=$no_undefined_flag - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$finish_cmds - -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$finish_eval - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$global_symbol_pipe - -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$global_symbol_to_cdecl - -# This is the shared library runtime path variable. -runpath_var=$runpath_var - -# This is the shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$hardcode_libdir_flag_spec - -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$hardcode_libdir_separator - -# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct - -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Compile-time system search path for libraries -sys_lib_search_path_spec=$sys_lib_search_path_spec - -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$sys_lib_dlsearch_path_spec - -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path" - -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols - -# The commands to list exported symbols. -export_symbols_cmds=$export_symbols_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$exclude_expsyms - -# Symbols that must always be exported. -include_expsyms=$include_expsyms - -EOF - -case "$ltmain" in -*.sh) - echo '### END LIBTOOL CONFIG' >> "$ofile" - echo >> "$ofile" - case "$host_os" in - aix3*) - cat <<\EOF >> "$ofile" - -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "${COLLECT_NAMES+set}" != set; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac - - # Append the ltmain.sh script. - sed '$q' "$ltmain" >> "$ofile" || (rm -f "$ofile"; exit 1) - - chmod +x "$ofile" - ;; - -*) - # Compile the libtool program. - echo "FIXME: would compile $ltmain" - ;; -esac - -test -n "$cache_file" || exit 0 - -# AC_CACHE_SAVE -trap '' 1 2 15 -cat > confcache <<\EOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs. It is not useful on other systems. -# If it contains results you don't want to keep, you may remove or edit it. -# -# By default, configure uses ./config.cache as the cache file, -# creating it if it does not exist already. You can give configure -# the --cache-file=FILE option to use a different cache file; that is -# what configure does when it calls configure scripts in -# subdirectories, so they share the cache. -# Giving --cache-file=/dev/null disables caching, for debugging configure. -# config.status only pays attention to the cache file if you give it the -# --recheck option to rerun configure. -# -EOF -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, don't put newlines in cache variables' values. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -(set) 2>&1 | - case `(ac_space=' '; set | grep ac_space) 2>&1` in - *ac_space=\ *) - # `set' does not quote correctly, so add quotes (double-quote substitution - # turns \\\\ into \\, and sed turns \\ into \). - sed -n \ - -e "s/'/'\\\\''/g" \ - -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" - ;; - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' - ;; - esac >> confcache -if cmp -s $cache_file confcache; then - : -else - if test -w $cache_file; then - echo "updating cache $cache_file" - cat confcache > $cache_file - else - echo "not updating unwritable cache $cache_file" - fi -fi -rm -f confcache - -exit 0 - -# Local Variables: -# mode:shell-script -# sh-indentation:2 -# End: diff --git a/lib-src/libid3tag/ltmain.sh b/lib-src/libid3tag/ltmain.sh deleted file mode 100644 index a356acafa..000000000 --- a/lib-src/libid3tag/ltmain.sh +++ /dev/null @@ -1,9661 +0,0 @@ - -# libtool (GNU libtool) 2.4.2 -# Written by Gordon Matzigkeit , 1996 - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, -# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, -# or obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - -# Usage: $progname [OPTION]... [MODE-ARG]... -# -# Provide generalized library-building support services. -# -# --config show all configuration variables -# --debug enable verbose shell tracing -# -n, --dry-run display commands without modifying any files -# --features display basic configuration information and exit -# --mode=MODE use operation mode MODE -# --preserve-dup-deps don't remove duplicate dependency libraries -# --quiet, --silent don't print informational messages -# --no-quiet, --no-silent -# print informational messages (default) -# --no-warn don't display warning messages -# --tag=TAG use configuration variables from tag TAG -# -v, --verbose print more informational messages than default -# --no-verbose don't print the extra informational messages -# --version print version information -# -h, --help, --help-all print short, long, or detailed help message -# -# MODE must be one of the following: -# -# clean remove files from the build directory -# compile compile a source file into a libtool object -# execute automatically set library path, then run a program -# finish complete the installation of libtool libraries -# install install libraries or executables -# link create a library or an executable -# uninstall remove libraries from an installed directory -# -# MODE-ARGS vary depending on the MODE. When passed as first option, -# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. -# Try `$progname --help --mode=MODE' for a more detailed description of MODE. -# -# When reporting a bug, please describe a test case to reproduce it and -# include the following information: -# -# host-triplet: $host -# shell: $SHELL -# compiler: $LTCC -# compiler flags: $LTCFLAGS -# linker: $LD (gnu? $with_gnu_ld) -# $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.7ubuntu1 -# automake: $automake_version -# autoconf: $autoconf_version -# -# Report bugs to . -# GNU libtool home page: . -# General help using GNU software: . - -PROGRAM=libtool -PACKAGE=libtool -VERSION="2.4.2 Debian-2.4.2-1.7ubuntu1" -TIMESTAMP="" -package_revision=1.3337 - -# Be Bourne compatible -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' -} - -# NLS nuisances: We save the old values to restore during execute mode. -lt_user_locale= -lt_safe_locale= -for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES -do - eval "if test \"\${$lt_var+set}\" = set; then - save_$lt_var=\$$lt_var - $lt_var=C - export $lt_var - lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" - lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" - fi" -done -LC_ALL=C -LANGUAGE=C -export LANGUAGE LC_ALL - -$lt_unset CDPATH - - -# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh -# is ksh but when the shell is invoked as "sh" and the current value of -# the _XPG environment variable is not equal to 1 (one), the special -# positional parameter $0, within a function call, is the name of the -# function. -progpath="$0" - - - -: ${CP="cp -f"} -test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} -: ${MAKE="make"} -: ${MKDIR="mkdir"} -: ${MV="mv -f"} -: ${RM="rm -f"} -: ${SHELL="${CONFIG_SHELL-/bin/sh}"} -: ${Xsed="$SED -e 1s/^X//"} - -# Global variables: -EXIT_SUCCESS=0 -EXIT_FAILURE=1 -EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. -EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. - -exit_status=$EXIT_SUCCESS - -# Make sure IFS has a sensible default -lt_nl=' -' -IFS=" $lt_nl" - -dirname="s,/[^/]*$,," -basename="s,^.*/,," - -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi -} # func_dirname may be replaced by extended shell implementation - - -# func_basename file -func_basename () -{ - func_basename_result=`$ECHO "${1}" | $SED "$basename"` -} # func_basename may be replaced by extended shell implementation - - -# func_dirname_and_basename file append nondir_replacement -# perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# Implementation must be kept synchronized with func_dirname -# and func_basename. For efficiency, we do not delegate to -# those functions but instead duplicate the functionality here. -func_dirname_and_basename () -{ - # Extract subdirectory from the argument. - func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi - func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` -} # func_dirname_and_basename may be replaced by extended shell implementation - - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# func_strip_suffix prefix name -func_stripname () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname may be replaced by extended shell implementation - - -# These SED scripts presuppose an absolute path with a trailing slash. -pathcar='s,^/\([^/]*\).*$,\1,' -pathcdr='s,^/[^/]*,,' -removedotparts=':dotsl - s@/\./@/@g - t dotsl - s,/\.$,/,' -collapseslashes='s@/\{1,\}@/@g' -finalslash='s,/*$,/,' - -# func_normal_abspath PATH -# Remove doubled-up and trailing slashes, "." path components, -# and cancel out any ".." path components in PATH after making -# it an absolute path. -# value returned in "$func_normal_abspath_result" -func_normal_abspath () -{ - # Start from root dir and reassemble the path. - func_normal_abspath_result= - func_normal_abspath_tpath=$1 - func_normal_abspath_altnamespace= - case $func_normal_abspath_tpath in - "") - # Empty path, that just means $cwd. - func_stripname '' '/' "`pwd`" - func_normal_abspath_result=$func_stripname_result - return - ;; - # The next three entries are used to spot a run of precisely - # two leading slashes without using negated character classes; - # we take advantage of case's first-match behaviour. - ///*) - # Unusual form of absolute path, do nothing. - ;; - //*) - # Not necessarily an ordinary path; POSIX reserves leading '//' - # and for example Cygwin uses it to access remote file shares - # over CIFS/SMB, so we conserve a leading double slash if found. - func_normal_abspath_altnamespace=/ - ;; - /*) - # Absolute path, do nothing. - ;; - *) - # Relative path, prepend $cwd. - func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath - ;; - esac - # Cancel out all the simple stuff to save iterations. We also want - # the path to end with a slash for ease of parsing, so make sure - # there is one (and only one) here. - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` - while :; do - # Processed it all yet? - if test "$func_normal_abspath_tpath" = / ; then - # If we ascended to the root using ".." the result may be empty now. - if test -z "$func_normal_abspath_result" ; then - func_normal_abspath_result=/ - fi - break - fi - func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcar"` - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcdr"` - # Figure out what to do with it - case $func_normal_abspath_tcomponent in - "") - # Trailing empty path component, ignore it. - ;; - ..) - # Parent dir; strip last assembled component from result. - func_dirname "$func_normal_abspath_result" - func_normal_abspath_result=$func_dirname_result - ;; - *) - # Actual path component, append it. - func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent - ;; - esac - done - # Restore leading double-slash if one was found on entry. - func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result -} - -# func_relative_path SRCDIR DSTDIR -# generates a relative path from SRCDIR to DSTDIR, with a trailing -# slash if non-empty, suitable for immediately appending a filename -# without needing to append a separator. -# value returned in "$func_relative_path_result" -func_relative_path () -{ - func_relative_path_result= - func_normal_abspath "$1" - func_relative_path_tlibdir=$func_normal_abspath_result - func_normal_abspath "$2" - func_relative_path_tbindir=$func_normal_abspath_result - - # Ascend the tree starting from libdir - while :; do - # check if we have found a prefix of bindir - case $func_relative_path_tbindir in - $func_relative_path_tlibdir) - # found an exact match - func_relative_path_tcancelled= - break - ;; - $func_relative_path_tlibdir*) - # found a matching prefix - func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" - func_relative_path_tcancelled=$func_stripname_result - if test -z "$func_relative_path_result"; then - func_relative_path_result=. - fi - break - ;; - *) - func_dirname $func_relative_path_tlibdir - func_relative_path_tlibdir=${func_dirname_result} - if test "x$func_relative_path_tlibdir" = x ; then - # Have to descend all the way to the root! - func_relative_path_result=../$func_relative_path_result - func_relative_path_tcancelled=$func_relative_path_tbindir - break - fi - func_relative_path_result=../$func_relative_path_result - ;; - esac - done - - # Now calculate path; take care to avoid doubling-up slashes. - func_stripname '' '/' "$func_relative_path_result" - func_relative_path_result=$func_stripname_result - func_stripname '/' '/' "$func_relative_path_tcancelled" - if test "x$func_stripname_result" != x ; then - func_relative_path_result=${func_relative_path_result}/${func_stripname_result} - fi - - # Normalisation. If bindir is libdir, return empty string, - # else relative path ending with a slash; either way, target - # file name can be directly appended. - if test ! -z "$func_relative_path_result"; then - func_stripname './' '' "$func_relative_path_result/" - func_relative_path_result=$func_stripname_result - fi -} - -# The name of this program: -func_dirname_and_basename "$progpath" -progname=$func_basename_result - -# Make sure we have an absolute path for reexecution: -case $progpath in - [\\/]*|[A-Za-z]:\\*) ;; - *[\\/]*) - progdir=$func_dirname_result - progdir=`cd "$progdir" && pwd` - progpath="$progdir/$progname" - ;; - *) - save_IFS="$IFS" - IFS=${PATH_SEPARATOR-:} - for progdir in $PATH; do - IFS="$save_IFS" - test -x "$progdir/$progname" && break - done - IFS="$save_IFS" - test -n "$progdir" || progdir=`pwd` - progpath="$progdir/$progname" - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed="${SED}"' -e 1s/^X//' -sed_quote_subst='s/\([`"$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution that turns a string into a regex matching for the -# string literally. -sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' - -# Sed substitution that converts a w32 file name or path -# which contains forward slashes, into one that contains -# (escaped) backslashes. A very naive implementation. -lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - -# Re-`\' parameter expansions in output of double_quote_subst that were -# `\'-ed in input to the same. If an odd number of `\' preceded a '$' -# in input to double_quote_subst, that '$' was protected from expansion. -# Since each input `\' is now two `\'s, look for any number of runs of -# four `\'s followed by two `\'s and then a '$'. `\' that '$'. -bs='\\' -bs2='\\\\' -bs4='\\\\\\\\' -dollar='\$' -sed_double_backslash="\ - s/$bs4/&\\ -/g - s/^$bs2$dollar/$bs&/ - s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g - s/\n//g" - -# Standard options: -opt_dry_run=false -opt_help=false -opt_quiet=false -opt_verbose=false -opt_warning=: - -# func_echo arg... -# Echo program name prefixed message, along with the current mode -# name if it has been set yet. -func_echo () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }$*" -} - -# func_verbose arg... -# Echo program name prefixed message in verbose mode only. -func_verbose () -{ - $opt_verbose && func_echo ${1+"$@"} - - # A bug in bash halts the script if the last line of a function - # fails when set -e is in force, so we need another command to - # work around that: - : -} - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -# func_error arg... -# Echo program name prefixed message to standard error. -func_error () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 -} - -# func_warning arg... -# Echo program name prefixed warning message to standard error. -func_warning () -{ - $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 - - # bash bug again: - : -} - -# func_fatal_error arg... -# Echo program name prefixed message to standard error, and exit. -func_fatal_error () -{ - func_error ${1+"$@"} - exit $EXIT_FAILURE -} - -# func_fatal_help arg... -# Echo program name prefixed message to standard error, followed by -# a help hint, and exit. -func_fatal_help () -{ - func_error ${1+"$@"} - func_fatal_error "$help" -} -help="Try \`$progname --help' for more information." ## default - - -# func_grep expression filename -# Check whether EXPRESSION matches any line of FILENAME, without output. -func_grep () -{ - $GREP "$1" "$2" >/dev/null 2>&1 -} - - -# func_mkdir_p directory-path -# Make sure the entire path to DIRECTORY-PATH is available. -func_mkdir_p () -{ - my_directory_path="$1" - my_dir_list= - - if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then - - # Protect directory names starting with `-' - case $my_directory_path in - -*) my_directory_path="./$my_directory_path" ;; - esac - - # While some portion of DIR does not yet exist... - while test ! -d "$my_directory_path"; do - # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. - my_dir_list="$my_directory_path:$my_dir_list" - - # If the last portion added has no slash in it, the list is done - case $my_directory_path in */*) ;; *) break ;; esac - - # ...otherwise throw away the child directory and loop - my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` - done - my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` - - save_mkdir_p_IFS="$IFS"; IFS=':' - for my_dir in $my_dir_list; do - IFS="$save_mkdir_p_IFS" - # mkdir can fail with a `File exist' error if two processes - # try to create one of the directories concurrently. Don't - # stop in that case! - $MKDIR "$my_dir" 2>/dev/null || : - done - IFS="$save_mkdir_p_IFS" - - # Bail out if we (or some other process) failed to create a directory. - test -d "$my_directory_path" || \ - func_fatal_error "Failed to create \`$1'" - fi -} - - -# func_mktempdir [string] -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, STRING is the basename for that directory. -func_mktempdir () -{ - my_template="${TMPDIR-/tmp}/${1-$progname}" - - if test "$opt_dry_run" = ":"; then - # Return a directory name, but don't create it in dry-run mode - my_tmpdir="${my_template}-$$" - else - - # If mktemp works, use that first and foremost - my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` - - if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" - - save_mktempdir_umask=`umask` - umask 0077 - $MKDIR "$my_tmpdir" - umask $save_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || \ - func_fatal_error "cannot create temporary directory \`$my_tmpdir'" - fi - - $ECHO "$my_tmpdir" -} - - -# func_quote_for_eval arg -# Aesthetically quote ARG to be evaled later. -# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT -# is double-quoted, suitable for a subsequent eval, whereas -# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters -# which are still active within double quotes backslashified. -func_quote_for_eval () -{ - case $1 in - *[\\\`\"\$]*) - func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; - *) - func_quote_for_eval_unquoted_result="$1" ;; - esac - - case $func_quote_for_eval_unquoted_result in - # Double-quote args containing shell metacharacters to delay - # word splitting, command substitution and and variable - # expansion for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" - ;; - *) - func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" - esac -} - - -# func_quote_for_expand arg -# Aesthetically quote ARG to be evaled later; same as above, -# but do not quote variable references. -func_quote_for_expand () -{ - case $1 in - *[\\\`\"]*) - my_arg=`$ECHO "$1" | $SED \ - -e "$double_quote_subst" -e "$sed_double_backslash"` ;; - *) - my_arg="$1" ;; - esac - - case $my_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting and command substitution for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - my_arg="\"$my_arg\"" - ;; - esac - - func_quote_for_expand_result="$my_arg" -} - - -# func_show_eval cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. -func_show_eval () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$my_cmd" - my_status=$? - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - - -# func_show_eval_locale cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. Use the saved locale for evaluation. -func_show_eval_locale () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$lt_user_locale - $my_cmd" - my_status=$? - eval "$lt_safe_locale" - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - -# func_tr_sh -# Turn $1 into a string suitable for a shell variable name. -# Result is stored in $func_tr_sh_result. All characters -# not in the set a-zA-Z0-9_ are replaced with '_'. Further, -# if $1 begins with a digit, a '_' is prepended as well. -func_tr_sh () -{ - case $1 in - [0-9]* | *[!a-zA-Z0-9_]*) - func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` - ;; - * ) - func_tr_sh_result=$1 - ;; - esac -} - - -# func_version -# Echo version message to standard output and exit. -func_version () -{ - $opt_debug - - $SED -n '/(C)/!b go - :more - /\./!{ - N - s/\n# / / - b more - } - :go - /^# '$PROGRAM' (GNU /,/# warranty; / { - s/^# // - s/^# *$// - s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ - p - }' < "$progpath" - exit $? -} - -# func_usage -# Echo short help message to standard output and exit. -func_usage () -{ - $opt_debug - - $SED -n '/^# Usage:/,/^# *.*--help/ { - s/^# // - s/^# *$// - s/\$progname/'$progname'/ - p - }' < "$progpath" - echo - $ECHO "run \`$progname --help | more' for full usage" - exit $? -} - -# func_help [NOEXIT] -# Echo long help message to standard output and exit, -# unless 'noexit' is passed as argument. -func_help () -{ - $opt_debug - - $SED -n '/^# Usage:/,/# Report bugs to/ { - :print - s/^# // - s/^# *$// - s*\$progname*'$progname'* - s*\$host*'"$host"'* - s*\$SHELL*'"$SHELL"'* - s*\$LTCC*'"$LTCC"'* - s*\$LTCFLAGS*'"$LTCFLAGS"'* - s*\$LD*'"$LD"'* - s/\$with_gnu_ld/'"$with_gnu_ld"'/ - s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/ - s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/ - p - d - } - /^# .* home page:/b print - /^# General help using/b print - ' < "$progpath" - ret=$? - if test -z "$1"; then - exit $ret - fi -} - -# func_missing_arg argname -# Echo program name prefixed message to standard error and set global -# exit_cmd. -func_missing_arg () -{ - $opt_debug - - func_error "missing argument for $1." - exit_cmd=exit -} - - -# func_split_short_opt shortopt -# Set func_split_short_opt_name and func_split_short_opt_arg shell -# variables after splitting SHORTOPT after the 2nd character. -func_split_short_opt () -{ - my_sed_short_opt='1s/^\(..\).*$/\1/;q' - my_sed_short_rest='1s/^..\(.*\)$/\1/;q' - - func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` - func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` -} # func_split_short_opt may be replaced by extended shell implementation - - -# func_split_long_opt longopt -# Set func_split_long_opt_name and func_split_long_opt_arg shell -# variables after splitting LONGOPT at the `=' sign. -func_split_long_opt () -{ - my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' - my_sed_long_arg='1s/^--[^=]*=//' - - func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` - func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` -} # func_split_long_opt may be replaced by extended shell implementation - -exit_cmd=: - - - - - -magic="%%%MAGIC variable%%%" -magic_exe="%%%MAGIC EXE variable%%%" - -# Global variables. -nonopt= -preserve_args= -lo2o="s/\\.lo\$/.${objext}/" -o2lo="s/\\.${objext}\$/.lo/" -extracted_archives= -extracted_serial=0 - -# If this variable is set in any of the actions, the command in it -# will be execed at the end. This prevents here-documents from being -# left over by shells. -exec_cmd= - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "${1}=\$${1}\${2}" -} # func_append may be replaced by extended shell implementation - -# func_append_quoted var value -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -func_append_quoted () -{ - func_quote_for_eval "${2}" - eval "${1}=\$${1}\\ \$func_quote_for_eval_result" -} # func_append_quoted may be replaced by extended shell implementation - - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "${@}"` -} # func_arith may be replaced by extended shell implementation - - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` -} # func_len may be replaced by extended shell implementation - - -# func_lo2o object -func_lo2o () -{ - func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` -} # func_lo2o may be replaced by extended shell implementation - - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` -} # func_xform may be replaced by extended shell implementation - - -# func_fatal_configuration arg... -# Echo program name prefixed message to standard error, followed by -# a configuration failure hint, and exit. -func_fatal_configuration () -{ - func_error ${1+"$@"} - func_error "See the $PACKAGE documentation for more information." - func_fatal_error "Fatal configuration error." -} - - -# func_config -# Display the configuration for all the tags in this script. -func_config () -{ - re_begincf='^# ### BEGIN LIBTOOL' - re_endcf='^# ### END LIBTOOL' - - # Default configuration. - $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" - - # Now print the configurations for the tags. - for tagname in $taglist; do - $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" - done - - exit $? -} - -# func_features -# Display the features supported by this script. -func_features () -{ - echo "host: $host" - if test "$build_libtool_libs" = yes; then - echo "enable shared libraries" - else - echo "disable shared libraries" - fi - if test "$build_old_libs" = yes; then - echo "enable static libraries" - else - echo "disable static libraries" - fi - - exit $? -} - -# func_enable_tag tagname -# Verify that TAGNAME is valid, and either flag an error and exit, or -# enable the TAGNAME tag. We also add TAGNAME to the global $taglist -# variable here. -func_enable_tag () -{ - # Global variable: - tagname="$1" - - re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" - re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" - sed_extractcf="/$re_begincf/,/$re_endcf/p" - - # Validate tagname. - case $tagname in - *[!-_A-Za-z0-9,/]*) - func_fatal_error "invalid tag name: $tagname" - ;; - esac - - # Don't test for the "default" C tag, as we know it's - # there but not specially marked. - case $tagname in - CC) ;; - *) - if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then - taglist="$taglist $tagname" - - # Evaluate the configuration. Be careful to quote the path - # and the sed script, to avoid splitting on whitespace, but - # also don't use non-portable quotes within backquotes within - # quotes we have to do it in 2 steps: - extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` - eval "$extractedcf" - else - func_error "ignoring unknown tag $tagname" - fi - ;; - esac -} - -# func_check_version_match -# Ensure that we are using m4 macros, and libtool script from the same -# release of libtool. -func_check_version_match () -{ - if test "$package_revision" != "$macro_revision"; then - if test "$VERSION" != "$macro_version"; then - if test -z "$macro_version"; then - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from an older release. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - fi - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, -$progname: but the definition of this LT_INIT comes from revision $macro_revision. -$progname: You should recreate aclocal.m4 with macros from revision $package_revision -$progname: of $PACKAGE $VERSION and run autoconf again. -_LT_EOF - fi - - exit $EXIT_MISMATCH - fi -} - - -# Shorthand for --mode=foo, only valid as the first argument -case $1 in -clean|clea|cle|cl) - shift; set dummy --mode clean ${1+"$@"}; shift - ;; -compile|compil|compi|comp|com|co|c) - shift; set dummy --mode compile ${1+"$@"}; shift - ;; -execute|execut|execu|exec|exe|ex|e) - shift; set dummy --mode execute ${1+"$@"}; shift - ;; -finish|finis|fini|fin|fi|f) - shift; set dummy --mode finish ${1+"$@"}; shift - ;; -install|instal|insta|inst|ins|in|i) - shift; set dummy --mode install ${1+"$@"}; shift - ;; -link|lin|li|l) - shift; set dummy --mode link ${1+"$@"}; shift - ;; -uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) - shift; set dummy --mode uninstall ${1+"$@"}; shift - ;; -esac - - - -# Option defaults: -opt_debug=: -opt_dry_run=false -opt_config=false -opt_preserve_dup_deps=false -opt_features=false -opt_finish=false -opt_help=false -opt_help_all=false -opt_silent=: -opt_warning=: -opt_verbose=: -opt_silent=false -opt_verbose=false - - -# Parse options once, thoroughly. This comes as soon as possible in the -# script to make things like `--version' happen as quickly as we can. -{ - # this just eases exit handling - while test $# -gt 0; do - opt="$1" - shift - case $opt in - --debug|-x) opt_debug='set -x' - func_echo "enabling shell trace mode" - $opt_debug - ;; - --dry-run|--dryrun|-n) - opt_dry_run=: - ;; - --config) - opt_config=: -func_config - ;; - --dlopen|-dlopen) - optarg="$1" - opt_dlopen="${opt_dlopen+$opt_dlopen -}$optarg" - shift - ;; - --preserve-dup-deps) - opt_preserve_dup_deps=: - ;; - --features) - opt_features=: -func_features - ;; - --finish) - opt_finish=: -set dummy --mode finish ${1+"$@"}; shift - ;; - --help) - opt_help=: - ;; - --help-all) - opt_help_all=: -opt_help=': help-all' - ;; - --mode) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_mode="$optarg" -case $optarg in - # Valid mode arguments: - clean|compile|execute|finish|install|link|relink|uninstall) ;; - - # Catch anything else as an error - *) func_error "invalid argument for $opt" - exit_cmd=exit - break - ;; -esac - shift - ;; - --no-silent|--no-quiet) - opt_silent=false -func_append preserve_args " $opt" - ;; - --no-warning|--no-warn) - opt_warning=false -func_append preserve_args " $opt" - ;; - --no-verbose) - opt_verbose=false -func_append preserve_args " $opt" - ;; - --silent|--quiet) - opt_silent=: -func_append preserve_args " $opt" - opt_verbose=false - ;; - --verbose|-v) - opt_verbose=: -func_append preserve_args " $opt" -opt_silent=false - ;; - --tag) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_tag="$optarg" -func_append preserve_args " $opt $optarg" -func_enable_tag "$optarg" - shift - ;; - - -\?|-h) func_usage ;; - --help) func_help ;; - --version) func_version ;; - - # Separate optargs to long options: - --*=*) - func_split_long_opt "$opt" - set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} - shift - ;; - - # Separate non-argument short options: - -\?*|-h*|-n*|-v*) - func_split_short_opt "$opt" - set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - - --) break ;; - -*) func_fatal_help "unrecognized option \`$opt'" ;; - *) set dummy "$opt" ${1+"$@"}; shift; break ;; - esac - done - - # Validate options: - - # save first non-option argument - if test "$#" -gt 0; then - nonopt="$opt" - shift - fi - - # preserve --debug - test "$opt_debug" = : || func_append preserve_args " --debug" - - case $host in - *cygwin* | *mingw* | *pw32* | *cegcc*) - # don't eliminate duplications in $postdeps and $predeps - opt_duplicate_compiler_generated_deps=: - ;; - *) - opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps - ;; - esac - - $opt_help || { - # Sanity checks first: - func_check_version_match - - if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then - func_fatal_configuration "not configured to build any kind of library" - fi - - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" - - # Only execute mode is allowed to have -dlopen flags. - if test -n "$opt_dlopen" && test "$opt_mode" != execute; then - func_error "unrecognized option \`-dlopen'" - $ECHO "$help" 1>&2 - exit $EXIT_FAILURE - fi - - # Change the help message to a mode-specific one. - generic_help="$help" - help="Try \`$progname --help --mode=$opt_mode' for more information." - } - - - # Bail if the options were screwed - $exit_cmd $EXIT_FAILURE -} - - - - -## ----------- ## -## Main. ## -## ----------- ## - -# func_lalib_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_lalib_p () -{ - test -f "$1" && - $SED -e 4q "$1" 2>/dev/null \ - | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 -} - -# func_lalib_unsafe_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function implements the same check as func_lalib_p without -# resorting to external programs. To this end, it redirects stdin and -# closes it afterwards, without saving the original file descriptor. -# As a safety measure, use it only where a negative result would be -# fatal anyway. Works if `file' does not exist. -func_lalib_unsafe_p () -{ - lalib_p=no - if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then - for lalib_p_l in 1 2 3 4 - do - read lalib_p_line - case "$lalib_p_line" in - \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; - esac - done - exec 0<&5 5<&- - fi - test "$lalib_p" = yes -} - -# func_ltwrapper_script_p file -# True iff FILE is a libtool wrapper script -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_script_p () -{ - func_lalib_p "$1" -} - -# func_ltwrapper_executable_p file -# True iff FILE is a libtool wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_executable_p () -{ - func_ltwrapper_exec_suffix= - case $1 in - *.exe) ;; - *) func_ltwrapper_exec_suffix=.exe ;; - esac - $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 -} - -# func_ltwrapper_scriptname file -# Assumes file is an ltwrapper_executable -# uses $file to determine the appropriate filename for a -# temporary ltwrapper_script. -func_ltwrapper_scriptname () -{ - func_dirname_and_basename "$1" "" "." - func_stripname '' '.exe' "$func_basename_result" - func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" -} - -# func_ltwrapper_p file -# True iff FILE is a libtool wrapper script or wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_p () -{ - func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" -} - - -# func_execute_cmds commands fail_cmd -# Execute tilde-delimited COMMANDS. -# If FAIL_CMD is given, eval that upon failure. -# FAIL_CMD may read-access the current command in variable CMD! -func_execute_cmds () -{ - $opt_debug - save_ifs=$IFS; IFS='~' - for cmd in $1; do - IFS=$save_ifs - eval cmd=\"$cmd\" - func_show_eval "$cmd" "${2-:}" - done - IFS=$save_ifs -} - - -# func_source file -# Source FILE, adding directory component if necessary. -# Note that it is not necessary on cygwin/mingw to append a dot to -# FILE even if both FILE and FILE.exe exist: automatic-append-.exe -# behavior happens only for exec(3), not for open(2)! Also, sourcing -# `FILE.' does not work on cygwin managed mounts. -func_source () -{ - $opt_debug - case $1 in - */* | *\\*) . "$1" ;; - *) . "./$1" ;; - esac -} - - -# func_resolve_sysroot PATH -# Replace a leading = in PATH with a sysroot. Store the result into -# func_resolve_sysroot_result -func_resolve_sysroot () -{ - func_resolve_sysroot_result=$1 - case $func_resolve_sysroot_result in - =*) - func_stripname '=' '' "$func_resolve_sysroot_result" - func_resolve_sysroot_result=$lt_sysroot$func_stripname_result - ;; - esac -} - -# func_replace_sysroot PATH -# If PATH begins with the sysroot, replace it with = and -# store the result into func_replace_sysroot_result. -func_replace_sysroot () -{ - case "$lt_sysroot:$1" in - ?*:"$lt_sysroot"*) - func_stripname "$lt_sysroot" '' "$1" - func_replace_sysroot_result="=$func_stripname_result" - ;; - *) - # Including no sysroot. - func_replace_sysroot_result=$1 - ;; - esac -} - -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () -{ - $opt_debug - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. - *) - for z in $available_tags; do - if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case "$@ " in - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - func_echo "unable to infer tagged configuration" - func_fatal_error "specify a tag with \`--tag'" -# else -# func_verbose "using $tagname tagged configuration" - fi - ;; - esac - fi -} - - - -# func_write_libtool_object output_name pic_name nonpic_name -# Create a libtool object file (analogous to a ".la" file), -# but don't create it if we're doing a dry run. -func_write_libtool_object () -{ - write_libobj=${1} - if test "$build_libtool_libs" = yes; then - write_lobj=\'${2}\' - else - write_lobj=none - fi - - if test "$build_old_libs" = yes; then - write_oldobj=\'${3}\' - else - write_oldobj=none - fi - - $opt_dry_run || { - cat >${write_libobj}T </dev/null` - if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then - func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | - $SED -e "$lt_sed_naive_backslashify"` - else - func_convert_core_file_wine_to_w32_result= - fi - fi -} -# end: func_convert_core_file_wine_to_w32 - - -# func_convert_core_path_wine_to_w32 ARG -# Helper function used by path conversion functions when $build is *nix, and -# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly -# configured wine environment available, with the winepath program in $build's -# $PATH. Assumes ARG has no leading or trailing path separator characters. -# -# ARG is path to be converted from $build format to win32. -# Result is available in $func_convert_core_path_wine_to_w32_result. -# Unconvertible file (directory) names in ARG are skipped; if no directory names -# are convertible, then the result may be empty. -func_convert_core_path_wine_to_w32 () -{ - $opt_debug - # unfortunately, winepath doesn't convert paths, only file names - func_convert_core_path_wine_to_w32_result="" - if test -n "$1"; then - oldIFS=$IFS - IFS=: - for func_convert_core_path_wine_to_w32_f in $1; do - IFS=$oldIFS - func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" - if test -n "$func_convert_core_file_wine_to_w32_result" ; then - if test -z "$func_convert_core_path_wine_to_w32_result"; then - func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" - else - func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" - fi - fi - done - IFS=$oldIFS - fi -} -# end: func_convert_core_path_wine_to_w32 - - -# func_cygpath ARGS... -# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when -# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) -# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or -# (2), returns the Cygwin file name or path in func_cygpath_result (input -# file name or path is assumed to be in w32 format, as previously converted -# from $build's *nix or MSYS format). In case (3), returns the w32 file name -# or path in func_cygpath_result (input file name or path is assumed to be in -# Cygwin format). Returns an empty string on error. -# -# ARGS are passed to cygpath, with the last one being the file name or path to -# be converted. -# -# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH -# environment variable; do not put it in $PATH. -func_cygpath () -{ - $opt_debug - if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then - func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` - if test "$?" -ne 0; then - # on failure, ensure result is empty - func_cygpath_result= - fi - else - func_cygpath_result= - func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" - fi -} -#end: func_cygpath - - -# func_convert_core_msys_to_w32 ARG -# Convert file name or path ARG from MSYS format to w32 format. Return -# result in func_convert_core_msys_to_w32_result. -func_convert_core_msys_to_w32 () -{ - $opt_debug - # awkward: cmd appends spaces to result - func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | - $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` -} -#end: func_convert_core_msys_to_w32 - - -# func_convert_file_check ARG1 ARG2 -# Verify that ARG1 (a file name in $build format) was converted to $host -# format in ARG2. Otherwise, emit an error message, but continue (resetting -# func_to_host_file_result to ARG1). -func_convert_file_check () -{ - $opt_debug - if test -z "$2" && test -n "$1" ; then - func_error "Could not determine host file name corresponding to" - func_error " \`$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback: - func_to_host_file_result="$1" - fi -} -# end func_convert_file_check - - -# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH -# Verify that FROM_PATH (a path in $build format) was converted to $host -# format in TO_PATH. Otherwise, emit an error message, but continue, resetting -# func_to_host_file_result to a simplistic fallback value (see below). -func_convert_path_check () -{ - $opt_debug - if test -z "$4" && test -n "$3"; then - func_error "Could not determine the host path corresponding to" - func_error " \`$3'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback. This is a deliberately simplistic "conversion" and - # should not be "improved". See libtool.info. - if test "x$1" != "x$2"; then - lt_replace_pathsep_chars="s|$1|$2|g" - func_to_host_path_result=`echo "$3" | - $SED -e "$lt_replace_pathsep_chars"` - else - func_to_host_path_result="$3" - fi - fi -} -# end func_convert_path_check - - -# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG -# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT -# and appending REPL if ORIG matches BACKPAT. -func_convert_path_front_back_pathsep () -{ - $opt_debug - case $4 in - $1 ) func_to_host_path_result="$3$func_to_host_path_result" - ;; - esac - case $4 in - $2 ) func_append func_to_host_path_result "$3" - ;; - esac -} -# end func_convert_path_front_back_pathsep - - -################################################## -# $build to $host FILE NAME CONVERSION FUNCTIONS # -################################################## -# invoked via `$to_host_file_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# Result will be available in $func_to_host_file_result. - - -# func_to_host_file ARG -# Converts the file name ARG from $build format to $host format. Return result -# in func_to_host_file_result. -func_to_host_file () -{ - $opt_debug - $to_host_file_cmd "$1" -} -# end func_to_host_file - - -# func_to_tool_file ARG LAZY -# converts the file name ARG from $build format to toolchain format. Return -# result in func_to_tool_file_result. If the conversion in use is listed -# in (the comma separated) LAZY, no conversion takes place. -func_to_tool_file () -{ - $opt_debug - case ,$2, in - *,"$to_tool_file_cmd",*) - func_to_tool_file_result=$1 - ;; - *) - $to_tool_file_cmd "$1" - func_to_tool_file_result=$func_to_host_file_result - ;; - esac -} -# end func_to_tool_file - - -# func_convert_file_noop ARG -# Copy ARG to func_to_host_file_result. -func_convert_file_noop () -{ - func_to_host_file_result="$1" -} -# end func_convert_file_noop - - -# func_convert_file_msys_to_w32 ARG -# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_file_result. -func_convert_file_msys_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_to_host_file_result="$func_convert_core_msys_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_w32 - - -# func_convert_file_cygwin_to_w32 ARG -# Convert file name ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_file_cygwin_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # because $build is cygwin, we call "the" cygpath in $PATH; no need to use - # LT_CYGPATH in this case. - func_to_host_file_result=`cygpath -m "$1"` - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_cygwin_to_w32 - - -# func_convert_file_nix_to_w32 ARG -# Convert file name ARG from *nix to w32 format. Requires a wine environment -# and a working winepath. Returns result in func_to_host_file_result. -func_convert_file_nix_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_file_wine_to_w32 "$1" - func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_w32 - - -# func_convert_file_msys_to_cygwin ARG -# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_file_msys_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_cygpath -u "$func_convert_core_msys_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_cygwin - - -# func_convert_file_nix_to_cygwin ARG -# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed -# in a wine environment, working winepath, and LT_CYGPATH set. Returns result -# in func_to_host_file_result. -func_convert_file_nix_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. - func_convert_core_file_wine_to_w32 "$1" - func_cygpath -u "$func_convert_core_file_wine_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_cygwin - - -############################################# -# $build to $host PATH CONVERSION FUNCTIONS # -############################################# -# invoked via `$to_host_path_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# The result will be available in $func_to_host_path_result. -# -# Path separators are also converted from $build format to $host format. If -# ARG begins or ends with a path separator character, it is preserved (but -# converted to $host format) on output. -# -# All path conversion functions are named using the following convention: -# file name conversion function : func_convert_file_X_to_Y () -# path conversion function : func_convert_path_X_to_Y () -# where, for any given $build/$host combination the 'X_to_Y' value is the -# same. If conversion functions are added for new $build/$host combinations, -# the two new functions must follow this pattern, or func_init_to_host_path_cmd -# will break. - - -# func_init_to_host_path_cmd -# Ensures that function "pointer" variable $to_host_path_cmd is set to the -# appropriate value, based on the value of $to_host_file_cmd. -to_host_path_cmd= -func_init_to_host_path_cmd () -{ - $opt_debug - if test -z "$to_host_path_cmd"; then - func_stripname 'func_convert_file_' '' "$to_host_file_cmd" - to_host_path_cmd="func_convert_path_${func_stripname_result}" - fi -} - - -# func_to_host_path ARG -# Converts the path ARG from $build format to $host format. Return result -# in func_to_host_path_result. -func_to_host_path () -{ - $opt_debug - func_init_to_host_path_cmd - $to_host_path_cmd "$1" -} -# end func_to_host_path - - -# func_convert_path_noop ARG -# Copy ARG to func_to_host_path_result. -func_convert_path_noop () -{ - func_to_host_path_result="$1" -} -# end func_convert_path_noop - - -# func_convert_path_msys_to_w32 ARG -# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_path_result. -func_convert_path_msys_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from ARG. MSYS - # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; - # and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_msys_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_msys_to_w32 - - -# func_convert_path_cygwin_to_w32 ARG -# Convert path ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_path_cygwin_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_cygwin_to_w32 - - -# func_convert_path_nix_to_w32 ARG -# Convert path ARG from *nix to w32 format. Requires a wine environment and -# a working winepath. Returns result in func_to_host_file_result. -func_convert_path_nix_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_nix_to_w32 - - -# func_convert_path_msys_to_cygwin ARG -# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_path_msys_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_msys_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_msys_to_cygwin - - -# func_convert_path_nix_to_cygwin ARG -# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a -# a wine environment, working winepath, and LT_CYGPATH set. Returns result in -# func_to_host_file_result. -func_convert_path_nix_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from - # ARG. msys behavior is inconsistent here, cygpath turns them - # into '.;' and ';.', and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_nix_to_cygwin - - -# func_mode_compile arg... -func_mode_compile () -{ - $opt_debug - # Get the compilation command and the source file. - base_compile= - srcfile="$nonopt" # always keep a non-empty value in "srcfile" - suppress_opt=yes - suppress_output= - arg_mode=normal - libobj= - later= - pie_flag= - - for arg - do - case $arg_mode in - arg ) - # do not "continue". Instead, add this to base_compile - lastarg="$arg" - arg_mode=normal - ;; - - target ) - libobj="$arg" - arg_mode=normal - continue - ;; - - normal ) - # Accept any command-line options. - case $arg in - -o) - test -n "$libobj" && \ - func_fatal_error "you cannot specify \`-o' more than once" - arg_mode=target - continue - ;; - - -pie | -fpie | -fPIE) - func_append pie_flag " $arg" - continue - ;; - - -shared | -static | -prefer-pic | -prefer-non-pic) - func_append later " $arg" - continue - ;; - - -no-suppress) - suppress_opt=no - continue - ;; - - -Xcompiler) - arg_mode=arg # the next one goes into the "base_compile" arg list - continue # The current "srcfile" will either be retained or - ;; # replaced later. I would guess that would be a bug. - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - lastarg= - save_ifs="$IFS"; IFS=',' - for arg in $args; do - IFS="$save_ifs" - func_append_quoted lastarg "$arg" - done - IFS="$save_ifs" - func_stripname ' ' '' "$lastarg" - lastarg=$func_stripname_result - - # Add the arguments to base_compile. - func_append base_compile " $lastarg" - continue - ;; - - *) - # Accept the current argument as the source file. - # The previous "srcfile" becomes the current argument. - # - lastarg="$srcfile" - srcfile="$arg" - ;; - esac # case $arg - ;; - esac # case $arg_mode - - # Aesthetically quote the previous argument. - func_append_quoted base_compile "$lastarg" - done # for arg - - case $arg_mode in - arg) - func_fatal_error "you must specify an argument for -Xcompile" - ;; - target) - func_fatal_error "you must specify a target with \`-o'" - ;; - *) - # Get the name of the library object. - test -z "$libobj" && { - func_basename "$srcfile" - libobj="$func_basename_result" - } - ;; - esac - - # Recognize several different file suffixes. - # If the user specifies -o file.o, it is replaced with file.lo - case $libobj in - *.[cCFSifmso] | \ - *.ada | *.adb | *.ads | *.asm | \ - *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ - *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) - func_xform "$libobj" - libobj=$func_xform_result - ;; - esac - - case $libobj in - *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; - *) - func_fatal_error "cannot determine name of library object from \`$libobj'" - ;; - esac - - func_infer_tag $base_compile - - for arg in $later; do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - continue - ;; - - -static) - build_libtool_libs=no - build_old_libs=yes - continue - ;; - - -prefer-pic) - pic_mode=yes - continue - ;; - - -prefer-non-pic) - pic_mode=no - continue - ;; - esac - done - - func_quote_for_eval "$libobj" - test "X$libobj" != "X$func_quote_for_eval_result" \ - && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && func_warning "libobj name \`$libobj' may not contain shell special characters." - func_dirname_and_basename "$obj" "/" "" - objname="$func_basename_result" - xdir="$func_dirname_result" - lobj=${xdir}$objdir/$objname - - test -z "$base_compile" && \ - func_fatal_help "you must specify a compilation command" - - # Delete any leftover library objects. - if test "$build_old_libs" = yes; then - removelist="$obj $lobj $libobj ${libobj}T" - else - removelist="$lobj $libobj ${libobj}T" - fi - - # On Cygwin there's no "real" PIC flag so we must build both object types - case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) - pic_mode=default - ;; - esac - if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then - # non-PIC code in shared libraries is not supported - pic_mode=default - fi - - # Calculate the filename of the output object if compiler does - # not support -o with -c - if test "$compiler_c_o" = no; then - output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} - lockfile="$output_obj.lock" - else - output_obj= - need_locks=no - lockfile= - fi - - # Lock this critical section if it is needed - # We use this script file to make the link, it avoids creating a new file - if test "$need_locks" = yes; then - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - elif test "$need_locks" = warn; then - if test -f "$lockfile"; then - $ECHO "\ -*** ERROR, $lockfile exists and contains: -`cat $lockfile 2>/dev/null` - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - func_append removelist " $output_obj" - $ECHO "$srcfile" > "$lockfile" - fi - - $opt_dry_run || $RM $removelist - func_append removelist " $lockfile" - trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - - func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 - srcfile=$func_to_tool_file_result - func_quote_for_eval "$srcfile" - qsrcfile=$func_quote_for_eval_result - - # Only build a PIC object if we are building libtool libraries. - if test "$build_libtool_libs" = yes; then - # Without this assignment, base_compile gets emptied. - fbsd_hideous_sh_bug=$base_compile - - if test "$pic_mode" != no; then - command="$base_compile $qsrcfile $pic_flag" - else - # Don't build PIC code - command="$base_compile $qsrcfile" - fi - - func_mkdir_p "$xdir$objdir" - - if test -z "$output_obj"; then - # Place PIC objects in $objdir - func_append command " -o $lobj" - fi - - func_show_eval_locale "$command" \ - 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed, then go on to compile the next one - if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - func_show_eval '$MV "$output_obj" "$lobj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - - # Allow error messages only from the first compilation. - if test "$suppress_opt" = yes; then - suppress_output=' >/dev/null 2>&1' - fi - fi - - # Only build a position-dependent object if we build old libraries. - if test "$build_old_libs" = yes; then - if test "$pic_mode" != yes; then - # Don't build PIC code - command="$base_compile $qsrcfile$pie_flag" - else - command="$base_compile $qsrcfile $pic_flag" - fi - if test "$compiler_c_o" = yes; then - func_append command " -o $obj" - fi - - # Suppress compiler output if we already did a PIC compilation. - func_append command "$suppress_output" - func_show_eval_locale "$command" \ - '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed - if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - func_show_eval '$MV "$output_obj" "$obj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - fi - - $opt_dry_run || { - func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" - - # Unlock the critical section if it was locked - if test "$need_locks" != no; then - removelist=$lockfile - $RM "$lockfile" - fi - } - - exit $EXIT_SUCCESS -} - -$opt_help || { - test "$opt_mode" = compile && func_mode_compile ${1+"$@"} -} - -func_mode_help () -{ - # We need to display help for each of the modes. - case $opt_mode in - "") - # Generic help is extracted from the usage comments - # at the start of this file. - func_help - ;; - - clean) - $ECHO \ -"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - -Remove files from the build directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, object or program, all the files associated -with it are deleted. Otherwise, only FILE itself is deleted using RM." - ;; - - compile) - $ECHO \ -"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - -Compile a source file into a libtool library object. - -This mode accepts the following additional options: - - -o OUTPUT-FILE set the output file name to OUTPUT-FILE - -no-suppress do not suppress compiler output for multiple passes - -prefer-pic try to build PIC objects only - -prefer-non-pic try to build non-PIC objects only - -shared do not build a \`.o' file suitable for static linking - -static only build a \`.o' file suitable for static linking - -Wc,FLAG pass FLAG directly to the compiler - -COMPILE-COMMAND is a command to be used in creating a \`standard' object file -from the given SOURCEFILE. - -The output file name is determined by removing the directory component from -SOURCEFILE, then substituting the C source code suffix \`.c' with the -library object suffix, \`.lo'." - ;; - - execute) - $ECHO \ -"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... - -Automatically set library path, then run a program. - -This mode accepts the following additional options: - - -dlopen FILE add the directory containing FILE to the library path - -This mode sets the library path environment variable according to \`-dlopen' -flags. - -If any of the ARGS are libtool executable wrappers, then they are translated -into their corresponding uninstalled binary, and any of their required library -directories are added to the library path. - -Then, COMMAND is executed, with ARGS as arguments." - ;; - - finish) - $ECHO \ -"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... - -Complete the installation of libtool libraries. - -Each LIBDIR is a directory that contains libtool libraries. - -The commands that this mode executes may require superuser privileges. Use -the \`--dry-run' option if you just want to see what would be executed." - ;; - - install) - $ECHO \ -"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... - -Install executables or libraries. - -INSTALL-COMMAND is the installation command. The first component should be -either the \`install' or \`cp' program. - -The following components of INSTALL-COMMAND are treated specially: - - -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation - -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; - - link) - $ECHO \ -"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... - -Link object files or libraries together to form another library, or to -create an executable program. - -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. - -The following components of LINK-COMMAND are treated specially: - - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -bindir BINDIR specify path to binaries directory (for systems where - libraries must be found in the PATH setting at runtime) - -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE Use a list of object files found in FILE to specify objects - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -shared only do dynamic linking of libtool libraries - -shrext SUFFIX override the standard shared library file extension - -static do not do any dynamic linking of uninstalled libtool libraries - -static-libtool-libs - do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -weak LIBNAME declare that the target provides the LIBNAME interface - -Wc,FLAG - -Xcompiler FLAG pass linker-specific FLAG directly to the compiler - -Wl,FLAG - -Xlinker FLAG pass linker-specific FLAG directly to the linker - -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) - -All other options (arguments beginning with \`-') are ignored. - -Every other argument is treated as a filename. Files ending in \`.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in \`.la', then a libtool library is created, -only library objects (\`.lo' files) may be specified, and \`-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created -using \`ar' and \`ranlib', or on Windows using \`lib'. - -If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file -is created, otherwise an executable program is created." - ;; - - uninstall) - $ECHO \ -"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... - -Remove libraries from an installation directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; - - *) - func_fatal_help "invalid operation mode \`$opt_mode'" - ;; - esac - - echo - $ECHO "Try \`$progname --help' for more information about other modes." -} - -# Now that we've collected a possible --mode arg, show help if necessary -if $opt_help; then - if test "$opt_help" = :; then - func_mode_help - else - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - func_mode_help - done - } | sed -n '1p; 2,$s/^Usage:/ or: /p' - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - echo - func_mode_help - done - } | - sed '1d - /^When reporting/,/^Report/{ - H - d - } - $x - /information about other modes/d - /more detailed .*MODE/d - s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' - fi - exit $? -fi - - -# func_mode_execute arg... -func_mode_execute () -{ - $opt_debug - # The first argument is the command name. - cmd="$nonopt" - test -z "$cmd" && \ - func_fatal_help "you must specify a COMMAND" - - # Handle -dlopen flags immediately. - for file in $opt_dlopen; do - test -f "$file" \ - || func_fatal_help "\`$file' is not a file" - - dir= - case $file in - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$lib' is not a valid libtool archive" - - # Read the libtool library. - dlname= - library_names= - func_source "$file" - - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && \ - func_warning "\`$file' was not linked with \`-export-dynamic'" - continue - fi - - func_dirname "$file" "" "." - dir="$func_dirname_result" - - if test -f "$dir/$objdir/$dlname"; then - func_append dir "/$objdir" - else - if test ! -f "$dir/$dlname"; then - func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" - fi - fi - ;; - - *.lo) - # Just add the directory containing the .lo file. - func_dirname "$file" "" "." - dir="$func_dirname_result" - ;; - - *) - func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" - continue - ;; - esac - - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir="$absdir" - - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done - - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic="$magic" - - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -* | *.la | *.lo ) ;; - *) - # Do a test to see if this is really a libtool program. - if func_ltwrapper_script_p "$file"; then - func_source "$file" - # Transform arg to wrapped name. - file="$progdir/$program" - elif func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - func_source "$func_ltwrapper_scriptname_result" - # Transform arg to wrapped name. - file="$progdir/$program" - fi - ;; - esac - # Quote arguments (to preserve shell metacharacters). - func_append_quoted args "$file" - done - - if test "X$opt_dry_run" = Xfalse; then - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi - - # Restore saved environment variables - for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES - do - eval "if test \"\${save_$lt_var+set}\" = set; then - $lt_var=\$save_$lt_var; export $lt_var - else - $lt_unset $lt_var - fi" - done - - # Now prepare to actually exec the command. - exec_cmd="\$cmd$args" - else - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - echo "export $shlibpath_var" - fi - $ECHO "$cmd$args" - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = execute && func_mode_execute ${1+"$@"} - - -# func_mode_finish arg... -func_mode_finish () -{ - $opt_debug - libs= - libdirs= - admincmds= - - for opt in "$nonopt" ${1+"$@"} - do - if test -d "$opt"; then - func_append libdirs " $opt" - - elif test -f "$opt"; then - if func_lalib_unsafe_p "$opt"; then - func_append libs " $opt" - else - func_warning "\`$opt' is not a valid libtool archive" - fi - - else - func_fatal_error "invalid argument \`$opt'" - fi - done - - if test -n "$libs"; then - if test -n "$lt_sysroot"; then - sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` - sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" - else - sysroot_cmd= - fi - - # Remove sysroot references - if $opt_dry_run; then - for lib in $libs; do - echo "removing references to $lt_sysroot and \`=' prefixes from $lib" - done - else - tmpdir=`func_mktempdir` - for lib in $libs; do - sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ - > $tmpdir/tmp-la - mv -f $tmpdir/tmp-la $lib - done - ${RM}r "$tmpdir" - fi - fi - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - func_execute_cmds "$finish_cmds" 'admincmds="$admincmds -'"$cmd"'"' - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || func_append admincmds " - $cmds" - fi - done - fi - - # Exit here if they wanted silent mode. - $opt_silent && exit $EXIT_SUCCESS - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - echo "----------------------------------------------------------------------" - echo "Libraries have been installed in:" - for libdir in $libdirs; do - $ECHO " $libdir" - done - echo - echo "If you ever happen to want to link against installed libraries" - echo "in a given directory, LIBDIR, you must either use libtool, and" - echo "specify the full pathname of the library, or use the \`-LLIBDIR'" - echo "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - echo " - add LIBDIR to the \`$shlibpath_var' environment variable" - echo " during execution" - fi - if test -n "$runpath_var"; then - echo " - add LIBDIR to the \`$runpath_var' environment variable" - echo " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" - - $ECHO " - use the \`$flag' linker flag" - fi - if test -n "$admincmds"; then - $ECHO " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" - fi - echo - - echo "See any operating system documentation about shared libraries for" - case $host in - solaris2.[6789]|solaris2.1[0-9]) - echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" - echo "pages." - ;; - *) - echo "more information, such as the ld(1) and ld.so(8) manual pages." - ;; - esac - echo "----------------------------------------------------------------------" - fi - exit $EXIT_SUCCESS -} - -test "$opt_mode" = finish && func_mode_finish ${1+"$@"} - - -# func_mode_install arg... -func_mode_install () -{ - $opt_debug - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || - # Allow the use of GNU shtool's install command. - case $nonopt in *shtool*) :;; *) false;; esac; then - # Aesthetically quote it. - func_quote_for_eval "$nonopt" - install_prog="$func_quote_for_eval_result " - arg=$1 - shift - else - install_prog= - arg=$nonopt - fi - - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - func_quote_for_eval "$arg" - func_append install_prog "$func_quote_for_eval_result" - install_shared_prog=$install_prog - case " $install_prog " in - *[\\\ /]cp\ *) install_cp=: ;; - *) install_cp=false ;; - esac - - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=no - stripme= - no_mode=: - for arg - do - arg2= - if test -n "$dest"; then - func_append files " $dest" - dest=$arg - continue - fi - - case $arg in - -d) isdir=yes ;; - -f) - if $install_cp; then :; else - prev=$arg - fi - ;; - -g | -m | -o) - prev=$arg - ;; - -s) - stripme=" -s" - continue - ;; - -*) - ;; - *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - if test "x$prev" = x-m && test -n "$install_override_mode"; then - arg2=$install_override_mode - no_mode=false - fi - prev= - else - dest=$arg - continue - fi - ;; - esac - - # Aesthetically quote the argument. - func_quote_for_eval "$arg" - func_append install_prog " $func_quote_for_eval_result" - if test -n "$arg2"; then - func_quote_for_eval "$arg2" - fi - func_append install_shared_prog " $func_quote_for_eval_result" - done - - test -z "$install_prog" && \ - func_fatal_help "you must specify an install program" - - test -n "$prev" && \ - func_fatal_help "the \`$prev' option requires an argument" - - if test -n "$install_override_mode" && $no_mode; then - if $install_cp; then :; else - func_quote_for_eval "$install_override_mode" - func_append install_shared_prog " -m $func_quote_for_eval_result" - fi - fi - - if test -z "$files"; then - if test -z "$dest"; then - func_fatal_help "no file or destination specified" - else - func_fatal_help "you must specify a destination" - fi - fi - - # Strip any trailing slash from the destination. - func_stripname '' '/' "$dest" - dest=$func_stripname_result - - # Check to see that the destination is a directory. - test -d "$dest" && isdir=yes - if test "$isdir" = yes; then - destdir="$dest" - destname= - else - func_dirname_and_basename "$dest" "" "." - destdir="$func_dirname_result" - destname="$func_basename_result" - - # Not a directory, so check to see that there is only one file specified. - set dummy $files; shift - test "$#" -gt 1 && \ - func_fatal_help "\`$dest' is not a directory" - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - func_fatal_help "\`$destdir' must be an absolute directory name" - ;; - esac - done - ;; - esac - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do - - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - func_append staticlibs " $file" - ;; - - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$file' is not a valid libtool archive" - - library_names= - old_library= - relink_command= - func_source "$file" - - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in - *" $libdir "*) ;; - *) func_append current_libdirs " $libdir" ;; - esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in - *" $libdir "*) ;; - *) func_append future_libdirs " $libdir" ;; - esac - fi - - func_dirname "$file" "/" "" - dir="$func_dirname_result" - func_append dir "$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` - - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - test "$inst_prefix_dir" = "$destdir" && \ - func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" - - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` - fi - - func_warning "relinking \`$file'" - func_show_eval "$relink_command" \ - 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' - fi - - # See the names of the shared library. - set dummy $library_names; shift - if test -n "$1"; then - realname="$1" - shift - - srcname="$realname" - test -n "$relink_command" && srcname="$realname"T - - # Install the shared library and build the symlinks. - func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ - 'exit $?' - tstripme="$stripme" - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - case $realname in - *.dll.a) - tstripme="" - ;; - esac - ;; - esac - if test -n "$tstripme" && test -n "$striplib"; then - func_show_eval "$striplib $destdir/$realname" 'exit $?' - fi - - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try `ln -sf' first, because the `ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - test "$linkname" != "$realname" \ - && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" - done - fi - - # Do each command in the postinstall commands. - lib="$destdir/$realname" - func_execute_cmds "$postinstall_cmds" 'exit $?' - fi - - # Install the pseudo-library for information purposes. - func_basename "$file" - name="$func_basename_result" - instname="$dir/$name"i - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' - - # Maybe install the static library, too. - test -n "$old_library" && func_append staticlibs " $dir/$old_library" - ;; - - *.lo) - # Install (i.e. copy) a libtool object. - - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - func_lo2o "$destfile" - staticdest=$func_lo2o_result - ;; - *.$objext) - staticdest="$destfile" - destfile= - ;; - *) - func_fatal_help "cannot copy a libtool object to \`$destfile'" - ;; - esac - - # Install the libtool object if requested. - test -n "$destfile" && \ - func_show_eval "$install_prog $file $destfile" 'exit $?' - - # Install the old object if enabled. - if test "$build_old_libs" = yes; then - # Deduce the name of the old-style object file. - func_lo2o "$file" - staticobj=$func_lo2o_result - func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' - fi - exit $EXIT_SUCCESS - ;; - - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext="" - case $file in - *.exe) - if test ! -f "$file"; then - func_stripname '' '.exe' "$file" - file=$func_stripname_result - stripped_ext=".exe" - fi - ;; - esac - - # Do a test to see if this is really a libtool program. - case $host in - *cygwin* | *mingw*) - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - wrapper=$func_ltwrapper_scriptname_result - else - func_stripname '' '.exe' "$file" - wrapper=$func_stripname_result - fi - ;; - *) - wrapper=$file - ;; - esac - if func_ltwrapper_script_p "$wrapper"; then - notinst_deplibs= - relink_command= - - func_source "$wrapper" - - # Check the variables that should have been set. - test -z "$generated_by_libtool_version" && \ - func_fatal_error "invalid libtool wrapper script \`$wrapper'" - - finalize=yes - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - func_source "$lib" - fi - libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test - if test -n "$libdir" && test ! -f "$libfile"; then - func_warning "\`$lib' has not been installed in \`$libdir'" - finalize=no - fi - done - - relink_command= - func_source "$wrapper" - - outputname= - if test "$fast_install" = no && test -n "$relink_command"; then - $opt_dry_run || { - if test "$finalize" = yes; then - tmpdir=`func_mktempdir` - func_basename "$file$stripped_ext" - file="$func_basename_result" - outputname="$tmpdir/$file" - # Replace the output file specification. - relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` - - $opt_silent || { - func_quote_for_expand "$relink_command" - eval "func_echo $func_quote_for_expand_result" - } - if eval "$relink_command"; then : - else - func_error "error: relink \`$file' with the above command before installing it" - $opt_dry_run || ${RM}r "$tmpdir" - continue - fi - file="$outputname" - else - func_warning "cannot relink \`$file'" - fi - } - else - # Install the binary that we compiled earlier. - file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` - fi - fi - - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - func_stripname '' '.exe' "$destfile" - destfile=$func_stripname_result - ;; - esac - ;; - esac - func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' - $opt_dry_run || if test -n "$outputname"; then - ${RM}r "$tmpdir" - fi - ;; - esac - done - - for file in $staticlibs; do - func_basename "$file" - name="$func_basename_result" - - # Set up the ranlib parameters. - oldlib="$destdir/$name" - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - - func_show_eval "$install_prog \$file \$oldlib" 'exit $?' - - if test -n "$stripme" && test -n "$old_striplib"; then - func_show_eval "$old_striplib $tool_oldlib" 'exit $?' - fi - - # Do each command in the postinstall commands. - func_execute_cmds "$old_postinstall_cmds" 'exit $?' - done - - test -n "$future_libdirs" && \ - func_warning "remember to run \`$progname --finish$future_libdirs'" - - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - $opt_dry_run && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' - else - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = install && func_mode_install ${1+"$@"} - - -# func_generate_dlsyms outputname originator pic_p -# Extract symbols from dlprefiles and create ${outputname}S.o with -# a dlpreopen symbol table. -func_generate_dlsyms () -{ - $opt_debug - my_outputname="$1" - my_originator="$2" - my_pic_p="${3-no}" - my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` - my_dlsyms= - - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - my_dlsyms="${my_outputname}S.c" - else - func_error "not configured to extract global symbols from dlpreopened files" - fi - fi - - if test -n "$my_dlsyms"; then - case $my_dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist="$output_objdir/${my_outputname}.nm" - - func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - - # Parse the name list into a source file. - func_verbose "creating $output_objdir/$my_dlsyms" - - $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ -/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ -/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ - -#ifdef __cplusplus -extern \"C\" { -#endif - -#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) -#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" -#endif - -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -/* External symbol declarations for the compiler. */\ -" - - if test "$dlself" = yes; then - func_verbose "generating symbol list for \`$output'" - - $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` - for progfile in $progfiles; do - func_to_tool_file "$progfile" func_convert_file_msys_to_w32 - func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" - $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $opt_dry_run || { - eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - if test -n "$export_symbols_regex"; then - $opt_dry_run || { - eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols="$output_objdir/$outputname.exp" - $opt_dry_run || { - $RM $export_symbols - eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - } - else - $opt_dry_run || { - eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - } - fi - fi - - for dlprefile in $dlprefiles; do - func_verbose "extracting global C symbols from \`$dlprefile'" - func_basename "$dlprefile" - name="$func_basename_result" - case $host in - *cygwin* | *mingw* | *cegcc* ) - # if an import library, we need to obtain dlname - if func_win32_import_lib_p "$dlprefile"; then - func_tr_sh "$dlprefile" - eval "curr_lafile=\$libfile_$func_tr_sh_result" - dlprefile_dlbasename="" - if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then - # Use subshell, to avoid clobbering current variable values - dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` - if test -n "$dlprefile_dlname" ; then - func_basename "$dlprefile_dlname" - dlprefile_dlbasename="$func_basename_result" - else - # no lafile. user explicitly requested -dlpreopen . - $sharedlib_from_linklib_cmd "$dlprefile" - dlprefile_dlbasename=$sharedlib_from_linklib_result - fi - fi - $opt_dry_run || { - if test -n "$dlprefile_dlbasename" ; then - eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' - else - func_warning "Could not compute DLL name from $name" - eval '$ECHO ": $name " >> "$nlist"' - fi - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | - $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" - } - else # not an import lib - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - fi - ;; - *) - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - ;; - esac - done - - $opt_dry_run || { - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $MV "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if $GREP -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - $GREP -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' - else - echo '/* NONE */' >> "$output_objdir/$my_dlsyms" - fi - - echo >> "$output_objdir/$my_dlsyms" "\ - -/* The mapping between symbol names and symbols. */ -typedef struct { - const char *name; - void *address; -} lt_dlsymlist; -extern LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[]; -LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[] = -{\ - { \"$my_originator\", (void *) 0 }," - - case $need_lib_prefix in - no) - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - *) - eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - esac - echo >> "$output_objdir/$my_dlsyms" "\ - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_${my_prefix}_LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif\ -" - } # !$opt_dry_run - - pic_flag_for_symtable= - case "$compile_command " in - *" -static "*) ;; - *) - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; - *-*-hpux*) - pic_flag_for_symtable=" $pic_flag" ;; - *) - if test "X$my_pic_p" != Xno; then - pic_flag_for_symtable=" $pic_flag" - fi - ;; - esac - ;; - esac - symtab_cflags= - for arg in $LTCFLAGS; do - case $arg in - -pie | -fpie | -fPIE) ;; - *) func_append symtab_cflags " $arg" ;; - esac - done - - # Now compile the dynamic symbol file. - func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - - # Clean up the generated files. - func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' - - # Transform the symbol file into the correct name. - symfileobj="$output_objdir/${my_outputname}S.$objext" - case $host in - *cygwin* | *mingw* | *cegcc* ) - if test -f "$output_objdir/$my_outputname.def"; then - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - else - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - fi - ;; - *) - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - ;; - esac - ;; - *) - func_fatal_error "unknown suffix for \`$my_dlsyms'" - ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. - - # Nullify the symbol file. - compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` - fi -} - -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -# Despite the name, also deal with 64 bit binaries. -func_win32_libid () -{ - $opt_debug - win32_libid_type="unknown" - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then - func_to_tool_file "$1" func_convert_file_msys_to_w32 - win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | - $SED -n -e ' - 1,100{ - / I /{ - s,.*,import, - p - q - } - }'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; - esac - ;; - esac - $ECHO "$win32_libid_type" -} - -# func_cygming_dll_for_implib ARG -# -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib () -{ - $opt_debug - sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` -} - -# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs -# -# The is the core of a fallback implementation of a -# platform-specific function to extract the name of the -# DLL associated with the specified import library LIBNAME. -# -# SECTION_NAME is either .idata$6 or .idata$7, depending -# on the platform and compiler that created the implib. -# -# Echos the name of the DLL associated with the -# specified import library. -func_cygming_dll_for_implib_fallback_core () -{ - $opt_debug - match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` - $OBJDUMP -s --section "$1" "$2" 2>/dev/null | - $SED '/^Contents of section '"$match_literal"':/{ - # Place marker at beginning of archive member dllname section - s/.*/====MARK====/ - p - d - } - # These lines can sometimes be longer than 43 characters, but - # are always uninteresting - /:[ ]*file format pe[i]\{,1\}-/d - /^In archive [^:]*:/d - # Ensure marker is printed - /^====MARK====/p - # Remove all lines with less than 43 characters - /^.\{43\}/!d - # From remaining lines, remove first 43 characters - s/^.\{43\}//' | - $SED -n ' - # Join marker and all lines until next marker into a single line - /^====MARK====/ b para - H - $ b para - b - :para - x - s/\n//g - # Remove the marker - s/^====MARK====// - # Remove trailing dots and whitespace - s/[\. \t]*$// - # Print - /./p' | - # we now have a list, one entry per line, of the stringified - # contents of the appropriate section of all members of the - # archive which possess that section. Heuristic: eliminate - # all those which have a first or second character that is - # a '.' (that is, objdump's representation of an unprintable - # character.) This should work for all archives with less than - # 0x302f exports -- but will fail for DLLs whose name actually - # begins with a literal '.' or a single character followed by - # a '.'. - # - # Of those that remain, print the first one. - $SED -e '/^\./d;/^.\./d;q' -} - -# func_cygming_gnu_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is a GNU/binutils-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_gnu_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - 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)$'` - test -n "$func_cygming_gnu_implib_tmp" -} - -# func_cygming_ms_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is an MS-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_ms_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` - test -n "$func_cygming_ms_implib_tmp" -} - -# func_cygming_dll_for_implib_fallback ARG -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# -# This fallback implementation is for use when $DLLTOOL -# does not support the --identify-strict option. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib_fallback () -{ - $opt_debug - if func_cygming_gnu_implib_p "$1" ; then - # binutils import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` - elif func_cygming_ms_implib_p "$1" ; then - # ms-generated import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` - else - # unknown - sharedlib_from_linklib_result="" - fi -} - - -# func_extract_an_archive dir oldlib -func_extract_an_archive () -{ - $opt_debug - f_ex_an_ar_dir="$1"; shift - f_ex_an_ar_oldlib="$1" - if test "$lock_old_archive_extraction" = yes; then - lockfile=$f_ex_an_ar_oldlib.lock - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - fi - func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ - 'stat=$?; rm -f "$lockfile"; exit $stat' - if test "$lock_old_archive_extraction" = yes; then - $opt_dry_run || rm -f "$lockfile" - fi - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" - fi -} - - -# func_extract_archives gentop oldlib ... -func_extract_archives () -{ - $opt_debug - my_gentop="$1"; shift - my_oldlibs=${1+"$@"} - my_oldobjs="" - my_xlib="" - my_xabs="" - my_xdir="" - - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - func_basename "$my_xlib" - my_xlib="$func_basename_result" - my_xlib_u=$my_xlib - while :; do - case " $extracted_archives " in - *" $my_xlib_u "*) - func_arith $extracted_serial + 1 - extracted_serial=$func_arith_result - my_xlib_u=lt$extracted_serial-$my_xlib ;; - *) break ;; - esac - done - extracted_archives="$extracted_archives $my_xlib_u" - my_xdir="$my_gentop/$my_xlib_u" - - func_mkdir_p "$my_xdir" - - case $host in - *-darwin*) - func_verbose "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - $opt_dry_run || { - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - darwin_base_archive=`basename "$darwin_archive"` - darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` - if test -n "$darwin_arches"; then - darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches ; do - func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" - $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" - cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" - func_extract_an_archive "`pwd`" "${darwin_base_archive}" - cd "$darwin_curdir" - $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" - done # $darwin_arches - ## Okay now we've a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` - $LIPO -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - $RM -rf unfat-$$ - cd "$darwin_orig_dir" - else - cd $darwin_orig_dir - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - } # !$opt_dry_run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` - done - - func_extract_archives_result="$my_oldobjs" -} - - -# func_emit_wrapper [arg=no] -# -# Emit a libtool wrapper script on stdout. -# Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw -# wrapper executable. Must ONLY be called from within -# func_mode_link because it depends on a number of variables -# set therein. -# -# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR -# variable will take. If 'yes', then the emitted script -# will assume that the directory in which it is stored is -# the $objdir directory. This is a cygwin/mingw-specific -# behavior. -func_emit_wrapper () -{ - func_emit_wrapper_arg1=${1-no} - - $ECHO "\ -#! $SHELL - -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='$sed_quote_subst' - -# Be Bourne compatible -if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -relink_command=\"$relink_command\" - -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variables: - generated_by_libtool_version='$macro_version' - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$ECHO are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - file=\"\$0\"" - - qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` - $ECHO "\ - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - ECHO=\"$qECHO\" - fi - -# Very basic option parsing. These options are (a) specific to -# the libtool wrapper, (b) are identical between the wrapper -# /script/ and the wrapper /executable/ which is used only on -# windows platforms, and (c) all begin with the string "--lt-" -# (application programs are unlikely to have options which match -# this pattern). -# -# There are only two supported options: --lt-debug and -# --lt-dump-script. There is, deliberately, no --lt-help. -# -# The first argument to this parsing function should be the -# script's $0 value, followed by "$@". -lt_option_debug= -func_parse_lt_options () -{ - lt_script_arg0=\$0 - shift - for lt_opt - do - case \"\$lt_opt\" in - --lt-debug) lt_option_debug=1 ;; - --lt-dump-script) - lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` - test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. - lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` - cat \"\$lt_dump_D/\$lt_dump_F\" - exit 0 - ;; - --lt-*) - \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 - exit 1 - ;; - esac - done - - # Print the debug banner immediately: - if test -n \"\$lt_option_debug\"; then - echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 - fi -} - -# Used when --lt-debug. Prints its arguments to stdout -# (redirection is the responsibility of the caller) -func_lt_dump_args () -{ - lt_dump_args_N=1; - for lt_arg - do - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" - lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` - done -} - -# Core function for launching the target application -func_exec_program_core () -{ -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" - ;; - esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 -} - -# A function to encapsulate launching the target application -# Strips options in the --lt-* namespace from \$@ and -# launches target application with the remaining arguments. -func_exec_program () -{ - case \" \$* \" in - *\\ --lt-*) - for lt_wr_arg - do - case \$lt_wr_arg in - --lt-*) ;; - *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; - esac - shift - done ;; - esac - func_exec_program_core \${1+\"\$@\"} -} - - # Parse options - func_parse_lt_options \"\$0\" \${1+\"\$@\"} - - # Find the directory that this script lives in. - thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. - - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` - - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi - - file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` - done - - # Usually 'no', except on cygwin/mingw when embedded into - # the cwrapper. - WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 - if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then - # special case for '.' - if test \"\$thisdir\" = \".\"; then - thisdir=\`pwd\` - fi - # remove .libs from thisdir - case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; - $objdir ) thisdir=. ;; - esac - fi - - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" - - if test "$fast_install" = yes; then - $ECHO "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" - - if test ! -f \"\$progdir/\$program\" || - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then - - file=\"\$\$-\$program\" - - if test ! -d \"\$progdir\"; then - $MKDIR \"\$progdir\" - else - $RM \"\$progdir/\$file\" - fi" - - $ECHO "\ - - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - $ECHO \"\$relink_command_output\" >&2 - $RM \"\$progdir/\$file\" - exit 1 - fi - fi - - $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $RM \"\$progdir/\$program\"; - $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $RM \"\$progdir/\$file\" - fi" - else - $ECHO "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" - fi - - $ECHO "\ - - if test -f \"\$progdir/\$program\"; then" - - # fixup the dll searchpath if we need to. - # - # Fix the DLL searchpath if we need to. Do this before prepending - # to shlibpath, because on Windows, both are PATH and uninstalled - # libraries must come first. - if test -n "$dllsearchpath"; then - $ECHO "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" - fi - - # Export our shlibpath_var if we have one. - if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $ECHO "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` - - export $shlibpath_var -" - fi - - $ECHO "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. - func_exec_program \${1+\"\$@\"} - fi - else - # The program doesn't exist. - \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 - \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 - \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 - exit 1 - fi -fi\ -" -} - - -# func_emit_cwrapperexe_src -# emit the source code for a wrapper executable on stdout -# Must ONLY be called from within func_mode_link because -# it depends on a number of variable set therein. -func_emit_cwrapperexe_src () -{ - cat < -#include -#ifdef _MSC_VER -# include -# include -# include -#else -# include -# include -# ifdef __CYGWIN__ -# include -# endif -#endif -#include -#include -#include -#include -#include -#include -#include -#include - -/* declarations of non-ANSI functions */ -#if defined(__MINGW32__) -# ifdef __STRICT_ANSI__ -int _putenv (const char *); -# endif -#elif defined(__CYGWIN__) -# ifdef __STRICT_ANSI__ -char *realpath (const char *, char *); -int putenv (char *); -int setenv (const char *, const char *, int); -# endif -/* #elif defined (other platforms) ... */ -#endif - -/* portability defines, excluding path handling macros */ -#if defined(_MSC_VER) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -# define S_IXUSR _S_IEXEC -# ifndef _INTPTR_T_DEFINED -# define _INTPTR_T_DEFINED -# define intptr_t int -# endif -#elif defined(__MINGW32__) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -#elif defined(__CYGWIN__) -# define HAVE_SETENV -# define FOPEN_WB "wb" -/* #elif defined (other platforms) ... */ -#endif - -#if defined(PATH_MAX) -# define LT_PATHMAX PATH_MAX -#elif defined(MAXPATHLEN) -# define LT_PATHMAX MAXPATHLEN -#else -# define LT_PATHMAX 1024 -#endif - -#ifndef S_IXOTH -# define S_IXOTH 0 -#endif -#ifndef S_IXGRP -# define S_IXGRP 0 -#endif - -/* path handling portability macros */ -#ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' -#endif - -#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ - defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# define FOPEN_WB "wb" -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif -#endif - -#ifndef DIR_SEPARATOR_2 -# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) -#else /* DIR_SEPARATOR_2 */ -# define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) -#endif /* DIR_SEPARATOR_2 */ - -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - -#ifndef FOPEN_WB -# define FOPEN_WB "w" -#endif -#ifndef _O_BINARY -# define _O_BINARY 0 -#endif - -#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) -#define XFREE(stale) do { \ - if (stale) { free ((void *) stale); stale = 0; } \ -} while (0) - -#if defined(LT_DEBUGWRAPPER) -static int lt_debug = 1; -#else -static int lt_debug = 0; -#endif - -const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ - -void *xmalloc (size_t num); -char *xstrdup (const char *string); -const char *base_name (const char *name); -char *find_executable (const char *wrapper); -char *chase_symlinks (const char *pathspec); -int make_executable (const char *path); -int check_executable (const char *path); -char *strendzap (char *str, const char *pat); -void lt_debugprintf (const char *file, int line, const char *fmt, ...); -void lt_fatal (const char *file, int line, const char *message, ...); -static const char *nonnull (const char *s); -static const char *nonempty (const char *s); -void lt_setenv (const char *name, const char *value); -char *lt_extend_str (const char *orig_value, const char *add, int to_end); -void lt_update_exe_path (const char *name, const char *value); -void lt_update_lib_path (const char *name, const char *value); -char **prepare_spawn (char **argv); -void lt_dump_script (FILE *f); -EOF - - cat <= 0) - && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) - return 1; - else - return 0; -} - -int -make_executable (const char *path) -{ - int rval = 0; - struct stat st; - - lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", - nonempty (path)); - if ((!path) || (!*path)) - return 0; - - if (stat (path, &st) >= 0) - { - rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); - } - return rval; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise - Does not chase symlinks, even on platforms that support them. -*/ -char * -find_executable (const char *wrapper) -{ - int has_slash = 0; - const char *p; - const char *p_next; - /* static buffer for getcwd */ - char tmp[LT_PATHMAX + 1]; - int tmp_len; - char *concat_name; - - lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", - nonempty (wrapper)); - - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; - - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } -#endif - - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char *path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char *q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR (*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = - XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = - XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - return NULL; -} - -char * -chase_symlinks (const char *pathspec) -{ -#ifndef S_ISLNK - return xstrdup (pathspec); -#else - char buf[LT_PATHMAX]; - struct stat s; - char *tmp_pathspec = xstrdup (pathspec); - char *p; - int has_symlinks = 0; - while (strlen (tmp_pathspec) && !has_symlinks) - { - lt_debugprintf (__FILE__, __LINE__, - "checking path component for symlinks: %s\n", - tmp_pathspec); - if (lstat (tmp_pathspec, &s) == 0) - { - if (S_ISLNK (s.st_mode) != 0) - { - has_symlinks = 1; - break; - } - - /* search backwards for last DIR_SEPARATOR */ - p = tmp_pathspec + strlen (tmp_pathspec) - 1; - while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - p--; - if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - { - /* no more DIR_SEPARATORS left */ - break; - } - *p = '\0'; - } - else - { - lt_fatal (__FILE__, __LINE__, - "error accessing file \"%s\": %s", - tmp_pathspec, nonnull (strerror (errno))); - } - } - XFREE (tmp_pathspec); - - if (!has_symlinks) - { - return xstrdup (pathspec); - } - - tmp_pathspec = realpath (pathspec, buf); - if (tmp_pathspec == 0) - { - lt_fatal (__FILE__, __LINE__, - "could not follow symlinks for %s", pathspec); - } - return xstrdup (tmp_pathspec); -#endif -} - -char * -strendzap (char *str, const char *pat) -{ - size_t len, patlen; - - assert (str != NULL); - assert (pat != NULL); - - len = strlen (str); - patlen = strlen (pat); - - if (patlen <= len) - { - str += len - patlen; - if (strcmp (str, pat) == 0) - *str = '\0'; - } - return str; -} - -void -lt_debugprintf (const char *file, int line, const char *fmt, ...) -{ - va_list args; - if (lt_debug) - { - (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); - va_start (args, fmt); - (void) vfprintf (stderr, fmt, args); - va_end (args); - } -} - -static void -lt_error_core (int exit_status, const char *file, - int line, const char *mode, - const char *message, va_list ap) -{ - fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); - vfprintf (stderr, message, ap); - fprintf (stderr, ".\n"); - - if (exit_status >= 0) - exit (exit_status); -} - -void -lt_fatal (const char *file, int line, const char *message, ...) -{ - va_list ap; - va_start (ap, message); - lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); - va_end (ap); -} - -static const char * -nonnull (const char *s) -{ - return s ? s : "(null)"; -} - -static const char * -nonempty (const char *s) -{ - return (s && !*s) ? "(empty)" : nonnull (s); -} - -void -lt_setenv (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_setenv) setting '%s' to '%s'\n", - nonnull (name), nonnull (value)); - { -#ifdef HAVE_SETENV - /* always make a copy, for consistency with !HAVE_SETENV */ - char *str = xstrdup (value); - setenv (name, str, 1); -#else - int len = strlen (name) + 1 + strlen (value) + 1; - char *str = XMALLOC (char, len); - sprintf (str, "%s=%s", name, value); - if (putenv (str) != EXIT_SUCCESS) - { - XFREE (str); - } -#endif - } -} - -char * -lt_extend_str (const char *orig_value, const char *add, int to_end) -{ - char *new_value; - if (orig_value && *orig_value) - { - int orig_value_len = strlen (orig_value); - int add_len = strlen (add); - new_value = XMALLOC (char, add_len + orig_value_len + 1); - if (to_end) - { - strcpy (new_value, orig_value); - strcpy (new_value + orig_value_len, add); - } - else - { - strcpy (new_value, add); - strcpy (new_value + add_len, orig_value); - } - } - else - { - new_value = xstrdup (add); - } - return new_value; -} - -void -lt_update_exe_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - /* some systems can't cope with a ':'-terminated path #' */ - int len = strlen (new_value); - while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) - { - new_value[len-1] = '\0'; - } - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -void -lt_update_lib_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -EOF - case $host_os in - mingw*) - cat <<"EOF" - -/* Prepares an argument vector before calling spawn(). - Note that spawn() does not by itself call the command interpreter - (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : - ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); - GetVersionEx(&v); - v.dwPlatformId == VER_PLATFORM_WIN32_NT; - }) ? "cmd.exe" : "command.com"). - Instead it simply concatenates the arguments, separated by ' ', and calls - CreateProcess(). We must quote the arguments since Win32 CreateProcess() - interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a - special way: - - Space and tab are interpreted as delimiters. They are not treated as - delimiters if they are surrounded by double quotes: "...". - - Unescaped double quotes are removed from the input. Their only effect is - that within double quotes, space and tab are treated like normal - characters. - - Backslashes not followed by double quotes are not special. - - But 2*n+1 backslashes followed by a double quote become - n backslashes followed by a double quote (n >= 0): - \" -> " - \\\" -> \" - \\\\\" -> \\" - */ -#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" -#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" -char ** -prepare_spawn (char **argv) -{ - size_t argc; - char **new_argv; - size_t i; - - /* Count number of arguments. */ - for (argc = 0; argv[argc] != NULL; argc++) - ; - - /* Allocate new argument vector. */ - new_argv = XMALLOC (char *, argc + 1); - - /* Put quoted arguments into the new argument vector. */ - for (i = 0; i < argc; i++) - { - const char *string = argv[i]; - - if (string[0] == '\0') - new_argv[i] = xstrdup ("\"\""); - else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) - { - int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); - size_t length; - unsigned int backslashes; - const char *s; - char *quoted_string; - char *p; - - length = 0; - backslashes = 0; - if (quote_around) - length++; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - length += backslashes + 1; - length++; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - length += backslashes + 1; - - quoted_string = XMALLOC (char, length + 1); - - p = quoted_string; - backslashes = 0; - if (quote_around) - *p++ = '"'; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - { - unsigned int j; - for (j = backslashes + 1; j > 0; j--) - *p++ = '\\'; - } - *p++ = c; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - { - unsigned int j; - for (j = backslashes; j > 0; j--) - *p++ = '\\'; - *p++ = '"'; - } - *p = '\0'; - - new_argv[i] = quoted_string; - } - else - new_argv[i] = (char *) string; - } - new_argv[argc] = NULL; - - return new_argv; -} -EOF - ;; - esac - - cat <<"EOF" -void lt_dump_script (FILE* f) -{ -EOF - func_emit_wrapper yes | - $SED -n -e ' -s/^\(.\{79\}\)\(..*\)/\1\ -\2/ -h -s/\([\\"]\)/\\\1/g -s/$/\\n/ -s/\([^\n]*\).*/ fputs ("\1", f);/p -g -D' - cat <<"EOF" -} -EOF -} -# end: func_emit_cwrapperexe_src - -# func_win32_import_lib_p ARG -# True if ARG is an import lib, as indicated by $file_magic_cmd -func_win32_import_lib_p () -{ - $opt_debug - case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in - *import*) : ;; - *) false ;; - esac -} - -# func_mode_link arg... -func_mode_link () -{ - $opt_debug - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - # It is impossible to link a dll without this setting, and - # we shouldn't force the makefile maintainer to figure out - # which system we are compiling for in order to pass an extra - # flag for every libtool invocation. - # allow_undefined=no - - # FIXME: Unfortunately, there are problems with the above when trying - # to make a dll which has undefined symbols, in which case not - # even a static library is built. For now, we need to specify - # -no-undefined on the libtool link line when we can be certain - # that all symbols are satisfied, otherwise we get a static library. - allow_undefined=yes - ;; - *) - allow_undefined=yes - ;; - esac - libtool_args=$nonopt - base_compile="$nonopt $@" - compile_command=$nonopt - finalize_command=$nonopt - - compile_rpath= - finalize_rpath= - compile_shlibpath= - finalize_shlibpath= - convenience= - old_convenience= - deplibs= - old_deplibs= - compiler_flags= - linker_flags= - dllsearchpath= - lib_search_path=`pwd` - inst_prefix_dir= - new_inherited_linker_flags= - - avoid_version=no - bindir= - dlfiles= - dlprefiles= - dlself=no - export_dynamic=no - export_symbols= - export_symbols_regex= - generated= - libobjs= - ltlibs= - module=no - no_install=no - objs= - non_pic_objects= - precious_files_regex= - prefer_static_libs=no - preload=no - prev= - prevarg= - release= - rpath= - xrpath= - perm_rpath= - temp_rpath= - thread_safe=no - vinfo= - vinfo_number=no - weak_libs= - single_module="${wl}-single_module" - func_infer_tag $base_compile - - # We need to know -static, to get the right output filenames. - for arg - do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - break - ;; - -all-static | -static | -static-libtool-libs) - case $arg in - -all-static) - if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then - func_warning "complete static linking is impossible in this configuration" - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - -static) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=built - ;; - -static-libtool-libs) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - esac - build_libtool_libs=no - build_old_libs=yes - break - ;; - esac - done - - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes - - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg="$1" - shift - func_quote_for_eval "$arg" - qarg=$func_quote_for_eval_unquoted_result - func_append libtool_args " $func_quote_for_eval_result" - - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - func_append compile_command " @OUTPUT@" - func_append finalize_command " @OUTPUT@" - ;; - esac - - case $prev in - bindir) - bindir="$arg" - prev= - continue - ;; - dlfiles|dlprefiles) - if test "$preload" = no; then - # Add the symbol object into the linking commands. - func_append compile_command " @SYMFILE@" - func_append finalize_command " @SYMFILE@" - preload=yes - fi - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test "$dlself" = no; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test "$prev" = dlprefiles; then - dlself=yes - elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test "$prev" = dlfiles; then - func_append dlfiles " $arg" - else - func_append dlprefiles " $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols="$arg" - test -f "$arg" \ - || func_fatal_error "symbol file \`$arg' does not exist" - prev= - continue - ;; - expsyms_regex) - export_symbols_regex="$arg" - prev= - continue - ;; - framework) - case $host in - *-*-darwin*) - case "$deplibs " in - *" $qarg.ltframework "*) ;; - *) func_append deplibs " $qarg.ltframework" # this is fixed later - ;; - esac - ;; - esac - prev= - continue - ;; - inst_prefix) - inst_prefix_dir="$arg" - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat "$save_arg"` - do -# func_append moreargs " $fil" - arg=$fil - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - done - else - func_fatal_error "link input file \`$arg' does not exist" - fi - arg=$save_arg - prev= - continue - ;; - precious_regex) - precious_files_regex="$arg" - prev= - continue - ;; - release) - release="-$arg" - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - if test "$prev" = rpath; then - case "$rpath " in - *" $arg "*) ;; - *) func_append rpath " $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) func_append xrpath " $arg" ;; - esac - fi - prev= - continue - ;; - shrext) - shrext_cmds="$arg" - prev= - continue - ;; - weak) - func_append weak_libs " $arg" - prev= - continue - ;; - xcclinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xcompiler) - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xlinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $wl$qarg" - prev= - func_append compile_command " $wl$qarg" - func_append finalize_command " $wl$qarg" - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" - - prevarg="$arg" - - case $arg in - -all-static) - if test -n "$link_static_flag"; then - # See comment for -static flag below, for more details. - func_append compile_command " $link_static_flag" - func_append finalize_command " $link_static_flag" - fi - continue - ;; - - -allow-undefined) - # FIXME: remove this flag sometime in the future. - func_fatal_error "\`-allow-undefined' must not be used because it is the default" - ;; - - -avoid-version) - avoid_version=yes - continue - ;; - - -bindir) - prev=bindir - continue - ;; - - -dlopen) - prev=dlfiles - continue - ;; - - -dlpreopen) - prev=dlprefiles - continue - ;; - - -export-dynamic) - export_dynamic=yes - continue - ;; - - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - func_fatal_error "more than one -exported-symbols argument is not allowed" - fi - if test "X$arg" = "X-export-symbols"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; - - -framework) - prev=framework - continue - ;; - - -inst-prefix-dir) - prev=inst_prefix - continue - ;; - - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - func_append compile_command " $arg" - func_append finalize_command " $arg" - ;; - esac - continue - ;; - - -L*) - func_stripname "-L" '' "$arg" - if test -z "$func_stripname_result"; then - if test "$#" -gt 0; then - func_fatal_error "require no space between \`-L' and \`$1'" - else - func_fatal_error "need path for \`-L' option" - fi - fi - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - test -z "$absdir" && \ - func_fatal_error "cannot determine absolute directory name of \`$dir'" - dir="$absdir" - ;; - esac - case "$deplibs " in - *" -L$dir "* | *" $arg "*) - # Will only happen for absolute or sysroot arguments - ;; - *) - # Preserve sysroot, but never include relative directories - case $dir in - [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; - *) func_append deplibs " -L$dir" ;; - esac - func_append lib_search_path " $dir" - ;; - esac - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$dir:"*) ;; - ::) dllsearchpath=$dir;; - *) func_append dllsearchpath ":$dir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - continue - ;; - - -l*) - if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test "X$arg" = "X-lc" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - test "X$arg" = "X-lc" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - func_append deplibs " System.ltframework" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; - esac - elif test "X$arg" = "X-lc_r"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac - fi - func_append deplibs " $arg" - continue - ;; - - -module) - module=yes - continue - ;; - - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot|--sysroot) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - prev=xcompiler - continue - ;; - - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) func_append new_inherited_linker_flags " $arg" ;; - esac - continue - ;; - - -multi_module) - single_module="${wl}-multi_module" - continue - ;; - - -no-fast-install) - fast_install=no - continue - ;; - - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) - # The PATH hackery in wrapper scripts is required on Windows - # and Darwin in order for the loader to find any dlls it needs. - func_warning "\`-no-install' is ignored for $host" - func_warning "assuming \`-no-fast-install' instead" - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; - - -no-undefined) - allow_undefined=no - continue - ;; - - -objectlist) - prev=objectlist - continue - ;; - - -o) prev=output ;; - - -precious-files-regex) - prev=precious_regex - continue - ;; - - -release) - prev=release - continue - ;; - - -rpath) - prev=rpath - continue - ;; - - -R) - prev=xrpath - continue - ;; - - -R*) - func_stripname '-R' '' "$arg" - dir=$func_stripname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - =*) - func_stripname '=' '' "$dir" - dir=$lt_sysroot$func_stripname_result - ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - continue - ;; - - -shared) - # The effects of -shared are defined in a previous loop. - continue - ;; - - -shrext) - prev=shrext - continue - ;; - - -static | -static-libtool-libs) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; - - -thread-safe) - thread_safe=yes - continue - ;; - - -version-info) - prev=vinfo - continue - ;; - - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; - - -weak) - prev=weak - continue - ;; - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $func_quote_for_eval_result" - func_append compiler_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Wl,*) - func_stripname '-Wl,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $wl$func_quote_for_eval_result" - func_append compiler_flags " $wl$func_quote_for_eval_result" - func_append linker_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Xcompiler) - prev=xcompiler - continue - ;; - - -Xlinker) - prev=xlinker - continue - ;; - - -XCClinker) - prev=xcclinker - continue - ;; - - # -msg_* for osf cc - -msg_*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - # Flags to be passed through unchanged, with rationale: - # -64, -mips[0-9] enable 64-bit mode for the SGI compiler - # -r[0-9][0-9]* specify processor for the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler - # +DA*, +DD* enable 64-bit mode for the HP compiler - # -q* compiler args for the IBM compiler - # -m*, -t[45]*, -txscale* architecture-specific flags for GCC - # -F/path path to uninstalled frameworks, gcc on darwin - # -p, -pg, --coverage, -fprofile-* profiling flags for GCC - # @file GCC response files - # -tp=* Portland pgcc target processor selection - # --sysroot=* for sysroot support - # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ - -O*|-flto*|-fwhopr*|-fuse-linker-plugin) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - func_append compile_command " $arg" - func_append finalize_command " $arg" - func_append compiler_flags " $arg" - continue - ;; - - # Some other compiler flag. - -* | +*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - *.$objext) - # A standard object. - func_append objs " $arg" - ;; - - *.lo) - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - ;; - - *.$libext) - # An archive. - func_append deplibs " $arg" - func_append old_deplibs " $arg" - continue - ;; - - *.la) - # A libtool-controlled library. - - func_resolve_sysroot "$arg" - if test "$prev" = dlfiles; then - # This library was specified with -dlopen. - func_append dlfiles " $func_resolve_sysroot_result" - prev= - elif test "$prev" = dlprefiles; then - # The library was specified with -dlpreopen. - func_append dlprefiles " $func_resolve_sysroot_result" - prev= - else - func_append deplibs " $func_resolve_sysroot_result" - fi - continue - ;; - - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - esac # arg - - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - done # argument parsing loop - - test -n "$prev" && \ - func_fatal_help "the \`$prevarg' option requires an argument" - - if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - - oldlibs= - # calculate the name of the file, without its directory - func_basename "$output" - outputname="$func_basename_result" - libobjs_save="$libobjs" - - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - - func_dirname "$output" "/" "" - output_objdir="$func_dirname_result$objdir" - func_to_tool_file "$output_objdir/" - tool_output_objdir=$func_to_tool_file_result - # Create the object directory. - func_mkdir_p "$output_objdir" - - # Determine the type of output - case $output in - "") - func_fatal_help "you must specify an output file" - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac - - specialdeplibs= - - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if $opt_preserve_dup_deps ; then - case "$libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append libs " $deplib" - done - - if test "$linkmode" = lib; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" - - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if $opt_duplicate_compiler_generated_deps; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; - esac - func_append pre_post_deps " $pre_post_dep" - done - fi - pre_post_deps= - fi - - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - notinst_path= # paths that contain not-installed libtool libraries - - case $linkmode in - lib) - passes="conv dlpreopen link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=no - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac - - for pass in $passes; do - # The preopen pass in lib mode reverses $deplibs; put it back here - # so that -L comes before libs that need it for instance... - if test "$linkmode,$pass" = "lib,link"; then - ## FIXME: Find the place where the list is rebuilt in the wrong - ## order, and fix it there properly - tmp_deplibs= - for deplib in $deplibs; do - tmp_deplibs="$deplib $tmp_deplibs" - done - deplibs="$tmp_deplibs" - fi - - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan"; then - libs="$deplibs" - deplibs= - fi - if test "$linkmode" = prog; then - case $pass in - dlopen) libs="$dlfiles" ;; - dlpreopen) libs="$dlprefiles" ;; - link) - libs="$deplibs %DEPLIBS%" - test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" - ;; - esac - fi - if test "$linkmode,$pass" = "lib,dlpreopen"; then - # Collect and forward deplibs of preopened libtool libs - for lib in $dlprefiles; do - # Ignore non-libtool-libs - dependency_libs= - func_resolve_sysroot "$lib" - case $lib in - *.la) func_source "$func_resolve_sysroot_result" ;; - esac - - # Collect preopened libtool deplibs, except any this library - # has declared as weak libs - for deplib in $dependency_libs; do - func_basename "$deplib" - deplib_base=$func_basename_result - case " $weak_libs " in - *" $deplib_base "*) ;; - *) func_append deplibs " $deplib" ;; - esac - done - done - libs="$dlprefiles" - fi - if test "$pass" = dlopen; then - # Collect dlpreopened libraries - save_deplibs="$deplibs" - deplibs= - fi - - for deplib in $libs; do - lib= - found=no - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append compiler_flags " $deplib" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -l*) - if test "$linkmode" != lib && test "$linkmode" != prog; then - func_warning "\`-l' is ignored for archives/objects" - continue - fi - func_stripname '-l' '' "$deplib" - name=$func_stripname_result - if test "$linkmode" = lib; then - searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" - else - searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" - fi - for searchdir in $searchdirs; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib="$searchdir/lib${name}${search_ext}" - if test -f "$lib"; then - if test "$search_ext" = ".la"; then - found=yes - else - found=no - fi - break 2 - fi - done - done - if test "$found" != yes; then - # deplib doesn't seem to be a libtool library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - else # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $deplib "*) - if func_lalib_p "$lib"; then - library_names= - old_library= - func_source "$lib" - for l in $old_library $library_names; do - ll="$l" - done - if test "X$ll" = "X$old_library" ; then # only static version available - found=no - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - lib=$ladir/$old_library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - fi - ;; # -l - *.ltframework) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test "$pass" = conv && continue - newdependency_libs="$deplib $newdependency_libs" - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - prog) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - if test "$pass" = scan; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - *) - func_warning "\`-L' is ignored for archives/objects" - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test "$pass" = link; then - func_stripname '-R' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) - func_resolve_sysroot "$deplib" - lib=$func_resolve_sysroot_result - ;; - *.$libext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - # Linking convenience modules into shared libraries is allowed, - # but linking other static libraries is non-portable. - case " $dlpreconveniencelibs " in - *" $deplib "*) ;; - *) - valid_a_lib=no - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=yes - fi - ;; - pass_all) - valid_a_lib=yes - ;; - esac - if test "$valid_a_lib" != yes; then - echo - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because the file extensions .$libext of this argument makes me believe" - echo "*** that it is just a static archive that I should not use here." - else - echo - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - fi - ;; - esac - continue - ;; - prog) - if test "$pass" != link; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - elif test "$linkmode" = prog; then - if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - func_append newdlprefiles " $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append newdlfiles " $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=yes - continue - ;; - esac # case $deplib - - if test "$found" = yes || test -f "$lib"; then : - else - func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" - fi - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$lib" \ - || func_fatal_error "\`$lib' is not a valid libtool archive" - - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - - dlname= - dlopen= - dlpreopen= - libdir= - library_names= - old_library= - inherited_linker_flags= - # If the library was installed with an old release of libtool, - # it will not redefine variables installed, or shouldnotlink - installed=yes - shouldnotlink=no - avoidtemprpath= - - - # Read the .la file - func_source "$lib" - - # Convert "-framework foo" to "foo.ltframework" - if test -n "$inherited_linker_flags"; then - tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` - for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do - case " $new_inherited_linker_flags " in - *" $tmp_inherited_linker_flag "*) ;; - *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; - esac - done - fi - dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan" || - { test "$linkmode" != prog && test "$linkmode" != lib; }; then - test -n "$dlopen" && func_append dlfiles " $dlopen" - test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" - fi - - if test "$pass" = conv; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - # It is a libtool convenience library, so add in its objects. - func_append convenience " $ladir/$objdir/$old_library" - func_append old_convenience " $ladir/$objdir/$old_library" - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done - elif test "$linkmode" != prog && test "$linkmode" != lib; then - func_fatal_error "\`$lib' is not a convenience library" - fi - continue - fi # $pass = conv - - - # Get the name of the library we link against. - linklib= - if test -n "$old_library" && - { test "$prefer_static_libs" = yes || - test "$prefer_static_libs,$installed" = "built,no"; }; then - linklib=$old_library - else - for l in $old_library $library_names; do - linklib="$l" - done - fi - if test -z "$linklib"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - - # This library was specified with -dlopen. - if test "$pass" = dlopen; then - if test -z "$libdir"; then - func_fatal_error "cannot -dlopen a convenience library: \`$lib'" - fi - if test -z "$dlname" || - test "$dlopen_support" != yes || - test "$build_libtool_libs" = no; then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - func_append dlprefiles " $lib $dependency_libs" - else - func_append newdlfiles " $lib" - fi - continue - fi # $pass = dlopen - - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - func_warning "cannot determine absolute directory name of \`$ladir'" - func_warning "passing it literally to the linker, although it might fail" - abs_ladir="$ladir" - fi - ;; - esac - func_basename "$lib" - laname="$func_basename_result" - - # Find the relevant object directory and library name. - if test "X$installed" = Xyes; then - if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - func_warning "library \`$lib' was moved." - dir="$ladir" - absdir="$abs_ladir" - libdir="$abs_ladir" - else - dir="$lt_sysroot$libdir" - absdir="$lt_sysroot$libdir" - fi - test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir="$ladir" - absdir="$abs_ladir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - else - dir="$ladir/$objdir" - absdir="$abs_ladir/$objdir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - fi - fi # $installed = yes - func_stripname 'lib' '.la' "$laname" - name=$func_stripname_result - - # This library was specified with -dlpreopen. - if test "$pass" = dlpreopen; then - if test -z "$libdir" && test "$linkmode" = prog; then - func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" - fi - case "$host" in - # special handling for platforms with PE-DLLs. - *cygwin* | *mingw* | *cegcc* ) - # Linker will automatically link against shared library if both - # static and shared are present. Therefore, ensure we extract - # symbols from the import library if a shared library is present - # (otherwise, the dlopen module name will be incorrect). We do - # this by putting the import library name into $newdlprefiles. - # We recover the dlopen module name by 'saving' the la file - # name in a special purpose variable, and (later) extracting the - # dlname from the la file. - if test -n "$dlname"; then - func_tr_sh "$dir/$linklib" - eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" - func_append newdlprefiles " $dir/$linklib" - else - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - fi - ;; - * ) - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - func_append newdlprefiles " $dir/$dlname" - else - func_append newdlprefiles " $dir/$linklib" - fi - ;; - esac - fi # $pass = dlpreopen - - if test -z "$libdir"; then - # Link the convenience library - if test "$linkmode" = lib; then - deplibs="$dir/$old_library $deplibs" - elif test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi - - - if test "$linkmode" = prog && test "$pass" != link; then - func_append newlib_search_path " $ladir" - deplibs="$lib $deplibs" - - linkalldeplibs=no - if test "$link_all_deplibs" != no || test -z "$library_names" || - test "$build_libtool_libs" = no; then - linkalldeplibs=yes - fi - - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - esac - # Need to link against all dependency_libs? - if test "$linkalldeplibs" = yes; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done # for deplib - continue - fi # $linkmode = prog... - - if test "$linkmode,$pass" = "prog,link"; then - if test -n "$library_names" && - { { test "$prefer_static_libs" = no || - test "$prefer_static_libs,$installed" = "built,yes"; } || - test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then - # Make sure the rpath contains only unique directories. - case "$temp_rpath:" in - *"$absdir:"*) ;; - *) func_append temp_rpath "$absdir:" ;; - esac - fi - - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi # $linkmode,$pass = prog,link... - - if test "$alldeplibs" = yes && - { test "$deplibs_check_method" = pass_all || - { test "$build_libtool_libs" = yes && - test -n "$library_names"; }; }; then - # We only need to search for static libraries - continue - fi - fi - - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes; then - use_static_libs=no - fi - if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc*) - # No point in relinking DLLs because paths are not encoded - func_append notinst_deplibs " $lib" - need_relink=no - ;; - *) - if test "$installed" = no; then - func_append notinst_deplibs " $lib" - need_relink=yes - fi - ;; - esac - # This is a shared library - - # Warn about portability, can't link against -module's on some - # systems (darwin). Don't bleat about dlopened modules though! - dlopenmodule="" - for dlpremoduletest in $dlprefiles; do - if test "X$dlpremoduletest" = "X$lib"; then - dlopenmodule="$dlpremoduletest" - break - fi - done - if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then - echo - if test "$linkmode" = prog; then - $ECHO "*** Warning: Linking the executable $output against the loadable module" - else - $ECHO "*** Warning: Linking the shared library $output against the loadable module" - fi - $ECHO "*** $linklib is not portable!" - fi - if test "$linkmode" = lib && - test "$hardcode_into_libs" = yes; then - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi - - if test -n "$old_archive_from_expsyms_cmds"; then - # figure out the soname - set dummy $library_names - shift - realname="$1" - shift - libname=`eval "\\$ECHO \"$libname_spec\""` - # use dlname if we got it. it's perfectly good, no? - if test -n "$dlname"; then - soname="$dlname" - elif test -n "$soname_spec"; then - # bleh windows - case $host in - *cygwin* | mingw* | *cegcc*) - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - esac - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - - # Make a new name for the extract_expsyms_cmds to use - soroot="$soname" - func_basename "$soroot" - soname="$func_basename_result" - func_stripname 'lib' '.dll' "$soname" - newlib=libimp-$func_stripname_result.a - - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - func_verbose "extracting exported symbol list from \`$soname'" - func_execute_cmds "$extract_expsyms_cmds" 'exit $?' - fi - - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - func_verbose "generating import library for \`$soname'" - func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" - - if test "$linkmode" = prog || test "$opt_mode" != relink; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test "$hardcode_direct" = no; then - add="$dir/$linklib" - case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; - *-*-darwin* ) - # if the lib is a (non-dlopened) module then we can not - # link against it, someone is ignoring the earlier warnings - if /usr/bin/file -L $add 2> /dev/null | - $GREP ": [^:]* bundle" >/dev/null ; then - if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" - if test -z "$old_library" ; then - echo - echo "*** And there doesn't seem to be a static archive available" - echo "*** The link will probably fail, sorry" - else - add="$dir/$old_library" - fi - elif test -n "$old_library"; then - add="$dir/$old_library" - fi - fi - esac - elif test "$hardcode_minus_L" = no; then - case $host in - *-*-sunos*) add_shlibpath="$dir" ;; - esac - add_dir="-L$dir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = no; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - relink) - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$dir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$absdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac - - if test "$lib_linked" != yes; then - func_fatal_configuration "unsupported hardcode properties" - fi - - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) func_append compile_shlibpath "$add_shlibpath:" ;; - esac - fi - if test "$linkmode" = prog; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test "$hardcode_direct" != yes && - test "$hardcode_minus_L" != yes && - test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - fi - fi - fi - - if test "$linkmode" = prog || test "$opt_mode" = relink; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$libdir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$libdir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - add="-l$name" - elif test "$hardcode_automatic" = yes; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib" ; then - add="$inst_prefix_dir$libdir/$linklib" - else - add="$libdir/$linklib" - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir="-L$libdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - fi - - if test "$linkmode" = prog; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test "$linkmode" = prog; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test "$hardcode_direct" != unsupported; then - test -n "$old_library" && linklib="$old_library" - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test "$build_libtool_libs" = yes; then - # Not a shared library - if test "$deplibs_check_method" != pass_all; then - # We're trying link a shared library against a static one - # but the system doesn't support it. - - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - echo - $ECHO "*** Warning: This system can not link to static lib archive $lib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have." - if test "$module" = yes; then - echo "*** But as you try to build a module library, libtool will still create " - echo "*** a static module, that should work as long as the dlopening application" - echo "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? - - if test "$linkmode" = lib; then - if test -n "$dependency_libs" && - { test "$hardcode_into_libs" != yes || - test "$build_old_libs" = yes || - test "$link_static" = yes; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) func_stripname '-R' '' "$libdir" - temp_xrpath=$func_stripname_result - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) func_append xrpath " $temp_xrpath";; - esac;; - *) func_append temp_deplibs " $libdir";; - esac - done - dependency_libs="$temp_deplibs" - fi - - func_append newlib_search_path " $absdir" - # Link against this library - test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result";; - *) func_resolve_sysroot "$deplib" ;; - esac - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $func_resolve_sysroot_result "*) - func_append specialdeplibs " $func_resolve_sysroot_result" ;; - esac - fi - func_append tmp_libs " $func_resolve_sysroot_result" - done - - if test "$link_all_deplibs" != no; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - path= - case $deplib in - -L*) path="$deplib" ;; - *.la) - func_resolve_sysroot "$deplib" - deplib=$func_resolve_sysroot_result - func_dirname "$deplib" "" "." - dir=$func_dirname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - func_warning "cannot determine absolute directory name of \`$dir'" - absdir="$dir" - fi - ;; - esac - if $GREP "^installed=no" $deplib > /dev/null; then - case $host in - *-*-darwin*) - depdepl= - eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names" ; then - for tmp in $deplibrary_names ; do - depdepl=$tmp - done - if test -f "$absdir/$objdir/$depdepl" ; then - depdepl="$absdir/$objdir/$depdepl" - darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - if test -z "$darwin_install_name"; then - darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - fi - func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" - func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" - path= - fi - fi - ;; - *) - path="-L$absdir/$objdir" - ;; - esac - else - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - test "$absdir" != "$libdir" && \ - func_warning "\`$deplib' seems to be moved" - - path="-L$absdir" - fi - ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - if test "$pass" = link; then - if test "$linkmode" = "prog"; then - compile_deplibs="$new_inherited_linker_flags $compile_deplibs" - finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" - else - compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - fi - fi - dependency_libs="$newdependency_libs" - if test "$pass" = dlpreopen; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test "$pass" != dlopen; then - if test "$pass" != conv; then - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) func_append lib_search_path " $dir" ;; - esac - done - newlib_search_path= - fi - - if test "$linkmode,$pass" != "prog,link"; then - vars="deplibs" - else - vars="compile_deplibs finalize_deplibs" - fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) func_append tmp_libs " $deplib" ;; - esac - ;; - *) func_append tmp_libs " $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs ; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i="" - ;; - esac - if test -n "$i" ; then - func_append tmp_libs " $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test "$linkmode" = prog; then - dlfiles="$newdlfiles" - fi - if test "$linkmode" = prog || test "$linkmode" = lib; then - dlprefiles="$newdlprefiles" - fi - - case $linkmode in - oldlib) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for archives" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for archives" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for archives" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for archives" - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for archives" - - test -n "$release" && \ - func_warning "\`-release' is ignored for archives" - - test -n "$export_symbols$export_symbols_regex" && \ - func_warning "\`-export-symbols' is ignored for archives" - - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs="$output" - func_append objs "$old_deplibs" - ;; - - lib) - # Make sure we only generate libraries of the form `libNAME.la'. - case $outputname in - lib*) - func_stripname 'lib' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - test "$module" = no && \ - func_fatal_help "libtool library \`$output' must begin with \`lib'" - - if test "$need_lib_prefix" != no; then - # Add the "lib" prefix for modules if required - func_stripname '' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - func_stripname '' '.la' "$outputname" - libname=$func_stripname_result - fi - ;; - esac - - if test -n "$objs"; then - if test "$deplibs_check_method" != pass_all; then - func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" - else - echo - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" - func_append libobjs " $objs" - fi - fi - - test "$dlself" != no && \ - func_warning "\`-dlopen self' is ignored for libtool libraries" - - set dummy $rpath - shift - test "$#" -gt 1 && \ - func_warning "ignoring multiple \`-rpath's for a libtool library" - - install_libdir="$1" - - oldlibs= - if test -z "$rpath"; then - if test "$build_libtool_libs" = yes; then - # Building a libtool convenience library. - # Some compilers have problems with a `.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for convenience libraries" - - test -n "$release" && \ - func_warning "\`-release' is ignored for convenience libraries" - else - - # Parse the version information argument. - save_ifs="$IFS"; IFS=':' - set dummy $vinfo 0 0 0 - shift - IFS="$save_ifs" - - test -n "$7" && \ - func_fatal_help "too many parameters to \`-version-info'" - - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible - - case $vinfo_number in - yes) - number_major="$1" - number_minor="$2" - number_revision="$3" - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # which has an extra 1 added just for fun - # - case $version_type in - # correct linux to gnu/linux during the next big refactor - darwin|linux|osf|windows|none) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_revision" - ;; - freebsd-aout|freebsd-elf|qnx|sunos) - current="$number_major" - revision="$number_minor" - age="0" - ;; - irix|nonstopux) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_minor" - lt_irix_increment=no - ;; - *) - func_fatal_configuration "$modename: unknown library version type \`$version_type'" - ;; - esac - ;; - no) - current="$1" - revision="$2" - age="$3" - ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 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]) ;; - *) - func_error "CURRENT \`$current' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $revision in - 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]) ;; - *) - func_error "REVISION \`$revision' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $age in - 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]) ;; - *) - func_error "AGE \`$age' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - if test "$age" -gt "$current"; then - func_error "AGE \`$age' is greater than the current interface number \`$current'" - func_fatal_error "\`$vinfo' is not valid version information" - fi - - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; - - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - # Darwin ld doesn't like 0 for these options... - func_arith $current + 1 - minor_current=$func_arith_result - xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - ;; - - freebsd-aout) - major=".$current" - versuffix=".$current.$revision"; - ;; - - freebsd-elf) - major=".$current" - versuffix=".$current" - ;; - - irix | nonstopux) - if test "X$lt_irix_increment" = "Xno"; then - func_arith $current - $age - else - func_arith $current - $age + 1 - fi - major=$func_arith_result - - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring="$verstring_prefix$major.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$revision - while test "$loop" -ne 0; do - func_arith $revision - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring_prefix$major.$iface:$verstring" - done - - # Before this point, $major must not contain `.'. - major=.$major - versuffix="$major.$revision" - ;; - - linux) # correct to gnu/linux during the next big refactor - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - ;; - - osf) - func_arith $current - $age - major=.$func_arith_result - versuffix=".$current.$age.$revision" - verstring="$current.$age.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$age - while test "$loop" -ne 0; do - func_arith $current - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring:${iface}.0" - done - - # Make executables depend on our current version. - func_append verstring ":${current}.0" - ;; - - qnx) - major=".$current" - versuffix=".$current" - ;; - - sunos) - major=".$current" - versuffix=".$current.$revision" - ;; - - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 filesystems. - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - - *) - func_fatal_configuration "unknown library version type \`$version_type'" - ;; - esac - - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring="0.0" - ;; - esac - if test "$need_version" = no; then - versuffix= - else - versuffix=".0.0" - fi - fi - - # Remove version info from name if versioning should be avoided - if test "$avoid_version" = yes && test "$need_version" = no; then - major= - versuffix= - verstring="" - fi - - # Check to see if the archive will have undefined symbols. - if test "$allow_undefined" = yes; then - if test "$allow_undefined_flag" = unsupported; then - func_warning "undefined symbols not allowed in $host shared libraries" - build_libtool_libs=no - build_old_libs=yes - fi - else - # Don't allow undefined symbols. - allow_undefined_flag="$no_undefined_flag" - fi - - fi - - func_generate_dlsyms "$libname" "$libname" "yes" - func_append libobjs " $symfileobj" - test "X$libobjs" = "X " && libobjs= - - if test "$opt_mode" != relink; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$ECHO "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext | *.gcno) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) - if test "X$precious_files_regex" != "X"; then - if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - func_append removelist " $p" - ;; - *) ;; - esac - done - test -n "$removelist" && \ - func_show_eval "${RM}r \$removelist" - fi - - # Now set the variables for building old libraries. - if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then - func_append oldlibs " $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` - fi - - # Eliminate all temporary directories. - #for path in $notinst_path; do - # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` - # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` - # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` - #done - - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - func_replace_sysroot "$libdir" - func_append temp_xrpath " -R$func_replace_sysroot_result" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then - dependency_libs="$temp_xrpath $dependency_libs" - fi - fi - - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles="$dlfiles" - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) func_append dlfiles " $lib" ;; - esac - done - - # Make sure dlprefiles contains only unique files - old_dlprefiles="$dlprefiles" - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) func_append dlprefiles " $lib" ;; - esac - done - - if test "$build_libtool_libs" = yes; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - func_append deplibs " System.ltframework" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test "$build_libtool_need_lc" = "yes"; then - func_append deplibs " -lc" - fi - ;; - esac - fi - - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release="" - versuffix="" - major="" - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c </dev/null` - $nocaseglob - else - potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` - fi - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null | - $GREP " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib="$potent_lib" - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | - $SED -e 10q | - $EGREP "$file_magic_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - for a_deplib in $deplibs; do - case $a_deplib in - -l*) - func_stripname -l '' "$a_deplib" - name=$func_stripname_result - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $a_deplib "*) - func_append newdeplibs " $a_deplib" - a_deplib="" - ;; - esac - fi - if test -n "$a_deplib" ; then - libname=`eval "\\$ECHO \"$libname_spec\""` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib="$potent_lib" # see symlink-check above in file_magic test - if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ - $EGREP "$match_pattern_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs="" - tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - for i in $predeps $postdeps ; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` - done - fi - case $tmp_deplibs in - *[!\ \ ]*) - echo - if test "X$deplibs_check_method" = "Xnone"; then - echo "*** Warning: inter-library dependencies are not supported in this platform." - else - echo "*** Warning: inter-library dependencies are not known to be supported." - fi - echo "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes - ;; - esac - ;; - esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library with the System framework - newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - if test "$droppeddeps" = yes; then - if test "$module" = yes; then - echo - echo "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - echo "*** a static module, that should work as long as the dlopening" - echo "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - echo "*** The inter-library dependencies that have been dropped here will be" - echo "*** automatically added whenever a program is linked with this library" - echo "*** or is declared to -dlopen it." - - if test "$allow_undefined" = no; then - echo - echo "*** Since this library must not contain undefined symbols," - echo "*** because either the platform does not support them or" - echo "*** it was explicitly requested with -no-undefined," - echo "*** libtool will only create a static version of it." - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - case $host in - *-*-darwin*) - newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - deplibs="$new_libs" - - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= - - # Test again, we may have decided not to build it any more - if test "$build_libtool_libs" = yes; then - # Remove ${wl} instances when linking with ld. - # FIXME: should test the right _cmds variable. - case $archive_cmds in - *\$LD\ *) wl= ;; - esac - if test "$hardcode_into_libs" = yes; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath="$finalize_rpath" - test "$opt_mode" != relink && rpath="$compile_rpath$rpath" - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - func_replace_sysroot "$libdir" - libdir=$func_replace_sysroot_result - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append dep_rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi - - shlibpath="$finalize_shlibpath" - test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi - - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - shift - realname="$1" - shift - - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - if test -z "$dlname"; then - dlname=$soname - fi - - lib="$output_objdir/$realname" - linknames= - for link - do - func_append linknames " $link" - done - - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` - test "X$libobjs" = "X " && libobjs= - - delfiles= - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" - export_symbols="$output_objdir/$libname.uexp" - func_append delfiles " $export_symbols" - fi - - orig_export_symbols= - case $host_os in - cygwin* | mingw* | cegcc*) - if test -n "$export_symbols" && test -z "$export_symbols_regex"; then - # exporting using user supplied symfile - if test "x`$SED 1q $export_symbols`" != xEXPORTS; then - # and it's NOT already a .def file. Must figure out - # which of the given symbols are data symbols and tag - # them as such. So, trigger use of export_symbols_cmds. - # export_symbols gets reassigned inside the "prepare - # the list of exported symbols" if statement, so the - # include_expsyms logic still works. - orig_export_symbols="$export_symbols" - export_symbols= - always_export_symbols=yes - fi - fi - ;; - esac - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - cmds=$export_symbols_cmds - save_ifs="$IFS"; IFS='~' - for cmd1 in $cmds; do - IFS="$save_ifs" - # Take the normal branch if the nm_file_list_spec branch - # doesn't work or if tool conversion is not needed. - case $nm_file_list_spec~$to_tool_file_cmd in - *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) - try_normal_branch=yes - eval cmd=\"$cmd1\" - func_len " $cmd" - len=$func_len_result - ;; - *) - try_normal_branch=no - ;; - esac - if test "$try_normal_branch" = yes \ - && { test "$len" -lt "$max_cmd_len" \ - || test "$max_cmd_len" -le -1; } - then - func_show_eval "$cmd" 'exit $?' - skipped_export=false - elif test -n "$nm_file_list_spec"; then - func_basename "$output" - output_la=$func_basename_result - save_libobjs=$libobjs - save_output=$output - output=${output_objdir}/${output_la}.nm - func_to_tool_file "$output" - libobjs=$nm_file_list_spec$func_to_tool_file_result - func_append delfiles " $output" - func_verbose "creating $NM input file list: $output" - for obj in $save_libobjs; do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > "$output" - eval cmd=\"$cmd1\" - func_show_eval "$cmd" 'exit $?' - output=$save_output - libobjs=$save_libobjs - skipped_export=false - else - # The command line is too long to execute in one step. - func_verbose "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS="$save_ifs" - if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - fi - - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - func_append tmp_deplibs " $test_deplib" - ;; - esac - done - deplibs="$tmp_deplibs" - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec" && - test "$compiler_needs_object" = yes && - test -z "$libobjs"; then - # extract the archives, so we have objects to list. - # TODO: could optimize this to just extract one archive. - whole_archive_flag_spec= - fi - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - else - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - fi - - if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - func_append linker_flags " $flag" - fi - - # Make a backup of the uninstalled library when relinking - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? - fi - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi - - if test "X$skipped_export" != "X:" && - func_len " $test_cmds" && - len=$func_len_result && - test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise - # or, if using GNU ld and skipped_export is not :, use a linker - # script. - - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - func_basename "$output" - output_la=$func_basename_result - - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - last_robj= - k=1 - - if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then - output=${output_objdir}/${output_la}.lnkscript - func_verbose "creating GNU ld script: $output" - echo 'INPUT (' > $output - for obj in $save_libobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - echo ')' >> $output - func_append delfiles " $output" - func_to_tool_file "$output" - output=$func_to_tool_file_result - elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then - output=${output_objdir}/${output_la}.lnk - func_verbose "creating linker input file list: $output" - : > $output - set x $save_libobjs - shift - firstobj= - if test "$compiler_needs_object" = yes; then - firstobj="$1 " - shift - fi - for obj - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - func_append delfiles " $output" - func_to_tool_file "$output" - output=$firstobj\"$file_list_spec$func_to_tool_file_result\" - else - if test -n "$save_libobjs"; then - func_verbose "creating reloadable object files..." - output=$output_objdir/$output_la-${k}.$objext - eval test_cmds=\"$reload_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - if test "X$objlist" = X || - test "$len" -lt "$max_cmd_len"; then - func_append objlist " $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test "$k" -eq 1 ; then - # The first file doesn't have a previous command to add. - reload_objs=$objlist - eval concat_cmds=\"$reload_cmds\" - else - # All subsequent reloadable object files will link in - # the last one created. - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" - fi - last_robj=$output_objdir/$output_la-${k}.$objext - func_arith $k + 1 - k=$func_arith_result - output=$output_objdir/$output_la-${k}.$objext - objlist=" $obj" - func_len " $last_robj" - func_arith $len0 + $func_len_result - len=$func_arith_result - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\${concat_cmds}$reload_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" - fi - func_append delfiles " $output" - - else - output= - fi - - if ${skipped_export-false}; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - libobjs=$output - # Append the command to create the export file. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - fi - - test -n "$save_libobjs" && - func_verbose "creating a temporary reloadable object file: $output" - - # Loop through the commands generated above and execute them. - save_ifs="$IFS"; IFS='~' - for cmd in $concat_cmds; do - IFS="$save_ifs" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - if test -n "$export_symbols_regex" && ${skipped_export-false}; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - - if ${skipped_export-false}; then - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - fi - - libobjs=$output - # Restore the value of output. - output=$save_output - - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds - else - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds - else - cmds=$archive_cmds - fi - fi - fi - - if test -n "$delfiles"; then - # Append the command to remove temporary files to $cmds. - eval cmds=\"\$cmds~\$RM $delfiles\" - fi - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? - - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - func_show_eval '${RM}r "$gentop"' - fi - fi - - exit $EXIT_SUCCESS - fi - - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' - fi - done - - # If -module or -export-dynamic was specified, set the dlname. - if test "$module" = yes || test "$export_dynamic" = yes; then - # On all known operating systems, these are identical. - dlname="$soname" - fi - fi - ;; - - obj) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for objects" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for objects" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for objects" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for objects" - - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for objects" - - test -n "$release" && \ - func_warning "\`-release' is ignored for objects" - - case $output in - *.lo) - test -n "$objs$old_deplibs" && \ - func_fatal_error "cannot build library object \`$output' from non-libtool objects" - - libobj=$output - func_lo2o "$libobj" - obj=$func_lo2o_result - ;; - *) - libobj= - obj="$output" - ;; - esac - - # Delete the old objects. - $opt_dry_run || $RM $obj $libobj - - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # reload_cmds runs $LD directly, so let us get rid of - # -Wl from whole_archive_flag_spec and hope we can get by with - # turning comma into space.. - wl= - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" - reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` - else - gentop="$output_objdir/${obj}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi - - # If we're not building shared, we need to use non_pic_objs - test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" - - # Create the old-style object. - reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test - - output="$obj" - func_execute_cmds "$reload_cmds" 'exit $?' - - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - fi - - if test "$build_libtool_libs" != yes; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - fi - - if test -n "$pic_flag" || test "$pic_mode" != default; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output="$libobj" - func_execute_cmds "$reload_cmds" 'exit $?' - fi - - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - ;; - - prog) - case $host in - *cygwin*) func_stripname '' '.exe' "$output" - output=$func_stripname_result.exe;; - esac - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for programs" - - test -n "$release" && \ - func_warning "\`-release' is ignored for programs" - - test "$preload" = yes \ - && test "$dlopen_support" = unknown \ - && test "$dlopen_self" = unknown \ - && test "$dlopen_self_static" = unknown && \ - func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - case $host in - *-*-darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - # But is supposedly fixed on 10.4 or later (yay!). - if test "$tagname" = CXX ; then - case ${MACOSX_DEPLOYMENT_TARGET-10.0} in - 10.[0123]) - func_append compile_command " ${wl}-bind_at_load" - func_append finalize_command " ${wl}-bind_at_load" - ;; - esac - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - compile_deplibs="$new_libs" - - - func_append compile_command " $compile_deplibs" - func_append finalize_command " $finalize_deplibs" - - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - fi - - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - ::) dllsearchpath=$libdir;; - *) func_append dllsearchpath ":$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath="$rpath" - - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) func_append finalize_perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath="$rpath" - - if test -n "$libobjs" && test "$build_old_libs" = yes; then - # Transform all the library objects into standard objects. - compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - fi - - func_generate_dlsyms "$outputname" "@PROGRAM@" "no" - - # template prelinking step - if test -n "$prelink_cmds"; then - func_execute_cmds "$prelink_cmds" 'exit $?' - fi - - wrappers_required=yes - case $host in - *cegcc* | *mingw32ce*) - # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. - wrappers_required=no - ;; - *cygwin* | *mingw* ) - if test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - *) - if test "$need_relink" = no || test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - esac - if test "$wrappers_required" = no; then - # Replace the output file specification. - compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - link_command="$compile_command$compile_rpath" - - # We have no uninstalled library dependencies, so finalize right now. - exit_status=0 - func_show_eval "$link_command" 'exit_status=$?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Delete the generated files. - if test -f "$output_objdir/${outputname}S.${objext}"; then - func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' - fi - - exit $exit_status - fi - - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi - - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - func_append rpath "$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - fi - - if test "$no_install" = yes; then - # We don't need to create a wrapper script. - link_command="$compile_var$compile_command$compile_rpath" - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $opt_dry_run || $RM $output - # Link the executable and exit - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - exit $EXIT_SUCCESS - fi - - if test "$hardcode_action" = relink; then - # Fast installation is not supported - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - - func_warning "this platform does not like uninstalled shared libraries" - func_warning "\`$output' will be relinked during installation" - else - if test "$fast_install" != no; then - link_command="$finalize_var$compile_command$finalize_rpath" - if test "$fast_install" = yes; then - relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` - else - # fast_install is set to needless - relink_command= - fi - else - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - fi - fi - - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - - # Delete the old output files. - $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname - - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output_objdir/$outputname" - 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'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Now create the wrapper script. - func_verbose "creating $output" - - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - fi - - # Only actually do things if not in dry run mode. - $opt_dry_run || { - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) func_stripname '' '.exe' "$output" - output=$func_stripname_result ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - func_stripname '' '.exe' "$outputname" - outputname=$func_stripname_result ;; - *) exeext= ;; - esac - case $host in - *cygwin* | *mingw* ) - func_dirname_and_basename "$output" "" "." - output_name=$func_basename_result - output_path=$func_dirname_result - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $RM $cwrappersource $cwrapper - trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - - func_emit_cwrapperexe_src > $cwrappersource - - # The wrapper executable is built using the $host compiler, - # because it contains $host paths and files. If cross- - # compiling, it, like the target executable, must be - # executed on the $host or under an emulation environment. - $opt_dry_run || { - $LTCC $LTCFLAGS -o $cwrapper $cwrappersource - $STRIP $cwrapper - } - - # Now, create the wrapper script for func_source use: - func_ltwrapper_scriptname $cwrapper - $RM $func_ltwrapper_scriptname_result - trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 - $opt_dry_run || { - # note: this script will not be executed, so do not chmod. - if test "x$build" = "x$host" ; then - $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result - else - func_emit_wrapper no > $func_ltwrapper_scriptname_result - fi - } - ;; - * ) - $RM $output - trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 - - func_emit_wrapper no > $output - chmod +x $output - ;; - esac - } - exit $EXIT_SUCCESS - ;; - esac - - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do - - if test "$build_libtool_libs" = convenience; then - oldobjs="$libobjs_save $symfileobj" - addlibs="$convenience" - build_libtool_libs=no - else - if test "$build_libtool_libs" = module; then - oldobjs="$libobjs_save" - build_libtool_libs=no - else - oldobjs="$old_deplibs $non_pic_objects" - if test "$preload" = yes && test -f "$symfileobj"; then - func_append oldobjs " $symfileobj" - fi - fi - addlibs="$old_convenience" - fi - - if test -n "$addlibs"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $addlibs - func_append oldobjs " $func_extract_archives_result" - fi - - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then - cmds=$old_archive_from_new_cmds - else - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append oldobjs " $func_extract_archives_result" - fi - - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - func_basename "$obj" - $ECHO "$func_basename_result" - done | sort | sort -uc >/dev/null 2>&1); then - : - else - echo "copying selected object files to avoid basename conflicts..." - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - func_mkdir_p "$gentop" - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - func_basename "$obj" - objbase="$func_basename_result" - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - func_arith $counter + 1 - counter=$func_arith_result - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - func_append oldobjs " $gentop/$newobj" - ;; - *) func_append oldobjs " $obj" ;; - esac - done - fi - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - eval cmds=\"$old_archive_cmds\" - - func_len " $cmds" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds - elif test -n "$archiver_list_spec"; then - func_verbose "using command file archive linking..." - for obj in $oldobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > $output_objdir/$libname.libcmd - func_to_tool_file "$output_objdir/$libname.libcmd" - oldobjs=" $archiver_list_spec$func_to_tool_file_result" - cmds=$old_archive_cmds - else - # the command line is too long to link in one step, link in parts - func_verbose "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - oldobjs= - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - eval test_cmds=\"$old_archive_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - for obj in $save_oldobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - func_append objlist " $obj" - if test "$len" -lt "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj" ; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" - objlist= - len=$len0 - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test "X$oldobjs" = "X" ; then - eval cmds=\"\$concat_cmds\" - else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" - fi - fi - fi - func_execute_cmds "$cmds" 'exit $?' - done - - test -n "$generated" && \ - func_show_eval "${RM}r$generated" - - # Now create the libtool archive. - case $output in - *.la) - old_library= - test "$build_old_libs" = yes && old_library="$libname.$libext" - func_verbose "creating $output" - - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - if test "$hardcode_automatic" = yes ; then - relink_command= - fi - - # Only create the output if not a dry run. - $opt_dry_run || { - for installed in no yes; do - if test "$installed" = yes; then - if test -z "$install_libdir"; then - break - fi - output="$output_objdir/$outputname"i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - func_basename "$deplib" - name="$func_basename_result" - func_resolve_sysroot "$deplib" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" - ;; - -L*) - func_stripname -L '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -L$func_replace_sysroot_result" - ;; - -R*) - func_stripname -R '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -R$func_replace_sysroot_result" - ;; - *) func_append newdependency_libs " $deplib" ;; - esac - done - dependency_libs="$newdependency_libs" - newdlfiles= - - for lib in $dlfiles; do - case $lib in - *.la) - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" - ;; - *) func_append newdlfiles " $lib" ;; - esac - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - *.la) - # Only pass preopened files to the pseudo-archive (for - # eventual linking with the app. that links it) if we - # didn't already link the preopened objects directly into - # the library: - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" - ;; - esac - done - dlprefiles="$newdlprefiles" - else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlfiles " $abs" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlprefiles " $abs" - done - dlprefiles="$newdlprefiles" - fi - $RM $output - # place dlname in correct position for cygwin - # In fact, it would be nice if we could use this code for all target - # systems that can't hard-code library paths into their executables - # and that have no shared library path variable independent of PATH, - # but it turns out we can't easily determine that from inspecting - # libtool variables, so we have to hard-code the OSs to which it - # applies here; at the moment, that means platforms that use the PE - # object format with DLL files. See the long comment at the top of - # tests/bindir.at for full details. - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) - # If a -bindir argument was supplied, place the dll there. - if test "x$bindir" != x ; - then - func_relative_path "$install_libdir" "$bindir" - tdlname=$func_relative_path_result$dlname - else - # Otherwise fall back on heuristic. - tdlname=../bin/$dlname - fi - ;; - esac - $ECHO > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# Please DO NOT delete this file! -# It is necessary for linking the library. - -# The name that we can dlopen(3). -dlname='$tdlname' - -# Names of this library. -library_names='$library_names' - -# The name of the static archive. -old_library='$old_library' - -# Linker flags that can not go in dependency_libs. -inherited_linker_flags='$new_inherited_linker_flags' - -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' - -# Names of additional weak libraries provided by this library -weak_library_names='$weak_libs' - -# Version information for $libname. -current=$current -age=$age -revision=$revision - -# Is this an already installed library? -installed=$installed - -# Should we warn about portability when linking against -modules? -shouldnotlink=$module - -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' - -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test "$installed" = no && test "$need_relink" = yes; then - $ECHO >> $output "\ -relink_command=\"$relink_command\"" - fi - done - } - - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' - ;; - esac - exit $EXIT_SUCCESS -} - -{ test "$opt_mode" = link || test "$opt_mode" = relink; } && - func_mode_link ${1+"$@"} - - -# func_mode_uninstall arg... -func_mode_uninstall () -{ - $opt_debug - RM="$nonopt" - files= - rmforce= - exit_status=0 - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - for arg - do - case $arg in - -f) func_append RM " $arg"; rmforce=yes ;; - -*) func_append RM " $arg" ;; - *) func_append files " $arg" ;; - esac - done - - test -z "$RM" && \ - func_fatal_help "you must specify an RM program" - - rmdirs= - - for file in $files; do - func_dirname "$file" "" "." - dir="$func_dirname_result" - if test "X$dir" = X.; then - odir="$objdir" - else - odir="$dir/$objdir" - fi - func_basename "$file" - name="$func_basename_result" - test "$opt_mode" = uninstall && odir="$dir" - - # Remember odir for removal later, being careful to avoid duplicates - if test "$opt_mode" = clean; then - case " $rmdirs " in - *" $odir "*) ;; - *) func_append rmdirs " $odir" ;; - esac - fi - - # Don't error if the file doesn't exist and rm -f was used. - if { test -L "$file"; } >/dev/null 2>&1 || - { test -h "$file"; } >/dev/null 2>&1 || - test -f "$file"; then - : - elif test -d "$file"; then - exit_status=1 - continue - elif test "$rmforce" = yes; then - continue - fi - - rmfiles="$file" - - case $name in - *.la) - # Possibly a libtool archive, so verify it. - if func_lalib_p "$file"; then - func_source $dir/$name - - # Delete the libtool libraries and symlinks. - for n in $library_names; do - func_append rmfiles " $odir/$n" - done - test -n "$old_library" && func_append rmfiles " $odir/$old_library" - - case "$opt_mode" in - clean) - case " $library_names " in - *" $dlname "*) ;; - *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; - esac - test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" - ;; - uninstall) - if test -n "$library_names"; then - # Do each command in the postuninstall commands. - func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - - if test -n "$old_library"; then - # Do each command in the old_postuninstall commands. - func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - # FIXME: should reinstall the best remaining shared library. - ;; - esac - fi - ;; - - *.lo) - # Possibly a libtool object, so verify it. - if func_lalib_p "$file"; then - - # Read the .lo file - func_source $dir/$name - - # Add PIC object to the list of files to remove. - if test -n "$pic_object" && - test "$pic_object" != none; then - func_append rmfiles " $dir/$pic_object" - fi - - # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" && - test "$non_pic_object" != none; then - func_append rmfiles " $dir/$non_pic_object" - fi - fi - ;; - - *) - if test "$opt_mode" = clean ; then - noexename=$name - case $file in - *.exe) - func_stripname '' '.exe' "$file" - file=$func_stripname_result - func_stripname '' '.exe' "$name" - noexename=$func_stripname_result - # $file with .exe has already been added to rmfiles, - # add $file without .exe - func_append rmfiles " $file" - ;; - esac - # Do a test to see if this is a libtool program. - if func_ltwrapper_p "$file"; then - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - relink_command= - func_source $func_ltwrapper_scriptname_result - func_append rmfiles " $func_ltwrapper_scriptname_result" - else - relink_command= - func_source $dir/$noexename - fi - - # note $name still contains .exe if it was in $file originally - # as does the version of $file that was added into $rmfiles - func_append rmfiles " $odir/$name $odir/${name}S.${objext}" - if test "$fast_install" = yes && test -n "$relink_command"; then - func_append rmfiles " $odir/lt-$name" - fi - if test "X$noexename" != "X$name" ; then - func_append rmfiles " $odir/lt-${noexename}.c" - fi - fi - fi - ;; - esac - func_show_eval "$RM $rmfiles" 'exit_status=1' - done - - # Try to remove the ${objdir}s in the directories where we deleted files - for dir in $rmdirs; do - if test -d "$dir"; then - func_show_eval "rmdir $dir >/dev/null 2>&1" - fi - done - - exit $exit_status -} - -{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && - func_mode_uninstall ${1+"$@"} - -test -z "$opt_mode" && { - help="$generic_help" - func_fatal_help "you must specify a MODE" -} - -test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode \`$opt_mode'" - -if test -n "$exec_cmd"; then - eval exec "$exec_cmd" - exit $EXIT_FAILURE -fi - -exit $exit_status - - -# The TAGs below are defined such that we never get into a situation -# in which we disable both kinds of libraries. Given conflicting -# choices, we go for a static library, that is the most portable, -# since we can't tell whether shared libraries were disabled because -# the user asked for that or because the platform doesn't support -# them. This is particularly important on AIX, because we don't -# support having both static and shared libraries enabled at the same -# time on that platform, so we default to a shared-only configuration. -# If a disable-shared tag is given, we'll fallback to a static-only -# configuration. But we'll never go from static-only to shared-only. - -# ### BEGIN LIBTOOL TAG CONFIG: disable-shared -build_libtool_libs=no -build_old_libs=yes -# ### END LIBTOOL TAG CONFIG: disable-shared - -# ### BEGIN LIBTOOL TAG CONFIG: disable-static -build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` -# ### END LIBTOOL TAG CONFIG: disable-static - -# Local Variables: -# mode:shell-script -# sh-indentation:2 -# End: -# vi:sw=2 - diff --git a/lib-src/libid3tag/m4/libtool.m4 b/lib-src/libid3tag/m4/libtool.m4 deleted file mode 100644 index d7c043f4f..000000000 --- a/lib-src/libid3tag/m4/libtool.m4 +++ /dev/null @@ -1,7997 +0,0 @@ -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -m4_define([_LT_COPYING], [dnl -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -]) - -# serial 57 LT_INIT - - -# LT_PREREQ(VERSION) -# ------------------ -# Complain and exit if this libtool version is less that VERSION. -m4_defun([LT_PREREQ], -[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, - [m4_default([$3], - [m4_fatal([Libtool version $1 or higher is required], - 63)])], - [$2])]) - - -# _LT_CHECK_BUILDDIR -# ------------------ -# Complain if the absolute build directory name contains unusual characters -m4_defun([_LT_CHECK_BUILDDIR], -[case `pwd` in - *\ * | *\ *) - AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; -esac -]) - - -# LT_INIT([OPTIONS]) -# ------------------ -AC_DEFUN([LT_INIT], -[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT -AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl -AC_BEFORE([$0], [LT_LANG])dnl -AC_BEFORE([$0], [LT_OUTPUT])dnl -AC_BEFORE([$0], [LTDL_INIT])dnl -m4_require([_LT_CHECK_BUILDDIR])dnl - -dnl Autoconf doesn't catch unexpanded LT_ macros by default: -m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl -m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl -dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 -dnl unless we require an AC_DEFUNed macro: -AC_REQUIRE([LTOPTIONS_VERSION])dnl -AC_REQUIRE([LTSUGAR_VERSION])dnl -AC_REQUIRE([LTVERSION_VERSION])dnl -AC_REQUIRE([LTOBSOLETE_VERSION])dnl -m4_require([_LT_PROG_LTMAIN])dnl - -_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) - -dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -_LT_SETUP - -# Only expand once: -m4_define([LT_INIT]) -])# LT_INIT - -# Old names: -AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) -AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PROG_LIBTOOL], []) -dnl AC_DEFUN([AM_PROG_LIBTOOL], []) - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -m4_defun([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` -]) - - -# _LT_FILEUTILS_DEFAULTS -# ---------------------- -# It is okay to use these file commands and assume they have been set -# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. -m4_defun([_LT_FILEUTILS_DEFAULTS], -[: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} -])# _LT_FILEUTILS_DEFAULTS - - -# _LT_SETUP -# --------- -m4_defun([_LT_SETUP], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl - -_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl -dnl -_LT_DECL([], [host_alias], [0], [The host system])dnl -_LT_DECL([], [host], [0])dnl -_LT_DECL([], [host_os], [0])dnl -dnl -_LT_DECL([], [build_alias], [0], [The build system])dnl -_LT_DECL([], [build], [0])dnl -_LT_DECL([], [build_os], [0])dnl -dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -dnl -AC_REQUIRE([AC_PROG_LN_S])dnl -test -z "$LN_S" && LN_S="ln -s" -_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl -dnl -AC_REQUIRE([LT_CMD_MAX_LEN])dnl -_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl -_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl -dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl -m4_require([_LT_CMD_RELOAD])dnl -m4_require([_LT_CHECK_MAGIC_METHOD])dnl -m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl -m4_require([_LT_CMD_OLD_ARCHIVE])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_WITH_SYSROOT])dnl - -_LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi -]) -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - -_LT_CHECK_OBJDIR - -m4_require([_LT_TAG_COMPILER])dnl - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - _LT_PATH_MAGIC - fi - ;; -esac - -# Use C for the default configuration in the libtool script -LT_SUPPORTED_TAG([CC]) -_LT_LANG_C_CONFIG -_LT_LANG_DEFAULT_CONFIG -_LT_CONFIG_COMMANDS -])# _LT_SETUP - - -# _LT_PREPARE_SED_QUOTE_VARS -# -------------------------- -# Define a few sed substitution that help us do robust quoting. -m4_defun([_LT_PREPARE_SED_QUOTE_VARS], -[# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([["`\\]]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' -]) - -# _LT_PROG_LTMAIN -# --------------- -# Note that this code is called both from `configure', and `config.status' -# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# `config.status' has no value for ac_aux_dir unless we are using Automake, -# so we pass a copy along to make sure it has a sensible value anyway. -m4_defun([_LT_PROG_LTMAIN], -[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl -_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain="$ac_aux_dir/ltmain.sh" -])# _LT_PROG_LTMAIN - - -## ------------------------------------- ## -## Accumulate code for creating libtool. ## -## ------------------------------------- ## - -# So that we can recreate a full libtool script including additional -# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the `libtool' -# label. - - -# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) -# ---------------------------------------- -# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL_INIT], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_INIT], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_INIT]) - - -# _LT_CONFIG_LIBTOOL([COMMANDS]) -# ------------------------------ -# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) - - -# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) -# ----------------------------------------------------- -m4_defun([_LT_CONFIG_SAVE_COMMANDS], -[_LT_CONFIG_LIBTOOL([$1]) -_LT_CONFIG_LIBTOOL_INIT([$2]) -]) - - -# _LT_FORMAT_COMMENT([COMMENT]) -# ----------------------------- -# Add leading comment marks to the start of each line, and a trailing -# full-stop to the whole comment if one is not present already. -m4_define([_LT_FORMAT_COMMENT], -[m4_ifval([$1], [ -m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], - [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) -)]) - - - -## ------------------------ ## -## FIXME: Eliminate VARNAME ## -## ------------------------ ## - - -# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) -# ------------------------------------------------------------------- -# CONFIGNAME is the name given to the value in the libtool script. -# VARNAME is the (base) name used in the configure script. -# VALUE may be 0, 1 or 2 for a computed quote escaped value based on -# VARNAME. Any other value will be used directly. -m4_define([_LT_DECL], -[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], - [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], - [m4_ifval([$1], [$1], [$2])]) - lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) - m4_ifval([$4], - [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) - lt_dict_add_subkey([lt_decl_dict], [$2], - [tagged?], [m4_ifval([$5], [yes], [no])])]) -]) - - -# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) -# -------------------------------------------------------- -m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) - - -# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_tag_varnames], -[_lt_decl_filter([tagged?], [yes], $@)]) - - -# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) -# --------------------------------------------------------- -m4_define([_lt_decl_filter], -[m4_case([$#], - [0], [m4_fatal([$0: too few arguments: $#])], - [1], [m4_fatal([$0: too few arguments: $#: $1])], - [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], - [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], - [lt_dict_filter([lt_decl_dict], $@)])[]dnl -]) - - -# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) -# -------------------------------------------------- -m4_define([lt_decl_quote_varnames], -[_lt_decl_filter([value], [1], $@)]) - - -# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_dquote_varnames], -[_lt_decl_filter([value], [2], $@)]) - - -# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_varnames_tagged], -[m4_assert([$# <= 2])dnl -_$0(m4_quote(m4_default([$1], [[, ]])), - m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), - m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) -m4_define([_lt_decl_varnames_tagged], -[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) - - -# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_all_varnames], -[_$0(m4_quote(m4_default([$1], [[, ]])), - m4_if([$2], [], - m4_quote(lt_decl_varnames), - m4_quote(m4_shift($@))))[]dnl -]) -m4_define([_lt_decl_all_varnames], -[lt_join($@, lt_decl_varnames_tagged([$1], - lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl -]) - - -# _LT_CONFIG_STATUS_DECLARE([VARNAME]) -# ------------------------------------ -# Quote a variable value, and forward it to `config.status' so that its -# declaration there will have the same value as in `configure'. VARNAME -# must have a single quote delimited value for this to work. -m4_define([_LT_CONFIG_STATUS_DECLARE], -[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) - - -# _LT_CONFIG_STATUS_DECLARATIONS -# ------------------------------ -# We delimit libtool config variables with single quotes, so when -# we write them to config.status, we have to be sure to quote all -# embedded single quotes properly. In configure, this macro expands -# each variable declared with _LT_DECL (and _LT_TAGDECL) into: -# -# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' -m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], -[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), - [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAGS -# ---------------- -# Output comment and list of tags supported by the script -m4_defun([_LT_LIBTOOL_TAGS], -[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags="_LT_TAGS"dnl -]) - - -# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) -# ----------------------------------- -# Extract the dictionary values for VARNAME (optionally with TAG) and -# expand to a commented shell variable setting: -# -# # Some comment about what VAR is for. -# visible_name=$lt_internal_name -m4_define([_LT_LIBTOOL_DECLARE], -[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], - [description])))[]dnl -m4_pushdef([_libtool_name], - m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl -m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), - [0], [_libtool_name=[$]$1], - [1], [_libtool_name=$lt_[]$1], - [2], [_libtool_name=$lt_[]$1], - [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl -m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl -]) - - -# _LT_LIBTOOL_CONFIG_VARS -# ----------------------- -# Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' -# script. Tagged libtool config variables (even for the LIBTOOL CONFIG -# section) are produced by _LT_LIBTOOL_TAG_VARS. -m4_defun([_LT_LIBTOOL_CONFIG_VARS], -[m4_foreach([_lt_var], - m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAG_VARS(TAG) -# ------------------------- -m4_define([_LT_LIBTOOL_TAG_VARS], -[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) - - -# _LT_TAGVAR(VARNAME, [TAGNAME]) -# ------------------------------ -m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) - - -# _LT_CONFIG_COMMANDS -# ------------------- -# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of -# variables for single and double quote escaping we saved from calls -# to _LT_DECL, we can put quote escaped variables declarations -# into `config.status', and then the shell code to quote escape them in -# for loops in `config.status'. Finally, any additional code accumulated -# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. -m4_defun([_LT_CONFIG_COMMANDS], -[AC_PROVIDE_IFELSE([LT_OUTPUT], - dnl If the libtool generation code has been placed in $CONFIG_LT, - dnl instead of duplicating it all over again into config.status, - dnl then we will have config.status run $CONFIG_LT later, so it - dnl needs to know what name is stored there: - [AC_CONFIG_COMMANDS([libtool], - [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], - dnl If the libtool generation code is destined for config.status, - dnl expand the accumulated commands and init code now: - [AC_CONFIG_COMMANDS([libtool], - [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) -])#_LT_CONFIG_COMMANDS - - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], -[ - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -_LT_CONFIG_STATUS_DECLARATIONS -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$[]1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_quote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_dquote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -_LT_OUTPUT_LIBTOOL_INIT -]) - -# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) -# ------------------------------------ -# Generate a child script FILE with all initialization necessary to -# reuse the environment learned by the parent script, and make the -# file executable. If COMMENT is supplied, it is inserted after the -# `#!' sequence but before initialization text begins. After this -# macro, additional text can be appended to FILE to form the body of -# the child script. The macro ends with non-zero status if the -# file could not be fully written (such as if the disk is full). -m4_ifdef([AS_INIT_GENERATED], -[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], -[m4_defun([_LT_GENERATED_FILE_INIT], -[m4_require([AS_PREPARE])]dnl -[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl -[lt_write_fail=0 -cat >$1 <<_ASEOF || lt_write_fail=1 -#! $SHELL -# Generated by $as_me. -$2 -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$1 <<\_ASEOF || lt_write_fail=1 -AS_SHELL_SANITIZE -_AS_PREPARE -exec AS_MESSAGE_FD>&1 -_ASEOF -test $lt_write_fail = 0 && chmod +x $1[]dnl -m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT - -# LT_OUTPUT -# --------- -# This macro allows early generation of the libtool script (before -# AC_OUTPUT is called), incase it is used in configure for compilation -# tests. -AC_DEFUN([LT_OUTPUT], -[: ${CONFIG_LT=./config.lt} -AC_MSG_NOTICE([creating $CONFIG_LT]) -_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], -[# Run this file to recreate a libtool stub with the current configuration.]) - -cat >>"$CONFIG_LT" <<\_LTEOF -lt_cl_silent=false -exec AS_MESSAGE_LOG_FD>>config.log -{ - echo - AS_BOX([Running $as_me.]) -} >&AS_MESSAGE_LOG_FD - -lt_cl_help="\ -\`$as_me' creates a local libtool stub from the current configuration, -for use in further configure time tests before the real libtool is -generated. - -Usage: $[0] [[OPTIONS]] - - -h, --help print this help, then exit - -V, --version print version number, then exit - -q, --quiet do not print progress messages - -d, --debug don't remove temporary files - -Report bugs to ." - -lt_cl_version="\ -m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl -m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) -configured by $[0], generated by m4_PACKAGE_STRING. - -Copyright (C) 2011 Free Software Foundation, Inc. -This config.lt script is free software; the Free Software Foundation -gives unlimited permision to copy, distribute and modify it." - -while test $[#] != 0 -do - case $[1] in - --version | --v* | -V ) - echo "$lt_cl_version"; exit 0 ;; - --help | --h* | -h ) - echo "$lt_cl_help"; exit 0 ;; - --debug | --d* | -d ) - debug=: ;; - --quiet | --q* | --silent | --s* | -q ) - lt_cl_silent=: ;; - - -*) AC_MSG_ERROR([unrecognized option: $[1] -Try \`$[0] --help' for more information.]) ;; - - *) AC_MSG_ERROR([unrecognized argument: $[1] -Try \`$[0] --help' for more information.]) ;; - esac - shift -done - -if $lt_cl_silent; then - exec AS_MESSAGE_FD>/dev/null -fi -_LTEOF - -cat >>"$CONFIG_LT" <<_LTEOF -_LT_OUTPUT_LIBTOOL_COMMANDS_INIT -_LTEOF - -cat >>"$CONFIG_LT" <<\_LTEOF -AC_MSG_NOTICE([creating $ofile]) -_LT_OUTPUT_LIBTOOL_COMMANDS -AS_EXIT(0) -_LTEOF -chmod +x "$CONFIG_LT" - -# configure is writing to config.log, but config.lt does its own redirection, -# appending to config.log, which fails on DOS, as config.log is still kept -# open by configure. Here we exec the FD to /dev/null, effectively closing -# config.log, so it can be properly (re)opened and appended to by config.lt. -lt_cl_success=: -test "$silent" = yes && - lt_config_lt_args="$lt_config_lt_args --quiet" -exec AS_MESSAGE_LOG_FD>/dev/null -$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false -exec AS_MESSAGE_LOG_FD>>config.log -$lt_cl_success || AS_EXIT(1) -])# LT_OUTPUT - - -# _LT_CONFIG(TAG) -# --------------- -# If TAG is the built-in tag, create an initial libtool script with a -# default configuration from the untagged config vars. Otherwise add code -# to config.status for appending the configuration named by TAG from the -# matching tagged config vars. -m4_defun([_LT_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_CONFIG_SAVE_COMMANDS([ - m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl - m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -_LT_COPYING -_LT_LIBTOOL_TAGS - -# ### BEGIN LIBTOOL CONFIG -_LT_LIBTOOL_CONFIG_VARS -_LT_LIBTOOL_TAG_VARS -# ### END LIBTOOL CONFIG - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - _LT_PROG_LTMAIN - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - _LT_PROG_REPLACE_SHELLFNS - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -], -[cat <<_LT_EOF >> "$ofile" - -dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded -dnl in a comment (ie after a #). -# ### BEGIN LIBTOOL TAG CONFIG: $1 -_LT_LIBTOOL_TAG_VARS(_LT_TAG) -# ### END LIBTOOL TAG CONFIG: $1 -_LT_EOF -])dnl /m4_if -], -[m4_if([$1], [], [ - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile'], []) -])dnl /_LT_CONFIG_SAVE_COMMANDS -])# _LT_CONFIG - - -# LT_SUPPORTED_TAG(TAG) -# --------------------- -# Trace this macro to discover what tags are supported by the libtool -# --tag option, using: -# autoconf --trace 'LT_SUPPORTED_TAG:$1' -AC_DEFUN([LT_SUPPORTED_TAG], []) - - -# C support is built-in for now -m4_define([_LT_LANG_C_enabled], []) -m4_define([_LT_TAGS], []) - - -# LT_LANG(LANG) -# ------------- -# Enable libtool support for the given language if not already enabled. -AC_DEFUN([LT_LANG], -[AC_BEFORE([$0], [LT_OUTPUT])dnl -m4_case([$1], - [C], [_LT_LANG(C)], - [C++], [_LT_LANG(CXX)], - [Go], [_LT_LANG(GO)], - [Java], [_LT_LANG(GCJ)], - [Fortran 77], [_LT_LANG(F77)], - [Fortran], [_LT_LANG(FC)], - [Windows Resource], [_LT_LANG(RC)], - [m4_ifdef([_LT_LANG_]$1[_CONFIG], - [_LT_LANG($1)], - [m4_fatal([$0: unsupported language: "$1"])])])dnl -])# LT_LANG - - -# _LT_LANG(LANGNAME) -# ------------------ -m4_defun([_LT_LANG], -[m4_ifdef([_LT_LANG_]$1[_enabled], [], - [LT_SUPPORTED_TAG([$1])dnl - m4_append([_LT_TAGS], [$1 ])dnl - m4_define([_LT_LANG_]$1[_enabled], [])dnl - _LT_LANG_$1_CONFIG($1)])dnl -])# _LT_LANG - - -m4_ifndef([AC_PROG_GO], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_GO. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ -m4_defun([AC_PROG_GO], -[AC_LANG_PUSH(Go)dnl -AC_ARG_VAR([GOC], [Go compiler command])dnl -AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl -_AC_ARG_VAR_LDFLAGS()dnl -AC_CHECK_TOOL(GOC, gccgo) -if test -z "$GOC"; then - if test -n "$ac_tool_prefix"; then - AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) - fi -fi -if test -z "$GOC"; then - AC_CHECK_PROG(GOC, gccgo, gccgo, false) -fi -])#m4_defun -])#m4_ifndef - - -# _LT_LANG_DEFAULT_CONFIG -# ----------------------- -m4_defun([_LT_LANG_DEFAULT_CONFIG], -[AC_PROVIDE_IFELSE([AC_PROG_CXX], - [LT_LANG(CXX)], - [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) - -AC_PROVIDE_IFELSE([AC_PROG_F77], - [LT_LANG(F77)], - [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) - -AC_PROVIDE_IFELSE([AC_PROG_FC], - [LT_LANG(FC)], - [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) - -dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal -dnl pulling things in needlessly. -AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([LT_PROG_GCJ], - [LT_LANG(GCJ)], - [m4_ifdef([AC_PROG_GCJ], - [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([A][M_PROG_GCJ], - [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([LT_PROG_GCJ], - [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) - -AC_PROVIDE_IFELSE([AC_PROG_GO], - [LT_LANG(GO)], - [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) - -AC_PROVIDE_IFELSE([LT_PROG_RC], - [LT_LANG(RC)], - [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) -])# _LT_LANG_DEFAULT_CONFIG - -# Obsolete macros: -AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) -AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) -AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) -AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) -AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_CXX], []) -dnl AC_DEFUN([AC_LIBTOOL_F77], []) -dnl AC_DEFUN([AC_LIBTOOL_FC], []) -dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) -dnl AC_DEFUN([AC_LIBTOOL_RC], []) - - -# _LT_TAG_COMPILER -# ---------------- -m4_defun([_LT_TAG_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl -_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl -_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl -_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_TAG_COMPILER - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -m4_defun([_LT_COMPILER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -m4_defun([_LT_LINKER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* -])# _LT_LINKER_BOILERPLATE - -# _LT_REQUIRED_DARWIN_CHECKS -# ------------------------- -m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ - case $host_os in - rhapsody* | darwin*) - AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) - AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) - AC_CHECK_TOOL([LIPO], [lipo], [:]) - AC_CHECK_TOOL([OTOOL], [otool], [:]) - AC_CHECK_TOOL([OTOOL64], [otool64], [:]) - _LT_DECL([], [DSYMUTIL], [1], - [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) - _LT_DECL([], [NMEDIT], [1], - [Tool to change global to local symbols on Mac OS X]) - _LT_DECL([], [LIPO], [1], - [Tool to manipulate fat objects and archives on Mac OS X]) - _LT_DECL([], [OTOOL], [1], - [ldd/readelf like tool for Mach-O binaries on Mac OS X]) - _LT_DECL([], [OTOOL64], [1], - [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) - - AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], - [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi]) - - AC_CACHE_CHECK([for -exported_symbols_list linker flag], - [lt_cv_ld_exported_symbols_list], - [lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [lt_cv_ld_exported_symbols_list=yes], - [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" - ]) - - AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], - [lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD - echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD - $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - ]) - case $host_os in - rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac -]) - - -# _LT_DARWIN_LINKER_FEATURES([TAG]) -# --------------------------------- -# Checks for linker and compiler features on darwin -m4_defun([_LT_DARWIN_LINKER_FEATURES], -[ - m4_require([_LT_REQUIRED_DARWIN_CHECKS]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_automatic, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - _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\"`' - m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], - [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='' - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - _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}" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _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}" - _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}" - m4_if([$1], [CXX], -[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _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}" - _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}" - fi -],[]) - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi -]) - -# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) -# ---------------------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -# Store the results from the different compilers for each TAGNAME. -# Allow to override them for all tags through lt_cv_aix_libpath. -m4_defun([_LT_SYS_MODULE_PATH_AIX], -[m4_require([_LT_DECL_SED])dnl -if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], - [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ - lt_aix_libpath_sed='[ - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }]' - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi],[]) - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" - fi - ]) - aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) -fi -])# _LT_SYS_MODULE_PATH_AIX - - -# _LT_SHELL_INIT(ARG) -# ------------------- -m4_define([_LT_SHELL_INIT], -[m4_divert_text([M4SH-INIT], [$1 -])])# _LT_SHELL_INIT - - - -# _LT_PROG_ECHO_BACKSLASH -# ----------------------- -# Find how we can fake an echo command that does not interpret backslash. -# In particular, with Autoconf 2.60 or later we add some code to the start -# of the generated configure script which will find a shell with a builtin -# printf (which we can use as an echo command). -m4_defun([_LT_PROG_ECHO_BACKSLASH], -[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -AC_MSG_CHECKING([how to print strings]) -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$[]1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -case "$ECHO" in - printf*) AC_MSG_RESULT([printf]) ;; - print*) AC_MSG_RESULT([print -r]) ;; - *) AC_MSG_RESULT([cat]) ;; -esac - -m4_ifdef([_AS_DETECT_SUGGESTED], -[_AS_DETECT_SUGGESTED([ - test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test "X`printf %s $ECHO`" = "X$ECHO" \ - || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) - -_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) -_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) -])# _LT_PROG_ECHO_BACKSLASH - - -# _LT_WITH_SYSROOT -# ---------------- -AC_DEFUN([_LT_WITH_SYSROOT], -[AC_MSG_CHECKING([for sysroot]) -AC_ARG_WITH([sysroot], -[ --with-sysroot[=DIR] Search for dependent libraries within DIR - (or the compiler's sysroot if not specified).], -[], [with_sysroot=no]) - -dnl lt_sysroot will always be passed unquoted. We quote it here -dnl in case the user passed a directory name. -lt_sysroot= -case ${with_sysroot} in #( - yes) - if test "$GCC" = yes; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - AC_MSG_RESULT([${with_sysroot}]) - AC_MSG_ERROR([The sysroot must be an absolute path.]) - ;; -esac - - AC_MSG_RESULT([${lt_sysroot:-no}]) -_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl -[dependent libraries, and in which our libraries should be installed.])]) - -# _LT_ENABLE_LOCK -# --------------- -m4_defun([_LT_ENABLE_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" -])# _LT_ENABLE_LOCK - - -# _LT_PROG_AR -# ----------- -m4_defun([_LT_PROG_AR], -[AC_CHECK_TOOLS(AR, [ar], false) -: ${AR=ar} -: ${AR_FLAGS=cru} -_LT_DECL([], [AR], [1], [The archiver]) -_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) - -AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], - [lt_cv_ar_at_file=no - AC_COMPILE_IFELSE([AC_LANG_PROGRAM], - [echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' - AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -eq 0; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -ne 0; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - ]) - ]) - -if test "x$lt_cv_ar_at_file" = xno; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi -_LT_DECL([], [archiver_list_spec], [1], - [How to feed a file listing to the archiver]) -])# _LT_PROG_AR - - -# _LT_CMD_OLD_ARCHIVE -# ------------------- -m4_defun([_LT_CMD_OLD_ARCHIVE], -[_LT_PROG_AR - -AC_CHECK_TOOL(STRIP, strip, :) -test -z "$STRIP" && STRIP=: -_LT_DECL([], [STRIP], [1], [A symbol stripping program]) - -AC_CHECK_TOOL(RANLIB, ranlib, :) -test -z "$RANLIB" && RANLIB=: -_LT_DECL([], [RANLIB], [1], - [Commands used to install an old-style archive]) - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac -_LT_DECL([], [old_postinstall_cmds], [2]) -_LT_DECL([], [old_postuninstall_cmds], [2]) -_LT_TAGDECL([], [old_archive_cmds], [2], - [Commands used to build an old-style archive]) -_LT_DECL([], [lock_old_archive_extraction], [0], - [Whether to use a lock for old archive extraction]) -])# _LT_CMD_OLD_ARCHIVE - - -# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([_LT_COMPILER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $RM conftest* -]) - -if test x"[$]$2" = xyes; then - m4_if([$5], , :, [$5]) -else - m4_if([$6], , :, [$6]) -fi -])# _LT_COMPILER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) - - -# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------- -# Check whether the given linker option works -AC_DEFUN([_LT_LINKER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - m4_if([$4], , :, [$4]) -else - m4_if([$5], , :, [$5]) -fi -])# _LT_LINKER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) - - -# LT_CMD_MAX_LEN -#--------------- -AC_DEFUN([LT_CMD_MAX_LEN], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -max_cmd_len=$lt_cv_sys_max_cmd_len -_LT_DECL([], [max_cmd_len], [0], - [What is the maximum length of a command?]) -])# LT_CMD_MAX_LEN - -# Old name: -AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) - - -# _LT_HEADER_DLFCN -# ---------------- -m4_defun([_LT_HEADER_DLFCN], -[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl -])# _LT_HEADER_DLFCN - - -# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ---------------------------------------------------------------- -m4_defun([_LT_TRY_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -[#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -}] -_LT_EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_dlunknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_TRY_DLOPEN_SELF - - -# LT_SYS_DLOPEN_SELF -# ------------------ -AC_DEFUN([LT_SYS_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -_LT_DECL([dlopen_support], [enable_dlopen], [0], - [Whether dlopen is supported]) -_LT_DECL([dlopen_self], [enable_dlopen_self], [0], - [Whether dlopen of programs is supported]) -_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], - [Whether dlopen of statically linked programs is supported]) -])# LT_SYS_DLOPEN_SELF - -# Old name: -AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) - - -# _LT_COMPILER_C_O([TAGNAME]) -# --------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler. -# This macro does not hard code the compiler like AC_PROG_CC_C_O. -m4_defun([_LT_COMPILER_C_O], -[m4_require([_LT_DECL_SED])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* -]) -_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], - [Does compiler simultaneously support -c and -o options?]) -])# _LT_COMPILER_C_O - - -# _LT_COMPILER_FILE_LOCKS([TAGNAME]) -# ---------------------------------- -# Check to see if we can do hard links to lock some files if needed -m4_defun([_LT_COMPILER_FILE_LOCKS], -[m4_require([_LT_ENABLE_LOCK])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_COMPILER_C_O([$1]) - -hard_links="nottested" -if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) -])# _LT_COMPILER_FILE_LOCKS - - -# _LT_CHECK_OBJDIR -# ---------------- -m4_defun([_LT_CHECK_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -_LT_DECL([], [objdir], [0], - [The name of the directory that contains temporary libtool files])dnl -m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", - [Define to the sub-directory in which libtool stores uninstalled libraries.]) -])# _LT_CHECK_OBJDIR - - -# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) -# -------------------------------------- -# Check hardcoding attributes. -m4_defun([_LT_LINKER_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || - test -n "$_LT_TAGVAR(runpath_var, $1)" || - test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) - -if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || - test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -_LT_TAGDECL([], [hardcode_action], [0], - [How to hardcode a shared library path into an executable]) -])# _LT_LINKER_HARDCODE_LIBPATH - - -# _LT_CMD_STRIPLIB -# ---------------- -m4_defun([_LT_CMD_STRIPLIB], -[m4_require([_LT_DECL_EGREP]) -striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) -_LT_DECL([], [striplib], [1]) -])# _LT_CMD_STRIPLIB - - -# _LT_SYS_DYNAMIC_LINKER([TAG]) -# ----------------------------- -# PORTME Fill in your ld.so characteristics -m4_defun([_LT_SYS_DYNAMIC_LINKER], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_OBJDUMP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -AC_MSG_CHECKING([dynamic linker characteristics]) -m4_if([$1], - [], [ -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[[lt_foo]]++; } - if (lt_freq[[lt_foo]] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[[4-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[23]].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ - freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[[3-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], - [lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ - LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], - [lt_cv_shlibpath_overrides_runpath=yes])]) - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - ]) - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - -_LT_DECL([], [variables_saved_for_relink], [1], - [Variables whose values should be saved in libtool wrapper scripts and - restored at link time]) -_LT_DECL([], [need_lib_prefix], [0], - [Do we need the "lib" prefix for modules?]) -_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) -_LT_DECL([], [version_type], [0], [Library versioning type]) -_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) -_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) -_LT_DECL([], [shlibpath_overrides_runpath], [0], - [Is shlibpath searched before the hard-coded library search path?]) -_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) -_LT_DECL([], [library_names_spec], [1], - [[List of archive names. First name is the real one, the rest are links. - The last name is the one that the linker finds with -lNAME]]) -_LT_DECL([], [soname_spec], [1], - [[The coded name of the library, if different from the real name]]) -_LT_DECL([], [install_override_mode], [1], - [Permission mode override for installation of shared libraries]) -_LT_DECL([], [postinstall_cmds], [2], - [Command to use after installation of a shared archive]) -_LT_DECL([], [postuninstall_cmds], [2], - [Command to use after uninstallation of a shared archive]) -_LT_DECL([], [finish_cmds], [2], - [Commands used to finish a libtool library installation in a directory]) -_LT_DECL([], [finish_eval], [1], - [[As "finish_cmds", except a single script fragment to be evaled but - not shown]]) -_LT_DECL([], [hardcode_into_libs], [0], - [Whether we should hardcode library paths into libraries]) -_LT_DECL([], [sys_lib_search_path_spec], [2], - [Compile-time system search path for libraries]) -_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], - [Run-time system search path for libraries]) -])# _LT_SYS_DYNAMIC_LINKER - - -# _LT_PATH_TOOL_PREFIX(TOOL) -# -------------------------- -# find a file program which can recognize shared library -AC_DEFUN([_LT_PATH_TOOL_PREFIX], -[m4_require([_LT_DECL_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="m4_if([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -_LT_DECL([], [MAGIC_CMD], [0], - [Used to examine libraries when file_magic_cmd begins with "file"])dnl -])# _LT_PATH_TOOL_PREFIX - -# Old name: -AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) - - -# _LT_PATH_MAGIC -# -------------- -# find a file program which can recognize a shared library -m4_defun([_LT_PATH_MAGIC], -[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# _LT_PATH_MAGIC - - -# LT_PATH_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([LT_PATH_LD], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PROG_ECHO_BACKSLASH])dnl - -AC_ARG_WITH([gnu-ld], - [AS_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no])dnl - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [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]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[[3-9]]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - 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]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - -_LT_DECL([], [deplibs_check_method], [1], - [Method to check whether dependent libraries are shared objects]) -_LT_DECL([], [file_magic_cmd], [1], - [Command to use when deplibs_check_method = "file_magic"]) -_LT_DECL([], [file_magic_glob], [1], - [How to find potential files when deplibs_check_method = "file_magic"]) -_LT_DECL([], [want_nocaseglob], [1], - [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) -])# _LT_CHECK_MAGIC_METHOD - - -# LT_PATH_NM -# ---------- -# find the pathname to a BSD- or MS-compatible name lister -AC_DEFUN([LT_PATH_NM], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi]) -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols" - ;; - *) - DUMPBIN=: - ;; - esac - fi - AC_SUBST([DUMPBIN]) - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm -AC_SUBST([NM]) -_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl - -AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], - [lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) - cat conftest.out >&AS_MESSAGE_LOG_FD - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest*]) -])# LT_PATH_NM - -# Old names: -AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) -AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_PROG_NM], []) -dnl AC_DEFUN([AC_PROG_NM], []) - -# _LT_CHECK_SHAREDLIB_FROM_LINKLIB -# -------------------------------- -# how to determine the name of the shared library -# associated with a specific link library. -# -- PORTME fill in with the dynamic library characteristics -m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], -[m4_require([_LT_DECL_EGREP]) -m4_require([_LT_DECL_OBJDUMP]) -m4_require([_LT_DECL_DLLTOOL]) -AC_CACHE_CHECK([how to associate runtime and link libraries], -lt_cv_sharedlib_from_linklib_cmd, -[lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" - ;; -esac -]) -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - -_LT_DECL([], [sharedlib_from_linklib_cmd], [1], - [Command to associate shared and link libraries]) -])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB - - -# _LT_PATH_MANIFEST_TOOL -# ---------------------- -# locate the manifest tool -m4_defun([_LT_PATH_MANIFEST_TOOL], -[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], - [lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&AS_MESSAGE_LOG_FD - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest*]) -if test "x$lt_cv_path_mainfest_tool" != xyes; then - MANIFEST_TOOL=: -fi -_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl -])# _LT_PATH_MANIFEST_TOOL - - -# LT_LIB_M -# -------- -# check for math library -AC_DEFUN([LT_LIB_M], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -AC_SUBST([LIBM]) -])# LT_LIB_M - -# Old name: -AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_CHECK_LIBM], []) - - -# _LT_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------- -m4_defun([_LT_COMPILER_NO_RTTI], -[m4_require([_LT_TAG_COMPILER])dnl - -_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test "$GCC" = yes; then - case $cc_basename in - nvcc*) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; - *) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; - esac - - _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], - [Compiler flag to turn off builtin functions]) -])# _LT_COMPILER_NO_RTTI - - -# _LT_CMD_GLOBAL_SYMBOLS -# ---------------------- -m4_defun([_LT_CMD_GLOBAL_SYMBOLS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([LT_PATH_NM])dnl -AC_REQUIRE([LT_PATH_LD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_TAG_COMPILER])dnl - -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris*) - symcode='[[BDRT]]' - ;; -sco3.2v5*) - symcode='[[DT]]' - ;; -sysv4.2uw2*) - symcode='[[DT]]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[[ABDT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" -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'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK ['"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx]" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT@&t@_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT@&t@_DLSYM_CONST -#else -# define LT@&t@_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT@&t@_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[[]] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - -_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], - [Take the output of nm and produce a listing of raw symbols and C names]) -_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], - [Transform the output of nm in a proper C declaration]) -_LT_DECL([global_symbol_to_c_name_address], - [lt_cv_sys_global_symbol_to_c_name_address], [1], - [Transform the output of nm in a C name address pair]) -_LT_DECL([global_symbol_to_c_name_address_lib_prefix], - [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], - [Transform the output of nm in a C name address pair when lib prefix is needed]) -_LT_DECL([], [nm_file_list_spec], [1], - [Specify filename containing input files for $NM]) -]) # _LT_CMD_GLOBAL_SYMBOLS - - -# _LT_COMPILER_PIC([TAGNAME]) -# --------------------------- -m4_defun([_LT_COMPILER_PIC], -[m4_require([_LT_TAG_COMPILER])dnl -_LT_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_TAGVAR(lt_prog_compiler_static, $1)= - -m4_if([$1], [CXX], [ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix[[4-9]]*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _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" - ;; - esac - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) - # IBM XL 8.0, 9.0 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd* | netbsdelf*-gnu) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' - if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - hpux9* | hpux10* | hpux11*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' - _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' - ;; - nagfor*) - # NAG Fortran compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='' - ;; - *Sun\ F* | *Sun*Fortran*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - *Intel*\ [[CF]]*Compiler*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - *Portland\ Group*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - rdos*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - solaris*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - unicos*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" - ;; -esac - -AC_CACHE_CHECK([for $compiler option to produce PIC], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) -_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], - [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], - [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], - [Additional compiler flags for building library objects]) - -_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], - [How to pass a linker flag through the compiler]) -# -# Check to make sure the static flag actually works. -# -wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" -_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], - _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), - $lt_tmp_static_flag, - [], - [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) -_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], - [Compiler flag to prevent dynamic linking]) -])# _LT_COMPILER_PIC - - -# _LT_LINKER_SHLIBS([TAGNAME]) -# ---------------------------- -# See if the linker supports building shared libraries. -m4_defun([_LT_LINKER_SHLIBS], -[AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -m4_if([$1], [CXX], [ - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - case $host_os in - aix[[4-9]]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global defined - # symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _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' - else - _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' - fi - ;; - pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw* | cegcc*) - case $cc_basename in - cl*) - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - ;; - *) - _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' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - ;; - esac - ;; - linux* | k*bsd*-gnu | gnu*) - _LT_TAGVAR(link_all_deplibs, $1)=no - ;; - *) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -], [ - runpath_var= - _LT_TAGVAR(allow_undefined_flag, $1)= - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(archive_cmds, $1)= - _LT_TAGVAR(archive_expsym_cmds, $1)= - _LT_TAGVAR(compiler_needs_object, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(hardcode_automatic, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(hardcode_libdir_separator, $1)= - _LT_TAGVAR(hardcode_minus_L, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_TAGVAR(inherit_rpath, $1)=no - _LT_TAGVAR(link_all_deplibs, $1)=unknown - _LT_TAGVAR(module_cmds, $1)= - _LT_TAGVAR(module_expsym_cmds, $1)= - _LT_TAGVAR(old_archive_from_new_cmds, $1)= - _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_TAGVAR(thread_safe_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. -dnl Note also adjust exclude_expsyms for C++ above. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - linux* | k*bsd*-gnu | gnu*) - _LT_TAGVAR(link_all_deplibs, $1)=no - ;; - esac - - _LT_TAGVAR(ld_shlibs, $1)=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; - *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test "$lt_use_gnu_ld_interface" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[[3-9]]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _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)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _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' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _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' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _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' - _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' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _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' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - _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' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - _LT_TAGVAR(whole_archive_flag_spec, $1)= - tmp_sharedflag='--shared' ;; - xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - sunos4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _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' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _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' - else - _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' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - _LT_TAGVAR(link_all_deplibs, $1)=no - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _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" - else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _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' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _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)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - bsdi[[45]]*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl*) - # Native MSVC - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - _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' - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC wrapper - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - esac - ;; - - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test "$GCC" = yes; then - _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' - else - _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' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - m4_if($1, [], [ - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - _LT_LINKER_OPTION([if $CC understands -b], - _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], - [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) - ;; - esac - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _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' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], - [lt_cv_irix_exported_symbol], - [save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - AC_LINK_IFELSE( - [AC_LANG_SOURCE( - [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], - [C++], [[int foo (void) { return 0; }]], - [Fortran 77], [[ - subroutine foo - end]], - [Fortran], [[ - subroutine foo - end]])])], - [lt_cv_irix_exported_symbol=yes], - [lt_cv_irix_exported_symbol=no]) - LDFLAGS="$save_LDFLAGS"]) - if test "$lt_cv_irix_exported_symbol" = yes; then - _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' - fi - else - _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' - _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' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *nto* | *qnx*) - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _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' - _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - _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~ - $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' - - # Both c and cxx compiler support -rpath directly - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - solaris*) - _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - fi - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_TAGVAR(ld_shlibs, $1)=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' - ;; - esac - fi - fi -]) -AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld - -_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl -_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl -_LT_DECL([], [extract_expsyms_cmds], [2], - [The commands to extract the exported symbol list from a shared archive]) - -# -# Do we need to explicitly link libc? -# -case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_CACHE_CHECK([whether -lc should be explicitly linked in], - [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), - [$RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) - pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) - _LT_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) - then - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no - else - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - ]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) - ;; - esac - fi - ;; -esac - -_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], - [Whether or not to add -lc for building shared libraries]) -_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], - [enable_shared_with_static_runtimes], [0], - [Whether or not to disallow shared libs when runtime libs are static]) -_LT_TAGDECL([], [export_dynamic_flag_spec], [1], - [Compiler flag to allow reflexive dlopens]) -_LT_TAGDECL([], [whole_archive_flag_spec], [1], - [Compiler flag to generate shared objects directly from archives]) -_LT_TAGDECL([], [compiler_needs_object], [1], - [Whether the compiler copes with passing no objects directly]) -_LT_TAGDECL([], [old_archive_from_new_cmds], [2], - [Create an old-style archive from a shared archive]) -_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], - [Create a temporary old-style archive to link instead of a shared archive]) -_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) -_LT_TAGDECL([], [archive_expsym_cmds], [2]) -_LT_TAGDECL([], [module_cmds], [2], - [Commands used to build a loadable module if different from building - a shared archive.]) -_LT_TAGDECL([], [module_expsym_cmds], [2]) -_LT_TAGDECL([], [with_gnu_ld], [1], - [Whether we are building with GNU ld or not]) -_LT_TAGDECL([], [allow_undefined_flag], [1], - [Flag that allows shared libraries with undefined symbols to be built]) -_LT_TAGDECL([], [no_undefined_flag], [1], - [Flag that enforces no undefined symbols]) -_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], - [Flag to hardcode $libdir into a binary during linking. - This must work even if $libdir does not exist]) -_LT_TAGDECL([], [hardcode_libdir_separator], [1], - [Whether we need a single "-rpath" flag with a separated argument]) -_LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary]) -_LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting ${shlibpath_var} if the - library is relocated]) -_LT_TAGDECL([], [hardcode_minus_L], [0], - [Set to "yes" if using the -LDIR flag during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_shlibpath_var], [0], - [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_automatic], [0], - [Set to "yes" if building a shared library automatically hardcodes DIR - into the library and all subsequent libraries and executables linked - against it]) -_LT_TAGDECL([], [inherit_rpath], [0], - [Set to yes if linker adds runtime paths of dependent libraries - to runtime path list]) -_LT_TAGDECL([], [link_all_deplibs], [0], - [Whether libtool must link a program against all its dependency libraries]) -_LT_TAGDECL([], [always_export_symbols], [0], - [Set to "yes" if exported symbols are required]) -_LT_TAGDECL([], [export_symbols_cmds], [2], - [The commands to list exported symbols]) -_LT_TAGDECL([], [exclude_expsyms], [1], - [Symbols that should not be listed in the preloaded symbols]) -_LT_TAGDECL([], [include_expsyms], [1], - [Symbols that must always be exported]) -_LT_TAGDECL([], [prelink_cmds], [2], - [Commands necessary for linking programs (against libraries) with templates]) -_LT_TAGDECL([], [postlink_cmds], [2], - [Commands necessary for finishing linking programs]) -_LT_TAGDECL([], [file_list_spec], [1], - [Specify filename containing input files]) -dnl FIXME: Not yet implemented -dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], -dnl [Compiler flag to generate thread safe objects]) -])# _LT_LINKER_SHLIBS - - -# _LT_LANG_C_CONFIG([TAG]) -# ------------------------ -# Ensure that the configuration variables for a C compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_C_CONFIG], -[m4_require([_LT_DECL_EGREP])dnl -lt_save_CC="$CC" -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - -_LT_TAG_COMPILER -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - LT_SYS_DLOPEN_SELF - _LT_CMD_STRIPLIB - - # Report which library types will actually be built - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_CONFIG($1) -fi -AC_LANG_POP -CC="$lt_save_CC" -])# _LT_LANG_C_CONFIG - - -# _LT_LANG_CXX_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a C++ compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_CXX_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -else - _lt_caught_CXX_error=yes -fi - -AC_LANG_PUSH(C++) -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(compiler_needs_object, $1)=no -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_CFLAGS=$CFLAGS - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - CFLAGS=$CXXFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - else - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - fi - - if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - LT_PATH_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) - _LT_TAGVAR(ld_shlibs, $1)=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty - # executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _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" - else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - _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' - fi - fi - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - case $GXX,$cc_basename in - ,cl* | no,cl*) - # Native MSVC - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # g++ - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _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' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $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' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - freebsd2.*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - freebsd-elf*) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - - freebsd* | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - _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' - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _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' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _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' - ;; - *) - _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' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _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' - _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' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _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' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _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' - else - _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' - fi - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _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' - _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' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - ;; - esac - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) - _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' - _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' - _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $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' - ;; - *) # Version 6 and above use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _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' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _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' - ;; - cxx*) - # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _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' - - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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' - ;; - xl* | mpixl* | bgxl*) - # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _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' - _LT_TAGVAR(compiler_needs_object, $1)=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - esac - ;; - - lynxos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - m88k*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - - *nto* | *qnx*) - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - openbsd2*) - # C++ shared libraries are fairly broken - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _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' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd=func_echo_all - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - case $host in - osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _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' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - ;; - *) - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _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' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $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~ - $RM $lib.exp' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - 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"' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - case $host in - osf3*) - _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' - ;; - *) - _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' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _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' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - fi - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ - '"$_LT_TAGVAR(old_archive_cmds, $1)" - _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ - '"$_LT_TAGVAR(reload_cmds, $1)" - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - - _LT_TAGVAR(GCC, $1)="$GXX" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes - -AC_LANG_POP -])# _LT_LANG_CXX_CONFIG - - -# _LT_FUNC_STRIPNAME_CNF -# ---------------------- -# func_stripname_cnf prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# -# This function is identical to the (non-XSI) version of func_stripname, -# except this one can be used by m4 code that may be executed by configure, -# rather than the libtool script. -m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl -AC_REQUIRE([_LT_DECL_SED]) -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) -func_stripname_cnf () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname_cnf -])# _LT_FUNC_STRIPNAME_CNF - -# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) -# --------------------------------- -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -m4_defun([_LT_SYS_HIDDEN_LIBDEPS], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl -# Dependencies to place before and after the object being linked: -_LT_TAGVAR(predep_objects, $1)= -_LT_TAGVAR(postdep_objects, $1)= -_LT_TAGVAR(predeps, $1)= -_LT_TAGVAR(postdeps, $1)= -_LT_TAGVAR(compiler_lib_search_path, $1)= - -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF -int a; -void foo (void) { a = 0; } -_LT_EOF -], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -_LT_EOF -], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer*4 a - a=0 - return - end -_LT_EOF -], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer a - a=0 - return - end -_LT_EOF -], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF -public class foo { - private int a; - public void bar (void) { - a = 0; - } -}; -_LT_EOF -], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF -package foo -func foo() { -} -_LT_EOF -]) - -_lt_libdeps_save_CFLAGS=$CFLAGS -case "$CC $CFLAGS " in #( -*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; -*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; -*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; -esac - -dnl Parse the compiler output and extract the necessary -dnl objects, libraries and library flags. -if AC_TRY_EVAL(ac_compile); then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - for p in `eval "$output_verbose_link_cmd"`; do - case ${prev}${p} in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test $p = "-L" || - test $p = "-R"; then - prev=$p - continue - fi - - # Expand the sysroot to ease extracting the directories later. - if test -z "$prev"; then - case $p in - -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; - -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; - -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; - esac - fi - case $p in - =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; - esac - if test "$pre_test_object_deps_done" = no; then - case ${prev} in - -L | -R) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" - else - _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$_LT_TAGVAR(postdeps, $1)"; then - _LT_TAGVAR(postdeps, $1)="${prev}${p}" - else - _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" - fi - fi - prev= - ;; - - *.lto.$objext) ;; # Ignore GCC LTO objects - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test "$pre_test_object_deps_done" = no; then - if test -z "$_LT_TAGVAR(predep_objects, $1)"; then - _LT_TAGVAR(predep_objects, $1)="$p" - else - _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" - fi - else - if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then - _LT_TAGVAR(postdep_objects, $1)="$p" - else - _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling $1 test program" -fi - -$RM -f confest.$objext -CFLAGS=$_lt_libdeps_save_CFLAGS - -# PORTME: override above test on systems where it is broken -m4_if([$1], [CXX], -[case $host_os in -interix[[3-9]]*) - # Interix 3.5 installs completely hosed .la files for C++, so rather than - # hack all around it, let's just trust "g++" to DTRT. - _LT_TAGVAR(predep_objects,$1)= - _LT_TAGVAR(postdep_objects,$1)= - _LT_TAGVAR(postdeps,$1)= - ;; - -linux*) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; - -solaris*) - case $cc_basename in - CC* | sunCC*) - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - # Adding this requires a known-good setup of shared libraries for - # Sun compiler versions before 5.6, else PIC objects from an old - # archive will be linked into the output, leading to subtle bugs. - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; -esac -]) - -case " $_LT_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; -esac - _LT_TAGVAR(compiler_lib_search_dirs, $1)= -if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` -fi -_LT_TAGDECL([], [compiler_lib_search_dirs], [1], - [The directories searched by this compiler when creating a shared library]) -_LT_TAGDECL([], [predep_objects], [1], - [Dependencies to place before and after the objects being linked to - create a shared library]) -_LT_TAGDECL([], [postdep_objects], [1]) -_LT_TAGDECL([], [predeps], [1]) -_LT_TAGDECL([], [postdeps], [1]) -_LT_TAGDECL([], [compiler_lib_search_path], [1], - [The library search path used internally by the compiler when linking - a shared library]) -])# _LT_SYS_HIDDEN_LIBDEPS - - -# _LT_LANG_F77_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a Fortran 77 compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_F77_CONFIG], -[AC_LANG_PUSH(Fortran 77) -if test -z "$F77" || test "X$F77" = "Xno"; then - _lt_disable_F77=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the F77 compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_F77" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${F77-"f77"} - CFLAGS=$FFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - GCC=$G77 - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$G77" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC="$lt_save_CC" - CFLAGS="$lt_save_CFLAGS" -fi # test "$_lt_disable_F77" != yes - -AC_LANG_POP -])# _LT_LANG_F77_CONFIG - - -# _LT_LANG_FC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for a Fortran compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_FC_CONFIG], -[AC_LANG_PUSH(Fortran) - -if test -z "$FC" || test "X$FC" = "Xno"; then - _lt_disable_FC=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for fc test sources. -ac_ext=${ac_fc_srcext-f} - -# Object file extension for compiled fc test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the FC compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_FC" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${FC-"f95"} - CFLAGS=$FCFLAGS - compiler=$CC - GCC=$ac_cv_fc_compiler_gnu - - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS -fi # test "$_lt_disable_FC" != yes - -AC_LANG_POP -])# _LT_LANG_FC_CONFIG - - -# _LT_LANG_GCJ_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Java Compiler compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_GCJ_CONFIG], -[AC_REQUIRE([LT_PROG_GCJ])dnl -AC_LANG_SAVE - -# Source file extension for Java test sources. -ac_ext=java - -# Object file extension for compiled Java test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}" - -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GCJ-"gcj"} -CFLAGS=$GCJFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" -_LT_CC_BASENAME([$compiler]) - -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GCJ_CONFIG - - -# _LT_LANG_GO_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Go compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_GO_CONFIG], -[AC_REQUIRE([LT_PROG_GO])dnl -AC_LANG_SAVE - -# Source file extension for Go test sources. -ac_ext=go - -# Object file extension for compiled Go test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="package main; func main() { }" - -# Code to be used in simple link tests -lt_simple_link_test_code='package main; func main() { }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GOC-"gccgo"} -CFLAGS=$GOFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" -_LT_CC_BASENAME([$compiler]) - -# Go did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GO_CONFIG - - -# _LT_LANG_RC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for the Windows resource compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_RC_CONFIG], -[AC_REQUIRE([LT_PROG_RC])dnl -AC_LANG_SAVE - -# Source file extension for RC test sources. -ac_ext=rc - -# Object file extension for compiled RC test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' - -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC= -CC=${RC-"windres"} -CFLAGS= -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) -_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -if test -n "$compiler"; then - : - _LT_CONFIG($1) -fi - -GCC=$lt_save_GCC -AC_LANG_RESTORE -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_RC_CONFIG - - -# LT_PROG_GCJ -# ----------- -AC_DEFUN([LT_PROG_GCJ], -[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], - [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], - [AC_CHECK_TOOL(GCJ, gcj,) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS)])])[]dnl -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_GCJ], []) - - -# LT_PROG_GO -# ---------- -AC_DEFUN([LT_PROG_GO], -[AC_CHECK_TOOL(GOC, gccgo,) -]) - - -# LT_PROG_RC -# ---------- -AC_DEFUN([LT_PROG_RC], -[AC_CHECK_TOOL(RC, windres,) -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_RC], []) - - -# _LT_DECL_EGREP -# -------------- -# If we don't have a new enough Autoconf to choose the best grep -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_EGREP], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_REQUIRE([AC_PROG_FGREP])dnl -test -z "$GREP" && GREP=grep -_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) -_LT_DECL([], [EGREP], [1], [An ERE matcher]) -_LT_DECL([], [FGREP], [1], [A literal string matcher]) -dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too -AC_SUBST([GREP]) -]) - - -# _LT_DECL_OBJDUMP -# -------------- -# If we don't have a new enough Autoconf to choose the best objdump -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_OBJDUMP], -[AC_CHECK_TOOL(OBJDUMP, objdump, false) -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) -AC_SUBST([OBJDUMP]) -]) - -# _LT_DECL_DLLTOOL -# ---------------- -# Ensure DLLTOOL variable is set. -m4_defun([_LT_DECL_DLLTOOL], -[AC_CHECK_TOOL(DLLTOOL, dlltool, false) -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) -AC_SUBST([DLLTOOL]) -]) - -# _LT_DECL_SED -# ------------ -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -m4_defun([_LT_DECL_SED], -[AC_PROG_SED -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" -_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) -_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], - [Sed that helps us avoid accidentally triggering echo(1) options like -n]) -])# _LT_DECL_SED - -m4_ifndef([AC_PROG_SED], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ - -m4_defun([AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -])#AC_PROG_SED -])#m4_ifndef - -# Old name: -AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_SED], []) - - -# _LT_CHECK_SHELL_FEATURES -# ------------------------ -# Find out whether the shell is Bourne or XSI compatible, -# or has some other useful features. -m4_defun([_LT_CHECK_SHELL_FEATURES], -[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -AC_MSG_RESULT([$xsi_shell]) -_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) - -AC_MSG_CHECKING([whether the shell understands "+="]) -lt_shell_append=no -( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -AC_MSG_RESULT([$lt_shell_append]) -_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi -_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac -_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl -_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl -])# _LT_CHECK_SHELL_FEATURES - - -# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) -# ------------------------------------------------------ -# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and -# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. -m4_defun([_LT_PROG_FUNCTION_REPLACE], -[dnl { -sed -e '/^$1 ()$/,/^} # $1 /c\ -$1 ()\ -{\ -m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) -} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: -]) - - -# _LT_PROG_REPLACE_SHELLFNS -# ------------------------- -# Replace existing portable implementations of several shell functions with -# equivalent extended shell implementations where those features are available.. -m4_defun([_LT_PROG_REPLACE_SHELLFNS], -[if test x"$xsi_shell" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl - func_split_long_opt_name=${1%%=*} - func_split_long_opt_arg=${1#*=}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl - func_split_short_opt_arg=${1#??} - func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) - - _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) - - _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) - - _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) -fi - -if test x"$lt_shell_append" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) - - _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl - func_quote_for_eval "${2}" -dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ - eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) -fi -]) - -# _LT_PATH_CONVERSION_FUNCTIONS -# ----------------------------- -# Determine which file name conversion functions should be used by -# func_to_host_file (and, implicitly, by func_to_host_path). These are needed -# for certain cross-compile configurations and native mingw. -m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_MSG_CHECKING([how to convert $build file names to $host format]) -AC_CACHE_VAL(lt_cv_to_host_file_cmd, -[case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac -]) -to_host_file_cmd=$lt_cv_to_host_file_cmd -AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) -_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], - [0], [convert $build file names to $host format])dnl - -AC_MSG_CHECKING([how to convert $build file names to toolchain format]) -AC_CACHE_VAL(lt_cv_to_tool_file_cmd, -[#assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac -]) -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) -_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], - [0], [convert $build files to toolchain format])dnl -])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/lib-src/libid3tag/m4/ltoptions.m4 b/lib-src/libid3tag/m4/ltoptions.m4 deleted file mode 100644 index 5d9acd8e2..000000000 --- a/lib-src/libid3tag/m4/ltoptions.m4 +++ /dev/null @@ -1,384 +0,0 @@ -# Helper functions for option handling. -*- Autoconf -*- -# -# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 7 ltoptions.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) - - -# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) -# ------------------------------------------ -m4_define([_LT_MANGLE_OPTION], -[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) - - -# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) -# --------------------------------------- -# Set option OPTION-NAME for macro MACRO-NAME, and if there is a -# matching handler defined, dispatch to it. Other OPTION-NAMEs are -# saved as a flag. -m4_define([_LT_SET_OPTION], -[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl -m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), - _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option `$2'])])[]dnl -]) - - -# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) -# ------------------------------------------------------------ -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -m4_define([_LT_IF_OPTION], -[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) - - -# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) -# ------------------------------------------------------- -# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME -# are set. -m4_define([_LT_UNLESS_OPTIONS], -[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), - [m4_define([$0_found])])])[]dnl -m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 -])[]dnl -]) - - -# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) -# ---------------------------------------- -# OPTION-LIST is a space-separated list of Libtool options associated -# with MACRO-NAME. If any OPTION has a matching handler declared with -# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about -# the unknown option and exit. -m4_defun([_LT_SET_OPTIONS], -[# Set options -m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [_LT_SET_OPTION([$1], _LT_Option)]) - -m4_if([$1],[LT_INIT],[ - dnl - dnl Simply set some default values (i.e off) if boolean options were not - dnl specified: - _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no - ]) - _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no - ]) - dnl - dnl If no reference was made to various pairs of opposing options, then - dnl we run the default mode handler for the pair. For example, if neither - dnl `shared' nor `disable-shared' was passed, we enable building of shared - dnl archives by default: - _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) - _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) - ]) -])# _LT_SET_OPTIONS - - -## --------------------------------- ## -## Macros to handle LT_INIT options. ## -## --------------------------------- ## - -# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) -# ----------------------------------------- -m4_define([_LT_MANGLE_DEFUN], -[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) - - -# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) -# ----------------------------------------------- -m4_define([LT_OPTION_DEFINE], -[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl -])# LT_OPTION_DEFINE - - -# dlopen -# ------ -LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes -]) - -AU_DEFUN([AC_LIBTOOL_DLOPEN], -[_LT_SET_OPTION([LT_INIT], [dlopen]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) - - -# win32-dll -# --------- -# Declare package support for building win32 dll's. -LT_OPTION_DEFINE([LT_INIT], [win32-dll], -[enable_win32_dll=yes - -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; -esac - -test -z "$AS" && AS=as -_LT_DECL([], [AS], [1], [Assembler program])dnl - -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl - -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl -])# win32-dll - -AU_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -_LT_SET_OPTION([LT_INIT], [win32-dll]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `win32-dll' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) - - -# _LT_ENABLE_SHARED([DEFAULT]) -# ---------------------------- -# implement the --enable-shared flag, and supports the `shared' and -# `disable-shared' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_SHARED], -[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) - - _LT_DECL([build_libtool_libs], [enable_shared], [0], - [Whether or not to build shared libraries]) -])# _LT_ENABLE_SHARED - -LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) -]) - -AC_DEFUN([AC_DISABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], [disable-shared]) -]) - -AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_SHARED], []) -dnl AC_DEFUN([AM_DISABLE_SHARED], []) - - - -# _LT_ENABLE_STATIC([DEFAULT]) -# ---------------------------- -# implement the --enable-static flag, and support the `static' and -# `disable-static' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_STATIC], -[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([static], - [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_static=]_LT_ENABLE_STATIC_DEFAULT) - - _LT_DECL([build_old_libs], [enable_static], [0], - [Whether or not to build static libraries]) -])# _LT_ENABLE_STATIC - -LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) -]) - -AC_DEFUN([AC_DISABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], [disable-static]) -]) - -AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_STATIC], []) -dnl AC_DEFUN([AM_DISABLE_STATIC], []) - - - -# _LT_ENABLE_FAST_INSTALL([DEFAULT]) -# ---------------------------------- -# implement the --enable-fast-install flag, and support the `fast-install' -# and `disable-fast-install' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_FAST_INSTALL], -[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([fast-install], - [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) - -_LT_DECL([fast_install], [enable_fast_install], [0], - [Whether or not to optimize for fast installation])dnl -])# _LT_ENABLE_FAST_INSTALL - -LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) - -# Old names: -AU_DEFUN([AC_ENABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `fast-install' option into LT_INIT's first parameter.]) -]) - -AU_DEFUN([AC_DISABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `disable-fast-install' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) -dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) - - -# _LT_WITH_PIC([MODE]) -# -------------------- -# implement the --with-pic flag, and support the `pic-only' and `no-pic' -# LT_INIT options. -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -m4_define([_LT_WITH_PIC], -[AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for lt_pkg in $withval; do - IFS="$lt_save_ifs" - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [pic_mode=default]) - -test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) - -_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl -])# _LT_WITH_PIC - -LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) - -# Old name: -AU_DEFUN([AC_LIBTOOL_PICMODE], -[_LT_SET_OPTION([LT_INIT], [pic-only]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `pic-only' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) - -## ----------------- ## -## LTDL_INIT Options ## -## ----------------- ## - -m4_define([_LTDL_MODE], []) -LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], - [m4_define([_LTDL_MODE], [nonrecursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [recursive], - [m4_define([_LTDL_MODE], [recursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [subproject], - [m4_define([_LTDL_MODE], [subproject])]) - -m4_define([_LTDL_TYPE], []) -LT_OPTION_DEFINE([LTDL_INIT], [installable], - [m4_define([_LTDL_TYPE], [installable])]) -LT_OPTION_DEFINE([LTDL_INIT], [convenience], - [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/lib-src/libid3tag/m4/ltsugar.m4 b/lib-src/libid3tag/m4/ltsugar.m4 deleted file mode 100644 index 9000a057d..000000000 --- a/lib-src/libid3tag/m4/ltsugar.m4 +++ /dev/null @@ -1,123 +0,0 @@ -# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 6 ltsugar.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) - - -# lt_join(SEP, ARG1, [ARG2...]) -# ----------------------------- -# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their -# associated separator. -# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier -# versions in m4sugar had bugs. -m4_define([lt_join], -[m4_if([$#], [1], [], - [$#], [2], [[$2]], - [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) -m4_define([_lt_join], -[m4_if([$#$2], [2], [], - [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) - - -# lt_car(LIST) -# lt_cdr(LIST) -# ------------ -# Manipulate m4 lists. -# These macros are necessary as long as will still need to support -# Autoconf-2.59 which quotes differently. -m4_define([lt_car], [[$1]]) -m4_define([lt_cdr], -[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], - [$#], 1, [], - [m4_dquote(m4_shift($@))])]) -m4_define([lt_unquote], $1) - - -# lt_append(MACRO-NAME, STRING, [SEPARATOR]) -# ------------------------------------------ -# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. -# Note that neither SEPARATOR nor STRING are expanded; they are appended -# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). -# No SEPARATOR is output if MACRO-NAME was previously undefined (different -# than defined and empty). -# -# This macro is needed until we can rely on Autoconf 2.62, since earlier -# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. -m4_define([lt_append], -[m4_define([$1], - m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) - - - -# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) -# ---------------------------------------------------------- -# Produce a SEP delimited list of all paired combinations of elements of -# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list -# has the form PREFIXmINFIXSUFFIXn. -# Needed until we can rely on m4_combine added in Autoconf 2.62. -m4_define([lt_combine], -[m4_if(m4_eval([$# > 3]), [1], - [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl -[[m4_foreach([_Lt_prefix], [$2], - [m4_foreach([_Lt_suffix], - ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, - [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) - - -# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) -# ----------------------------------------------------------------------- -# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited -# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. -m4_define([lt_if_append_uniq], -[m4_ifdef([$1], - [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], - [lt_append([$1], [$2], [$3])$4], - [$5])], - [lt_append([$1], [$2], [$3])$4])]) - - -# lt_dict_add(DICT, KEY, VALUE) -# ----------------------------- -m4_define([lt_dict_add], -[m4_define([$1($2)], [$3])]) - - -# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) -# -------------------------------------------- -m4_define([lt_dict_add_subkey], -[m4_define([$1($2:$3)], [$4])]) - - -# lt_dict_fetch(DICT, KEY, [SUBKEY]) -# ---------------------------------- -m4_define([lt_dict_fetch], -[m4_ifval([$3], - m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), - m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) - - -# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) -# ----------------------------------------------------------------- -m4_define([lt_if_dict_fetch], -[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], - [$5], - [$6])]) - - -# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) -# -------------------------------------------------------------- -m4_define([lt_dict_filter], -[m4_if([$5], [], [], - [lt_join(m4_quote(m4_default([$4], [[, ]])), - lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), - [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl -]) diff --git a/lib-src/libid3tag/m4/ltversion.m4 b/lib-src/libid3tag/m4/ltversion.m4 deleted file mode 100644 index 07a8602d4..000000000 --- a/lib-src/libid3tag/m4/ltversion.m4 +++ /dev/null @@ -1,23 +0,0 @@ -# ltversion.m4 -- version numbers -*- Autoconf -*- -# -# Copyright (C) 2004 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# @configure_input@ - -# serial 3337 ltversion.m4 -# This file is part of GNU Libtool - -m4_define([LT_PACKAGE_VERSION], [2.4.2]) -m4_define([LT_PACKAGE_REVISION], [1.3337]) - -AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.2' -macro_revision='1.3337' -_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) -_LT_DECL(, macro_revision, 0) -]) diff --git a/lib-src/libid3tag/m4/lt~obsolete.m4 b/lib-src/libid3tag/m4/lt~obsolete.m4 deleted file mode 100644 index c573da90c..000000000 --- a/lib-src/libid3tag/m4/lt~obsolete.m4 +++ /dev/null @@ -1,98 +0,0 @@ -# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004. -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 5 lt~obsolete.m4 - -# These exist entirely to fool aclocal when bootstrapping libtool. -# -# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) -# which have later been changed to m4_define as they aren't part of the -# exported API, or moved to Autoconf or Automake where they belong. -# -# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN -# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us -# using a macro with the same name in our local m4/libtool.m4 it'll -# pull the old libtool.m4 in (it doesn't see our shiny new m4_define -# and doesn't know about Autoconf macros at all.) -# -# So we provide this file, which has a silly filename so it's always -# included after everything else. This provides aclocal with the -# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything -# because those macros already exist, or will be overwritten later. -# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. -# -# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. -# Yes, that means every name once taken will need to remain here until -# we give up compatibility with versions before 1.7, at which point -# we need to keep only those names which we still refer to. - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) - -m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) -m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) -m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) -m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) -m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) -m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) -m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) -m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) -m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) -m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) -m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) -m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) -m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) -m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) -m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) -m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) -m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) -m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) -m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) -m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) -m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) -m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) -m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) -m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) -m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) -m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) -m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) -m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) -m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) -m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) -m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) -m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) -m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) -m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) -m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) -m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) -m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) -m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) -m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) -m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) -m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) -m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) -m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) -m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) -m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) -m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) -m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) -m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) -m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) -m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/lib-src/libid3tag/missing b/lib-src/libid3tag/missing deleted file mode 100755 index db98974ff..000000000 --- a/lib-src/libid3tag/missing +++ /dev/null @@ -1,215 +0,0 @@ -#! /bin/sh -# Common wrapper for a few potentially missing GNU programs. - -scriptversion=2013-10-28.13; # UTC - -# Copyright (C) 1996-2013 Free Software Foundation, Inc. -# Originally written by Fran,cois Pinard , 1996. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -if test $# -eq 0; then - echo 1>&2 "Try '$0 --help' for more information" - exit 1 -fi - -case $1 in - - --is-lightweight) - # Used by our autoconf macros to check whether the available missing - # script is modern enough. - exit 0 - ;; - - --run) - # Back-compat with the calling convention used by older automake. - shift - ;; - - -h|--h|--he|--hel|--help) - echo "\ -$0 [OPTION]... PROGRAM [ARGUMENT]... - -Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due -to PROGRAM being missing or too old. - -Options: - -h, --help display this help and exit - -v, --version output version information and exit - -Supported PROGRAM values: - aclocal autoconf autoheader autom4te automake makeinfo - bison yacc flex lex help2man - -Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and -'g' are ignored when checking the name. - -Send bug reports to ." - exit $? - ;; - - -v|--v|--ve|--ver|--vers|--versi|--versio|--version) - echo "missing $scriptversion (GNU Automake)" - exit $? - ;; - - -*) - echo 1>&2 "$0: unknown '$1' option" - echo 1>&2 "Try '$0 --help' for more information" - exit 1 - ;; - -esac - -# Run the given program, remember its exit status. -"$@"; st=$? - -# If it succeeded, we are done. -test $st -eq 0 && exit 0 - -# Also exit now if we it failed (or wasn't found), and '--version' was -# passed; such an option is passed most likely to detect whether the -# program is present and works. -case $2 in --version|--help) exit $st;; esac - -# Exit code 63 means version mismatch. This often happens when the user -# tries to use an ancient version of a tool on a file that requires a -# minimum version. -if test $st -eq 63; then - msg="probably too old" -elif test $st -eq 127; then - # Program was missing. - msg="missing on your system" -else - # Program was found and executed, but failed. Give up. - exit $st -fi - -perl_URL=http://www.perl.org/ -flex_URL=http://flex.sourceforge.net/ -gnu_software_URL=http://www.gnu.org/software - -program_details () -{ - case $1 in - aclocal|automake) - echo "The '$1' program is part of the GNU Automake package:" - echo "<$gnu_software_URL/automake>" - echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/autoconf>" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - autoconf|autom4te|autoheader) - echo "The '$1' program is part of the GNU Autoconf package:" - echo "<$gnu_software_URL/autoconf/>" - echo "It also requires GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - esac -} - -give_advice () -{ - # Normalize program name to check for. - normalized_program=`echo "$1" | sed ' - s/^gnu-//; t - s/^gnu//; t - s/^g//; t'` - - printf '%s\n' "'$1' is $msg." - - configure_deps="'configure.ac' or m4 files included by 'configure.ac'" - case $normalized_program in - autoconf*) - echo "You should only need it if you modified 'configure.ac'," - echo "or m4 files included by it." - program_details 'autoconf' - ;; - autoheader*) - echo "You should only need it if you modified 'acconfig.h' or" - echo "$configure_deps." - program_details 'autoheader' - ;; - automake*) - echo "You should only need it if you modified 'Makefile.am' or" - echo "$configure_deps." - program_details 'automake' - ;; - aclocal*) - echo "You should only need it if you modified 'acinclude.m4' or" - echo "$configure_deps." - program_details 'aclocal' - ;; - autom4te*) - echo "You might have modified some maintainer files that require" - echo "the 'autom4te' program to be rebuilt." - program_details 'autom4te' - ;; - bison*|yacc*) - echo "You should only need it if you modified a '.y' file." - echo "You may want to install the GNU Bison package:" - echo "<$gnu_software_URL/bison/>" - ;; - lex*|flex*) - echo "You should only need it if you modified a '.l' file." - echo "You may want to install the Fast Lexical Analyzer package:" - echo "<$flex_URL>" - ;; - help2man*) - echo "You should only need it if you modified a dependency" \ - "of a man page." - echo "You may want to install the GNU Help2man package:" - echo "<$gnu_software_URL/help2man/>" - ;; - makeinfo*) - echo "You should only need it if you modified a '.texi' file, or" - echo "any other file indirectly affecting the aspect of the manual." - echo "You might want to install the Texinfo package:" - echo "<$gnu_software_URL/texinfo/>" - echo "The spurious makeinfo call might also be the consequence of" - echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" - echo "want to install GNU make:" - echo "<$gnu_software_URL/make/>" - ;; - *) - echo "You might have modified some files without having the proper" - echo "tools for further handling them. Check the 'README' file, it" - echo "often tells you about the needed prerequisites for installing" - echo "this package. You may also peek at any GNU archive site, in" - echo "case some other package contains this missing '$1' program." - ;; - esac -} - -give_advice "$1" | sed -e '1s/^/WARNING: /' \ - -e '2,$s/^/ /' >&2 - -# Propagate the correct exit status (expected to be 127 for a program -# not found, 63 for a program that failed due to version mismatch). -exit $st - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libid3tag/mkinstalldirs b/lib-src/libid3tag/mkinstalldirs deleted file mode 100755 index 55d537f87..000000000 --- a/lib-src/libid3tag/mkinstalldirs +++ /dev/null @@ -1,162 +0,0 @@ -#! /bin/sh -# mkinstalldirs --- make directory hierarchy - -scriptversion=2009-04-28.21; # UTC - -# Original author: Noah Friedman -# Created: 1993-05-16 -# Public domain. -# -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -nl=' -' -IFS=" "" $nl" -errstatus=0 -dirmode= - -usage="\ -Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ... - -Create each directory DIR (with mode MODE, if specified), including all -leading file name components. - -Report bugs to ." - -# process command line arguments -while test $# -gt 0 ; do - case $1 in - -h | --help | --h*) # -h for help - echo "$usage" - exit $? - ;; - -m) # -m PERM arg - shift - test $# -eq 0 && { echo "$usage" 1>&2; exit 1; } - dirmode=$1 - shift - ;; - --version) - echo "$0 $scriptversion" - exit $? - ;; - --) # stop option processing - shift - break - ;; - -*) # unknown option - echo "$usage" 1>&2 - exit 1 - ;; - *) # first non-opt arg - break - ;; - esac -done - -for file -do - if test -d "$file"; then - shift - else - break - fi -done - -case $# in - 0) exit 0 ;; -esac - -# Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and -# mkdir -p a/c at the same time, both will detect that a is missing, -# one will create a, then the other will try to create a and die with -# a "File exists" error. This is a problem when calling mkinstalldirs -# from a parallel make. We use --version in the probe to restrict -# ourselves to GNU mkdir, which is thread-safe. -case $dirmode in - '') - if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then - echo "mkdir -p -- $*" - exec mkdir -p -- "$@" - else - # On NextStep and OpenStep, the 'mkdir' command does not - # recognize any option. It will interpret all options as - # directories to create, and then abort because '.' already - # exists. - test -d ./-p && rmdir ./-p - test -d ./--version && rmdir ./--version - fi - ;; - *) - if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 && - test ! -d ./--version; then - echo "mkdir -m $dirmode -p -- $*" - exec mkdir -m "$dirmode" -p -- "$@" - else - # Clean up after NextStep and OpenStep mkdir. - for d in ./-m ./-p ./--version "./$dirmode"; - do - test -d $d && rmdir $d - done - fi - ;; -esac - -for file -do - case $file in - /*) pathcomp=/ ;; - *) pathcomp= ;; - esac - oIFS=$IFS - IFS=/ - set fnord $file - shift - IFS=$oIFS - - for d - do - test "x$d" = x && continue - - pathcomp=$pathcomp$d - case $pathcomp in - -*) pathcomp=./$pathcomp ;; - esac - - if test ! -d "$pathcomp"; then - echo "mkdir $pathcomp" - - mkdir "$pathcomp" || lasterr=$? - - if test ! -d "$pathcomp"; then - errstatus=$lasterr - else - if test ! -z "$dirmode"; then - echo "chmod $dirmode $pathcomp" - lasterr= - chmod "$dirmode" "$pathcomp" || lasterr=$? - - if test ! -z "$lasterr"; then - errstatus=$lasterr - fi - fi - fi - fi - - pathcomp=$pathcomp/ - done -done - -exit $errstatus - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libid3tag/msvc++/Makefile.am b/lib-src/libid3tag/msvc++/Makefile.am deleted file mode 100644 index a0e8492bf..000000000 --- a/lib-src/libid3tag/msvc++/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -## -## libid3tag - ID3 tag manipulation library -## Copyright (C) 2000-2004 Underbit Technologies, Inc. -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License -## along with this program; if not, write to the Free Software -## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -## -## $Id: Makefile.am,v 1.1 2004-06-08 06:42:50 dmazzoni Exp $ -## - -## Process this file with automake to produce Makefile.in - -EXTRA_DIST = config.h libid3tag.dsp diff --git a/lib-src/libid3tag/msvc++/Makefile.in b/lib-src/libid3tag/msvc++/Makefile.in deleted file mode 100644 index 0c28ef3ce..000000000 --- a/lib-src/libid3tag/msvc++/Makefile.in +++ /dev/null @@ -1,425 +0,0 @@ -# Makefile.in generated by automake 1.14.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2013 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = msvc++ -DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ - $(top_srcdir)/mkinstalldirs -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ - $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ - $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -EXTRA_DIST = config.h libid3tag.dsp -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign msvc++/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign msvc++/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/libid3tag/msvc++/config.h b/lib-src/libid3tag/msvc++/config.h deleted file mode 100644 index 7b1330ff7..000000000 --- a/lib-src/libid3tag/msvc++/config.h +++ /dev/null @@ -1,78 +0,0 @@ -/* config.h. Generated by configure. */ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to enable diagnostic debugging support. */ -/* #undef DEBUG */ - -/* Define to 1 if you have the header file. */ -#define HAVE_ASSERT_H 1 - -/* Define to 1 if you have the header file. */ -/* #undef HAVE_DLFCN_H */ - -/* Define to 1 if you have the `ftruncate' function. */ -/* #undef HAVE_FTRUNCATE */ - -/* Define to 1 if you have the header file. */ -#define HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the `z' library (-lz). */ -#define HAVE_LIBZ 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_MEMORY_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRING_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have the header file. */ -/* #undef HAVE_UNISTD_H */ - -/* Define to disable debugging assertions. */ -/* #undef NDEBUG */ - -/* Name of package */ -#define PACKAGE "libid3tag" - -/* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "support@underbit.com" - -/* Define to the full name of this package. */ -#define PACKAGE_NAME "ID3 Tag" - -/* Define to the full name and version of this package. */ -#define PACKAGE_STRING "ID3 Tag 0.15.1b" - -/* Define to the one symbol short name of this package. */ -#define PACKAGE_TARNAME "libid3tag" - -/* Define to the version of this package. */ -#define PACKAGE_VERSION "0.15.1b" - -/* Define to 1 if you have the ANSI C header files. */ -#define STDC_HEADERS 1 - -/* Version number of package */ -#define VERSION "0.15.1b" - -/* Define to empty if `const' does not conform to ANSI C. */ -/* #undef const */ - -/* Define as `__inline' if that's what the C compiler calls it, or to nothing - if it is not supported. */ -/* #undef inline */ diff --git a/lib-src/libid3tag/msvc++/libid3tag.dsp b/lib-src/libid3tag/msvc++/libid3tag.dsp deleted file mode 100644 index 4ff87fc3c..000000000 --- a/lib-src/libid3tag/msvc++/libid3tag.dsp +++ /dev/null @@ -1,250 +0,0 @@ -# Microsoft Developer Studio Project File - Name="libid3tag" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Static Library" 0x0104 - -CFG=libid3tag - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "libid3tag.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "libid3tag.mak" CFG="libid3tag - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "libid3tag - Win32 Release" (based on "Win32 (x86) Static Library") -!MESSAGE "libid3tag - Win32 Debug" (based on "Win32 (x86) Static Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "libid3tag - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c -# ADD CPP /nologo /GX /O2 /I "." /I "..\..\libz" /I "..\..\libz-1.1.4" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "HAVE_CONFIG_H" /FD /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo - -!ELSEIF "$(CFG)" == "libid3tag - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c -# ADD CPP /nologo /Gm /GX /ZI /Od /I "." /I "..\..\libz" /I "..\..\libz-1.1.4" /D "_LIB" /D "HAVE_CONFIG_H" /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "DEBUG" /FD /GZ /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo - -!ENDIF - -# Begin Target - -# Name "libid3tag - Win32 Release" -# Name "libid3tag - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "c" -# Begin Source File - -SOURCE=..\compat.c -# End Source File -# Begin Source File - -SOURCE=..\crc.c -# End Source File -# Begin Source File - -SOURCE=..\debug.c -# End Source File -# Begin Source File - -SOURCE=..\field.c -# End Source File -# Begin Source File - -SOURCE=..\file.c -# End Source File -# Begin Source File - -SOURCE=..\frame.c -# End Source File -# Begin Source File - -SOURCE=..\frametype.c -# End Source File -# Begin Source File - -SOURCE=..\genre.c -# End Source File -# Begin Source File - -SOURCE=..\latin1.c -# End Source File -# Begin Source File - -SOURCE=..\parse.c -# End Source File -# Begin Source File - -SOURCE=..\render.c -# End Source File -# Begin Source File - -SOURCE=..\tag.c -# End Source File -# Begin Source File - -SOURCE=..\ucs4.c -# End Source File -# Begin Source File - -SOURCE=..\utf16.c -# End Source File -# Begin Source File - -SOURCE=..\utf8.c -# End Source File -# Begin Source File - -SOURCE=..\util.c -# End Source File -# Begin Source File - -SOURCE=..\version.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h" -# Begin Source File - -SOURCE=..\compat.h -# End Source File -# Begin Source File - -SOURCE=.\config.h -# End Source File -# Begin Source File - -SOURCE=..\crc.h -# End Source File -# Begin Source File - -SOURCE=..\debug.h -# End Source File -# Begin Source File - -SOURCE=..\field.h -# End Source File -# Begin Source File - -SOURCE=..\file.h -# End Source File -# Begin Source File - -SOURCE=..\frame.h -# End Source File -# Begin Source File - -SOURCE=..\frametype.h -# End Source File -# Begin Source File - -SOURCE=..\genre.h -# End Source File -# Begin Source File - -SOURCE=..\global.h -# End Source File -# Begin Source File - -SOURCE=..\id3tag.h -# End Source File -# Begin Source File - -SOURCE=..\latin1.h -# End Source File -# Begin Source File - -SOURCE=..\parse.h -# End Source File -# Begin Source File - -SOURCE=..\render.h -# End Source File -# Begin Source File - -SOURCE=..\tag.h -# End Source File -# Begin Source File - -SOURCE=..\ucs4.h -# End Source File -# Begin Source File - -SOURCE=..\utf16.h -# End Source File -# Begin Source File - -SOURCE=..\utf8.h -# End Source File -# Begin Source File - -SOURCE=..\util.h -# End Source File -# Begin Source File - -SOURCE=..\version.h -# End Source File -# End Group -# Begin Group "Data Files" - -# PROP Default_Filter "dat" -# Begin Source File - -SOURCE=..\genre.dat -# End Source File -# End Group -# End Target -# End Project diff --git a/lib-src/libid3tag/parse.c b/lib-src/libid3tag/parse.c deleted file mode 100644 index a905bdf56..000000000 --- a/lib-src/libid3tag/parse.c +++ /dev/null @@ -1,196 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: parse.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include -# include - -# include "id3tag.h" -# include "parse.h" -# include "latin1.h" -# include "utf16.h" -# include "utf8.h" - -signed long id3_parse_int(id3_byte_t const **ptr, unsigned int bytes) -{ - signed long value = 0; - - assert(bytes >= 1 && bytes <= 4); - - if (**ptr & 0x80) - value = ~0; - - switch (bytes) { - case 4: value = (value << 8) | *(*ptr)++; - case 3: value = (value << 8) | *(*ptr)++; - case 2: value = (value << 8) | *(*ptr)++; - case 1: value = (value << 8) | *(*ptr)++; - } - - return value; -} - -unsigned long id3_parse_uint(id3_byte_t const **ptr, unsigned int bytes) -{ - unsigned long value = 0; - - assert(bytes >= 1 && bytes <= 4); - - switch (bytes) { - case 4: value = (value << 8) | *(*ptr)++; - case 3: value = (value << 8) | *(*ptr)++; - case 2: value = (value << 8) | *(*ptr)++; - case 1: value = (value << 8) | *(*ptr)++; - } - - return value; -} - -unsigned long id3_parse_syncsafe(id3_byte_t const **ptr, unsigned int bytes) -{ - unsigned long value = 0; - - assert(bytes == 4 || bytes == 5); - - switch (bytes) { - case 5: value = (value << 4) | (*(*ptr)++ & 0x0f); - case 4: value = (value << 7) | (*(*ptr)++ & 0x7f); - value = (value << 7) | (*(*ptr)++ & 0x7f); - value = (value << 7) | (*(*ptr)++ & 0x7f); - value = (value << 7) | (*(*ptr)++ & 0x7f); - } - - return value; -} - -void id3_parse_immediate(id3_byte_t const **ptr, unsigned int bytes, - char *value) -{ - assert(value); - assert(bytes == 8 || bytes == 4 || bytes == 3); - - switch (bytes) { - case 8: *value++ = *(*ptr)++; - *value++ = *(*ptr)++; - *value++ = *(*ptr)++; - *value++ = *(*ptr)++; - case 4: *value++ = *(*ptr)++; - case 3: *value++ = *(*ptr)++; - *value++ = *(*ptr)++; - *value++ = *(*ptr)++; - } - - *value = 0; -} - -id3_latin1_t *id3_parse_latin1(id3_byte_t const **ptr, id3_length_t length, - int full) -{ - id3_byte_t const *end; - int terminated = 0; - id3_latin1_t *latin1; - - end = memchr(*ptr, 0, length); - if (end == 0) - end = *ptr + length; - else { - length = end - *ptr; - terminated = 1; - } - - latin1 = malloc(length + 1); - if (latin1) { - memcpy(latin1, *ptr, length); - latin1[length] = 0; - - if (!full) { - id3_latin1_t *check; - - for (check = latin1; *check; ++check) { - if (*check == '\n') - *check = ' '; - } - } - } - - *ptr += length + terminated; - - return latin1; -} - -id3_ucs4_t *id3_parse_string(id3_byte_t const **ptr, id3_length_t length, - enum id3_field_textencoding encoding, int full) -{ - id3_ucs4_t *ucs4 = 0; - enum id3_utf16_byteorder byteorder = ID3_UTF16_BYTEORDER_ANY; - - switch (encoding) { - case ID3_FIELD_TEXTENCODING_ISO_8859_1: - ucs4 = id3_latin1_deserialize(ptr, length); - break; - - case ID3_FIELD_TEXTENCODING_UTF_16BE: - byteorder = ID3_UTF16_BYTEORDER_BE; - case ID3_FIELD_TEXTENCODING_UTF_16: - ucs4 = id3_utf16_deserialize(ptr, length, byteorder); - break; - - case ID3_FIELD_TEXTENCODING_UTF_8: - ucs4 = id3_utf8_deserialize(ptr, length); - break; - } - - if (ucs4 && !full) { - id3_ucs4_t *check; - - for (check = ucs4; *check; ++check) { - if (*check == '\n') - *check = ' '; - } - } - - return ucs4; -} - -id3_byte_t *id3_parse_binary(id3_byte_t const **ptr, id3_length_t length) -{ - id3_byte_t *data; - - if (length == 0) - return malloc(1); - - data = malloc(length); - if (data) - memcpy(data, *ptr, length); - - *ptr += length; - - return data; -} diff --git a/lib-src/libid3tag/parse.h b/lib-src/libid3tag/parse.h deleted file mode 100644 index fadd3fb2f..000000000 --- a/lib-src/libid3tag/parse.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: parse.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_PARSE_H -# define LIBID3TAG_PARSE_H - -signed long id3_parse_int(id3_byte_t const **, unsigned int); -unsigned long id3_parse_uint(id3_byte_t const **, unsigned int); -unsigned long id3_parse_syncsafe(id3_byte_t const **, unsigned int); -void id3_parse_immediate(id3_byte_t const **, unsigned int, char *); -id3_latin1_t *id3_parse_latin1(id3_byte_t const **, id3_length_t, int); -id3_ucs4_t *id3_parse_string(id3_byte_t const **, id3_length_t, - enum id3_field_textencoding, int); -id3_byte_t *id3_parse_binary(id3_byte_t const **, id3_length_t); - -# endif diff --git a/lib-src/libid3tag/render.c b/lib-src/libid3tag/render.c deleted file mode 100644 index baa20ce28..000000000 --- a/lib-src/libid3tag/render.c +++ /dev/null @@ -1,200 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: render.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "render.h" -# include "ucs4.h" -# include "latin1.h" -# include "utf16.h" -# include "utf8.h" - -id3_length_t id3_render_immediate(id3_byte_t **ptr, - char const *value, unsigned int bytes) -{ - assert(value); - assert(bytes == 8 || bytes == 4 || bytes == 3); - - if (ptr) { - switch (bytes) { - case 8: *(*ptr)++ = *value++; - *(*ptr)++ = *value++; - *(*ptr)++ = *value++; - *(*ptr)++ = *value++; - case 4: *(*ptr)++ = *value++; - case 3: *(*ptr)++ = *value++; - *(*ptr)++ = *value++; - *(*ptr)++ = *value++; - } - } - - return bytes; -} - -id3_length_t id3_render_syncsafe(id3_byte_t **ptr, - unsigned long num, unsigned int bytes) -{ - assert(bytes == 4 || bytes == 5); - - if (ptr) { - switch (bytes) { - case 5: *(*ptr)++ = (num >> 28) & 0x0f; - case 4: *(*ptr)++ = (num >> 21) & 0x7f; - *(*ptr)++ = (num >> 14) & 0x7f; - *(*ptr)++ = (num >> 7) & 0x7f; - *(*ptr)++ = (num >> 0) & 0x7f; - } - } - - return bytes; -} - -id3_length_t id3_render_int(id3_byte_t **ptr, - signed long num, unsigned int bytes) -{ - assert(bytes >= 1 && bytes <= 4); - - if (ptr) { - switch (bytes) { - case 4: *(*ptr)++ = num >> 24; - case 3: *(*ptr)++ = num >> 16; - case 2: *(*ptr)++ = num >> 8; - case 1: *(*ptr)++ = num >> 0; - } - } - - return bytes; -} - -id3_length_t id3_render_binary(id3_byte_t **ptr, - id3_byte_t const *data, id3_length_t length) -{ - if (data == 0) - return 0; - - if (ptr) { - memcpy(*ptr, data, length); - *ptr += length; - } - - return length; -} - -id3_length_t id3_render_latin1(id3_byte_t **ptr, - id3_latin1_t const *latin1, int terminate) -{ - id3_length_t size; - - if (latin1 == 0) - latin1 = (id3_latin1_t const *)""; - - size = id3_latin1_size(latin1); - if (!terminate) - --size; - - if (ptr) { - memcpy(*ptr, latin1, size); - *ptr += size; - } - - return size; -} - -id3_length_t id3_render_string(id3_byte_t **ptr, id3_ucs4_t const *ucs4, - enum id3_field_textencoding encoding, - int terminate) -{ - enum id3_utf16_byteorder byteorder = ID3_UTF16_BYTEORDER_ANY; - - if (ucs4 == 0) - ucs4 = id3_ucs4_empty; - - switch (encoding) { - case ID3_FIELD_TEXTENCODING_ISO_8859_1: - return id3_latin1_serialize(ptr, ucs4, terminate); - - case ID3_FIELD_TEXTENCODING_UTF_16BE: - byteorder = ID3_UTF16_BYTEORDER_BE; - case ID3_FIELD_TEXTENCODING_UTF_16: - return id3_utf16_serialize(ptr, ucs4, byteorder, terminate); - - case ID3_FIELD_TEXTENCODING_UTF_8: - return id3_utf8_serialize(ptr, ucs4, terminate); - } - - return 0; -} - -id3_length_t id3_render_padding(id3_byte_t **ptr, id3_byte_t value, - id3_length_t length) -{ - if (ptr) { - memset(*ptr, value, length); - *ptr += length; - } - - return length; -} - -/* - * NAME: render->paddedstring() - * DESCRIPTION: render a space-padded string using latin1 encoding - */ -id3_length_t id3_render_paddedstring(id3_byte_t **ptr, id3_ucs4_t const *ucs4, - id3_length_t length) -{ - id3_ucs4_t padded[31], *data, *end; - - /* latin1 encoding only (this is used for ID3v1 fields) */ - - assert(length <= 30); - - data = padded; - end = data + length; - - if (ucs4) { - while (*ucs4 && end - data > 0) { - *data++ = *ucs4++; - - if (data[-1] == '\n') - data[-1] = ' '; - } - } - - while (end - data > 0) - *data++ = ' '; - - *data = 0; - - return id3_latin1_serialize(ptr, padded, 0); -} diff --git a/lib-src/libid3tag/render.h b/lib-src/libid3tag/render.h deleted file mode 100644 index 11e89d94e..000000000 --- a/lib-src/libid3tag/render.h +++ /dev/null @@ -1,40 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: render.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_RENDER_H -# define LIBID3TAG_RENDER_H - -# include "id3tag.h" - -id3_length_t id3_render_immediate(id3_byte_t **, char const *, unsigned int); -id3_length_t id3_render_syncsafe(id3_byte_t **, unsigned long, unsigned int); -id3_length_t id3_render_int(id3_byte_t **, signed long, unsigned int); -id3_length_t id3_render_binary(id3_byte_t **, - id3_byte_t const *, id3_length_t); -id3_length_t id3_render_latin1(id3_byte_t **, id3_latin1_t const *, int); -id3_length_t id3_render_string(id3_byte_t **, id3_ucs4_t const *, - enum id3_field_textencoding, int); -id3_length_t id3_render_padding(id3_byte_t **, id3_byte_t, id3_length_t); - -id3_length_t id3_render_paddedstring(id3_byte_t **, id3_ucs4_t const *, - id3_length_t); - -# endif diff --git a/lib-src/libid3tag/stamp-h.in b/lib-src/libid3tag/stamp-h.in deleted file mode 100644 index 9788f7023..000000000 --- a/lib-src/libid3tag/stamp-h.in +++ /dev/null @@ -1 +0,0 @@ -timestamp diff --git a/lib-src/libid3tag/tag.c b/lib-src/libid3tag/tag.c deleted file mode 100644 index a62e03f52..000000000 --- a/lib-src/libid3tag/tag.c +++ /dev/null @@ -1,1061 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: tag.c,v 1.4 2007-04-29 05:10:24 llucius Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "id3tag.h" -# include "tag.h" -# include "frame.h" -# include "compat.h" -# include "parse.h" -# include "render.h" -# include "latin1.h" -# include "ucs4.h" -# include "genre.h" -# include "crc.h" -# include "field.h" -# include "util.h" - -/* - * NAME: tag->new() - * DESCRIPTION: allocate and return a new, empty tag - */ -struct id3_tag *id3_tag_new(void) -{ - struct id3_tag *tag; - - tag = malloc(sizeof(*tag)); - if (tag) { - tag->refcount = 0; - tag->version = ID3_TAG_VERSION; - tag->flags = 0; - tag->extendedflags = 0; - tag->restrictions = 0; - tag->options = /* ID3_TAG_OPTION_UNSYNCHRONISATION | */ - ID3_TAG_OPTION_COMPRESSION | ID3_TAG_OPTION_CRC; - tag->nframes = 0; - tag->frames = 0; - tag->paddedsize = 0; - } - - return tag; -} - -/* - * NAME: tag->delete() - * DESCRIPTION: destroy a tag and deallocate all associated memory - */ -void id3_tag_delete(struct id3_tag *tag) -{ - assert(tag); - - if (tag->refcount == 0) { - id3_tag_clearframes(tag); - - if (tag->frames) - free(tag->frames); - - free(tag); - } -} - -/* - * NAME: tag->addref() - * DESCRIPTION: add an external reference to a tag - */ -void id3_tag_addref(struct id3_tag *tag) -{ - assert(tag); - - ++tag->refcount; -} - -/* - * NAME: tag->delref() - * DESCRIPTION: remove an external reference to a tag - */ -void id3_tag_delref(struct id3_tag *tag) -{ - assert(tag && tag->refcount > 0); - - --tag->refcount; -} - -/* - * NAME: tag->version() - * DESCRIPTION: return the tag's original ID3 version number - */ -unsigned int id3_tag_version(struct id3_tag const *tag) -{ - assert(tag); - - return tag->version; -} - -/* - * NAME: tag->options() - * DESCRIPTION: get or set tag options - */ -int id3_tag_options(struct id3_tag *tag, int mask, int values) -{ - assert(tag); - - if (mask) - tag->options = (tag->options & ~mask) | (values & mask); - - return tag->options; -} - -/* - * NAME: tag->setlength() - * DESCRIPTION: set the minimum rendered tag size - */ -void id3_tag_setlength(struct id3_tag *tag, id3_length_t length) -{ - assert(tag); - - tag->paddedsize = length; -} - -/* - * NAME: tag->clearframes() - * DESCRIPTION: detach and delete all frames associated with a tag - */ -void id3_tag_clearframes(struct id3_tag *tag) -{ - unsigned int i; - - assert(tag); - - for (i = 0; i < tag->nframes; ++i) { - id3_frame_delref(tag->frames[i]); - id3_frame_delete(tag->frames[i]); - } - - tag->nframes = 0; -} - -/* - * NAME: tag->attachframe() - * DESCRIPTION: attach a frame to a tag - */ -int id3_tag_attachframe(struct id3_tag *tag, struct id3_frame *frame) -{ - struct id3_frame **frames; - - assert(tag && frame); - - frames = realloc(tag->frames, (tag->nframes + 1) * sizeof(*frames)); - if (frames == 0) - return -1; - - tag->frames = frames; - tag->frames[tag->nframes++] = frame; - - id3_frame_addref(frame); - - return 0; -} - -/* - * NAME: tag->detachframe() - * DESCRIPTION: detach (but don't delete) a frame from a tag - */ -int id3_tag_detachframe(struct id3_tag *tag, struct id3_frame *frame) -{ - unsigned int i; - - assert(tag && frame); - - for (i = 0; i < tag->nframes; ++i) { - if (tag->frames[i] == frame) - break; - } - - if (i == tag->nframes) - return -1; - - --tag->nframes; - while (i++ < tag->nframes) - tag->frames[i - 1] = tag->frames[i]; - - id3_frame_delref(frame); - - return 0; -} - -/* - * NAME: tag->findframe() - * DESCRIPTION: find in a tag the nth (0-based) frame with the given frame ID - */ -struct id3_frame *id3_tag_findframe(struct id3_tag const *tag, - char const *id, unsigned int index) -{ - unsigned int len, i; - - assert(tag); - - if (id == 0 || *id == 0) - return (index < tag->nframes) ? tag->frames[index] : 0; - - len = strlen(id); - - if (len == 4) { - struct id3_compat const *compat; - - compat = id3_compat_lookup(id, len); - if (compat && compat->equiv && !compat->translate) { - id = compat->equiv; - len = strlen(id); - } - } - - for (i = 0; i < tag->nframes; ++i) { - if (strncmp(tag->frames[i]->id, id, len) == 0 && index-- == 0) - return tag->frames[i]; - } - - return 0; -} - -enum tagtype { - TAGTYPE_NONE = 0, - TAGTYPE_ID3V1, - TAGTYPE_ID3V2, - TAGTYPE_ID3V2_FOOTER -}; - -static -enum tagtype tagtype(id3_byte_t const *data, id3_length_t length) -{ - if (length >= 3 && - data[0] == 'T' && data[1] == 'A' && data[2] == 'G') - return TAGTYPE_ID3V1; - - if (length >= 10 && - ((data[0] == 'I' && data[1] == 'D' && data[2] == '3') || - (data[0] == '3' && data[1] == 'D' && data[2] == 'I')) && - data[3] < 0xff && data[4] < 0xff && - data[6] < 0x80 && data[7] < 0x80 && data[8] < 0x80 && data[9] < 0x80) - return data[0] == 'I' ? TAGTYPE_ID3V2 : TAGTYPE_ID3V2_FOOTER; - - return TAGTYPE_NONE; -} - -static -void parse_header(id3_byte_t const **ptr, - unsigned int *version, int *flags, id3_length_t *size) -{ - *ptr += 3; - - *version = id3_parse_uint(ptr, 2); - *flags = id3_parse_uint(ptr, 1); - *size = id3_parse_syncsafe(ptr, 4); -} - -/* - * NAME: tag->query() - * DESCRIPTION: if a tag begins at the given location, return its size - */ -signed long id3_tag_query(id3_byte_t const *data, id3_length_t length) -{ - unsigned int version; - int flags; - id3_length_t size; - - assert(data); - - switch (tagtype(data, length)) { - case TAGTYPE_ID3V1: - return 128; - - case TAGTYPE_ID3V2: - parse_header(&data, &version, &flags, &size); - - if (flags & ID3_TAG_FLAG_FOOTERPRESENT) - size += 10; - - return 10 + size; - - case TAGTYPE_ID3V2_FOOTER: - parse_header(&data, &version, &flags, &size); - return -size - 10; - - case TAGTYPE_NONE: - break; - } - - return 0; -} - -static -void trim(char *str) -{ - char *ptr; - - ptr = str + strlen(str); - while (ptr > str && ptr[-1] == ' ') - --ptr; - - *ptr = 0; -} - -static -int v1_attachstr(struct id3_tag *tag, char const *id, - char *text, unsigned long number) -{ - struct id3_frame *frame; - id3_ucs4_t ucs4[31]; - - if (text) { - trim(text); - if (*text == 0) - return 0; - } - - frame = id3_frame_new(id); - if (frame == 0) - return -1; - - if (id3_field_settextencoding(&frame->fields[0], - ID3_FIELD_TEXTENCODING_ISO_8859_1) == -1) - goto fail; - - if (text) - id3_latin1_decode((id3_latin1_t const *)text, ucs4); - else - id3_ucs4_putnumber(ucs4, number); - - if (strcmp(id, ID3_FRAME_COMMENT) == 0) { - if (id3_field_setlanguage(&frame->fields[1], "XXX") == -1 || - id3_field_setstring(&frame->fields[2], id3_ucs4_empty) == -1 || - id3_field_setfullstring(&frame->fields[3], ucs4) == -1) - goto fail; - } - else { - id3_ucs4_t *ptr = ucs4; - - if (id3_field_setstrings(&frame->fields[1], 1, &ptr) == -1) - goto fail; - } - - if (id3_tag_attachframe(tag, frame) == -1) - goto fail; - - return 0; - - fail: - id3_frame_delete(frame); - return -1; -} - -static -struct id3_tag *v1_parse(id3_byte_t const *data) -{ - struct id3_tag *tag; - - tag = id3_tag_new(); - if (tag) { - char title[31], artist[31], album[31], year[5], comment[31]; - unsigned int genre, track; - - tag->version = 0x0100; - - tag->options |= ID3_TAG_OPTION_ID3V1; - tag->options &= ~ID3_TAG_OPTION_COMPRESSION; - - tag->restrictions = - ID3_TAG_RESTRICTION_TEXTENCODING_LATIN1_UTF8 | - ID3_TAG_RESTRICTION_TEXTSIZE_30_CHARS; - - title[30] = artist[30] = album[30] = year[4] = comment[30] = 0; - - memcpy(title, &data[3], 30); - memcpy(artist, &data[33], 30); - memcpy(album, &data[63], 30); - memcpy(year, &data[93], 4); - memcpy(comment, &data[97], 30); - - genre = data[127]; - - track = 0; - if (comment[28] == 0 && comment[29] != 0) { - track = comment[29]; - tag->version = 0x0101; - } - - /* populate tag frames */ - - if (v1_attachstr(tag, ID3_FRAME_TITLE, title, 0) == -1 || - v1_attachstr(tag, ID3_FRAME_ARTIST, artist, 0) == -1 || - v1_attachstr(tag, ID3_FRAME_ALBUM, album, 0) == -1 || - v1_attachstr(tag, ID3_FRAME_YEAR, year, 0) == -1 || - (track && v1_attachstr(tag, ID3_FRAME_TRACK, 0, track) == -1) || - (genre < 0xff && v1_attachstr(tag, ID3_FRAME_GENRE, 0, genre) == -1) || - v1_attachstr(tag, ID3_FRAME_COMMENT, comment, 0) == -1) { - id3_tag_delete(tag); - tag = 0; - } - } - - return tag; -} - -static -struct id3_tag *v2_parse(id3_byte_t const *ptr) -{ - struct id3_tag *tag; - id3_byte_t *mem = 0; - - tag = id3_tag_new(); - if (tag) { - id3_byte_t const *end; - id3_length_t size; - - parse_header(&ptr, &tag->version, &tag->flags, &size); - - tag->paddedsize = 10 + size; - - if ((tag->flags & ID3_TAG_FLAG_UNSYNCHRONISATION) && - ID3_TAG_VERSION_MAJOR(tag->version) < 4) { - mem = malloc(size); - if (mem == 0) - goto fail; - - memcpy(mem, ptr, size); - - size = id3_util_deunsynchronise(mem, size); - ptr = mem; - } - - end = ptr + size; - - if (tag->flags & ID3_TAG_FLAG_EXTENDEDHEADER) { - switch (ID3_TAG_VERSION_MAJOR(tag->version)) { - case 2: - goto fail; - - case 3: - { - id3_byte_t const *ehptr, *ehend; - id3_length_t ehsize; - - enum { - EH_FLAG_CRC = 0x8000 /* CRC data present */ - }; - - if (end - ptr < 4) - goto fail; - - ehsize = id3_parse_uint(&ptr, 4); - - if (ehsize > end - ptr) - goto fail; - - ehptr = ptr; - ehend = ptr + ehsize; - - ptr = ehend; - - if (ehend - ehptr >= 6) { - int ehflags; - id3_length_t padsize; - - ehflags = id3_parse_uint(&ehptr, 2); - padsize = id3_parse_uint(&ehptr, 4); - - if (padsize > end - ptr) - goto fail; - - end -= padsize; - - if (ehflags & EH_FLAG_CRC) { - unsigned long crc; - - if (ehend - ehptr < 4) - goto fail; - - crc = id3_parse_uint(&ehptr, 4); - - if (crc != id3_crc_compute(ptr, end - ptr)) - goto fail; - - tag->extendedflags |= ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT; - } - } - } - break; - - case 4: - { - id3_byte_t const *ehptr, *ehend; - id3_length_t ehsize; - unsigned int bytes; - - if (end - ptr < 4) - goto fail; - - ehptr = ptr; - ehsize = id3_parse_syncsafe(&ptr, 4); - - if (ehsize < 6 || ehsize > end - ehptr) - goto fail; - - ehend = ehptr + ehsize; - - bytes = id3_parse_uint(&ptr, 1); - - if (bytes < 1 || bytes > ehend - ptr) - goto fail; - - ehptr = ptr + bytes; - - /* verify extended header size */ - { - id3_byte_t const *flagsptr = ptr, *dataptr = ehptr; - unsigned int datalen; - int ehflags; - - while (bytes--) { - for (ehflags = id3_parse_uint(&flagsptr, 1); ehflags; - ehflags = (ehflags << 1) & 0xff) { - if (ehflags & 0x80) { - if (dataptr == ehend) - goto fail; - datalen = id3_parse_uint(&dataptr, 1); - if (datalen > 0x7f || datalen > ehend - dataptr) - goto fail; - dataptr += datalen; - } - } - } - } - - tag->extendedflags = id3_parse_uint(&ptr, 1); - - ptr = ehend; - - if (tag->extendedflags & ID3_TAG_EXTENDEDFLAG_TAGISANUPDATE) { - bytes = id3_parse_uint(&ehptr, 1); - ehptr += bytes; - } - - if (tag->extendedflags & ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT) { - unsigned long crc; - - bytes = id3_parse_uint(&ehptr, 1); - if (bytes < 5) - goto fail; - - crc = id3_parse_syncsafe(&ehptr, 5); - ehptr += bytes - 5; - - if (crc != id3_crc_compute(ptr, end - ptr)) - goto fail; - } - - if (tag->extendedflags & ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS) { - bytes = id3_parse_uint(&ehptr, 1); - if (bytes < 1) - goto fail; - - tag->restrictions = id3_parse_uint(&ehptr, 1); - ehptr += bytes - 1; - } - } - break; - } - } - - /* frames */ - - while (ptr < end) { - struct id3_frame *frame; - - if (*ptr == 0) - break; /* padding */ - - frame = id3_frame_parse(&ptr, end - ptr, tag->version); - if (frame == 0 || id3_tag_attachframe(tag, frame) == -1) - goto fail; - } - - if (ID3_TAG_VERSION_MAJOR(tag->version) < 4 && - id3_compat_fixup(tag) == -1) - goto fail; - } - - if (0) { - fail: - id3_tag_delete(tag); - tag = 0; - } - - if (mem) - free(mem); - - return tag; -} - -/* - * NAME: tag->parse() - * DESCRIPTION: parse a complete ID3 tag - */ -struct id3_tag *id3_tag_parse(id3_byte_t const *data, id3_length_t length) -{ - id3_byte_t const *ptr; - unsigned int version; - int flags; - id3_length_t size; - - assert(data); - - switch (tagtype(data, length)) { - case TAGTYPE_ID3V1: - return (length < 128) ? 0 : v1_parse(data); - - case TAGTYPE_ID3V2: - break; - - case TAGTYPE_ID3V2_FOOTER: - case TAGTYPE_NONE: - return 0; - } - - /* ID3v2.x */ - - ptr = data; - parse_header(&ptr, &version, &flags, &size); - - switch (ID3_TAG_VERSION_MAJOR(version)) { - case 4: - if (flags & ID3_TAG_FLAG_FOOTERPRESENT) - size += 10; - case 2: - case 3: - return (length < 10 + size) ? 0 : v2_parse(data); - } - - return 0; -} - -static -void v1_renderstr(struct id3_tag const *tag, char const *frameid, - id3_byte_t **buffer, id3_length_t length) -{ - struct id3_frame *frame; - id3_ucs4_t const *string; - - frame = id3_tag_findframe(tag, frameid, 0); - if (frame == 0) - string = id3_ucs4_empty; - else { - if (strcmp(frameid, ID3_FRAME_COMMENT) == 0) - string = id3_field_getfullstring(&frame->fields[3]); - else - string = id3_field_getstrings(&frame->fields[1], 0); - } - - id3_render_paddedstring(buffer, string, length); -} - -/* - * NAME: v1->render() - * DESCRIPTION: render an ID3v1 (or ID3v1.1) tag - */ -static -id3_length_t v1_render(struct id3_tag const *tag, id3_byte_t *buffer) -{ - id3_byte_t data[128], *ptr; - struct id3_frame *frame; - unsigned int i; - int genre = -1; - - ptr = data; - - id3_render_immediate(&ptr, "TAG", 3); - - v1_renderstr(tag, ID3_FRAME_TITLE, &ptr, 30); - v1_renderstr(tag, ID3_FRAME_ARTIST, &ptr, 30); - v1_renderstr(tag, ID3_FRAME_ALBUM, &ptr, 30); - v1_renderstr(tag, ID3_FRAME_YEAR, &ptr, 4); - v1_renderstr(tag, ID3_FRAME_COMMENT, &ptr, 30); - - /* ID3v1.1 track number */ - - frame = id3_tag_findframe(tag, ID3_FRAME_TRACK, 0); - if (frame) { - unsigned int track; - - track = id3_ucs4_getnumber(id3_field_getstrings(&frame->fields[1], 0)); - if (track > 0 && track <= 0xff) { - ptr[-2] = 0; - ptr[-1] = track; - } - } - - /* ID3v1 genre number */ - - frame = id3_tag_findframe(tag, ID3_FRAME_GENRE, 0); - if (frame) { - unsigned int nstrings; - - nstrings = id3_field_getnstrings(&frame->fields[1]); - - for (i = 0; i < nstrings; ++i) { - genre = id3_genre_number(id3_field_getstrings(&frame->fields[1], i)); - if (genre != -1) - break; - } - - if (i == nstrings && nstrings > 0) - genre = ID3_GENRE_OTHER; - } - - id3_render_int(&ptr, genre, 1); - - /* make sure the tag is not empty */ - - if (genre == -1) { - for (i = 3; i < 127; ++i) { - if (data[i] != ' ') - break; - } - - if (i == 127) - return 0; - } - - if (buffer) - memcpy(buffer, data, 128); - - return 128; -} - -/* - * NAME: v2_3_render() - * DESCRIPTION: render a v2.3 ID3 tag for compatibility - * AUTHOR: Dominic Mazzoni - */ - -#define ID3V2_3_TAG_VERSION 0x0300 -#define ID3V2_3_TAG_FLAG_KNOWNFLAGS 0xc0 - -id3_length_t v2_3_render(struct id3_tag const *tag, id3_byte_t *buffer) -{ - id3_length_t size = 0; - id3_byte_t **ptr, - *header_ptr = 0, *tagsize_ptr = 0, *crc_ptr = 0, *frames_ptr = 0; - int flags, extendedflags; - unsigned int i; - - assert(tag); - - /* a tag must contain at least one (renderable) frame */ - - for (i = 0; i < tag->nframes; ++i) { - if (id3_frame_render(tag->frames[i], 0, 0) > 0) - break; - } - - if (i == tag->nframes) - return 0; - - ptr = buffer ? &buffer : 0; - - /* get flags */ - - flags = tag->flags & ID3V2_3_TAG_FLAG_KNOWNFLAGS; - extendedflags = tag->extendedflags & ID3_TAG_EXTENDEDFLAG_KNOWNFLAGS; - - extendedflags &= ~ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT; - if (tag->options & ID3_TAG_OPTION_CRC) - extendedflags |= ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT; - - extendedflags &= ~ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS; - if (tag->restrictions) - extendedflags |= ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS; - - - extendedflags = 0; - - - flags &= ~ID3_TAG_FLAG_UNSYNCHRONISATION; - if (tag->options & ID3_TAG_OPTION_UNSYNCHRONISATION) - flags |= ID3_TAG_FLAG_UNSYNCHRONISATION; - - flags &= ~ID3_TAG_FLAG_EXTENDEDHEADER; - if (extendedflags) - flags |= ID3_TAG_FLAG_EXTENDEDHEADER; - - /* header */ - - if (ptr) - header_ptr = *ptr; - - size += id3_render_immediate(ptr, "ID3", 3); - size += id3_render_int(ptr, ID3V2_3_TAG_VERSION, 2); - size += id3_render_int(ptr, flags, 1); - - if (ptr) - tagsize_ptr = *ptr; - - size += id3_render_syncsafe(ptr, 0, 4); - - /* extended header */ - - if (flags & ID3_TAG_FLAG_EXTENDEDHEADER) { - id3_length_t ehsize = 0; - id3_byte_t *ehsize_ptr = 0; - - if (ptr) - ehsize_ptr = *ptr; - - ehsize += id3_render_syncsafe(ptr, 0, 4); - ehsize += id3_render_int(ptr, 1, 1); - ehsize += id3_render_int(ptr, extendedflags, 1); - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_TAGISANUPDATE) - ehsize += id3_render_int(ptr, 0, 1); - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT) { - ehsize += id3_render_int(ptr, 5, 1); - - if (ptr) - crc_ptr = *ptr; - - ehsize += id3_render_syncsafe(ptr, 0, 5); - } - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS) { - ehsize += id3_render_int(ptr, 1, 1); - ehsize += id3_render_int(ptr, tag->restrictions, 1); - } - - if (ehsize_ptr) - id3_render_syncsafe(&ehsize_ptr, ehsize, 4); - - size += ehsize; - } - - /* frames */ - - if (ptr) - frames_ptr = *ptr; - - for (i = 0; i < tag->nframes; ++i) - size += id3_frame_render(tag->frames[i], ptr, tag->options); - - /* padding */ - - if (!(flags & ID3_TAG_FLAG_FOOTERPRESENT)) { - if (size < tag->paddedsize) - size += id3_render_padding(ptr, 0, tag->paddedsize - size); - else if (tag->options & ID3_TAG_OPTION_UNSYNCHRONISATION) { - if (ptr == 0) - size += 1; - else { - if ((*ptr)[-1] == 0xff) - size += id3_render_padding(ptr, 0, 1); - } - } - } - - /* patch tag size and CRC */ - - if (tagsize_ptr) - id3_render_syncsafe(&tagsize_ptr, size - 10, 4); - - if (crc_ptr) { - id3_render_syncsafe(&crc_ptr, - id3_crc_compute(frames_ptr, *ptr - frames_ptr), 5); - } - - /* footer */ - - if (flags & ID3_TAG_FLAG_FOOTERPRESENT) { - size += id3_render_immediate(ptr, "3DI", 3); - size += id3_render_binary(ptr, header_ptr + 3, 7); - } - - return size; -} - -/* - * NAME: tag->render() - * DESCRIPTION: render a complete ID3 tag - */ -id3_length_t id3_tag_render(struct id3_tag const *tag, id3_byte_t *buffer) -{ - id3_length_t size = 0; - id3_byte_t **ptr, - *header_ptr = 0, *tagsize_ptr = 0, *crc_ptr = 0, *frames_ptr = 0; - int flags, extendedflags; - unsigned int i; - - assert(tag); - - if (tag->options & ID3_TAG_OPTION_ID3V1) - return v1_render(tag, buffer); - - if (tag->options & ID3_TAG_OPTION_ID3V2_3) - return v2_3_render(tag, buffer); - - /* a tag must contain at least one (renderable) frame */ - - for (i = 0; i < tag->nframes; ++i) { - if (id3_frame_render(tag->frames[i], 0, 0) > 0) - break; - } - - if (i == tag->nframes) - return 0; - - ptr = buffer ? &buffer : 0; - - /* get flags */ - - flags = tag->flags & ID3_TAG_FLAG_KNOWNFLAGS; - extendedflags = tag->extendedflags & ID3_TAG_EXTENDEDFLAG_KNOWNFLAGS; - - extendedflags &= ~ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT; - if (tag->options & ID3_TAG_OPTION_CRC) - extendedflags |= ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT; - - extendedflags &= ~ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS; - if (tag->restrictions) - extendedflags |= ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS; - - flags &= ~ID3_TAG_FLAG_UNSYNCHRONISATION; - if (tag->options & ID3_TAG_OPTION_UNSYNCHRONISATION) - flags |= ID3_TAG_FLAG_UNSYNCHRONISATION; - - flags &= ~ID3_TAG_FLAG_EXTENDEDHEADER; - if (extendedflags) - flags |= ID3_TAG_FLAG_EXTENDEDHEADER; - - flags &= ~ID3_TAG_FLAG_FOOTERPRESENT; - if (tag->options & ID3_TAG_OPTION_APPENDEDTAG) - flags |= ID3_TAG_FLAG_FOOTERPRESENT; - - /* header */ - - if (ptr) - header_ptr = *ptr; - - size += id3_render_immediate(ptr, "ID3", 3); - size += id3_render_int(ptr, ID3_TAG_VERSION, 2); - size += id3_render_int(ptr, flags, 1); - - if (ptr) - tagsize_ptr = *ptr; - - size += id3_render_syncsafe(ptr, 0, 4); - - /* extended header */ - - if (flags & ID3_TAG_FLAG_EXTENDEDHEADER) { - id3_length_t ehsize = 0; - id3_byte_t *ehsize_ptr = 0; - - if (ptr) - ehsize_ptr = *ptr; - - ehsize += id3_render_syncsafe(ptr, 0, 4); - ehsize += id3_render_int(ptr, 1, 1); - ehsize += id3_render_int(ptr, extendedflags, 1); - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_TAGISANUPDATE) - ehsize += id3_render_int(ptr, 0, 1); - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_CRCDATAPRESENT) { - ehsize += id3_render_int(ptr, 5, 1); - - if (ptr) - crc_ptr = *ptr; - - ehsize += id3_render_syncsafe(ptr, 0, 5); - } - - if (extendedflags & ID3_TAG_EXTENDEDFLAG_TAGRESTRICTIONS) { - ehsize += id3_render_int(ptr, 1, 1); - ehsize += id3_render_int(ptr, tag->restrictions, 1); - } - - if (ehsize_ptr) - id3_render_syncsafe(&ehsize_ptr, ehsize, 4); - - size += ehsize; - } - - /* frames */ - - if (ptr) - frames_ptr = *ptr; - - for (i = 0; i < tag->nframes; ++i) - size += id3_frame_render(tag->frames[i], ptr, tag->options); - - /* padding */ - - if (!(flags & ID3_TAG_FLAG_FOOTERPRESENT)) { - if (size < tag->paddedsize) - size += id3_render_padding(ptr, 0, tag->paddedsize - size); - else if (tag->options & ID3_TAG_OPTION_UNSYNCHRONISATION) { - if (ptr == 0) - size += 1; - else { - if ((*ptr)[-1] == 0xff) - size += id3_render_padding(ptr, 0, 1); - } - } - } - - /* patch tag size and CRC */ - - if (tagsize_ptr) - id3_render_syncsafe(&tagsize_ptr, size - 10, 4); - - if (crc_ptr) { - id3_render_syncsafe(&crc_ptr, - id3_crc_compute(frames_ptr, *ptr - frames_ptr), 5); - } - - /* footer */ - - if (flags & ID3_TAG_FLAG_FOOTERPRESENT) { - size += id3_render_immediate(ptr, "3DI", 3); - size += id3_render_binary(ptr, header_ptr + 3, 7); - } - - return size; -} diff --git a/lib-src/libid3tag/tag.h b/lib-src/libid3tag/tag.h deleted file mode 100644 index 477c2f9b7..000000000 --- a/lib-src/libid3tag/tag.h +++ /dev/null @@ -1,30 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: tag.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_TAG_H -# define LIBID3TAG_TAG_H - -# include "id3tag.h" - -void id3_tag_addref(struct id3_tag *); -void id3_tag_delref(struct id3_tag *); - -# endif diff --git a/lib-src/libid3tag/ucs4.c b/lib-src/libid3tag/ucs4.c deleted file mode 100644 index 9f88d4a73..000000000 --- a/lib-src/libid3tag/ucs4.c +++ /dev/null @@ -1,224 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: ucs4.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "ucs4.h" -# include "latin1.h" -# include "utf16.h" -# include "utf8.h" - -id3_ucs4_t const id3_ucs4_empty[] = { 0 }; - -/* - * NAME: ucs4->length() - * DESCRIPTION: return the number of ucs4 chars represented by a ucs4 string - */ -id3_length_t id3_ucs4_length(id3_ucs4_t const *ucs4) -{ - id3_ucs4_t const *ptr = ucs4; - - while (*ptr) - ++ptr; - - return ptr - ucs4; -} - -/* - * NAME: ucs4->size() - * DESCRIPTION: return the encoding size of a ucs4 string - */ -id3_length_t id3_ucs4_size(id3_ucs4_t const *ucs4) -{ - return id3_ucs4_length(ucs4) + 1; -} - -/* - * NAME: ucs4->latin1size() - * DESCRIPTION: return the encoding size of a latin1-encoded ucs4 string - */ -id3_length_t id3_ucs4_latin1size(id3_ucs4_t const *ucs4) -{ - return id3_ucs4_size(ucs4); -} - -/* - * NAME: ucs4->utf16size() - * DESCRIPTION: return the encoding size of a utf16-encoded ucs4 string - */ -id3_length_t id3_ucs4_utf16size(id3_ucs4_t const *ucs4) -{ - id3_length_t size = 0; - - while (*ucs4) { - ++size; - if (*ucs4 >= 0x00010000L && - *ucs4 <= 0x0010ffffL) - ++size; - - ++ucs4; - } - - return size + 1; -} - -/* - * NAME: ucs4->utf8size() - * DESCRIPTION: return the encoding size of a utf8-encoded ucs4 string - */ -id3_length_t id3_ucs4_utf8size(id3_ucs4_t const *ucs4) -{ - id3_length_t size = 0; - - while (*ucs4) { - if (*ucs4 <= 0x0000007fL) - size += 1; - else if (*ucs4 <= 0x000007ffL) - size += 2; - else if (*ucs4 <= 0x0000ffffL) - size += 3; - else if (*ucs4 <= 0x001fffffL) - size += 4; - else if (*ucs4 <= 0x03ffffffL) - size += 5; - else if (*ucs4 <= 0x7fffffffL) - size += 6; - else - size += 2; /* based on U+00B7 replacement char */ - - ++ucs4; - } - - return size + 1; -} - -/* - * NAME: ucs4->latin1duplicate() - * DESCRIPTION: duplicate and encode a ucs4 string into latin1 - */ -id3_latin1_t *id3_ucs4_latin1duplicate(id3_ucs4_t const *ucs4) -{ - id3_latin1_t *latin1; - - latin1 = malloc(id3_ucs4_latin1size(ucs4) * sizeof(*latin1)); - if (latin1) - id3_latin1_encode(latin1, ucs4); - - return release(latin1); -} - -/* - * NAME: ucs4->utf16duplicate() - * DESCRIPTION: duplicate and encode a ucs4 string into utf16 - */ -id3_utf16_t *id3_ucs4_utf16duplicate(id3_ucs4_t const *ucs4) -{ - id3_utf16_t *utf16; - - utf16 = malloc(id3_ucs4_utf16size(ucs4) * sizeof(*utf16)); - if (utf16) - id3_utf16_encode(utf16, ucs4); - - return release(utf16); -} - -/* - * NAME: ucs4->utf8duplicate() - * DESCRIPTION: duplicate and encode a ucs4 string into utf8 - */ -id3_utf8_t *id3_ucs4_utf8duplicate(id3_ucs4_t const *ucs4) -{ - id3_utf8_t *utf8; - - utf8 = malloc(id3_ucs4_utf8size(ucs4) * sizeof(*utf8)); - if (utf8) - id3_utf8_encode(utf8, ucs4); - - return release(utf8); -} - -/* - * NAME: ucs4->copy() - * DESCRIPTION: copy a ucs4 string - */ -void id3_ucs4_copy(id3_ucs4_t *dest, id3_ucs4_t const *src) -{ - while ((*dest++ = *src++)) - ; -} - -/* - * NAME: ucs4->duplicate() - * DESCRIPTION: duplicate a ucs4 string - */ -id3_ucs4_t *id3_ucs4_duplicate(id3_ucs4_t const *src) -{ - id3_ucs4_t *ucs4; - - ucs4 = malloc(id3_ucs4_size(src) * sizeof(*ucs4)); - if (ucs4) - id3_ucs4_copy(ucs4, src); - - return ucs4; -} - -/* - * NAME: ucs4->putnumber() - * DESCRIPTION: write a ucs4 string containing a (positive) decimal number - */ -void id3_ucs4_putnumber(id3_ucs4_t *ucs4, unsigned long number) -{ - int digits[10], *digit; - - digit = digits; - - do { - *digit++ = number % 10; - number /= 10; - } - while (number); - - while (digit != digits) - *ucs4++ = '0' + *--digit; - - *ucs4 = 0; -} - -/* - * NAME: ucs4->getnumber() - * DESCRIPTION: read a ucs4 string containing a (positive) decimal number - */ -unsigned long id3_ucs4_getnumber(id3_ucs4_t const *ucs4) -{ - unsigned long number = 0; - - while (*ucs4 >= '0' && *ucs4 <= '9') - number = 10 * number + (*ucs4++ - '0'); - - return number; -} diff --git a/lib-src/libid3tag/ucs4.h b/lib-src/libid3tag/ucs4.h deleted file mode 100644 index df543f28e..000000000 --- a/lib-src/libid3tag/ucs4.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: ucs4.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_UCS4_H -# define LIBID3TAG_UCS4_H - -# include "id3tag.h" - -# define ID3_UCS4_REPLACEMENTCHAR 0x000000b7L /* middle dot */ - -extern id3_ucs4_t const id3_ucs4_empty[]; - -id3_length_t id3_ucs4_length(id3_ucs4_t const *); -id3_length_t id3_ucs4_size(id3_ucs4_t const *); - -id3_length_t id3_ucs4_latin1size(id3_ucs4_t const *); -id3_length_t id3_ucs4_utf16size(id3_ucs4_t const *); -id3_length_t id3_ucs4_utf8size(id3_ucs4_t const *); - -void id3_ucs4_copy(id3_ucs4_t *, id3_ucs4_t const *); -id3_ucs4_t *id3_ucs4_duplicate(id3_ucs4_t const *); - -# endif diff --git a/lib-src/libid3tag/utf16.c b/lib-src/libid3tag/utf16.c deleted file mode 100644 index 48b1469a5..000000000 --- a/lib-src/libid3tag/utf16.c +++ /dev/null @@ -1,327 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: utf16.c,v 1.4 2009-03-30 10:00:58 llucius Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "utf16.h" -# include "ucs4.h" - -/* - * NAME: utf16->length() - * DESCRIPTION: return the number of ucs4 chars represented by a utf16 string - */ -id3_length_t id3_utf16_length(id3_utf16_t const *utf16) -{ - id3_length_t length = 0; - - while (*utf16) { - if (utf16[0] < 0xd800 || utf16[0] > 0xdfff) - ++length; - else if (utf16[0] >= 0xd800 && utf16[0] <= 0xdbff && - utf16[1] >= 0xdc00 && utf16[1] <= 0xdfff) { - ++length; - ++utf16; - } - - ++utf16; - } - - return length; -} - -/* - * NAME: utf16->size() - * DESCRIPTION: return the encoding size of a utf16 string - */ -id3_length_t id3_utf16_size(id3_utf16_t const *utf16) -{ - id3_utf16_t const *ptr = utf16; - - while (*ptr) - ++ptr; - - return ptr - utf16 + 1; -} - -/* - * NAME: utf16->ucs4duplicate() - * DESCRIPTION: duplicate and decode a utf16 string into ucs4 - */ -id3_ucs4_t *id3_utf16_ucs4duplicate(id3_utf16_t const *utf16) -{ - id3_ucs4_t *ucs4; - - ucs4 = malloc((id3_utf16_length(utf16) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_utf16_decode(utf16, ucs4); - - return release(ucs4); -} - -/* - * NAME: utf16->decodechar() - * DESCRIPTION: decode a series of utf16 chars into a single ucs4 char - */ -id3_length_t id3_utf16_decodechar(id3_utf16_t const *utf16, id3_ucs4_t *ucs4) -{ - id3_utf16_t const *start = utf16; - - while (1) { - if (utf16[0] < 0xd800 || utf16[0] > 0xdfff) { - *ucs4 = utf16[0]; - return utf16 - start + 1; - } - else if (utf16[0] >= 0xd800 && utf16[0] <= 0xdbff && - utf16[1] >= 0xdc00 && utf16[1] <= 0xdfff) { - *ucs4 = (((utf16[0] & 0x03ffL) << 10) | - ((utf16[1] & 0x03ffL) << 0)) + 0x00010000L; - return utf16 - start + 2; - } - - ++utf16; - } -} - -/* - * NAME: utf16->encodechar() - * DESCRIPTION: encode a single ucs4 char into a series of up to 2 utf16 chars - */ -id3_length_t id3_utf16_encodechar(id3_utf16_t *utf16, id3_ucs4_t ucs4) -{ - if (ucs4 < 0x00010000L) { - utf16[0] = ucs4; - - return 1; - } - else if (ucs4 < 0x00110000L) { - ucs4 -= 0x00010000L; - - utf16[0] = ((ucs4 >> 10) & 0x3ff) | 0xd800; - utf16[1] = ((ucs4 >> 0) & 0x3ff) | 0xdc00; - - return 2; - } - - /* default */ - - return id3_utf16_encodechar(utf16, ID3_UCS4_REPLACEMENTCHAR); -} - -/* - * NAME: utf16->decode() - * DESCRIPTION: decode a complete utf16 string into a ucs4 string - */ -void id3_utf16_decode(id3_utf16_t const *utf16, id3_ucs4_t *ucs4) -{ - do - utf16 += id3_utf16_decodechar(utf16, ucs4); - while (*ucs4++); -} - -/* - * NAME: utf16->encode() - * DESCRIPTION: encode a complete ucs4 string into a utf16 string - */ -void id3_utf16_encode(id3_utf16_t *utf16, id3_ucs4_t const *ucs4) -{ - do - utf16 += id3_utf16_encodechar(utf16, *ucs4); - while (*ucs4++); -} - -/* - * NAME: utf16->put() - * DESCRIPTION: serialize a single utf16 character - */ -id3_length_t id3_utf16_put(id3_byte_t **ptr, id3_utf16_t utf16, - enum id3_utf16_byteorder byteorder) -{ - if (ptr) { - switch (byteorder) { - case ID3_UTF16_BYTEORDER_BE: - (*ptr)[0] = (utf16 >> 8) & 0xff; - (*ptr)[1] = (utf16 >> 0) & 0xff; - break; - - default: - case ID3_UTF16_BYTEORDER_LE: - (*ptr)[0] = (utf16 >> 0) & 0xff; - (*ptr)[1] = (utf16 >> 8) & 0xff; - break; - } - - *ptr += 2; - } - - return 2; -} - -/* - * NAME: utf16->get() - * DESCRIPTION: deserialize a single utf16 character - */ -id3_utf16_t id3_utf16_get(id3_byte_t const **ptr, - enum id3_utf16_byteorder byteorder) -{ - id3_utf16_t utf16; - - switch (byteorder) { - default: - case ID3_UTF16_BYTEORDER_BE: - utf16 = - ((*ptr)[0] << 8) | - ((*ptr)[1] << 0); - break; - - case ID3_UTF16_BYTEORDER_LE: - utf16 = - ((*ptr)[0] << 0) | - ((*ptr)[1] << 8); - break; - } - - *ptr += 2; - - return utf16; -} - -/* - * NAME: utf16->serialize() - * DESCRIPTION: serialize a ucs4 string using utf16 encoding - */ -id3_length_t id3_utf16_serialize(id3_byte_t **ptr, id3_ucs4_t const *ucs4, - enum id3_utf16_byteorder byteorder, - int terminate) -{ - id3_length_t size = 0; - id3_utf16_t utf16[2], *out; - - if (byteorder == ID3_UTF16_BYTEORDER_ANY) - size += id3_utf16_put(ptr, 0xfeff, byteorder); - - while (*ucs4) { - switch (id3_utf16_encodechar(out = utf16, *ucs4++)) { - case 2: size += id3_utf16_put(ptr, *out++, byteorder); - case 1: size += id3_utf16_put(ptr, *out++, byteorder); - case 0: break; - } - } - - if (terminate) - size += id3_utf16_put(ptr, 0, byteorder); - - return size; -} - -/* - * NAME: utf16->deserialize() - * DESCRIPTION: deserialize a ucs4 string using utf16 encoding - */ -id3_ucs4_t *id3_utf16_deserialize(id3_byte_t const **ptr, id3_length_t length, - enum id3_utf16_byteorder byteorder) -{ - id3_byte_t const *end; - id3_utf16_t *utf16ptr, *utf16; - id3_ucs4_t *ucs4; - - end = *ptr + (length & ~1); - - utf16 = malloc((length / 2 + 1) * sizeof(*utf16)); - if (utf16 == 0) - return 0; - - if (byteorder == ID3_UTF16_BYTEORDER_ANY && end - *ptr > 0) { - switch (((*ptr)[0] << 8) | - ((*ptr)[1] << 0)) { - case 0xfeff: - byteorder = ID3_UTF16_BYTEORDER_BE; - *ptr += 2; - break; - - case 0xfffe: - byteorder = ID3_UTF16_BYTEORDER_LE; - *ptr += 2; - break; - default: - // The text is missing the BOM, so attempt to detect the byte order. - // This is using code from ReactOS and, while it's not foolproof, it - // does provide some hope of getting the endianness correct. - { - unsigned char last_lo_byte = 0; - unsigned char last_hi_byte = 0; - unsigned int hi_byte_diff = 0; - unsigned int lo_byte_diff = 0; - - int i; - for (i = 0; i < length; i += 2) - { - unsigned char lo_byte = (*ptr)[i + 1]; - unsigned char hi_byte = (*ptr)[i]; - -#if !defined(MIN) -#define MIN(x, y) ((x) < (y) ? (x) : (y)) -#endif -#if !defined(MAX) -#define MAX(x, y) ((x) > (y) ? (x) : (y)) -#endif - - lo_byte_diff += MAX(lo_byte, last_lo_byte) - MIN(lo_byte, last_lo_byte); - hi_byte_diff += MAX(hi_byte, last_hi_byte) - MIN(hi_byte, last_hi_byte); - - last_lo_byte = lo_byte; - last_hi_byte = hi_byte; - } - - if (lo_byte_diff < 127 && !hi_byte_diff) - { - byteorder = ID3_UTF16_BYTEORDER_BE; - } - - if (hi_byte_diff && !lo_byte_diff) - { - byteorder = ID3_UTF16_BYTEORDER_LE; - } - } - break; - } - } - - utf16ptr = utf16; - while (end - *ptr > 0 && (*utf16ptr = id3_utf16_get(ptr, byteorder))) - ++utf16ptr; - - *utf16ptr = 0; - - ucs4 = malloc((id3_utf16_length(utf16) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_utf16_decode(utf16, ucs4); - - free(utf16); - - return ucs4; -} diff --git a/lib-src/libid3tag/utf16.h b/lib-src/libid3tag/utf16.h deleted file mode 100644 index c26f36582..000000000 --- a/lib-src/libid3tag/utf16.h +++ /dev/null @@ -1,51 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: utf16.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_UTF16_H -# define LIBID3TAG_UTF16_H - -# include "id3tag.h" - -enum id3_utf16_byteorder { - ID3_UTF16_BYTEORDER_ANY, - ID3_UTF16_BYTEORDER_BE, - ID3_UTF16_BYTEORDER_LE -}; - -id3_length_t id3_utf16_length(id3_utf16_t const *); -id3_length_t id3_utf16_size(id3_utf16_t const *); - -id3_length_t id3_utf16_decodechar(id3_utf16_t const *, id3_ucs4_t *); -id3_length_t id3_utf16_encodechar(id3_utf16_t *, id3_ucs4_t); - -void id3_utf16_decode(id3_utf16_t const *, id3_ucs4_t *); -void id3_utf16_encode(id3_utf16_t *, id3_ucs4_t const *); - -id3_length_t id3_utf16_put(id3_byte_t **, id3_utf16_t, - enum id3_utf16_byteorder); -id3_utf16_t id3_utf16_get(id3_byte_t const **, enum id3_utf16_byteorder); - -id3_length_t id3_utf16_serialize(id3_byte_t **, id3_ucs4_t const *, - enum id3_utf16_byteorder, int); -id3_ucs4_t *id3_utf16_deserialize(id3_byte_t const **, id3_length_t, - enum id3_utf16_byteorder); - -# endif diff --git a/lib-src/libid3tag/utf8.c b/lib-src/libid3tag/utf8.c deleted file mode 100644 index bc79f0dbb..000000000 --- a/lib-src/libid3tag/utf8.c +++ /dev/null @@ -1,365 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: utf8.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "id3tag.h" -# include "utf8.h" -# include "ucs4.h" - -/* - * NAME: utf8->length() - * DESCRIPTION: return the number of ucs4 chars represented by a utf8 string - */ -id3_length_t id3_utf8_length(id3_utf8_t const *utf8) -{ - id3_length_t length = 0; - - while (*utf8) { - if ((utf8[0] & 0x80) == 0x00) - ++length; - else if ((utf8[0] & 0xe0) == 0xc0 && - (utf8[1] & 0xc0) == 0x80) { - if (((utf8[0] & 0x1fL) << 6) >= 0x00000080L) { - ++length; - utf8 += 1; - } - } - else if ((utf8[0] & 0xf0) == 0xe0 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80) { - if ((((utf8[0] & 0x0fL) << 12) | - ((utf8[1] & 0x3fL) << 6)) >= 0x00000800L) { - ++length; - utf8 += 2; - } - } - else if ((utf8[0] & 0xf8) == 0xf0 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80) { - if ((((utf8[0] & 0x07L) << 18) | - ((utf8[1] & 0x3fL) << 12)) >= 0x00010000L) { - ++length; - utf8 += 3; - } - } - else if ((utf8[0] & 0xfc) == 0xf8 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80 && - (utf8[4] & 0xc0) == 0x80) { - if ((((utf8[0] & 0x03L) << 24) | - ((utf8[0] & 0x3fL) << 18)) >= 0x00200000L) { - ++length; - utf8 += 4; - } - } - else if ((utf8[0] & 0xfe) == 0xfc && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80 && - (utf8[4] & 0xc0) == 0x80 && - (utf8[5] & 0xc0) == 0x80) { - if ((((utf8[0] & 0x01L) << 30) | - ((utf8[0] & 0x3fL) << 24)) >= 0x04000000L) { - ++length; - utf8 += 5; - } - } - - ++utf8; - } - - return length; -} - -/* - * NAME: utf8->size() - * DESCRIPTION: return the encoding size of a utf8 string - */ -id3_length_t id3_utf8_size(id3_utf8_t const *utf8) -{ - id3_utf8_t const *ptr = utf8; - - while (*ptr) - ++ptr; - - return ptr - utf8 + 1; -} - -/* - * NAME: utf8->ucs4duplicate() - * DESCRIPTION: duplicate and decode a utf8 string into ucs4 - */ -id3_ucs4_t *id3_utf8_ucs4duplicate(id3_utf8_t const *utf8) -{ - id3_ucs4_t *ucs4; - - ucs4 = malloc((id3_utf8_length(utf8) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_utf8_decode(utf8, ucs4); - - return release(ucs4); -} - -/* - * NAME: utf8->decodechar() - * DESCRIPTION: decode a series of utf8 chars into a single ucs4 char - */ -id3_length_t id3_utf8_decodechar(id3_utf8_t const *utf8, id3_ucs4_t *ucs4) -{ - id3_utf8_t const *start = utf8; - - while (1) { - if ((utf8[0] & 0x80) == 0x00) { - *ucs4 = utf8[0]; - return utf8 - start + 1; - } - else if ((utf8[0] & 0xe0) == 0xc0 && - (utf8[1] & 0xc0) == 0x80) { - *ucs4 = - ((utf8[0] & 0x1fL) << 6) | - ((utf8[1] & 0x3fL) << 0); - if (*ucs4 >= 0x00000080L) - return utf8 - start + 2; - } - else if ((utf8[0] & 0xf0) == 0xe0 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80) { - *ucs4 = - ((utf8[0] & 0x0fL) << 12) | - ((utf8[1] & 0x3fL) << 6) | - ((utf8[2] & 0x3fL) << 0); - if (*ucs4 >= 0x00000800L) - return utf8 - start + 3; - } - else if ((utf8[0] & 0xf8) == 0xf0 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80) { - *ucs4 = - ((utf8[0] & 0x07L) << 18) | - ((utf8[1] & 0x3fL) << 12) | - ((utf8[2] & 0x3fL) << 6) | - ((utf8[3] & 0x3fL) << 0); - if (*ucs4 >= 0x00010000L) - return utf8 - start + 4; - } - else if ((utf8[0] & 0xfc) == 0xf8 && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80 && - (utf8[4] & 0xc0) == 0x80) { - *ucs4 = - ((utf8[0] & 0x03L) << 24) | - ((utf8[1] & 0x3fL) << 18) | - ((utf8[2] & 0x3fL) << 12) | - ((utf8[3] & 0x3fL) << 6) | - ((utf8[4] & 0x3fL) << 0); - if (*ucs4 >= 0x00200000L) - return utf8 - start + 5; - } - else if ((utf8[0] & 0xfe) == 0xfc && - (utf8[1] & 0xc0) == 0x80 && - (utf8[2] & 0xc0) == 0x80 && - (utf8[3] & 0xc0) == 0x80 && - (utf8[4] & 0xc0) == 0x80 && - (utf8[5] & 0xc0) == 0x80) { - *ucs4 = - ((utf8[0] & 0x01L) << 30) | - ((utf8[1] & 0x3fL) << 24) | - ((utf8[2] & 0x3fL) << 18) | - ((utf8[3] & 0x3fL) << 12) | - ((utf8[4] & 0x3fL) << 6) | - ((utf8[5] & 0x3fL) << 0); - if (*ucs4 >= 0x04000000L) - return utf8 - start + 6; - } - - ++utf8; - } -} - -/* - * NAME: utf8->encodechar() - * DESCRIPTION: encode a single ucs4 char into a series of up to 6 utf8 chars - */ -id3_length_t id3_utf8_encodechar(id3_utf8_t *utf8, id3_ucs4_t ucs4) -{ - if (ucs4 <= 0x0000007fL) { - utf8[0] = ucs4; - - return 1; - } - else if (ucs4 <= 0x000007ffL) { - utf8[0] = 0xc0 | ((ucs4 >> 6) & 0x1f); - utf8[1] = 0x80 | ((ucs4 >> 0) & 0x3f); - - return 2; - } - else if (ucs4 <= 0x0000ffffL) { - utf8[0] = 0xe0 | ((ucs4 >> 12) & 0x0f); - utf8[1] = 0x80 | ((ucs4 >> 6) & 0x3f); - utf8[2] = 0x80 | ((ucs4 >> 0) & 0x3f); - - return 3; - } - else if (ucs4 <= 0x001fffffL) { - utf8[0] = 0xf0 | ((ucs4 >> 18) & 0x07); - utf8[1] = 0x80 | ((ucs4 >> 12) & 0x3f); - utf8[2] = 0x80 | ((ucs4 >> 6) & 0x3f); - utf8[3] = 0x80 | ((ucs4 >> 0) & 0x3f); - - return 4; - } - else if (ucs4 <= 0x03ffffffL) { - utf8[0] = 0xf8 | ((ucs4 >> 24) & 0x03); - utf8[1] = 0x80 | ((ucs4 >> 18) & 0x3f); - utf8[2] = 0x80 | ((ucs4 >> 12) & 0x3f); - utf8[3] = 0x80 | ((ucs4 >> 6) & 0x3f); - utf8[4] = 0x80 | ((ucs4 >> 0) & 0x3f); - - return 5; - } - else if (ucs4 <= 0x7fffffffL) { - utf8[0] = 0xfc | ((ucs4 >> 30) & 0x01); - utf8[1] = 0x80 | ((ucs4 >> 24) & 0x3f); - utf8[2] = 0x80 | ((ucs4 >> 18) & 0x3f); - utf8[3] = 0x80 | ((ucs4 >> 12) & 0x3f); - utf8[4] = 0x80 | ((ucs4 >> 6) & 0x3f); - utf8[5] = 0x80 | ((ucs4 >> 0) & 0x3f); - - return 6; - } - - /* default */ - - return id3_utf8_encodechar(utf8, ID3_UCS4_REPLACEMENTCHAR); -} - -/* - * NAME: utf8->decode() - * DESCRIPTION: decode a complete utf8 string into a ucs4 string - */ -void id3_utf8_decode(id3_utf8_t const *utf8, id3_ucs4_t *ucs4) -{ - do - utf8 += id3_utf8_decodechar(utf8, ucs4); - while (*ucs4++); -} - -/* - * NAME: utf8->encode() - * DESCRIPTION: encode a complete ucs4 string into a utf8 string - */ -void id3_utf8_encode(id3_utf8_t *utf8, id3_ucs4_t const *ucs4) -{ - do - utf8 += id3_utf8_encodechar(utf8, *ucs4); - while (*ucs4++); -} - -/* - * NAME: utf8->put() - * DESCRIPTION: serialize a single utf8 character - */ -id3_length_t id3_utf8_put(id3_byte_t **ptr, id3_utf8_t utf8) -{ - if (ptr) - *(*ptr)++ = utf8; - - return 1; -} - -/* - * NAME: utf8->get() - * DESCRIPTION: deserialize a single utf8 character - */ -id3_utf8_t id3_utf8_get(id3_byte_t const **ptr) -{ - return *(*ptr)++; -} - -/* - * NAME: utf8->serialize() - * DESCRIPTION: serialize a ucs4 string using utf8 encoding - */ -id3_length_t id3_utf8_serialize(id3_byte_t **ptr, id3_ucs4_t const *ucs4, - int terminate) -{ - id3_length_t size = 0; - id3_utf8_t utf8[6], *out; - - while (*ucs4) { - switch (id3_utf8_encodechar(out = utf8, *ucs4++)) { - case 6: size += id3_utf8_put(ptr, *out++); - case 5: size += id3_utf8_put(ptr, *out++); - case 4: size += id3_utf8_put(ptr, *out++); - case 3: size += id3_utf8_put(ptr, *out++); - case 2: size += id3_utf8_put(ptr, *out++); - case 1: size += id3_utf8_put(ptr, *out++); - case 0: break; - } - } - - if (terminate) - size += id3_utf8_put(ptr, 0); - - return size; -} - -/* - * NAME: utf8->deserialize() - * DESCRIPTION: deserialize a ucs4 string using utf8 encoding - */ -id3_ucs4_t *id3_utf8_deserialize(id3_byte_t const **ptr, id3_length_t length) -{ - id3_byte_t const *end; - id3_utf8_t *utf8ptr, *utf8; - id3_ucs4_t *ucs4; - - end = *ptr + length; - - utf8 = malloc((length + 1) * sizeof(*utf8)); - if (utf8 == 0) - return 0; - - utf8ptr = utf8; - while (end - *ptr > 0 && (*utf8ptr = id3_utf8_get(ptr))) - ++utf8ptr; - - *utf8ptr = 0; - - ucs4 = malloc((id3_utf8_length(utf8) + 1) * sizeof(*ucs4)); - if (ucs4) - id3_utf8_decode(utf8, ucs4); - - free(utf8); - - return ucs4; -} diff --git a/lib-src/libid3tag/utf8.h b/lib-src/libid3tag/utf8.h deleted file mode 100644 index 2742d2a52..000000000 --- a/lib-src/libid3tag/utf8.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: utf8.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_UTF8_H -# define LIBID3TAG_UTF8_H - -# include "id3tag.h" - -id3_length_t id3_utf8_length(id3_utf8_t const *); -id3_length_t id3_utf8_size(id3_utf8_t const *); - -id3_length_t id3_utf8_decodechar(id3_utf8_t const *, id3_ucs4_t *); -id3_length_t id3_utf8_encodechar(id3_utf8_t *, id3_ucs4_t); - -void id3_utf8_decode(id3_utf8_t const *, id3_ucs4_t *); -void id3_utf8_encode(id3_utf8_t *, id3_ucs4_t const *); - -id3_length_t id3_utf8_put(id3_byte_t **, id3_utf8_t); -id3_utf8_t id3_utf8_get(id3_byte_t const **); - -id3_length_t id3_utf8_serialize(id3_byte_t **, id3_ucs4_t const *, int); -id3_ucs4_t *id3_utf8_deserialize(id3_byte_t const **, id3_length_t); - -# endif diff --git a/lib-src/libid3tag/util.c b/lib-src/libid3tag/util.c deleted file mode 100644 index 78839051b..000000000 --- a/lib-src/libid3tag/util.c +++ /dev/null @@ -1,147 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: util.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# include "id3tag.h" -# include "util.h" - -/* - * NAME: util->unsynchronise() - * DESCRIPTION: perform (in-place) unsynchronisation - */ -id3_length_t id3_util_unsynchronise(id3_byte_t *data, id3_length_t length) -{ - id3_length_t bytes = 0, count; - id3_byte_t *end = data + length; - id3_byte_t const *ptr; - - if (length == 0) - return 0; - - for (ptr = data; ptr < end - 1; ++ptr) { - if (ptr[0] == 0xff && (ptr[1] == 0x00 || (ptr[1] & 0xe0) == 0xe0)) - ++bytes; - } - - if (bytes) { - ptr = end; - end += bytes; - - *--end = *--ptr; - - for (count = bytes; count; *--end = *--ptr) { - if (ptr[-1] == 0xff && (ptr[0] == 0x00 || (ptr[0] & 0xe0) == 0xe0)) { - *--end = 0x00; - --count; - } - } - } - - return length + bytes; -} - -/* - * NAME: util->deunsynchronise() - * DESCRIPTION: undo unsynchronisation (in-place) - */ -id3_length_t id3_util_deunsynchronise(id3_byte_t *data, id3_length_t length) -{ - id3_byte_t const *old, *end = data + length; - id3_byte_t *new; - - if (length == 0) - return 0; - - for (old = new = data; old < end - 1; ++old) { - *new++ = *old; - if (old[0] == 0xff && old[1] == 0x00) - ++old; - } - - *new++ = *old; - - return new - data; -} - -/* - * NAME: util->compress() - * DESCRIPTION: perform zlib deflate method compression - */ -id3_byte_t *id3_util_compress(id3_byte_t const *data, id3_length_t length, - id3_length_t *newlength) -{ - id3_byte_t *compressed; - - *newlength = length + 12; - *newlength += *newlength / 1000; - - compressed = malloc(*newlength); - if (compressed) { - if (compress2(compressed, newlength, data, length, - Z_BEST_COMPRESSION) != Z_OK || - *newlength >= length) { - free(compressed); - compressed = 0; - } - else { - id3_byte_t *resized; - - resized = realloc(compressed, *newlength ? *newlength : 1); - if (resized) - compressed = resized; - } - } - - return compressed; -} - -/* - * NAME: util->decompress() - * DESCRIPTION: undo zlib deflate method compression - */ -id3_byte_t *id3_util_decompress(id3_byte_t const *data, id3_length_t length, - id3_length_t newlength) -{ - id3_byte_t *decompressed; - - decompressed = malloc(newlength ? newlength : 1); - if (decompressed) { - id3_length_t size; - - size = newlength; - - if (uncompress(decompressed, &size, data, length) != Z_OK || - size != newlength) { - free(decompressed); - decompressed = 0; - } - } - - return decompressed; -} diff --git a/lib-src/libid3tag/util.h b/lib-src/libid3tag/util.h deleted file mode 100644 index ba534d5d1..000000000 --- a/lib-src/libid3tag/util.h +++ /dev/null @@ -1,35 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: util.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_UTIL_H -# define LIBID3TAG_UTIL_H - -# include "id3tag.h" - -id3_length_t id3_util_unsynchronise(id3_byte_t *, id3_length_t); -id3_length_t id3_util_deunsynchronise(id3_byte_t *, id3_length_t); - -id3_byte_t *id3_util_compress(id3_byte_t const *, id3_length_t, - id3_length_t *); -id3_byte_t *id3_util_decompress(id3_byte_t const *, id3_length_t, - id3_length_t); - -# endif diff --git a/lib-src/libid3tag/version.c b/lib-src/libid3tag/version.c deleted file mode 100644 index dec49d364..000000000 --- a/lib-src/libid3tag/version.c +++ /dev/null @@ -1,45 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: version.c,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "id3tag.h" -# include "version.h" - -char const id3_version[] = "ID3 Tag Library " ID3_VERSION; -char const id3_copyright[] = "Copyright (C) " ID3_PUBLISHYEAR " " ID3_AUTHOR; -char const id3_author[] = ID3_AUTHOR " <" ID3_EMAIL ">"; - -char const id3_build[] = "" -# if defined(DEBUG) - "DEBUG " -# elif defined(NDEBUG) - "NDEBUG " -# endif - -# if defined(EXPERIMENTAL) - "EXPERIMENTAL " -# endif -; diff --git a/lib-src/libid3tag/version.h b/lib-src/libid3tag/version.h deleted file mode 100644 index c17bdad8a..000000000 --- a/lib-src/libid3tag/version.h +++ /dev/null @@ -1,25 +0,0 @@ -/* - * libid3tag - ID3 tag manipulation library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: version.h,v 1.3 2004-06-08 06:38:15 dmazzoni Exp $ - */ - -# ifndef LIBID3TAG_VERSION_H -# define LIBID3TAG_VERSION_H - -# endif diff --git a/lib-src/libmad/CHANGES b/lib-src/libmad/CHANGES deleted file mode 100644 index 969451957..000000000 --- a/lib-src/libmad/CHANGES +++ /dev/null @@ -1,338 +0,0 @@ - - libmad - MPEG audio decoder library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: CHANGES,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - -=============================================================================== - -Version 0.15.1 (beta) - - * Updated to autoconf 2.59, automake 1.8.2, libtool 1.5.2. - - * Replaced Layer III IMDCT routine with one based on a faster algorithm, - improving both speed and accuracy. - - * Improved portability of the Huffman table initialization. - - * Fixed a problem that could result in an assertion failure in layer3.c - due to an invalid Layer III free format bitrate. - - * Improved the robustness of Layer II bitrate/mode combinations, and added - a new MAD_ERROR_BADMODE error enum. The allowability of low-bitrate - stereo streams is influenced by the --enable-strict-iso option to - `configure'. - -Version 0.15.0 (beta) - - * Updated to autoconf 2.57, automake 1.7.5, libtool 1.4.3. - - * Added new mad_f_div() API routine. - - * Added a 64th entry to the Layer I/Layer II scalefactor table, for better - compatibility with existing streams. The --enable-strict-iso option to - `configure' can be used to disable use of this entry. - - * Modified the header decoding routine to allow the reserved emphasis - value, for better compatibility with existing streams. The - --enable-strict-iso option to `configure' can be used to restore the - previous behavior of reporting this value as an error. - - * Added new MAD_EMPHASIS_RESERVED enumeration constant. - - * Fixed a bug in the ARM version of mad_f_scale64() discovered by Andre - McCurdy. - - * Rewrote PowerPC assembly for minor gains. - - * Modified mad_timer_fraction() to avoid the possibility of division by - zero when 0 is passed as the second argument. - - * Fixed a non-fatal problem caused by attempting to designate ancillary - bits in Layer III after a decoding error. - - * Changed to build a shared library by default. - - * Changed to use native Cygwin build by default; give --host=mingw32 to - `configure' to use MinGW (and avoid a dependency on the Cygwin DLL). - -Version 0.14.2 (beta) - - * Changed Cygwin builds to use MinGW; resulting Win32 executables no - longer have a dependency on Cygwin DLLs. - - * Added a new mad_stream_errorstr() API function to libmad for retrieving - a string description of the current error condition. - -Version 0.14.1 (beta) - - * Updated config.guess and config.sub to latest upstream versions. - - * Enabled libtool versioning rather than release numbering. - - * Improved the documentation in minimad.c. - - * Several other small fixes. - -Version 0.14.0 (beta) - - * Added a 64-bit FPM negation operation to improve performance of subband - synthesis on some platforms. - - * Improved MSVC++ portability and added MSVC++ project files. - - * Added rounding to Layer III requantization for slightly better accuracy. - -Version 0.13.0 (beta) - - * Ancillary data is now properly extracted from Layer III streams. - - * Rewrote the Layer III joint stereo decoding routine to correct a major - MPEG-2 problem and a minor MPEG-1 problem decoding intensity stereo. - - * Eliminated the dependency on sign-extending right shifts for Layer I and - Layer II. - - * Renamed `private' field to `private_bits' for better C++ compatibility. - - * Gratuitously renamed `sfreq' field to `samplerate' and - MAD_ERROR_BADSAMPLEFREQ constant to MAD_ERROR_BADSAMPLERATE. - - * Added `samplerate' and `channels' fields to synth.pcm struct to allow - these to be different from the decoded frame, and for simpler access. - - * Added new mad_stream_options() and mad_decoder_options() API entries for - special runtime decoding options. - - * Added new MAD_OPTION_IGNORECRC and MAD_OPTION_HALFSAMPLERATE options. - - * Added new MAD_FLAG_FREEFORMAT indicator flag. - - * Fixed some bugs in the async decoder. - - * Added a new mad_timer_multiply() API routine. - - * Eliminated `+' from asm constraints under Intel for better compatibility - with some compilers. - - * Fixed a PIC-related problem in imdct_l_arm.S. - - * Eliminated a static variable to make libmad thread-safe. - -Version 0.12.5 (beta) - - * Modified Layer III requantization to occur during Huffman decoding for - significant performance gains. - - * Optimized short block IMDCT by eliminating redundant calculations. - - * Made several other Layer III performance improvements; added - ASO_INTERLEAVE1, ASO_INTERLEAVE2, and ASO_ZEROCHECK - architecture-specific options for best performance on various - architectures. - - * Optimized synthesis DCT to store result values as soon as they are - calculated. - -Version 0.12.4 (beta) - - * New PowerPC fixed-point assembly courtesy of David Blythe. - - * Reorganized fixed-point assembly routines for easier maintenance and - better performance. - - * Improved performance of subband synthesis through better indexing and - fewer local variables. - - * Added alias reduction for the lower two subbands of mixed short blocks, - per a report of ambiguity with ISO/IEC 11172-3 and for uniformity with - most other implementations. Also improved alias reduction performance - using multiply/accumulate. - - * Added --enable-strict-iso option to `configure' to override best - accepted practices such as the alias reduction for mixed short blocks. - - * Improved performance of Layer III IMDCT by using longer - multiply/accumulate runs where possible. - -Version 0.12.3 (beta) - - * Added MPEG 2.5 support. - - * Added preliminary support for parameterizing the binary point position - in the fixed-point representation. - - * Added multiply/accumulate optimization to the Layer III IMDCT for long - blocks. - - * Fixed a bug in the handling of Layer III mixed_block_flag. - - * Fixed a configure problem when multiple -O CFLAGS are present. - -Version 0.12.2 (beta) - - * Rearranged the synthesis polyphase filterbank memory vector for better - locality of reference, and rewrote mad_synth_frame() to accommodate, - resulting in improved performance. - - * Discovered a combination of compiler optimization flags that further - improve performance. - - * Changed some array references in layer3.c to pointer derefs. - -Version 0.12.1 (beta) - - * Resolved the intensity + MS joint stereo issue (a simple bug). - OPT_ISKLUGE is no longer considered to be a kluge. - - * Fixed another, hopefully last main_data memory bug. - - * Split part of struct mad_frame into struct mad_header for convenience - and size. - -Version 0.12.0 (alpha) - - * Changed the build environment to use automake and libtool. A libmad - shared library can now be built using the --enable-shared option to - `configure'. - - * Added another callback to MAD's high-level decoder API after the frame - header has been read but before the frame's audio data is decoded. - - * Streamlined header processing so that mad_frame_decode() can be called - with or without having already called mad_frame_header(). - - * Fixed some other header reading miscellany, including CRC handling and - free bitrate detection, and frame length verification with free - bitrates. - - * Fixed a problem with Layer III free bitrates > 320 kbps. The main_data - buffer size should now be large enough to handle any size frame, by - virtue of the maximum possible part2_3_length. - - * Further developed the async API; arbitrary messages can now be passed to - the subsidiary decoding process. - - * Streamlined timer.c and extended its interface. It now has support for - video frame/field lengths, including output support for drop-frame - encoding. - - * Replaced many constant integer preprocessor defines with enums. - -Version 0.11.4 (beta) - - * Fixed free format bitrate discovery. - - * Changed the timer implementation and extended its interface. - - * Integrated Nicolas Pitre's patch for pre-shifting at compile-time and - for better multiply/accumulate code output. - - * Applied Simon Burge's patch to imdct_l_arm.S for a.out compatibility. - - * Added -mtune=strongarm for all ARM targets. - -Version 0.11.3 (beta) - - * Added new --enable-speed and --enable-accuracy options for `configure' - to automatically select appropriate SSO/ASO options, et al. - - * Modified subband synthesis to use multiply/accumulate optimization (if - available) for better speed and/or accuracy. - - * Incorporated Andre McCurdy's changes for further rounding optimizations - in the rest of his code. - -Version 0.11.2 (beta) - - * Incorporated Nicolas Pitre's ARM assembly and parameterized scaling - changes. - - * Incorporated Andre McCurdy's ARM assembly optimization (used only if - --enable-aso is given to `configure' to enable architecture-specific - optimizations.) - - * Reduced FPM_INTEL assembly to two instructions. - - * Fixed accuracy problems with certain FPM modes in synth.c. - - * Improved the accuracy of FPM_APPROX. - - * Improved the accuracy of SSO. - - * Improved sync discovery by checking for a sync word in the following - frame. - - * Minor code clean-up. - - * Added experimental rules for generating a libmad.so shared library. - -Version 0.11.1 (beta) - - * Moved libmad code into a separate directory. - - * Changed SSO to be disabled by default, as output accuracy is deemed to - be more important than speed in the general case. - - * Fixed a bug in Layer III sanity checking that could cause a crash on - certain random data input. - - * Extended the Layer III requantization table from 8191 to 8206 as some - encoders are known to use these values, even though ISO/IEC 11172-3 - suggests the maximum should be 8191. - -Version 0.11.0 (beta) - - * Implemented MPEG-2 extension to Lower Sampling Frequencies. - - * Improved Layer III performance by avoiding IMDCT calculation when all - input samples are zero. - - * Significantly reduced size of Layer II tables. - -Version 0.10.3 (beta) - - * Improved SSO output quality. - - * Made portable to cygwin. - - * Localized memory references in III_huffdecode() for better performance. - -Version 0.10.2 (beta) - - * Rewrote Layer III long block 36-point IMDCT routine for better - performance. - - * Improved subband synthesis fixed-point games somewhat. - -Version 0.10.1 (beta) - - * Added a subband synthesis optimization (SSO) which involves modifying - the fixed-point multiplication method during windowing. This produces - subtle differences in the output but improves performance greatly. - - * Added I_STEREO and MS_STEREO flags to frame struct. - - * Eliminated privately-used CRCFAILED flag. - - * Fixed a bug where Layer III decoding could crash on some badly-formatted - (e.g. non-MPEG) bitstreams. - - * Miscellaneous code clean-up. - -Version 0.10.0 (beta) - - * Added SPARC fixed-point math support. - - * Revamped libmad API for better high- and low-level support. - - * Documented more of the code. - - * Changed sync semantics such that new stream buffers are assumed to be - sync-aligned. - - * Changed Layer III to dynamically allocate static memory so as not to - waste it (about 6.4K) when only decoding Layer I or Layer II. - -=============================================================================== - diff --git a/lib-src/libmad/COPYING b/lib-src/libmad/COPYING deleted file mode 100644 index d60c31a97..000000000 --- a/lib-src/libmad/COPYING +++ /dev/null @@ -1,340 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc. - 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Library General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - - Gnomovision version 69, Copyright (C) year name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - , 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Library General -Public License instead of this License. diff --git a/lib-src/libmad/COPYRIGHT b/lib-src/libmad/COPYRIGHT deleted file mode 100644 index ed91d2bac..000000000 --- a/lib-src/libmad/COPYRIGHT +++ /dev/null @@ -1,21 +0,0 @@ - - libmad - MPEG audio decoder library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - If you would like to negotiate alternate licensing terms, you may do - so by contacting: Underbit Technologies, Inc. - diff --git a/lib-src/libmad/CREDITS b/lib-src/libmad/CREDITS deleted file mode 100644 index c860cd2d8..000000000 --- a/lib-src/libmad/CREDITS +++ /dev/null @@ -1,116 +0,0 @@ - - libmad - MPEG audio decoder library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: CREDITS,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - -=============================================================================== - -AUTHOR - - Except where otherwise noted, all code was authored by: - - Robert Leslie - -CONTRIBUTORS - - Significant contributions have been incorporated with thanks to: - - Anonymous - 2002/03/15: frame.c - - Reported problem with use of reserved emphasis value. - 2003/08/31: layer12.c - - Suggested support for certain disallowed bitrate/mode - combinations. - - Niek Albers - 2003/04/21: layer3.c - - Reported runtime uninitialized use of `ptr' in designating - ancillary bits after a decoding error. - - Christian Biere - 2003/02/01: frame.c - - Reported assertion failure in layer3.c due to an - invalid/unsupported Layer III free format bitrate. - - David Blythe - 2001/01/30: fixed.h - - Provided initial PowerPC fixed-point assembly. - - Simon Burge - 2000/09/20: imdct_l_arm.S - - Suggested patch for a.out compatibility. - - Brian Cameron - 2003/07/02: huffman.c - - Suggested changes for improved portability. - - Joshua Haberman - 2001/08/10: decoder.c, huffman.c - - Suggested portability fixes. - - Timothy King - 2002/05/04: sf_table.dat, layer12.c - - Reported problem with use of (missing) scalefactor index 63. - - Felix von Leitner - 2003/01/21: fixed.h - - Suggested Intel scaling alternative for possible speedup. - - Andre McCurdy - 2000/08/10: imdct_l_arm.S - - ARM optimized assembly replacement for III_imdct_l(). - 2000/09/15: imdct_l_arm.S - - Applied Nicolas Pitre's rounding optimisation in all remaining - places. - 2001/02/10: layer3.c - - Inspiration for Huffman decoding and requantization rewrite, and - other miscellany. - 2001/03/24: imdct_l_arm.S - - Corrected PIC unsafe code. - 2002/02/16: fixed.h - - Discovered bug in ARM version of mad_f_scale64(). - - Haruhiko OGASAWARA - 2001/01/28: layer3.c - - Reported discrepancy in alias reduction for mixed short blocks. - - Brett Paterson - 2001/10/28: global.h - - Reported missing et al. under MS Embedded Visual C. - - Sean 'Shaleh' Perry - 2000/04/04: fixed.h - - Suggested use of size-dependent typedefs. - 2001/10/22: config.guess, config.sub - - Keep up to date for proper Debian packaging. - - Bertrand Petit - 2001/11/05: synth.h - - Suggested PCM channel enumeration constants. - 2001/11/05: stream.h - - Suggested MAD_ERROR_NONE enumeration constant. - 2001/11/05: stream.c - - Suggested mad_stream_errorstr() function. - - Nicolas Pitre - 2000/09/09: fixed.h - - Parameterized all scaling for correct use of all multiplication - methods within mad_synth_frame(). - - Rewrote the FPM_ARM version of mad_f_mul() so we have 64-bit - multiplication result, rounding and scaling with 3 instructions. - 2000/09/09: imdct_l_arm.S - - Optimized rounding + scaling operations. - 2000/09/17: synth.c - - Changed D[] run-time shifts to compile-time. - - Modified synthesis for better multiply/accumulate code output. - 2001/08/11: fixed.h, synth.c - - Suggested 64-bit FPM negation and negative term factorization - during synthesis. - 2001/08/11: fixed.h - - Suggested unrounded behavior for FPM_DEFAULT when OPT_SPEED. - 2001/11/19: fixed.c - - Suggested computation of any resampling ratio. - -=============================================================================== - diff --git a/lib-src/libmad/D.dat b/lib-src/libmad/D.dat deleted file mode 100644 index f7820d728..000000000 --- a/lib-src/libmad/D.dat +++ /dev/null @@ -1,607 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: D.dat,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - */ - -/* - * These are the coefficients for the subband synthesis window. This is a - * reordered version of Table B.3 from ISO/IEC 11172-3. - * - * Every value is parameterized so that shift optimizations can be made at - * compile-time. For example, every value can be right-shifted 12 bits to - * minimize multiply instruction times without any loss of accuracy. - */ - - { PRESHIFT(0x00000000) /* 0.000000000 */, /* 0 */ - -PRESHIFT(0x0001d000) /* -0.000442505 */, - PRESHIFT(0x000d5000) /* 0.003250122 */, - -PRESHIFT(0x001cb000) /* -0.007003784 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - -PRESHIFT(0x01421000) /* -0.078628540 */, - PRESHIFT(0x019ae000) /* 0.100311279 */, - -PRESHIFT(0x09271000) /* -0.572036743 */, - PRESHIFT(0x1251e000) /* 1.144989014 */, - PRESHIFT(0x09271000) /* 0.572036743 */, - PRESHIFT(0x019ae000) /* 0.100311279 */, - PRESHIFT(0x01421000) /* 0.078628540 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - PRESHIFT(0x001cb000) /* 0.007003784 */, - PRESHIFT(0x000d5000) /* 0.003250122 */, - PRESHIFT(0x0001d000) /* 0.000442505 */, - - PRESHIFT(0x00000000) /* 0.000000000 */, - -PRESHIFT(0x0001d000) /* -0.000442505 */, - PRESHIFT(0x000d5000) /* 0.003250122 */, - -PRESHIFT(0x001cb000) /* -0.007003784 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - -PRESHIFT(0x01421000) /* -0.078628540 */, - PRESHIFT(0x019ae000) /* 0.100311279 */, - -PRESHIFT(0x09271000) /* -0.572036743 */, - PRESHIFT(0x1251e000) /* 1.144989014 */, - PRESHIFT(0x09271000) /* 0.572036743 */, - PRESHIFT(0x019ae000) /* 0.100311279 */, - PRESHIFT(0x01421000) /* 0.078628540 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - PRESHIFT(0x001cb000) /* 0.007003784 */, - PRESHIFT(0x000d5000) /* 0.003250122 */, - PRESHIFT(0x0001d000) /* 0.000442505 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 1 */ - -PRESHIFT(0x0001f000) /* -0.000473022 */, - PRESHIFT(0x000da000) /* 0.003326416 */, - -PRESHIFT(0x00207000) /* -0.007919312 */, - PRESHIFT(0x007d0000) /* 0.030517578 */, - -PRESHIFT(0x0158d000) /* -0.084182739 */, - PRESHIFT(0x01747000) /* 0.090927124 */, - -PRESHIFT(0x099a8000) /* -0.600219727 */, - PRESHIFT(0x124f0000) /* 1.144287109 */, - PRESHIFT(0x08b38000) /* 0.543823242 */, - PRESHIFT(0x01bde000) /* 0.108856201 */, - PRESHIFT(0x012b4000) /* 0.073059082 */, - PRESHIFT(0x0080f000) /* 0.031478882 */, - PRESHIFT(0x00191000) /* 0.006118774 */, - PRESHIFT(0x000d0000) /* 0.003173828 */, - PRESHIFT(0x0001a000) /* 0.000396729 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x0001f000) /* -0.000473022 */, - PRESHIFT(0x000da000) /* 0.003326416 */, - -PRESHIFT(0x00207000) /* -0.007919312 */, - PRESHIFT(0x007d0000) /* 0.030517578 */, - -PRESHIFT(0x0158d000) /* -0.084182739 */, - PRESHIFT(0x01747000) /* 0.090927124 */, - -PRESHIFT(0x099a8000) /* -0.600219727 */, - PRESHIFT(0x124f0000) /* 1.144287109 */, - PRESHIFT(0x08b38000) /* 0.543823242 */, - PRESHIFT(0x01bde000) /* 0.108856201 */, - PRESHIFT(0x012b4000) /* 0.073059082 */, - PRESHIFT(0x0080f000) /* 0.031478882 */, - PRESHIFT(0x00191000) /* 0.006118774 */, - PRESHIFT(0x000d0000) /* 0.003173828 */, - PRESHIFT(0x0001a000) /* 0.000396729 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 2 */ - -PRESHIFT(0x00023000) /* -0.000534058 */, - PRESHIFT(0x000de000) /* 0.003387451 */, - -PRESHIFT(0x00245000) /* -0.008865356 */, - PRESHIFT(0x007a0000) /* 0.029785156 */, - -PRESHIFT(0x016f7000) /* -0.089706421 */, - PRESHIFT(0x014a8000) /* 0.080688477 */, - -PRESHIFT(0x0a0d8000) /* -0.628295898 */, - PRESHIFT(0x12468000) /* 1.142211914 */, - PRESHIFT(0x083ff000) /* 0.515609741 */, - PRESHIFT(0x01dd8000) /* 0.116577148 */, - PRESHIFT(0x01149000) /* 0.067520142 */, - PRESHIFT(0x00820000) /* 0.031738281 */, - PRESHIFT(0x0015b000) /* 0.005294800 */, - PRESHIFT(0x000ca000) /* 0.003082275 */, - PRESHIFT(0x00018000) /* 0.000366211 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x00023000) /* -0.000534058 */, - PRESHIFT(0x000de000) /* 0.003387451 */, - -PRESHIFT(0x00245000) /* -0.008865356 */, - PRESHIFT(0x007a0000) /* 0.029785156 */, - -PRESHIFT(0x016f7000) /* -0.089706421 */, - PRESHIFT(0x014a8000) /* 0.080688477 */, - -PRESHIFT(0x0a0d8000) /* -0.628295898 */, - PRESHIFT(0x12468000) /* 1.142211914 */, - PRESHIFT(0x083ff000) /* 0.515609741 */, - PRESHIFT(0x01dd8000) /* 0.116577148 */, - PRESHIFT(0x01149000) /* 0.067520142 */, - PRESHIFT(0x00820000) /* 0.031738281 */, - PRESHIFT(0x0015b000) /* 0.005294800 */, - PRESHIFT(0x000ca000) /* 0.003082275 */, - PRESHIFT(0x00018000) /* 0.000366211 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 3 */ - -PRESHIFT(0x00026000) /* -0.000579834 */, - PRESHIFT(0x000e1000) /* 0.003433228 */, - -PRESHIFT(0x00285000) /* -0.009841919 */, - PRESHIFT(0x00765000) /* 0.028884888 */, - -PRESHIFT(0x0185d000) /* -0.095169067 */, - PRESHIFT(0x011d1000) /* 0.069595337 */, - -PRESHIFT(0x0a7fe000) /* -0.656219482 */, - PRESHIFT(0x12386000) /* 1.138763428 */, - PRESHIFT(0x07ccb000) /* 0.487472534 */, - PRESHIFT(0x01f9c000) /* 0.123474121 */, - PRESHIFT(0x00fdf000) /* 0.061996460 */, - PRESHIFT(0x00827000) /* 0.031845093 */, - PRESHIFT(0x00126000) /* 0.004486084 */, - PRESHIFT(0x000c4000) /* 0.002990723 */, - PRESHIFT(0x00015000) /* 0.000320435 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x00026000) /* -0.000579834 */, - PRESHIFT(0x000e1000) /* 0.003433228 */, - -PRESHIFT(0x00285000) /* -0.009841919 */, - PRESHIFT(0x00765000) /* 0.028884888 */, - -PRESHIFT(0x0185d000) /* -0.095169067 */, - PRESHIFT(0x011d1000) /* 0.069595337 */, - -PRESHIFT(0x0a7fe000) /* -0.656219482 */, - PRESHIFT(0x12386000) /* 1.138763428 */, - PRESHIFT(0x07ccb000) /* 0.487472534 */, - PRESHIFT(0x01f9c000) /* 0.123474121 */, - PRESHIFT(0x00fdf000) /* 0.061996460 */, - PRESHIFT(0x00827000) /* 0.031845093 */, - PRESHIFT(0x00126000) /* 0.004486084 */, - PRESHIFT(0x000c4000) /* 0.002990723 */, - PRESHIFT(0x00015000) /* 0.000320435 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 4 */ - -PRESHIFT(0x00029000) /* -0.000625610 */, - PRESHIFT(0x000e3000) /* 0.003463745 */, - -PRESHIFT(0x002c7000) /* -0.010848999 */, - PRESHIFT(0x0071e000) /* 0.027801514 */, - -PRESHIFT(0x019bd000) /* -0.100540161 */, - PRESHIFT(0x00ec0000) /* 0.057617187 */, - -PRESHIFT(0x0af15000) /* -0.683914185 */, - PRESHIFT(0x12249000) /* 1.133926392 */, - PRESHIFT(0x075a0000) /* 0.459472656 */, - PRESHIFT(0x0212c000) /* 0.129577637 */, - PRESHIFT(0x00e79000) /* 0.056533813 */, - PRESHIFT(0x00825000) /* 0.031814575 */, - PRESHIFT(0x000f4000) /* 0.003723145 */, - PRESHIFT(0x000be000) /* 0.002899170 */, - PRESHIFT(0x00013000) /* 0.000289917 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x00029000) /* -0.000625610 */, - PRESHIFT(0x000e3000) /* 0.003463745 */, - -PRESHIFT(0x002c7000) /* -0.010848999 */, - PRESHIFT(0x0071e000) /* 0.027801514 */, - -PRESHIFT(0x019bd000) /* -0.100540161 */, - PRESHIFT(0x00ec0000) /* 0.057617187 */, - -PRESHIFT(0x0af15000) /* -0.683914185 */, - PRESHIFT(0x12249000) /* 1.133926392 */, - PRESHIFT(0x075a0000) /* 0.459472656 */, - PRESHIFT(0x0212c000) /* 0.129577637 */, - PRESHIFT(0x00e79000) /* 0.056533813 */, - PRESHIFT(0x00825000) /* 0.031814575 */, - PRESHIFT(0x000f4000) /* 0.003723145 */, - PRESHIFT(0x000be000) /* 0.002899170 */, - PRESHIFT(0x00013000) /* 0.000289917 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 5 */ - -PRESHIFT(0x0002d000) /* -0.000686646 */, - PRESHIFT(0x000e4000) /* 0.003479004 */, - -PRESHIFT(0x0030b000) /* -0.011886597 */, - PRESHIFT(0x006cb000) /* 0.026535034 */, - -PRESHIFT(0x01b17000) /* -0.105819702 */, - PRESHIFT(0x00b77000) /* 0.044784546 */, - -PRESHIFT(0x0b619000) /* -0.711318970 */, - PRESHIFT(0x120b4000) /* 1.127746582 */, - PRESHIFT(0x06e81000) /* 0.431655884 */, - PRESHIFT(0x02288000) /* 0.134887695 */, - PRESHIFT(0x00d17000) /* 0.051132202 */, - PRESHIFT(0x0081b000) /* 0.031661987 */, - PRESHIFT(0x000c5000) /* 0.003005981 */, - PRESHIFT(0x000b7000) /* 0.002792358 */, - PRESHIFT(0x00011000) /* 0.000259399 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x0002d000) /* -0.000686646 */, - PRESHIFT(0x000e4000) /* 0.003479004 */, - -PRESHIFT(0x0030b000) /* -0.011886597 */, - PRESHIFT(0x006cb000) /* 0.026535034 */, - -PRESHIFT(0x01b17000) /* -0.105819702 */, - PRESHIFT(0x00b77000) /* 0.044784546 */, - -PRESHIFT(0x0b619000) /* -0.711318970 */, - PRESHIFT(0x120b4000) /* 1.127746582 */, - PRESHIFT(0x06e81000) /* 0.431655884 */, - PRESHIFT(0x02288000) /* 0.134887695 */, - PRESHIFT(0x00d17000) /* 0.051132202 */, - PRESHIFT(0x0081b000) /* 0.031661987 */, - PRESHIFT(0x000c5000) /* 0.003005981 */, - PRESHIFT(0x000b7000) /* 0.002792358 */, - PRESHIFT(0x00011000) /* 0.000259399 */ }, - - { -PRESHIFT(0x00001000) /* -0.000015259 */, /* 6 */ - -PRESHIFT(0x00031000) /* -0.000747681 */, - PRESHIFT(0x000e4000) /* 0.003479004 */, - -PRESHIFT(0x00350000) /* -0.012939453 */, - PRESHIFT(0x0066c000) /* 0.025085449 */, - -PRESHIFT(0x01c67000) /* -0.110946655 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - -PRESHIFT(0x0bd06000) /* -0.738372803 */, - PRESHIFT(0x11ec7000) /* 1.120223999 */, - PRESHIFT(0x06772000) /* 0.404083252 */, - PRESHIFT(0x023b3000) /* 0.139450073 */, - PRESHIFT(0x00bbc000) /* 0.045837402 */, - PRESHIFT(0x00809000) /* 0.031387329 */, - PRESHIFT(0x00099000) /* 0.002334595 */, - PRESHIFT(0x000b0000) /* 0.002685547 */, - PRESHIFT(0x00010000) /* 0.000244141 */, - - -PRESHIFT(0x00001000) /* -0.000015259 */, - -PRESHIFT(0x00031000) /* -0.000747681 */, - PRESHIFT(0x000e4000) /* 0.003479004 */, - -PRESHIFT(0x00350000) /* -0.012939453 */, - PRESHIFT(0x0066c000) /* 0.025085449 */, - -PRESHIFT(0x01c67000) /* -0.110946655 */, - PRESHIFT(0x007f5000) /* 0.031082153 */, - -PRESHIFT(0x0bd06000) /* -0.738372803 */, - PRESHIFT(0x11ec7000) /* 1.120223999 */, - PRESHIFT(0x06772000) /* 0.404083252 */, - PRESHIFT(0x023b3000) /* 0.139450073 */, - PRESHIFT(0x00bbc000) /* 0.045837402 */, - PRESHIFT(0x00809000) /* 0.031387329 */, - PRESHIFT(0x00099000) /* 0.002334595 */, - PRESHIFT(0x000b0000) /* 0.002685547 */, - PRESHIFT(0x00010000) /* 0.000244141 */ }, - - { -PRESHIFT(0x00002000) /* -0.000030518 */, /* 7 */ - -PRESHIFT(0x00035000) /* -0.000808716 */, - PRESHIFT(0x000e3000) /* 0.003463745 */, - -PRESHIFT(0x00397000) /* -0.014022827 */, - PRESHIFT(0x005ff000) /* 0.023422241 */, - -PRESHIFT(0x01dad000) /* -0.115921021 */, - PRESHIFT(0x0043a000) /* 0.016510010 */, - -PRESHIFT(0x0c3d9000) /* -0.765029907 */, - PRESHIFT(0x11c83000) /* 1.111373901 */, - PRESHIFT(0x06076000) /* 0.376800537 */, - PRESHIFT(0x024ad000) /* 0.143264771 */, - PRESHIFT(0x00a67000) /* 0.040634155 */, - PRESHIFT(0x007f0000) /* 0.031005859 */, - PRESHIFT(0x0006f000) /* 0.001693726 */, - PRESHIFT(0x000a9000) /* 0.002578735 */, - PRESHIFT(0x0000e000) /* 0.000213623 */, - - -PRESHIFT(0x00002000) /* -0.000030518 */, - -PRESHIFT(0x00035000) /* -0.000808716 */, - PRESHIFT(0x000e3000) /* 0.003463745 */, - -PRESHIFT(0x00397000) /* -0.014022827 */, - PRESHIFT(0x005ff000) /* 0.023422241 */, - -PRESHIFT(0x01dad000) /* -0.115921021 */, - PRESHIFT(0x0043a000) /* 0.016510010 */, - -PRESHIFT(0x0c3d9000) /* -0.765029907 */, - PRESHIFT(0x11c83000) /* 1.111373901 */, - PRESHIFT(0x06076000) /* 0.376800537 */, - PRESHIFT(0x024ad000) /* 0.143264771 */, - PRESHIFT(0x00a67000) /* 0.040634155 */, - PRESHIFT(0x007f0000) /* 0.031005859 */, - PRESHIFT(0x0006f000) /* 0.001693726 */, - PRESHIFT(0x000a9000) /* 0.002578735 */, - PRESHIFT(0x0000e000) /* 0.000213623 */ }, - - { -PRESHIFT(0x00002000) /* -0.000030518 */, /* 8 */ - -PRESHIFT(0x0003a000) /* -0.000885010 */, - PRESHIFT(0x000e0000) /* 0.003417969 */, - -PRESHIFT(0x003df000) /* -0.015121460 */, - PRESHIFT(0x00586000) /* 0.021575928 */, - -PRESHIFT(0x01ee6000) /* -0.120697021 */, - PRESHIFT(0x00046000) /* 0.001068115 */, - -PRESHIFT(0x0ca8d000) /* -0.791213989 */, - PRESHIFT(0x119e9000) /* 1.101211548 */, - PRESHIFT(0x05991000) /* 0.349868774 */, - PRESHIFT(0x02578000) /* 0.146362305 */, - PRESHIFT(0x0091a000) /* 0.035552979 */, - PRESHIFT(0x007d1000) /* 0.030532837 */, - PRESHIFT(0x00048000) /* 0.001098633 */, - PRESHIFT(0x000a1000) /* 0.002456665 */, - PRESHIFT(0x0000d000) /* 0.000198364 */, - - -PRESHIFT(0x00002000) /* -0.000030518 */, - -PRESHIFT(0x0003a000) /* -0.000885010 */, - PRESHIFT(0x000e0000) /* 0.003417969 */, - -PRESHIFT(0x003df000) /* -0.015121460 */, - PRESHIFT(0x00586000) /* 0.021575928 */, - -PRESHIFT(0x01ee6000) /* -0.120697021 */, - PRESHIFT(0x00046000) /* 0.001068115 */, - -PRESHIFT(0x0ca8d000) /* -0.791213989 */, - PRESHIFT(0x119e9000) /* 1.101211548 */, - PRESHIFT(0x05991000) /* 0.349868774 */, - PRESHIFT(0x02578000) /* 0.146362305 */, - PRESHIFT(0x0091a000) /* 0.035552979 */, - PRESHIFT(0x007d1000) /* 0.030532837 */, - PRESHIFT(0x00048000) /* 0.001098633 */, - PRESHIFT(0x000a1000) /* 0.002456665 */, - PRESHIFT(0x0000d000) /* 0.000198364 */ }, - - { -PRESHIFT(0x00002000) /* -0.000030518 */, /* 9 */ - -PRESHIFT(0x0003f000) /* -0.000961304 */, - PRESHIFT(0x000dd000) /* 0.003372192 */, - -PRESHIFT(0x00428000) /* -0.016235352 */, - PRESHIFT(0x00500000) /* 0.019531250 */, - -PRESHIFT(0x02011000) /* -0.125259399 */, - -PRESHIFT(0x003e6000) /* -0.015228271 */, - -PRESHIFT(0x0d11e000) /* -0.816864014 */, - PRESHIFT(0x116fc000) /* 1.089782715 */, - PRESHIFT(0x052c5000) /* 0.323318481 */, - PRESHIFT(0x02616000) /* 0.148773193 */, - PRESHIFT(0x007d6000) /* 0.030609131 */, - PRESHIFT(0x007aa000) /* 0.029937744 */, - PRESHIFT(0x00024000) /* 0.000549316 */, - PRESHIFT(0x0009a000) /* 0.002349854 */, - PRESHIFT(0x0000b000) /* 0.000167847 */, - - -PRESHIFT(0x00002000) /* -0.000030518 */, - -PRESHIFT(0x0003f000) /* -0.000961304 */, - PRESHIFT(0x000dd000) /* 0.003372192 */, - -PRESHIFT(0x00428000) /* -0.016235352 */, - PRESHIFT(0x00500000) /* 0.019531250 */, - -PRESHIFT(0x02011000) /* -0.125259399 */, - -PRESHIFT(0x003e6000) /* -0.015228271 */, - -PRESHIFT(0x0d11e000) /* -0.816864014 */, - PRESHIFT(0x116fc000) /* 1.089782715 */, - PRESHIFT(0x052c5000) /* 0.323318481 */, - PRESHIFT(0x02616000) /* 0.148773193 */, - PRESHIFT(0x007d6000) /* 0.030609131 */, - PRESHIFT(0x007aa000) /* 0.029937744 */, - PRESHIFT(0x00024000) /* 0.000549316 */, - PRESHIFT(0x0009a000) /* 0.002349854 */, - PRESHIFT(0x0000b000) /* 0.000167847 */ }, - - { -PRESHIFT(0x00002000) /* -0.000030518 */, /* 10 */ - -PRESHIFT(0x00044000) /* -0.001037598 */, - PRESHIFT(0x000d7000) /* 0.003280640 */, - -PRESHIFT(0x00471000) /* -0.017349243 */, - PRESHIFT(0x0046b000) /* 0.017257690 */, - -PRESHIFT(0x0212b000) /* -0.129562378 */, - -PRESHIFT(0x0084a000) /* -0.032379150 */, - -PRESHIFT(0x0d78a000) /* -0.841949463 */, - PRESHIFT(0x113be000) /* 1.077117920 */, - PRESHIFT(0x04c16000) /* 0.297210693 */, - PRESHIFT(0x02687000) /* 0.150497437 */, - PRESHIFT(0x0069c000) /* 0.025817871 */, - PRESHIFT(0x0077f000) /* 0.029281616 */, - PRESHIFT(0x00002000) /* 0.000030518 */, - PRESHIFT(0x00093000) /* 0.002243042 */, - PRESHIFT(0x0000a000) /* 0.000152588 */, - - -PRESHIFT(0x00002000) /* -0.000030518 */, - -PRESHIFT(0x00044000) /* -0.001037598 */, - PRESHIFT(0x000d7000) /* 0.003280640 */, - -PRESHIFT(0x00471000) /* -0.017349243 */, - PRESHIFT(0x0046b000) /* 0.017257690 */, - -PRESHIFT(0x0212b000) /* -0.129562378 */, - -PRESHIFT(0x0084a000) /* -0.032379150 */, - -PRESHIFT(0x0d78a000) /* -0.841949463 */, - PRESHIFT(0x113be000) /* 1.077117920 */, - PRESHIFT(0x04c16000) /* 0.297210693 */, - PRESHIFT(0x02687000) /* 0.150497437 */, - PRESHIFT(0x0069c000) /* 0.025817871 */, - PRESHIFT(0x0077f000) /* 0.029281616 */, - PRESHIFT(0x00002000) /* 0.000030518 */, - PRESHIFT(0x00093000) /* 0.002243042 */, - PRESHIFT(0x0000a000) /* 0.000152588 */ }, - - { -PRESHIFT(0x00003000) /* -0.000045776 */, /* 11 */ - -PRESHIFT(0x00049000) /* -0.001113892 */, - PRESHIFT(0x000d0000) /* 0.003173828 */, - -PRESHIFT(0x004ba000) /* -0.018463135 */, - PRESHIFT(0x003ca000) /* 0.014801025 */, - -PRESHIFT(0x02233000) /* -0.133590698 */, - -PRESHIFT(0x00ce4000) /* -0.050354004 */, - -PRESHIFT(0x0ddca000) /* -0.866363525 */, - PRESHIFT(0x1102f000) /* 1.063217163 */, - PRESHIFT(0x04587000) /* 0.271591187 */, - PRESHIFT(0x026cf000) /* 0.151596069 */, - PRESHIFT(0x0056c000) /* 0.021179199 */, - PRESHIFT(0x0074e000) /* 0.028533936 */, - -PRESHIFT(0x0001d000) /* -0.000442505 */, - PRESHIFT(0x0008b000) /* 0.002120972 */, - PRESHIFT(0x00009000) /* 0.000137329 */, - - -PRESHIFT(0x00003000) /* -0.000045776 */, - -PRESHIFT(0x00049000) /* -0.001113892 */, - PRESHIFT(0x000d0000) /* 0.003173828 */, - -PRESHIFT(0x004ba000) /* -0.018463135 */, - PRESHIFT(0x003ca000) /* 0.014801025 */, - -PRESHIFT(0x02233000) /* -0.133590698 */, - -PRESHIFT(0x00ce4000) /* -0.050354004 */, - -PRESHIFT(0x0ddca000) /* -0.866363525 */, - PRESHIFT(0x1102f000) /* 1.063217163 */, - PRESHIFT(0x04587000) /* 0.271591187 */, - PRESHIFT(0x026cf000) /* 0.151596069 */, - PRESHIFT(0x0056c000) /* 0.021179199 */, - PRESHIFT(0x0074e000) /* 0.028533936 */, - -PRESHIFT(0x0001d000) /* -0.000442505 */, - PRESHIFT(0x0008b000) /* 0.002120972 */, - PRESHIFT(0x00009000) /* 0.000137329 */ }, - - { -PRESHIFT(0x00003000) /* -0.000045776 */, /* 12 */ - -PRESHIFT(0x0004f000) /* -0.001205444 */, - PRESHIFT(0x000c8000) /* 0.003051758 */, - -PRESHIFT(0x00503000) /* -0.019577026 */, - PRESHIFT(0x0031a000) /* 0.012115479 */, - -PRESHIFT(0x02326000) /* -0.137298584 */, - -PRESHIFT(0x011b5000) /* -0.069168091 */, - -PRESHIFT(0x0e3dd000) /* -0.890090942 */, - PRESHIFT(0x10c54000) /* 1.048156738 */, - PRESHIFT(0x03f1b000) /* 0.246505737 */, - PRESHIFT(0x026ee000) /* 0.152069092 */, - PRESHIFT(0x00447000) /* 0.016708374 */, - PRESHIFT(0x00719000) /* 0.027725220 */, - -PRESHIFT(0x00039000) /* -0.000869751 */, - PRESHIFT(0x00084000) /* 0.002014160 */, - PRESHIFT(0x00008000) /* 0.000122070 */, - - -PRESHIFT(0x00003000) /* -0.000045776 */, - -PRESHIFT(0x0004f000) /* -0.001205444 */, - PRESHIFT(0x000c8000) /* 0.003051758 */, - -PRESHIFT(0x00503000) /* -0.019577026 */, - PRESHIFT(0x0031a000) /* 0.012115479 */, - -PRESHIFT(0x02326000) /* -0.137298584 */, - -PRESHIFT(0x011b5000) /* -0.069168091 */, - -PRESHIFT(0x0e3dd000) /* -0.890090942 */, - PRESHIFT(0x10c54000) /* 1.048156738 */, - PRESHIFT(0x03f1b000) /* 0.246505737 */, - PRESHIFT(0x026ee000) /* 0.152069092 */, - PRESHIFT(0x00447000) /* 0.016708374 */, - PRESHIFT(0x00719000) /* 0.027725220 */, - -PRESHIFT(0x00039000) /* -0.000869751 */, - PRESHIFT(0x00084000) /* 0.002014160 */, - PRESHIFT(0x00008000) /* 0.000122070 */ }, - - { -PRESHIFT(0x00004000) /* -0.000061035 */, /* 13 */ - -PRESHIFT(0x00055000) /* -0.001296997 */, - PRESHIFT(0x000bd000) /* 0.002883911 */, - -PRESHIFT(0x0054c000) /* -0.020690918 */, - PRESHIFT(0x0025d000) /* 0.009231567 */, - -PRESHIFT(0x02403000) /* -0.140670776 */, - -PRESHIFT(0x016ba000) /* -0.088775635 */, - -PRESHIFT(0x0e9be000) /* -0.913055420 */, - PRESHIFT(0x1082d000) /* 1.031936646 */, - PRESHIFT(0x038d4000) /* 0.221984863 */, - PRESHIFT(0x026e7000) /* 0.151962280 */, - PRESHIFT(0x0032e000) /* 0.012420654 */, - PRESHIFT(0x006df000) /* 0.026840210 */, - -PRESHIFT(0x00053000) /* -0.001266479 */, - PRESHIFT(0x0007d000) /* 0.001907349 */, - PRESHIFT(0x00007000) /* 0.000106812 */, - - -PRESHIFT(0x00004000) /* -0.000061035 */, - -PRESHIFT(0x00055000) /* -0.001296997 */, - PRESHIFT(0x000bd000) /* 0.002883911 */, - -PRESHIFT(0x0054c000) /* -0.020690918 */, - PRESHIFT(0x0025d000) /* 0.009231567 */, - -PRESHIFT(0x02403000) /* -0.140670776 */, - -PRESHIFT(0x016ba000) /* -0.088775635 */, - -PRESHIFT(0x0e9be000) /* -0.913055420 */, - PRESHIFT(0x1082d000) /* 1.031936646 */, - PRESHIFT(0x038d4000) /* 0.221984863 */, - PRESHIFT(0x026e7000) /* 0.151962280 */, - PRESHIFT(0x0032e000) /* 0.012420654 */, - PRESHIFT(0x006df000) /* 0.026840210 */, - -PRESHIFT(0x00053000) /* -0.001266479 */, - PRESHIFT(0x0007d000) /* 0.001907349 */, - PRESHIFT(0x00007000) /* 0.000106812 */ }, - - { -PRESHIFT(0x00004000) /* -0.000061035 */, /* 14 */ - -PRESHIFT(0x0005b000) /* -0.001388550 */, - PRESHIFT(0x000b1000) /* 0.002700806 */, - -PRESHIFT(0x00594000) /* -0.021789551 */, - PRESHIFT(0x00192000) /* 0.006134033 */, - -PRESHIFT(0x024c8000) /* -0.143676758 */, - -PRESHIFT(0x01bf2000) /* -0.109161377 */, - -PRESHIFT(0x0ef69000) /* -0.935195923 */, - PRESHIFT(0x103be000) /* 1.014617920 */, - PRESHIFT(0x032b4000) /* 0.198059082 */, - PRESHIFT(0x026bc000) /* 0.151306152 */, - PRESHIFT(0x00221000) /* 0.008316040 */, - PRESHIFT(0x006a2000) /* 0.025909424 */, - -PRESHIFT(0x0006a000) /* -0.001617432 */, - PRESHIFT(0x00075000) /* 0.001785278 */, - PRESHIFT(0x00007000) /* 0.000106812 */, - - -PRESHIFT(0x00004000) /* -0.000061035 */, - -PRESHIFT(0x0005b000) /* -0.001388550 */, - PRESHIFT(0x000b1000) /* 0.002700806 */, - -PRESHIFT(0x00594000) /* -0.021789551 */, - PRESHIFT(0x00192000) /* 0.006134033 */, - -PRESHIFT(0x024c8000) /* -0.143676758 */, - -PRESHIFT(0x01bf2000) /* -0.109161377 */, - -PRESHIFT(0x0ef69000) /* -0.935195923 */, - PRESHIFT(0x103be000) /* 1.014617920 */, - PRESHIFT(0x032b4000) /* 0.198059082 */, - PRESHIFT(0x026bc000) /* 0.151306152 */, - PRESHIFT(0x00221000) /* 0.008316040 */, - PRESHIFT(0x006a2000) /* 0.025909424 */, - -PRESHIFT(0x0006a000) /* -0.001617432 */, - PRESHIFT(0x00075000) /* 0.001785278 */, - PRESHIFT(0x00007000) /* 0.000106812 */ }, - - { -PRESHIFT(0x00005000) /* -0.000076294 */, /* 15 */ - -PRESHIFT(0x00061000) /* -0.001480103 */, - PRESHIFT(0x000a3000) /* 0.002487183 */, - -PRESHIFT(0x005da000) /* -0.022857666 */, - PRESHIFT(0x000b9000) /* 0.002822876 */, - -PRESHIFT(0x02571000) /* -0.146255493 */, - -PRESHIFT(0x0215c000) /* -0.130310059 */, - -PRESHIFT(0x0f4dc000) /* -0.956481934 */, - PRESHIFT(0x0ff0a000) /* 0.996246338 */, - PRESHIFT(0x02cbf000) /* 0.174789429 */, - PRESHIFT(0x0266e000) /* 0.150115967 */, - PRESHIFT(0x00120000) /* 0.004394531 */, - PRESHIFT(0x00662000) /* 0.024932861 */, - -PRESHIFT(0x0007f000) /* -0.001937866 */, - PRESHIFT(0x0006f000) /* 0.001693726 */, - PRESHIFT(0x00006000) /* 0.000091553 */, - - -PRESHIFT(0x00005000) /* -0.000076294 */, - -PRESHIFT(0x00061000) /* -0.001480103 */, - PRESHIFT(0x000a3000) /* 0.002487183 */, - -PRESHIFT(0x005da000) /* -0.022857666 */, - PRESHIFT(0x000b9000) /* 0.002822876 */, - -PRESHIFT(0x02571000) /* -0.146255493 */, - -PRESHIFT(0x0215c000) /* -0.130310059 */, - -PRESHIFT(0x0f4dc000) /* -0.956481934 */, - PRESHIFT(0x0ff0a000) /* 0.996246338 */, - PRESHIFT(0x02cbf000) /* 0.174789429 */, - PRESHIFT(0x0266e000) /* 0.150115967 */, - PRESHIFT(0x00120000) /* 0.004394531 */, - PRESHIFT(0x00662000) /* 0.024932861 */, - -PRESHIFT(0x0007f000) /* -0.001937866 */, - PRESHIFT(0x0006f000) /* 0.001693726 */, - PRESHIFT(0x00006000) /* 0.000091553 */ }, - - { -PRESHIFT(0x00005000) /* -0.000076294 */, /* 16 */ - -PRESHIFT(0x00068000) /* -0.001586914 */, - PRESHIFT(0x00092000) /* 0.002227783 */, - -PRESHIFT(0x0061f000) /* -0.023910522 */, - -PRESHIFT(0x0002d000) /* -0.000686646 */, - -PRESHIFT(0x025ff000) /* -0.148422241 */, - -PRESHIFT(0x026f7000) /* -0.152206421 */, - -PRESHIFT(0x0fa13000) /* -0.976852417 */, - PRESHIFT(0x0fa13000) /* 0.976852417 */, - PRESHIFT(0x026f7000) /* 0.152206421 */, - PRESHIFT(0x025ff000) /* 0.148422241 */, - PRESHIFT(0x0002d000) /* 0.000686646 */, - PRESHIFT(0x0061f000) /* 0.023910522 */, - -PRESHIFT(0x00092000) /* -0.002227783 */, - PRESHIFT(0x00068000) /* 0.001586914 */, - PRESHIFT(0x00005000) /* 0.000076294 */, - - -PRESHIFT(0x00005000) /* -0.000076294 */, - -PRESHIFT(0x00068000) /* -0.001586914 */, - PRESHIFT(0x00092000) /* 0.002227783 */, - -PRESHIFT(0x0061f000) /* -0.023910522 */, - -PRESHIFT(0x0002d000) /* -0.000686646 */, - -PRESHIFT(0x025ff000) /* -0.148422241 */, - -PRESHIFT(0x026f7000) /* -0.152206421 */, - -PRESHIFT(0x0fa13000) /* -0.976852417 */, - PRESHIFT(0x0fa13000) /* 0.976852417 */, - PRESHIFT(0x026f7000) /* 0.152206421 */, - PRESHIFT(0x025ff000) /* 0.148422241 */, - PRESHIFT(0x0002d000) /* 0.000686646 */, - PRESHIFT(0x0061f000) /* 0.023910522 */, - -PRESHIFT(0x00092000) /* -0.002227783 */, - PRESHIFT(0x00068000) /* 0.001586914 */, - PRESHIFT(0x00005000) /* 0.000076294 */ } diff --git a/lib-src/libmad/INSTALL b/lib-src/libmad/INSTALL deleted file mode 100644 index 50dbe439d..000000000 --- a/lib-src/libmad/INSTALL +++ /dev/null @@ -1,183 +0,0 @@ -Basic Installation -================== - - These are generic installation instructions. - - The `configure' shell script attempts to guess correct values for -various system-dependent variables used during compilation. It uses -those values to create a `Makefile' in each directory of the package. -It may also create one or more `.h' files containing system-dependent -definitions. Finally, it creates a shell script `config.status' that -you can run in the future to recreate the current configuration, a file -`config.cache' that saves the results of its tests to speed up -reconfiguring, and a file `config.log' containing compiler output -(useful mainly for debugging `configure'). - - If you need to do unusual things to compile the package, please try -to figure out how `configure' could check whether to do them, and mail -diffs or instructions to the address given in the `README' so they can -be considered for the next release. If at some point `config.cache' -contains results you don't want to keep, you may remove or edit it. - - The file `configure.in' is used to create `configure' by a program -called `autoconf'. You only need `configure.in' if you want to change -it or regenerate `configure' using a newer version of `autoconf'. - -The simplest way to compile this package is: - - 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. If you're - using `csh' on an old version of System V, you might need to type - `sh ./configure' instead to prevent `csh' from trying to execute - `configure' itself. - - Running `configure' takes awhile. While running, it prints some - messages telling which features it is checking for. - - 2. Type `make' to compile the package. - - 3. Optionally, type `make check' to run any self-tests that come with - the package. - - 4. Type `make install' to install the programs and any data files and - documentation. - - 5. You can remove the program binaries and object files from the - source code directory by typing `make clean'. To also remove the - files that `configure' created (so you can compile the package for - a different kind of computer), type `make distclean'. There is - also a `make maintainer-clean' target, but that is intended mainly - for the package's developers. If you use it, you may have to get - all sorts of other programs in order to regenerate files that came - with the distribution. - -Compilers and Options -===================== - - Some systems require unusual options for compilation or linking that -the `configure' script does not know about. You can give `configure' -initial values for variables by setting them in the environment. Using -a Bourne-compatible shell, you can do that on the command line like -this: - CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure - -Or on systems that have the `env' program, you can do it like this: - env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure - -Compiling For Multiple Architectures -==================================== - - You can compile the package for more than one kind of computer at the -same time, by placing the object files for each architecture in their -own directory. To do this, you must use a version of `make' that -supports the `VPATH' variable, such as GNU `make'. `cd' to the -directory where you want the object files and executables to go and run -the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. - - If you have to use a `make' that does not supports the `VPATH' -variable, you have to compile the package for one architecture at a time -in the source code directory. After you have installed the package for -one architecture, use `make distclean' before reconfiguring for another -architecture. - -Installation Names -================== - - By default, `make install' will install the package's files in -`/usr/local/bin', `/usr/local/man', etc. You can specify an -installation prefix other than `/usr/local' by giving `configure' the -option `--prefix=PATH'. - - You can specify separate installation prefixes for -architecture-specific files and architecture-independent files. If you -give `configure' the option `--exec-prefix=PATH', the package will use -PATH as the prefix for installing programs and libraries. -Documentation and other data files will still use the regular prefix. - - In addition, if you use an unusual directory layout you can give -options like `--bindir=PATH' to specify different values for particular -kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. - - If the package supports it, you can cause programs to be installed -with an extra prefix or suffix on their names by giving `configure' the -option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. - -Optional Features -================= - - Some packages pay attention to `--enable-FEATURE' options to -`configure', where FEATURE indicates an optional part of the package. -They may also pay attention to `--with-PACKAGE' options, where PACKAGE -is something like `gnu-as' or `x' (for the X Window System). The -`README' should mention any `--enable-' and `--with-' options that the -package recognizes. - - For packages that use the X Window System, `configure' can usually -find the X include and library files automatically, but if it doesn't, -you can use the `configure' options `--x-includes=DIR' and -`--x-libraries=DIR' to specify their locations. - -Specifying the System Type -========================== - - There may be some features `configure' can not figure out -automatically, but needs to determine by the type of host the package -will run on. Usually `configure' can figure that out, but if it prints -a message saying it can not guess the host type, give it the -`--host=TYPE' option. TYPE can either be a short name for the system -type, such as `sun4', or a canonical name with three fields: - CPU-COMPANY-SYSTEM - -See the file `config.sub' for the possible values of each field. If -`config.sub' isn't included in this package, then this package doesn't -need to know the host type. - - If you are building compiler tools for cross-compiling, you can also -use the `--target=TYPE' option to select the type of system they will -produce code for and the `--build=TYPE' option to select the type of -system on which you are compiling the package. - -Sharing Defaults -================ - - If you want to set default values for `configure' scripts to share, -you can create a site shell script called `config.site' that gives -default values for variables like `CC', `cache_file', and `prefix'. -`configure' looks for `PREFIX/share/config.site' if it exists, then -`PREFIX/etc/config.site' if it exists. Or, you can set the -`CONFIG_SITE' environment variable to the location of the site script. -A warning: not all `configure' scripts look for a site script. - -Operation Controls -================== - - `configure' recognizes the following options to control how it -operates. - -`--cache-file=FILE' - Use and save the results of the tests in FILE instead of - `./config.cache'. Set FILE to `/dev/null' to disable caching, for - debugging `configure'. - -`--help' - Print a summary of the options to `configure', and exit. - -`--quiet' -`--silent' -`-q' - Do not print messages saying which checks are being made. To - suppress all normal output, redirect it to `/dev/null' (any error - messages will still be shown). - -`--srcdir=DIR' - Look for the package's source code in directory DIR. Usually - `configure' can determine that directory automatically. - -`--version' - Print the version of Autoconf used to generate the `configure' - script, and exit. - -`configure' also accepts some other, not widely useful, options. - diff --git a/lib-src/libmad/Makefile.am b/lib-src/libmad/Makefile.am deleted file mode 100644 index 4d2638ac3..000000000 --- a/lib-src/libmad/Makefile.am +++ /dev/null @@ -1,140 +0,0 @@ -## -## libmad - MPEG audio decoder library -## Copyright (C) 2000-2004 Underbit Technologies, Inc. -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License -## along with this program; if not, write to the Free Software -## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -## -## $Id: Makefile.am,v 1.4 2005-09-12 07:01:29 dmazzoni Exp $ -## - -## Process this file with automake to produce Makefile.in - -SUBDIRS = -DIST_SUBDIRS = msvc++ - -lib_LTLIBRARIES = libmad.la -include_HEADERS = mad.h - -EXTRA_PROGRAMS = minimad - -minimad_SOURCES = minimad.c -minimad_INCLUDES = -minimad_LDADD = libmad.la - -EXTRA_DIST = mad.h.sed \ - CHANGES COPYRIGHT CREDITS README TODO VERSION - -exported_headers = version.h fixed.h bit.h timer.h stream.h frame.h \ - synth.h decoder.h - -headers = $(exported_headers) \ - global.h layer12.h layer3.h huffman.h - -data_includes = D.dat imdct_s.dat qc_table.dat rq_table.dat \ - sf_table.dat - -libmad_la_SOURCES = version.c fixed.c bit.c timer.c stream.c frame.c \ - synth.c decoder.c layer12.c layer3.c huffman.c \ - $(headers) $(data_includes) - -EXTRA_libmad_la_SOURCES = imdct_l_arm.S #synth_mmx.S - -libmad_la_DEPENDENCIES = @ASO_OBJS@ -libmad_la_LIBADD = @ASO_OBJS@ - -INCLUDES = $(FPM) $(ASO) - -BUILT_SOURCES = mad.h -CLEANFILES = mad.h - -## From the libtool documentation on library versioning: -## -## CURRENT -## The most recent interface number that this library implements. -## -## REVISION -## The implementation number of the CURRENT interface. -## -## AGE -## The difference between the newest and oldest interfaces that this -## library implements. In other words, the library implements all the -## interface numbers in the range from number `CURRENT - AGE' to -## `CURRENT'. -## -## If two libraries have identical CURRENT and AGE numbers, then the -## dynamic linker chooses the library with the greater REVISION number. -## -## 1. Start with version information of `0:0:0' for each libtool library. -## -## 2. Update the version information only immediately before a public -## release of your software. More frequent updates are unnecessary, -## and only guarantee that the current interface number gets larger -## faster. -## -## 3. If the library source code has changed at all since the last -## update, then increment REVISION (`C:R:A' becomes `C:r+1:A'). -## -## 4. If any interfaces have been added, removed, or changed since the -## last update, increment CURRENT, and set REVISION to 0. -## -## 5. If any interfaces have been added since the last public release, -## then increment AGE. -## -## 6. If any interfaces have been removed since the last public release, -## then set AGE to 0. - -version_current = 2 -version_revision = 1 -version_age = 2 - -version_info = $(version_current):$(version_revision):$(version_age) - -libmad_la_LDFLAGS = -version-info $(version_info) - -mad.h: config.status config.h Makefile.am \ - $(srcdir)/COPYRIGHT $(srcdir)/mad.h.sed $(exported_headers) - (sed -e '1s|.*|/*|' -e '1b' -e '$$s|.*| */|' -e '$$b' \ - -e 's/^.*/ *&/' $(srcdir)/COPYRIGHT; echo; \ - echo "# ifdef __cplusplus"; \ - echo 'extern "C" {'; \ - echo "# endif"; echo; \ - if [ ".$(FPM)" != "." ]; then \ - echo ".$(FPM)" | sed -e 's|^\.-D|# define |'; echo; \ - fi; \ - sed -ne 's/^# *define *\(HAVE_.*_ASM\).*/# define \1/p' \ - config.h; echo; \ - sed -ne 's/^# *define *OPT_\(SPEED\|ACCURACY\).*/# define OPT_\1/p' \ - config.h; echo; \ - sed -ne 's/^# *define *\(SIZEOF_.*\)/# define \1/p' \ - config.h; echo; \ - for header in $(exported_headers); do \ - echo; \ - sed -n -f $(srcdir)/mad.h.sed $(srcdir)/$$header; \ - done; echo; \ - echo "# ifdef __cplusplus"; \ - echo '}'; \ - echo "# endif") >$@ - -libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - -.c.s: - $(COMPILE) -S $< - -again: - $(MAKE) clean - $(MAKE) - -.PHONY: again diff --git a/lib-src/libmad/Makefile.in b/lib-src/libmad/Makefile.in deleted file mode 100644 index 10b921ad5..000000000 --- a/lib-src/libmad/Makefile.in +++ /dev/null @@ -1,1095 +0,0 @@ -# Makefile.in generated by automake 1.14.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2013 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - -VPATH = @srcdir@ -am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -EXTRA_PROGRAMS = minimad$(EXEEXT) -subdir = . -DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ - $(top_srcdir)/configure $(am__configure_deps) acconfig.h \ - $(srcdir)/config.h.in mkinstalldirs $(srcdir)/libmad.list.in \ - depcomp $(include_HEADERS) COPYING INSTALL README TODO compile \ - config.guess config.sub install-sh missing ltmain.sh -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs -CONFIG_HEADER = config.h -CONFIG_CLEAN_FILES = libmad.list -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)" -LTLIBRARIES = $(lib_LTLIBRARIES) -am__objects_1 = -am__objects_2 = $(am__objects_1) -am_libmad_la_OBJECTS = version.lo fixed.lo bit.lo timer.lo stream.lo \ - frame.lo synth.lo decoder.lo layer12.lo layer3.lo huffman.lo \ - $(am__objects_2) $(am__objects_1) -libmad_la_OBJECTS = $(am_libmad_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libmad_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(libmad_la_LDFLAGS) $(LDFLAGS) -o $@ -am_minimad_OBJECTS = minimad.$(OBJEXT) -minimad_OBJECTS = $(am_minimad_OBJECTS) -minimad_DEPENDENCIES = libmad.la -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -CPPASCOMPILE = $(CCAS) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CCASFLAGS) $(CCASFLAGS) -LTCPPASCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CCAS) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CCASFLAGS) $(CCASFLAGS) -AM_V_CPPAS = $(am__v_CPPAS_@AM_V@) -am__v_CPPAS_ = $(am__v_CPPAS_@AM_DEFAULT_V@) -am__v_CPPAS_0 = @echo " CPPAS " $@; -am__v_CPPAS_1 = -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(libmad_la_SOURCES) $(EXTRA_libmad_la_SOURCES) \ - $(minimad_SOURCES) -DIST_SOURCES = $(libmad_la_SOURCES) $(EXTRA_libmad_la_SOURCES) \ - $(minimad_SOURCES) -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -HEADERS = $(include_HEADERS) -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - cscope distdir dist dist-all distcheck -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ - $(LISP)config.h.in -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -CSCOPE = cscope -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - if test -d "$(distdir)"; then \ - find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -rf "$(distdir)" \ - || { sleep 5 && rm -rf "$(distdir)"; }; \ - else :; fi -am__post_remove_distdir = $(am__remove_distdir) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -DIST_ARCHIVES = $(distdir).tar.gz -GZIP_ENV = --best -DIST_TARGETS = dist-gzip -distuninstallcheck_listfiles = find . -type f -print -am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ - | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -ASO = @ASO@ -ASO_OBJS = @ASO_OBJS@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCAS = @CCAS@ -CCASDEPMODE = @CCASDEPMODE@ -CCASFLAGS = @CCASFLAGS@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FPM = @FPM@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -SUBDIRS = -DIST_SUBDIRS = msvc++ -lib_LTLIBRARIES = libmad.la -include_HEADERS = mad.h -minimad_SOURCES = minimad.c -minimad_INCLUDES = -minimad_LDADD = libmad.la -EXTRA_DIST = mad.h.sed \ - CHANGES COPYRIGHT CREDITS README TODO VERSION - -exported_headers = version.h fixed.h bit.h timer.h stream.h frame.h \ - synth.h decoder.h - -headers = $(exported_headers) \ - global.h layer12.h layer3.h huffman.h - -data_includes = D.dat imdct_s.dat qc_table.dat rq_table.dat \ - sf_table.dat - -libmad_la_SOURCES = version.c fixed.c bit.c timer.c stream.c frame.c \ - synth.c decoder.c layer12.c layer3.c huffman.c \ - $(headers) $(data_includes) - -EXTRA_libmad_la_SOURCES = imdct_l_arm.S #synth_mmx.S -libmad_la_DEPENDENCIES = @ASO_OBJS@ -libmad_la_LIBADD = @ASO_OBJS@ -INCLUDES = $(FPM) $(ASO) -BUILT_SOURCES = mad.h -CLEANFILES = mad.h -version_current = 2 -version_revision = 1 -version_age = 2 -version_info = $(version_current):$(version_revision):$(version_age) -libmad_la_LDFLAGS = -version-info $(version_info) -all: $(BUILT_SOURCES) config.h - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -.SUFFIXES: .S .c .lo .o .obj .s -am--refresh: Makefile - @: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ - $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - $(am__cd) $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) -$(am__aclocal_m4_deps): - -config.h: stamp-h1 - @test -f $@ || rm -f stamp-h1 - @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 - -stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status - @rm -f stamp-h1 - cd $(top_builddir) && $(SHELL) ./config.status config.h -$(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) $(top_srcdir)/acconfig.h - ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) - rm -f stamp-h1 - touch $@ - -distclean-hdr: - -rm -f config.h stamp-h1 -libmad.list: $(top_builddir)/config.status $(srcdir)/libmad.list.in - cd $(top_builddir) && $(SHELL) ./config.status $@ - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libmad.la: $(libmad_la_OBJECTS) $(libmad_la_DEPENDENCIES) $(EXTRA_libmad_la_DEPENDENCIES) - $(AM_V_CCLD)$(libmad_la_LINK) -rpath $(libdir) $(libmad_la_OBJECTS) $(libmad_la_LIBADD) $(LIBS) - -minimad$(EXEEXT): $(minimad_OBJECTS) $(minimad_DEPENDENCIES) $(EXTRA_minimad_DEPENDENCIES) - @rm -f minimad$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(minimad_OBJECTS) $(minimad_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bit.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decoder.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fixed.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/frame.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/huffman.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/imdct_l_arm.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/layer12.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/layer3.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/minimad.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stream.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/synth.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timer.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Plo@am__quote@ - -.S.o: -@am__fastdepCCAS_TRUE@ $(AM_V_CPPAS)$(CPPASCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCCAS_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ DEPDIR=$(DEPDIR) $(CCASDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS@am__nodep@)$(CPPASCOMPILE) -c -o $@ $< - -.S.obj: -@am__fastdepCCAS_TRUE@ $(AM_V_CPPAS)$(CPPASCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCCAS_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ DEPDIR=$(DEPDIR) $(CCASDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS@am__nodep@)$(CPPASCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.S.lo: -@am__fastdepCCAS_TRUE@ $(AM_V_CPPAS)$(LTCPPASCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCCAS_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCCAS_FALSE@ DEPDIR=$(DEPDIR) $(CCASDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCCAS_FALSE@ $(AM_V_CPPAS@am__nodep@)$(LTCPPASCOMPILE) -c -o $@ $< - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -distclean-libtool: - -rm -f libtool config.lt -install-includeHEADERS: $(include_HEADERS) - @$(NORMAL_INSTALL) - @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ - fi; \ - for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; \ - done | $(am__base_list) | \ - while read files; do \ - echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \ - $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \ - done - -uninstall-includeHEADERS: - @$(NORMAL_UNINSTALL) - @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ - files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ - dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscope: cscope.files - test ! -s cscope.files \ - || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) -clean-cscope: - -rm -f cscope.files -cscope.files: clean-cscope cscopelist -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -rm -f cscope.out cscope.in.out cscope.po.out cscope.files - -distdir: $(DISTFILES) - $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done - -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -755 \ - -exec chmod u+rwx,go+rx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r "$(distdir)" -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__post_remove_distdir) - -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 - $(am__post_remove_distdir) - -dist-lzip: distdir - tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz - $(am__post_remove_distdir) - -dist-xz: distdir - tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz - $(am__post_remove_distdir) - -dist-tarZ: distdir - @echo WARNING: "Support for shar distribution archives is" \ - "deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__post_remove_distdir) - -dist-shar: distdir - @echo WARNING: "Support for distribution archives compressed with" \ - "legacy program 'compress' is deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__post_remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__post_remove_distdir) - -dist dist-all: - $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' - $(am__post_remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lz*) \ - lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ - *.tar.xz*) \ - xz -dc $(distdir).tar.xz | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - esac - chmod -R a-w $(distdir) - chmod u+w $(distdir) - mkdir $(distdir)/_build $(distdir)/_inst - chmod a-w $(distdir) - test -d $(distdir)/_build || exit 0; \ - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure \ - $(AM_DISTCHECK_CONFIGURE_FLAGS) \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - --srcdir=.. --prefix="$$dc_install_base" \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ - && cd "$$am__cwd" \ - || exit 1 - $(am__post_remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @test -n '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: trying to run $@ with an empty' \ - '$$(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - $(am__cd) '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) check-recursive -all-am: Makefile $(LTLIBRARIES) $(HEADERS) config.h -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) -clean: clean-recursive - -clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ - mostlyclean-am - -distclean: distclean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-hdr distclean-libtool distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: install-includeHEADERS - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: install-libLTLIBRARIES - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES - -.MAKE: $(am__recursive_targets) all check install install-am \ - install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--refresh check check-am clean clean-cscope clean-generic \ - clean-libLTLIBRARIES clean-libtool cscope cscopelist-am ctags \ - ctags-am dist dist-all dist-bzip2 dist-gzip dist-lzip \ - dist-shar dist-tarZ dist-xz dist-zip distcheck distclean \ - distclean-compile distclean-generic distclean-hdr \ - distclean-libtool distclean-tags distcleancheck distdir \ - distuninstallcheck dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-includeHEADERS install-info \ - install-info-am install-libLTLIBRARIES install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-includeHEADERS uninstall-libLTLIBRARIES - - -mad.h: config.status config.h Makefile.am \ - $(srcdir)/COPYRIGHT $(srcdir)/mad.h.sed $(exported_headers) - (sed -e '1s|.*|/*|' -e '1b' -e '$$s|.*| */|' -e '$$b' \ - -e 's/^.*/ *&/' $(srcdir)/COPYRIGHT; echo; \ - echo "# ifdef __cplusplus"; \ - echo 'extern "C" {'; \ - echo "# endif"; echo; \ - if [ ".$(FPM)" != "." ]; then \ - echo ".$(FPM)" | sed -e 's|^\.-D|# define |'; echo; \ - fi; \ - sed -ne 's/^# *define *\(HAVE_.*_ASM\).*/# define \1/p' \ - config.h; echo; \ - sed -ne 's/^# *define *OPT_\(SPEED\|ACCURACY\).*/# define OPT_\1/p' \ - config.h; echo; \ - sed -ne 's/^# *define *\(SIZEOF_.*\)/# define \1/p' \ - config.h; echo; \ - for header in $(exported_headers); do \ - echo; \ - sed -n -f $(srcdir)/mad.h.sed $(srcdir)/$$header; \ - done; echo; \ - echo "# ifdef __cplusplus"; \ - echo '}'; \ - echo "# endif") >$@ - -libtool: $(LIBTOOL_DEPS) - $(SHELL) ./config.status --recheck - -.c.s: - $(COMPILE) -S $< - -again: - $(MAKE) clean - $(MAKE) - -.PHONY: again - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/libmad/README b/lib-src/libmad/README deleted file mode 100644 index 7c94f6655..000000000 --- a/lib-src/libmad/README +++ /dev/null @@ -1,241 +0,0 @@ - - libmad - MPEG audio decoder library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: README,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - -=============================================================================== - -INTRODUCTION - - MAD (libmad) is a high-quality MPEG audio decoder. It currently supports - MPEG-1 and the MPEG-2 extension to Lower Sampling Frequencies, as well as - the so-called MPEG 2.5 format. All three audio layers (Layer I, Layer II, - and Layer III a.k.a. MP3) are fully implemented. - - MAD does not yet support MPEG-2 multichannel audio (although it should be - backward compatible with such streams) nor does it currently support AAC. - - MAD has the following special features: - - - 24-bit PCM output - - 100% fixed-point (integer) computation - - completely new implementation based on the ISO/IEC standards - - distributed under the terms of the GNU General Public License (GPL) - - Because MAD provides full 24-bit PCM output, applications using MAD are - able to produce high quality audio. Even when the output device supports - only 16-bit PCM, applications can use the extra resolution to increase the - audible dynamic range through the use of dithering or noise shaping. - - Because MAD uses integer computation rather than floating point, it is - well suited for architectures without a floating point unit. All - calculations are performed with a 32-bit fixed-point integer - representation. - - Because MAD is a new implementation of the ISO/IEC standards, it is - unencumbered by the errors of other implementations. MAD is NOT a - derivation of the ISO reference source or any other code. Considerable - effort has been expended to ensure a correct implementation, even in cases - where the standards are ambiguous or misleading. - - Because MAD is distributed under the terms of the GPL, its redistribution - is not generally restricted, so long as the terms of the GPL are followed. - This means MAD can be incorporated into other software as long as that - software is also distributed under the GPL. (Should this be undesirable, - alternate arrangements may be possible by contacting Underbit.) - -=============================================================================== - -ABOUT THE CODE - - The code is optimized and performs very well, although specific - improvements can still be made. The output from the decoder library - consists of 32-bit signed linear fixed-point values that can be easily - scaled for any size PCM output, up to 24 bits per sample. - - The API for libmad can be found in the `mad.h' header file. Note that this - file is automatically generated, and will not exist until after you have - built the library. - - There are two APIs available, one high-level, and the other low-level. - With the low-level API, each step of the decoding process must be handled - explicitly, offering the greatest amount of control. With the high-level - API, after callbacks are configured, a single routine will decode an - entire bitstream. - - The high-level API may either be used synchronously or asynchronously. If - used asynchronously, decoding will occur in a separate process. - Communication is possible with the decoding process by passing control - messages. - - The file `minimad.c' contains an example usage of the libmad API that - shows only the bare minimum required to implement a useful decoder. It - expects a regular file to be redirected to standard input, and it sends - decoded 16-bit signed little-endian PCM samples to standard output. If a - decoding error occurs, it is reported to standard error and decoding - continues. Note that the scale() routine in this code is only provided as - an example; it rounds MAD's high-resolution samples down to 16 bits, but - does not perform any dithering or noise shaping. It is therefore not - recommended to use this routine as-is in your own code if sound quality is - important. - -Integer Performance - - To get the best possible performance, it is recommended that an assembly - version of the fixed-point multiply and related routines be selected. - Several such assembly routines have been written for various CPUs. - - If an assembly version is not available, a fast approximation version will - be used. This will result in reduced accuracy of the decoder. - - Alternatively, if 64-bit integers are supported as a datatype by the - compiler, another version can be used that is much more accurate. - However, using an assembly version is generally much faster and just as - accurate. - - More information can be gathered from the `fixed.h' header file. - - MAD's CPU-intensive subband synthesis routine can be further optimized at - the expense of a slight loss in output accuracy due to a modified method - for fixed-point multiplication with a small windowing constant. While this - is helpful for performance and the output accuracy loss is generally - undetectable, it is disabled by default and must be explicitly enabled. - - Under some architectures, other special optimizations may also be - available. - -Audio Quality - - The output from MAD has been found to satisfy the ISO/IEC 11172-4 - computational accuracy requirements for compliance. In most - configurations, MAD is a Full Layer III ISO/IEC 11172-3 audio decoder as - defined by the standard. - - When the approximation version of the fixed-point multiply is used, MAD is - a limited accuracy ISO/IEC 11172-3 audio decoder as defined by the - standard. - - MAD can alternatively be configured to produce output with less or more - accuracy than the default, as a tradeoff with performance. - - MAD produces output samples with a precision greater than 24 bits. Because - most output formats use fewer bits, typically 16, it is recommended that a - dithering algorithm be used (rather than rounding or truncating) to obtain - the highest quality audio. However, dithering may unfavorably affect an - analytic examination of the output (such as compliance testing); you may - therefore wish to use rounding in this case instead. - -Portability Issues - - GCC is preferred to compile the code, but other compilers may also work. - The assembly code in `fixed.h' depends on the inline assembly features of - your compiler. If you're not using GCC or MSVC++, you can either write - your own assembly macros or use the default (low quality output) version. - - The union initialization of `huffman.c' may not be portable to all - platforms when GCC is not used. - - The code should not be sensitive to word sizes or byte ordering, however - it does assume A % B has the same sign as A. - -=============================================================================== - -BUILDING AND INSTALLING - -Windows Platforms - - MAD can be built under Windows using either MSVC++ or Cygwin. A MSVC++ - project file can be found under the `msvc++' subdirectory. - - To build libmad using Cygwin, you will first need to install the Cygwin - tools: - - http://www.cygwin.com/ - - You may then proceed with the following POSIX instructions within the - Cygwin shell. - - Note that by default Cygwin will build a library that depends on the - Cygwin DLL. You can use MinGW to build a library that does not depend on - the Cygwin DLL. To do so, give the option --host=mingw32 to `configure'. - -POSIX Platforms (including Cygwin) - - The code is distributed with a `configure' script that will generate for - you a `Makefile' and a `config.h' for your platform. See the file - `INSTALL' for generic instructions. - - The specific options you may want to give `configure' are: - - --enable-speed optimize for speed over accuracy - - --enable-accuracy optimize for accuracy over speed - - --disable-debugging do not compile with debugging support, and - use more optimizations - - --disable-shared do not build a shared library - - Note that you need not specify one of --enable-speed or --enable-accuracy; - in its default configuration, MAD is optimized for both. You should only - use one of these options if you wish to compromise speed or accuracy for - the other. - - By default the package will build a shared library if possible for your - platform. If you want only a static library, use --disable-shared. - - It is not normally necessary to use the following options, but you may - fine-tune the configuration with them if desired: - - --enable-fpm=ARCH use the ARCH-specific version of the - fixed-point math assembly routines - (current options are: intel, arm, mips, - sparc, ppc; also allowed are: 64bit, approx) - - --enable-sso use the subband synthesis optimization, - with reduced accuracy - - --disable-aso do not use certain architecture-specific - optimizations - - By default an appropriate fixed-point assembly routine will be selected - for the configured host type, if it can be determined. Thus if you are - cross-compiling for another architecture, you should be sure either to - give `configure' a host type argument (--host) or to use an explicit - --enable-fpm option. - - If an appropriate assembly routine cannot be determined, the default - approximation version will be used. In this case, use of an alternate - --enable-fpm is highly recommended. - -Experimenting and Developing - - Further options for `configure' that may be useful to developers and - experimenters are: - - --enable-debugging enable diagnostic debugging support and - debugging symbols - - --enable-profiling generate `gprof' profiling code - - --enable-experimental enable code using the EXPERIMENTAL - preprocessor define - -=============================================================================== - -COPYRIGHT - - Please read the `COPYRIGHT' file for copyright and warranty information. - Also, the file `COPYING' contains the full text of the GNU GPL. - - Send inquiries, comments, bug reports, suggestions, patches, etc. to: - - Underbit Technologies, Inc. - - See also the MAD home page on the Web: - - http://www.underbit.com/products/mad/ - -=============================================================================== - diff --git a/lib-src/libmad/TODO b/lib-src/libmad/TODO deleted file mode 100644 index 54702c3cf..000000000 --- a/lib-src/libmad/TODO +++ /dev/null @@ -1,69 +0,0 @@ - - libmad - MPEG audio decoder library - Copyright (C) 2000-2004 Underbit Technologies, Inc. - - $Id: TODO,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - -=============================================================================== - -libmad: - - more API layers (buffering, PCM samples, dithering, etc.) - - x86 performance optimization compiler flags - - function documentation, general docs - - finish async API - - parse system streams? - - MPEG-2 MC, AAC? - - logarithmic multiplication? - - multiple frame decoding for better locality of reference? - - frame serial numbers, Layer III frame continuity checks - -fixed.h: - - experiment with FPM_INTEL: - -# if 1 -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("shrl %3,%1\n\t" \ - "shll %4,%2\n\t" \ - "orl %2,%1" \ - : "=rm" (__result) \ - : "0" (lo), "r" (hi), \ - "I" (MAD_F_SCALEBITS), "I" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# else -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed64hi_t __hi_; \ - mad_fixed64lo_t __lo_; \ - mad_fixed_t __result; \ - asm ("sall %2,%1" \ - : "=r" (__hi_) \ - : "0" (hi), "I" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - asm ("shrl %2,%1" \ - : "=r" (__lo_) \ - : "0" (lo), "I" (MAD_F_SCALEBITS) \ - : "cc"); \ - asm ("orl %1,%2" \ - : "=rm" (__result) \ - : "r" (__hi_), "0" (__lo_) \ - : "cc"); \ - __result; \ - }) -# endif - -libmad Layer I: - - check frame length sanity - -libmad Layer II: - - check frame length sanity - -libmad Layer III: - - circular buffer - - optimize zero_part from Huffman decoding throughout - - MPEG 2.5 8000 Hz sf bands? mixed blocks? - - stereo->mono conversion optimization? - - enable frame-at-a-time decoding - - improve portability of huffman.c - diff --git a/lib-src/libmad/VERSION b/lib-src/libmad/VERSION deleted file mode 100644 index d4e8f64aa..000000000 --- a/lib-src/libmad/VERSION +++ /dev/null @@ -1,7 +0,0 @@ -0.15.1b -configure.ac:24 -version.h:25-28 -msvc++/config.h:99,105,120 -msvc++/mad.h:41-44 - -Makefile.am:98-100 diff --git a/lib-src/libmad/acconfig.h b/lib-src/libmad/acconfig.h deleted file mode 100644 index 3af62311f..000000000 --- a/lib-src/libmad/acconfig.h +++ /dev/null @@ -1,63 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2001 Robert Leslie - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: acconfig.h,v 1.2 2001-10-21 22:26:32 dmazzoni Exp $ - */ - -# ifndef LIBMAD_CONFIG_H -# define LIBMAD_CONFIG_H - -/***************************************************************************** - * Definitions selected automatically by `configure' * - *****************************************************************************/ -@TOP@ - -/* Define to optimize for speed over accuracy. */ -#undef OPT_SPEED - -/* Define to optimize for accuracy over speed. */ -#undef OPT_ACCURACY - -/* Define to enable a fast subband synthesis approximation optimization. */ -#undef OPT_SSO - -/* Define to influence a strict interpretation of the ISO/IEC standards, - even if this is in opposition with best accepted practices. */ -#undef OPT_STRICT - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#undef HAVE_MADD_ASM - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#undef HAVE_MADD16_ASM - -/* Define to enable diagnostic debugging support. */ -#undef DEBUG - -/* Define to disable debugging assertions. */ -#undef NDEBUG - -/* Define to enable experimental code. */ -#undef EXPERIMENTAL - -@BOTTOM@ -/***************************************************************************** - * End of automatically configured definitions * - *****************************************************************************/ - -# endif diff --git a/lib-src/libmad/bit.c b/lib-src/libmad/bit.c deleted file mode 100644 index 4dc746d41..000000000 --- a/lib-src/libmad/bit.c +++ /dev/null @@ -1,237 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: bit.c,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# ifdef HAVE_LIMITS_H -# include -# else -# define CHAR_BIT 8 -# endif - -# include "bit.h" - -/* - * This is the lookup table for computing the CRC-check word. - * As described in section 2.4.3.1 and depicted in Figure A.9 - * of ISO/IEC 11172-3, the generator polynomial is: - * - * G(X) = X^16 + X^15 + X^2 + 1 - */ -static -unsigned short const crc_table[256] = { - 0x0000, 0x8005, 0x800f, 0x000a, 0x801b, 0x001e, 0x0014, 0x8011, - 0x8033, 0x0036, 0x003c, 0x8039, 0x0028, 0x802d, 0x8027, 0x0022, - 0x8063, 0x0066, 0x006c, 0x8069, 0x0078, 0x807d, 0x8077, 0x0072, - 0x0050, 0x8055, 0x805f, 0x005a, 0x804b, 0x004e, 0x0044, 0x8041, - 0x80c3, 0x00c6, 0x00cc, 0x80c9, 0x00d8, 0x80dd, 0x80d7, 0x00d2, - 0x00f0, 0x80f5, 0x80ff, 0x00fa, 0x80eb, 0x00ee, 0x00e4, 0x80e1, - 0x00a0, 0x80a5, 0x80af, 0x00aa, 0x80bb, 0x00be, 0x00b4, 0x80b1, - 0x8093, 0x0096, 0x009c, 0x8099, 0x0088, 0x808d, 0x8087, 0x0082, - - 0x8183, 0x0186, 0x018c, 0x8189, 0x0198, 0x819d, 0x8197, 0x0192, - 0x01b0, 0x81b5, 0x81bf, 0x01ba, 0x81ab, 0x01ae, 0x01a4, 0x81a1, - 0x01e0, 0x81e5, 0x81ef, 0x01ea, 0x81fb, 0x01fe, 0x01f4, 0x81f1, - 0x81d3, 0x01d6, 0x01dc, 0x81d9, 0x01c8, 0x81cd, 0x81c7, 0x01c2, - 0x0140, 0x8145, 0x814f, 0x014a, 0x815b, 0x015e, 0x0154, 0x8151, - 0x8173, 0x0176, 0x017c, 0x8179, 0x0168, 0x816d, 0x8167, 0x0162, - 0x8123, 0x0126, 0x012c, 0x8129, 0x0138, 0x813d, 0x8137, 0x0132, - 0x0110, 0x8115, 0x811f, 0x011a, 0x810b, 0x010e, 0x0104, 0x8101, - - 0x8303, 0x0306, 0x030c, 0x8309, 0x0318, 0x831d, 0x8317, 0x0312, - 0x0330, 0x8335, 0x833f, 0x033a, 0x832b, 0x032e, 0x0324, 0x8321, - 0x0360, 0x8365, 0x836f, 0x036a, 0x837b, 0x037e, 0x0374, 0x8371, - 0x8353, 0x0356, 0x035c, 0x8359, 0x0348, 0x834d, 0x8347, 0x0342, - 0x03c0, 0x83c5, 0x83cf, 0x03ca, 0x83db, 0x03de, 0x03d4, 0x83d1, - 0x83f3, 0x03f6, 0x03fc, 0x83f9, 0x03e8, 0x83ed, 0x83e7, 0x03e2, - 0x83a3, 0x03a6, 0x03ac, 0x83a9, 0x03b8, 0x83bd, 0x83b7, 0x03b2, - 0x0390, 0x8395, 0x839f, 0x039a, 0x838b, 0x038e, 0x0384, 0x8381, - - 0x0280, 0x8285, 0x828f, 0x028a, 0x829b, 0x029e, 0x0294, 0x8291, - 0x82b3, 0x02b6, 0x02bc, 0x82b9, 0x02a8, 0x82ad, 0x82a7, 0x02a2, - 0x82e3, 0x02e6, 0x02ec, 0x82e9, 0x02f8, 0x82fd, 0x82f7, 0x02f2, - 0x02d0, 0x82d5, 0x82df, 0x02da, 0x82cb, 0x02ce, 0x02c4, 0x82c1, - 0x8243, 0x0246, 0x024c, 0x8249, 0x0258, 0x825d, 0x8257, 0x0252, - 0x0270, 0x8275, 0x827f, 0x027a, 0x826b, 0x026e, 0x0264, 0x8261, - 0x0220, 0x8225, 0x822f, 0x022a, 0x823b, 0x023e, 0x0234, 0x8231, - 0x8213, 0x0216, 0x021c, 0x8219, 0x0208, 0x820d, 0x8207, 0x0202 -}; - -# define CRC_POLY 0x8005 - -/* - * NAME: bit->init() - * DESCRIPTION: initialize bit pointer struct - */ -void mad_bit_init(struct mad_bitptr *bitptr, unsigned char const *byte) -{ - bitptr->byte = byte; - bitptr->cache = 0; - bitptr->left = CHAR_BIT; -} - -/* - * NAME: bit->length() - * DESCRIPTION: return number of bits between start and end points - */ -unsigned int mad_bit_length(struct mad_bitptr const *begin, - struct mad_bitptr const *end) -{ - return begin->left + - CHAR_BIT * (end->byte - (begin->byte + 1)) + (CHAR_BIT - end->left); -} - -/* - * NAME: bit->nextbyte() - * DESCRIPTION: return pointer to next unprocessed byte - */ -unsigned char const *mad_bit_nextbyte(struct mad_bitptr const *bitptr) -{ - return bitptr->left == CHAR_BIT ? bitptr->byte : bitptr->byte + 1; -} - -/* - * NAME: bit->skip() - * DESCRIPTION: advance bit pointer - */ -void mad_bit_skip(struct mad_bitptr *bitptr, unsigned int len) -{ - bitptr->byte += len / CHAR_BIT; - bitptr->left -= len % CHAR_BIT; - - if (bitptr->left > CHAR_BIT) { - bitptr->byte++; - bitptr->left += CHAR_BIT; - } - - if (bitptr->left < CHAR_BIT) - bitptr->cache = *bitptr->byte; -} - -/* - * NAME: bit->read() - * DESCRIPTION: read an arbitrary number of bits and return their UIMSBF value - */ -unsigned long mad_bit_read(struct mad_bitptr *bitptr, unsigned int len) -{ - register unsigned long value; - - if (bitptr->left == CHAR_BIT) - bitptr->cache = *bitptr->byte; - - if (len < bitptr->left) { - value = (bitptr->cache & ((1 << bitptr->left) - 1)) >> - (bitptr->left - len); - bitptr->left -= len; - - return value; - } - - /* remaining bits in current byte */ - - value = bitptr->cache & ((1 << bitptr->left) - 1); - len -= bitptr->left; - - bitptr->byte++; - bitptr->left = CHAR_BIT; - - /* more bytes */ - - while (len >= CHAR_BIT) { - value = (value << CHAR_BIT) | *bitptr->byte++; - len -= CHAR_BIT; - } - - if (len > 0) { - bitptr->cache = *bitptr->byte; - - value = (value << len) | (bitptr->cache >> (CHAR_BIT - len)); - bitptr->left -= len; - } - - return value; -} - -# if 0 -/* - * NAME: bit->write() - * DESCRIPTION: write an arbitrary number of bits - */ -void mad_bit_write(struct mad_bitptr *bitptr, unsigned int len, - unsigned long value) -{ - unsigned char *ptr; - - ptr = (unsigned char *) bitptr->byte; - - /* ... */ -} -# endif - -/* - * NAME: bit->crc() - * DESCRIPTION: compute CRC-check word - */ -unsigned short mad_bit_crc(struct mad_bitptr bitptr, unsigned int len, - unsigned short init) -{ - register unsigned int crc; - - for (crc = init; len >= 32; len -= 32) { - register unsigned long data; - - data = mad_bit_read(&bitptr, 32); - - crc = (crc << 8) ^ crc_table[((crc >> 8) ^ (data >> 24)) & 0xff]; - crc = (crc << 8) ^ crc_table[((crc >> 8) ^ (data >> 16)) & 0xff]; - crc = (crc << 8) ^ crc_table[((crc >> 8) ^ (data >> 8)) & 0xff]; - crc = (crc << 8) ^ crc_table[((crc >> 8) ^ (data >> 0)) & 0xff]; - } - - switch (len / 8) { - case 3: crc = (crc << 8) ^ - crc_table[((crc >> 8) ^ mad_bit_read(&bitptr, 8)) & 0xff]; - case 2: crc = (crc << 8) ^ - crc_table[((crc >> 8) ^ mad_bit_read(&bitptr, 8)) & 0xff]; - case 1: crc = (crc << 8) ^ - crc_table[((crc >> 8) ^ mad_bit_read(&bitptr, 8)) & 0xff]; - - len %= 8; - - case 0: break; - } - - while (len--) { - register unsigned int msb; - - msb = mad_bit_read(&bitptr, 1) ^ (crc >> 15); - - crc <<= 1; - if (msb & 1) - crc ^= CRC_POLY; - } - - return crc & 0xffff; -} diff --git a/lib-src/libmad/bit.h b/lib-src/libmad/bit.h deleted file mode 100644 index d0ce3ad8c..000000000 --- a/lib-src/libmad/bit.h +++ /dev/null @@ -1,47 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: bit.h,v 1.2 2005-09-12 07:01:29 dmazzoni Exp $ - */ - -# ifndef LIBMAD_BIT_H -# define LIBMAD_BIT_H - -struct mad_bitptr { - unsigned char const *byte; - unsigned short cache; - unsigned short left; -}; - -void mad_bit_init(struct mad_bitptr *, unsigned char const *); - -# define mad_bit_finish(bitptr) /* nothing */ - -unsigned int mad_bit_length(struct mad_bitptr const *, - struct mad_bitptr const *); - -# define mad_bit_bitsleft(bitptr) ((bitptr)->left) -unsigned char const *mad_bit_nextbyte(struct mad_bitptr const *); - -void mad_bit_skip(struct mad_bitptr *, unsigned int); -unsigned long mad_bit_read(struct mad_bitptr *, unsigned int); -void mad_bit_write(struct mad_bitptr *, unsigned int, unsigned long); - -unsigned short mad_bit_crc(struct mad_bitptr, unsigned int, unsigned short); - -# endif diff --git a/lib-src/libmad/compile b/lib-src/libmad/compile deleted file mode 100755 index 531136b06..000000000 --- a/lib-src/libmad/compile +++ /dev/null @@ -1,347 +0,0 @@ -#! /bin/sh -# Wrapper for compilers which do not understand '-c -o'. - -scriptversion=2012-10-14.11; # UTC - -# Copyright (C) 1999-2013 Free Software Foundation, Inc. -# Written by Tom Tromey . -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -nl=' -' - -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent tools from complaining about whitespace usage. -IFS=" "" $nl" - -file_conv= - -# func_file_conv build_file lazy -# Convert a $build file to $host form and store it in $file -# Currently only supports Windows hosts. If the determined conversion -# type is listed in (the comma separated) LAZY, no conversion will -# take place. -func_file_conv () -{ - file=$1 - case $file in - / | /[!/]*) # absolute file, and not a UNC file - if test -z "$file_conv"; then - # lazily determine how to convert abs files - case `uname -s` in - MINGW*) - file_conv=mingw - ;; - CYGWIN*) - file_conv=cygwin - ;; - *) - file_conv=wine - ;; - esac - fi - case $file_conv/,$2, in - *,$file_conv,*) - ;; - mingw/*) - file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` - ;; - cygwin/*) - file=`cygpath -m "$file" || echo "$file"` - ;; - wine/*) - file=`winepath -w "$file" || echo "$file"` - ;; - esac - ;; - esac -} - -# func_cl_dashL linkdir -# Make cl look for libraries in LINKDIR -func_cl_dashL () -{ - func_file_conv "$1" - if test -z "$lib_path"; then - lib_path=$file - else - lib_path="$lib_path;$file" - fi - linker_opts="$linker_opts -LIBPATH:$file" -} - -# func_cl_dashl library -# Do a library search-path lookup for cl -func_cl_dashl () -{ - lib=$1 - found=no - save_IFS=$IFS - IFS=';' - for dir in $lib_path $LIB - do - IFS=$save_IFS - if $shared && test -f "$dir/$lib.dll.lib"; then - found=yes - lib=$dir/$lib.dll.lib - break - fi - if test -f "$dir/$lib.lib"; then - found=yes - lib=$dir/$lib.lib - break - fi - if test -f "$dir/lib$lib.a"; then - found=yes - lib=$dir/lib$lib.a - break - fi - done - IFS=$save_IFS - - if test "$found" != yes; then - lib=$lib.lib - fi -} - -# func_cl_wrapper cl arg... -# Adjust compile command to suit cl -func_cl_wrapper () -{ - # Assume a capable shell - lib_path= - shared=: - linker_opts= - for arg - do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - eat=1 - case $2 in - *.o | *.[oO][bB][jJ]) - func_file_conv "$2" - set x "$@" -Fo"$file" - shift - ;; - *) - func_file_conv "$2" - set x "$@" -Fe"$file" - shift - ;; - esac - ;; - -I) - eat=1 - func_file_conv "$2" mingw - set x "$@" -I"$file" - shift - ;; - -I*) - func_file_conv "${1#-I}" mingw - set x "$@" -I"$file" - shift - ;; - -l) - eat=1 - func_cl_dashl "$2" - set x "$@" "$lib" - shift - ;; - -l*) - func_cl_dashl "${1#-l}" - set x "$@" "$lib" - shift - ;; - -L) - eat=1 - func_cl_dashL "$2" - ;; - -L*) - func_cl_dashL "${1#-L}" - ;; - -static) - shared=false - ;; - -Wl,*) - arg=${1#-Wl,} - save_ifs="$IFS"; IFS=',' - for flag in $arg; do - IFS="$save_ifs" - linker_opts="$linker_opts $flag" - done - IFS="$save_ifs" - ;; - -Xlinker) - eat=1 - linker_opts="$linker_opts $2" - ;; - -*) - set x "$@" "$1" - shift - ;; - *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) - func_file_conv "$1" - set x "$@" -Tp"$file" - shift - ;; - *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) - func_file_conv "$1" mingw - set x "$@" "$file" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift - done - if test -n "$linker_opts"; then - linker_opts="-link$linker_opts" - fi - exec "$@" $linker_opts - exit 1 -} - -eat= - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: compile [--help] [--version] PROGRAM [ARGS] - -Wrapper for compilers which do not understand '-c -o'. -Remove '-o dest.o' from ARGS, run PROGRAM with the remaining -arguments, and rename the output as expected. - -If you are trying to build a whole package this is not the -right script to run: please start by reading the file 'INSTALL'. - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "compile $scriptversion" - exit $? - ;; - cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) - func_cl_wrapper "$@" # Doesn't return... - ;; -esac - -ofile= -cfile= - -for arg -do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - # So we strip '-o arg' only if arg is an object. - eat=1 - case $2 in - *.o | *.obj) - ofile=$2 - ;; - *) - set x "$@" -o "$2" - shift - ;; - esac - ;; - *.c) - cfile=$1 - set x "$@" "$1" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift -done - -if test -z "$ofile" || test -z "$cfile"; then - # If no '-o' option was seen then we might have been invoked from a - # pattern rule where we don't need one. That is ok -- this is a - # normal compilation that the losing compiler can handle. If no - # '.c' file was seen then we are probably linking. That is also - # ok. - exec "$@" -fi - -# Name of file we expect compiler to create. -cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` - -# Create the lock directory. -# Note: use '[/\\:.-]' here to ensure that we don't use the same name -# that we are using for the .o file. Also, base the name on the expected -# object file name, since that is what matters with a parallel build. -lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d -while true; do - if mkdir "$lockdir" >/dev/null 2>&1; then - break - fi - sleep 1 -done -# FIXME: race condition here if user kills between mkdir and trap. -trap "rmdir '$lockdir'; exit 1" 1 2 15 - -# Run the compile. -"$@" -ret=$? - -if test -f "$cofile"; then - test "$cofile" = "$ofile" || mv "$cofile" "$ofile" -elif test -f "${cofile}bj"; then - test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" -fi - -rmdir "$lockdir" -exit $ret - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libmad/config.guess b/lib-src/libmad/config.guess deleted file mode 100755 index b79252d6b..000000000 --- a/lib-src/libmad/config.guess +++ /dev/null @@ -1,1558 +0,0 @@ -#! /bin/sh -# Attempt to guess a canonical system name. -# Copyright 1992-2013 Free Software Foundation, Inc. - -timestamp='2013-06-10' - -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). -# -# Originally written by Per Bothner. -# -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD -# -# Please send patches with a ChangeLog entry to config-patches@gnu.org. - - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] - -Output the configuration name of the system \`$me' is run on. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.guess ($timestamp) - -Originally written by Per Bothner. -Copyright 1992-2013 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" >&2 - exit 1 ;; - * ) - break ;; - esac -done - -if test $# != 0; then - echo "$me: too many arguments$help" >&2 - exit 1 -fi - -trap 'exit 1' 1 2 15 - -# CC_FOR_BUILD -- compiler used by this script. Note that the use of a -# compiler to aid in system detection is discouraged as it requires -# temporary files to be created and, as you can see below, it is a -# headache to deal with in a portable fashion. - -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. - -# Portable tmp directory creation inspired by the Autoconf team. - -set_cc_for_build=' -trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; -trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; -: ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || - { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || - { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || - { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; -dummy=$tmp/dummy ; -tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; -case $CC_FOR_BUILD,$HOST_CC,$CC in - ,,) echo "int x;" > $dummy.c ; - for c in cc gcc c89 c99 ; do - if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then - CC_FOR_BUILD="$c"; break ; - fi ; - done ; - if test x"$CC_FOR_BUILD" = x ; then - CC_FOR_BUILD=no_compiler_found ; - fi - ;; - ,,*) CC_FOR_BUILD=$CC ;; - ,*,*) CC_FOR_BUILD=$HOST_CC ;; -esac ; set_cc_for_build= ;' - -# This is needed to find uname on a Pyramid OSx when run in the BSD universe. -# (ghazi@noc.rutgers.edu 1994-08-24) -if (test -f /.attbin/uname) >/dev/null 2>&1 ; then - PATH=$PATH:/.attbin ; export PATH -fi - -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown - -case "${UNAME_SYSTEM}" in -Linux|GNU|GNU/*) - # If the system lacks a compiler, then just pick glibc. - # We could probably try harder. - LIBC=gnu - - eval $set_cc_for_build - cat <<-EOF > $dummy.c - #include - #if defined(__UCLIBC__) - LIBC=uclibc - #elif defined(__dietlibc__) - LIBC=dietlibc - #else - LIBC=gnu - #endif - EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` - ;; -esac - -# Note: order is significant - the case branches are not exclusive. - -case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in - *:NetBSD:*:*) - # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, - # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently - # switched to ELF, *-*-netbsd* would select the old - # object file format. This provides both forward - # compatibility and a consistent mechanism for selecting the - # object file format. - # - # Note: NetBSD doesn't particularly care about the vendor - # portion of the name. We always set it to "unknown". - sysctl="sysctl -n hw.machine_arch" - UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ - /usr/sbin/$sysctl 2>/dev/null || echo unknown)` - case "${UNAME_MACHINE_ARCH}" in - armeb) machine=armeb-unknown ;; - arm*) machine=arm-unknown ;; - sh3el) machine=shl-unknown ;; - sh3eb) machine=sh-unknown ;; - sh5el) machine=sh5le-unknown ;; - *) machine=${UNAME_MACHINE_ARCH}-unknown ;; - esac - # The Operating System including object format, if it has switched - # to ELF recently, or will in the future. - case "${UNAME_MACHINE_ARCH}" in - arm*|i386|m68k|ns32k|sh3*|sparc|vax) - eval $set_cc_for_build - if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ELF__ - then - # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). - # Return netbsd for either. FIX? - os=netbsd - else - os=netbsdelf - fi - ;; - *) - os=netbsd - ;; - esac - # The OS release - # Debian GNU/NetBSD machines have a different userland, and - # thus, need a distinct triplet. However, they do not need - # kernel version information, so it can be replaced with a - # suitable tag, in the style of linux-gnu. - case "${UNAME_VERSION}" in - Debian*) - release='-gnu' - ;; - *) - release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` - ;; - esac - # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: - # contains redundant information, the shorter form: - # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "${machine}-${os}${release}" - exit ;; - *:Bitrig:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} - exit ;; - *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} - exit ;; - *:ekkoBSD:*:*) - echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} - exit ;; - *:SolidBSD:*:*) - echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} - exit ;; - macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd${UNAME_RELEASE} - exit ;; - *:MirBSD:*:*) - echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} - exit ;; - alpha:OSF1:*:*) - case $UNAME_RELEASE in - *4.0) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` - ;; - *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` - ;; - esac - # According to Compaq, /usr/sbin/psrinfo has been available on - # OSF/1 and Tru64 systems produced since 1995. I hope that - # covers most systems running today. This code pipes the CPU - # types through head -n 1, so we only detect the type of CPU 0. - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` - case "$ALPHA_CPU_TYPE" in - "EV4 (21064)") - UNAME_MACHINE="alpha" ;; - "EV4.5 (21064)") - UNAME_MACHINE="alpha" ;; - "LCA4 (21066/21068)") - UNAME_MACHINE="alpha" ;; - "EV5 (21164)") - UNAME_MACHINE="alphaev5" ;; - "EV5.6 (21164A)") - UNAME_MACHINE="alphaev56" ;; - "EV5.6 (21164PC)") - UNAME_MACHINE="alphapca56" ;; - "EV5.7 (21164PC)") - UNAME_MACHINE="alphapca57" ;; - "EV6 (21264)") - UNAME_MACHINE="alphaev6" ;; - "EV6.7 (21264A)") - UNAME_MACHINE="alphaev67" ;; - "EV6.8CB (21264C)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8AL (21264B)") - UNAME_MACHINE="alphaev68" ;; - "EV6.8CX (21264D)") - UNAME_MACHINE="alphaev68" ;; - "EV6.9A (21264/EV69A)") - UNAME_MACHINE="alphaev69" ;; - "EV7 (21364)") - UNAME_MACHINE="alphaev7" ;; - "EV7.9 (21364A)") - UNAME_MACHINE="alphaev79" ;; - esac - # A Pn.n version is a patched version. - # A Vn.n version is a released version. - # A Tn.n version is a released field test version. - # A Xn.n version is an unreleased experimental baselevel. - # 1.2 uses "1.2" for uname -r. - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; - Alpha\ *:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # Should we change UNAME_MACHINE based on the output of uname instead - # of the specific Alpha model? - echo alpha-pc-interix - exit ;; - 21064:Windows_NT:50:3) - echo alpha-dec-winnt3.5 - exit ;; - Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; - *:[Aa]miga[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-amigaos - exit ;; - *:[Mm]orph[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-morphos - exit ;; - *:OS/390:*:*) - echo i370-ibm-openedition - exit ;; - *:z/VM:*:*) - echo s390-ibm-zvmoe - exit ;; - *:OS400:*:*) - echo powerpc-ibm-os400 - exit ;; - arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix${UNAME_RELEASE} - exit ;; - arm*:riscos:*:*|arm*:RISCOS:*:*) - echo arm-unknown-riscos - exit ;; - SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - echo hppa1.1-hitachi-hiuxmpp - exit ;; - Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) - # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - if test "`(/bin/universe) 2>/dev/null`" = att ; then - echo pyramid-pyramid-sysv3 - else - echo pyramid-pyramid-bsd - fi - exit ;; - NILE*:*:*:dcosx) - echo pyramid-pyramid-svr4 - exit ;; - DRS?6000:unix:4.0:6*) - echo sparc-icl-nx6 - exit ;; - DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) - case `/usr/bin/uname -p` in - sparc) echo sparc-icl-nx7; exit ;; - esac ;; - s390x:SunOS:*:*) - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux${UNAME_RELEASE} - exit ;; - i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - eval $set_cc_for_build - SUN_ARCH="i386" - # If there is a compiler, see if it is configured for 64-bit objects. - # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. - # This test works for both compilers. - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - SUN_ARCH="x86_64" - fi - fi - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:6*:*) - # According to config.sub, this is the proper way to canonicalize - # SunOS6. Hard to guess exactly what SunOS6 will be like, but - # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - sun4*:SunOS:*:*) - case "`/usr/bin/arch -k`" in - Series*|S4*) - UNAME_RELEASE=`uname -v` - ;; - esac - # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` - exit ;; - sun3*:SunOS:*:*) - echo m68k-sun-sunos${UNAME_RELEASE} - exit ;; - sun*:*:4.2BSD:*) - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 - case "`/bin/arch`" in - sun3) - echo m68k-sun-sunos${UNAME_RELEASE} - ;; - sun4) - echo sparc-sun-sunos${UNAME_RELEASE} - ;; - esac - exit ;; - aushp:SunOS:*:*) - echo sparc-auspex-sunos${UNAME_RELEASE} - exit ;; - # The situation for MiNT is a little confusing. The machine name - # can be virtually everything (everything which is not - # "atarist" or "atariste" at least should have a processor - # > m68000). The system name ranges from "MiNT" over "FreeMiNT" - # to the lowercase version "mint" (or "freemint"). Finally - # the system name "TOS" denotes a system which is actually not - # MiNT. But MiNT is downward compatible to TOS, so this should - # be no problem. - atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} - exit ;; - milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; - hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; - *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; - m68k:machten:*:*) - echo m68k-apple-machten${UNAME_RELEASE} - exit ;; - powerpc:machten:*:*) - echo powerpc-apple-machten${UNAME_RELEASE} - exit ;; - RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; - RISC*:ULTRIX:*:*) - echo mips-dec-ultrix${UNAME_RELEASE} - exit ;; - VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix${UNAME_RELEASE} - exit ;; - 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix${UNAME_RELEASE} - exit ;; - mips:*:*:UMIPS | mips:*:*:RISCos) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c -#ifdef __cplusplus -#include /* for printf() prototype */ - int main (int argc, char *argv[]) { -#else - int main (argc, argv) int argc; char *argv[]; { -#endif - #if defined (host_mips) && defined (MIPSEB) - #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); - #endif - #endif - exit (-1); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && - dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`$dummy $dummyarg` && - { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos${UNAME_RELEASE} - exit ;; - Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax - exit ;; - Motorola:*:4.3:PL8-*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - echo powerpc-harris-powermax - exit ;; - Night_Hawk:Power_UNIX:*:*) - echo powerpc-harris-powerunix - exit ;; - m88k:CX/UX:7*:*) - echo m88k-harris-cxux7 - exit ;; - m88k:*:4*:R4*) - echo m88k-motorola-sysv4 - exit ;; - m88k:*:3*:R3*) - echo m88k-motorola-sysv3 - exit ;; - AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] - then - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ - [ ${TARGET_BINARY_INTERFACE}x = x ] - then - echo m88k-dg-dgux${UNAME_RELEASE} - else - echo m88k-dg-dguxbcs${UNAME_RELEASE} - fi - else - echo i586-dg-dgux${UNAME_RELEASE} - fi - exit ;; - M88*:DolphinOS:*:*) # DolphinOS (SVR3) - echo m88k-dolphin-sysv3 - exit ;; - M88*:*:R3*:*) - # Delta 88k system running SVR3 - echo m88k-motorola-sysv3 - exit ;; - XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - echo m88k-tektronix-sysv3 - exit ;; - Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - echo m68k-tektronix-bsd - exit ;; - *:IRIX*:*:*) - echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` - exit ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' - i*86:AIX:*:*) - echo i386-ibm-aix - exit ;; - ia64:AIX:*:*) - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} - exit ;; - *:AIX:2:3) - if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - - main() - { - if (!__power_pc()) - exit(1); - puts("powerpc-ibm-aix3.2.5"); - exit(0); - } -EOF - if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` - then - echo "$SYSTEM_NAME" - else - echo rs6000-ibm-aix3.2.5 - fi - elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - echo rs6000-ibm-aix3.2.4 - else - echo rs6000-ibm-aix3.2 - fi - exit ;; - *:AIX:*:[4567]) - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then - IBM_ARCH=rs6000 - else - IBM_ARCH=powerpc - fi - if [ -x /usr/bin/oslevel ] ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} - fi - echo ${IBM_ARCH}-ibm-aix${IBM_REV} - exit ;; - *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; - ibmrt:4.4BSD:*|romp-ibm:BSD:*) - echo romp-ibm-bsd4.4 - exit ;; - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 - *:BOSX:*:*) - echo rs6000-bull-bosx - exit ;; - DPX/2?00:B.O.S.:*:*) - echo m68k-bull-sysv3 - exit ;; - 9000/[34]??:4.3bsd:1.*:*) - echo m68k-hp-bsd - exit ;; - hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - echo m68k-hp-bsd4.4 - exit ;; - 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - case "${UNAME_MACHINE}" in - 9000/31? ) HP_ARCH=m68000 ;; - 9000/[34]?? ) HP_ARCH=m68k ;; - 9000/[678][0-9][0-9]) - if [ -x /usr/bin/getconf ]; then - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; - '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac - fi - if [ "${HP_ARCH}" = "" ]; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - - #define _HPUX_SOURCE - #include - #include - - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); - - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } -EOF - (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` - test -z "$HP_ARCH" && HP_ARCH=hppa - fi ;; - esac - if [ ${HP_ARCH} = "hppa2.0w" ] - then - eval $set_cc_for_build - - # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating - # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler - # generating 64-bit code. GNU and HP use different nomenclature: - # - # $ CC_FOR_BUILD=cc ./config.guess - # => hppa2.0w-hp-hpux11.23 - # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess - # => hppa64-hp-hpux11.23 - - if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep -q __LP64__ - then - HP_ARCH="hppa2.0w" - else - HP_ARCH="hppa64" - fi - fi - echo ${HP_ARCH}-hp-hpux${HPUX_REV} - exit ;; - ia64:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux${HPUX_REV} - exit ;; - 3050*:HI-UX:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - int - main () - { - long cpu = sysconf (_SC_CPU_VERSION); - /* The order matters, because CPU_IS_HP_MC68K erroneously returns - true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct - results, however. */ - if (CPU_IS_PA_RISC (cpu)) - { - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; - case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; - default: puts ("hppa-hitachi-hiuxwe2"); break; - } - } - else if (CPU_IS_HP_MC68K (cpu)) - puts ("m68k-hitachi-hiuxwe2"); - else puts ("unknown-hitachi-hiuxwe2"); - exit (0); - } -EOF - $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) - echo hppa1.1-hp-bsd - exit ;; - 9000/8??:4.3bsd:*:*) - echo hppa1.0-hp-bsd - exit ;; - *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) - echo hppa1.1-hp-osf - exit ;; - hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; - i*86:OSF1:*:*) - if [ -x /usr/sbin/sysversion ] ; then - echo ${UNAME_MACHINE}-unknown-osf1mk - else - echo ${UNAME_MACHINE}-unknown-osf1 - fi - exit ;; - parisc*:Lites*:*:*) - echo hppa1.1-hp-lites - exit ;; - C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - echo c1-convex-bsd - exit ;; - C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - echo c34-convex-bsd - exit ;; - C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - echo c38-convex-bsd - exit ;; - C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - echo c4-convex-bsd - exit ;; - CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*[A-Z]90:*:*:*) - echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ - | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ - -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ - -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*TS:*:*:*) - echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*SV1:*:*:*) - echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' - exit ;; - F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) - FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} - exit ;; - sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:BSD/OS:*:*) - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} - exit ;; - *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` - case ${UNAME_PROCESSOR} in - amd64) - echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - *) - echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; - esac - exit ;; - i*:CYGWIN*:*) - echo ${UNAME_MACHINE}-pc-cygwin - exit ;; - *:MINGW64*:*) - echo ${UNAME_MACHINE}-pc-mingw64 - exit ;; - *:MINGW*:*) - echo ${UNAME_MACHINE}-pc-mingw32 - exit ;; - i*:MSYS*:*) - echo ${UNAME_MACHINE}-pc-msys - exit ;; - i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 - exit ;; - i*:PW*:*) - echo ${UNAME_MACHINE}-pc-pw32 - exit ;; - *:Interix*:*) - case ${UNAME_MACHINE} in - x86) - echo i586-pc-interix${UNAME_RELEASE} - exit ;; - authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix${UNAME_RELEASE} - exit ;; - IA64) - echo ia64-unknown-interix${UNAME_RELEASE} - exit ;; - esac ;; - [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) - echo i${UNAME_MACHINE}-pc-mks - exit ;; - 8664:Windows_NT:*) - echo x86_64-pc-mks - exit ;; - i*:Windows_NT*:* | Pentium*:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we - # UNAME_MACHINE based on the output of uname instead of i386? - echo i586-pc-interix - exit ;; - i*:UWIN*:*) - echo ${UNAME_MACHINE}-pc-uwin - exit ;; - amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - echo x86_64-unknown-cygwin - exit ;; - p*:CYGWIN*:*) - echo powerpcle-unknown-cygwin - exit ;; - prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; - *:GNU:*:*) - # the GNU system - echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` - exit ;; - *:GNU/*:*:*) - # other systems with GNU libc and userland - echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} - exit ;; - i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix - exit ;; - aarch64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - aarch64_be:Linux:*:*) - UNAME_MACHINE=aarch64_be - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep -q ld.so.1 - if test "$?" = 0 ; then LIBC="gnulibc1" ; fi - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - arc:Linux:*:* | arceb:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - arm*:Linux:*:*) - eval $set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_EABI__ - then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - else - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi - else - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf - fi - fi - exit ;; - avr32*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - cris:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} - exit ;; - crisv32:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} - exit ;; - frv:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - hexagon:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - i*86:Linux:*:*) - echo ${UNAME_MACHINE}-pc-linux-${LIBC} - exit ;; - ia64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - m32r*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - m68*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - mips:Linux:*:* | mips64:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef ${UNAME_MACHINE} - #undef ${UNAME_MACHINE}el - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=${UNAME_MACHINE}el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=${UNAME_MACHINE} - #else - CPU= - #endif - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } - ;; - or1k:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - or32:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - padre:Linux:*:*) - echo sparc-unknown-linux-${LIBC} - exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-${LIBC} - exit ;; - parisc:Linux:*:* | hppa:Linux:*:*) - # Look for CPU level - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; - PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; - *) echo hppa-unknown-linux-${LIBC} ;; - esac - exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-${LIBC} - exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-${LIBC} - exit ;; - ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-${LIBC} - exit ;; - ppcle:Linux:*:*) - echo powerpcle-unknown-linux-${LIBC} - exit ;; - s390:Linux:*:* | s390x:Linux:*:*) - echo ${UNAME_MACHINE}-ibm-linux-${LIBC} - exit ;; - sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - sh*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - sparc:Linux:*:* | sparc64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - tile*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - vax:Linux:*:*) - echo ${UNAME_MACHINE}-dec-linux-${LIBC} - exit ;; - x86_64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - xtensa*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} - exit ;; - i*86:DYNIX/ptx:4*:*) - # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. - # earlier versions are messed up and put the nodename in both - # sysname and nodename. - echo i386-sequent-sysv4 - exit ;; - i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, - # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. - echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} - exit ;; - i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility - # is probably installed. - echo ${UNAME_MACHINE}-pc-os2-emx - exit ;; - i*86:XTS-300:*:STOP) - echo ${UNAME_MACHINE}-unknown-stop - exit ;; - i*86:atheos:*:*) - echo ${UNAME_MACHINE}-unknown-atheos - exit ;; - i*86:syllable:*:*) - echo ${UNAME_MACHINE}-pc-syllable - exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos${UNAME_RELEASE} - exit ;; - i*86:*DOS:*:*) - echo ${UNAME_MACHINE}-pc-msdosdjgpp - exit ;; - i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) - UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` - if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} - else - echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} - fi - exit ;; - i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. - case `/bin/uname -X | grep "^Machine"` in - *486*) UNAME_MACHINE=i486 ;; - *Pentium) UNAME_MACHINE=i586 ;; - *Pent*|*Celeron) UNAME_MACHINE=i686 ;; - esac - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} - exit ;; - i*86:*:3.2:*) - if test -f /usr/options/cb.name; then - UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` - (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 - (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ - && UNAME_MACHINE=i586 - (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ - && UNAME_MACHINE=i686 - (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ - && UNAME_MACHINE=i686 - echo ${UNAME_MACHINE}-pc-sco$UNAME_REL - else - echo ${UNAME_MACHINE}-pc-sysv32 - fi - exit ;; - pc:*:*:*) - # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i586. - # Note: whatever this is, it MUST be the same as what config.sub - # prints for the "djgpp" host, or else GDB configury will decide that - # this is a cross-build. - echo i586-pc-msdosdjgpp - exit ;; - Intel:Mach:3*:*) - echo i386-pc-mach3 - exit ;; - paragon:*:*:*) - echo i860-intel-osf1 - exit ;; - i860:*:4.*:*) # i860-SVR4 - if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 - else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 - fi - exit ;; - mini*:CTIX:SYS*5:*) - # "miniframe" - echo m68010-convergent-sysv - exit ;; - mc68k:UNIX:SYSTEM5:3.51m) - echo m68k-convergent-sysv - exit ;; - M680?0:D-NIX:5.3:*) - echo m68k-diab-dnix - exit ;; - M68*:*:R3V[5678]*:*) - test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; - 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) - OS_REL='' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; - NCR*:*:4.2:* | MPRAS*:*:4.2:*) - OS_REL='.3' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; - m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos${UNAME_RELEASE} - exit ;; - mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; - TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos${UNAME_RELEASE} - exit ;; - rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos${UNAME_RELEASE} - exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos${UNAME_RELEASE} - exit ;; - SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv${UNAME_RELEASE} - exit ;; - RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - RM*:SINIX-*:*:*) - echo mips-sni-sysv4 - exit ;; - *:SINIX-*:*:*) - if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo ${UNAME_MACHINE}-sni-sysv4 - else - echo ns32k-sni-sysv - fi - exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; - *:UNIX_System_V:4*:FTX*) - # From Gerald Hewes . - # How about differentiating between stratus architectures? -djm - echo hppa1.1-stratus-sysv4 - exit ;; - *:*:*:FTX*) - # From seanf@swdc.stratus.com. - echo i860-stratus-sysv4 - exit ;; - i*86:VOS:*:*) - # From Paul.Green@stratus.com. - echo ${UNAME_MACHINE}-stratus-vos - exit ;; - *:VOS:*:*) - # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; - mc68*:A/UX:*:*) - echo m68k-apple-aux${UNAME_RELEASE} - exit ;; - news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; - R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) - if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} - else - echo mips-unknown-sysv${UNAME_RELEASE} - fi - exit ;; - BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - echo powerpc-be-beos - exit ;; - BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - echo powerpc-apple-beos - exit ;; - BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - echo i586-pc-beos - exit ;; - BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; - x86_64:Haiku:*:*) - echo x86_64-unknown-haiku - exit ;; - SX-4:SUPER-UX:*:*) - echo sx4-nec-superux${UNAME_RELEASE} - exit ;; - SX-5:SUPER-UX:*:*) - echo sx5-nec-superux${UNAME_RELEASE} - exit ;; - SX-6:SUPER-UX:*:*) - echo sx6-nec-superux${UNAME_RELEASE} - exit ;; - SX-7:SUPER-UX:*:*) - echo sx7-nec-superux${UNAME_RELEASE} - exit ;; - SX-8:SUPER-UX:*:*) - echo sx8-nec-superux${UNAME_RELEASE} - exit ;; - SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux${UNAME_RELEASE} - exit ;; - Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Rhapsody:*:*) - echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} - exit ;; - *:Darwin:*:*) - UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown - eval $set_cc_for_build - if test "$UNAME_PROCESSOR" = unknown ; then - UNAME_PROCESSOR=powerpc - fi - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - case $UNAME_PROCESSOR in - i386) UNAME_PROCESSOR=x86_64 ;; - powerpc) UNAME_PROCESSOR=powerpc64 ;; - esac - fi - fi - echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} - exit ;; - *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=`uname -p` - if test "$UNAME_PROCESSOR" = "x86"; then - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc - fi - echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} - exit ;; - *:QNX:*:4*) - echo i386-pc-qnx - exit ;; - NEO-?:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk${UNAME_RELEASE} - exit ;; - NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk${UNAME_RELEASE} - exit ;; - NSR-?:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk${UNAME_RELEASE} - exit ;; - *:NonStop-UX:*:*) - echo mips-compaq-nonstopux - exit ;; - BS2000:POSIX*:*:*) - echo bs2000-siemens-sysv - exit ;; - DS/*:UNIX_System_V:*:*) - echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} - exit ;; - *:Plan9:*:*) - # "uname -m" is not consistent, so use $cputype instead. 386 - # is converted to i386 for consistency with other x86 - # operating systems. - if test "$cputype" = "386"; then - UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" - fi - echo ${UNAME_MACHINE}-unknown-plan9 - exit ;; - *:TOPS-10:*:*) - echo pdp10-unknown-tops10 - exit ;; - *:TENEX:*:*) - echo pdp10-unknown-tenex - exit ;; - KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - echo pdp10-dec-tops20 - exit ;; - XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - echo pdp10-xkl-tops20 - exit ;; - *:TOPS-20:*:*) - echo pdp10-unknown-tops20 - exit ;; - *:ITS:*:*) - echo pdp10-unknown-its - exit ;; - SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} - exit ;; - *:DragonFly:*:*) - echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` - exit ;; - *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "${UNAME_MACHINE}" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; - esac ;; - *:XENIX:*:SysV) - echo i386-pc-xenix - exit ;; - i*86:skyos:*:*) - echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' - exit ;; - i*86:rdos:*:*) - echo ${UNAME_MACHINE}-pc-rdos - exit ;; - i*86:AROS:*:*) - echo ${UNAME_MACHINE}-pc-aros - exit ;; - x86_64:VMkernel:*:*) - echo ${UNAME_MACHINE}-unknown-esx - exit ;; -esac - -eval $set_cc_for_build -cat >$dummy.c < -# include -#endif -main () -{ -#if defined (sony) -#if defined (MIPSEB) - /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, - I don't know.... */ - printf ("mips-sony-bsd\n"); exit (0); -#else -#include - printf ("m68k-sony-newsos%s\n", -#ifdef NEWSOS4 - "4" -#else - "" -#endif - ); exit (0); -#endif -#endif - -#if defined (__arm) && defined (__acorn) && defined (__unix) - printf ("arm-acorn-riscix\n"); exit (0); -#endif - -#if defined (hp300) && !defined (hpux) - printf ("m68k-hp-bsd\n"); exit (0); -#endif - -#if defined (NeXT) -#if !defined (__ARCHITECTURE__) -#define __ARCHITECTURE__ "m68k" -#endif - int version; - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; - if (version < 4) - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); - else - printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); - exit (0); -#endif - -#if defined (MULTIMAX) || defined (n16) -#if defined (UMAXV) - printf ("ns32k-encore-sysv\n"); exit (0); -#else -#if defined (CMU) - printf ("ns32k-encore-mach\n"); exit (0); -#else - printf ("ns32k-encore-bsd\n"); exit (0); -#endif -#endif -#endif - -#if defined (__386BSD__) - printf ("i386-pc-bsd\n"); exit (0); -#endif - -#if defined (sequent) -#if defined (i386) - printf ("i386-sequent-dynix\n"); exit (0); -#endif -#if defined (ns32000) - printf ("ns32k-sequent-dynix\n"); exit (0); -#endif -#endif - -#if defined (_SEQUENT_) - struct utsname un; - - uname(&un); - - if (strncmp(un.version, "V2", 2) == 0) { - printf ("i386-sequent-ptx2\n"); exit (0); - } - if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ - printf ("i386-sequent-ptx1\n"); exit (0); - } - printf ("i386-sequent-ptx\n"); exit (0); - -#endif - -#if defined (vax) -# if !defined (ultrix) -# include -# if defined (BSD) -# if BSD == 43 - printf ("vax-dec-bsd4.3\n"); exit (0); -# else -# if BSD == 199006 - printf ("vax-dec-bsd4.3reno\n"); exit (0); -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# endif -# else - printf ("vax-dec-bsd\n"); exit (0); -# endif -# else - printf ("vax-dec-ultrix\n"); exit (0); -# endif -#endif - -#if defined (alliant) && defined (i860) - printf ("i860-alliant-bsd\n"); exit (0); -#endif - - exit (1); -} -EOF - -$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && - { echo "$SYSTEM_NAME"; exit; } - -# Apollos put the system type in the environment. - -test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } - -# Convex versions that predate uname can use getsysinfo(1) - -if [ -x /usr/convex/getsysinfo ] -then - case `getsysinfo -f cpu_type` in - c1*) - echo c1-convex-bsd - exit ;; - c2*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - c34*) - echo c34-convex-bsd - exit ;; - c38*) - echo c38-convex-bsd - exit ;; - c4*) - echo c4-convex-bsd - exit ;; - esac -fi - -cat >&2 < in order to provide the needed -information to handle your system. - -config.guess timestamp = $timestamp - -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null` - -hostinfo = `(hostinfo) 2>/dev/null` -/bin/universe = `(/bin/universe) 2>/dev/null` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` -/bin/arch = `(/bin/arch) 2>/dev/null` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` - -UNAME_MACHINE = ${UNAME_MACHINE} -UNAME_RELEASE = ${UNAME_RELEASE} -UNAME_SYSTEM = ${UNAME_SYSTEM} -UNAME_VERSION = ${UNAME_VERSION} -EOF - -exit 1 - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/libmad/config.h.in b/lib-src/libmad/config.h.in deleted file mode 100644 index 017deb496..000000000 --- a/lib-src/libmad/config.h.in +++ /dev/null @@ -1,214 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2001 Robert Leslie - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: acconfig.h,v 1.2 2001-10-21 22:26:32 dmazzoni Exp $ - */ - -# ifndef LIBMAD_CONFIG_H -# define LIBMAD_CONFIG_H - -/***************************************************************************** - * Definitions selected automatically by `configure' * - *****************************************************************************/ - -/* Define to optimize for speed over accuracy. */ -#undef OPT_SPEED - -/* Define to optimize for accuracy over speed. */ -#undef OPT_ACCURACY - -/* Define to enable a fast subband synthesis approximation optimization. */ -#undef OPT_SSO - -/* Define to influence a strict interpretation of the ISO/IEC standards, - even if this is in opposition with best accepted practices. */ -#undef OPT_STRICT - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#undef HAVE_MADD_ASM - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#undef HAVE_MADD16_ASM - -/* Define to enable diagnostic debugging support. */ -#undef DEBUG - -/* Define to disable debugging assertions. */ -#undef NDEBUG - -/* Define to enable experimental code. */ -#undef EXPERIMENTAL - - -/* Define if building universal (internal helper macro) */ -#undef AC_APPLE_UNIVERSAL_BUILD - -/* Define to enable diagnostic debugging support. */ -#undef DEBUG - -/* Define to enable experimental code. */ -#undef EXPERIMENTAL - -/* Define to 1 if you have the header file. */ -#undef HAVE_ASSERT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_ERRNO_H - -/* Define to 1 if you have the `fcntl' function. */ -#undef HAVE_FCNTL - -/* Define to 1 if you have the header file. */ -#undef HAVE_FCNTL_H - -/* Define to 1 if you have the `fork' function. */ -#undef HAVE_FORK - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIMITS_H - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#undef HAVE_MADD16_ASM - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#undef HAVE_MADD_ASM - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the `pipe' function. */ -#undef HAVE_PIPE - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have that is POSIX.1 compatible. */ -#undef HAVE_SYS_WAIT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if you have the `waitpid' function. */ -#undef HAVE_WAITPID - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#undef LT_OBJDIR - -/* Define to disable debugging assertions. */ -#undef NDEBUG - -/* Define to optimize for accuracy over speed. */ -#undef OPT_ACCURACY - -/* Define to optimize for speed over accuracy. */ -#undef OPT_SPEED - -/* Define to enable a fast subband synthesis approximation optimization. */ -#undef OPT_SSO - -/* Define to influence a strict interpretation of the ISO/IEC standards, even - if this is in opposition with best accepted practices. */ -#undef OPT_STRICT - -/* Name of package */ -#undef PACKAGE - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* The size of `int', as computed by sizeof. */ -#undef SIZEOF_INT - -/* The size of `long', as computed by sizeof. */ -#undef SIZEOF_LONG - -/* The size of `long long', as computed by sizeof. */ -#undef SIZEOF_LONG_LONG - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* Version number of package */ -#undef VERSION - -/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most - significant byte first (like Motorola and SPARC, unlike Intel). */ -#if defined AC_APPLE_UNIVERSAL_BUILD -# if defined __BIG_ENDIAN__ -# define WORDS_BIGENDIAN 1 -# endif -#else -# ifndef WORDS_BIGENDIAN -# undef WORDS_BIGENDIAN -# endif -#endif - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#undef inline -#endif - -/* Define to `int' if does not define. */ -#undef pid_t -/***************************************************************************** - * End of automatically configured definitions * - *****************************************************************************/ - -# endif diff --git a/lib-src/libmad/config.sub b/lib-src/libmad/config.sub deleted file mode 100755 index 9633db704..000000000 --- a/lib-src/libmad/config.sub +++ /dev/null @@ -1,1791 +0,0 @@ -#! /bin/sh -# Configuration validation subroutine script. -# Copyright 1992-2013 Free Software Foundation, Inc. - -timestamp='2013-08-10' - -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). - - -# Please send patches with a ChangeLog entry to config-patches@gnu.org. -# -# Configuration subroutine to validate and canonicalize a configuration type. -# Supply the specified configuration type as an argument. -# If it is invalid, we print an error message on stderr and exit with code 1. -# Otherwise, we print the canonical config type on stdout and succeed. - -# You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD - -# This file is supposed to be the same for all GNU packages -# and recognize all the CPU types, system types and aliases -# that are meaningful with *any* GNU software. -# Each package is responsible for reporting which valid configurations -# it does not support. The user should be able to distinguish -# a failure to support a valid configuration from a meaningless -# configuration. - -# The goal of this file is to map all the various variations of a given -# machine specification into a single specification in the form: -# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM -# or in some cases, the newer four-part form: -# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM -# It is wrong to echo any other type of specification. - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] CPU-MFR-OPSYS - $0 [OPTION] ALIAS - -Canonicalize a configuration name. - -Operation modes: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.sub ($timestamp) - -Copyright 1992-2013 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" - exit 1 ;; - - *local*) - # First pass through any local machine types. - echo $1 - exit ;; - - * ) - break ;; - esac -done - -case $# in - 0) echo "$me: missing argument$help" >&2 - exit 1;; - 1) ;; - *) echo "$me: too many arguments$help" >&2 - exit 1;; -esac - -# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). -# Here we must recognize all the valid KERNEL-OS combinations. -maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` -case $maybe_os in - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ - linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ - knetbsd*-gnu* | netbsd*-gnu* | \ - kopensolaris*-gnu* | \ - storm-chaos* | os2-emx* | rtmk-nova*) - os=-$maybe_os - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` - ;; - android-linux) - os=-linux-android - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown - ;; - *) - basic_machine=`echo $1 | sed 's/-[^-]*$//'` - if [ $basic_machine != $1 ] - then os=`echo $1 | sed 's/.*-/-/'` - else os=; fi - ;; -esac - -### Let's recognize common machines as not being operating systems so -### that things like config.sub decstation-3100 work. We also -### recognize some manufacturers as not being operating systems, so we -### can provide default operating systems below. -case $os in - -sun*os*) - # Prevent following clause from handling this invalid input. - ;; - -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ - -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ - -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ - -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ - -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ - -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray | -microblaze*) - os= - basic_machine=$1 - ;; - -bluegene*) - os=-cnk - ;; - -sim | -cisco | -oki | -wec | -winbond) - os= - basic_machine=$1 - ;; - -scout) - ;; - -wrs) - os=-vxworks - basic_machine=$1 - ;; - -chorusos*) - os=-chorusos - basic_machine=$1 - ;; - -chorusrdb) - os=-chorusrdb - basic_machine=$1 - ;; - -hiux*) - os=-hiuxwe2 - ;; - -sco6) - os=-sco5v6 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5) - os=-sco3.2v5 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco4) - os=-sco3.2v4 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2.[4-9]*) - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco3.2v[4-9]*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco5v6*) - # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -sco*) - os=-sco3.2v2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -udk*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -isc) - os=-isc2.2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -clix*) - basic_machine=clipper-intergraph - ;; - -isc*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` - ;; - -lynx*178) - os=-lynxos178 - ;; - -lynx*5) - os=-lynxos5 - ;; - -lynx*) - os=-lynxos - ;; - -ptx*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` - ;; - -windowsnt*) - os=`echo $os | sed -e 's/windowsnt/winnt/'` - ;; - -psos*) - os=-psos - ;; - -mint | -mint[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; -esac - -# Decode aliases for certain CPU-COMPANY combinations. -case $basic_machine in - # Recognize the basic CPU types without company name. - # Some are omitted here because they have special meanings below. - 1750a | 580 \ - | a29k \ - | aarch64 | aarch64_be \ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ - | am33_2.0 \ - | arc | arceb \ - | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ - | avr | avr32 \ - | be32 | be64 \ - | bfin \ - | c4x | c8051 | clipper \ - | d10v | d30v | dlx | dsp16xx \ - | epiphany \ - | fido | fr30 | frv \ - | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ - | hexagon \ - | i370 | i860 | i960 | ia64 \ - | ip2k | iq2000 \ - | le32 | le64 \ - | lm32 \ - | m32c | m32r | m32rle | m68000 | m68k | m88k \ - | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ - | mips | mipsbe | mipseb | mipsel | mipsle \ - | mips16 \ - | mips64 | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ - | mips64vr | mips64vrel \ - | mips64vr4100 | mips64vr4100el \ - | mips64vr4300 | mips64vr4300el \ - | mips64vr5000 | mips64vr5000el \ - | mips64vr5900 | mips64vr5900el \ - | mipsisa32 | mipsisa32el \ - | mipsisa32r2 | mipsisa32r2el \ - | mipsisa64 | mipsisa64el \ - | mipsisa64r2 | mipsisa64r2el \ - | mipsisa64sb1 | mipsisa64sb1el \ - | mipsisa64sr71k | mipsisa64sr71kel \ - | mipsr5900 | mipsr5900el \ - | mipstx39 | mipstx39el \ - | mn10200 | mn10300 \ - | moxie \ - | mt \ - | msp430 \ - | nds32 | nds32le | nds32be \ - | nios | nios2 | nios2eb | nios2el \ - | ns16k | ns32k \ - | open8 \ - | or1k | or32 \ - | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle \ - | pyramid \ - | rl78 | rx \ - | score \ - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ - | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ - | spu \ - | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ - | ubicom32 \ - | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ - | we32k \ - | x86 | xc16x | xstormy16 | xtensa \ - | z8k | z80) - basic_machine=$basic_machine-unknown - ;; - c54x) - basic_machine=tic54x-unknown - ;; - c55x) - basic_machine=tic55x-unknown - ;; - c6x) - basic_machine=tic6x-unknown - ;; - m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip) - basic_machine=$basic_machine-unknown - os=-none - ;; - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) - ;; - ms1) - basic_machine=mt-unknown - ;; - - strongarm | thumb | xscale) - basic_machine=arm-unknown - ;; - xgate) - basic_machine=$basic_machine-unknown - os=-none - ;; - xscaleeb) - basic_machine=armeb-unknown - ;; - - xscaleel) - basic_machine=armel-unknown - ;; - - # We use `pc' rather than `unknown' - # because (1) that's what they normally are, and - # (2) the word "unknown" tends to confuse beginning users. - i*86 | x86_64) - basic_machine=$basic_machine-pc - ;; - # Object if more than one company name word. - *-*-*) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; - # Recognize the basic CPU types with company name. - 580-* \ - | a29k-* \ - | aarch64-* | aarch64_be-* \ - | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ - | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ - | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ - | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* | avr32-* \ - | be32-* | be64-* \ - | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* \ - | c8051-* | clipper-* | craynv-* | cydra-* \ - | d10v-* | d30v-* | dlx-* \ - | elxsi-* \ - | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ - | h8300-* | h8500-* \ - | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ - | hexagon-* \ - | i*86-* | i860-* | i960-* | ia64-* \ - | ip2k-* | iq2000-* \ - | le32-* | le64-* \ - | lm32-* \ - | m32c-* | m32r-* | m32rle-* \ - | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ - | microblaze-* | microblazeel-* \ - | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ - | mips16-* \ - | mips64-* | mips64el-* \ - | mips64octeon-* | mips64octeonel-* \ - | mips64orion-* | mips64orionel-* \ - | mips64r5900-* | mips64r5900el-* \ - | mips64vr-* | mips64vrel-* \ - | mips64vr4100-* | mips64vr4100el-* \ - | mips64vr4300-* | mips64vr4300el-* \ - | mips64vr5000-* | mips64vr5000el-* \ - | mips64vr5900-* | mips64vr5900el-* \ - | mipsisa32-* | mipsisa32el-* \ - | mipsisa32r2-* | mipsisa32r2el-* \ - | mipsisa64-* | mipsisa64el-* \ - | mipsisa64r2-* | mipsisa64r2el-* \ - | mipsisa64sb1-* | mipsisa64sb1el-* \ - | mipsisa64sr71k-* | mipsisa64sr71kel-* \ - | mipsr5900-* | mipsr5900el-* \ - | mipstx39-* | mipstx39el-* \ - | mmix-* \ - | mt-* \ - | msp430-* \ - | nds32-* | nds32le-* | nds32be-* \ - | nios-* | nios2-* | nios2eb-* | nios2el-* \ - | none-* | np1-* | ns16k-* | ns32k-* \ - | open8-* \ - | orion-* \ - | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ - | pyramid-* \ - | rl78-* | romp-* | rs6000-* | rx-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ - | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ - | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ - | tahoe-* \ - | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ - | tile*-* \ - | tron-* \ - | ubicom32-* \ - | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ - | vax-* \ - | we32k-* \ - | x86-* | x86_64-* | xc16x-* | xps100-* \ - | xstormy16-* | xtensa*-* \ - | ymp-* \ - | z8k-* | z80-*) - ;; - # Recognize the basic CPU types without company name, with glob match. - xtensa*) - basic_machine=$basic_machine-unknown - ;; - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. - 386bsd) - basic_machine=i386-unknown - os=-bsd - ;; - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) - basic_machine=m68000-att - ;; - 3b*) - basic_machine=we32k-att - ;; - a29khif) - basic_machine=a29k-amd - os=-udi - ;; - abacus) - basic_machine=abacus-unknown - ;; - adobe68k) - basic_machine=m68010-adobe - os=-scout - ;; - alliant | fx80) - basic_machine=fx80-alliant - ;; - altos | altos3068) - basic_machine=m68k-altos - ;; - am29k) - basic_machine=a29k-none - os=-bsd - ;; - amd64) - basic_machine=x86_64-pc - ;; - amd64-*) - basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - amdahl) - basic_machine=580-amdahl - os=-sysv - ;; - amiga | amiga-*) - basic_machine=m68k-unknown - ;; - amigaos | amigados) - basic_machine=m68k-unknown - os=-amigaos - ;; - amigaunix | amix) - basic_machine=m68k-unknown - os=-sysv4 - ;; - apollo68) - basic_machine=m68k-apollo - os=-sysv - ;; - apollo68bsd) - basic_machine=m68k-apollo - os=-bsd - ;; - aros) - basic_machine=i386-pc - os=-aros - ;; - aux) - basic_machine=m68k-apple - os=-aux - ;; - balance) - basic_machine=ns32k-sequent - os=-dynix - ;; - blackfin) - basic_machine=bfin-unknown - os=-linux - ;; - blackfin-*) - basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - bluegene*) - basic_machine=powerpc-ibm - os=-cnk - ;; - c54x-*) - basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c55x-*) - basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c6x-*) - basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - c90) - basic_machine=c90-cray - os=-unicos - ;; - cegcc) - basic_machine=arm-unknown - os=-cegcc - ;; - convex-c1) - basic_machine=c1-convex - os=-bsd - ;; - convex-c2) - basic_machine=c2-convex - os=-bsd - ;; - convex-c32) - basic_machine=c32-convex - os=-bsd - ;; - convex-c34) - basic_machine=c34-convex - os=-bsd - ;; - convex-c38) - basic_machine=c38-convex - os=-bsd - ;; - cray | j90) - basic_machine=j90-cray - os=-unicos - ;; - craynv) - basic_machine=craynv-cray - os=-unicosmp - ;; - cr16 | cr16-*) - basic_machine=cr16-unknown - os=-elf - ;; - crds | unos) - basic_machine=m68k-crds - ;; - crisv32 | crisv32-* | etraxfs*) - basic_machine=crisv32-axis - ;; - cris | cris-* | etrax*) - basic_machine=cris-axis - ;; - crx) - basic_machine=crx-unknown - os=-elf - ;; - da30 | da30-*) - basic_machine=m68k-da30 - ;; - decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) - basic_machine=mips-dec - ;; - decsystem10* | dec10*) - basic_machine=pdp10-dec - os=-tops10 - ;; - decsystem20* | dec20*) - basic_machine=pdp10-dec - os=-tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) - basic_machine=m68k-motorola - ;; - delta88) - basic_machine=m88k-motorola - os=-sysv3 - ;; - dicos) - basic_machine=i686-pc - os=-dicos - ;; - djgpp) - basic_machine=i586-pc - os=-msdosdjgpp - ;; - dpx20 | dpx20-*) - basic_machine=rs6000-bull - os=-bosx - ;; - dpx2* | dpx2*-bull) - basic_machine=m68k-bull - os=-sysv3 - ;; - ebmon29k) - basic_machine=a29k-amd - os=-ebmon - ;; - elxsi) - basic_machine=elxsi-elxsi - os=-bsd - ;; - encore | umax | mmax) - basic_machine=ns32k-encore - ;; - es1800 | OSE68k | ose68k | ose | OSE) - basic_machine=m68k-ericsson - os=-ose - ;; - fx2800) - basic_machine=i860-alliant - ;; - genix) - basic_machine=ns32k-ns - ;; - gmicro) - basic_machine=tron-gmicro - os=-sysv - ;; - go32) - basic_machine=i386-pc - os=-go32 - ;; - h3050r* | hiux*) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - h8300hms) - basic_machine=h8300-hitachi - os=-hms - ;; - h8300xray) - basic_machine=h8300-hitachi - os=-xray - ;; - h8500hms) - basic_machine=h8500-hitachi - os=-hms - ;; - harris) - basic_machine=m88k-harris - os=-sysv3 - ;; - hp300-*) - basic_machine=m68k-hp - ;; - hp300bsd) - basic_machine=m68k-hp - os=-bsd - ;; - hp300hpux) - basic_machine=m68k-hp - os=-hpux - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) - basic_machine=m68000-hp - ;; - hp9k3[2-9][0-9]) - basic_machine=m68k-hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) - basic_machine=hppa1.1-hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) - # FIXME: really hppa2.0-hp - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) - basic_machine=hppa1.1-hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) - basic_machine=hppa1.0-hp - ;; - hppa-next) - os=-nextstep3 - ;; - hppaosf) - basic_machine=hppa1.1-hp - os=-osf - ;; - hppro) - basic_machine=hppa1.1-hp - os=-proelf - ;; - i370-ibm* | ibm*) - basic_machine=i370-ibm - ;; - i*86v32) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv32 - ;; - i*86v4*) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv4 - ;; - i*86v) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-sysv - ;; - i*86sol2) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` - os=-solaris2 - ;; - i386mach) - basic_machine=i386-mach - os=-mach - ;; - i386-vsta | vsta) - basic_machine=i386-unknown - os=-vsta - ;; - iris | iris4d) - basic_machine=mips-sgi - case $os in - -irix*) - ;; - *) - os=-irix4 - ;; - esac - ;; - isi68 | isi) - basic_machine=m68k-isi - os=-sysv - ;; - m68knommu) - basic_machine=m68k-unknown - os=-linux - ;; - m68knommu-*) - basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - m88k-omron*) - basic_machine=m88k-omron - ;; - magnum | m3230) - basic_machine=mips-mips - os=-sysv - ;; - merlin) - basic_machine=ns32k-utek - os=-sysv - ;; - microblaze*) - basic_machine=microblaze-xilinx - ;; - mingw64) - basic_machine=x86_64-pc - os=-mingw64 - ;; - mingw32) - basic_machine=i686-pc - os=-mingw32 - ;; - mingw32ce) - basic_machine=arm-unknown - os=-mingw32ce - ;; - miniframe) - basic_machine=m68000-convergent - ;; - *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) - basic_machine=m68k-atari - os=-mint - ;; - mips3*-*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` - ;; - mips3*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown - ;; - monitor) - basic_machine=m68k-rom68k - os=-coff - ;; - morphos) - basic_machine=powerpc-unknown - os=-morphos - ;; - msdos) - basic_machine=i386-pc - os=-msdos - ;; - ms1-*) - basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` - ;; - msys) - basic_machine=i686-pc - os=-msys - ;; - mvs) - basic_machine=i370-ibm - os=-mvs - ;; - nacl) - basic_machine=le32-unknown - os=-nacl - ;; - ncr3000) - basic_machine=i486-ncr - os=-sysv4 - ;; - netbsd386) - basic_machine=i386-unknown - os=-netbsd - ;; - netwinder) - basic_machine=armv4l-rebel - os=-linux - ;; - news | news700 | news800 | news900) - basic_machine=m68k-sony - os=-newsos - ;; - news1000) - basic_machine=m68030-sony - os=-newsos - ;; - news-3600 | risc-news) - basic_machine=mips-sony - os=-newsos - ;; - necv70) - basic_machine=v70-nec - os=-sysv - ;; - next | m*-next ) - basic_machine=m68k-next - case $os in - -nextstep* ) - ;; - -ns2*) - os=-nextstep2 - ;; - *) - os=-nextstep3 - ;; - esac - ;; - nh3000) - basic_machine=m68k-harris - os=-cxux - ;; - nh[45]000) - basic_machine=m88k-harris - os=-cxux - ;; - nindy960) - basic_machine=i960-intel - os=-nindy - ;; - mon960) - basic_machine=i960-intel - os=-mon960 - ;; - nonstopux) - basic_machine=mips-compaq - os=-nonstopux - ;; - np1) - basic_machine=np1-gould - ;; - neo-tandem) - basic_machine=neo-tandem - ;; - nse-tandem) - basic_machine=nse-tandem - ;; - nsr-tandem) - basic_machine=nsr-tandem - ;; - op50n-* | op60c-*) - basic_machine=hppa1.1-oki - os=-proelf - ;; - openrisc | openrisc-*) - basic_machine=or32-unknown - ;; - os400) - basic_machine=powerpc-ibm - os=-os400 - ;; - OSE68000 | ose68000) - basic_machine=m68000-ericsson - os=-ose - ;; - os68k) - basic_machine=m68k-none - os=-os68k - ;; - pa-hitachi) - basic_machine=hppa1.1-hitachi - os=-hiuxwe2 - ;; - paragon) - basic_machine=i860-intel - os=-osf - ;; - parisc) - basic_machine=hppa-unknown - os=-linux - ;; - parisc-*) - basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` - os=-linux - ;; - pbd) - basic_machine=sparc-tti - ;; - pbb) - basic_machine=m68k-tti - ;; - pc532 | pc532-*) - basic_machine=ns32k-pc532 - ;; - pc98) - basic_machine=i386-pc - ;; - pc98-*) - basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium | p5 | k5 | k6 | nexgen | viac3) - basic_machine=i586-pc - ;; - pentiumpro | p6 | 6x86 | athlon | athlon_*) - basic_machine=i686-pc - ;; - pentiumii | pentium2 | pentiumiii | pentium3) - basic_machine=i686-pc - ;; - pentium4) - basic_machine=i786-pc - ;; - pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) - basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumpro-* | p6-* | 6x86-* | athlon-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pentium4-*) - basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - pn) - basic_machine=pn-gould - ;; - power) basic_machine=power-ibm - ;; - ppc | ppcbe) basic_machine=powerpc-unknown - ;; - ppc-* | ppcbe-*) - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppcle | powerpclittle | ppc-le | powerpc-little) - basic_machine=powerpcle-unknown - ;; - ppcle-* | powerpclittle-*) - basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64) basic_machine=powerpc64-unknown - ;; - ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ppc64le | powerpc64little | ppc64-le | powerpc64-little) - basic_machine=powerpc64le-unknown - ;; - ppc64le-* | powerpc64little-*) - basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - ps2) - basic_machine=i386-ibm - ;; - pw32) - basic_machine=i586-unknown - os=-pw32 - ;; - rdos | rdos64) - basic_machine=x86_64-pc - os=-rdos - ;; - rdos32) - basic_machine=i386-pc - os=-rdos - ;; - rom68k) - basic_machine=m68k-rom68k - os=-coff - ;; - rm[46]00) - basic_machine=mips-siemens - ;; - rtpc | rtpc-*) - basic_machine=romp-ibm - ;; - s390 | s390-*) - basic_machine=s390-ibm - ;; - s390x | s390x-*) - basic_machine=s390x-ibm - ;; - sa29200) - basic_machine=a29k-amd - os=-udi - ;; - sb1) - basic_machine=mipsisa64sb1-unknown - ;; - sb1el) - basic_machine=mipsisa64sb1el-unknown - ;; - sde) - basic_machine=mipsisa32-sde - os=-elf - ;; - sei) - basic_machine=mips-sei - os=-seiux - ;; - sequent) - basic_machine=i386-sequent - ;; - sh) - basic_machine=sh-hitachi - os=-hms - ;; - sh5el) - basic_machine=sh5le-unknown - ;; - sh64) - basic_machine=sh64-unknown - ;; - sparclite-wrs | simso-wrs) - basic_machine=sparclite-wrs - os=-vxworks - ;; - sps7) - basic_machine=m68k-bull - os=-sysv2 - ;; - spur) - basic_machine=spur-unknown - ;; - st2000) - basic_machine=m68k-tandem - ;; - stratus) - basic_machine=i860-stratus - os=-sysv4 - ;; - strongarm-* | thumb-*) - basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` - ;; - sun2) - basic_machine=m68000-sun - ;; - sun2os3) - basic_machine=m68000-sun - os=-sunos3 - ;; - sun2os4) - basic_machine=m68000-sun - os=-sunos4 - ;; - sun3os3) - basic_machine=m68k-sun - os=-sunos3 - ;; - sun3os4) - basic_machine=m68k-sun - os=-sunos4 - ;; - sun4os3) - basic_machine=sparc-sun - os=-sunos3 - ;; - sun4os4) - basic_machine=sparc-sun - os=-sunos4 - ;; - sun4sol2) - basic_machine=sparc-sun - os=-solaris2 - ;; - sun3 | sun3-*) - basic_machine=m68k-sun - ;; - sun4) - basic_machine=sparc-sun - ;; - sun386 | sun386i | roadrunner) - basic_machine=i386-sun - ;; - sv1) - basic_machine=sv1-cray - os=-unicos - ;; - symmetry) - basic_machine=i386-sequent - os=-dynix - ;; - t3e) - basic_machine=alphaev5-cray - os=-unicos - ;; - t90) - basic_machine=t90-cray - os=-unicos - ;; - tile*) - basic_machine=$basic_machine-unknown - os=-linux-gnu - ;; - tx39) - basic_machine=mipstx39-unknown - ;; - tx39el) - basic_machine=mipstx39el-unknown - ;; - toad1) - basic_machine=pdp10-xkl - os=-tops20 - ;; - tower | tower-32) - basic_machine=m68k-ncr - ;; - tpf) - basic_machine=s390x-ibm - os=-tpf - ;; - udi29k) - basic_machine=a29k-amd - os=-udi - ;; - ultra3) - basic_machine=a29k-nyu - os=-sym1 - ;; - v810 | necv810) - basic_machine=v810-nec - os=-none - ;; - vaxv) - basic_machine=vax-dec - os=-sysv - ;; - vms) - basic_machine=vax-dec - os=-vms - ;; - vpp*|vx|vx-*) - basic_machine=f301-fujitsu - ;; - vxworks960) - basic_machine=i960-wrs - os=-vxworks - ;; - vxworks68) - basic_machine=m68k-wrs - os=-vxworks - ;; - vxworks29k) - basic_machine=a29k-wrs - os=-vxworks - ;; - w65*) - basic_machine=w65-wdc - os=-none - ;; - w89k-*) - basic_machine=hppa1.1-winbond - os=-proelf - ;; - xbox) - basic_machine=i686-pc - os=-mingw32 - ;; - xps | xps100) - basic_machine=xps100-honeywell - ;; - xscale-* | xscalee[bl]-*) - basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` - ;; - ymp) - basic_machine=ymp-cray - os=-unicos - ;; - z8k-*-coff) - basic_machine=z8k-unknown - os=-sim - ;; - z80-*-coff) - basic_machine=z80-unknown - os=-sim - ;; - none) - basic_machine=none-none - os=-none - ;; - -# Here we handle the default manufacturer of certain CPU types. It is in -# some cases the only manufacturer, in others, it is the most popular. - w89k) - basic_machine=hppa1.1-winbond - ;; - op50n) - basic_machine=hppa1.1-oki - ;; - op60c) - basic_machine=hppa1.1-oki - ;; - romp) - basic_machine=romp-ibm - ;; - mmix) - basic_machine=mmix-knuth - ;; - rs6000) - basic_machine=rs6000-ibm - ;; - vax) - basic_machine=vax-dec - ;; - pdp10) - # there are many clones, so DEC is not a safe bet - basic_machine=pdp10-unknown - ;; - pdp11) - basic_machine=pdp11-dec - ;; - we32k) - basic_machine=we32k-att - ;; - sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) - basic_machine=sh-unknown - ;; - sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) - basic_machine=sparc-sun - ;; - cydra) - basic_machine=cydra-cydrome - ;; - orion) - basic_machine=orion-highlevel - ;; - orion105) - basic_machine=clipper-highlevel - ;; - mac | mpw | mac-mpw) - basic_machine=m68k-apple - ;; - pmac | pmac-mpw) - basic_machine=powerpc-apple - ;; - *-unknown) - # Make sure to match an already-canonicalized machine name. - ;; - *) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 - exit 1 - ;; -esac - -# Here we canonicalize certain aliases for manufacturers. -case $basic_machine in - *-digital*) - basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` - ;; - *-commodore*) - basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` - ;; - *) - ;; -esac - -# Decode manufacturer-specific aliases for certain operating systems. - -if [ x"$os" != x"" ] -then -case $os in - # First match some system type aliases - # that might get confused with valid system types. - # -solaris* is a basic system type, with this one exception. - -auroraux) - os=-auroraux - ;; - -solaris1 | -solaris1.*) - os=`echo $os | sed -e 's|solaris1|sunos4|'` - ;; - -solaris) - os=-solaris2 - ;; - -svr4*) - os=-sysv4 - ;; - -unixware*) - os=-sysv4.2uw - ;; - -gnu/linux*) - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` - ;; - # First accept the basic system types. - # The portable systems comes first. - # Each alternative MUST END IN A *, to match a version number. - # -sysv* is not here because it comes later, after sysvr4. - -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ - | -sym* | -kopensolaris* | -plan9* \ - | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* | -aros* \ - | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ - | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ - | -bitrig* | -openbsd* | -solidbsd* \ - | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ - | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ - | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ - | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* | -cegcc* \ - | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ - | -linux-newlib* | -linux-musl* | -linux-uclibc* \ - | -uxpv* | -beos* | -mpeix* | -udk* \ - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ - | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ - | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ - | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ - | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) - # Remember, each alternative MUST END IN *, to match a version number. - ;; - -qnx*) - case $basic_machine in - x86-* | i*86-*) - ;; - *) - os=-nto$os - ;; - esac - ;; - -nto-qnx*) - ;; - -nto*) - os=`echo $os | sed -e 's|nto|nto-qnx|'` - ;; - -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ - | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ - | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) - ;; - -mac*) - os=`echo $os | sed -e 's|mac|macos|'` - ;; - -linux-dietlibc) - os=-linux-dietlibc - ;; - -linux*) - os=`echo $os | sed -e 's|linux|linux-gnu|'` - ;; - -sunos5*) - os=`echo $os | sed -e 's|sunos5|solaris2|'` - ;; - -sunos6*) - os=`echo $os | sed -e 's|sunos6|solaris3|'` - ;; - -opened*) - os=-openedition - ;; - -os400*) - os=-os400 - ;; - -wince*) - os=-wince - ;; - -osfrose*) - os=-osfrose - ;; - -osf*) - os=-osf - ;; - -utek*) - os=-bsd - ;; - -dynix*) - os=-bsd - ;; - -acis*) - os=-aos - ;; - -atheos*) - os=-atheos - ;; - -syllable*) - os=-syllable - ;; - -386bsd) - os=-bsd - ;; - -ctix* | -uts*) - os=-sysv - ;; - -nova*) - os=-rtmk-nova - ;; - -ns2 ) - os=-nextstep2 - ;; - -nsk*) - os=-nsk - ;; - # Preserve the version number of sinix5. - -sinix5.*) - os=`echo $os | sed -e 's|sinix|sysv|'` - ;; - -sinix*) - os=-sysv4 - ;; - -tpf*) - os=-tpf - ;; - -triton*) - os=-sysv3 - ;; - -oss*) - os=-sysv3 - ;; - -svr4) - os=-sysv4 - ;; - -svr3) - os=-sysv3 - ;; - -sysvr4) - os=-sysv4 - ;; - # This must come after -sysvr4. - -sysv*) - ;; - -ose*) - os=-ose - ;; - -es1800*) - os=-ose - ;; - -xenix) - os=-xenix - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - os=-mint - ;; - -aros*) - os=-aros - ;; - -zvmoe) - os=-zvmoe - ;; - -dicos*) - os=-dicos - ;; - -nacl*) - ;; - -none) - ;; - *) - # Get rid of the `-' at the beginning of $os. - os=`echo $os | sed 's/[^-]*-//'` - echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 - exit 1 - ;; -esac -else - -# Here we handle the default operating systems that come with various machines. -# The value should be what the vendor currently ships out the door with their -# machine or put another way, the most popular os provided with the machine. - -# Note that if you're going to try to match "-MANUFACTURER" here (say, -# "-sun"), then you have to tell the case statement up towards the top -# that MANUFACTURER isn't an operating system. Otherwise, code above -# will signal an error saying that MANUFACTURER isn't an operating -# system, and we'll never get to this point. - -case $basic_machine in - score-*) - os=-elf - ;; - spu-*) - os=-elf - ;; - *-acorn) - os=-riscix1.2 - ;; - arm*-rebel) - os=-linux - ;; - arm*-semi) - os=-aout - ;; - c4x-* | tic4x-*) - os=-coff - ;; - c8051-*) - os=-elf - ;; - hexagon-*) - os=-elf - ;; - tic54x-*) - os=-coff - ;; - tic55x-*) - os=-coff - ;; - tic6x-*) - os=-coff - ;; - # This must come before the *-dec entry. - pdp10-*) - os=-tops20 - ;; - pdp11-*) - os=-none - ;; - *-dec | vax-*) - os=-ultrix4.2 - ;; - m68*-apollo) - os=-domain - ;; - i386-sun) - os=-sunos4.0.2 - ;; - m68000-sun) - os=-sunos3 - ;; - m68*-cisco) - os=-aout - ;; - mep-*) - os=-elf - ;; - mips*-cisco) - os=-elf - ;; - mips*-*) - os=-elf - ;; - or1k-*) - os=-elf - ;; - or32-*) - os=-coff - ;; - *-tti) # must be before sparc entry or we get the wrong os. - os=-sysv3 - ;; - sparc-* | *-sun) - os=-sunos4.1.1 - ;; - *-be) - os=-beos - ;; - *-haiku) - os=-haiku - ;; - *-ibm) - os=-aix - ;; - *-knuth) - os=-mmixware - ;; - *-wec) - os=-proelf - ;; - *-winbond) - os=-proelf - ;; - *-oki) - os=-proelf - ;; - *-hp) - os=-hpux - ;; - *-hitachi) - os=-hiux - ;; - i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) - os=-sysv - ;; - *-cbm) - os=-amigaos - ;; - *-dg) - os=-dgux - ;; - *-dolphin) - os=-sysv3 - ;; - m68k-ccur) - os=-rtu - ;; - m88k-omron*) - os=-luna - ;; - *-next ) - os=-nextstep - ;; - *-sequent) - os=-ptx - ;; - *-crds) - os=-unos - ;; - *-ns) - os=-genix - ;; - i370-*) - os=-mvs - ;; - *-next) - os=-nextstep3 - ;; - *-gould) - os=-sysv - ;; - *-highlevel) - os=-bsd - ;; - *-encore) - os=-bsd - ;; - *-sgi) - os=-irix - ;; - *-siemens) - os=-sysv4 - ;; - *-masscomp) - os=-rtu - ;; - f30[01]-fujitsu | f700-fujitsu) - os=-uxpv - ;; - *-rom68k) - os=-coff - ;; - *-*bug) - os=-coff - ;; - *-apple) - os=-macos - ;; - *-atari*) - os=-mint - ;; - *) - os=-none - ;; -esac -fi - -# Here we handle the case where we know the os, and the CPU type, but not the -# manufacturer. We pick the logical manufacturer. -vendor=unknown -case $basic_machine in - *-unknown) - case $os in - -riscix*) - vendor=acorn - ;; - -sunos*) - vendor=sun - ;; - -cnk*|-aix*) - vendor=ibm - ;; - -beos*) - vendor=be - ;; - -hpux*) - vendor=hp - ;; - -mpeix*) - vendor=hp - ;; - -hiux*) - vendor=hitachi - ;; - -unos*) - vendor=crds - ;; - -dgux*) - vendor=dg - ;; - -luna*) - vendor=omron - ;; - -genix*) - vendor=ns - ;; - -mvs* | -opened*) - vendor=ibm - ;; - -os400*) - vendor=ibm - ;; - -ptx*) - vendor=sequent - ;; - -tpf*) - vendor=ibm - ;; - -vxsim* | -vxworks* | -windiss*) - vendor=wrs - ;; - -aux*) - vendor=apple - ;; - -hms*) - vendor=hitachi - ;; - -mpw* | -macos*) - vendor=apple - ;; - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) - vendor=atari - ;; - -vos*) - vendor=stratus - ;; - esac - basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` - ;; -esac - -echo $basic_machine$os -exit - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib-src/libmad/configunix.h.in b/lib-src/libmad/configunix.h.in deleted file mode 100644 index edad9682b..000000000 --- a/lib-src/libmad/configunix.h.in +++ /dev/null @@ -1,159 +0,0 @@ -/* configunix.h.in. Generated from configure.in by autoheader. */ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2001 Robert Leslie - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: configunix.h.in,v 1.5 2005-09-12 07:01:29 dmazzoni Exp $ - */ - -# ifndef LIBMAD_CONFIG_H -# define LIBMAD_CONFIG_H - -/***************************************************************************** - * Definitions selected automatically by `configure' * - *****************************************************************************/ - -/* Define to optimize for speed over accuracy. */ -#undef OPT_SPEED - -/* Define to optimize for accuracy over speed. */ -#undef OPT_ACCURACY - -/* Define to enable a fast subband synthesis approximation optimization. */ -#undef OPT_SSO - -/* Define to influence a strict interpretation of the ISO/IEC standards, - even if this is in opposition with best accepted practices. */ -#undef OPT_STRICT - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -#undef HAVE_MADD_ASM - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -#undef HAVE_MADD16_ASM - -/* Define to enable diagnostic debugging support. */ -#undef DEBUG - -/* Define to disable debugging assertions. */ -#undef NDEBUG - -/* Define to enable experimental code. */ -#undef EXPERIMENTAL - - -/* Define to 1 if you have the header file. */ -#undef HAVE_ASSERT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_ERRNO_H - -/* Define to 1 if you have the `fcntl' function. */ -#undef HAVE_FCNTL - -/* Define to 1 if you have the header file. */ -#undef HAVE_FCNTL_H - -/* Define to 1 if you have the `fork' function. */ -#undef HAVE_FORK - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIMITS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the `pipe' function. */ -#undef HAVE_PIPE - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have that is POSIX.1 compatible. */ -#undef HAVE_SYS_WAIT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if you have the `waitpid' function. */ -#undef HAVE_WAITPID - -/* Name of package */ -#undef PACKAGE - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* The size of a `int', as computed by sizeof. */ -#undef SIZEOF_INT - -/* The size of a `long', as computed by sizeof. */ -#undef SIZEOF_LONG - -/* The size of a `long long', as computed by sizeof. */ -#undef SIZEOF_LONG_LONG - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* Version number of package */ -#undef VERSION - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define as `__inline' if that's what the C compiler calls it, or to nothing - if it is not supported. */ -#undef inline - -/* Define to `int' if does not define. */ -#undef pid_t -/***************************************************************************** - * End of automatically configured definitions * - *****************************************************************************/ - -# endif diff --git a/lib-src/libmad/configure b/lib-src/libmad/configure deleted file mode 100755 index 5999c394d..000000000 --- a/lib-src/libmad/configure +++ /dev/null @@ -1,15382 +0,0 @@ -#! /bin/sh -# From configure.ac Id: configure.ac,v 1.4 2009-01-17 22:01:06 richardash1981 Exp . -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for MPEG Audio Decoder 0.15.1b. -# -# Report bugs to . -# -# -# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# Use a proper internal environment variable to ensure we don't fall - # into an infinite loop, continuously re-executing ourselves. - if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then - _as_can_reexec=no; export _as_can_reexec; - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -as_fn_exit 255 - fi - # We don't want this to propagate to other subprocesses. - { _as_can_reexec=; unset _as_can_reexec;} -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : - -else - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1 -test -x / || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 - - test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ - || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" - if (eval "$as_required") 2>/dev/null; then : - as_have_required=yes -else - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : - -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : - CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : - break 2 -fi -fi - done;; - esac - as_found=false -done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } -IFS=$as_save_IFS - - - if test "x$CONFIG_SHELL" != x; then : - export CONFIG_SHELL - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 -fi - - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." - else - $as_echo "$0: Please tell bug-autoconf@gnu.org and -$0: support@underbit.com about your system, including any -$0: error possibly output before this message. Then install -$0: a modern shell, or manually run the script under such a -$0: shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # If we had to re-execute with $CONFIG_SHELL, we're ensured to have - # already done that, so ensure we don't try to do so again and fall - # in an infinite loop. This has already happened in practice. - _as_can_reexec=no; export _as_can_reexec - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - -SHELL=${CONFIG_SHELL-/bin/sh} - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME='MPEG Audio Decoder' -PACKAGE_TARNAME='libmad' -PACKAGE_VERSION='0.15.1b' -PACKAGE_STRING='MPEG Audio Decoder 0.15.1b' -PACKAGE_BUGREPORT='support@underbit.com' -PACKAGE_URL='' - -ac_unique_file="decoder.h" -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef STDC_HEADERS -# include -# include -#else -# ifdef HAVE_STDLIB_H -# include -# endif -#endif -#ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include -# endif -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_subst_vars='am__EXEEXT_FALSE -am__EXEEXT_TRUE -LTLIBOBJS -LIBOBJS -ASO_OBJS -ASO -FPM -LIBTOOL_DEPS -CPP -OTOOL64 -OTOOL -LIPO -NMEDIT -DSYMUTIL -MANIFEST_TOOL -RANLIB -ac_ct_AR -AR -DLLTOOL -OBJDUMP -LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP -EGREP -GREP -SED -LIBTOOL -am__fastdepCCAS_FALSE -am__fastdepCCAS_TRUE -CCASDEPMODE -CCASFLAGS -CCAS -am__fastdepCC_FALSE -am__fastdepCC_TRUE -CCDEPMODE -am__nodep -AMDEPBACKSLASH -AMDEP_FALSE -AMDEP_TRUE -am__quote -am__include -DEPDIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -host_os -host_vendor -host_cpu -host -build_os -build_vendor -build_cpu -build -MAINT -MAINTAINER_MODE_FALSE -MAINTAINER_MODE_TRUE -AM_BACKSLASH -AM_DEFAULT_VERBOSITY -AM_DEFAULT_V -AM_V -am__untar -am__tar -AMTAR -am__leading_dot -SET_MAKE -AWK -mkdir_p -MKDIR_P -INSTALL_STRIP_PROGRAM -STRIP -install_sh -MAKEINFO -AUTOHEADER -AUTOMAKE -AUTOCONF -ACLOCAL -VERSION -PACKAGE -CYGPATH_W -am__isrc -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_silent_rules -enable_maintainer_mode -enable_dependency_tracking -enable_shared -enable_static -with_pic -enable_fast_install -with_gnu_ld -with_sysroot -enable_libtool_lock -enable_speed -enable_accuracy -enable_fpm -enable_sso -enable_aso -enable_strict_iso -enable_profiling -enable_debugging -enable_experimental -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -CCAS -CCASFLAGS -CPP' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *=) ac_optarg= ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error $? "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information" - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error $? "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error $? "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error $? "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures MPEG Audio Decoder 0.15.1b to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking ...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/libmad] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names - -System types: - --build=BUILD configure for building on BUILD [guessed] - --host=HOST cross-compile to build programs to run on HOST [BUILD] -_ACEOF -fi - -if test -n "$ac_init_help"; then - case $ac_init_help in - short | recursive ) echo "Configuration of MPEG Audio Decoder 0.15.1b:";; - esac - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-silent-rules less verbose build output (undo: "make V=1") - --disable-silent-rules verbose build output (undo: "make V=0") - --enable-maintainer-mode - enable make rules and dependencies not useful (and - sometimes confusing) to the casual installer - --enable-dependency-tracking - do not reject slow dependency extractors - --disable-dependency-tracking - speeds up one-time build - --enable-shared[=PKGS] build shared libraries [default=yes] - --enable-static[=PKGS] build static libraries [default=yes] - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) - --enable-speed optimize for speed over accuracy - --enable-accuracy optimize for accuracy over speed - --enable-fpm=ARCH use ARCH-specific fixed-point math routines (one of: - intel, arm, mips, sparc, ppc, 64bit, default) - --enable-sso use subband synthesis optimization - --disable-aso disable architecture-specific optimizations - --enable-strict-iso use strict ISO/IEC interpretations - --enable-profiling generate profiling code - --enable-debugging enable diagnostic debugging support - --disable-debugging do not enable debugging and use more optimization - --enable-experimental enable experimental code - -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use - both] - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-sysroot=DIR Search for dependent libraries within DIR - (or the compiler's sysroot if not specified). - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - CCAS assembler compiler command (defaults to CC) - CCASFLAGS assembler compiler flags (defaults to CFLAGS) - CPP C preprocessor - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to . -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -MPEG Audio Decoder configure 0.15.1b -generated by GNU Autoconf 2.69 - -Copyright (C) 2012 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link - -# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists and can be compiled using the include files in -# INCLUDES, setting the cache variable VAR accordingly. -ac_fn_c_check_header_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_compile - -# ac_fn_c_try_cpp LINENO -# ---------------------- -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_cpp - -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : - ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_run - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_func - -# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists, giving a warning if it cannot be compiled using -# the include files in INCLUDES and setting the cache variable VAR -# accordingly. -ac_fn_c_check_header_mongrel () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval \${$3+:} false; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 -$as_echo_n "checking $2 usability... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_header_compiler=yes -else - ac_header_compiler=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } - -# Is the header present? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 -$as_echo_n "checking $2 presence... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <$2> -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - ac_header_preproc=yes -else - ac_header_preproc=no -fi -rm -f conftest.err conftest.i conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( - yes:no: ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} - ;; - no:yes:* ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} -( $as_echo "## ----------------------------------- ## -## Report this to support@underbit.com ## -## ----------------------------------- ##" - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=\$ac_header_compiler" -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_mongrel - -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_type - -# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES -# -------------------------------------------- -# Tries to find the compile-time value of EXPR in a program that includes -# INCLUDES, setting VAR accordingly. Returns whether the value could be -# computed -ac_fn_c_compute_int () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) >= 0)]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_lo=0 ac_mid=0 - while :; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_hi=$ac_mid; break -else - as_fn_arith $ac_mid + 1 && ac_lo=$as_val - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) < 0)]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_hi=-1 ac_mid=-1 - while :; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) >= $ac_mid)]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_lo=$ac_mid; break -else - as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_hi=$ac_mid -else - as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in #(( -?*) eval "$3=\$ac_lo"; ac_retval=0 ;; -'') ac_retval=1 ;; -esac - else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -static long int longval () { return $2; } -static unsigned long int ulongval () { return $2; } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (($2) < 0) - { - long int i = longval (); - if (i != ($2)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ($2)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - echo >>conftest.val; read $3 config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by MPEG Audio Decoder $as_me 0.15.1b, which was -generated by GNU Autoconf 2.69. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - $as_echo "## ---------------- ## -## Cache variables. ## -## ---------------- ##" - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - $as_echo "## ----------------- ## -## Output variables. ## -## ----------------- ##" - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - $as_echo "## ------------------- ## -## File substitutions. ## -## ------------------- ##" - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - $as_echo "## ----------- ## -## confdefs.h. ## -## ----------- ##" - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -$as_echo "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE -if test -n "$CONFIG_SITE"; then - # We do not want a PATH search for config.site. - case $CONFIG_SITE in #(( - -*) ac_site_file1=./$CONFIG_SITE;; - */*) ac_site_file1=$CONFIG_SITE;; - *) ac_site_file1=./$CONFIG_SITE;; - esac -elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site -else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site -fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" -do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" \ - || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5; } - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - - - - -am__api_version='1.14' - -ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if ${ac_cv_path_install+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -$as_echo_n "checking whether build environment is sane... " >&6; } -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; -esac -case $srcdir in - *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; -esac - -# Do 'set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error $? "ls -t appears to fail. Make sure there is not a broken - alias in your environment" "$LINENO" 5 - fi - if test "$2" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error $? "newly created file is older than distributed files! -Check your system clock" "$LINENO" 5 -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -# If we didn't sleep, we still need to ensure time stamps of config.status and -# generated files are strictly newer. -am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & - am_sleep_pid=$! -fi - -rm -f conftest.file - -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. -# By default was `s,x,x', remove it if useless. -ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` - -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` - -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --is-lightweight"; then - am_missing_run="$MISSING " -else - am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} -fi - -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi - -# Installed binaries are usually stripped using 'strip' when the user -# run "make install-strip". However 'strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the 'STRIP' environment variable to overrule this program. -if test "$cross_compiling" != no; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 -$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } -if test -z "$MKDIR_P"; then - if ${ac_cv_path_mkdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in mkdir gmkdir; do - for ac_exec_ext in '' $ac_executable_extensions; do - as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue - case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir (GNU coreutils) '* | \ - 'mkdir (coreutils) '* | \ - 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext - break 3;; - esac - done - done - done -IFS=$as_save_IFS - -fi - - test -d ./--version && rmdir ./--version - if test "${ac_cv_path_mkdir+set}" = set; then - MKDIR_P="$ac_cv_path_mkdir -p" - else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AWK+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AWK" && break -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - SET_MAKE= -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null - -# Check whether --enable-silent-rules was given. -if test "${enable_silent_rules+set}" = set; then : - enableval=$enable_silent_rules; -fi - -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=1;; -esac -am_make=${MAKE-make} -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -$as_echo_n "checking whether $am_make supports nested variables... " >&6; } -if ${am_cv_make_support_nested_variables+:} false; then : - $as_echo_n "(cached) " >&6 -else - if $as_echo 'TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -$as_echo "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AM_BACKSLASH='\' - -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - am__isrc=' -I$(srcdir)' - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi - - -# Define the identity of the package. - PACKAGE='libmad' - VERSION='0.15.1b' - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE "$PACKAGE" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VERSION "$VERSION" -_ACEOF - -# Some tools Automake needs. - -ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} - - -AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} - - -AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} - - -AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} - - -MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} - -# For better backward compatibility. To be removed once Automake 1.9.x -# dies out for good. For more background, see: -# -# -mkdir_p='$(MKDIR_P)' - -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. Yes, it's still used -# in the wild :-( We should find a proper way to deprecate it ... -AMTAR='$${TAR-tar}' - - -# We'll loop over all known methods to create a tar archive until one works. -_am_tools='gnutar pax cpio none' - -am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' - - - - - - -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! - -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: - -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. - -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. - -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . - -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. - -END - as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 - fi -fi - -ac_config_headers="$ac_config_headers config.h" - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 -$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } - # Check whether --enable-maintainer-mode was given. -if test "${enable_maintainer_mode+set}" = set; then : - enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval -else - USE_MAINTAINER_MODE=no -fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 -$as_echo "$USE_MAINTAINER_MODE" >&6; } - if test $USE_MAINTAINER_MODE = yes; then - MAINTAINER_MODE_TRUE= - MAINTAINER_MODE_FALSE='#' -else - MAINTAINER_MODE_TRUE='#' - MAINTAINER_MODE_FALSE= -fi - - MAINT=$MAINTAINER_MODE_TRUE - - - - -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -$as_echo_n "checking build system type... " >&6; } -if ${ac_cv_build+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 -$as_echo_n "checking host system type... " >&6; } -if ${ac_cv_host+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -$as_echo "$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if ${ac_cv_objext+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if ${ac_cv_c_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 -$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } -if ${am_cv_prog_cc_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF - # Make sure it works both with $CC and with simple cc. - # Following AC_PROG_CC_C_O, we do the test twice because some - # compilers refuse to overwrite an existing .o file with -o, - # though they will create one. - am_cv_prog_cc_c_o=yes - for am_i in 1 2; do - if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 - ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } \ - && test -f conftest2.$ac_objext; then - : OK - else - am_cv_prog_cc_c_o=no - break - fi - done - rm -f core conftest* - unset am_i -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 -$as_echo "$am_cv_prog_cc_c_o" >&6; } -if test "$am_cv_prog_cc_c_o" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from 'make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf - -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' - am__nodep='_no' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - - -depcc="$CC" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CC_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - -# By default we simply use the C compiler to build assembly code. - -test "${CCAS+set}" = set || CCAS=$CC -test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS - - - -depcc="$CCAS" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CCAS_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CCAS_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CCAS_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CCAS_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CCAS_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CCAS_dependencies_compiler_type" >&6; } -CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then - am__fastdepCCAS_TRUE= - am__fastdepCCAS_FALSE='#' -else - am__fastdepCCAS_TRUE='#' - am__fastdepCCAS_FALSE= -fi - - - -if test "$GCC" = yes -then - case "$host" in - *-*-mingw*) - case "$build" in - *-*-cygwin*) - CPPFLAGS="$CPPFLAGS -mno-cygwin" - LDFLAGS="$LDFLAGS -mno-cygwin" - ;; - esac - esac - -fi - - -case `pwd` in - *\ * | *\ *) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; -esac - - - -macro_version='2.4.2' -macro_revision='1.3337' - - - - - - - - - - - - - -ltmain="$ac_aux_dir/ltmain.sh" - -# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\(["`$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 -$as_echo_n "checking how to print strings... " >&6; } -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "" -} - -case "$ECHO" in - printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 -$as_echo "printf" >&6; } ;; - print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 -$as_echo "print -r" >&6; } ;; - *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 -$as_echo "cat" >&6; } ;; -esac - - - - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if ${ac_cv_path_SED+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for ac_i in 1 2 3 4 5 6 7; do - ac_script="$ac_script$as_nl$ac_script" - done - echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed - { ac_script=; unset ac_script;} - if test -z "$SED"; then - ac_path_SED_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_SED" || continue -# Check for GNU ac_path_SED and select it if it is found. - # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in -*GNU*) - ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo '' >> "conftest.nl" - "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_SED="$ac_path_SED" - ac_path_SED_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_SED_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_SED"; then - as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 - fi -else - ac_cv_path_SED=$SED -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -$as_echo "$ac_cv_path_SED" >&6; } - SED="$ac_cv_path_SED" - rm -f conftest.sed - -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if ${ac_cv_path_GREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$GREP"; then - ac_path_GREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_GREP" || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_GREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_GREP=$GREP -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if ${ac_cv_path_EGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_EGREP=$EGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 -$as_echo_n "checking for fgrep... " >&6; } -if ${ac_cv_path_FGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in fgrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_FGREP" || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in -*GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_FGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_FGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_FGREP=$FGREP -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 -$as_echo "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - - - - - -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if ${lt_cv_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$LD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if ${lt_cv_prog_gnu_ld+:} false; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 -$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if ${lt_cv_path_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - if test -n "$ac_tool_prefix"; then - for ac_prog in dumpbin "link -dump" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DUMPBIN=$ac_cv_prog_DUMPBIN -if test -n "$DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 -$as_echo "$DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$DUMPBIN" && break - done -fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in dumpbin "link -dump" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DUMPBIN"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN -if test -n "$ac_ct_DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 -$as_echo "$ac_ct_DUMPBIN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_DUMPBIN" && break -done - - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DUMPBIN=$ac_ct_DUMPBIN - fi -fi - - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols" - ;; - *) - DUMPBIN=: - ;; - esac - fi - - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 -$as_echo_n "checking the name lister ($NM) interface... " >&6; } -if ${lt_cv_nm_interface+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 -$as_echo "$lt_cv_nm_interface" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } -fi - -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if ${lt_cv_sys_max_cmd_len+:} false; then : - $as_echo_n "(cached) " >&6 -else - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac - -fi - -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } -fi -max_cmd_len=$lt_cv_sys_max_cmd_len - - - - - - -: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 -$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 -$as_echo "$xsi_shell" >&6; } - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 -$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } -lt_shell_append=no -( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 -$as_echo "$lt_shell_append" >&6; } - - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi - - - - - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 -$as_echo_n "checking how to convert $build file names to $host format... " >&6; } -if ${lt_cv_to_host_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac - -fi - -to_host_file_cmd=$lt_cv_to_host_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 -$as_echo "$lt_cv_to_host_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 -$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } -if ${lt_cv_to_tool_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - #assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac - -fi - -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 -$as_echo "$lt_cv_to_tool_file_cmd" >&6; } - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if ${lt_cv_ld_reload_flag+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_reload_flag='-r' -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - if test "$GCC" != yes; then - reload_cmds=false - fi - ;; - darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 -$as_echo_n "checking how to recognize dependent libraries... " >&6; } -if ${lt_cv_deplibs_check_method+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[4-9]*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. - if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - 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]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[3-9]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - 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]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - - - - - - - - - - - - - - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" -fi - -test -z "$DLLTOOL" && DLLTOOL=dlltool - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 -$as_echo_n "checking how to associate runtime and link libraries... " >&6; } -if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 -$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - - - - - - - - -if test -n "$ac_tool_prefix"; then - for ac_prog in ar - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AR" && break - done -fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AR="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_AR" && break -done - - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -fi - -: ${AR=ar} -: ${AR_FLAGS=cru} - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 -$as_echo_n "checking for archiver @FILE support... " >&6; } -if ${lt_cv_ar_at_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ar_at_file=no - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -eq 0; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -ne 0; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 -$as_echo "$lt_cv_ar_at_file" >&6; } - -if test "x$lt_cv_ar_at_file" = xno; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -test -z "$STRIP" && STRIP=: - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - -test -z "$RANLIB" && RANLIB=: - - - - - - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if ${lt_cv_sys_global_symbol_pipe+:} false; then : - $as_echo_n "(cached) " >&6 -else - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[ABCDGISTW]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris*) - symcode='[BDRT]' - ;; -sco3.2v5*) - symcode='[DT]' - ;; -sysv4.2uw2*) - symcode='[DT]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[ABDT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" -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'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK '"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done - -fi - -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 -$as_echo_n "checking for sysroot... " >&6; } - -# Check whether --with-sysroot was given. -if test "${with_sysroot+set}" = set; then : - withval=$with_sysroot; -else - with_sysroot=no -fi - - -lt_sysroot= -case ${with_sysroot} in #( - yes) - if test "$GCC" = yes; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 -$as_echo "${with_sysroot}" >&6; } - as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 - ;; -esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 -$as_echo "${lt_sysroot:-no}" >&6; } - - - - - -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi - -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line '$LINENO' "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if ${lt_cv_cc_needs_belf+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. -set dummy ${ac_tool_prefix}mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$MANIFEST_TOOL"; then - ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL -if test -n "$MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 -$as_echo "$MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_MANIFEST_TOOL"; then - ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL - # Extract the first word of "mt", so it can be a program name with args. -set dummy mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_MANIFEST_TOOL"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL -if test -n "$ac_ct_MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 -$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_MANIFEST_TOOL" = x; then - MANIFEST_TOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL - fi -else - MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" -fi - -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 -$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } -if ${lt_cv_path_mainfest_tool+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&5 - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 -$as_echo "$lt_cv_path_mainfest_tool" >&6; } -if test "x$lt_cv_path_mainfest_tool" != xyes; then - MANIFEST_TOOL=: -fi - - - - - - - case $host_os in - rhapsody* | darwin*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. -set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DSYMUTIL=$ac_cv_prog_DSYMUTIL -if test -n "$DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 -$as_echo "$DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DSYMUTIL"; then - ac_ct_DSYMUTIL=$DSYMUTIL - # Extract the first word of "dsymutil", so it can be a program name with args. -set dummy dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL -if test -n "$ac_ct_DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 -$as_echo "$ac_ct_DSYMUTIL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DSYMUTIL=$ac_ct_DSYMUTIL - fi -else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. -set dummy ${ac_tool_prefix}nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -NMEDIT=$ac_cv_prog_NMEDIT -if test -n "$NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 -$as_echo "$NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NMEDIT"; then - ac_ct_NMEDIT=$NMEDIT - # Extract the first word of "nmedit", so it can be a program name with args. -set dummy nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_NMEDIT"; then - ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_NMEDIT="nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT -if test -n "$ac_ct_NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 -$as_echo "$ac_ct_NMEDIT" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_NMEDIT" = x; then - NMEDIT=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - NMEDIT=$ac_ct_NMEDIT - fi -else - NMEDIT="$ac_cv_prog_NMEDIT" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. -set dummy ${ac_tool_prefix}lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$LIPO"; then - ac_cv_prog_LIPO="$LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_LIPO="${ac_tool_prefix}lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LIPO=$ac_cv_prog_LIPO -if test -n "$LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 -$as_echo "$LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_LIPO"; then - ac_ct_LIPO=$LIPO - # Extract the first word of "lipo", so it can be a program name with args. -set dummy lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_LIPO"; then - ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_LIPO="lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO -if test -n "$ac_ct_LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 -$as_echo "$ac_ct_LIPO" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_LIPO" = x; then - LIPO=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - LIPO=$ac_ct_LIPO - fi -else - LIPO="$ac_cv_prog_LIPO" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL"; then - ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL="${ac_tool_prefix}otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL=$ac_cv_prog_OTOOL -if test -n "$OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 -$as_echo "$OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL"; then - ac_ct_OTOOL=$OTOOL - # Extract the first word of "otool", so it can be a program name with args. -set dummy otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL"; then - ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL="otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL -if test -n "$ac_ct_OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 -$as_echo "$ac_ct_OTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL" = x; then - OTOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL=$ac_ct_OTOOL - fi -else - OTOOL="$ac_cv_prog_OTOOL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL64"; then - ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL64=$ac_cv_prog_OTOOL64 -if test -n "$OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 -$as_echo "$OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL64"; then - ac_ct_OTOOL64=$OTOOL64 - # Extract the first word of "otool64", so it can be a program name with args. -set dummy otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL64"; then - ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL64="otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 -if test -n "$ac_ct_OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 -$as_echo "$ac_ct_OTOOL64" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL64" = x; then - OTOOL64=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL64=$ac_ct_OTOOL64 - fi -else - OTOOL64="$ac_cv_prog_OTOOL64" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 -$as_echo_n "checking for -single_module linker flag... " >&6; } -if ${lt_cv_apple_cc_single_mod+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&5 - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&5 - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 -$as_echo "$lt_cv_apple_cc_single_mod" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 -$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } -if ${lt_cv_ld_exported_symbols_list+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_ld_exported_symbols_list=yes -else - lt_cv_ld_exported_symbols_list=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 -$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 -$as_echo_n "checking for -force_load linker flag... " >&6; } -if ${lt_cv_ld_force_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 - echo "$AR cru libconftest.a conftest.o" >&5 - $AR cru libconftest.a conftest.o 2>&5 - echo "$RANLIB libconftest.a" >&5 - $RANLIB libconftest.a 2>&5 - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&5 - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&5 - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 -$as_echo "$lt_cv_ld_force_load" >&6; } - case $host_os in - rhapsody* | darwin1.[012]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[91]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[012]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if ${ac_cv_prog_CPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default -" -if test "x$ac_cv_header_dlfcn_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF - -fi - -done - - - - - -# Set options - - - - enable_dlopen=no - - - enable_win32_dll=no - - - # Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_shared=yes -fi - - - - - - - - - - # Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_static=yes -fi - - - - - - - - - - -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for lt_pkg in $withval; do - IFS="$lt_save_ifs" - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - pic_mode=default -fi - - -test -z "$pic_mode" && pic_mode=default - - - - - - - - # Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_fast_install=yes -fi - - - - - - - - - - - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -test -z "$LN_S" && LN_S="ln -s" - - - - - - - - - - - - - - -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if ${lt_cv_objdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - - - - -cat >>confdefs.h <<_ACEOF -#define LT_OBJDIR "$lt_cv_objdir/" -_ACEOF - - - - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` - - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - - - -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi - -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - else - MAGIC_CMD=: - fi -fi - - fi - ;; -esac - -# Use C for the default configuration in the libtool script - -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -objext=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - -if test -n "$compiler"; then - -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - case $cc_basename in - nvcc*) - lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; - *) - lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; - esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi - -fi - - - - - - - lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= - - - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; - - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; - - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - lt_prog_compiler_wl='-Xlinker ' - if test -n "$lt_prog_compiler_pic"; then - lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='--shared' - lt_prog_compiler_static='--static' - ;; - nagfor*) - # NAG Fortran compiler - lt_prog_compiler_wl='-Wl,-Wl,,' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-qpic' - lt_prog_compiler_static='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' - ;; - *Sun\ F* | *Sun*Fortran*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Wl,' - ;; - *Intel*\ [CF]*Compiler*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - *Portland\ Group*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - - rdos*) - lt_prog_compiler_static='-non_shared' - ;; - - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; - - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; - - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; - - *) - lt_prog_compiler_can_build_shared=no - ;; - esac - fi - -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -if ${lt_cv_prog_compiler_pic+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic=$lt_prog_compiler_pic -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 -$as_echo "$lt_cv_prog_compiler_pic" >&6; } -lt_prog_compiler_pic=$lt_cv_prog_compiler_pic - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if ${lt_cv_prog_compiler_pic_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } - -if test x"$lt_cv_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac -else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no -fi - -fi - - - - - - - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if ${lt_cv_prog_compiler_static_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works=yes - fi - else - lt_cv_prog_compiler_static_works=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 -$as_echo "$lt_cv_prog_compiler_static_works" >&6; } - -if test x"$lt_cv_prog_compiler_static_works" = xyes; then - : -else - lt_prog_compiler_static= -fi - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag= - always_export_symbols=no - archive_cmds= - archive_expsym_cmds= - compiler_needs_object=no - enable_shared_with_static_runtimes=no - export_dynamic_flag_spec= - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - hardcode_automatic=no - hardcode_direct=no - hardcode_direct_absolute=no - hardcode_libdir_flag_spec= - hardcode_libdir_separator= - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - inherit_rpath=no - link_all_deplibs=unknown - module_cmds= - module_expsym_cmds= - old_archive_from_new_cmds= - old_archive_from_expsyms_cmds= - thread_safe_flag_spec= - whole_archive_flag_spec= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - linux* | k*bsd*-gnu | gnu*) - link_all_deplibs=no - ;; - esac - - ld_shlibs=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; - *\ \(GNU\ Binutils\)\ [3-9]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test "$lt_use_gnu_ld_interface" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[3-9]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - export_dynamic_flag_spec='${wl}--export-all-symbols' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - 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' - exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs=no - fi - ;; - - haiku*) - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - link_all_deplibs=yes - ;; - - interix[3-9]*) - hardcode_direct=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - 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' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - 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' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - 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' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - whole_archive_flag_spec= - tmp_sharedflag='--shared' ;; - xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - 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' - compiler_needs_object=yes - ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - 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' - compiler_needs_object=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - ld_shlibs=no - fi - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - 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' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - - aix[4-9]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - 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' - else - 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' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds='' - hardcode_direct=yes - hardcode_direct_absolute=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - file_list_spec='${wl}-f,' - - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - link_all_deplibs=no - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - export_dynamic_flag_spec='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - 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" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - 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" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test "${lt_cv_aix_libpath+set}" = set; then - aix_libpath=$lt_cv_aix_libpath -else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_="/usr/lib:/lib" - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec='$convenience' - fi - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - 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' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - 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)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl*) - # Native MSVC - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - always_export_symbols=yes - file_list_spec='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, )='true' - enable_shared_with_static_runtimes=yes - exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' - # Don't use ranlib - old_postinstall_cmds='chmod 644 $oldlib' - postlink_cmds='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC wrapper - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' - enable_shared_with_static_runtimes=yes - ;; - esac - ;; - - darwin* | rhapsody*) - - - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - 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\"`' - - else - whole_archive_flag_spec='' - fi - link_all_deplibs=yes - allow_undefined_flag="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=func_echo_all - archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - 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}" - 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}" - - else - ld_shlibs=no - fi - - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9*) - if test "$GCC" = yes; then - 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' - else - 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' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 -$as_echo_n "checking if $CC understands -b... " >&6; } -if ${lt_cv_prog_compiler__b+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler__b=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -b" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler__b=yes - fi - else - lt_cv_prog_compiler__b=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 -$as_echo "$lt_cv_prog_compiler__b" >&6; } - -if test x"$lt_cv_prog_compiler__b" = xyes; then - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' -else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' -fi - - ;; - esac - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - *) - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - 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' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 -$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } -if ${lt_cv_irix_exported_symbol+:} false; then : - $as_echo_n "(cached) " >&6 -else - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int foo (void) { return 0; } -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_irix_exported_symbol=yes -else - lt_cv_irix_exported_symbol=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 -$as_echo "$lt_cv_irix_exported_symbol" >&6; } - if test "$lt_cv_irix_exported_symbol" = yes; then - 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' - fi - else - 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' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - inherit_rpath=yes - link_all_deplibs=yes - ;; - - netbsd* | netbsdelf*-gnu) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - - *nto* | *qnx*) - ;; - - openbsd*) - if test -f /usr/libexec/ld.so; then - hardcode_direct=yes - hardcode_shlibpath_var=no - hardcode_direct_absolute=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - else - ld_shlibs=no - fi - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - 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' - old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - 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' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - 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' - 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~ - $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' - - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - archive_cmds_need_lc='no' - hardcode_libdir_separator=: - ;; - - solaris*) - no_undefined_flag=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $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' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' - fi - ;; - esac - link_all_deplibs=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag='${wl}-z,text' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag='${wl}-z,text' - allow_undefined_flag='${wl}-z,nodefs' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-R,$libdir' - hardcode_libdir_separator=':' - link_all_deplibs=yes - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - *) - ld_shlibs=no - ;; - esac - - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - export_dynamic_flag_spec='${wl}-Blargedynsym' - ;; - esac - fi - fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no - -with_gnu_ld=$with_gnu_ld - - - - - - - - - - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } -if ${lt_cv_archive_cmds_need_lc+:} false; then : - $as_echo_n "(cached) " >&6 -else - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - pic_flag=$lt_prog_compiler_pic - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc=no - else - lt_cv_archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 -$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } - archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } - -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[lt_foo]++; } - if (lt_freq[lt_foo] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([A-Za-z]:\),\1,g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - 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' - ;; - esac - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl*) - # Native MSVC - libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec="$LIB" - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if ${lt_cv_shlibpath_overrides_runpath+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - 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' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsdelf*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='NetBSD ld.elf_so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || - test -n "$runpath_var" || - test "X$hardcode_automatic" = "Xyes" ; then - - # We can hardcode non-existent directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } - -if test "$hardcode_action" = relink || - test "$inherit_rpath" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - -fi - - ;; - - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if ${ac_cv_lib_dld_shl_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes -else - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = xyes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if ${ac_cv_lib_svld_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes -else - ac_cv_lib_svld_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = xyes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if ${ac_cv_lib_dld_dld_link+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); -int -main () -{ -return dld_link (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes -else - ac_cv_lib_dld_dld_link=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = xyes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" -fi - - -fi - - -fi - - -fi - - -fi - - -fi - - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self_static+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisbility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi - - - - - - - - - - - - - - - - - -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac -fi - - - - - - - - - - - - - # Report which library types will actually be built - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[4-9]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } - - - - -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" - - - - - - - - - - - - - - - - ac_config_commands="$ac_config_commands libtool" - - - - -# Only expand once: - - - - - - -arch="" -debug="" -optimize="" -profile="" - -set -- $CFLAGS -CFLAGS="" - -if test "$GCC" = yes -then - CFLAGS="-Wall" -fi - -while test $# -gt 0 -do - case "$1" in - -Wall) - if test "$GCC" = yes - then - : - else - CFLAGS="$CFLAGS $1" - fi - shift - ;; - -g) - debug="-g" - shift - ;; - -mno-cygwin) - shift - ;; - -m*) - arch="$arch $1" - shift - ;; - -O2) - optimize="-O" - shift - ;; - -fomit-frame-pointer) - shift - ;; - -O*|-f*) - optimize="$optimize $1" - shift - ;; - *) - CFLAGS="$CFLAGS $1" - shift - ;; - esac -done - -if test "$GCC" = yes -then - if test -z "$arch" - then - case "$host" in - i386-*) ;; - i?86-*) arch="-march=i486" ;; - arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;; - armv4*-*) arch="-march=armv4 -mtune=strongarm" ;; - powerpc-*) ;; - mips*-agenda-*) arch="-mcpu=vr4100" ;; - mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;; - esac - fi - - case "$optimize" in - -O|"-O "*) - optimize="-O" - : #x optimize="$optimize -fforce-mem" - : #x optimize="$optimize -fforce-addr" - : #x optimize="$optimize -finline-functions" - : #- optimize="$optimize -fstrength-reduce" - optimize="$optimize -fthread-jumps" - optimize="$optimize -fcse-follow-jumps" - optimize="$optimize -fcse-skip-blocks" - : #x optimize="$optimize -frerun-cse-after-loop" - : #x optimize="$optimize -frerun-loop-opt" - : #x optimize="$optimize -fgcse" - optimize="$optimize -fexpensive-optimizations" - optimize="$optimize -fregmove" - : #* optimize="$optimize -fdelayed-branch" - : #x optimize="$optimize -fschedule-insns" - optimize="$optimize -fschedule-insns2" - : #? optimize="$optimize -ffunction-sections" - : #? optimize="$optimize -fcaller-saves" - : #> optimize="$optimize -funroll-loops" - : #> optimize="$optimize -funroll-all-loops" - : #x optimize="$optimize -fmove-all-movables" - : #x optimize="$optimize -freduce-all-givs" - : #? optimize="$optimize -fstrict-aliasing" - : #* optimize="$optimize -fstructure-noalias" - - case "$host" in - arm*-*) - optimize="$optimize -fstrength-reduce" - ;; - mips*-*) - optimize="$optimize -fstrength-reduce" - optimize="$optimize -finline-functions" - ;; - i?86-*) - optimize="$optimize -fstrength-reduce" - ;; - powerpc-apple-*) - # this triggers an internal compiler error with gcc2 - : #optimize="$optimize -fstrength-reduce" - - # this is really only beneficial with gcc3 - : #optimize="$optimize -finline-functions" - ;; - *) - # this sometimes provokes bugs in gcc 2.95.2 - : #optimize="$optimize -fstrength-reduce" - ;; - esac - ;; - esac -fi - -case "$host" in - mips*-agenda-*) - -$as_echo "#define HAVE_MADD16_ASM 1" >>confdefs.h - - ;; - mips*-luxsonor-*) - -$as_echo "#define HAVE_MADD_ASM 1" >>confdefs.h - - ;; -esac - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5 -$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; } -if ${ac_cv_header_sys_wait_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#ifndef WEXITSTATUS -# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) -#endif -#ifndef WIFEXITED -# define WIFEXITED(stat_val) (((stat_val) & 255) == 0) -#endif - -int -main () -{ - int s; - wait (&s); - s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_sys_wait_h=yes -else - ac_cv_header_sys_wait_h=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5 -$as_echo "$ac_cv_header_sys_wait_h" >&6; } -if test $ac_cv_header_sys_wait_h = yes; then - -$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h - -fi - -for ac_header in assert.h limits.h unistd.h sys/types.h fcntl.h errno.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if ${ac_cv_c_const+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - -#ifndef __cplusplus - /* Ultrix mips cc rejects this sort of thing. */ - typedef int charset[2]; - const charset cs = { 0, 0 }; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this sort of thing. */ - char tx; - char *t = &tx; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; } bx; - struct s *b = &bx; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes -else - ac_cv_c_const=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -$as_echo "#define const /**/" >>confdefs.h - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if ${ac_cv_c_inline+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif - -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_inline=$ac_kw -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } - -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF - ;; -esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 -$as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if ${ac_cv_c_bigendian+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_bigendian=unknown - # See if we're dealing with a universal compiler. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifndef __APPLE_CC__ - not a universal capable compiler - #endif - typedef int dummy; - -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - - # Check for potential -arch flags. It is not universal unless - # there are at least two -arch flags with different values. - ac_arch= - ac_prev= - for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do - if test -n "$ac_prev"; then - case $ac_word in - i?86 | x86_64 | ppc | ppc64) - if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then - ac_arch=$ac_word - else - ac_cv_c_bigendian=universal - break - fi - ;; - esac - ac_prev= - elif test "x$ac_word" = "x-arch"; then - ac_prev=arch - fi - done -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - if test $ac_cv_c_bigendian = unknown; then - # See if sys/param.h defines the BYTE_ORDER macro. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - #include - -int -main () -{ -#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ - && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ - && LITTLE_ENDIAN) - bogus endian macros - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - # It does; now see whether it defined to BIG_ENDIAN or not. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - #include - -int -main () -{ -#if BYTE_ORDER != BIG_ENDIAN - not big endian - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_bigendian=yes -else - ac_cv_c_bigendian=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $ac_cv_c_bigendian = unknown; then - # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -int -main () -{ -#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) - bogus endian macros - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - # It does; now see whether it defined to _BIG_ENDIAN or not. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -int -main () -{ -#ifndef _BIG_ENDIAN - not big endian - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_bigendian=yes -else - ac_cv_c_bigendian=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $ac_cv_c_bigendian = unknown; then - # Compile a test program. - if test "$cross_compiling" = yes; then : - # Try to guess by grepping values from an object file. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -short int ascii_mm[] = - { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; - short int ascii_ii[] = - { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; - int use_ascii (int i) { - return ascii_mm[i] + ascii_ii[i]; - } - short int ebcdic_ii[] = - { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; - short int ebcdic_mm[] = - { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; - int use_ebcdic (int i) { - return ebcdic_mm[i] + ebcdic_ii[i]; - } - extern int foo; - -int -main () -{ -return use_ascii (foo) == use_ebcdic (foo); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then - ac_cv_c_bigendian=yes - fi - if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then - if test "$ac_cv_c_bigendian" = unknown; then - ac_cv_c_bigendian=no - else - # finding both strings is unlikely to happen, but who knows? - ac_cv_c_bigendian=unknown - fi - fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ - - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long int l; - char c[sizeof (long int)]; - } u; - u.l = 1; - return u.c[sizeof (long int) - 1] == 1; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - ac_cv_c_bigendian=no -else - ac_cv_c_bigendian=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 -$as_echo "$ac_cv_c_bigendian" >&6; } - case $ac_cv_c_bigendian in #( - yes) - $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h -;; #( - no) - ;; #( - universal) - -$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h - - ;; #( - *) - as_fn_error $? "unknown endianness - presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; - esac - -ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" -if test "x$ac_cv_type_pid_t" = xyes; then : - -else - -cat >>confdefs.h <<_ACEOF -#define pid_t int -_ACEOF - -fi - - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if ${ac_cv_sizeof_int+:} false; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "cannot compute sizeof (int) -See \`config.log' for more details" "$LINENO" 5; } - else - ac_cv_sizeof_int=0 - fi -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF - - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if ${ac_cv_sizeof_long+:} false; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "cannot compute sizeof (long) -See \`config.log' for more details" "$LINENO" 5; } - else - ac_cv_sizeof_long=0 - fi -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF - - -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 -$as_echo_n "checking size of long long... " >&6; } -if ${ac_cv_sizeof_long_long+:} false; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_long_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "cannot compute sizeof (long long) -See \`config.log' for more details" "$LINENO" 5; } - else - ac_cv_sizeof_long_long=0 - fi -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 -$as_echo "$ac_cv_sizeof_long_long" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long -_ACEOF - - - - -for ac_func in waitpid fcntl pipe fork -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - - - - - - - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to optimize for speed or for accuracy" >&5 -$as_echo_n "checking whether to optimize for speed or for accuracy... " >&6; } - -# Check whether --enable-speed was given. -if test "${enable_speed+set}" = set; then : - enableval=$enable_speed; - case "$enableval" in - yes) - optimize_for="speed" - -$as_echo "#define OPT_SPEED 1" >>confdefs.h - - ;; - esac - -fi - - -# Check whether --enable-accuracy was given. -if test "${enable_accuracy+set}" = set; then : - enableval=$enable_accuracy; - case "$enableval" in - yes) - if test "$optimize_for" = "speed" - then - optimize_for="both" - else - optimize_for="accuracy" - fi - -$as_echo "#define OPT_ACCURACY 1" >>confdefs.h - - ;; - esac - -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${optimize_for-default}" >&5 -$as_echo "${optimize_for-default}" >&6; } - -if test "$optimize_for" = "both" -then - as_fn_error $? "cannot optimize for both speed and accuracy" "$LINENO" 5 -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for architecture-specific fixed-point math routines" >&5 -$as_echo_n "checking for architecture-specific fixed-point math routines... " >&6; } -# Check whether --enable-fpm was given. -if test "${enable_fpm+set}" = set; then : - enableval=$enable_fpm; - case "$enableval" in - yes) ;; - no|default|approx) FPM="DEFAULT" ;; - intel|i?86) FPM="INTEL" ;; - arm) FPM="ARM" ;; - mips) FPM="MIPS" ;; - sparc) FPM="SPARC" ;; - ppc|powerpc) FPM="PPC" ;; - 64bit) FPM="64BIT" ;; - float) FPM="FLOAT" ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } - as_fn_error $? "bad --enable-fpm option" "$LINENO" 5 - ;; - esac - -fi - - -if test -z "$FPM" && test "$GCC" = yes -then - case "$host" in - i?86-*) FPM="INTEL" ;; - arm*-*) FPM="ARM" ;; - mips*-*) FPM="MIPS" ;; - sparc*-*) FPM="SPARC" ;; - powerpc*-*) FPM="PPC" ;; - # FIXME: need to test for 64-bit long long... - esac -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${FPM=DEFAULT}" >&5 -$as_echo "${FPM=DEFAULT}" >&6; } - -if test "$FPM" = "DEFAULT" -then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: default fixed-point math will yield limited accuracy" >&5 -$as_echo "$as_me: WARNING: default fixed-point math will yield limited accuracy" >&2;} -fi - -FPM="-DFPM_$FPM" - -# Check whether --enable-sso was given. -if test "${enable_sso+set}" = set; then : - enableval=$enable_sso; - case "$enableval" in - yes) - -$as_echo "#define OPT_SSO 1" >>confdefs.h - - ;; - esac - -fi - - -# Check whether --enable-aso was given. -if test "${enable_aso+set}" = set; then : - enableval=$enable_aso; -else - enable_aso=yes -fi - - -if test "$enable_aso" = yes -then - case "$host" in - i?86-*) - : #ASO="$ASO -DASO_INTERLEAVE1" - ASO="$ASO -DASO_ZEROCHECK" - : #not yet #ASO="$ASO -DASO_SYNTH" - : #not yet #ASO_OBJS="synth_mmx.lo" - ;; - arm*-*) - ASO="$ASO -DASO_INTERLEAVE1" - ASO="$ASO -DASO_IMDCT" - ASO_OBJS="imdct_l_arm.lo" - ;; - mips*-*) - ASO="$ASO -DASO_INTERLEAVE2" - ASO="$ASO -DASO_ZEROCHECK" - ;; - esac -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ISO/IEC interpretation" >&5 -$as_echo_n "checking for ISO/IEC interpretation... " >&6; } -# Check whether --enable-strict-iso was given. -if test "${enable_strict_iso+set}" = set; then : - enableval=$enable_strict_iso; - case "$enableval" in - yes) - -$as_echo "#define OPT_STRICT 1" >>confdefs.h - - interpretation="strict" - ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${interpretation-best accepted practices}" >&5 -$as_echo "${interpretation-best accepted practices}" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable profiling" >&5 -$as_echo_n "checking whether to enable profiling... " >&6; } -# Check whether --enable-profiling was given. -if test "${enable_profiling+set}" = set; then : - enableval=$enable_profiling; - case "$enableval" in - yes) profile="-pg" ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_profiling-no}" >&5 -$as_echo "${enable_profiling-no}" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable debugging" >&5 -$as_echo_n "checking whether to enable debugging... " >&6; } -# Check whether --enable-debugging was given. -if test "${enable_debugging+set}" = set; then : - enableval=$enable_debugging; - case "$enableval" in - yes) - -$as_echo "#define DEBUG 1" >>confdefs.h - - optimize="" - ;; - no) - if test -n "$profile" - then - as_fn_error $? "--enable-profiling and --disable-debugging are incompatible" "$LINENO" 5 - fi - - -$as_echo "#define NDEBUG 1" >>confdefs.h - - debug="" - if test "$GCC" = yes - then - optimize="$optimize -fomit-frame-pointer" - fi - ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_debugging-default}" >&5 -$as_echo "${enable_debugging-default}" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable experimental code" >&5 -$as_echo_n "checking whether to enable experimental code... " >&6; } -# Check whether --enable-experimental was given. -if test "${enable_experimental+set}" = set; then : - enableval=$enable_experimental; - case "$enableval" in - yes) - -$as_echo "#define EXPERIMENTAL 1" >>confdefs.h - - ;; - esac - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_experimental-no}" >&5 -$as_echo "${enable_experimental-no}" >&6; } - - -test -n "$arch" && CFLAGS="$CFLAGS $arch" -test -n "$debug" && CFLAGS="$CFLAGS $debug" -test -n "$optimize" && CFLAGS="$CFLAGS $optimize" -test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile" - - -ac_config_files="$ac_config_files Makefile msvc++/Makefile libmad.list" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -DEFS=-DHAVE_CONFIG_H - -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 -$as_echo_n "checking that generated files are newer than configure... " >&6; } - if test -n "$am_sleep_pid"; then - # Hide warnings about reused PIDs. - wait $am_sleep_pid 2>/dev/null - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 -$as_echo "done" >&6; } - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi - -if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then - as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error $? "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCCAS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi - - -: "${CONFIG_STATUS=./config.status}" -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - $as_echo "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by MPEG Audio Decoder $as_me 0.15.1b, which was -generated by GNU Autoconf 2.69. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE - -Configuration files: -$config_files - -Configuration headers: -$config_headers - -Configuration commands: -$config_commands - -Report bugs to ." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -MPEG Audio Decoder config.status 0.15.1b -configured by $0, generated by GNU Autoconf 2.69, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2012 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=?*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - --*=) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg= - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - '') as_fn_error $? "missing file argument" ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error $? "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error $? "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" - - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' -macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' -enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' -enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' -pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' -enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' -SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' -ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' -PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' -host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' -host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' -host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' -build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' -build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' -build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' -SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' -Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' -GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' -EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' -FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' -LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' -NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' -LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' -max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' -ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' -exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' -lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' -lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' -lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' -lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' -lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' -reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' -reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' -OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' -deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' -file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' -file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' -want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' -DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' -sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' -AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' -AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' -archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' -STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' -RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' -old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' -old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' -lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' -CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' -CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' -compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' -GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' -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"`' -nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' -lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' -objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' -MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' -need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' -MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' -DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' -NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' -LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' -OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' -OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' -libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' -shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' -extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' -compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' -module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' -with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' -no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' -hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' -hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' -inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' -link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' -always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' -exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' -include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' -prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' -postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' -file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' -variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' -need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' -need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' -version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' -runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' -libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' -library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' -soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' -install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' -postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' -postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' -finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' -hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' -sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' -sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' -hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' -enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' -old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' -striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' - -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in SHELL \ -ECHO \ -PATH_SEPARATOR \ -SED \ -GREP \ -EGREP \ -FGREP \ -LD \ -NM \ -LN_S \ -lt_SP2NL \ -lt_NL2SP \ -reload_flag \ -OBJDUMP \ -deplibs_check_method \ -file_magic_cmd \ -file_magic_glob \ -want_nocaseglob \ -DLLTOOL \ -sharedlib_from_linklib_cmd \ -AR \ -AR_FLAGS \ -archiver_list_spec \ -STRIP \ -RANLIB \ -CC \ -CFLAGS \ -compiler \ -lt_cv_sys_global_symbol_pipe \ -lt_cv_sys_global_symbol_to_cdecl \ -lt_cv_sys_global_symbol_to_c_name_address \ -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ -nm_file_list_spec \ -lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_pic \ -lt_prog_compiler_wl \ -lt_prog_compiler_static \ -lt_cv_prog_compiler_c_o \ -need_locks \ -MANIFEST_TOOL \ -DSYMUTIL \ -NMEDIT \ -LIPO \ -OTOOL \ -OTOOL64 \ -shrext_cmds \ -export_dynamic_flag_spec \ -whole_archive_flag_spec \ -compiler_needs_object \ -with_gnu_ld \ -allow_undefined_flag \ -no_undefined_flag \ -hardcode_libdir_flag_spec \ -hardcode_libdir_separator \ -exclude_expsyms \ -include_expsyms \ -file_list_spec \ -variables_saved_for_relink \ -libname_spec \ -library_names_spec \ -soname_spec \ -install_override_mode \ -finish_eval \ -old_striplib \ -striplib; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in reload_cmds \ -old_postinstall_cmds \ -old_postuninstall_cmds \ -old_archive_cmds \ -extract_expsyms_cmds \ -old_archive_from_new_cmds \ -old_archive_from_expsyms_cmds \ -archive_cmds \ -archive_expsym_cmds \ -module_cmds \ -module_expsym_cmds \ -export_symbols_cmds \ -prelink_cmds \ -postlink_cmds \ -postinstall_cmds \ -postuninstall_cmds \ -finish_cmds \ -sys_lib_search_path_spec \ -sys_lib_dlsearch_path_spec; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -ac_aux_dir='$ac_aux_dir' -xsi_shell='$xsi_shell' -lt_shell_append='$lt_shell_append' - -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi - - - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile' - - - - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "msvc++/Makefile") CONFIG_FILES="$CONFIG_FILES msvc++/Makefile" ;; - "libmad.list") CONFIG_FILES="$CONFIG_FILES libmad.list" ;; - - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= ac_tmp= - trap 'exit_status=$? - : "${ac_tmp:=$tmp}" - { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 -ac_tmp=$tmp - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$ac_tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ - || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove sole $(srcdir), -# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ -h -s/// -s/^/:/ -s/[ ]*$/:/ -s/:\$(srcdir):/:/g -s/:\${srcdir}:/:/g -s/:@srcdir@:/:/g -s/^:*// -s/:*$// -x -s/\(=[ ]*\).*/\1/ -G -s/\n// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$ac_tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF - -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. - -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_tt=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_tt"; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. - -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" - - -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$ac_tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$ac_tmp/stdin" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ - >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ - "$ac_tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&2;} - - rm -f "$ac_tmp/stdin" - case $ac_file in - -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; - *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; - esac \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" - } >"$ac_tmp/config.h" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$ac_tmp/config.h" "$ac_file" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error $? "could not create -" "$LINENO" 5 - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Older Autoconf quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named 'Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running 'make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "$am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} - ;; - "libtool":C) - - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - - -# The names of the tagged configurations supported by this script. -available_tags="" - -# ### BEGIN LIBTOOL CONFIG - -# Which release of libtool.m4 was used? -macro_version=$macro_version -macro_revision=$macro_revision - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# What type of objects to build. -pic_mode=$pic_mode - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# An echo program that protects backslashes. -ECHO=$lt_ECHO - -# The PATH separator for the build system. -PATH_SEPARATOR=$lt_PATH_SEPARATOR - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="\$SED -e 1s/^X//" - -# A grep program that handles long lines. -GREP=$lt_GREP - -# An ERE matcher. -EGREP=$lt_EGREP - -# A literal string matcher. -FGREP=$lt_FGREP - -# A BSD- or MS-compatible name lister. -NM=$lt_NM - -# Whether we need soft or hard links. -LN_S=$lt_LN_S - -# What is the maximum length of a command? -max_cmd_len=$max_cmd_len - -# Object file suffix (normally "o"). -objext=$ac_objext - -# Executable file suffix (normally ""). -exeext=$exeext - -# whether the shell understands "unset". -lt_unset=$lt_unset - -# turn spaces into newlines. -SP2NL=$lt_lt_SP2NL - -# turn newlines into spaces. -NL2SP=$lt_lt_NL2SP - -# convert \$build file names to \$host format. -to_host_file_cmd=$lt_cv_to_host_file_cmd - -# convert \$build files to toolchain format. -to_tool_file_cmd=$lt_cv_to_tool_file_cmd - -# An object symbol dumper. -OBJDUMP=$lt_OBJDUMP - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method = "file_magic". -file_magic_cmd=$lt_file_magic_cmd - -# How to find potential files when deplibs_check_method = "file_magic". -file_magic_glob=$lt_file_magic_glob - -# Find potential files using nocaseglob when deplibs_check_method = "file_magic". -want_nocaseglob=$lt_want_nocaseglob - -# DLL creation program. -DLLTOOL=$lt_DLLTOOL - -# Command to associate shared and link libraries. -sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd - -# The archiver. -AR=$lt_AR - -# Flags to create an archive. -AR_FLAGS=$lt_AR_FLAGS - -# How to feed a file listing to the archiver. -archiver_list_spec=$lt_archiver_list_spec - -# A symbol stripping program. -STRIP=$lt_STRIP - -# Commands used to install an old-style archive. -RANLIB=$lt_RANLIB -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Whether to use a lock for old archive extraction. -lock_old_archive_extraction=$lock_old_archive_extraction - -# A C compiler. -LTCC=$lt_CC - -# LTCC compiler flags. -LTCFLAGS=$lt_CFLAGS - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration. -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair. -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# Transform the output of nm in a C name address pair when lib prefix is needed. -global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix - -# Specify filename containing input files for \$NM. -nm_file_list_spec=$lt_nm_file_list_spec - -# The root where to search for dependent libraries,and in which our libraries should be installed. -lt_sysroot=$lt_sysroot - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# Used to examine libraries when file_magic_cmd begins with "file". -MAGIC_CMD=$MAGIC_CMD - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Manifest tool. -MANIFEST_TOOL=$lt_MANIFEST_TOOL - -# Tool to manipulate archived DWARF debug symbol files on Mac OS X. -DSYMUTIL=$lt_DSYMUTIL - -# Tool to change global to local symbols on Mac OS X. -NMEDIT=$lt_NMEDIT - -# Tool to manipulate fat objects and archives on Mac OS X. -LIPO=$lt_LIPO - -# ldd/readelf like tool for Mach-O binaries on Mac OS X. -OTOOL=$lt_OTOOL - -# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. -OTOOL64=$lt_OTOOL64 - -# Old archive suffix (normally "a"). -libext=$libext - -# Shared library suffix (normally ".so"). -shrext_cmds=$lt_shrext_cmds - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at link time. -variables_saved_for_relink=$lt_variables_saved_for_relink - -# Do we need the "lib" prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Library versioning type. -version_type=$version_type - -# Shared library runtime path variable. -runpath_var=$runpath_var - -# Shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Permission mode override for installation of shared libraries. -install_override_mode=$lt_install_override_mode - -# Command to use after installation of a shared archive. -postinstall_cmds=$lt_postinstall_cmds - -# Command to use after uninstallation of a shared archive. -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# As "finish_cmds", except a single script fragment to be evaled but -# not shown. -finish_eval=$lt_finish_eval - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Compile-time system search path for libraries. -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries. -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - - -# The linker used to build libraries. -LD=$lt_LD - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds - -# A language specific compiler. -CC=$lt_compiler - -# Is the compiler the GNU compiler? -with_gcc=$GCC - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct - -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \${shlibpath_var} if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action - -# ### END LIBTOOL CONFIG - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - -ltmain="$ac_aux_dir/ltmain.sh" - - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - if test x"$xsi_shell" = xyes; then - sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ -func_dirname ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_basename ()$/,/^} # func_basename /c\ -func_basename ()\ -{\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ -func_dirname_and_basename ()\ -{\ -\ case ${1} in\ -\ */*) func_dirname_result="${1%/*}${2}" ;;\ -\ * ) func_dirname_result="${3}" ;;\ -\ esac\ -\ func_basename_result="${1##*/}"\ -} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ -func_stripname ()\ -{\ -\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ -\ # positional parameters, so assign one to ordinary parameter first.\ -\ func_stripname_result=${3}\ -\ func_stripname_result=${func_stripname_result#"${1}"}\ -\ func_stripname_result=${func_stripname_result%"${2}"}\ -} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ -func_split_long_opt ()\ -{\ -\ func_split_long_opt_name=${1%%=*}\ -\ func_split_long_opt_arg=${1#*=}\ -} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ -func_split_short_opt ()\ -{\ -\ func_split_short_opt_arg=${1#??}\ -\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ -} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ -func_lo2o ()\ -{\ -\ case ${1} in\ -\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ -\ *) func_lo2o_result=${1} ;;\ -\ esac\ -} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_xform ()$/,/^} # func_xform /c\ -func_xform ()\ -{\ - func_xform_result=${1%.*}.lo\ -} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_arith ()$/,/^} # func_arith /c\ -func_arith ()\ -{\ - func_arith_result=$(( $* ))\ -} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_len ()$/,/^} # func_len /c\ -func_len ()\ -{\ - func_len_result=${#1}\ -} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - -fi - -if test x"$lt_shell_append" = xyes; then - sed -e '/^func_append ()$/,/^} # func_append /c\ -func_append ()\ -{\ - eval "${1}+=\\${2}"\ -} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ -func_append_quoted ()\ -{\ -\ func_quote_for_eval "${2}"\ -\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ -} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: - - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 -$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} -fi - - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit 1 -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - diff --git a/lib-src/libmad/configure.ac b/lib-src/libmad/configure.ac deleted file mode 100644 index 293616fab..000000000 --- a/lib-src/libmad/configure.ac +++ /dev/null @@ -1,435 +0,0 @@ -dnl -*- m4 -*- -dnl -dnl libmad - MPEG audio decoder library -dnl Copyright (C) 2000-2004 Underbit Technologies, Inc. -dnl -dnl This program is free software; you can redistribute it and/or modify -dnl it under the terms of the GNU General Public License as published by -dnl the Free Software Foundation; either version 2 of the License, or -dnl (at your option) any later version. -dnl -dnl This program is distributed in the hope that it will be useful, -dnl but WITHOUT ANY WARRANTY; without even the implied warranty of -dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -dnl GNU General Public License for more details. -dnl -dnl You should have received a copy of the GNU General Public License -dnl along with this program; if not, write to the Free Software -dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -dnl -AC_REVISION([$Id: configure.ac,v 1.4 2009-01-17 22:01:06 richardash1981 Exp $])dnl - -dnl Process this file with autoconf to produce a configure script. - -AC_INIT([MPEG Audio Decoder], [0.15.1b], [support@underbit.com], [libmad]) -AC_PREREQ(2.53) - -AC_CONFIG_SRCDIR([decoder.h]) - -AM_INIT_AUTOMAKE([-Wall foreign]) - -AM_CONFIG_HEADER([config.h]) - -AM_MAINTAINER_MODE - -dnl System type. - -AC_CANONICAL_HOST - -dnl Checks for programs. - -AC_PROG_CC -AM_PROG_AS - -if test "$GCC" = yes -then - case "$host" in - *-*-mingw*) - case "$build" in - *-*-cygwin*) - CPPFLAGS="$CPPFLAGS -mno-cygwin" - LDFLAGS="$LDFLAGS -mno-cygwin" - ;; - esac - esac - -dnl case "$host" in -dnl *-*-cygwin* | *-*-mingw*) -dnl LDFLAGS="$LDFLAGS -no-undefined -mdll" -dnl ;; -dnl esac -fi - -dnl Support for libtool. - -dnl AC_DISABLE_SHARED -dnl AC_LIBTOOL_WIN32_DLL -AC_PROG_LIBTOOL - -AC_SUBST(LIBTOOL_DEPS) - -dnl Compiler options. - -arch="" -debug="" -optimize="" -profile="" - -set -- $CFLAGS -CFLAGS="" - -if test "$GCC" = yes -then - CFLAGS="-Wall" -fi - -while test $# -gt 0 -do - case "$1" in - -Wall) - if test "$GCC" = yes - then - : - else - CFLAGS="$CFLAGS $1" - fi - shift - ;; - -g) - debug="-g" - shift - ;; - -mno-cygwin) - shift - ;; - -m*) - arch="$arch $1" - shift - ;; - -O2) - optimize="-O" - shift - ;; - -fomit-frame-pointer) - shift - ;; - -O*|-f*) - optimize="$optimize $1" - shift - ;; - *) - CFLAGS="$CFLAGS $1" - shift - ;; - esac -done - -if test "$GCC" = yes -then - if test -z "$arch" - then - case "$host" in - i386-*) ;; - i?86-*) arch="-march=i486" ;; - arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;; - armv4*-*) arch="-march=armv4 -mtune=strongarm" ;; - powerpc-*) ;; - mips*-agenda-*) arch="-mcpu=vr4100" ;; - mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;; - esac - fi - - case "$optimize" in - -O|"-O "*) - optimize="-O" - : #x optimize="$optimize -fforce-mem" - : #x optimize="$optimize -fforce-addr" - : #x optimize="$optimize -finline-functions" - : #- optimize="$optimize -fstrength-reduce" - optimize="$optimize -fthread-jumps" - optimize="$optimize -fcse-follow-jumps" - optimize="$optimize -fcse-skip-blocks" - : #x optimize="$optimize -frerun-cse-after-loop" - : #x optimize="$optimize -frerun-loop-opt" - : #x optimize="$optimize -fgcse" - optimize="$optimize -fexpensive-optimizations" - optimize="$optimize -fregmove" - : #* optimize="$optimize -fdelayed-branch" - : #x optimize="$optimize -fschedule-insns" - optimize="$optimize -fschedule-insns2" - : #? optimize="$optimize -ffunction-sections" - : #? optimize="$optimize -fcaller-saves" - : #> optimize="$optimize -funroll-loops" - : #> optimize="$optimize -funroll-all-loops" - : #x optimize="$optimize -fmove-all-movables" - : #x optimize="$optimize -freduce-all-givs" - : #? optimize="$optimize -fstrict-aliasing" - : #* optimize="$optimize -fstructure-noalias" - - case "$host" in - arm*-*) - optimize="$optimize -fstrength-reduce" - ;; - mips*-*) - optimize="$optimize -fstrength-reduce" - optimize="$optimize -finline-functions" - ;; - i?86-*) - optimize="$optimize -fstrength-reduce" - ;; - powerpc-apple-*) - # this triggers an internal compiler error with gcc2 - : #optimize="$optimize -fstrength-reduce" - - # this is really only beneficial with gcc3 - : #optimize="$optimize -finline-functions" - ;; - *) - # this sometimes provokes bugs in gcc 2.95.2 - : #optimize="$optimize -fstrength-reduce" - ;; - esac - ;; - esac -fi - -case "$host" in - mips*-agenda-*) - AC_DEFINE(HAVE_MADD16_ASM, 1, - [Define if your MIPS CPU supports a 2-operand MADD16 instruction.]) - ;; - mips*-luxsonor-*) - AC_DEFINE(HAVE_MADD_ASM, 1, - [Define if your MIPS CPU supports a 2-operand MADD instruction.]) - ;; -esac - -dnl Checks for header files. - -AC_HEADER_STDC -AC_HEADER_SYS_WAIT -AC_CHECK_HEADERS(assert.h limits.h unistd.h sys/types.h fcntl.h errno.h) - -dnl Checks for typedefs, structures, and compiler characteristics. - -AC_C_CONST -AC_C_INLINE -AC_C_BIGENDIAN -AC_TYPE_PID_T - -AC_CHECK_SIZEOF(int, 2) -AC_CHECK_SIZEOF(long, 4) -AC_CHECK_SIZEOF(long long, 8) - -dnl Checks for library functions. - -AC_CHECK_FUNCS(waitpid fcntl pipe fork) - -dnl Other options. - -AC_SUBST(FPM) -AC_SUBST(ASO) -AC_SUBST(ASO_OBJS) - -dnl handle --enable and --disable options - -AC_CACHE_SAVE - -AC_MSG_CHECKING(whether to optimize for speed or for accuracy) - -AC_ARG_ENABLE(speed, AC_HELP_STRING([--enable-speed], - [optimize for speed over accuracy]), -[ - case "$enableval" in - yes) - optimize_for="speed" - AC_DEFINE(OPT_SPEED, 1, - [Define to optimize for speed over accuracy.]) - ;; - esac -]) - -AC_ARG_ENABLE(accuracy, AC_HELP_STRING([--enable-accuracy], - [optimize for accuracy over speed]), -[ - case "$enableval" in - yes) - if test "$optimize_for" = "speed" - then - optimize_for="both" - else - optimize_for="accuracy" - fi - AC_DEFINE(OPT_ACCURACY, 1, - [Define to optimize for accuracy over speed.]) - ;; - esac -]) - -AC_MSG_RESULT(${optimize_for-default}) - -if test "$optimize_for" = "both" -then - AC_MSG_ERROR(cannot optimize for both speed and accuracy) -fi - -AC_MSG_CHECKING(for architecture-specific fixed-point math routines) -AC_ARG_ENABLE(fpm, AC_HELP_STRING([--enable-fpm=ARCH], - [use ARCH-specific fixed-point math routines - (one of: intel, arm, mips, sparc, ppc, 64bit, default)]), -[ - case "$enableval" in - yes) ;; - no|default|approx) FPM="DEFAULT" ;; - intel|i?86) FPM="INTEL" ;; - arm) FPM="ARM" ;; - mips) FPM="MIPS" ;; - sparc) FPM="SPARC" ;; - ppc|powerpc) FPM="PPC" ;; - 64bit) FPM="64BIT" ;; - float) FPM="FLOAT" ;; - *) - AC_MSG_RESULT(failed) - AC_MSG_ERROR([bad --enable-fpm option]) - ;; - esac -]) - -if test -z "$FPM" && test "$GCC" = yes -then - case "$host" in - i?86-*) FPM="INTEL" ;; - arm*-*) FPM="ARM" ;; - mips*-*) FPM="MIPS" ;; - sparc*-*) FPM="SPARC" ;; - powerpc*-*) FPM="PPC" ;; - # FIXME: need to test for 64-bit long long... - esac -fi - -AC_MSG_RESULT(${FPM=DEFAULT}) - -if test "$FPM" = "DEFAULT" -then - AC_MSG_WARN([default fixed-point math will yield limited accuracy]) -fi - -FPM="-DFPM_$FPM" - -AC_ARG_ENABLE(sso, AC_HELP_STRING([--enable-sso], - [use subband synthesis optimization]), -[ - case "$enableval" in - yes) - AC_DEFINE(OPT_SSO, 1, - [Define to enable a fast subband synthesis approximation optimization.]) - ;; - esac -]) - -AC_ARG_ENABLE(aso, AC_HELP_STRING([--disable-aso], - [disable architecture-specific optimizations]), - [], [enable_aso=yes]) - -if test "$enable_aso" = yes -then - case "$host" in - i?86-*) - : #ASO="$ASO -DASO_INTERLEAVE1" - ASO="$ASO -DASO_ZEROCHECK" - : #not yet #ASO="$ASO -DASO_SYNTH" - : #not yet #ASO_OBJS="synth_mmx.lo" - ;; - arm*-*) - ASO="$ASO -DASO_INTERLEAVE1" - ASO="$ASO -DASO_IMDCT" - ASO_OBJS="imdct_l_arm.lo" - ;; - mips*-*) - ASO="$ASO -DASO_INTERLEAVE2" - ASO="$ASO -DASO_ZEROCHECK" - ;; - esac -fi - -AC_MSG_CHECKING(for ISO/IEC interpretation) -AC_ARG_ENABLE(strict-iso, AC_HELP_STRING([--enable-strict-iso], - [use strict ISO/IEC interpretations]), -[ - case "$enableval" in - yes) - AC_DEFINE(OPT_STRICT, 1, - [Define to influence a strict interpretation of the ISO/IEC standards, - even if this is in opposition with best accepted practices.]) - interpretation="strict" - ;; - esac -]) -AC_MSG_RESULT(${interpretation-best accepted practices}) - -AC_MSG_CHECKING(whether to enable profiling) -AC_ARG_ENABLE(profiling, AC_HELP_STRING([--enable-profiling], - [generate profiling code]), -[ - case "$enableval" in - yes) profile="-pg" ;; - esac -]) -AC_MSG_RESULT(${enable_profiling-no}) - -AC_MSG_CHECKING(whether to enable debugging) -AC_ARG_ENABLE(debugging, AC_HELP_STRING([--enable-debugging], - [enable diagnostic debugging support]) -AC_HELP_STRING([--disable-debugging], - [do not enable debugging and use more optimization]), -[ - case "$enableval" in - yes) - AC_DEFINE(DEBUG, 1, - [Define to enable diagnostic debugging support.]) - optimize="" - ;; - no) - if test -n "$profile" - then - AC_MSG_ERROR(--enable-profiling and --disable-debugging are incompatible) - fi - - AC_DEFINE(NDEBUG, 1, - [Define to disable debugging assertions.]) - debug="" - if test "$GCC" = yes - then - optimize="$optimize -fomit-frame-pointer" - fi - ;; - esac -]) -AC_MSG_RESULT(${enable_debugging-default}) - -AC_MSG_CHECKING(whether to enable experimental code) -AC_ARG_ENABLE(experimental, AC_HELP_STRING([--enable-experimental], - [enable experimental code]), -[ - case "$enableval" in - yes) - AC_DEFINE(EXPERIMENTAL, 1, - [Define to enable experimental code.]) - ;; - esac -]) -AC_MSG_RESULT(${enable_experimental-no}) - -dnl Create output files. - -test -n "$arch" && CFLAGS="$CFLAGS $arch" -test -n "$debug" && CFLAGS="$CFLAGS $debug" -test -n "$optimize" && CFLAGS="$CFLAGS $optimize" -test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile" - -dnl LTLIBOBJS=`echo "$LIBOBJS" | sed -e 's/\.o/.lo/g'` -dnl AC_SUBST(LTLIBOBJS) - -AC_CONFIG_FILES([Makefile msvc++/Makefile \ - libmad.list]) -AC_OUTPUT diff --git a/lib-src/libmad/decoder.c b/lib-src/libmad/decoder.c deleted file mode 100644 index 4e747c58b..000000000 --- a/lib-src/libmad/decoder.c +++ /dev/null @@ -1,582 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: decoder.c,v 1.5 2005-09-12 07:01:29 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# ifdef HAVE_SYS_TYPES_H -# include -# endif - -# ifdef HAVE_SYS_WAIT_H -# include -# endif - -# ifdef HAVE_UNISTD_H -# include -# endif - -# ifdef HAVE_FCNTL_H -# include -# endif - -# include - -# ifdef HAVE_ERRNO_H -# include -# endif - -# include "stream.h" -# include "frame.h" -# include "synth.h" -# include "decoder.h" - -/* - * NAME: decoder->init() - * DESCRIPTION: initialize a decoder object with callback routines - */ -void mad_decoder_init(struct mad_decoder *decoder, void *data, - enum mad_flow (*input_func)(void *, - struct mad_stream *), - enum mad_flow (*header_func)(void *, - struct mad_header const *), - enum mad_flow (*filter_func)(void *, - struct mad_stream const *, - struct mad_frame *), - enum mad_flow (*output_func)(void *, - struct mad_header const *, - struct mad_pcm *), - enum mad_flow (*error_func)(void *, - struct mad_stream *, - struct mad_frame *), - enum mad_flow (*message_func)(void *, - void *, unsigned int *)) -{ - decoder->mode = -1; - - decoder->options = 0; - - decoder->async.pid = 0; - decoder->async.in = -1; - decoder->async.out = -1; - - decoder->sync = 0; - - decoder->cb_data = data; - - decoder->input_func = input_func; - decoder->header_func = header_func; - decoder->filter_func = filter_func; - decoder->output_func = output_func; - decoder->error_func = error_func; - decoder->message_func = message_func; -} - -int mad_decoder_finish(struct mad_decoder *decoder) -{ -# if defined(USE_ASYNC) - if (decoder->mode == MAD_DECODER_MODE_ASYNC && decoder->async.pid) { - pid_t pid; - int status; - - close(decoder->async.in); - - do - pid = waitpid(decoder->async.pid, &status, 0); - while (pid == -1 && errno == EINTR); - - decoder->mode = -1; - - close(decoder->async.out); - - decoder->async.pid = 0; - decoder->async.in = -1; - decoder->async.out = -1; - - if (pid == -1) - return -1; - - return (!WIFEXITED(status) || WEXITSTATUS(status)) ? -1 : 0; - } -# endif - - return 0; -} - -# if defined(USE_ASYNC) -static -enum mad_flow send_io(int fd, void const *data, size_t len) -{ - char const *ptr = data; - ssize_t count; - - while (len) { - do - count = write(fd, ptr, len); - while (count == -1 && errno == EINTR); - - if (count == -1) - return MAD_FLOW_BREAK; - - len -= count; - ptr += count; - } - - return MAD_FLOW_CONTINUE; -} - -static -enum mad_flow receive_io(int fd, void *buffer, size_t len) -{ - char *ptr = buffer; - ssize_t count; - - while (len) { - do - count = read(fd, ptr, len); - while (count == -1 && errno == EINTR); - - if (count == -1) - return (errno == EAGAIN) ? MAD_FLOW_IGNORE : MAD_FLOW_BREAK; - else if (count == 0) - return MAD_FLOW_STOP; - - len -= count; - ptr += count; - } - - return MAD_FLOW_CONTINUE; -} - -static -enum mad_flow receive_io_blocking(int fd, void *buffer, size_t len) -{ - int flags, blocking; - enum mad_flow result; - - flags = fcntl(fd, F_GETFL); - if (flags == -1) - return MAD_FLOW_BREAK; - - blocking = flags & ~O_NONBLOCK; - - if (blocking != flags && - fcntl(fd, F_SETFL, blocking) == -1) - return MAD_FLOW_BREAK; - - result = receive_io(fd, buffer, len); - - if (flags != blocking && - fcntl(fd, F_SETFL, flags) == -1) - return MAD_FLOW_BREAK; - - return result; -} - -static -enum mad_flow send(int fd, void const *message, unsigned int size) -{ - enum mad_flow result; - - /* send size */ - - result = send_io(fd, &size, sizeof(size)); - - /* send message */ - - if (result == MAD_FLOW_CONTINUE) - result = send_io(fd, message, size); - - return result; -} - -static -enum mad_flow receive(int fd, void **message, unsigned int *size) -{ - enum mad_flow result; - unsigned int actual; - - if (*message == 0) - *size = 0; - - /* receive size */ - - result = receive_io(fd, &actual, sizeof(actual)); - - /* receive message */ - - if (result == MAD_FLOW_CONTINUE) { - if (actual > *size) - actual -= *size; - else { - *size = actual; - actual = 0; - } - - if (*size > 0) { - if (*message == 0) { - *message = malloc(*size); - if (*message == 0) - return MAD_FLOW_BREAK; - } - - result = receive_io_blocking(fd, *message, *size); - } - - /* throw away remainder of message */ - - while (actual && result == MAD_FLOW_CONTINUE) { - char sink[256]; - unsigned int len; - - len = actual > sizeof(sink) ? sizeof(sink) : actual; - - result = receive_io_blocking(fd, sink, len); - - actual -= len; - } - } - - return result; -} - -static -enum mad_flow check_message(struct mad_decoder *decoder) -{ - enum mad_flow result; - void *message = 0; - unsigned int size; - - result = receive(decoder->async.in, &message, &size); - - if (result == MAD_FLOW_CONTINUE) { - if (decoder->message_func == 0) - size = 0; - else { - result = decoder->message_func(decoder->cb_data, message, &size); - - if (result == MAD_FLOW_IGNORE || - result == MAD_FLOW_BREAK) - size = 0; - } - - if (send(decoder->async.out, message, size) != MAD_FLOW_CONTINUE) - result = MAD_FLOW_BREAK; - } - - if (message) - free(message); - - return result; -} -# endif - -static -enum mad_flow error_default(void *data, struct mad_stream *stream, - struct mad_frame *frame) -{ - int *bad_last_frame = data; - - switch (stream->error) { - case MAD_ERROR_BADCRC: - if (*bad_last_frame) - mad_frame_mute(frame); - else - *bad_last_frame = 1; - - return MAD_FLOW_IGNORE; - - default: - return MAD_FLOW_CONTINUE; - } -} - -static -int run_sync(struct mad_decoder *decoder) -{ - enum mad_flow (*error_func)(void *, struct mad_stream *, struct mad_frame *); - void *error_data; - int bad_last_frame = 0; - struct mad_stream *stream; - struct mad_frame *frame; - struct mad_synth *synth; - int result = 0; - - if (decoder->input_func == 0) - return 0; - - if (decoder->error_func) { - error_func = decoder->error_func; - error_data = decoder->cb_data; - } - else { - error_func = error_default; - error_data = &bad_last_frame; - } - - stream = &decoder->sync->stream; - frame = &decoder->sync->frame; - synth = &decoder->sync->synth; - - mad_stream_init(stream); - mad_frame_init(frame); - mad_synth_init(synth); - - mad_stream_options(stream, decoder->options); - - do { - switch (decoder->input_func(decoder->cb_data, stream)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - continue; - case MAD_FLOW_CONTINUE: - break; - } - - while (1) { -# if defined(USE_ASYNC) - if (decoder->mode == MAD_DECODER_MODE_ASYNC) { - switch (check_message(decoder)) { - case MAD_FLOW_IGNORE: - case MAD_FLOW_CONTINUE: - break; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_STOP: - goto done; - } - } -# endif - - if (decoder->header_func) { - if (mad_header_decode(&frame->header, stream) == -1) { - if (!MAD_RECOVERABLE(stream->error)) - break; - - switch (error_func(error_data, stream, frame)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - case MAD_FLOW_CONTINUE: - default: - continue; - } - } - - switch (decoder->header_func(decoder->cb_data, &frame->header)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - continue; - case MAD_FLOW_CONTINUE: - break; - } - } - - if (mad_frame_decode(frame, stream) == -1) { - if (!MAD_RECOVERABLE(stream->error)) - break; - - switch (error_func(error_data, stream, frame)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - break; - case MAD_FLOW_CONTINUE: - default: - continue; - } - } - else - bad_last_frame = 0; - - if (decoder->filter_func) { - switch (decoder->filter_func(decoder->cb_data, stream, frame)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - continue; - case MAD_FLOW_CONTINUE: - break; - } - } - - mad_synth_frame(synth, frame); - - if (decoder->output_func) { - switch (decoder->output_func(decoder->cb_data, - &frame->header, &synth->pcm)) { - case MAD_FLOW_STOP: - goto done; - case MAD_FLOW_BREAK: - goto fail; - case MAD_FLOW_IGNORE: - case MAD_FLOW_CONTINUE: - break; - } - } - } - } - while (stream->error == MAD_ERROR_BUFLEN); - - fail: - result = -1; - - done: - mad_synth_finish(synth); - mad_frame_finish(frame); - mad_stream_finish(stream); - - return result; -} - -# if defined(USE_ASYNC) -static -int run_async(struct mad_decoder *decoder) -{ - pid_t pid; - int ptoc[2], ctop[2], flags; - - if (pipe(ptoc) == -1) - return -1; - - if (pipe(ctop) == -1) { - close(ptoc[0]); - close(ptoc[1]); - return -1; - } - - flags = fcntl(ptoc[0], F_GETFL); - if (flags == -1 || - fcntl(ptoc[0], F_SETFL, flags | O_NONBLOCK) == -1) { - close(ctop[0]); - close(ctop[1]); - close(ptoc[0]); - close(ptoc[1]); - return -1; - } - - pid = fork(); - if (pid == -1) { - close(ctop[0]); - close(ctop[1]); - close(ptoc[0]); - close(ptoc[1]); - return -1; - } - - decoder->async.pid = pid; - - if (pid) { - /* parent */ - - close(ptoc[0]); - close(ctop[1]); - - decoder->async.in = ctop[0]; - decoder->async.out = ptoc[1]; - - return 0; - } - - /* child */ - - close(ptoc[1]); - close(ctop[0]); - - decoder->async.in = ptoc[0]; - decoder->async.out = ctop[1]; - - _exit(run_sync(decoder)); - - /* not reached */ - return -1; -} -# endif - -/* - * NAME: decoder->run() - * DESCRIPTION: run the decoder thread either synchronously or asynchronously - */ -int mad_decoder_run(struct mad_decoder *decoder, enum mad_decoder_mode mode) -{ - int result; - int (*run)(struct mad_decoder *) = 0; - - switch (decoder->mode = mode) { - case MAD_DECODER_MODE_SYNC: - run = run_sync; - break; - - case MAD_DECODER_MODE_ASYNC: -# if defined(USE_ASYNC) - run = run_async; -# endif - break; - } - - if (run == 0) - return -1; - - decoder->sync = malloc(sizeof(*decoder->sync)); - if (decoder->sync == 0) - return -1; - - result = run(decoder); - - free(decoder->sync); - decoder->sync = 0; - - return result; -} - -/* - * NAME: decoder->message() - * DESCRIPTION: send a message to and receive a reply from the decoder process - */ -int mad_decoder_message(struct mad_decoder *decoder, - void *message, unsigned int *len) -{ -# if defined(USE_ASYNC) - if (decoder->mode != MAD_DECODER_MODE_ASYNC || - send(decoder->async.out, message, *len) != MAD_FLOW_CONTINUE || - receive(decoder->async.in, &message, len) != MAD_FLOW_CONTINUE) - return -1; - - return 0; -# else - return -1; -# endif -} diff --git a/lib-src/libmad/decoder.h b/lib-src/libmad/decoder.h deleted file mode 100644 index 82202f0bc..000000000 --- a/lib-src/libmad/decoder.h +++ /dev/null @@ -1,91 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: decoder.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_DECODER_H -# define LIBMAD_DECODER_H - -# include "stream.h" -# include "frame.h" -# include "synth.h" - -enum mad_decoder_mode { - MAD_DECODER_MODE_SYNC = 0, - MAD_DECODER_MODE_ASYNC -}; - -enum mad_flow { - MAD_FLOW_CONTINUE = 0x0000, /* continue normally */ - MAD_FLOW_STOP = 0x0010, /* stop decoding normally */ - MAD_FLOW_BREAK = 0x0011, /* stop decoding and signal an error */ - MAD_FLOW_IGNORE = 0x0020 /* ignore the current frame */ -}; - -struct mad_decoder { - enum mad_decoder_mode mode; - - int options; - - struct { - long pid; - int in; - int out; - } async; - - struct { - struct mad_stream stream; - struct mad_frame frame; - struct mad_synth synth; - } *sync; - - void *cb_data; - - enum mad_flow (*input_func)(void *, struct mad_stream *); - enum mad_flow (*header_func)(void *, struct mad_header const *); - enum mad_flow (*filter_func)(void *, - struct mad_stream const *, struct mad_frame *); - enum mad_flow (*output_func)(void *, - struct mad_header const *, struct mad_pcm *); - enum mad_flow (*error_func)(void *, struct mad_stream *, struct mad_frame *); - enum mad_flow (*message_func)(void *, void *, unsigned int *); -}; - -void mad_decoder_init(struct mad_decoder *, void *, - enum mad_flow (*)(void *, struct mad_stream *), - enum mad_flow (*)(void *, struct mad_header const *), - enum mad_flow (*)(void *, - struct mad_stream const *, - struct mad_frame *), - enum mad_flow (*)(void *, - struct mad_header const *, - struct mad_pcm *), - enum mad_flow (*)(void *, - struct mad_stream *, - struct mad_frame *), - enum mad_flow (*)(void *, void *, unsigned int *)); -int mad_decoder_finish(struct mad_decoder *); - -# define mad_decoder_options(decoder, opts) \ - ((void) ((decoder)->options = (opts))) - -int mad_decoder_run(struct mad_decoder *, enum mad_decoder_mode); -int mad_decoder_message(struct mad_decoder *, void *, unsigned int *); - -# endif diff --git a/lib-src/libmad/depcomp b/lib-src/libmad/depcomp deleted file mode 100755 index 4ebd5b3a2..000000000 --- a/lib-src/libmad/depcomp +++ /dev/null @@ -1,791 +0,0 @@ -#! /bin/sh -# depcomp - compile a program generating dependencies as side-effects - -scriptversion=2013-05-30.07; # UTC - -# Copyright (C) 1999-2013 Free Software Foundation, Inc. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Originally written by Alexandre Oliva . - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: depcomp [--help] [--version] PROGRAM [ARGS] - -Run PROGRAMS ARGS to compile a file, generating dependencies -as side-effects. - -Environment variables: - depmode Dependency tracking mode. - source Source file read by 'PROGRAMS ARGS'. - object Object file output by 'PROGRAMS ARGS'. - DEPDIR directory where to store dependencies. - depfile Dependency file to output. - tmpdepfile Temporary file to use when outputting dependencies. - libtool Whether libtool is used (yes/no). - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "depcomp $scriptversion" - exit $? - ;; -esac - -# Get the directory component of the given path, and save it in the -# global variables '$dir'. Note that this directory component will -# be either empty or ending with a '/' character. This is deliberate. -set_dir_from () -{ - case $1 in - */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; - *) dir=;; - esac -} - -# Get the suffix-stripped basename of the given path, and save it the -# global variable '$base'. -set_base_from () -{ - base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` -} - -# If no dependency file was actually created by the compiler invocation, -# we still have to create a dummy depfile, to avoid errors with the -# Makefile "include basename.Plo" scheme. -make_dummy_depfile () -{ - echo "#dummy" > "$depfile" -} - -# Factor out some common post-processing of the generated depfile. -# Requires the auxiliary global variable '$tmpdepfile' to be set. -aix_post_process_depfile () -{ - # If the compiler actually managed to produce a dependency file, - # post-process it. - if test -f "$tmpdepfile"; then - # Each line is of the form 'foo.o: dependency.h'. - # Do two passes, one to just change these to - # $object: dependency.h - # and one to simply output - # dependency.h: - # which is needed to avoid the deleted-header problem. - { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" - sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" - } > "$depfile" - rm -f "$tmpdepfile" - else - make_dummy_depfile - fi -} - -# A tabulation character. -tab=' ' -# A newline character. -nl=' -' -# Character ranges might be problematic outside the C locale. -# These definitions help. -upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ -lower=abcdefghijklmnopqrstuvwxyz -digits=0123456789 -alpha=${upper}${lower} - -if test -z "$depmode" || test -z "$source" || test -z "$object"; then - echo "depcomp: Variables source, object and depmode must be set" 1>&2 - exit 1 -fi - -# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. -depfile=${depfile-`echo "$object" | - sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} -tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} - -rm -f "$tmpdepfile" - -# Avoid interferences from the environment. -gccflag= dashmflag= - -# Some modes work just like other modes, but use different flags. We -# parameterize here, but still list the modes in the big case below, -# to make depend.m4 easier to write. Note that we *cannot* use a case -# here, because this file can only contain one case statement. -if test "$depmode" = hp; then - # HP compiler uses -M and no extra arg. - gccflag=-M - depmode=gcc -fi - -if test "$depmode" = dashXmstdout; then - # This is just like dashmstdout with a different argument. - dashmflag=-xM - depmode=dashmstdout -fi - -cygpath_u="cygpath -u -f -" -if test "$depmode" = msvcmsys; then - # This is just like msvisualcpp but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvisualcpp -fi - -if test "$depmode" = msvc7msys; then - # This is just like msvc7 but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvc7 -fi - -if test "$depmode" = xlc; then - # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. - gccflag=-qmakedep=gcc,-MF - depmode=gcc -fi - -case "$depmode" in -gcc3) -## gcc 3 implements dependency tracking that does exactly what -## we want. Yay! Note: for some reason libtool 1.4 doesn't like -## it if -MD -MP comes after the -MF stuff. Hmm. -## Unfortunately, FreeBSD c89 acceptance of flags depends upon -## the command line argument order; so add the flags where they -## appear in depend2.am. Note that the slowdown incurred here -## affects only configure: in makefiles, %FASTDEP% shortcuts this. - for arg - do - case $arg in - -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; - *) set fnord "$@" "$arg" ;; - esac - shift # fnord - shift # $arg - done - "$@" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - mv "$tmpdepfile" "$depfile" - ;; - -gcc) -## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. -## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. -## (see the conditional assignment to $gccflag above). -## There are various ways to get dependency output from gcc. Here's -## why we pick this rather obscure method: -## - Don't want to use -MD because we'd like the dependencies to end -## up in a subdir. Having to rename by hand is ugly. -## (We might end up doing this anyway to support other compilers.) -## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like -## -MM, not -M (despite what the docs say). Also, it might not be -## supported by the other compilers which use the 'gcc' depmode. -## - Using -M directly means running the compiler twice (even worse -## than renaming). - if test -z "$gccflag"; then - gccflag=-MD, - fi - "$@" -Wp,"$gccflag$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The second -e expression handles DOS-style file names with drive - # letters. - sed -e 's/^[^:]*: / /' \ - -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" -## This next piece of magic avoids the "deleted header file" problem. -## The problem is that when a header file which appears in a .P file -## is deleted, the dependency causes make to die (because there is -## typically no way to rebuild the header). We avoid this by adding -## dummy dependencies for each header file. Too bad gcc doesn't do -## this for us directly. -## Some versions of gcc put a space before the ':'. On the theory -## that the space means something, we add a space to the output as -## well. hp depmode also adds that space, but also prefixes the VPATH -## to the object. Take care to not repeat it in the output. -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -sgi) - if test "$libtool" = yes; then - "$@" "-Wp,-MDupdate,$tmpdepfile" - else - "$@" -MDupdate "$tmpdepfile" - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - - if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files - echo "$object : \\" > "$depfile" - # Clip off the initial element (the dependent). Don't try to be - # clever and replace this with sed code, as IRIX sed won't handle - # lines with more than a fixed number of characters (4096 in - # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; - # the IRIX cc adds comments like '#:fec' to the end of the - # dependency line. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ - | tr "$nl" ' ' >> "$depfile" - echo >> "$depfile" - # The second pass generates a dummy entry for each header file. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" - ;; - -xlc) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -aix) - # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. In older versions, this file always lives in the - # current directory. Also, the AIX compiler puts '$object:' at the - # start of each line; $object doesn't have directory information. - # Version 6 uses the directory in both cases. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.u - tmpdepfile2=$base.u - tmpdepfile3=$dir.libs/$base.u - "$@" -Wc,-M - else - tmpdepfile1=$dir$base.u - tmpdepfile2=$dir$base.u - tmpdepfile3=$dir$base.u - "$@" -M - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - aix_post_process_depfile - ;; - -tcc) - # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 - # FIXME: That version still under development at the moment of writing. - # Make that this statement remains true also for stable, released - # versions. - # It will wrap lines (doesn't matter whether long or short) with a - # trailing '\', as in: - # - # foo.o : \ - # foo.c \ - # foo.h \ - # - # It will put a trailing '\' even on the last line, and will use leading - # spaces rather than leading tabs (at least since its commit 0394caf7 - # "Emit spaces for -MD"). - "$@" -MD -MF "$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. - # We have to change lines of the first kind to '$object: \'. - sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" - # And for each line of the second kind, we have to emit a 'dep.h:' - # dummy dependency, to avoid the deleted-header problem. - sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" - rm -f "$tmpdepfile" - ;; - -## The order of this option in the case statement is important, since the -## shell code in configure will try each of these formats in the order -## listed in this file. A plain '-MD' option would be understood by many -## compilers, so we must ensure this comes after the gcc and icc options. -pgcc) - # Portland's C compiler understands '-MD'. - # Will always output deps to 'file.d' where file is the root name of the - # source file under compilation, even if file resides in a subdirectory. - # The object file name does not affect the name of the '.d' file. - # pgcc 10.2 will output - # foo.o: sub/foo.c sub/foo.h - # and will wrap long lines using '\' : - # foo.o: sub/foo.c ... \ - # sub/foo.h ... \ - # ... - set_dir_from "$object" - # Use the source, not the object, to determine the base name, since - # that's sadly what pgcc will do too. - set_base_from "$source" - tmpdepfile=$base.d - - # For projects that build the same source file twice into different object - # files, the pgcc approach of using the *source* file root name can cause - # problems in parallel builds. Use a locking strategy to avoid stomping on - # the same $tmpdepfile. - lockdir=$base.d-lock - trap " - echo '$0: caught signal, cleaning up...' >&2 - rmdir '$lockdir' - exit 1 - " 1 2 13 15 - numtries=100 - i=$numtries - while test $i -gt 0; do - # mkdir is a portable test-and-set. - if mkdir "$lockdir" 2>/dev/null; then - # This process acquired the lock. - "$@" -MD - stat=$? - # Release the lock. - rmdir "$lockdir" - break - else - # If the lock is being held by a different process, wait - # until the winning process is done or we timeout. - while test -d "$lockdir" && test $i -gt 0; do - sleep 1 - i=`expr $i - 1` - done - fi - i=`expr $i - 1` - done - trap - 1 2 13 15 - if test $i -le 0; then - echo "$0: failed to acquire lock after $numtries attempts" >&2 - echo "$0: check lockdir '$lockdir'" >&2 - exit 1 - fi - - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each line is of the form `foo.o: dependent.h', - # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp2) - # The "hp" stanza above does not work with aCC (C++) and HP's ia64 - # compilers, which have integrated preprocessors. The correct option - # to use with these is +Maked; it writes dependencies to a file named - # 'foo.d', which lands next to the object file, wherever that - # happens to be. - # Much of this is similar to the tru64 case; see comments there. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir.libs/$base.d - "$@" -Wc,+Maked - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - "$@" +Maked - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" - do - test -f "$tmpdepfile" && break - done - if test -f "$tmpdepfile"; then - sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" - # Add 'dependent.h:' lines. - sed -ne '2,${ - s/^ *// - s/ \\*$// - s/$/:/ - p - }' "$tmpdepfile" >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" "$tmpdepfile2" - ;; - -tru64) - # The Tru64 compiler uses -MD to generate dependencies as a side - # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. - # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put - # dependencies in 'foo.d' instead, so we check for that too. - # Subdirectories are respected. - set_dir_from "$object" - set_base_from "$object" - - if test "$libtool" = yes; then - # Libtool generates 2 separate objects for the 2 libraries. These - # two compilations output dependencies in $dir.libs/$base.o.d and - # in $dir$base.o.d. We have to check for both files, because - # one of the two compilations can be disabled. We should prefer - # $dir$base.o.d over $dir.libs/$base.o.d because the latter is - # automatically cleaned when .libs/ is deleted, while ignoring - # the former would cause a distcleancheck panic. - tmpdepfile1=$dir$base.o.d # libtool 1.5 - tmpdepfile2=$dir.libs/$base.o.d # Likewise. - tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 - "$@" -Wc,-MD - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - tmpdepfile3=$dir$base.d - "$@" -MD - fi - - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - # Same post-processing that is required for AIX mode. - aix_post_process_depfile - ;; - -msvc7) - if test "$libtool" = yes; then - showIncludes=-Wc,-showIncludes - else - showIncludes=-showIncludes - fi - "$@" $showIncludes > "$tmpdepfile" - stat=$? - grep -v '^Note: including file: ' "$tmpdepfile" - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The first sed program below extracts the file names and escapes - # backslashes for cygpath. The second sed program outputs the file - # name when reading, but also accumulates all include files in the - # hold buffer in order to output them again at the end. This only - # works with sed implementations that can handle large buffers. - sed < "$tmpdepfile" -n ' -/^Note: including file: *\(.*\)/ { - s//\1/ - s/\\/\\\\/g - p -}' | $cygpath_u | sort -u | sed -n ' -s/ /\\ /g -s/\(.*\)/'"$tab"'\1 \\/p -s/.\(.*\) \\/\1:/ -H -$ { - s/.*/'"$tab"'/ - G - p -}' >> "$depfile" - echo >> "$depfile" # make sure the fragment doesn't end with a backslash - rm -f "$tmpdepfile" - ;; - -msvc7msys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -#nosideeffect) - # This comment above is used by automake to tell side-effect - # dependency tracking mechanisms from slower ones. - -dashmstdout) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - test -z "$dashmflag" && dashmflag=-M - # Require at least two characters before searching for ':' - # in the target name. This is to cope with DOS-style filenames: - # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. - "$@" $dashmflag | - sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this sed invocation - # correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -dashXmstdout) - # This case only exists to satisfy depend.m4. It is never actually - # run, as this mode is specially recognized in the preamble. - exit 1 - ;; - -makedepend) - "$@" || exit $? - # Remove any Libtool call - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - # X makedepend - shift - cleared=no eat=no - for arg - do - case $cleared in - no) - set ""; shift - cleared=yes ;; - esac - if test $eat = yes; then - eat=no - continue - fi - case "$arg" in - -D*|-I*) - set fnord "$@" "$arg"; shift ;; - # Strip any option that makedepend may not understand. Remove - # the object too, otherwise makedepend will parse it as a source file. - -arch) - eat=yes ;; - -*|$object) - ;; - *) - set fnord "$@" "$arg"; shift ;; - esac - done - obj_suffix=`echo "$object" | sed 's/^.*\././'` - touch "$tmpdepfile" - ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" - rm -f "$depfile" - # makedepend may prepend the VPATH from the source file name to the object. - # No need to regex-escape $object, excess matching of '.' is harmless. - sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process the last invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed '1,2d' "$tmpdepfile" \ - | tr ' ' "$nl" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" "$tmpdepfile".bak - ;; - -cpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - "$@" -E \ - | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - | sed '$ s: \\$::' > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - cat < "$tmpdepfile" >> "$depfile" - sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvisualcpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - IFS=" " - for arg - do - case "$arg" in - -o) - shift - ;; - $object) - shift - ;; - "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") - set fnord "$@" - shift - shift - ;; - *) - set fnord "$@" "$arg" - shift - shift - ;; - esac - done - "$@" -E 2>/dev/null | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" - echo "$tab" >> "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvcmsys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -none) - exec "$@" - ;; - -*) - echo "Unknown depmode $depmode" 1>&2 - exit 1 - ;; -esac - -exit 0 - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libmad/fixed.c b/lib-src/libmad/fixed.c deleted file mode 100644 index b9123344d..000000000 --- a/lib-src/libmad/fixed.c +++ /dev/null @@ -1,81 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: fixed.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "fixed.h" - -/* - * NAME: fixed->abs() - * DESCRIPTION: return absolute value of a fixed-point number - */ -mad_fixed_t mad_f_abs(mad_fixed_t x) -{ - return x < 0 ? -x : x; -} - -/* - * NAME: fixed->div() - * DESCRIPTION: perform division using fixed-point math - */ -mad_fixed_t mad_f_div(mad_fixed_t x, mad_fixed_t y) -{ - mad_fixed_t q, r; - unsigned int bits; - - q = mad_f_abs(x / y); - - if (x < 0) { - x = -x; - y = -y; - } - - r = x % y; - - if (y < 0) { - x = -x; - y = -y; - } - - if (q > mad_f_intpart(MAD_F_MAX) && - !(q == -mad_f_intpart(MAD_F_MIN) && r == 0 && (x < 0) != (y < 0))) - return 0; - - for (bits = MAD_F_FRACBITS; bits && r; --bits) { - q <<= 1, r <<= 1; - if (r >= y) - r -= y, ++q; - } - - /* round */ - if (2 * r >= y) - ++q; - - /* fix sign */ - if ((x < 0) != (y < 0)) - q = -q; - - return q << bits; -} diff --git a/lib-src/libmad/fixed.h b/lib-src/libmad/fixed.h deleted file mode 100644 index b6eff6c68..000000000 --- a/lib-src/libmad/fixed.h +++ /dev/null @@ -1,499 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: fixed.h,v 1.3 2008-02-02 11:37:37 richardash1981 Exp $ - */ - -# ifndef LIBMAD_FIXED_H -# define LIBMAD_FIXED_H - -# if SIZEOF_INT >= 4 -typedef signed int mad_fixed_t; - -typedef signed int mad_fixed64hi_t; -typedef unsigned int mad_fixed64lo_t; -# else -typedef signed long mad_fixed_t; - -typedef signed long mad_fixed64hi_t; -typedef unsigned long mad_fixed64lo_t; -# endif - -# if defined(_MSC_VER) -# define mad_fixed64_t signed __int64 -# elif 1 || defined(__GNUC__) -# define mad_fixed64_t signed long long -# endif - -# if defined(FPM_FLOAT) -typedef double mad_sample_t; -# else -typedef mad_fixed_t mad_sample_t; -# endif - -/* - * Fixed-point format: 0xABBBBBBB - * A == whole part (sign + 3 bits) - * B == fractional part (28 bits) - * - * Values are signed two's complement, so the effective range is: - * 0x80000000 to 0x7fffffff - * -8.0 to +7.9999999962747097015380859375 - * - * The smallest representable value is: - * 0x00000001 == 0.0000000037252902984619140625 (i.e. about 3.725e-9) - * - * 28 bits of fractional accuracy represent about - * 8.6 digits of decimal accuracy. - * - * Fixed-point numbers can be added or subtracted as normal - * integers, but multiplication requires shifting the 64-bit result - * from 56 fractional bits back to 28 (and rounding.) - * - * Changing the definition of MAD_F_FRACBITS is only partially - * supported, and must be done with care. - */ - -# define MAD_F_FRACBITS 28 - -# if MAD_F_FRACBITS == 28 -# define MAD_F(x) ((mad_fixed_t) (x##L)) -# else -# if MAD_F_FRACBITS < 28 -# warning "MAD_F_FRACBITS < 28" -# define MAD_F(x) ((mad_fixed_t) \ - (((x##L) + \ - (1L << (28 - MAD_F_FRACBITS - 1))) >> \ - (28 - MAD_F_FRACBITS))) -# elif MAD_F_FRACBITS > 28 -# error "MAD_F_FRACBITS > 28 not currently supported" -# define MAD_F(x) ((mad_fixed_t) \ - ((x##L) << (MAD_F_FRACBITS - 28))) -# endif -# endif - -# define MAD_F_MIN ((mad_fixed_t) -0x80000000L) -# define MAD_F_MAX ((mad_fixed_t) +0x7fffffffL) - -# define MAD_F_ONE MAD_F(0x10000000) - -# define mad_f_tofixed(x) ((mad_fixed_t) \ - ((x) * (double) (1L << MAD_F_FRACBITS) + 0.5)) -# define mad_f_todouble(x) ((double) \ - ((x) / (double) (1L << MAD_F_FRACBITS))) - -# define mad_f_intpart(x) ((x) >> MAD_F_FRACBITS) -# define mad_f_fracpart(x) ((x) & ((1L << MAD_F_FRACBITS) - 1)) - /* (x should be positive) */ - -# define mad_f_fromint(x) ((x) << MAD_F_FRACBITS) - -# define mad_f_add(x, y) ((x) + (y)) -# define mad_f_sub(x, y) ((x) - (y)) - -# if defined(FPM_FLOAT) -# error "FPM_FLOAT not yet supported" - -# undef MAD_F -# define MAD_F(x) mad_f_todouble(x) - -# define mad_f_mul(x, y) ((x) * (y)) -# define mad_f_scale64 - -# undef ASO_ZEROCHECK - -# elif defined(FPM_64BIT) - -/* - * This version should be the most accurate if 64-bit types are supported by - * the compiler, although it may not be the most efficient. - */ -# if defined(OPT_ACCURACY) -# define mad_f_mul(x, y) \ - ((mad_fixed_t) \ - ((((mad_fixed64_t) (x) * (y)) + \ - (1L << (MAD_F_SCALEBITS - 1))) >> MAD_F_SCALEBITS)) -# else -# define mad_f_mul(x, y) \ - ((mad_fixed_t) (((mad_fixed64_t) (x) * (y)) >> MAD_F_SCALEBITS)) -# endif - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- Intel --------------------------------------------------------------- */ - -# elif defined(FPM_INTEL) || defined (__i386__) - -# if defined(_MSC_VER) -# pragma warning(push) -# pragma warning(disable: 4035) /* no return value */ -static __forceinline -mad_fixed_t mad_f_mul_inline(mad_fixed_t x, mad_fixed_t y) -{ - enum { - fracbits = MAD_F_FRACBITS - }; - - __asm { - mov eax, x - imul y - shrd eax, edx, fracbits - } - - /* implicit return of eax */ -} -# pragma warning(pop) - -# define mad_f_mul mad_f_mul_inline -# define mad_f_scale64 -# else -/* - * This Intel version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("imull %3" \ - : "=a" (lo), "=d" (hi) \ - : "%a" (x), "rm" (y) \ - : "cc") - -# if defined(OPT_ACCURACY) -/* - * This gives best accuracy but is not very fast. - */ -# define MAD_F_MLA(hi, lo, x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - asm ("addl %2,%0\n\t" \ - "adcl %3,%1" \ - : "=rm" (lo), "=rm" (hi) \ - : "r" (__lo), "r" (__hi), "0" (lo), "1" (hi) \ - : "cc"); \ - }) -# endif /* OPT_ACCURACY */ - -# if defined(OPT_ACCURACY) -/* - * Surprisingly, this is faster than SHRD followed by ADC. - */ -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed64hi_t __hi_; \ - mad_fixed64lo_t __lo_; \ - mad_fixed_t __result; \ - asm ("addl %4,%2\n\t" \ - "adcl %5,%3" \ - : "=rm" (__lo_), "=rm" (__hi_) \ - : "0" (lo), "1" (hi), \ - "ir" (1L << (MAD_F_SCALEBITS - 1)), "ir" (0) \ - : "cc"); \ - asm ("shrdl %3,%2,%1" \ - : "=rm" (__result) \ - : "0" (__lo_), "r" (__hi_), "I" (MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# elif defined(OPT_INTEL) -/* - * Alternate Intel scaling that may or may not perform better. - */ -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("shrl %3,%1\n\t" \ - "shll %4,%2\n\t" \ - "orl %2,%1" \ - : "=rm" (__result) \ - : "0" (lo), "r" (hi), \ - "I" (MAD_F_SCALEBITS), "I" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# else -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("shrdl %3,%2,%1" \ - : "=rm" (__result) \ - : "0" (lo), "r" (hi), "I" (MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# endif /* OPT_ACCURACY */ - -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* --- ARM ----------------------------------------------------------------- */ - -# elif defined(FPM_ARM) - -/* - * This ARM V4 version is as accurate as FPM_64BIT but much faster. The - * least significant bit is properly rounded at no CPU cycle cost! - */ -# if 1 -/* - * This is faster than the default implementation via MAD_F_MLX() and - * mad_f_scale64(). - */ -# define mad_f_mul(x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - mad_fixed_t __result; \ - asm ("smull %0, %1, %3, %4\n\t" \ - "movs %0, %0, lsr %5\n\t" \ - "adc %2, %0, %1, lsl %6" \ - : "=&r" (__lo), "=&r" (__hi), "=r" (__result) \ - : "%r" (x), "r" (y), \ - "M" (MAD_F_SCALEBITS), "M" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# endif - -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("smull %0, %1, %2, %3" \ - : "=&r" (lo), "=&r" (hi) \ - : "%r" (x), "r" (y)) - -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("smlal %0, %1, %2, %3" \ - : "+r" (lo), "+r" (hi) \ - : "%r" (x), "r" (y)) - -# define MAD_F_MLN(hi, lo) \ - asm ("rsbs %0, %2, #0\n\t" \ - "rsc %1, %3, #0" \ - : "=r" (lo), "=r" (hi) \ - : "0" (lo), "1" (hi) \ - : "cc") - -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("movs %0, %1, lsr %3\n\t" \ - "adc %0, %0, %2, lsl %4" \ - : "=&r" (__result) \ - : "r" (lo), "r" (hi), \ - "M" (MAD_F_SCALEBITS), "M" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- MIPS ---------------------------------------------------------------- */ - -# elif defined(FPM_MIPS) - -/* - * This MIPS version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("mult %2,%3" \ - : "=l" (lo), "=h" (hi) \ - : "%r" (x), "r" (y)) - -# if defined(HAVE_MADD_ASM) -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("madd %2,%3" \ - : "+l" (lo), "+h" (hi) \ - : "%r" (x), "r" (y)) -# elif defined(HAVE_MADD16_ASM) -/* - * This loses significant accuracy due to the 16-bit integer limit in the - * multiply/accumulate instruction. - */ -# define MAD_F_ML0(hi, lo, x, y) \ - asm ("mult %2,%3" \ - : "=l" (lo), "=h" (hi) \ - : "%r" ((x) >> 12), "r" ((y) >> 16)) -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("madd16 %2,%3" \ - : "+l" (lo), "+h" (hi) \ - : "%r" ((x) >> 12), "r" ((y) >> 16)) -# define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo)) -# endif - -# if defined(OPT_SPEED) -# define mad_f_scale64(hi, lo) \ - ((mad_fixed_t) ((hi) << (32 - MAD_F_SCALEBITS))) -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* --- SPARC --------------------------------------------------------------- */ - -# elif defined(FPM_SPARC) - -/* - * This SPARC V8 version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("smul %2, %3, %0\n\t" \ - "rd %%y, %1" \ - : "=r" (lo), "=r" (hi) \ - : "%r" (x), "rI" (y)) - -/* --- PowerPC ------------------------------------------------------------- */ - -# elif defined(FPM_PPC) || defined(__ppc__) - -/* - * This PowerPC version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - do { \ - asm ("mullw %0,%1,%2" \ - : "=r" (lo) \ - : "%r" (x), "r" (y)); \ - asm ("mulhw %0,%1,%2" \ - : "=r" (hi) \ - : "%r" (x), "r" (y)); \ - } \ - while (0) - -# if defined(OPT_ACCURACY) -/* - * This gives best accuracy but is not very fast. - */ -# define MAD_F_MLA(hi, lo, x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - asm ("addc %0,%2,%3\n\t" \ - "adde %1,%4,%5" \ - : "=r" (lo), "=r" (hi) \ - : "%r" (lo), "r" (__lo), \ - "%r" (hi), "r" (__hi) \ - : "xer"); \ - }) -# endif - -# if defined(OPT_ACCURACY) -/* - * This is slower than the truncating version below it. - */ -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result, __round; \ - asm ("rotrwi %0,%1,%2" \ - : "=r" (__result) \ - : "r" (lo), "i" (MAD_F_SCALEBITS)); \ - asm ("extrwi %0,%1,1,0" \ - : "=r" (__round) \ - : "r" (__result)); \ - asm ("insrwi %0,%1,%2,0" \ - : "+r" (__result) \ - : "r" (hi), "i" (MAD_F_SCALEBITS)); \ - asm ("add %0,%1,%2" \ - : "=r" (__result) \ - : "%r" (__result), "r" (__round)); \ - __result; \ - }) -# else -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("rotrwi %0,%1,%2" \ - : "=r" (__result) \ - : "r" (lo), "i" (MAD_F_SCALEBITS)); \ - asm ("insrwi %0,%1,%2,0" \ - : "+r" (__result) \ - : "r" (hi), "i" (MAD_F_SCALEBITS)); \ - __result; \ - }) -# endif - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- Default ------------------------------------------------------------- */ - -# elif defined(FPM_DEFAULT) - -/* - * This version is the most portable but it loses significant accuracy. - * Furthermore, accuracy is biased against the second argument, so care - * should be taken when ordering operands. - * - * The scale factors are constant as this is not used with SSO. - * - * Pre-rounding is required to stay within the limits of compliance. - */ -# if defined(OPT_SPEED) -# define mad_f_mul(x, y) (((x) >> 12) * ((y) >> 16)) -# else -# define mad_f_mul(x, y) ((((x) + (1L << 11)) >> 12) * \ - (((y) + (1L << 15)) >> 16)) -# endif - -/* ------------------------------------------------------------------------- */ - -# else -# error "no FPM selected" -# endif - -/* default implementations */ - -# if !defined(mad_f_mul) -# define mad_f_mul(x, y) \ - ({ register mad_fixed64hi_t __hi; \ - register mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - mad_f_scale64(__hi, __lo); \ - }) -# endif - -# if !defined(MAD_F_MLA) -# define MAD_F_ML0(hi, lo, x, y) ((lo) = mad_f_mul((x), (y))) -# define MAD_F_MLA(hi, lo, x, y) ((lo) += mad_f_mul((x), (y))) -# define MAD_F_MLN(hi, lo) ((lo) = -(lo)) -# define MAD_F_MLZ(hi, lo) ((void) (hi), (mad_fixed_t) (lo)) -# endif - -# if !defined(MAD_F_ML0) -# define MAD_F_ML0(hi, lo, x, y) MAD_F_MLX((hi), (lo), (x), (y)) -# endif - -# if !defined(MAD_F_MLN) -# define MAD_F_MLN(hi, lo) ((hi) = ((lo) = -(lo)) ? ~(hi) : -(hi)) -# endif - -# if !defined(MAD_F_MLZ) -# define MAD_F_MLZ(hi, lo) mad_f_scale64((hi), (lo)) -# endif - -# if !defined(mad_f_scale64) -# if defined(OPT_ACCURACY) -# define mad_f_scale64(hi, lo) \ - ((((mad_fixed_t) \ - (((hi) << (32 - (MAD_F_SCALEBITS - 1))) | \ - ((lo) >> (MAD_F_SCALEBITS - 1)))) + 1) >> 1) -# else -# define mad_f_scale64(hi, lo) \ - ((mad_fixed_t) \ - (((hi) << (32 - MAD_F_SCALEBITS)) | \ - ((lo) >> MAD_F_SCALEBITS))) -# endif -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* C routines */ - -mad_fixed_t mad_f_abs(mad_fixed_t); -mad_fixed_t mad_f_div(mad_fixed_t, mad_fixed_t); - -# endif diff --git a/lib-src/libmad/frame.c b/lib-src/libmad/frame.c deleted file mode 100644 index d6e1ef446..000000000 --- a/lib-src/libmad/frame.c +++ /dev/null @@ -1,503 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frame.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "bit.h" -# include "stream.h" -# include "frame.h" -# include "timer.h" -# include "layer12.h" -# include "layer3.h" - -static -unsigned long const bitrate_table[5][15] = { - /* MPEG-1 */ - { 0, 32000, 64000, 96000, 128000, 160000, 192000, 224000, /* Layer I */ - 256000, 288000, 320000, 352000, 384000, 416000, 448000 }, - { 0, 32000, 48000, 56000, 64000, 80000, 96000, 112000, /* Layer II */ - 128000, 160000, 192000, 224000, 256000, 320000, 384000 }, - { 0, 32000, 40000, 48000, 56000, 64000, 80000, 96000, /* Layer III */ - 112000, 128000, 160000, 192000, 224000, 256000, 320000 }, - - /* MPEG-2 LSF */ - { 0, 32000, 48000, 56000, 64000, 80000, 96000, 112000, /* Layer I */ - 128000, 144000, 160000, 176000, 192000, 224000, 256000 }, - { 0, 8000, 16000, 24000, 32000, 40000, 48000, 56000, /* Layers */ - 64000, 80000, 96000, 112000, 128000, 144000, 160000 } /* II & III */ -}; - -static -unsigned int const samplerate_table[3] = { 44100, 48000, 32000 }; - -static -int (*const decoder_table[3])(struct mad_stream *, struct mad_frame *) = { - mad_layer_I, - mad_layer_II, - mad_layer_III -}; - -/* - * NAME: header->init() - * DESCRIPTION: initialize header struct - */ -void mad_header_init(struct mad_header *header) -{ - header->layer = 0; - header->mode = 0; - header->mode_extension = 0; - header->emphasis = 0; - - header->bitrate = 0; - header->samplerate = 0; - - header->crc_check = 0; - header->crc_target = 0; - - header->flags = 0; - header->private_bits = 0; - - header->duration = mad_timer_zero; -} - -/* - * NAME: frame->init() - * DESCRIPTION: initialize frame struct - */ -void mad_frame_init(struct mad_frame *frame) -{ - mad_header_init(&frame->header); - - frame->options = 0; - - frame->overlap = 0; - mad_frame_mute(frame); -} - -/* - * NAME: frame->finish() - * DESCRIPTION: deallocate any dynamic memory associated with frame - */ -void mad_frame_finish(struct mad_frame *frame) -{ - mad_header_finish(&frame->header); - - if (frame->overlap) { - free(frame->overlap); - frame->overlap = 0; - } -} - -/* - * NAME: decode_header() - * DESCRIPTION: read header data and following CRC word - */ -static -int decode_header(struct mad_header *header, struct mad_stream *stream) -{ - unsigned int index; - - header->flags = 0; - header->private_bits = 0; - - /* header() */ - - /* syncword */ - mad_bit_skip(&stream->ptr, 11); - - /* MPEG 2.5 indicator (really part of syncword) */ - if (mad_bit_read(&stream->ptr, 1) == 0) - header->flags |= MAD_FLAG_MPEG_2_5_EXT; - - /* ID */ - if (mad_bit_read(&stream->ptr, 1) == 0) - header->flags |= MAD_FLAG_LSF_EXT; - else if (header->flags & MAD_FLAG_MPEG_2_5_EXT) { - stream->error = MAD_ERROR_LOSTSYNC; - return -1; - } - - /* layer */ - header->layer = 4 - mad_bit_read(&stream->ptr, 2); - - if ((int)header->layer == 4) { - stream->error = MAD_ERROR_BADLAYER; - return -1; - } - - /* protection_bit */ - if (mad_bit_read(&stream->ptr, 1) == 0) { - header->flags |= MAD_FLAG_PROTECTION; - header->crc_check = mad_bit_crc(stream->ptr, 16, 0xffff); - } - - /* bitrate_index */ - index = mad_bit_read(&stream->ptr, 4); - - if (index == 15) { - stream->error = MAD_ERROR_BADBITRATE; - return -1; - } - - if (header->flags & MAD_FLAG_LSF_EXT) - header->bitrate = bitrate_table[3 + (header->layer >> 1)][index]; - else - header->bitrate = bitrate_table[header->layer - 1][index]; - - /* sampling_frequency */ - index = mad_bit_read(&stream->ptr, 2); - - if (index == 3) { - stream->error = MAD_ERROR_BADSAMPLERATE; - return -1; - } - - header->samplerate = samplerate_table[index]; - - if (header->flags & MAD_FLAG_LSF_EXT) { - header->samplerate /= 2; - - if (header->flags & MAD_FLAG_MPEG_2_5_EXT) - header->samplerate /= 2; - } - - /* padding_bit */ - if (mad_bit_read(&stream->ptr, 1)) - header->flags |= MAD_FLAG_PADDING; - - /* private_bit */ - if (mad_bit_read(&stream->ptr, 1)) - header->private_bits |= MAD_PRIVATE_HEADER; - - /* mode */ - header->mode = 3 - mad_bit_read(&stream->ptr, 2); - - /* mode_extension */ - header->mode_extension = mad_bit_read(&stream->ptr, 2); - - /* copyright */ - if (mad_bit_read(&stream->ptr, 1)) - header->flags |= MAD_FLAG_COPYRIGHT; - - /* original/copy */ - if (mad_bit_read(&stream->ptr, 1)) - header->flags |= MAD_FLAG_ORIGINAL; - - /* emphasis */ - header->emphasis = mad_bit_read(&stream->ptr, 2); - -# if defined(OPT_STRICT) - /* - * ISO/IEC 11172-3 says this is a reserved emphasis value, but - * streams exist which use it anyway. Since the value is not important - * to the decoder proper, we allow it unless OPT_STRICT is defined. - */ - if (header->emphasis == MAD_EMPHASIS_RESERVED) { - stream->error = MAD_ERROR_BADEMPHASIS; - return -1; - } -# endif - - /* error_check() */ - - /* crc_check */ - if (header->flags & MAD_FLAG_PROTECTION) - header->crc_target = mad_bit_read(&stream->ptr, 16); - - return 0; -} - -/* - * NAME: free_bitrate() - * DESCRIPTION: attempt to discover the bitstream's free bitrate - */ -static -int free_bitrate(struct mad_stream *stream, struct mad_header const *header) -{ - struct mad_bitptr keep_ptr; - unsigned long rate = 0; - unsigned int pad_slot, slots_per_frame; - unsigned char const *ptr = 0; - - keep_ptr = stream->ptr; - - pad_slot = (header->flags & MAD_FLAG_PADDING) ? 1 : 0; - slots_per_frame = (header->layer == MAD_LAYER_III && - (header->flags & MAD_FLAG_LSF_EXT)) ? 72 : 144; - - while (mad_stream_sync(stream) == 0) { - struct mad_stream peek_stream; - struct mad_header peek_header; - - peek_stream = *stream; - peek_header = *header; - - if (decode_header(&peek_header, &peek_stream) == 0 && - peek_header.layer == header->layer && - peek_header.samplerate == header->samplerate) { - unsigned int N; - - ptr = mad_bit_nextbyte(&stream->ptr); - - N = ptr - stream->this_frame; - - if (header->layer == MAD_LAYER_I) { - rate = (unsigned long) header->samplerate * - (N - 4 * pad_slot + 4) / 48 / 1000; - } - else { - rate = (unsigned long) header->samplerate * - (N - pad_slot + 1) / slots_per_frame / 1000; - } - - if (rate >= 8) - break; - } - - mad_bit_skip(&stream->ptr, 8); - } - - stream->ptr = keep_ptr; - - if (rate < 8 || (header->layer == MAD_LAYER_III && rate > 640)) { - stream->error = MAD_ERROR_LOSTSYNC; - return -1; - } - - stream->freerate = rate * 1000; - - return 0; -} - -/* - * NAME: header->decode() - * DESCRIPTION: read the next frame header from the stream - */ -int mad_header_decode(struct mad_header *header, struct mad_stream *stream) -{ - register unsigned char const *ptr, *end; - unsigned int pad_slot, N; - - ptr = stream->next_frame; - end = stream->bufend; - - if (ptr == 0) { - stream->error = MAD_ERROR_BUFPTR; - goto fail; - } - - /* stream skip */ - if (stream->skiplen) { - if (!stream->sync) - ptr = stream->this_frame; - - if (end - ptr < stream->skiplen) { - stream->skiplen -= end - ptr; - stream->next_frame = end; - - stream->error = MAD_ERROR_BUFLEN; - goto fail; - } - - ptr += stream->skiplen; - stream->skiplen = 0; - - stream->sync = 1; - } - - sync: - /* synchronize */ - if (stream->sync) { - if (end - ptr < MAD_BUFFER_GUARD) { - stream->next_frame = ptr; - - stream->error = MAD_ERROR_BUFLEN; - goto fail; - } - else if (!(ptr[0] == 0xff && (ptr[1] & 0xe0) == 0xe0)) { - /* mark point where frame sync word was expected */ - stream->this_frame = ptr; - stream->next_frame = ptr + 1; - - stream->error = MAD_ERROR_LOSTSYNC; - goto fail; - } - } - else { - mad_bit_init(&stream->ptr, ptr); - - if (mad_stream_sync(stream) == -1) { - if (end - stream->next_frame >= MAD_BUFFER_GUARD) - stream->next_frame = end - MAD_BUFFER_GUARD; - - stream->error = MAD_ERROR_BUFLEN; - goto fail; - } - - ptr = mad_bit_nextbyte(&stream->ptr); - } - - /* begin processing */ - stream->this_frame = ptr; - stream->next_frame = ptr + 1; /* possibly bogus sync word */ - - mad_bit_init(&stream->ptr, stream->this_frame); - - if (decode_header(header, stream) == -1) - goto fail; - - /* calculate frame duration */ - mad_timer_set(&header->duration, 0, - 32 * MAD_NSBSAMPLES(header), header->samplerate); - - /* calculate free bit rate */ - if (header->bitrate == 0) { - if ((stream->freerate == 0 || !stream->sync || - (header->layer == MAD_LAYER_III && stream->freerate > 640000)) && - free_bitrate(stream, header) == -1) - goto fail; - - header->bitrate = stream->freerate; - header->flags |= MAD_FLAG_FREEFORMAT; - } - - /* calculate beginning of next frame */ - pad_slot = (header->flags & MAD_FLAG_PADDING) ? 1 : 0; - - if (header->layer == MAD_LAYER_I) - N = ((12 * header->bitrate / header->samplerate) + pad_slot) * 4; - else { - unsigned int slots_per_frame; - - slots_per_frame = (header->layer == MAD_LAYER_III && - (header->flags & MAD_FLAG_LSF_EXT)) ? 72 : 144; - - N = (slots_per_frame * header->bitrate / header->samplerate) + pad_slot; - } - - /* verify there is enough data left in buffer to decode this frame */ - if (N + MAD_BUFFER_GUARD > end - stream->this_frame) { - stream->next_frame = stream->this_frame; - - stream->error = MAD_ERROR_BUFLEN; - goto fail; - } - - stream->next_frame = stream->this_frame + N; - - if (!stream->sync) { - /* check that a valid frame header follows this frame */ - - ptr = stream->next_frame; - if (!(ptr[0] == 0xff && (ptr[1] & 0xe0) == 0xe0)) { - ptr = stream->next_frame = stream->this_frame + 1; - goto sync; - } - - stream->sync = 1; - } - - header->flags |= MAD_FLAG_INCOMPLETE; - - return 0; - - fail: - stream->sync = 0; - - return -1; -} - -/* - * NAME: frame->decode() - * DESCRIPTION: decode a single frame from a bitstream - */ -int mad_frame_decode(struct mad_frame *frame, struct mad_stream *stream) -{ - frame->options = stream->options; - - /* header() */ - /* error_check() */ - - if (!(frame->header.flags & MAD_FLAG_INCOMPLETE) && - mad_header_decode(&frame->header, stream) == -1) - goto fail; - - /* audio_data() */ - - frame->header.flags &= ~MAD_FLAG_INCOMPLETE; - - if (decoder_table[frame->header.layer - 1](stream, frame) == -1) { - if (!MAD_RECOVERABLE(stream->error)) - stream->next_frame = stream->this_frame; - - goto fail; - } - - /* ancillary_data() */ - - if (frame->header.layer != MAD_LAYER_III) { - struct mad_bitptr next_frame; - - mad_bit_init(&next_frame, stream->next_frame); - - stream->anc_ptr = stream->ptr; - stream->anc_bitlen = mad_bit_length(&stream->ptr, &next_frame); - - mad_bit_finish(&next_frame); - } - - return 0; - - fail: - stream->anc_bitlen = 0; - return -1; -} - -/* - * NAME: frame->mute() - * DESCRIPTION: zero all subband values so the frame becomes silent - */ -void mad_frame_mute(struct mad_frame *frame) -{ - unsigned int s, sb; - - for (s = 0; s < 36; ++s) { - for (sb = 0; sb < 32; ++sb) { - frame->sbsample[0][s][sb] = - frame->sbsample[1][s][sb] = 0; - } - } - - if (frame->overlap) { - for (s = 0; s < 18; ++s) { - for (sb = 0; sb < 32; ++sb) { - (*frame->overlap)[0][sb][s] = - (*frame->overlap)[1][sb][s] = 0; - } - } - } -} diff --git a/lib-src/libmad/frame.h b/lib-src/libmad/frame.h deleted file mode 100644 index 87c9606cd..000000000 --- a/lib-src/libmad/frame.h +++ /dev/null @@ -1,118 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: frame.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_FRAME_H -# define LIBMAD_FRAME_H - -# include "fixed.h" -# include "timer.h" -# include "stream.h" - -enum mad_layer { - MAD_LAYER_I = 1, /* Layer I */ - MAD_LAYER_II = 2, /* Layer II */ - MAD_LAYER_III = 3 /* Layer III */ -}; - -enum mad_mode { - MAD_MODE_SINGLE_CHANNEL = 0, /* single channel */ - MAD_MODE_DUAL_CHANNEL = 1, /* dual channel */ - MAD_MODE_JOINT_STEREO = 2, /* joint (MS/intensity) stereo */ - MAD_MODE_STEREO = 3 /* normal LR stereo */ -}; - -enum mad_emphasis { - MAD_EMPHASIS_NONE = 0, /* no emphasis */ - MAD_EMPHASIS_50_15_US = 1, /* 50/15 microseconds emphasis */ - MAD_EMPHASIS_CCITT_J_17 = 3, /* CCITT J.17 emphasis */ - MAD_EMPHASIS_RESERVED = 2 /* unknown emphasis */ -}; - -struct mad_header { - enum mad_layer layer; /* audio layer (1, 2, or 3) */ - enum mad_mode mode; /* channel mode (see above) */ - int mode_extension; /* additional mode info */ - enum mad_emphasis emphasis; /* de-emphasis to use (see above) */ - - unsigned long bitrate; /* stream bitrate (bps) */ - unsigned int samplerate; /* sampling frequency (Hz) */ - - unsigned short crc_check; /* frame CRC accumulator */ - unsigned short crc_target; /* final target CRC checksum */ - - int flags; /* flags (see below) */ - int private_bits; /* private bits (see below) */ - - mad_timer_t duration; /* audio playing time of frame */ -}; - -struct mad_frame { - struct mad_header header; /* MPEG audio header */ - - int options; /* decoding options (from stream) */ - - mad_fixed_t sbsample[2][36][32]; /* synthesis subband filter samples */ - mad_fixed_t (*overlap)[2][32][18]; /* Layer III block overlap data */ -}; - -# define MAD_NCHANNELS(header) ((header)->mode ? 2 : 1) -# define MAD_NSBSAMPLES(header) \ - ((header)->layer == MAD_LAYER_I ? 12 : \ - (((header)->layer == MAD_LAYER_III && \ - ((header)->flags & MAD_FLAG_LSF_EXT)) ? 18 : 36)) - -enum { - MAD_FLAG_NPRIVATE_III = 0x0007, /* number of Layer III private bits */ - MAD_FLAG_INCOMPLETE = 0x0008, /* header but not data is decoded */ - - MAD_FLAG_PROTECTION = 0x0010, /* frame has CRC protection */ - MAD_FLAG_COPYRIGHT = 0x0020, /* frame is copyright */ - MAD_FLAG_ORIGINAL = 0x0040, /* frame is original (else copy) */ - MAD_FLAG_PADDING = 0x0080, /* frame has additional slot */ - - MAD_FLAG_I_STEREO = 0x0100, /* uses intensity joint stereo */ - MAD_FLAG_MS_STEREO = 0x0200, /* uses middle/side joint stereo */ - MAD_FLAG_FREEFORMAT = 0x0400, /* uses free format bitrate */ - - MAD_FLAG_LSF_EXT = 0x1000, /* lower sampling freq. extension */ - MAD_FLAG_MC_EXT = 0x2000, /* multichannel audio extension */ - MAD_FLAG_MPEG_2_5_EXT = 0x4000 /* MPEG 2.5 (unofficial) extension */ -}; - -enum { - MAD_PRIVATE_HEADER = 0x0100, /* header private bit */ - MAD_PRIVATE_III = 0x001f /* Layer III private bits (up to 5) */ -}; - -void mad_header_init(struct mad_header *); - -# define mad_header_finish(header) /* nothing */ - -int mad_header_decode(struct mad_header *, struct mad_stream *); - -void mad_frame_init(struct mad_frame *); -void mad_frame_finish(struct mad_frame *); - -int mad_frame_decode(struct mad_frame *, struct mad_stream *); - -void mad_frame_mute(struct mad_frame *); - -# endif diff --git a/lib-src/libmad/global.h b/lib-src/libmad/global.h deleted file mode 100644 index 9ff055667..000000000 --- a/lib-src/libmad/global.h +++ /dev/null @@ -1,58 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: global.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_GLOBAL_H -# define LIBMAD_GLOBAL_H - -/* conditional debugging */ - -# if defined(DEBUG) && defined(NDEBUG) -# error "cannot define both DEBUG and NDEBUG" -# endif - -# if defined(DEBUG) -# include -# endif - -/* conditional features */ - -# if defined(OPT_SPEED) && defined(OPT_ACCURACY) -# error "cannot optimize for both speed and accuracy" -# endif - -# if defined(OPT_SPEED) && !defined(OPT_SSO) -# define OPT_SSO -# endif - -# if defined(HAVE_UNISTD_H) && defined(HAVE_WAITPID) && \ - defined(HAVE_FCNTL) && defined(HAVE_PIPE) && defined(HAVE_FORK) -# define USE_ASYNC -# endif - -# if !defined(HAVE_ASSERT_H) -# if defined(NDEBUG) -# define assert(x) /* nothing */ -# else -# define assert(x) do { if (!(x)) abort(); } while (0) -# endif -# endif - -# endif diff --git a/lib-src/libmad/huffman.c b/lib-src/libmad/huffman.c deleted file mode 100644 index 1e8d98c67..000000000 --- a/lib-src/libmad/huffman.c +++ /dev/null @@ -1,3109 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: huffman.c,v 1.4 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "huffman.h" - -/* - * These are the Huffman code words for Layer III. - * The data for these tables are derived from Table B.7 of ISO/IEC 11172-3. - * - * These tables support decoding up to 4 Huffman code bits at a time. - */ - -# if defined(__GNUC__) || \ - (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901) -# define PTR(offs, bits) { .ptr = { 0, bits, offs } } -# define V(v, w, x, y, hlen) { .value = { 1, hlen, v, w, x, y } } -# else -# define PTR(offs, bits) { { 0, bits, offs } } -# if defined(WORDS_BIGENDIAN) -# define V(v, w, x, y, hlen) { { 1, hlen, (v << 11) | (w << 10) | \ - (x << 9) | (y << 8) } } -# else -# define V(v, w, x, y, hlen) { { 1, hlen, (v << 0) | (w << 1) | \ - (x << 2) | (y << 3) } } -# endif -# endif - -static -union huffquad const hufftabA[] = { - /* 0000 */ PTR(16, 2), - /* 0001 */ PTR(20, 2), - /* 0010 */ PTR(24, 1), - /* 0011 */ PTR(26, 1), - /* 0100 */ V(0, 0, 1, 0, 4), - /* 0101 */ V(0, 0, 0, 1, 4), - /* 0110 */ V(0, 1, 0, 0, 4), - /* 0111 */ V(1, 0, 0, 0, 4), - /* 1000 */ V(0, 0, 0, 0, 1), - /* 1001 */ V(0, 0, 0, 0, 1), - /* 1010 */ V(0, 0, 0, 0, 1), - /* 1011 */ V(0, 0, 0, 0, 1), - /* 1100 */ V(0, 0, 0, 0, 1), - /* 1101 */ V(0, 0, 0, 0, 1), - /* 1110 */ V(0, 0, 0, 0, 1), - /* 1111 */ V(0, 0, 0, 0, 1), - - /* 0000 ... */ - /* 00 */ V(1, 0, 1, 1, 2), /* 16 */ - /* 01 */ V(1, 1, 1, 1, 2), - /* 10 */ V(1, 1, 0, 1, 2), - /* 11 */ V(1, 1, 1, 0, 2), - - /* 0001 ... */ - /* 00 */ V(0, 1, 1, 1, 2), /* 20 */ - /* 01 */ V(0, 1, 0, 1, 2), - /* 10 */ V(1, 0, 0, 1, 1), - /* 11 */ V(1, 0, 0, 1, 1), - - /* 0010 ... */ - /* 0 */ V(0, 1, 1, 0, 1), /* 24 */ - /* 1 */ V(0, 0, 1, 1, 1), - - /* 0011 ... */ - /* 0 */ V(1, 0, 1, 0, 1), /* 26 */ - /* 1 */ V(1, 1, 0, 0, 1) -}; - -static -union huffquad const hufftabB[] = { - /* 0000 */ V(1, 1, 1, 1, 4), - /* 0001 */ V(1, 1, 1, 0, 4), - /* 0010 */ V(1, 1, 0, 1, 4), - /* 0011 */ V(1, 1, 0, 0, 4), - /* 0100 */ V(1, 0, 1, 1, 4), - /* 0101 */ V(1, 0, 1, 0, 4), - /* 0110 */ V(1, 0, 0, 1, 4), - /* 0111 */ V(1, 0, 0, 0, 4), - /* 1000 */ V(0, 1, 1, 1, 4), - /* 1001 */ V(0, 1, 1, 0, 4), - /* 1010 */ V(0, 1, 0, 1, 4), - /* 1011 */ V(0, 1, 0, 0, 4), - /* 1100 */ V(0, 0, 1, 1, 4), - /* 1101 */ V(0, 0, 1, 0, 4), - /* 1110 */ V(0, 0, 0, 1, 4), - /* 1111 */ V(0, 0, 0, 0, 4) -}; - -# undef V -# undef PTR - -# if defined(__GNUC__) || \ - (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901) -# define PTR(offs, bits) { .ptr = { 0, bits, offs } } -# define V(x, y, hlen) { .value = { 1, hlen, x, y } } -# else -# define PTR(offs, bits) { { 0, bits, offs } } -# if defined(WORDS_BIGENDIAN) -# define V(x, y, hlen) { { 1, hlen, (x << 8) | (y << 4) } } -# else -# define V(x, y, hlen) { { 1, hlen, (x << 0) | (y << 4) } } -# endif -# endif - -static -union huffpair const hufftab0[] = { - /* */ V(0, 0, 0) -}; - -static -union huffpair const hufftab1[] = { - /* 000 */ V(1, 1, 3), - /* 001 */ V(0, 1, 3), - /* 010 */ V(1, 0, 2), - /* 011 */ V(1, 0, 2), - /* 100 */ V(0, 0, 1), - /* 101 */ V(0, 0, 1), - /* 110 */ V(0, 0, 1), - /* 111 */ V(0, 0, 1) -}; - -static -union huffpair const hufftab2[] = { - /* 000 */ PTR(8, 3), - /* 001 */ V(1, 1, 3), - /* 010 */ V(0, 1, 3), - /* 011 */ V(1, 0, 3), - /* 100 */ V(0, 0, 1), - /* 101 */ V(0, 0, 1), - /* 110 */ V(0, 0, 1), - /* 111 */ V(0, 0, 1), - - /* 000 ... */ - /* 000 */ V(2, 2, 3), /* 8 */ - /* 001 */ V(0, 2, 3), - /* 010 */ V(1, 2, 2), - /* 011 */ V(1, 2, 2), - /* 100 */ V(2, 1, 2), - /* 101 */ V(2, 1, 2), - /* 110 */ V(2, 0, 2), - /* 111 */ V(2, 0, 2) -}; - -static -union huffpair const hufftab3[] = { - /* 000 */ PTR(8, 3), - /* 001 */ V(1, 0, 3), - /* 010 */ V(1, 1, 2), - /* 011 */ V(1, 1, 2), - /* 100 */ V(0, 1, 2), - /* 101 */ V(0, 1, 2), - /* 110 */ V(0, 0, 2), - /* 111 */ V(0, 0, 2), - - /* 000 ... */ - /* 000 */ V(2, 2, 3), /* 8 */ - /* 001 */ V(0, 2, 3), - /* 010 */ V(1, 2, 2), - /* 011 */ V(1, 2, 2), - /* 100 */ V(2, 1, 2), - /* 101 */ V(2, 1, 2), - /* 110 */ V(2, 0, 2), - /* 111 */ V(2, 0, 2) -}; - -static -union huffpair const hufftab5[] = { - /* 000 */ PTR(8, 4), - /* 001 */ V(1, 1, 3), - /* 010 */ V(0, 1, 3), - /* 011 */ V(1, 0, 3), - /* 100 */ V(0, 0, 1), - /* 101 */ V(0, 0, 1), - /* 110 */ V(0, 0, 1), - /* 111 */ V(0, 0, 1), - - /* 000 ... */ - /* 0000 */ PTR(24, 1), /* 8 */ - /* 0001 */ V(3, 2, 4), - /* 0010 */ V(3, 1, 3), - /* 0011 */ V(3, 1, 3), - /* 0100 */ V(1, 3, 4), - /* 0101 */ V(0, 3, 4), - /* 0110 */ V(3, 0, 4), - /* 0111 */ V(2, 2, 4), - /* 1000 */ V(1, 2, 3), - /* 1001 */ V(1, 2, 3), - /* 1010 */ V(2, 1, 3), - /* 1011 */ V(2, 1, 3), - /* 1100 */ V(0, 2, 3), - /* 1101 */ V(0, 2, 3), - /* 1110 */ V(2, 0, 3), - /* 1111 */ V(2, 0, 3), - - /* 000 0000 ... */ - /* 0 */ V(3, 3, 1), /* 24 */ - /* 1 */ V(2, 3, 1) -}; - -static -union huffpair const hufftab6[] = { - /* 0000 */ PTR(16, 3), - /* 0001 */ PTR(24, 1), - /* 0010 */ PTR(26, 1), - /* 0011 */ V(1, 2, 4), - /* 0100 */ V(2, 1, 4), - /* 0101 */ V(2, 0, 4), - /* 0110 */ V(0, 1, 3), - /* 0111 */ V(0, 1, 3), - /* 1000 */ V(1, 1, 2), - /* 1001 */ V(1, 1, 2), - /* 1010 */ V(1, 1, 2), - /* 1011 */ V(1, 1, 2), - /* 1100 */ V(1, 0, 3), - /* 1101 */ V(1, 0, 3), - /* 1110 */ V(0, 0, 3), - /* 1111 */ V(0, 0, 3), - - /* 0000 ... */ - /* 000 */ V(3, 3, 3), /* 16 */ - /* 001 */ V(0, 3, 3), - /* 010 */ V(2, 3, 2), - /* 011 */ V(2, 3, 2), - /* 100 */ V(3, 2, 2), - /* 101 */ V(3, 2, 2), - /* 110 */ V(3, 0, 2), - /* 111 */ V(3, 0, 2), - - /* 0001 ... */ - /* 0 */ V(1, 3, 1), /* 24 */ - /* 1 */ V(3, 1, 1), - - /* 0010 ... */ - /* 0 */ V(2, 2, 1), /* 26 */ - /* 1 */ V(0, 2, 1) -}; - -static -union huffpair const hufftab7[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 2), - /* 0011 */ V(1, 1, 4), - /* 0100 */ V(0, 1, 3), - /* 0101 */ V(0, 1, 3), - /* 0110 */ V(1, 0, 3), - /* 0111 */ V(1, 0, 3), - /* 1000 */ V(0, 0, 1), - /* 1001 */ V(0, 0, 1), - /* 1010 */ V(0, 0, 1), - /* 1011 */ V(0, 0, 1), - /* 1100 */ V(0, 0, 1), - /* 1101 */ V(0, 0, 1), - /* 1110 */ V(0, 0, 1), - /* 1111 */ V(0, 0, 1), - - /* 0000 ... */ - /* 0000 */ PTR(52, 2), /* 16 */ - /* 0001 */ PTR(56, 1), - /* 0010 */ PTR(58, 1), - /* 0011 */ V(1, 5, 4), - /* 0100 */ V(5, 1, 4), - /* 0101 */ PTR(60, 1), - /* 0110 */ V(5, 0, 4), - /* 0111 */ PTR(62, 1), - /* 1000 */ V(2, 4, 4), - /* 1001 */ V(4, 2, 4), - /* 1010 */ V(1, 4, 3), - /* 1011 */ V(1, 4, 3), - /* 1100 */ V(4, 1, 3), - /* 1101 */ V(4, 1, 3), - /* 1110 */ V(4, 0, 3), - /* 1111 */ V(4, 0, 3), - - /* 0001 ... */ - /* 0000 */ V(0, 4, 4), /* 32 */ - /* 0001 */ V(2, 3, 4), - /* 0010 */ V(3, 2, 4), - /* 0011 */ V(0, 3, 4), - /* 0100 */ V(1, 3, 3), - /* 0101 */ V(1, 3, 3), - /* 0110 */ V(3, 1, 3), - /* 0111 */ V(3, 1, 3), - /* 1000 */ V(3, 0, 3), - /* 1001 */ V(3, 0, 3), - /* 1010 */ V(2, 2, 3), - /* 1011 */ V(2, 2, 3), - /* 1100 */ V(1, 2, 2), - /* 1101 */ V(1, 2, 2), - /* 1110 */ V(1, 2, 2), - /* 1111 */ V(1, 2, 2), - - /* 0010 ... */ - /* 00 */ V(2, 1, 1), /* 48 */ - /* 01 */ V(2, 1, 1), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 00 */ V(5, 5, 2), /* 52 */ - /* 01 */ V(4, 5, 2), - /* 10 */ V(5, 4, 2), - /* 11 */ V(5, 3, 2), - - /* 0000 0001 ... */ - /* 0 */ V(3, 5, 1), /* 56 */ - /* 1 */ V(4, 4, 1), - - /* 0000 0010 ... */ - /* 0 */ V(2, 5, 1), /* 58 */ - /* 1 */ V(5, 2, 1), - - /* 0000 0101 ... */ - /* 0 */ V(0, 5, 1), /* 60 */ - /* 1 */ V(3, 4, 1), - - /* 0000 0111 ... */ - /* 0 */ V(4, 3, 1), /* 62 */ - /* 1 */ V(3, 3, 1) -}; - -# if 0 -/* this version saves 8 entries (16 bytes) at the expense of - an extra lookup in 4 out of 36 cases */ -static -union huffpair const hufftab8[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 2), - /* 0010 */ V(1, 2, 4), - /* 0011 */ V(2, 1, 4), - /* 0100 */ V(1, 1, 2), - /* 0101 */ V(1, 1, 2), - /* 0110 */ V(1, 1, 2), - /* 0111 */ V(1, 1, 2), - /* 1000 */ V(0, 1, 3), - /* 1001 */ V(0, 1, 3), - /* 1010 */ V(1, 0, 3), - /* 1011 */ V(1, 0, 3), - /* 1100 */ V(0, 0, 2), - /* 1101 */ V(0, 0, 2), - /* 1110 */ V(0, 0, 2), - /* 1111 */ V(0, 0, 2), - - /* 0000 ... */ - /* 0000 */ PTR(36, 3), /* 16 */ - /* 0001 */ PTR(44, 2), - /* 0010 */ PTR(48, 1), - /* 0011 */ V(1, 5, 4), - /* 0100 */ V(5, 1, 4), - /* 0101 */ PTR(50, 1), - /* 0110 */ PTR(52, 1), - /* 0111 */ V(2, 4, 4), - /* 1000 */ V(4, 2, 4), - /* 1001 */ V(1, 4, 4), - /* 1010 */ V(4, 1, 3), - /* 1011 */ V(4, 1, 3), - /* 1100 */ V(0, 4, 4), - /* 1101 */ V(4, 0, 4), - /* 1110 */ V(2, 3, 4), - /* 1111 */ V(3, 2, 4), - - /* 0001 ... */ - /* 00 */ PTR(54, 2), /* 32 */ - /* 01 */ V(2, 2, 2), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 000 */ V(5, 5, 3), /* 36 */ - /* 001 */ V(5, 4, 3), - /* 010 */ V(4, 5, 2), - /* 011 */ V(4, 5, 2), - /* 100 */ V(5, 3, 1), - /* 101 */ V(5, 3, 1), - /* 110 */ V(5, 3, 1), - /* 111 */ V(5, 3, 1), - - /* 0000 0001 ... */ - /* 00 */ V(3, 5, 2), /* 44 */ - /* 01 */ V(4, 4, 2), - /* 10 */ V(2, 5, 1), - /* 11 */ V(2, 5, 1), - - /* 0000 0010 ... */ - /* 0 */ V(5, 2, 1), /* 48 */ - /* 1 */ V(0, 5, 1), - - /* 0000 0101 ... */ - /* 0 */ V(3, 4, 1), /* 50 */ - /* 1 */ V(4, 3, 1), - - /* 0000 0110 ... */ - /* 0 */ V(5, 0, 1), /* 52 */ - /* 1 */ V(3, 3, 1), - - /* 0001 00 ... */ - /* 00 */ V(1, 3, 2), /* 54 */ - /* 01 */ V(3, 1, 2), - /* 10 */ V(0, 3, 2), - /* 11 */ V(3, 0, 2), -}; -# else -static -union huffpair const hufftab8[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ V(1, 2, 4), - /* 0011 */ V(2, 1, 4), - /* 0100 */ V(1, 1, 2), - /* 0101 */ V(1, 1, 2), - /* 0110 */ V(1, 1, 2), - /* 0111 */ V(1, 1, 2), - /* 1000 */ V(0, 1, 3), - /* 1001 */ V(0, 1, 3), - /* 1010 */ V(1, 0, 3), - /* 1011 */ V(1, 0, 3), - /* 1100 */ V(0, 0, 2), - /* 1101 */ V(0, 0, 2), - /* 1110 */ V(0, 0, 2), - /* 1111 */ V(0, 0, 2), - - /* 0000 ... */ - /* 0000 */ PTR(48, 3), /* 16 */ - /* 0001 */ PTR(56, 2), - /* 0010 */ PTR(60, 1), - /* 0011 */ V(1, 5, 4), - /* 0100 */ V(5, 1, 4), - /* 0101 */ PTR(62, 1), - /* 0110 */ PTR(64, 1), - /* 0111 */ V(2, 4, 4), - /* 1000 */ V(4, 2, 4), - /* 1001 */ V(1, 4, 4), - /* 1010 */ V(4, 1, 3), - /* 1011 */ V(4, 1, 3), - /* 1100 */ V(0, 4, 4), - /* 1101 */ V(4, 0, 4), - /* 1110 */ V(2, 3, 4), - /* 1111 */ V(3, 2, 4), - - /* 0001 ... */ - /* 0000 */ V(1, 3, 4), /* 32 */ - /* 0001 */ V(3, 1, 4), - /* 0010 */ V(0, 3, 4), - /* 0011 */ V(3, 0, 4), - /* 0100 */ V(2, 2, 2), - /* 0101 */ V(2, 2, 2), - /* 0110 */ V(2, 2, 2), - /* 0111 */ V(2, 2, 2), - /* 1000 */ V(0, 2, 2), - /* 1001 */ V(0, 2, 2), - /* 1010 */ V(0, 2, 2), - /* 1011 */ V(0, 2, 2), - /* 1100 */ V(2, 0, 2), - /* 1101 */ V(2, 0, 2), - /* 1110 */ V(2, 0, 2), - /* 1111 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 000 */ V(5, 5, 3), /* 48 */ - /* 001 */ V(5, 4, 3), - /* 010 */ V(4, 5, 2), - /* 011 */ V(4, 5, 2), - /* 100 */ V(5, 3, 1), - /* 101 */ V(5, 3, 1), - /* 110 */ V(5, 3, 1), - /* 111 */ V(5, 3, 1), - - /* 0000 0001 ... */ - /* 00 */ V(3, 5, 2), /* 56 */ - /* 01 */ V(4, 4, 2), - /* 10 */ V(2, 5, 1), - /* 11 */ V(2, 5, 1), - - /* 0000 0010 ... */ - /* 0 */ V(5, 2, 1), /* 60 */ - /* 1 */ V(0, 5, 1), - - /* 0000 0101 ... */ - /* 0 */ V(3, 4, 1), /* 62 */ - /* 1 */ V(4, 3, 1), - - /* 0000 0110 ... */ - /* 0 */ V(5, 0, 1), /* 64 */ - /* 1 */ V(3, 3, 1) -}; -# endif - -static -union huffpair const hufftab9[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 3), - /* 0010 */ PTR(40, 2), - /* 0011 */ PTR(44, 2), - /* 0100 */ PTR(48, 1), - /* 0101 */ V(1, 2, 4), - /* 0110 */ V(2, 1, 4), - /* 0111 */ V(2, 0, 4), - /* 1000 */ V(1, 1, 3), - /* 1001 */ V(1, 1, 3), - /* 1010 */ V(0, 1, 3), - /* 1011 */ V(0, 1, 3), - /* 1100 */ V(1, 0, 3), - /* 1101 */ V(1, 0, 3), - /* 1110 */ V(0, 0, 3), - /* 1111 */ V(0, 0, 3), - - /* 0000 ... */ - /* 0000 */ PTR(50, 1), /* 16 */ - /* 0001 */ V(3, 5, 4), - /* 0010 */ V(5, 3, 4), - /* 0011 */ PTR(52, 1), - /* 0100 */ V(4, 4, 4), - /* 0101 */ V(2, 5, 4), - /* 0110 */ V(5, 2, 4), - /* 0111 */ V(1, 5, 4), - /* 1000 */ V(5, 1, 3), - /* 1001 */ V(5, 1, 3), - /* 1010 */ V(3, 4, 3), - /* 1011 */ V(3, 4, 3), - /* 1100 */ V(4, 3, 3), - /* 1101 */ V(4, 3, 3), - /* 1110 */ V(5, 0, 4), - /* 1111 */ V(0, 4, 4), - - /* 0001 ... */ - /* 000 */ V(2, 4, 3), /* 32 */ - /* 001 */ V(4, 2, 3), - /* 010 */ V(3, 3, 3), - /* 011 */ V(4, 0, 3), - /* 100 */ V(1, 4, 2), - /* 101 */ V(1, 4, 2), - /* 110 */ V(4, 1, 2), - /* 111 */ V(4, 1, 2), - - /* 0010 ... */ - /* 00 */ V(2, 3, 2), /* 40 */ - /* 01 */ V(3, 2, 2), - /* 10 */ V(1, 3, 1), - /* 11 */ V(1, 3, 1), - - /* 0011 ... */ - /* 00 */ V(3, 1, 1), /* 44 */ - /* 01 */ V(3, 1, 1), - /* 10 */ V(0, 3, 2), - /* 11 */ V(3, 0, 2), - - /* 0100 ... */ - /* 0 */ V(2, 2, 1), /* 48 */ - /* 1 */ V(0, 2, 1), - - /* 0000 0000 ... */ - /* 0 */ V(5, 5, 1), /* 50 */ - /* 1 */ V(4, 5, 1), - - /* 0000 0011 ... */ - /* 0 */ V(5, 4, 1), /* 52 */ - /* 1 */ V(0, 5, 1) -}; - -static -union huffpair const hufftab10[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 2), - /* 0011 */ V(1, 1, 4), - /* 0100 */ V(0, 1, 3), - /* 0101 */ V(0, 1, 3), - /* 0110 */ V(1, 0, 3), - /* 0111 */ V(1, 0, 3), - /* 1000 */ V(0, 0, 1), - /* 1001 */ V(0, 0, 1), - /* 1010 */ V(0, 0, 1), - /* 1011 */ V(0, 0, 1), - /* 1100 */ V(0, 0, 1), - /* 1101 */ V(0, 0, 1), - /* 1110 */ V(0, 0, 1), - /* 1111 */ V(0, 0, 1), - - /* 0000 ... */ - /* 0000 */ PTR(52, 3), /* 16 */ - /* 0001 */ PTR(60, 2), - /* 0010 */ PTR(64, 3), - /* 0011 */ PTR(72, 1), - /* 0100 */ PTR(74, 2), - /* 0101 */ PTR(78, 2), - /* 0110 */ PTR(82, 2), - /* 0111 */ V(1, 7, 4), - /* 1000 */ V(7, 1, 4), - /* 1001 */ PTR(86, 1), - /* 1010 */ PTR(88, 2), - /* 1011 */ PTR(92, 2), - /* 1100 */ V(1, 6, 4), - /* 1101 */ V(6, 1, 4), - /* 1110 */ V(6, 0, 4), - /* 1111 */ PTR(96, 1), - - /* 0001 ... */ - /* 0000 */ PTR(98, 1), /* 32 */ - /* 0001 */ PTR(100, 1), - /* 0010 */ V(1, 4, 4), - /* 0011 */ V(4, 1, 4), - /* 0100 */ V(4, 0, 4), - /* 0101 */ V(2, 3, 4), - /* 0110 */ V(3, 2, 4), - /* 0111 */ V(0, 3, 4), - /* 1000 */ V(1, 3, 3), - /* 1001 */ V(1, 3, 3), - /* 1010 */ V(3, 1, 3), - /* 1011 */ V(3, 1, 3), - /* 1100 */ V(3, 0, 3), - /* 1101 */ V(3, 0, 3), - /* 1110 */ V(2, 2, 3), - /* 1111 */ V(2, 2, 3), - - /* 0010 ... */ - /* 00 */ V(1, 2, 2), /* 48 */ - /* 01 */ V(2, 1, 2), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 000 */ V(7, 7, 3), /* 52 */ - /* 001 */ V(6, 7, 3), - /* 010 */ V(7, 6, 3), - /* 011 */ V(5, 7, 3), - /* 100 */ V(7, 5, 3), - /* 101 */ V(6, 6, 3), - /* 110 */ V(4, 7, 2), - /* 111 */ V(4, 7, 2), - - /* 0000 0001 ... */ - /* 00 */ V(7, 4, 2), /* 60 */ - /* 01 */ V(5, 6, 2), - /* 10 */ V(6, 5, 2), - /* 11 */ V(3, 7, 2), - - /* 0000 0010 ... */ - /* 000 */ V(7, 3, 2), /* 64 */ - /* 001 */ V(7, 3, 2), - /* 010 */ V(4, 6, 2), - /* 011 */ V(4, 6, 2), - /* 100 */ V(5, 5, 3), - /* 101 */ V(5, 4, 3), - /* 110 */ V(6, 3, 2), - /* 111 */ V(6, 3, 2), - - /* 0000 0011 ... */ - /* 0 */ V(2, 7, 1), /* 72 */ - /* 1 */ V(7, 2, 1), - - /* 0000 0100 ... */ - /* 00 */ V(6, 4, 2), /* 74 */ - /* 01 */ V(0, 7, 2), - /* 10 */ V(7, 0, 1), - /* 11 */ V(7, 0, 1), - - /* 0000 0101 ... */ - /* 00 */ V(6, 2, 1), /* 78 */ - /* 01 */ V(6, 2, 1), - /* 10 */ V(4, 5, 2), - /* 11 */ V(3, 5, 2), - - /* 0000 0110 ... */ - /* 00 */ V(0, 6, 1), /* 82 */ - /* 01 */ V(0, 6, 1), - /* 10 */ V(5, 3, 2), - /* 11 */ V(4, 4, 2), - - /* 0000 1001 ... */ - /* 0 */ V(3, 6, 1), /* 86 */ - /* 1 */ V(2, 6, 1), - - /* 0000 1010 ... */ - /* 00 */ V(2, 5, 2), /* 88 */ - /* 01 */ V(5, 2, 2), - /* 10 */ V(1, 5, 1), - /* 11 */ V(1, 5, 1), - - /* 0000 1011 ... */ - /* 00 */ V(5, 1, 1), /* 92 */ - /* 01 */ V(5, 1, 1), - /* 10 */ V(3, 4, 2), - /* 11 */ V(4, 3, 2), - - /* 0000 1111 ... */ - /* 0 */ V(0, 5, 1), /* 96 */ - /* 1 */ V(5, 0, 1), - - /* 0001 0000 ... */ - /* 0 */ V(2, 4, 1), /* 98 */ - /* 1 */ V(4, 2, 1), - - /* 0001 0001 ... */ - /* 0 */ V(3, 3, 1), /* 100 */ - /* 1 */ V(0, 4, 1) -}; - -static -union huffpair const hufftab11[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ PTR(64, 3), - /* 0100 */ V(1, 2, 4), - /* 0101 */ PTR(72, 1), - /* 0110 */ V(1, 1, 3), - /* 0111 */ V(1, 1, 3), - /* 1000 */ V(0, 1, 3), - /* 1001 */ V(0, 1, 3), - /* 1010 */ V(1, 0, 3), - /* 1011 */ V(1, 0, 3), - /* 1100 */ V(0, 0, 2), - /* 1101 */ V(0, 0, 2), - /* 1110 */ V(0, 0, 2), - /* 1111 */ V(0, 0, 2), - - /* 0000 ... */ - /* 0000 */ PTR(74, 2), /* 16 */ - /* 0001 */ PTR(78, 3), - /* 0010 */ PTR(86, 2), - /* 0011 */ PTR(90, 1), - /* 0100 */ PTR(92, 2), - /* 0101 */ V(2, 7, 4), - /* 0110 */ V(7, 2, 4), - /* 0111 */ PTR(96, 1), - /* 1000 */ V(7, 1, 3), - /* 1001 */ V(7, 1, 3), - /* 1010 */ V(1, 7, 4), - /* 1011 */ V(7, 0, 4), - /* 1100 */ V(3, 6, 4), - /* 1101 */ V(6, 3, 4), - /* 1110 */ V(6, 0, 4), - /* 1111 */ PTR(98, 1), - - /* 0001 ... */ - /* 0000 */ PTR(100, 1), /* 32 */ - /* 0001 */ V(1, 5, 4), - /* 0010 */ V(6, 2, 3), - /* 0011 */ V(6, 2, 3), - /* 0100 */ V(2, 6, 4), - /* 0101 */ V(0, 6, 4), - /* 0110 */ V(1, 6, 3), - /* 0111 */ V(1, 6, 3), - /* 1000 */ V(6, 1, 3), - /* 1001 */ V(6, 1, 3), - /* 1010 */ V(5, 1, 4), - /* 1011 */ V(3, 4, 4), - /* 1100 */ V(5, 0, 4), - /* 1101 */ PTR(102, 1), - /* 1110 */ V(2, 4, 4), - /* 1111 */ V(4, 2, 4), - - /* 0010 ... */ - /* 0000 */ V(1, 4, 4), /* 48 */ - /* 0001 */ V(4, 1, 4), - /* 0010 */ V(0, 4, 4), - /* 0011 */ V(4, 0, 4), - /* 0100 */ V(2, 3, 3), - /* 0101 */ V(2, 3, 3), - /* 0110 */ V(3, 2, 3), - /* 0111 */ V(3, 2, 3), - /* 1000 */ V(1, 3, 2), - /* 1001 */ V(1, 3, 2), - /* 1010 */ V(1, 3, 2), - /* 1011 */ V(1, 3, 2), - /* 1100 */ V(3, 1, 2), - /* 1101 */ V(3, 1, 2), - /* 1110 */ V(3, 1, 2), - /* 1111 */ V(3, 1, 2), - - /* 0011 ... */ - /* 000 */ V(0, 3, 3), /* 64 */ - /* 001 */ V(3, 0, 3), - /* 010 */ V(2, 2, 2), - /* 011 */ V(2, 2, 2), - /* 100 */ V(2, 1, 1), - /* 101 */ V(2, 1, 1), - /* 110 */ V(2, 1, 1), - /* 111 */ V(2, 1, 1), - - /* 0101 ... */ - /* 0 */ V(0, 2, 1), /* 72 */ - /* 1 */ V(2, 0, 1), - - /* 0000 0000 ... */ - /* 00 */ V(7, 7, 2), /* 74 */ - /* 01 */ V(6, 7, 2), - /* 10 */ V(7, 6, 2), - /* 11 */ V(7, 5, 2), - - /* 0000 0001 ... */ - /* 000 */ V(6, 6, 2), /* 78 */ - /* 001 */ V(6, 6, 2), - /* 010 */ V(4, 7, 2), - /* 011 */ V(4, 7, 2), - /* 100 */ V(7, 4, 2), - /* 101 */ V(7, 4, 2), - /* 110 */ V(5, 7, 3), - /* 111 */ V(5, 5, 3), - - /* 0000 0010 ... */ - /* 00 */ V(5, 6, 2), /* 86 */ - /* 01 */ V(6, 5, 2), - /* 10 */ V(3, 7, 1), - /* 11 */ V(3, 7, 1), - - /* 0000 0011 ... */ - /* 0 */ V(7, 3, 1), /* 90 */ - /* 1 */ V(4, 6, 1), - - /* 0000 0100 ... */ - /* 00 */ V(4, 5, 2), /* 92 */ - /* 01 */ V(5, 4, 2), - /* 10 */ V(3, 5, 2), - /* 11 */ V(5, 3, 2), - - /* 0000 0111 ... */ - /* 0 */ V(6, 4, 1), /* 96 */ - /* 1 */ V(0, 7, 1), - - /* 0000 1111 ... */ - /* 0 */ V(4, 4, 1), /* 98 */ - /* 1 */ V(2, 5, 1), - - /* 0001 0000 ... */ - /* 0 */ V(5, 2, 1), /* 100 */ - /* 1 */ V(0, 5, 1), - - /* 0001 1101 ... */ - /* 0 */ V(4, 3, 1), /* 102 */ - /* 1 */ V(3, 3, 1) -}; - -static -union huffpair const hufftab12[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ PTR(64, 2), - /* 0100 */ PTR(68, 3), - /* 0101 */ PTR(76, 1), - /* 0110 */ V(1, 2, 4), - /* 0111 */ V(2, 1, 4), - /* 1000 */ PTR(78, 1), - /* 1001 */ V(0, 0, 4), - /* 1010 */ V(1, 1, 3), - /* 1011 */ V(1, 1, 3), - /* 1100 */ V(0, 1, 3), - /* 1101 */ V(0, 1, 3), - /* 1110 */ V(1, 0, 3), - /* 1111 */ V(1, 0, 3), - - /* 0000 ... */ - /* 0000 */ PTR(80, 2), /* 16 */ - /* 0001 */ PTR(84, 1), - /* 0010 */ PTR(86, 1), - /* 0011 */ PTR(88, 1), - /* 0100 */ V(5, 6, 4), - /* 0101 */ V(3, 7, 4), - /* 0110 */ PTR(90, 1), - /* 0111 */ V(2, 7, 4), - /* 1000 */ V(7, 2, 4), - /* 1001 */ V(4, 6, 4), - /* 1010 */ V(6, 4, 4), - /* 1011 */ V(1, 7, 4), - /* 1100 */ V(7, 1, 4), - /* 1101 */ PTR(92, 1), - /* 1110 */ V(3, 6, 4), - /* 1111 */ V(6, 3, 4), - - /* 0001 ... */ - /* 0000 */ V(4, 5, 4), /* 32 */ - /* 0001 */ V(5, 4, 4), - /* 0010 */ V(4, 4, 4), - /* 0011 */ PTR(94, 1), - /* 0100 */ V(2, 6, 3), - /* 0101 */ V(2, 6, 3), - /* 0110 */ V(6, 2, 3), - /* 0111 */ V(6, 2, 3), - /* 1000 */ V(6, 1, 3), - /* 1001 */ V(6, 1, 3), - /* 1010 */ V(1, 6, 4), - /* 1011 */ V(6, 0, 4), - /* 1100 */ V(3, 5, 4), - /* 1101 */ V(5, 3, 4), - /* 1110 */ V(2, 5, 4), - /* 1111 */ V(5, 2, 4), - - /* 0010 ... */ - /* 0000 */ V(1, 5, 3), /* 48 */ - /* 0001 */ V(1, 5, 3), - /* 0010 */ V(5, 1, 3), - /* 0011 */ V(5, 1, 3), - /* 0100 */ V(3, 4, 3), - /* 0101 */ V(3, 4, 3), - /* 0110 */ V(4, 3, 3), - /* 0111 */ V(4, 3, 3), - /* 1000 */ V(5, 0, 4), - /* 1001 */ V(0, 4, 4), - /* 1010 */ V(2, 4, 3), - /* 1011 */ V(2, 4, 3), - /* 1100 */ V(4, 2, 3), - /* 1101 */ V(4, 2, 3), - /* 1110 */ V(1, 4, 3), - /* 1111 */ V(1, 4, 3), - - /* 0011 ... */ - /* 00 */ V(3, 3, 2), /* 64 */ - /* 01 */ V(4, 1, 2), - /* 10 */ V(2, 3, 2), - /* 11 */ V(3, 2, 2), - - /* 0100 ... */ - /* 000 */ V(4, 0, 3), /* 68 */ - /* 001 */ V(0, 3, 3), - /* 010 */ V(3, 0, 2), - /* 011 */ V(3, 0, 2), - /* 100 */ V(1, 3, 1), - /* 101 */ V(1, 3, 1), - /* 110 */ V(1, 3, 1), - /* 111 */ V(1, 3, 1), - - /* 0101 ... */ - /* 0 */ V(3, 1, 1), /* 76 */ - /* 1 */ V(2, 2, 1), - - /* 1000 ... */ - /* 0 */ V(0, 2, 1), /* 78 */ - /* 1 */ V(2, 0, 1), - - /* 0000 0000 ... */ - /* 00 */ V(7, 7, 2), /* 80 */ - /* 01 */ V(6, 7, 2), - /* 10 */ V(7, 6, 1), - /* 11 */ V(7, 6, 1), - - /* 0000 0001 ... */ - /* 0 */ V(5, 7, 1), /* 84 */ - /* 1 */ V(7, 5, 1), - - /* 0000 0010 ... */ - /* 0 */ V(6, 6, 1), /* 86 */ - /* 1 */ V(4, 7, 1), - - /* 0000 0011 ... */ - /* 0 */ V(7, 4, 1), /* 88 */ - /* 1 */ V(6, 5, 1), - - /* 0000 0110 ... */ - /* 0 */ V(7, 3, 1), /* 90 */ - /* 1 */ V(5, 5, 1), - - /* 0000 1101 ... */ - /* 0 */ V(0, 7, 1), /* 92 */ - /* 1 */ V(7, 0, 1), - - /* 0001 0011 ... */ - /* 0 */ V(0, 6, 1), /* 94 */ - /* 1 */ V(0, 5, 1) -}; - -static -union huffpair const hufftab13[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ PTR(64, 2), - /* 0100 */ V(1, 1, 4), - /* 0101 */ V(0, 1, 4), - /* 0110 */ V(1, 0, 3), - /* 0111 */ V(1, 0, 3), - /* 1000 */ V(0, 0, 1), - /* 1001 */ V(0, 0, 1), - /* 1010 */ V(0, 0, 1), - /* 1011 */ V(0, 0, 1), - /* 1100 */ V(0, 0, 1), - /* 1101 */ V(0, 0, 1), - /* 1110 */ V(0, 0, 1), - /* 1111 */ V(0, 0, 1), - - /* 0000 ... */ - /* 0000 */ PTR(68, 4), /* 16 */ - /* 0001 */ PTR(84, 4), - /* 0010 */ PTR(100, 4), - /* 0011 */ PTR(116, 4), - /* 0100 */ PTR(132, 4), - /* 0101 */ PTR(148, 4), - /* 0110 */ PTR(164, 3), - /* 0111 */ PTR(172, 3), - /* 1000 */ PTR(180, 3), - /* 1001 */ PTR(188, 3), - /* 1010 */ PTR(196, 3), - /* 1011 */ PTR(204, 3), - /* 1100 */ PTR(212, 1), - /* 1101 */ PTR(214, 2), - /* 1110 */ PTR(218, 3), - /* 1111 */ PTR(226, 1), - - /* 0001 ... */ - /* 0000 */ PTR(228, 2), /* 32 */ - /* 0001 */ PTR(232, 2), - /* 0010 */ PTR(236, 2), - /* 0011 */ PTR(240, 2), - /* 0100 */ V(8, 1, 4), - /* 0101 */ PTR(244, 1), - /* 0110 */ PTR(246, 1), - /* 0111 */ PTR(248, 1), - /* 1000 */ PTR(250, 2), - /* 1001 */ PTR(254, 1), - /* 1010 */ V(1, 5, 4), - /* 1011 */ V(5, 1, 4), - /* 1100 */ PTR(256, 1), - /* 1101 */ PTR(258, 1), - /* 1110 */ PTR(260, 1), - /* 1111 */ V(1, 4, 4), - - /* 0010 ... */ - /* 0000 */ V(4, 1, 3), /* 48 */ - /* 0001 */ V(4, 1, 3), - /* 0010 */ V(0, 4, 4), - /* 0011 */ V(4, 0, 4), - /* 0100 */ V(2, 3, 4), - /* 0101 */ V(3, 2, 4), - /* 0110 */ V(1, 3, 3), - /* 0111 */ V(1, 3, 3), - /* 1000 */ V(3, 1, 3), - /* 1001 */ V(3, 1, 3), - /* 1010 */ V(0, 3, 3), - /* 1011 */ V(0, 3, 3), - /* 1100 */ V(3, 0, 3), - /* 1101 */ V(3, 0, 3), - /* 1110 */ V(2, 2, 3), - /* 1111 */ V(2, 2, 3), - - /* 0011 ... */ - /* 00 */ V(1, 2, 2), /* 64 */ - /* 01 */ V(2, 1, 2), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 0000 */ PTR(262, 4), /* 68 */ - /* 0001 */ PTR(278, 4), - /* 0010 */ PTR(294, 4), - /* 0011 */ PTR(310, 3), - /* 0100 */ PTR(318, 2), - /* 0101 */ PTR(322, 2), - /* 0110 */ PTR(326, 3), - /* 0111 */ PTR(334, 2), - /* 1000 */ PTR(338, 1), - /* 1001 */ PTR(340, 2), - /* 1010 */ PTR(344, 2), - /* 1011 */ PTR(348, 2), - /* 1100 */ PTR(352, 2), - /* 1101 */ PTR(356, 2), - /* 1110 */ V(1, 15, 4), - /* 1111 */ V(15, 1, 4), - - /* 0000 0001 ... */ - /* 0000 */ V(15, 0, 4), /* 84 */ - /* 0001 */ PTR(360, 1), - /* 0010 */ PTR(362, 1), - /* 0011 */ PTR(364, 1), - /* 0100 */ V(14, 2, 4), - /* 0101 */ PTR(366, 1), - /* 0110 */ V(1, 14, 4), - /* 0111 */ V(14, 1, 4), - /* 1000 */ PTR(368, 1), - /* 1001 */ PTR(370, 1), - /* 1010 */ PTR(372, 1), - /* 1011 */ PTR(374, 1), - /* 1100 */ PTR(376, 1), - /* 1101 */ PTR(378, 1), - /* 1110 */ V(12, 6, 4), - /* 1111 */ V(3, 13, 4), - - /* 0000 0010 ... */ - /* 0000 */ PTR(380, 1), /* 100 */ - /* 0001 */ V(2, 13, 4), - /* 0010 */ V(13, 2, 4), - /* 0011 */ V(1, 13, 4), - /* 0100 */ V(11, 7, 4), - /* 0101 */ PTR(382, 1), - /* 0110 */ PTR(384, 1), - /* 0111 */ V(12, 3, 4), - /* 1000 */ PTR(386, 1), - /* 1001 */ V(4, 11, 4), - /* 1010 */ V(13, 1, 3), - /* 1011 */ V(13, 1, 3), - /* 1100 */ V(0, 13, 4), - /* 1101 */ V(13, 0, 4), - /* 1110 */ V(8, 10, 4), - /* 1111 */ V(10, 8, 4), - - /* 0000 0011 ... */ - /* 0000 */ V(4, 12, 4), /* 116 */ - /* 0001 */ V(12, 4, 4), - /* 0010 */ V(6, 11, 4), - /* 0011 */ V(11, 6, 4), - /* 0100 */ V(3, 12, 3), - /* 0101 */ V(3, 12, 3), - /* 0110 */ V(2, 12, 3), - /* 0111 */ V(2, 12, 3), - /* 1000 */ V(12, 2, 3), - /* 1001 */ V(12, 2, 3), - /* 1010 */ V(5, 11, 3), - /* 1011 */ V(5, 11, 3), - /* 1100 */ V(11, 5, 4), - /* 1101 */ V(8, 9, 4), - /* 1110 */ V(1, 12, 3), - /* 1111 */ V(1, 12, 3), - - /* 0000 0100 ... */ - /* 0000 */ V(12, 1, 3), /* 132 */ - /* 0001 */ V(12, 1, 3), - /* 0010 */ V(9, 8, 4), - /* 0011 */ V(0, 12, 4), - /* 0100 */ V(12, 0, 3), - /* 0101 */ V(12, 0, 3), - /* 0110 */ V(11, 4, 4), - /* 0111 */ V(6, 10, 4), - /* 1000 */ V(10, 6, 4), - /* 1001 */ V(7, 9, 4), - /* 1010 */ V(3, 11, 3), - /* 1011 */ V(3, 11, 3), - /* 1100 */ V(11, 3, 3), - /* 1101 */ V(11, 3, 3), - /* 1110 */ V(8, 8, 4), - /* 1111 */ V(5, 10, 4), - - /* 0000 0101 ... */ - /* 0000 */ V(2, 11, 3), /* 148 */ - /* 0001 */ V(2, 11, 3), - /* 0010 */ V(10, 5, 4), - /* 0011 */ V(6, 9, 4), - /* 0100 */ V(10, 4, 3), - /* 0101 */ V(10, 4, 3), - /* 0110 */ V(7, 8, 4), - /* 0111 */ V(8, 7, 4), - /* 1000 */ V(9, 4, 3), - /* 1001 */ V(9, 4, 3), - /* 1010 */ V(7, 7, 4), - /* 1011 */ V(7, 6, 4), - /* 1100 */ V(11, 2, 2), - /* 1101 */ V(11, 2, 2), - /* 1110 */ V(11, 2, 2), - /* 1111 */ V(11, 2, 2), - - /* 0000 0110 ... */ - /* 000 */ V(1, 11, 2), /* 164 */ - /* 001 */ V(1, 11, 2), - /* 010 */ V(11, 1, 2), - /* 011 */ V(11, 1, 2), - /* 100 */ V(0, 11, 3), - /* 101 */ V(11, 0, 3), - /* 110 */ V(9, 6, 3), - /* 111 */ V(4, 10, 3), - - /* 0000 0111 ... */ - /* 000 */ V(3, 10, 3), /* 172 */ - /* 001 */ V(10, 3, 3), - /* 010 */ V(5, 9, 3), - /* 011 */ V(9, 5, 3), - /* 100 */ V(2, 10, 2), - /* 101 */ V(2, 10, 2), - /* 110 */ V(10, 2, 2), - /* 111 */ V(10, 2, 2), - - /* 0000 1000 ... */ - /* 000 */ V(1, 10, 2), /* 180 */ - /* 001 */ V(1, 10, 2), - /* 010 */ V(10, 1, 2), - /* 011 */ V(10, 1, 2), - /* 100 */ V(0, 10, 3), - /* 101 */ V(6, 8, 3), - /* 110 */ V(10, 0, 2), - /* 111 */ V(10, 0, 2), - - /* 0000 1001 ... */ - /* 000 */ V(8, 6, 3), /* 188 */ - /* 001 */ V(4, 9, 3), - /* 010 */ V(9, 3, 2), - /* 011 */ V(9, 3, 2), - /* 100 */ V(3, 9, 3), - /* 101 */ V(5, 8, 3), - /* 110 */ V(8, 5, 3), - /* 111 */ V(6, 7, 3), - - /* 0000 1010 ... */ - /* 000 */ V(2, 9, 2), /* 196 */ - /* 001 */ V(2, 9, 2), - /* 010 */ V(9, 2, 2), - /* 011 */ V(9, 2, 2), - /* 100 */ V(5, 7, 3), - /* 101 */ V(7, 5, 3), - /* 110 */ V(3, 8, 2), - /* 111 */ V(3, 8, 2), - - /* 0000 1011 ... */ - /* 000 */ V(8, 3, 2), /* 204 */ - /* 001 */ V(8, 3, 2), - /* 010 */ V(6, 6, 3), - /* 011 */ V(4, 7, 3), - /* 100 */ V(7, 4, 3), - /* 101 */ V(5, 6, 3), - /* 110 */ V(6, 5, 3), - /* 111 */ V(7, 3, 3), - - /* 0000 1100 ... */ - /* 0 */ V(1, 9, 1), /* 212 */ - /* 1 */ V(9, 1, 1), - - /* 0000 1101 ... */ - /* 00 */ V(0, 9, 2), /* 214 */ - /* 01 */ V(9, 0, 2), - /* 10 */ V(4, 8, 2), - /* 11 */ V(8, 4, 2), - - /* 0000 1110 ... */ - /* 000 */ V(7, 2, 2), /* 218 */ - /* 001 */ V(7, 2, 2), - /* 010 */ V(4, 6, 3), - /* 011 */ V(6, 4, 3), - /* 100 */ V(2, 8, 1), - /* 101 */ V(2, 8, 1), - /* 110 */ V(2, 8, 1), - /* 111 */ V(2, 8, 1), - - /* 0000 1111 ... */ - /* 0 */ V(8, 2, 1), /* 226 */ - /* 1 */ V(1, 8, 1), - - /* 0001 0000 ... */ - /* 00 */ V(3, 7, 2), /* 228 */ - /* 01 */ V(2, 7, 2), - /* 10 */ V(1, 7, 1), - /* 11 */ V(1, 7, 1), - - /* 0001 0001 ... */ - /* 00 */ V(7, 1, 1), /* 232 */ - /* 01 */ V(7, 1, 1), - /* 10 */ V(5, 5, 2), - /* 11 */ V(0, 7, 2), - - /* 0001 0010 ... */ - /* 00 */ V(7, 0, 2), /* 236 */ - /* 01 */ V(3, 6, 2), - /* 10 */ V(6, 3, 2), - /* 11 */ V(4, 5, 2), - - /* 0001 0011 ... */ - /* 00 */ V(5, 4, 2), /* 240 */ - /* 01 */ V(2, 6, 2), - /* 10 */ V(6, 2, 2), - /* 11 */ V(3, 5, 2), - - /* 0001 0101 ... */ - /* 0 */ V(0, 8, 1), /* 244 */ - /* 1 */ V(8, 0, 1), - - /* 0001 0110 ... */ - /* 0 */ V(1, 6, 1), /* 246 */ - /* 1 */ V(6, 1, 1), - - /* 0001 0111 ... */ - /* 0 */ V(0, 6, 1), /* 248 */ - /* 1 */ V(6, 0, 1), - - /* 0001 1000 ... */ - /* 00 */ V(5, 3, 2), /* 250 */ - /* 01 */ V(4, 4, 2), - /* 10 */ V(2, 5, 1), - /* 11 */ V(2, 5, 1), - - /* 0001 1001 ... */ - /* 0 */ V(5, 2, 1), /* 254 */ - /* 1 */ V(0, 5, 1), - - /* 0001 1100 ... */ - /* 0 */ V(3, 4, 1), /* 256 */ - /* 1 */ V(4, 3, 1), - - /* 0001 1101 ... */ - /* 0 */ V(5, 0, 1), /* 258 */ - /* 1 */ V(2, 4, 1), - - /* 0001 1110 ... */ - /* 0 */ V(4, 2, 1), /* 260 */ - /* 1 */ V(3, 3, 1), - - /* 0000 0000 0000 ... */ - /* 0000 */ PTR(388, 3), /* 262 */ - /* 0001 */ V(15, 15, 4), - /* 0010 */ V(14, 15, 4), - /* 0011 */ V(13, 15, 4), - /* 0100 */ V(14, 14, 4), - /* 0101 */ V(12, 15, 4), - /* 0110 */ V(13, 14, 4), - /* 0111 */ V(11, 15, 4), - /* 1000 */ V(15, 11, 4), - /* 1001 */ V(12, 14, 4), - /* 1010 */ V(13, 12, 4), - /* 1011 */ PTR(396, 1), - /* 1100 */ V(14, 12, 3), - /* 1101 */ V(14, 12, 3), - /* 1110 */ V(13, 13, 3), - /* 1111 */ V(13, 13, 3), - - /* 0000 0000 0001 ... */ - /* 0000 */ V(15, 10, 4), /* 278 */ - /* 0001 */ V(12, 13, 4), - /* 0010 */ V(11, 14, 3), - /* 0011 */ V(11, 14, 3), - /* 0100 */ V(14, 11, 3), - /* 0101 */ V(14, 11, 3), - /* 0110 */ V(9, 15, 3), - /* 0111 */ V(9, 15, 3), - /* 1000 */ V(15, 9, 3), - /* 1001 */ V(15, 9, 3), - /* 1010 */ V(14, 10, 3), - /* 1011 */ V(14, 10, 3), - /* 1100 */ V(11, 13, 3), - /* 1101 */ V(11, 13, 3), - /* 1110 */ V(13, 11, 3), - /* 1111 */ V(13, 11, 3), - - /* 0000 0000 0010 ... */ - /* 0000 */ V(8, 15, 3), /* 294 */ - /* 0001 */ V(8, 15, 3), - /* 0010 */ V(15, 8, 3), - /* 0011 */ V(15, 8, 3), - /* 0100 */ V(12, 12, 3), - /* 0101 */ V(12, 12, 3), - /* 0110 */ V(10, 14, 4), - /* 0111 */ V(9, 14, 4), - /* 1000 */ V(8, 14, 3), - /* 1001 */ V(8, 14, 3), - /* 1010 */ V(7, 15, 4), - /* 1011 */ V(7, 14, 4), - /* 1100 */ V(15, 7, 2), - /* 1101 */ V(15, 7, 2), - /* 1110 */ V(15, 7, 2), - /* 1111 */ V(15, 7, 2), - - /* 0000 0000 0011 ... */ - /* 000 */ V(13, 10, 2), /* 310 */ - /* 001 */ V(13, 10, 2), - /* 010 */ V(10, 13, 3), - /* 011 */ V(11, 12, 3), - /* 100 */ V(12, 11, 3), - /* 101 */ V(15, 6, 3), - /* 110 */ V(6, 15, 2), - /* 111 */ V(6, 15, 2), - - /* 0000 0000 0100 ... */ - /* 00 */ V(14, 8, 2), /* 318 */ - /* 01 */ V(5, 15, 2), - /* 10 */ V(9, 13, 2), - /* 11 */ V(13, 9, 2), - - /* 0000 0000 0101 ... */ - /* 00 */ V(15, 5, 2), /* 322 */ - /* 01 */ V(14, 7, 2), - /* 10 */ V(10, 12, 2), - /* 11 */ V(11, 11, 2), - - /* 0000 0000 0110 ... */ - /* 000 */ V(4, 15, 2), /* 326 */ - /* 001 */ V(4, 15, 2), - /* 010 */ V(15, 4, 2), - /* 011 */ V(15, 4, 2), - /* 100 */ V(12, 10, 3), - /* 101 */ V(14, 6, 3), - /* 110 */ V(15, 3, 2), - /* 111 */ V(15, 3, 2), - - /* 0000 0000 0111 ... */ - /* 00 */ V(3, 15, 1), /* 334 */ - /* 01 */ V(3, 15, 1), - /* 10 */ V(8, 13, 2), - /* 11 */ V(13, 8, 2), - - /* 0000 0000 1000 ... */ - /* 0 */ V(2, 15, 1), /* 338 */ - /* 1 */ V(15, 2, 1), - - /* 0000 0000 1001 ... */ - /* 00 */ V(6, 14, 2), /* 340 */ - /* 01 */ V(9, 12, 2), - /* 10 */ V(0, 15, 1), - /* 11 */ V(0, 15, 1), - - /* 0000 0000 1010 ... */ - /* 00 */ V(12, 9, 2), /* 344 */ - /* 01 */ V(5, 14, 2), - /* 10 */ V(10, 11, 1), - /* 11 */ V(10, 11, 1), - - /* 0000 0000 1011 ... */ - /* 00 */ V(7, 13, 2), /* 348 */ - /* 01 */ V(13, 7, 2), - /* 10 */ V(4, 14, 1), - /* 11 */ V(4, 14, 1), - - /* 0000 0000 1100 ... */ - /* 00 */ V(12, 8, 2), /* 352 */ - /* 01 */ V(13, 6, 2), - /* 10 */ V(3, 14, 1), - /* 11 */ V(3, 14, 1), - - /* 0000 0000 1101 ... */ - /* 00 */ V(11, 9, 1), /* 356 */ - /* 01 */ V(11, 9, 1), - /* 10 */ V(9, 11, 2), - /* 11 */ V(10, 10, 2), - - /* 0000 0001 0001 ... */ - /* 0 */ V(11, 10, 1), /* 360 */ - /* 1 */ V(14, 5, 1), - - /* 0000 0001 0010 ... */ - /* 0 */ V(14, 4, 1), /* 362 */ - /* 1 */ V(8, 12, 1), - - /* 0000 0001 0011 ... */ - /* 0 */ V(6, 13, 1), /* 364 */ - /* 1 */ V(14, 3, 1), - - /* 0000 0001 0101 ... */ - /* 0 */ V(2, 14, 1), /* 366 */ - /* 1 */ V(0, 14, 1), - - /* 0000 0001 1000 ... */ - /* 0 */ V(14, 0, 1), /* 368 */ - /* 1 */ V(5, 13, 1), - - /* 0000 0001 1001 ... */ - /* 0 */ V(13, 5, 1), /* 370 */ - /* 1 */ V(7, 12, 1), - - /* 0000 0001 1010 ... */ - /* 0 */ V(12, 7, 1), /* 372 */ - /* 1 */ V(4, 13, 1), - - /* 0000 0001 1011 ... */ - /* 0 */ V(8, 11, 1), /* 374 */ - /* 1 */ V(11, 8, 1), - - /* 0000 0001 1100 ... */ - /* 0 */ V(13, 4, 1), /* 376 */ - /* 1 */ V(9, 10, 1), - - /* 0000 0001 1101 ... */ - /* 0 */ V(10, 9, 1), /* 378 */ - /* 1 */ V(6, 12, 1), - - /* 0000 0010 0000 ... */ - /* 0 */ V(13, 3, 1), /* 380 */ - /* 1 */ V(7, 11, 1), - - /* 0000 0010 0101 ... */ - /* 0 */ V(5, 12, 1), /* 382 */ - /* 1 */ V(12, 5, 1), - - /* 0000 0010 0110 ... */ - /* 0 */ V(9, 9, 1), /* 384 */ - /* 1 */ V(7, 10, 1), - - /* 0000 0010 1000 ... */ - /* 0 */ V(10, 7, 1), /* 386 */ - /* 1 */ V(9, 7, 1), - - /* 0000 0000 0000 0000 ... */ - /* 000 */ V(15, 14, 3), /* 388 */ - /* 001 */ V(15, 12, 3), - /* 010 */ V(15, 13, 2), - /* 011 */ V(15, 13, 2), - /* 100 */ V(14, 13, 1), - /* 101 */ V(14, 13, 1), - /* 110 */ V(14, 13, 1), - /* 111 */ V(14, 13, 1), - - /* 0000 0000 0000 1011 ... */ - /* 0 */ V(10, 15, 1), /* 396 */ - /* 1 */ V(14, 9, 1) -}; - -static -union huffpair const hufftab15[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ PTR(64, 4), - /* 0100 */ PTR(80, 4), - /* 0101 */ PTR(96, 3), - /* 0110 */ PTR(104, 3), - /* 0111 */ PTR(112, 2), - /* 1000 */ PTR(116, 1), - /* 1001 */ PTR(118, 1), - /* 1010 */ V(1, 1, 3), - /* 1011 */ V(1, 1, 3), - /* 1100 */ V(0, 1, 4), - /* 1101 */ V(1, 0, 4), - /* 1110 */ V(0, 0, 3), - /* 1111 */ V(0, 0, 3), - - /* 0000 ... */ - /* 0000 */ PTR(120, 4), /* 16 */ - /* 0001 */ PTR(136, 4), - /* 0010 */ PTR(152, 4), - /* 0011 */ PTR(168, 4), - /* 0100 */ PTR(184, 4), - /* 0101 */ PTR(200, 3), - /* 0110 */ PTR(208, 3), - /* 0111 */ PTR(216, 4), - /* 1000 */ PTR(232, 3), - /* 1001 */ PTR(240, 3), - /* 1010 */ PTR(248, 3), - /* 1011 */ PTR(256, 3), - /* 1100 */ PTR(264, 2), - /* 1101 */ PTR(268, 3), - /* 1110 */ PTR(276, 3), - /* 1111 */ PTR(284, 2), - - /* 0001 ... */ - /* 0000 */ PTR(288, 2), /* 32 */ - /* 0001 */ PTR(292, 2), - /* 0010 */ PTR(296, 2), - /* 0011 */ PTR(300, 2), - /* 0100 */ PTR(304, 2), - /* 0101 */ PTR(308, 2), - /* 0110 */ PTR(312, 2), - /* 0111 */ PTR(316, 2), - /* 1000 */ PTR(320, 1), - /* 1001 */ PTR(322, 1), - /* 1010 */ PTR(324, 1), - /* 1011 */ PTR(326, 2), - /* 1100 */ PTR(330, 1), - /* 1101 */ PTR(332, 1), - /* 1110 */ PTR(334, 2), - /* 1111 */ PTR(338, 1), - - /* 0010 ... */ - /* 0000 */ PTR(340, 1), /* 48 */ - /* 0001 */ PTR(342, 1), - /* 0010 */ V(9, 1, 4), - /* 0011 */ PTR(344, 1), - /* 0100 */ PTR(346, 1), - /* 0101 */ PTR(348, 1), - /* 0110 */ PTR(350, 1), - /* 0111 */ PTR(352, 1), - /* 1000 */ V(2, 8, 4), - /* 1001 */ V(8, 2, 4), - /* 1010 */ V(1, 8, 4), - /* 1011 */ V(8, 1, 4), - /* 1100 */ PTR(354, 1), - /* 1101 */ PTR(356, 1), - /* 1110 */ PTR(358, 1), - /* 1111 */ PTR(360, 1), - - /* 0011 ... */ - /* 0000 */ V(2, 7, 4), /* 64 */ - /* 0001 */ V(7, 2, 4), - /* 0010 */ V(6, 4, 4), - /* 0011 */ V(1, 7, 4), - /* 0100 */ V(5, 5, 4), - /* 0101 */ V(7, 1, 4), - /* 0110 */ PTR(362, 1), - /* 0111 */ V(3, 6, 4), - /* 1000 */ V(6, 3, 4), - /* 1001 */ V(4, 5, 4), - /* 1010 */ V(5, 4, 4), - /* 1011 */ V(2, 6, 4), - /* 1100 */ V(6, 2, 4), - /* 1101 */ V(1, 6, 4), - /* 1110 */ PTR(364, 1), - /* 1111 */ V(3, 5, 4), - - /* 0100 ... */ - /* 0000 */ V(6, 1, 3), /* 80 */ - /* 0001 */ V(6, 1, 3), - /* 0010 */ V(5, 3, 4), - /* 0011 */ V(4, 4, 4), - /* 0100 */ V(2, 5, 3), - /* 0101 */ V(2, 5, 3), - /* 0110 */ V(5, 2, 3), - /* 0111 */ V(5, 2, 3), - /* 1000 */ V(1, 5, 3), - /* 1001 */ V(1, 5, 3), - /* 1010 */ V(5, 1, 3), - /* 1011 */ V(5, 1, 3), - /* 1100 */ V(0, 5, 4), - /* 1101 */ V(5, 0, 4), - /* 1110 */ V(3, 4, 3), - /* 1111 */ V(3, 4, 3), - - /* 0101 ... */ - /* 000 */ V(4, 3, 3), /* 96 */ - /* 001 */ V(2, 4, 3), - /* 010 */ V(4, 2, 3), - /* 011 */ V(3, 3, 3), - /* 100 */ V(4, 1, 2), - /* 101 */ V(4, 1, 2), - /* 110 */ V(1, 4, 3), - /* 111 */ V(0, 4, 3), - - /* 0110 ... */ - /* 000 */ V(2, 3, 2), /* 104 */ - /* 001 */ V(2, 3, 2), - /* 010 */ V(3, 2, 2), - /* 011 */ V(3, 2, 2), - /* 100 */ V(4, 0, 3), - /* 101 */ V(0, 3, 3), - /* 110 */ V(1, 3, 2), - /* 111 */ V(1, 3, 2), - - /* 0111 ... */ - /* 00 */ V(3, 1, 2), /* 112 */ - /* 01 */ V(3, 0, 2), - /* 10 */ V(2, 2, 1), - /* 11 */ V(2, 2, 1), - - /* 1000 ... */ - /* 0 */ V(1, 2, 1), /* 116 */ - /* 1 */ V(2, 1, 1), - - /* 1001 ... */ - /* 0 */ V(0, 2, 1), /* 118 */ - /* 1 */ V(2, 0, 1), - - /* 0000 0000 ... */ - /* 0000 */ PTR(366, 1), /* 120 */ - /* 0001 */ PTR(368, 1), - /* 0010 */ V(14, 14, 4), - /* 0011 */ PTR(370, 1), - /* 0100 */ PTR(372, 1), - /* 0101 */ PTR(374, 1), - /* 0110 */ V(15, 11, 4), - /* 0111 */ PTR(376, 1), - /* 1000 */ V(13, 13, 4), - /* 1001 */ V(10, 15, 4), - /* 1010 */ V(15, 10, 4), - /* 1011 */ V(11, 14, 4), - /* 1100 */ V(14, 11, 4), - /* 1101 */ V(12, 13, 4), - /* 1110 */ V(13, 12, 4), - /* 1111 */ V(9, 15, 4), - - /* 0000 0001 ... */ - /* 0000 */ V(15, 9, 4), /* 136 */ - /* 0001 */ V(14, 10, 4), - /* 0010 */ V(11, 13, 4), - /* 0011 */ V(13, 11, 4), - /* 0100 */ V(8, 15, 4), - /* 0101 */ V(15, 8, 4), - /* 0110 */ V(12, 12, 4), - /* 0111 */ V(9, 14, 4), - /* 1000 */ V(14, 9, 4), - /* 1001 */ V(7, 15, 4), - /* 1010 */ V(15, 7, 4), - /* 1011 */ V(10, 13, 4), - /* 1100 */ V(13, 10, 4), - /* 1101 */ V(11, 12, 4), - /* 1110 */ V(6, 15, 4), - /* 1111 */ PTR(378, 1), - - /* 0000 0010 ... */ - /* 0000 */ V(12, 11, 3), /* 152 */ - /* 0001 */ V(12, 11, 3), - /* 0010 */ V(15, 6, 3), - /* 0011 */ V(15, 6, 3), - /* 0100 */ V(8, 14, 4), - /* 0101 */ V(14, 8, 4), - /* 0110 */ V(5, 15, 4), - /* 0111 */ V(9, 13, 4), - /* 1000 */ V(15, 5, 3), - /* 1001 */ V(15, 5, 3), - /* 1010 */ V(7, 14, 3), - /* 1011 */ V(7, 14, 3), - /* 1100 */ V(14, 7, 3), - /* 1101 */ V(14, 7, 3), - /* 1110 */ V(10, 12, 3), - /* 1111 */ V(10, 12, 3), - - /* 0000 0011 ... */ - /* 0000 */ V(12, 10, 3), /* 168 */ - /* 0001 */ V(12, 10, 3), - /* 0010 */ V(11, 11, 3), - /* 0011 */ V(11, 11, 3), - /* 0100 */ V(13, 9, 4), - /* 0101 */ V(8, 13, 4), - /* 0110 */ V(4, 15, 3), - /* 0111 */ V(4, 15, 3), - /* 1000 */ V(15, 4, 3), - /* 1001 */ V(15, 4, 3), - /* 1010 */ V(3, 15, 3), - /* 1011 */ V(3, 15, 3), - /* 1100 */ V(15, 3, 3), - /* 1101 */ V(15, 3, 3), - /* 1110 */ V(13, 8, 3), - /* 1111 */ V(13, 8, 3), - - /* 0000 0100 ... */ - /* 0000 */ V(14, 6, 3), /* 184 */ - /* 0001 */ V(14, 6, 3), - /* 0010 */ V(2, 15, 3), - /* 0011 */ V(2, 15, 3), - /* 0100 */ V(15, 2, 3), - /* 0101 */ V(15, 2, 3), - /* 0110 */ V(6, 14, 4), - /* 0111 */ V(15, 0, 4), - /* 1000 */ V(1, 15, 3), - /* 1001 */ V(1, 15, 3), - /* 1010 */ V(15, 1, 3), - /* 1011 */ V(15, 1, 3), - /* 1100 */ V(9, 12, 3), - /* 1101 */ V(9, 12, 3), - /* 1110 */ V(12, 9, 3), - /* 1111 */ V(12, 9, 3), - - /* 0000 0101 ... */ - /* 000 */ V(5, 14, 3), /* 200 */ - /* 001 */ V(10, 11, 3), - /* 010 */ V(11, 10, 3), - /* 011 */ V(14, 5, 3), - /* 100 */ V(7, 13, 3), - /* 101 */ V(13, 7, 3), - /* 110 */ V(4, 14, 3), - /* 111 */ V(14, 4, 3), - - /* 0000 0110 ... */ - /* 000 */ V(8, 12, 3), /* 208 */ - /* 001 */ V(12, 8, 3), - /* 010 */ V(3, 14, 3), - /* 011 */ V(6, 13, 3), - /* 100 */ V(13, 6, 3), - /* 101 */ V(14, 3, 3), - /* 110 */ V(9, 11, 3), - /* 111 */ V(11, 9, 3), - - /* 0000 0111 ... */ - /* 0000 */ V(2, 14, 3), /* 216 */ - /* 0001 */ V(2, 14, 3), - /* 0010 */ V(10, 10, 3), - /* 0011 */ V(10, 10, 3), - /* 0100 */ V(14, 2, 3), - /* 0101 */ V(14, 2, 3), - /* 0110 */ V(1, 14, 3), - /* 0111 */ V(1, 14, 3), - /* 1000 */ V(14, 1, 3), - /* 1001 */ V(14, 1, 3), - /* 1010 */ V(0, 14, 4), - /* 1011 */ V(14, 0, 4), - /* 1100 */ V(5, 13, 3), - /* 1101 */ V(5, 13, 3), - /* 1110 */ V(13, 5, 3), - /* 1111 */ V(13, 5, 3), - - /* 0000 1000 ... */ - /* 000 */ V(7, 12, 3), /* 232 */ - /* 001 */ V(12, 7, 3), - /* 010 */ V(4, 13, 3), - /* 011 */ V(8, 11, 3), - /* 100 */ V(13, 4, 2), - /* 101 */ V(13, 4, 2), - /* 110 */ V(11, 8, 3), - /* 111 */ V(9, 10, 3), - - /* 0000 1001 ... */ - /* 000 */ V(10, 9, 3), /* 240 */ - /* 001 */ V(6, 12, 3), - /* 010 */ V(12, 6, 3), - /* 011 */ V(3, 13, 3), - /* 100 */ V(13, 3, 2), - /* 101 */ V(13, 3, 2), - /* 110 */ V(13, 2, 2), - /* 111 */ V(13, 2, 2), - - /* 0000 1010 ... */ - /* 000 */ V(2, 13, 3), /* 248 */ - /* 001 */ V(0, 13, 3), - /* 010 */ V(1, 13, 2), - /* 011 */ V(1, 13, 2), - /* 100 */ V(7, 11, 2), - /* 101 */ V(7, 11, 2), - /* 110 */ V(11, 7, 2), - /* 111 */ V(11, 7, 2), - - /* 0000 1011 ... */ - /* 000 */ V(13, 1, 2), /* 256 */ - /* 001 */ V(13, 1, 2), - /* 010 */ V(5, 12, 3), - /* 011 */ V(13, 0, 3), - /* 100 */ V(12, 5, 2), - /* 101 */ V(12, 5, 2), - /* 110 */ V(8, 10, 2), - /* 111 */ V(8, 10, 2), - - /* 0000 1100 ... */ - /* 00 */ V(10, 8, 2), /* 264 */ - /* 01 */ V(4, 12, 2), - /* 10 */ V(12, 4, 2), - /* 11 */ V(6, 11, 2), - - /* 0000 1101 ... */ - /* 000 */ V(11, 6, 2), /* 268 */ - /* 001 */ V(11, 6, 2), - /* 010 */ V(9, 9, 3), - /* 011 */ V(0, 12, 3), - /* 100 */ V(3, 12, 2), - /* 101 */ V(3, 12, 2), - /* 110 */ V(12, 3, 2), - /* 111 */ V(12, 3, 2), - - /* 0000 1110 ... */ - /* 000 */ V(7, 10, 2), /* 276 */ - /* 001 */ V(7, 10, 2), - /* 010 */ V(10, 7, 2), - /* 011 */ V(10, 7, 2), - /* 100 */ V(10, 6, 2), - /* 101 */ V(10, 6, 2), - /* 110 */ V(12, 0, 3), - /* 111 */ V(0, 11, 3), - - /* 0000 1111 ... */ - /* 00 */ V(12, 2, 1), /* 284 */ - /* 01 */ V(12, 2, 1), - /* 10 */ V(2, 12, 2), - /* 11 */ V(5, 11, 2), - - /* 0001 0000 ... */ - /* 00 */ V(11, 5, 2), /* 288 */ - /* 01 */ V(1, 12, 2), - /* 10 */ V(8, 9, 2), - /* 11 */ V(9, 8, 2), - - /* 0001 0001 ... */ - /* 00 */ V(12, 1, 2), /* 292 */ - /* 01 */ V(4, 11, 2), - /* 10 */ V(11, 4, 2), - /* 11 */ V(6, 10, 2), - - /* 0001 0010 ... */ - /* 00 */ V(3, 11, 2), /* 296 */ - /* 01 */ V(7, 9, 2), - /* 10 */ V(11, 3, 1), - /* 11 */ V(11, 3, 1), - - /* 0001 0011 ... */ - /* 00 */ V(9, 7, 2), /* 300 */ - /* 01 */ V(8, 8, 2), - /* 10 */ V(2, 11, 2), - /* 11 */ V(5, 10, 2), - - /* 0001 0100 ... */ - /* 00 */ V(11, 2, 1), /* 304 */ - /* 01 */ V(11, 2, 1), - /* 10 */ V(10, 5, 2), - /* 11 */ V(1, 11, 2), - - /* 0001 0101 ... */ - /* 00 */ V(11, 1, 1), /* 308 */ - /* 01 */ V(11, 1, 1), - /* 10 */ V(11, 0, 2), - /* 11 */ V(6, 9, 2), - - /* 0001 0110 ... */ - /* 00 */ V(9, 6, 2), /* 312 */ - /* 01 */ V(4, 10, 2), - /* 10 */ V(10, 4, 2), - /* 11 */ V(7, 8, 2), - - /* 0001 0111 ... */ - /* 00 */ V(8, 7, 2), /* 316 */ - /* 01 */ V(3, 10, 2), - /* 10 */ V(10, 3, 1), - /* 11 */ V(10, 3, 1), - - /* 0001 1000 ... */ - /* 0 */ V(5, 9, 1), /* 320 */ - /* 1 */ V(9, 5, 1), - - /* 0001 1001 ... */ - /* 0 */ V(2, 10, 1), /* 322 */ - /* 1 */ V(10, 2, 1), - - /* 0001 1010 ... */ - /* 0 */ V(1, 10, 1), /* 324 */ - /* 1 */ V(10, 1, 1), - - /* 0001 1011 ... */ - /* 00 */ V(0, 10, 2), /* 326 */ - /* 01 */ V(10, 0, 2), - /* 10 */ V(6, 8, 1), - /* 11 */ V(6, 8, 1), - - /* 0001 1100 ... */ - /* 0 */ V(8, 6, 1), /* 330 */ - /* 1 */ V(4, 9, 1), - - /* 0001 1101 ... */ - /* 0 */ V(9, 4, 1), /* 332 */ - /* 1 */ V(3, 9, 1), - - /* 0001 1110 ... */ - /* 00 */ V(9, 3, 1), /* 334 */ - /* 01 */ V(9, 3, 1), - /* 10 */ V(7, 7, 2), - /* 11 */ V(0, 9, 2), - - /* 0001 1111 ... */ - /* 0 */ V(5, 8, 1), /* 338 */ - /* 1 */ V(8, 5, 1), - - /* 0010 0000 ... */ - /* 0 */ V(2, 9, 1), /* 340 */ - /* 1 */ V(6, 7, 1), - - /* 0010 0001 ... */ - /* 0 */ V(7, 6, 1), /* 342 */ - /* 1 */ V(9, 2, 1), - - /* 0010 0011 ... */ - /* 0 */ V(1, 9, 1), /* 344 */ - /* 1 */ V(9, 0, 1), - - /* 0010 0100 ... */ - /* 0 */ V(4, 8, 1), /* 346 */ - /* 1 */ V(8, 4, 1), - - /* 0010 0101 ... */ - /* 0 */ V(5, 7, 1), /* 348 */ - /* 1 */ V(7, 5, 1), - - /* 0010 0110 ... */ - /* 0 */ V(3, 8, 1), /* 350 */ - /* 1 */ V(8, 3, 1), - - /* 0010 0111 ... */ - /* 0 */ V(6, 6, 1), /* 352 */ - /* 1 */ V(4, 7, 1), - - /* 0010 1100 ... */ - /* 0 */ V(7, 4, 1), /* 354 */ - /* 1 */ V(0, 8, 1), - - /* 0010 1101 ... */ - /* 0 */ V(8, 0, 1), /* 356 */ - /* 1 */ V(5, 6, 1), - - /* 0010 1110 ... */ - /* 0 */ V(6, 5, 1), /* 358 */ - /* 1 */ V(3, 7, 1), - - /* 0010 1111 ... */ - /* 0 */ V(7, 3, 1), /* 360 */ - /* 1 */ V(4, 6, 1), - - /* 0011 0110 ... */ - /* 0 */ V(0, 7, 1), /* 362 */ - /* 1 */ V(7, 0, 1), - - /* 0011 1110 ... */ - /* 0 */ V(0, 6, 1), /* 364 */ - /* 1 */ V(6, 0, 1), - - /* 0000 0000 0000 ... */ - /* 0 */ V(15, 15, 1), /* 366 */ - /* 1 */ V(14, 15, 1), - - /* 0000 0000 0001 ... */ - /* 0 */ V(15, 14, 1), /* 368 */ - /* 1 */ V(13, 15, 1), - - /* 0000 0000 0011 ... */ - /* 0 */ V(15, 13, 1), /* 370 */ - /* 1 */ V(12, 15, 1), - - /* 0000 0000 0100 ... */ - /* 0 */ V(15, 12, 1), /* 372 */ - /* 1 */ V(13, 14, 1), - - /* 0000 0000 0101 ... */ - /* 0 */ V(14, 13, 1), /* 374 */ - /* 1 */ V(11, 15, 1), - - /* 0000 0000 0111 ... */ - /* 0 */ V(12, 14, 1), /* 376 */ - /* 1 */ V(14, 12, 1), - - /* 0000 0001 1111 ... */ - /* 0 */ V(10, 14, 1), /* 378 */ - /* 1 */ V(0, 15, 1) -}; - -static -union huffpair const hufftab16[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ PTR(64, 2), - /* 0100 */ V(1, 1, 4), - /* 0101 */ V(0, 1, 4), - /* 0110 */ V(1, 0, 3), - /* 0111 */ V(1, 0, 3), - /* 1000 */ V(0, 0, 1), - /* 1001 */ V(0, 0, 1), - /* 1010 */ V(0, 0, 1), - /* 1011 */ V(0, 0, 1), - /* 1100 */ V(0, 0, 1), - /* 1101 */ V(0, 0, 1), - /* 1110 */ V(0, 0, 1), - /* 1111 */ V(0, 0, 1), - - /* 0000 ... */ - /* 0000 */ PTR(68, 3), /* 16 */ - /* 0001 */ PTR(76, 3), - /* 0010 */ PTR(84, 2), - /* 0011 */ V(15, 15, 4), - /* 0100 */ PTR(88, 2), - /* 0101 */ PTR(92, 1), - /* 0110 */ PTR(94, 4), - /* 0111 */ V(15, 2, 4), - /* 1000 */ PTR(110, 1), - /* 1001 */ V(1, 15, 4), - /* 1010 */ V(15, 1, 4), - /* 1011 */ PTR(112, 4), - /* 1100 */ PTR(128, 4), - /* 1101 */ PTR(144, 4), - /* 1110 */ PTR(160, 4), - /* 1111 */ PTR(176, 4), - - /* 0001 ... */ - /* 0000 */ PTR(192, 4), /* 32 */ - /* 0001 */ PTR(208, 3), - /* 0010 */ PTR(216, 3), - /* 0011 */ PTR(224, 3), - /* 0100 */ PTR(232, 3), - /* 0101 */ PTR(240, 3), - /* 0110 */ PTR(248, 3), - /* 0111 */ PTR(256, 3), - /* 1000 */ PTR(264, 2), - /* 1001 */ PTR(268, 2), - /* 1010 */ PTR(272, 1), - /* 1011 */ PTR(274, 2), - /* 1100 */ PTR(278, 2), - /* 1101 */ PTR(282, 1), - /* 1110 */ V(5, 1, 4), - /* 1111 */ PTR(284, 1), - - /* 0010 ... */ - /* 0000 */ PTR(286, 1), /* 48 */ - /* 0001 */ PTR(288, 1), - /* 0010 */ PTR(290, 1), - /* 0011 */ V(1, 4, 4), - /* 0100 */ V(4, 1, 4), - /* 0101 */ PTR(292, 1), - /* 0110 */ V(2, 3, 4), - /* 0111 */ V(3, 2, 4), - /* 1000 */ V(1, 3, 3), - /* 1001 */ V(1, 3, 3), - /* 1010 */ V(3, 1, 3), - /* 1011 */ V(3, 1, 3), - /* 1100 */ V(0, 3, 4), - /* 1101 */ V(3, 0, 4), - /* 1110 */ V(2, 2, 3), - /* 1111 */ V(2, 2, 3), - - /* 0011 ... */ - /* 00 */ V(1, 2, 2), /* 64 */ - /* 01 */ V(2, 1, 2), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0000 0000 ... */ - /* 000 */ V(14, 15, 3), /* 68 */ - /* 001 */ V(15, 14, 3), - /* 010 */ V(13, 15, 3), - /* 011 */ V(15, 13, 3), - /* 100 */ V(12, 15, 3), - /* 101 */ V(15, 12, 3), - /* 110 */ V(11, 15, 3), - /* 111 */ V(15, 11, 3), - - /* 0000 0001 ... */ - /* 000 */ V(10, 15, 2), /* 76 */ - /* 001 */ V(10, 15, 2), - /* 010 */ V(15, 10, 3), - /* 011 */ V(9, 15, 3), - /* 100 */ V(15, 9, 3), - /* 101 */ V(15, 8, 3), - /* 110 */ V(8, 15, 2), - /* 111 */ V(8, 15, 2), - - /* 0000 0010 ... */ - /* 00 */ V(7, 15, 2), /* 84 */ - /* 01 */ V(15, 7, 2), - /* 10 */ V(6, 15, 2), - /* 11 */ V(15, 6, 2), - - /* 0000 0100 ... */ - /* 00 */ V(5, 15, 2), /* 88 */ - /* 01 */ V(15, 5, 2), - /* 10 */ V(4, 15, 1), - /* 11 */ V(4, 15, 1), - - /* 0000 0101 ... */ - /* 0 */ V(15, 4, 1), /* 92 */ - /* 1 */ V(15, 3, 1), - - /* 0000 0110 ... */ - /* 0000 */ V(15, 0, 1), /* 94 */ - /* 0001 */ V(15, 0, 1), - /* 0010 */ V(15, 0, 1), - /* 0011 */ V(15, 0, 1), - /* 0100 */ V(15, 0, 1), - /* 0101 */ V(15, 0, 1), - /* 0110 */ V(15, 0, 1), - /* 0111 */ V(15, 0, 1), - /* 1000 */ V(3, 15, 2), - /* 1001 */ V(3, 15, 2), - /* 1010 */ V(3, 15, 2), - /* 1011 */ V(3, 15, 2), - /* 1100 */ PTR(294, 4), - /* 1101 */ PTR(310, 3), - /* 1110 */ PTR(318, 3), - /* 1111 */ PTR(326, 3), - - /* 0000 1000 ... */ - /* 0 */ V(2, 15, 1), /* 110 */ - /* 1 */ V(0, 15, 1), - - /* 0000 1011 ... */ - /* 0000 */ PTR(334, 2), /* 112 */ - /* 0001 */ PTR(338, 2), - /* 0010 */ PTR(342, 2), - /* 0011 */ PTR(346, 1), - /* 0100 */ PTR(348, 2), - /* 0101 */ PTR(352, 2), - /* 0110 */ PTR(356, 1), - /* 0111 */ PTR(358, 2), - /* 1000 */ PTR(362, 2), - /* 1001 */ PTR(366, 2), - /* 1010 */ PTR(370, 2), - /* 1011 */ V(14, 3, 4), - /* 1100 */ PTR(374, 1), - /* 1101 */ PTR(376, 1), - /* 1110 */ PTR(378, 1), - /* 1111 */ PTR(380, 1), - - /* 0000 1100 ... */ - /* 0000 */ PTR(382, 1), /* 128 */ - /* 0001 */ PTR(384, 1), - /* 0010 */ PTR(386, 1), - /* 0011 */ V(0, 13, 4), - /* 0100 */ PTR(388, 1), - /* 0101 */ PTR(390, 1), - /* 0110 */ PTR(392, 1), - /* 0111 */ V(3, 12, 4), - /* 1000 */ PTR(394, 1), - /* 1001 */ V(1, 12, 4), - /* 1010 */ V(12, 0, 4), - /* 1011 */ PTR(396, 1), - /* 1100 */ V(14, 2, 3), - /* 1101 */ V(14, 2, 3), - /* 1110 */ V(2, 14, 4), - /* 1111 */ V(1, 14, 4), - - /* 0000 1101 ... */ - /* 0000 */ V(13, 3, 4), /* 144 */ - /* 0001 */ V(2, 13, 4), - /* 0010 */ V(13, 2, 4), - /* 0011 */ V(13, 1, 4), - /* 0100 */ V(3, 11, 4), - /* 0101 */ PTR(398, 1), - /* 0110 */ V(1, 13, 3), - /* 0111 */ V(1, 13, 3), - /* 1000 */ V(12, 4, 4), - /* 1001 */ V(6, 11, 4), - /* 1010 */ V(12, 3, 4), - /* 1011 */ V(10, 7, 4), - /* 1100 */ V(2, 12, 3), - /* 1101 */ V(2, 12, 3), - /* 1110 */ V(12, 2, 4), - /* 1111 */ V(11, 5, 4), - - /* 0000 1110 ... */ - /* 0000 */ V(12, 1, 4), /* 160 */ - /* 0001 */ V(0, 12, 4), - /* 0010 */ V(4, 11, 4), - /* 0011 */ V(11, 4, 4), - /* 0100 */ V(6, 10, 4), - /* 0101 */ V(10, 6, 4), - /* 0110 */ V(11, 3, 3), - /* 0111 */ V(11, 3, 3), - /* 1000 */ V(5, 10, 4), - /* 1001 */ V(10, 5, 4), - /* 1010 */ V(2, 11, 3), - /* 1011 */ V(2, 11, 3), - /* 1100 */ V(11, 2, 3), - /* 1101 */ V(11, 2, 3), - /* 1110 */ V(1, 11, 3), - /* 1111 */ V(1, 11, 3), - - /* 0000 1111 ... */ - /* 0000 */ V(11, 1, 3), /* 176 */ - /* 0001 */ V(11, 1, 3), - /* 0010 */ V(0, 11, 4), - /* 0011 */ V(11, 0, 4), - /* 0100 */ V(6, 9, 4), - /* 0101 */ V(9, 6, 4), - /* 0110 */ V(4, 10, 4), - /* 0111 */ V(10, 4, 4), - /* 1000 */ V(7, 8, 4), - /* 1001 */ V(8, 7, 4), - /* 1010 */ V(10, 3, 3), - /* 1011 */ V(10, 3, 3), - /* 1100 */ V(3, 10, 4), - /* 1101 */ V(5, 9, 4), - /* 1110 */ V(2, 10, 3), - /* 1111 */ V(2, 10, 3), - - /* 0001 0000 ... */ - /* 0000 */ V(9, 5, 4), /* 192 */ - /* 0001 */ V(6, 8, 4), - /* 0010 */ V(10, 1, 3), - /* 0011 */ V(10, 1, 3), - /* 0100 */ V(8, 6, 4), - /* 0101 */ V(7, 7, 4), - /* 0110 */ V(9, 4, 3), - /* 0111 */ V(9, 4, 3), - /* 1000 */ V(4, 9, 4), - /* 1001 */ V(5, 7, 4), - /* 1010 */ V(6, 7, 3), - /* 1011 */ V(6, 7, 3), - /* 1100 */ V(10, 2, 2), - /* 1101 */ V(10, 2, 2), - /* 1110 */ V(10, 2, 2), - /* 1111 */ V(10, 2, 2), - - /* 0001 0001 ... */ - /* 000 */ V(1, 10, 2), /* 208 */ - /* 001 */ V(1, 10, 2), - /* 010 */ V(0, 10, 3), - /* 011 */ V(10, 0, 3), - /* 100 */ V(3, 9, 3), - /* 101 */ V(9, 3, 3), - /* 110 */ V(5, 8, 3), - /* 111 */ V(8, 5, 3), - - /* 0001 0010 ... */ - /* 000 */ V(2, 9, 2), /* 216 */ - /* 001 */ V(2, 9, 2), - /* 010 */ V(9, 2, 2), - /* 011 */ V(9, 2, 2), - /* 100 */ V(7, 6, 3), - /* 101 */ V(0, 9, 3), - /* 110 */ V(1, 9, 2), - /* 111 */ V(1, 9, 2), - - /* 0001 0011 ... */ - /* 000 */ V(9, 1, 2), /* 224 */ - /* 001 */ V(9, 1, 2), - /* 010 */ V(9, 0, 3), - /* 011 */ V(4, 8, 3), - /* 100 */ V(8, 4, 3), - /* 101 */ V(7, 5, 3), - /* 110 */ V(3, 8, 3), - /* 111 */ V(8, 3, 3), - - /* 0001 0100 ... */ - /* 000 */ V(6, 6, 3), /* 232 */ - /* 001 */ V(2, 8, 3), - /* 010 */ V(8, 2, 2), - /* 011 */ V(8, 2, 2), - /* 100 */ V(4, 7, 3), - /* 101 */ V(7, 4, 3), - /* 110 */ V(1, 8, 2), - /* 111 */ V(1, 8, 2), - - /* 0001 0101 ... */ - /* 000 */ V(8, 1, 2), /* 240 */ - /* 001 */ V(8, 1, 2), - /* 010 */ V(8, 0, 2), - /* 011 */ V(8, 0, 2), - /* 100 */ V(0, 8, 3), - /* 101 */ V(5, 6, 3), - /* 110 */ V(3, 7, 2), - /* 111 */ V(3, 7, 2), - - /* 0001 0110 ... */ - /* 000 */ V(7, 3, 2), /* 248 */ - /* 001 */ V(7, 3, 2), - /* 010 */ V(6, 5, 3), - /* 011 */ V(4, 6, 3), - /* 100 */ V(2, 7, 2), - /* 101 */ V(2, 7, 2), - /* 110 */ V(7, 2, 2), - /* 111 */ V(7, 2, 2), - - /* 0001 0111 ... */ - /* 000 */ V(6, 4, 3), /* 256 */ - /* 001 */ V(5, 5, 3), - /* 010 */ V(0, 7, 2), - /* 011 */ V(0, 7, 2), - /* 100 */ V(1, 7, 1), - /* 101 */ V(1, 7, 1), - /* 110 */ V(1, 7, 1), - /* 111 */ V(1, 7, 1), - - /* 0001 1000 ... */ - /* 00 */ V(7, 1, 1), /* 264 */ - /* 01 */ V(7, 1, 1), - /* 10 */ V(7, 0, 2), - /* 11 */ V(3, 6, 2), - - /* 0001 1001 ... */ - /* 00 */ V(6, 3, 2), /* 268 */ - /* 01 */ V(4, 5, 2), - /* 10 */ V(5, 4, 2), - /* 11 */ V(2, 6, 2), - - /* 0001 1010 ... */ - /* 0 */ V(6, 2, 1), /* 272 */ - /* 1 */ V(1, 6, 1), - - /* 0001 1011 ... */ - /* 00 */ V(6, 1, 1), /* 274 */ - /* 01 */ V(6, 1, 1), - /* 10 */ V(0, 6, 2), - /* 11 */ V(6, 0, 2), - - /* 0001 1100 ... */ - /* 00 */ V(5, 3, 1), /* 278 */ - /* 01 */ V(5, 3, 1), - /* 10 */ V(3, 5, 2), - /* 11 */ V(4, 4, 2), - - /* 0001 1101 ... */ - /* 0 */ V(2, 5, 1), /* 282 */ - /* 1 */ V(5, 2, 1), - - /* 0001 1111 ... */ - /* 0 */ V(1, 5, 1), /* 284 */ - /* 1 */ V(0, 5, 1), - - /* 0010 0000 ... */ - /* 0 */ V(3, 4, 1), /* 286 */ - /* 1 */ V(4, 3, 1), - - /* 0010 0001 ... */ - /* 0 */ V(5, 0, 1), /* 288 */ - /* 1 */ V(2, 4, 1), - - /* 0010 0010 ... */ - /* 0 */ V(4, 2, 1), /* 290 */ - /* 1 */ V(3, 3, 1), - - /* 0010 0101 ... */ - /* 0 */ V(0, 4, 1), /* 292 */ - /* 1 */ V(4, 0, 1), - - /* 0000 0110 1100 ... */ - /* 0000 */ V(12, 14, 4), /* 294 */ - /* 0001 */ PTR(400, 1), - /* 0010 */ V(13, 14, 3), - /* 0011 */ V(13, 14, 3), - /* 0100 */ V(14, 9, 3), - /* 0101 */ V(14, 9, 3), - /* 0110 */ V(14, 10, 4), - /* 0111 */ V(13, 9, 4), - /* 1000 */ V(14, 14, 2), - /* 1001 */ V(14, 14, 2), - /* 1010 */ V(14, 14, 2), - /* 1011 */ V(14, 14, 2), - /* 1100 */ V(14, 13, 3), - /* 1101 */ V(14, 13, 3), - /* 1110 */ V(14, 11, 3), - /* 1111 */ V(14, 11, 3), - - /* 0000 0110 1101 ... */ - /* 000 */ V(11, 14, 2), /* 310 */ - /* 001 */ V(11, 14, 2), - /* 010 */ V(12, 13, 2), - /* 011 */ V(12, 13, 2), - /* 100 */ V(13, 12, 3), - /* 101 */ V(13, 11, 3), - /* 110 */ V(10, 14, 2), - /* 111 */ V(10, 14, 2), - - /* 0000 0110 1110 ... */ - /* 000 */ V(12, 12, 2), /* 318 */ - /* 001 */ V(12, 12, 2), - /* 010 */ V(10, 13, 3), - /* 011 */ V(13, 10, 3), - /* 100 */ V(7, 14, 3), - /* 101 */ V(10, 12, 3), - /* 110 */ V(12, 10, 2), - /* 111 */ V(12, 10, 2), - - /* 0000 0110 1111 ... */ - /* 000 */ V(12, 9, 3), /* 326 */ - /* 001 */ V(7, 13, 3), - /* 010 */ V(5, 14, 2), - /* 011 */ V(5, 14, 2), - /* 100 */ V(11, 13, 1), - /* 101 */ V(11, 13, 1), - /* 110 */ V(11, 13, 1), - /* 111 */ V(11, 13, 1), - - /* 0000 1011 0000 ... */ - /* 00 */ V(9, 14, 1), /* 334 */ - /* 01 */ V(9, 14, 1), - /* 10 */ V(11, 12, 2), - /* 11 */ V(12, 11, 2), - - /* 0000 1011 0001 ... */ - /* 00 */ V(8, 14, 2), /* 338 */ - /* 01 */ V(14, 8, 2), - /* 10 */ V(9, 13, 2), - /* 11 */ V(14, 7, 2), - - /* 0000 1011 0010 ... */ - /* 00 */ V(11, 11, 2), /* 342 */ - /* 01 */ V(8, 13, 2), - /* 10 */ V(13, 8, 2), - /* 11 */ V(6, 14, 2), - - /* 0000 1011 0011 ... */ - /* 0 */ V(14, 6, 1), /* 346 */ - /* 1 */ V(9, 12, 1), - - /* 0000 1011 0100 ... */ - /* 00 */ V(10, 11, 2), /* 348 */ - /* 01 */ V(11, 10, 2), - /* 10 */ V(14, 5, 2), - /* 11 */ V(13, 7, 2), - - /* 0000 1011 0101 ... */ - /* 00 */ V(4, 14, 1), /* 352 */ - /* 01 */ V(4, 14, 1), - /* 10 */ V(14, 4, 2), - /* 11 */ V(8, 12, 2), - - /* 0000 1011 0110 ... */ - /* 0 */ V(12, 8, 1), /* 356 */ - /* 1 */ V(3, 14, 1), - - /* 0000 1011 0111 ... */ - /* 00 */ V(6, 13, 1), /* 358 */ - /* 01 */ V(6, 13, 1), - /* 10 */ V(13, 6, 2), - /* 11 */ V(9, 11, 2), - - /* 0000 1011 1000 ... */ - /* 00 */ V(11, 9, 2), /* 362 */ - /* 01 */ V(10, 10, 2), - /* 10 */ V(14, 1, 1), - /* 11 */ V(14, 1, 1), - - /* 0000 1011 1001 ... */ - /* 00 */ V(13, 4, 1), /* 366 */ - /* 01 */ V(13, 4, 1), - /* 10 */ V(11, 8, 2), - /* 11 */ V(10, 9, 2), - - /* 0000 1011 1010 ... */ - /* 00 */ V(7, 11, 1), /* 370 */ - /* 01 */ V(7, 11, 1), - /* 10 */ V(11, 7, 2), - /* 11 */ V(13, 0, 2), - - /* 0000 1011 1100 ... */ - /* 0 */ V(0, 14, 1), /* 374 */ - /* 1 */ V(14, 0, 1), - - /* 0000 1011 1101 ... */ - /* 0 */ V(5, 13, 1), /* 376 */ - /* 1 */ V(13, 5, 1), - - /* 0000 1011 1110 ... */ - /* 0 */ V(7, 12, 1), /* 378 */ - /* 1 */ V(12, 7, 1), - - /* 0000 1011 1111 ... */ - /* 0 */ V(4, 13, 1), /* 380 */ - /* 1 */ V(8, 11, 1), - - /* 0000 1100 0000 ... */ - /* 0 */ V(9, 10, 1), /* 382 */ - /* 1 */ V(6, 12, 1), - - /* 0000 1100 0001 ... */ - /* 0 */ V(12, 6, 1), /* 384 */ - /* 1 */ V(3, 13, 1), - - /* 0000 1100 0010 ... */ - /* 0 */ V(5, 12, 1), /* 386 */ - /* 1 */ V(12, 5, 1), - - /* 0000 1100 0100 ... */ - /* 0 */ V(8, 10, 1), /* 388 */ - /* 1 */ V(10, 8, 1), - - /* 0000 1100 0101 ... */ - /* 0 */ V(9, 9, 1), /* 390 */ - /* 1 */ V(4, 12, 1), - - /* 0000 1100 0110 ... */ - /* 0 */ V(11, 6, 1), /* 392 */ - /* 1 */ V(7, 10, 1), - - /* 0000 1100 1000 ... */ - /* 0 */ V(5, 11, 1), /* 394 */ - /* 1 */ V(8, 9, 1), - - /* 0000 1100 1011 ... */ - /* 0 */ V(9, 8, 1), /* 396 */ - /* 1 */ V(7, 9, 1), - - /* 0000 1101 0101 ... */ - /* 0 */ V(9, 7, 1), /* 398 */ - /* 1 */ V(8, 8, 1), - - /* 0000 0110 1100 0001 ... */ - /* 0 */ V(14, 12, 1), /* 400 */ - /* 1 */ V(13, 13, 1) -}; - -static -union huffpair const hufftab24[] = { - /* 0000 */ PTR(16, 4), - /* 0001 */ PTR(32, 4), - /* 0010 */ PTR(48, 4), - /* 0011 */ V(15, 15, 4), - /* 0100 */ PTR(64, 4), - /* 0101 */ PTR(80, 4), - /* 0110 */ PTR(96, 4), - /* 0111 */ PTR(112, 4), - /* 1000 */ PTR(128, 4), - /* 1001 */ PTR(144, 4), - /* 1010 */ PTR(160, 3), - /* 1011 */ PTR(168, 2), - /* 1100 */ V(1, 1, 4), - /* 1101 */ V(0, 1, 4), - /* 1110 */ V(1, 0, 4), - /* 1111 */ V(0, 0, 4), - - /* 0000 ... */ - /* 0000 */ V(14, 15, 4), /* 16 */ - /* 0001 */ V(15, 14, 4), - /* 0010 */ V(13, 15, 4), - /* 0011 */ V(15, 13, 4), - /* 0100 */ V(12, 15, 4), - /* 0101 */ V(15, 12, 4), - /* 0110 */ V(11, 15, 4), - /* 0111 */ V(15, 11, 4), - /* 1000 */ V(15, 10, 3), - /* 1001 */ V(15, 10, 3), - /* 1010 */ V(10, 15, 4), - /* 1011 */ V(9, 15, 4), - /* 1100 */ V(15, 9, 3), - /* 1101 */ V(15, 9, 3), - /* 1110 */ V(15, 8, 3), - /* 1111 */ V(15, 8, 3), - - /* 0001 ... */ - /* 0000 */ V(8, 15, 4), /* 32 */ - /* 0001 */ V(7, 15, 4), - /* 0010 */ V(15, 7, 3), - /* 0011 */ V(15, 7, 3), - /* 0100 */ V(6, 15, 3), - /* 0101 */ V(6, 15, 3), - /* 0110 */ V(15, 6, 3), - /* 0111 */ V(15, 6, 3), - /* 1000 */ V(5, 15, 3), - /* 1001 */ V(5, 15, 3), - /* 1010 */ V(15, 5, 3), - /* 1011 */ V(15, 5, 3), - /* 1100 */ V(4, 15, 3), - /* 1101 */ V(4, 15, 3), - /* 1110 */ V(15, 4, 3), - /* 1111 */ V(15, 4, 3), - - /* 0010 ... */ - /* 0000 */ V(3, 15, 3), /* 48 */ - /* 0001 */ V(3, 15, 3), - /* 0010 */ V(15, 3, 3), - /* 0011 */ V(15, 3, 3), - /* 0100 */ V(2, 15, 3), - /* 0101 */ V(2, 15, 3), - /* 0110 */ V(15, 2, 3), - /* 0111 */ V(15, 2, 3), - /* 1000 */ V(15, 1, 3), - /* 1001 */ V(15, 1, 3), - /* 1010 */ V(1, 15, 4), - /* 1011 */ V(15, 0, 4), - /* 1100 */ PTR(172, 3), - /* 1101 */ PTR(180, 3), - /* 1110 */ PTR(188, 3), - /* 1111 */ PTR(196, 3), - - /* 0100 ... */ - /* 0000 */ PTR(204, 4), /* 64 */ - /* 0001 */ PTR(220, 3), - /* 0010 */ PTR(228, 3), - /* 0011 */ PTR(236, 3), - /* 0100 */ PTR(244, 2), - /* 0101 */ PTR(248, 2), - /* 0110 */ PTR(252, 2), - /* 0111 */ PTR(256, 2), - /* 1000 */ PTR(260, 2), - /* 1001 */ PTR(264, 2), - /* 1010 */ PTR(268, 2), - /* 1011 */ PTR(272, 2), - /* 1100 */ PTR(276, 2), - /* 1101 */ PTR(280, 3), - /* 1110 */ PTR(288, 2), - /* 1111 */ PTR(292, 2), - - /* 0101 ... */ - /* 0000 */ PTR(296, 2), /* 80 */ - /* 0001 */ PTR(300, 3), - /* 0010 */ PTR(308, 2), - /* 0011 */ PTR(312, 3), - /* 0100 */ PTR(320, 1), - /* 0101 */ PTR(322, 2), - /* 0110 */ PTR(326, 2), - /* 0111 */ PTR(330, 1), - /* 1000 */ PTR(332, 2), - /* 1001 */ PTR(336, 1), - /* 1010 */ PTR(338, 1), - /* 1011 */ PTR(340, 1), - /* 1100 */ PTR(342, 1), - /* 1101 */ PTR(344, 1), - /* 1110 */ PTR(346, 1), - /* 1111 */ PTR(348, 1), - - /* 0110 ... */ - /* 0000 */ PTR(350, 1), /* 96 */ - /* 0001 */ PTR(352, 1), - /* 0010 */ PTR(354, 1), - /* 0011 */ PTR(356, 1), - /* 0100 */ PTR(358, 1), - /* 0101 */ PTR(360, 1), - /* 0110 */ PTR(362, 1), - /* 0111 */ PTR(364, 1), - /* 1000 */ PTR(366, 1), - /* 1001 */ PTR(368, 1), - /* 1010 */ PTR(370, 2), - /* 1011 */ PTR(374, 1), - /* 1100 */ PTR(376, 2), - /* 1101 */ V(7, 3, 4), - /* 1110 */ PTR(380, 1), - /* 1111 */ V(7, 2, 4), - - /* 0111 ... */ - /* 0000 */ V(4, 6, 4), /* 112 */ - /* 0001 */ V(6, 4, 4), - /* 0010 */ V(5, 5, 4), - /* 0011 */ V(7, 1, 4), - /* 0100 */ V(3, 6, 4), - /* 0101 */ V(6, 3, 4), - /* 0110 */ V(4, 5, 4), - /* 0111 */ V(5, 4, 4), - /* 1000 */ V(2, 6, 4), - /* 1001 */ V(6, 2, 4), - /* 1010 */ V(1, 6, 4), - /* 1011 */ V(6, 1, 4), - /* 1100 */ PTR(382, 1), - /* 1101 */ V(3, 5, 4), - /* 1110 */ V(5, 3, 4), - /* 1111 */ V(4, 4, 4), - - /* 1000 ... */ - /* 0000 */ V(2, 5, 4), /* 128 */ - /* 0001 */ V(5, 2, 4), - /* 0010 */ V(1, 5, 4), - /* 0011 */ PTR(384, 1), - /* 0100 */ V(5, 1, 3), - /* 0101 */ V(5, 1, 3), - /* 0110 */ V(3, 4, 4), - /* 0111 */ V(4, 3, 4), - /* 1000 */ V(2, 4, 3), - /* 1001 */ V(2, 4, 3), - /* 1010 */ V(4, 2, 3), - /* 1011 */ V(4, 2, 3), - /* 1100 */ V(3, 3, 3), - /* 1101 */ V(3, 3, 3), - /* 1110 */ V(1, 4, 3), - /* 1111 */ V(1, 4, 3), - - /* 1001 ... */ - /* 0000 */ V(4, 1, 3), /* 144 */ - /* 0001 */ V(4, 1, 3), - /* 0010 */ V(0, 4, 4), - /* 0011 */ V(4, 0, 4), - /* 0100 */ V(2, 3, 3), - /* 0101 */ V(2, 3, 3), - /* 0110 */ V(3, 2, 3), - /* 0111 */ V(3, 2, 3), - /* 1000 */ V(1, 3, 2), - /* 1001 */ V(1, 3, 2), - /* 1010 */ V(1, 3, 2), - /* 1011 */ V(1, 3, 2), - /* 1100 */ V(3, 1, 2), - /* 1101 */ V(3, 1, 2), - /* 1110 */ V(3, 1, 2), - /* 1111 */ V(3, 1, 2), - - /* 1010 ... */ - /* 000 */ V(0, 3, 3), /* 160 */ - /* 001 */ V(3, 0, 3), - /* 010 */ V(2, 2, 2), - /* 011 */ V(2, 2, 2), - /* 100 */ V(1, 2, 1), - /* 101 */ V(1, 2, 1), - /* 110 */ V(1, 2, 1), - /* 111 */ V(1, 2, 1), - - /* 1011 ... */ - /* 00 */ V(2, 1, 1), /* 168 */ - /* 01 */ V(2, 1, 1), - /* 10 */ V(0, 2, 2), - /* 11 */ V(2, 0, 2), - - /* 0010 1100 ... */ - /* 000 */ V(0, 15, 1), /* 172 */ - /* 001 */ V(0, 15, 1), - /* 010 */ V(0, 15, 1), - /* 011 */ V(0, 15, 1), - /* 100 */ V(14, 14, 3), - /* 101 */ V(13, 14, 3), - /* 110 */ V(14, 13, 3), - /* 111 */ V(12, 14, 3), - - /* 0010 1101 ... */ - /* 000 */ V(14, 12, 3), /* 180 */ - /* 001 */ V(13, 13, 3), - /* 010 */ V(11, 14, 3), - /* 011 */ V(14, 11, 3), - /* 100 */ V(12, 13, 3), - /* 101 */ V(13, 12, 3), - /* 110 */ V(10, 14, 3), - /* 111 */ V(14, 10, 3), - - /* 0010 1110 ... */ - /* 000 */ V(11, 13, 3), /* 188 */ - /* 001 */ V(13, 11, 3), - /* 010 */ V(12, 12, 3), - /* 011 */ V(9, 14, 3), - /* 100 */ V(14, 9, 3), - /* 101 */ V(10, 13, 3), - /* 110 */ V(13, 10, 3), - /* 111 */ V(11, 12, 3), - - /* 0010 1111 ... */ - /* 000 */ V(12, 11, 3), /* 196 */ - /* 001 */ V(8, 14, 3), - /* 010 */ V(14, 8, 3), - /* 011 */ V(9, 13, 3), - /* 100 */ V(13, 9, 3), - /* 101 */ V(7, 14, 3), - /* 110 */ V(14, 7, 3), - /* 111 */ V(10, 12, 3), - - /* 0100 0000 ... */ - /* 0000 */ V(12, 10, 3), /* 204 */ - /* 0001 */ V(12, 10, 3), - /* 0010 */ V(11, 11, 3), - /* 0011 */ V(11, 11, 3), - /* 0100 */ V(8, 13, 3), - /* 0101 */ V(8, 13, 3), - /* 0110 */ V(13, 8, 3), - /* 0111 */ V(13, 8, 3), - /* 1000 */ V(0, 14, 4), - /* 1001 */ V(14, 0, 4), - /* 1010 */ V(0, 13, 3), - /* 1011 */ V(0, 13, 3), - /* 1100 */ V(14, 6, 2), - /* 1101 */ V(14, 6, 2), - /* 1110 */ V(14, 6, 2), - /* 1111 */ V(14, 6, 2), - - /* 0100 0001 ... */ - /* 000 */ V(6, 14, 3), /* 220 */ - /* 001 */ V(9, 12, 3), - /* 010 */ V(12, 9, 2), - /* 011 */ V(12, 9, 2), - /* 100 */ V(5, 14, 2), - /* 101 */ V(5, 14, 2), - /* 110 */ V(11, 10, 2), - /* 111 */ V(11, 10, 2), - - /* 0100 0010 ... */ - /* 000 */ V(14, 5, 2), /* 228 */ - /* 001 */ V(14, 5, 2), - /* 010 */ V(10, 11, 3), - /* 011 */ V(7, 13, 3), - /* 100 */ V(13, 7, 2), - /* 101 */ V(13, 7, 2), - /* 110 */ V(14, 4, 2), - /* 111 */ V(14, 4, 2), - - /* 0100 0011 ... */ - /* 000 */ V(8, 12, 2), /* 236 */ - /* 001 */ V(8, 12, 2), - /* 010 */ V(12, 8, 2), - /* 011 */ V(12, 8, 2), - /* 100 */ V(4, 14, 3), - /* 101 */ V(2, 14, 3), - /* 110 */ V(3, 14, 2), - /* 111 */ V(3, 14, 2), - - /* 0100 0100 ... */ - /* 00 */ V(6, 13, 2), /* 244 */ - /* 01 */ V(13, 6, 2), - /* 10 */ V(14, 3, 2), - /* 11 */ V(9, 11, 2), - - /* 0100 0101 ... */ - /* 00 */ V(11, 9, 2), /* 248 */ - /* 01 */ V(10, 10, 2), - /* 10 */ V(14, 2, 2), - /* 11 */ V(1, 14, 2), - - /* 0100 0110 ... */ - /* 00 */ V(14, 1, 2), /* 252 */ - /* 01 */ V(5, 13, 2), - /* 10 */ V(13, 5, 2), - /* 11 */ V(7, 12, 2), - - /* 0100 0111 ... */ - /* 00 */ V(12, 7, 2), /* 256 */ - /* 01 */ V(4, 13, 2), - /* 10 */ V(8, 11, 2), - /* 11 */ V(11, 8, 2), - - /* 0100 1000 ... */ - /* 00 */ V(13, 4, 2), /* 260 */ - /* 01 */ V(9, 10, 2), - /* 10 */ V(10, 9, 2), - /* 11 */ V(6, 12, 2), - - /* 0100 1001 ... */ - /* 00 */ V(12, 6, 2), /* 264 */ - /* 01 */ V(3, 13, 2), - /* 10 */ V(13, 3, 2), - /* 11 */ V(2, 13, 2), - - /* 0100 1010 ... */ - /* 00 */ V(13, 2, 2), /* 268 */ - /* 01 */ V(1, 13, 2), - /* 10 */ V(7, 11, 2), - /* 11 */ V(11, 7, 2), - - /* 0100 1011 ... */ - /* 00 */ V(13, 1, 2), /* 272 */ - /* 01 */ V(5, 12, 2), - /* 10 */ V(12, 5, 2), - /* 11 */ V(8, 10, 2), - - /* 0100 1100 ... */ - /* 00 */ V(10, 8, 2), /* 276 */ - /* 01 */ V(9, 9, 2), - /* 10 */ V(4, 12, 2), - /* 11 */ V(12, 4, 2), - - /* 0100 1101 ... */ - /* 000 */ V(6, 11, 2), /* 280 */ - /* 001 */ V(6, 11, 2), - /* 010 */ V(11, 6, 2), - /* 011 */ V(11, 6, 2), - /* 100 */ V(13, 0, 3), - /* 101 */ V(0, 12, 3), - /* 110 */ V(3, 12, 2), - /* 111 */ V(3, 12, 2), - - /* 0100 1110 ... */ - /* 00 */ V(12, 3, 2), /* 288 */ - /* 01 */ V(7, 10, 2), - /* 10 */ V(10, 7, 2), - /* 11 */ V(2, 12, 2), - - /* 0100 1111 ... */ - /* 00 */ V(12, 2, 2), /* 292 */ - /* 01 */ V(5, 11, 2), - /* 10 */ V(11, 5, 2), - /* 11 */ V(1, 12, 2), - - /* 0101 0000 ... */ - /* 00 */ V(8, 9, 2), /* 296 */ - /* 01 */ V(9, 8, 2), - /* 10 */ V(12, 1, 2), - /* 11 */ V(4, 11, 2), - - /* 0101 0001 ... */ - /* 000 */ V(12, 0, 3), /* 300 */ - /* 001 */ V(0, 11, 3), - /* 010 */ V(3, 11, 2), - /* 011 */ V(3, 11, 2), - /* 100 */ V(11, 0, 3), - /* 101 */ V(0, 10, 3), - /* 110 */ V(1, 10, 2), - /* 111 */ V(1, 10, 2), - - /* 0101 0010 ... */ - /* 00 */ V(11, 4, 1), /* 308 */ - /* 01 */ V(11, 4, 1), - /* 10 */ V(6, 10, 2), - /* 11 */ V(10, 6, 2), - - /* 0101 0011 ... */ - /* 000 */ V(7, 9, 2), /* 312 */ - /* 001 */ V(7, 9, 2), - /* 010 */ V(9, 7, 2), - /* 011 */ V(9, 7, 2), - /* 100 */ V(10, 0, 3), - /* 101 */ V(0, 9, 3), - /* 110 */ V(9, 0, 2), - /* 111 */ V(9, 0, 2), - - /* 0101 0100 ... */ - /* 0 */ V(11, 3, 1), /* 320 */ - /* 1 */ V(8, 8, 1), - - /* 0101 0101 ... */ - /* 00 */ V(2, 11, 2), /* 322 */ - /* 01 */ V(5, 10, 2), - /* 10 */ V(11, 2, 1), - /* 11 */ V(11, 2, 1), - - /* 0101 0110 ... */ - /* 00 */ V(10, 5, 2), /* 326 */ - /* 01 */ V(1, 11, 2), - /* 10 */ V(11, 1, 2), - /* 11 */ V(6, 9, 2), - - /* 0101 0111 ... */ - /* 0 */ V(9, 6, 1), /* 330 */ - /* 1 */ V(10, 4, 1), - - /* 0101 1000 ... */ - /* 00 */ V(4, 10, 2), /* 332 */ - /* 01 */ V(7, 8, 2), - /* 10 */ V(8, 7, 1), - /* 11 */ V(8, 7, 1), - - /* 0101 1001 ... */ - /* 0 */ V(3, 10, 1), /* 336 */ - /* 1 */ V(10, 3, 1), - - /* 0101 1010 ... */ - /* 0 */ V(5, 9, 1), /* 338 */ - /* 1 */ V(9, 5, 1), - - /* 0101 1011 ... */ - /* 0 */ V(2, 10, 1), /* 340 */ - /* 1 */ V(10, 2, 1), - - /* 0101 1100 ... */ - /* 0 */ V(10, 1, 1), /* 342 */ - /* 1 */ V(6, 8, 1), - - /* 0101 1101 ... */ - /* 0 */ V(8, 6, 1), /* 344 */ - /* 1 */ V(7, 7, 1), - - /* 0101 1110 ... */ - /* 0 */ V(4, 9, 1), /* 346 */ - /* 1 */ V(9, 4, 1), - - /* 0101 1111 ... */ - /* 0 */ V(3, 9, 1), /* 348 */ - /* 1 */ V(9, 3, 1), - - /* 0110 0000 ... */ - /* 0 */ V(5, 8, 1), /* 350 */ - /* 1 */ V(8, 5, 1), - - /* 0110 0001 ... */ - /* 0 */ V(2, 9, 1), /* 352 */ - /* 1 */ V(6, 7, 1), - - /* 0110 0010 ... */ - /* 0 */ V(7, 6, 1), /* 354 */ - /* 1 */ V(9, 2, 1), - - /* 0110 0011 ... */ - /* 0 */ V(1, 9, 1), /* 356 */ - /* 1 */ V(9, 1, 1), - - /* 0110 0100 ... */ - /* 0 */ V(4, 8, 1), /* 358 */ - /* 1 */ V(8, 4, 1), - - /* 0110 0101 ... */ - /* 0 */ V(5, 7, 1), /* 360 */ - /* 1 */ V(7, 5, 1), - - /* 0110 0110 ... */ - /* 0 */ V(3, 8, 1), /* 362 */ - /* 1 */ V(8, 3, 1), - - /* 0110 0111 ... */ - /* 0 */ V(6, 6, 1), /* 364 */ - /* 1 */ V(2, 8, 1), - - /* 0110 1000 ... */ - /* 0 */ V(8, 2, 1), /* 366 */ - /* 1 */ V(1, 8, 1), - - /* 0110 1001 ... */ - /* 0 */ V(4, 7, 1), /* 368 */ - /* 1 */ V(7, 4, 1), - - /* 0110 1010 ... */ - /* 00 */ V(8, 1, 1), /* 370 */ - /* 01 */ V(8, 1, 1), - /* 10 */ V(0, 8, 2), - /* 11 */ V(8, 0, 2), - - /* 0110 1011 ... */ - /* 0 */ V(5, 6, 1), /* 374 */ - /* 1 */ V(6, 5, 1), - - /* 0110 1100 ... */ - /* 00 */ V(1, 7, 1), /* 376 */ - /* 01 */ V(1, 7, 1), - /* 10 */ V(0, 7, 2), - /* 11 */ V(7, 0, 2), - - /* 0110 1110 ... */ - /* 0 */ V(3, 7, 1), /* 380 */ - /* 1 */ V(2, 7, 1), - - /* 0111 1100 ... */ - /* 0 */ V(0, 6, 1), /* 382 */ - /* 1 */ V(6, 0, 1), - - /* 1000 0011 ... */ - /* 0 */ V(0, 5, 1), /* 384 */ - /* 1 */ V(5, 0, 1) -}; - -# undef V -# undef PTR - -/* external tables */ - -union huffquad const *const mad_huff_quad_table[2] = { hufftabA, hufftabB }; - -struct hufftable const mad_huff_pair_table[32] = { - /* 0 */ { hufftab0, 0, 0 }, - /* 1 */ { hufftab1, 0, 3 }, - /* 2 */ { hufftab2, 0, 3 }, - /* 3 */ { hufftab3, 0, 3 }, - /* 4 */ { 0 /* not used */ }, - /* 5 */ { hufftab5, 0, 3 }, - /* 6 */ { hufftab6, 0, 4 }, - /* 7 */ { hufftab7, 0, 4 }, - /* 8 */ { hufftab8, 0, 4 }, - /* 9 */ { hufftab9, 0, 4 }, - /* 10 */ { hufftab10, 0, 4 }, - /* 11 */ { hufftab11, 0, 4 }, - /* 12 */ { hufftab12, 0, 4 }, - /* 13 */ { hufftab13, 0, 4 }, - /* 14 */ { 0 /* not used */ }, - /* 15 */ { hufftab15, 0, 4 }, - /* 16 */ { hufftab16, 1, 4 }, - /* 17 */ { hufftab16, 2, 4 }, - /* 18 */ { hufftab16, 3, 4 }, - /* 19 */ { hufftab16, 4, 4 }, - /* 20 */ { hufftab16, 6, 4 }, - /* 21 */ { hufftab16, 8, 4 }, - /* 22 */ { hufftab16, 10, 4 }, - /* 23 */ { hufftab16, 13, 4 }, - /* 24 */ { hufftab24, 4, 4 }, - /* 25 */ { hufftab24, 5, 4 }, - /* 26 */ { hufftab24, 6, 4 }, - /* 27 */ { hufftab24, 7, 4 }, - /* 28 */ { hufftab24, 8, 4 }, - /* 29 */ { hufftab24, 9, 4 }, - /* 30 */ { hufftab24, 11, 4 }, - /* 31 */ { hufftab24, 13, 4 } -}; diff --git a/lib-src/libmad/huffman.h b/lib-src/libmad/huffman.h deleted file mode 100644 index d4b5fccd5..000000000 --- a/lib-src/libmad/huffman.h +++ /dev/null @@ -1,66 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: huffman.h,v 1.4 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_HUFFMAN_H -# define LIBMAD_HUFFMAN_H - -union huffquad { - struct { - unsigned short final : 1; - unsigned short bits : 3; - unsigned short offset : 12; - } ptr; - struct { - unsigned short final : 1; - unsigned short hlen : 3; - unsigned short v : 1; - unsigned short w : 1; - unsigned short x : 1; - unsigned short y : 1; - } value; - unsigned short final : 1; -}; - -union huffpair { - struct { - unsigned short final : 1; - unsigned short bits : 3; - unsigned short offset : 12; - } ptr; - struct { - unsigned short final : 1; - unsigned short hlen : 3; - unsigned short x : 4; - unsigned short y : 4; - } value; - unsigned short final : 1; -}; - -struct hufftable { - union huffpair const *table; - unsigned short linbits; - unsigned short startbits; -}; - -extern union huffquad const *const mad_huff_quad_table[2]; -extern struct hufftable const mad_huff_pair_table[32]; - -# endif diff --git a/lib-src/libmad/imdct_l_arm.S b/lib-src/libmad/imdct_l_arm.S deleted file mode 100644 index 742be89fb..000000000 --- a/lib-src/libmad/imdct_l_arm.S +++ /dev/null @@ -1,1000 +0,0 @@ -/***************************************************************************** -* Copyright (C) 2000-2001 Andre McCurdy -* -* This program is free software. you can redistribute it and/or modify -* it under the terms of the GNU General Public License as published by -* the Free Software Foundation@ either version 2 of the License, or -* (at your option) any later version. -* -* This program is distributed in the hope that it will be useful, -* but WITHOUT ANY WARRANTY, without even the implied warranty of -* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -* GNU General Public License for more details. -* -* You should have received a copy of the GNU General Public License -* along with this program@ if not, write to the Free Software -* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -* -***************************************************************************** -* -* Notes: -* -* -***************************************************************************** -* -* $Id: imdct_l_arm.S,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ -* -* 2001/03/24: Andre McCurdy -* - Corrected PIC unsafe loading of address of 'imdct36_long_karray' -* -* 2000/09/20: Robert Leslie -* - Added a global symbol with leading underscore per suggestion of -* Simon Burge to support linking with the a.out format. -* -* 2000/09/15: Robert Leslie -* - Fixed a small bug where flags were changed before a conditional branch. -* -* 2000/09/15: Andre McCurdy -* - Applied Nicolas Pitre's rounding optimisation in all remaining places. -* -* 2000/09/09: Nicolas Pitre -* - Optimized rounding + scaling operations. -* -* 2000/08/09: Andre McCurdy -* - Original created. -* -****************************************************************************/ - - -/* - On entry: - - r0 = pointer to 18 element input array - r1 = pointer to 36 element output array - r2 = windowing block type - - - Stack frame created during execution of the function: - - Initial Holds: - Stack - pointer - minus: - - 0 - 4 lr - 8 r11 - 12 r10 - 16 r9 - 20 r8 - 24 r7 - 28 r6 - 32 r5 - 36 r4 - - 40 r2 : windowing block type - - 44 ct00 high - 48 ct00 low - 52 ct01 high - 56 ct01 low - 60 ct04 high - 64 ct04 low - 68 ct06 high - 72 ct06 low - 76 ct05 high - 80 ct05 low - 84 ct03 high - 88 ct03 low - 92 -ct05 high - 96 -ct05 low - 100 -ct07 high - 104 -ct07 low - 108 ct07 high - 112 ct07 low - 116 ct02 high - 120 ct02 low -*/ - -#define BLOCK_MODE_NORMAL 0 -#define BLOCK_MODE_START 1 -#define BLOCK_MODE_STOP 3 - - -#define X0 0x00 -#define X1 0x04 -#define X2 0x08 -#define X3 0x0C -#define X4 0x10 -#define X5 0x14 -#define X6 0x18 -#define X7 0x1c -#define X8 0x20 -#define X9 0x24 -#define X10 0x28 -#define X11 0x2c -#define X12 0x30 -#define X13 0x34 -#define X14 0x38 -#define X15 0x3c -#define X16 0x40 -#define X17 0x44 - -#define x0 0x00 -#define x1 0x04 -#define x2 0x08 -#define x3 0x0C -#define x4 0x10 -#define x5 0x14 -#define x6 0x18 -#define x7 0x1c -#define x8 0x20 -#define x9 0x24 -#define x10 0x28 -#define x11 0x2c -#define x12 0x30 -#define x13 0x34 -#define x14 0x38 -#define x15 0x3c -#define x16 0x40 -#define x17 0x44 -#define x18 0x48 -#define x19 0x4c -#define x20 0x50 -#define x21 0x54 -#define x22 0x58 -#define x23 0x5c -#define x24 0x60 -#define x25 0x64 -#define x26 0x68 -#define x27 0x6c -#define x28 0x70 -#define x29 0x74 -#define x30 0x78 -#define x31 0x7c -#define x32 0x80 -#define x33 0x84 -#define x34 0x88 -#define x35 0x8c - -#define K00 0x0ffc19fd -#define K01 0x00b2aa3e -#define K02 0x0fdcf549 -#define K03 0x0216a2a2 -#define K04 0x0f9ee890 -#define K05 0x03768962 -#define K06 0x0f426cb5 -#define K07 0x04cfb0e2 -#define K08 0x0ec835e8 -#define K09 0x061f78aa -#define K10 0x0e313245 -#define K11 0x07635284 -#define K12 0x0d7e8807 -#define K13 0x0898c779 -#define K14 0x0cb19346 -#define K15 0x09bd7ca0 -#define K16 0x0bcbe352 -#define K17 0x0acf37ad - -#define minus_K02 0xf0230ab7 - -#define WL0 0x00b2aa3e -#define WL1 0x0216a2a2 -#define WL2 0x03768962 -#define WL3 0x04cfb0e2 -#define WL4 0x061f78aa -#define WL5 0x07635284 -#define WL6 0x0898c779 -#define WL7 0x09bd7ca0 -#define WL8 0x0acf37ad -#define WL9 0x0bcbe352 -#define WL10 0x0cb19346 -#define WL11 0x0d7e8807 -#define WL12 0x0e313245 -#define WL13 0x0ec835e8 -#define WL14 0x0f426cb5 -#define WL15 0x0f9ee890 -#define WL16 0x0fdcf549 -#define WL17 0x0ffc19fd - - -@***************************************************************************** - - - .text - .align - - .global III_imdct_l - .global _III_imdct_l - -III_imdct_l: -_III_imdct_l: - - stmdb sp!, { r2, r4 - r11, lr } @ all callee saved regs, plus arg3 - - ldr r4, =K08 @ r4 = K08 - ldr r5, =K09 @ r5 = K09 - ldr r8, [r0, #X4] @ r8 = X4 - ldr r9, [r0, #X13] @ r9 = X13 - rsb r6, r4, #0 @ r6 = -K08 - rsb r7, r5, #0 @ r7 = -K09 - - smull r2, r3, r4, r8 @ r2..r3 = (X4 * K08) - smlal r2, r3, r5, r9 @ r2..r3 = (X4 * K08) + (X13 * K09) = ct01 - - smull r10, lr, r8, r5 @ r10..lr = (X4 * K09) - smlal r10, lr, r9, r6 @ r10..lr = (X4 * K09) + (X13 * -K08) = ct00 - - ldr r8, [r0, #X7] @ r8 = X7 - ldr r9, [r0, #X16] @ r9 = X16 - - stmdb sp!, { r2, r3, r10, lr } @ stack ct00_h, ct00_l, ct01_h, ct01_l - - add r8, r8, r9 @ r8 = (X7 + X16) - ldr r9, [r0, #X1] @ r9 = X1 - - smlal r2, r3, r6, r8 @ r2..r3 = ct01 + ((X7 + X16) * -K08) - smlal r2, r3, r7, r9 @ r2..r3 += (X1 * -K09) - - ldr r7, [r0, #X10] @ r7 = X10 - - rsbs r10, r10, #0 - rsc lr, lr, #0 @ r10..lr = -ct00 - - smlal r2, r3, r5, r7 @ r2..r3 += (X10 * K09) = ct06 - - smlal r10, lr, r9, r6 @ r10..lr = -ct00 + ( X1 * -K08) - smlal r10, lr, r8, r5 @ r10..lr += ((X7 + X16) * K09) - smlal r10, lr, r7, r4 @ r10..lr += ( X10 * K08) = ct04 - - stmdb sp!, { r2, r3, r10, lr } @ stack ct04_h, ct04_l, ct06_h, ct06_l - - @---- - - ldr r7, [r0, #X0] - ldr r8, [r0, #X11] - ldr r9, [r0, #X12] - sub r7, r7, r8 - sub r7, r7, r9 @ r7 = (X0 - X11 -X12) = ct14 - - ldr r9, [r0, #X3] - ldr r8, [r0, #X8] - ldr r11, [r0, #X15] - sub r8, r8, r9 - add r8, r8, r11 @ r8 = (X8 - X3 + X15) = ct16 - - add r11, r7, r8 @ r11 = ct14 + ct16 = ct18 - - smlal r2, r3, r6, r11 @ r2..r3 = ct06 + ((X0 - X11 - X3 + X15 + X8 - X12) * -K08) - - ldr r6, [r0, #X2] - ldr r9, [r0, #X9] - ldr r12, [r0, #X14] - sub r6, r6, r9 - sub r6, r6, r12 @ r6 = (X2 - X9 - X14) = ct15 - - ldr r9, [r0, #X5] - ldr r12, [r0, #X6] - sub r9, r9, r12 - ldr r12, [r0, #X17] - sub r9, r9, r12 @ r9 = (X5 - X6 - X17) = ct17 - - add r12, r9, r6 @ r12 = ct15 + ct17 = ct19 - - smlal r2, r3, r5, r12 @ r2..r3 += ((X2 - X9 + X5 - X6 - X17 - X14) * K09) - - smlal r10, lr, r11, r5 @ r10..lr = ct04 + (ct18 * K09) - smlal r10, lr, r12, r4 @ r10..lr = ct04 + (ct18 * K09) + (ct19 * K08) - - movs r2, r2, lsr #28 - adc r2, r2, r3, lsl #4 @ r2 = bits[59..28] of r2..r3 - str r2, [r1, #x22] @ store result x22 - - movs r10, r10, lsr #28 - adc r10, r10, lr, lsl #4 @ r10 = bits[59..28] of r10..lr - str r10, [r1, #x4] @ store result x4 - - @---- - - ldmia sp, { r2, r3, r4, r5 } @ r2..r3 = ct06, r4..r5 = ct04 (dont update sp) - - @ r2..r3 = ct06 - @ r4..r5 = ct04 - @ r6 = ct15 - @ r7 = ct14 - @ r8 = ct16 - @ r9 = ct17 - @ r10 = . - @ r11 = . - @ r12 = . - @ lr = . - - ldr r10, =K03 @ r10 = K03 - ldr lr, =K15 @ lr = K15 - - smlal r2, r3, r10, r7 @ r2..r3 = ct06 + (ct14 * K03) - smlal r4, r5, lr, r7 @ r4..r5 = ct04 + (ct14 * K15) - - ldr r12, =K14 @ r12 = K14 - rsb r10, r10, #0 @ r10 = -K03 - - smlal r2, r3, lr, r6 @ r2..r3 += (ct15 * K15) - smlal r4, r5, r10, r6 @ r4..r5 += (ct15 * -K03) - smlal r2, r3, r12, r8 @ r2..r3 += (ct16 * K14) - - ldr r11, =minus_K02 @ r11 = -K02 - rsb r12, r12, #0 @ r12 = -K14 - - smlal r4, r5, r12, r9 @ r4..r5 += (ct17 * -K14) - smlal r2, r3, r11, r9 @ r2..r3 += (ct17 * -K02) - smlal r4, r5, r11, r8 @ r4..r5 += (ct16 * -K02) - - movs r2, r2, lsr #28 - adc r2, r2, r3, lsl #4 @ r2 = bits[59..28] of r2..r3 - str r2, [r1, #x7] @ store result x7 - - movs r4, r4, lsr #28 - adc r4, r4, r5, lsl #4 @ r4 = bits[59..28] of r4..r5 - str r4, [r1, #x1] @ store result x1 - - @---- - - ldmia sp, { r2, r3, r4, r5 } @ r2..r3 = ct06, r4..r5 = ct04 (dont update sp) - - @ r2..r3 = ct06 - @ r4..r5 = ct04 - @ r6 = ct15 - @ r7 = ct14 - @ r8 = ct16 - @ r9 = ct17 - @ r10 = -K03 - @ r11 = -K02 - @ r12 = -K14 - @ lr = K15 - - rsbs r2, r2, #0 - rsc r3, r3, #0 @ r2..r3 = -ct06 - - smlal r2, r3, r12, r7 @ r2..r3 = -ct06 + (ct14 * -K14) - smlal r2, r3, r10, r8 @ r2..r3 += (ct16 * -K03) - - smlal r4, r5, r12, r6 @ r4..r5 = ct04 + (ct15 * -K14) - smlal r4, r5, r10, r9 @ r4..r5 += (ct17 * -K03) - smlal r4, r5, lr, r8 @ r4..r5 += (ct16 * K15) - smlal r4, r5, r11, r7 @ r4..r5 += (ct14 * -K02) - - rsb lr, lr, #0 @ lr = -K15 - rsb r11, r11, #0 @ r11 = K02 - - smlal r2, r3, lr, r9 @ r2..r3 += (ct17 * -K15) - smlal r2, r3, r11, r6 @ r2..r3 += (ct15 * K02) - - movs r4, r4, lsr #28 - adc r4, r4, r5, lsl #4 @ r4 = bits[59..28] of r4..r5 - str r4, [r1, #x25] @ store result x25 - - movs r2, r2, lsr #28 - adc r2, r2, r3, lsl #4 @ r2 = bits[59..28] of r2..r3 - str r2, [r1, #x19] @ store result x19 - - @---- - - ldr r2, [sp, #16] @ r2 = ct01_l - ldr r3, [sp, #20] @ r3 = ct01_h - - ldr r6, [r0, #X1] - ldr r8, [r0, #X7] - ldr r9, [r0, #X10] - ldr r7, [r0, #X16] - - rsbs r2, r2, #0 - rsc r3, r3, #0 @ r2..r3 = -ct01 - - mov r4, r2 - mov r5, r3 @ r4..r5 = -ct01 - - @ r2..r3 = -ct01 - @ r4..r5 = -ct01 - @ r6 = X1 - @ r7 = X16 - @ r8 = X7 - @ r9 = X10 - @ r10 = -K03 - @ r11 = K02 - @ r12 = -K14 - @ lr = -K15 - - smlal r4, r5, r12, r7 @ r4..r5 = -ct01 + (X16 * -K14) - smlal r2, r3, lr, r9 @ r2..r3 = -ct01 + (X10 * -K15) - - smlal r4, r5, r10, r8 @ r4..r5 += (X7 * -K03) - smlal r2, r3, r10, r7 @ r2..r3 += (X16 * -K03) - - smlal r4, r5, r11, r9 @ r4..r5 += (X10 * K02) - smlal r2, r3, r12, r8 @ r2..r3 += (X7 * -K14) - - rsb lr, lr, #0 @ lr = K15 - rsb r11, r11, #0 @ r11 = -K02 - - smlal r4, r5, lr, r6 @ r4..r5 += (X1 * K15) = ct05 - smlal r2, r3, r11, r6 @ r2..r3 += (X1 * -K02) = ct03 - - stmdb sp!, { r2, r3, r4, r5 } @ stack ct05_h, ct05_l, ct03_h, ct03_l - - rsbs r4, r4, #0 - rsc r5, r5, #0 @ r4..r5 = -ct05 - - stmdb sp!, { r4, r5 } @ stack -ct05_h, -ct05_l - - ldr r2, [sp, #48] @ r2 = ct00_l - ldr r3, [sp, #52] @ r3 = ct00_h - - rsb r10, r10, #0 @ r10 = K03 - - rsbs r4, r2, #0 - rsc r5, r3, #0 @ r4..r5 = -ct00 - - @ r2..r3 = ct00 - @ r4..r5 = -ct00 - @ r6 = X1 - @ r7 = X16 - @ r8 = X7 - @ r9 = X10 - @ r10 = K03 - @ r11 = -K02 - @ r12 = -K14 - @ lr = K15 - - smlal r4, r5, r10, r6 @ r4..r5 = -ct00 + (X1 * K03) - smlal r2, r3, r10, r9 @ r2..r3 = ct00 + (X10 * K03) - - smlal r4, r5, r12, r9 @ r4..r5 += (X10 * -K14) - smlal r2, r3, r12, r6 @ r2..r3 += (X1 * -K14) - - smlal r4, r5, r11, r7 @ r4..r5 += (X16 * -K02) - smlal r4, r5, lr, r8 @ r4..r5 += (X7 * K15) = ct07 - - rsb lr, lr, #0 @ lr = -K15 - rsb r11, r11, #0 @ r11 = K02 - - smlal r2, r3, r11, r8 @ r2..r3 += (X7 * K02) - smlal r2, r3, lr, r7 @ r2..r3 += (X16 * -K15) = ct02 - - rsbs r6, r4, #0 - rsc r7, r5, #0 @ r6..r7 = -ct07 - - stmdb sp!, { r2 - r7 } @ stack -ct07_h, -ct07_l, ct07_h, ct07_l, ct02_h, ct02_l - - - @---- - - add r2, pc, #(imdct36_long_karray-.-8) @ r2 = base address of Knn array (PIC safe ?) - - -loop: - ldr r12, [r0, #X0] - - ldmia r2!, { r5 - r11 } @ first 7 words from Karray element - - smull r3, r4, r5, r12 @ sum = (Kxx * X0) - ldr r12, [r0, #X2] - ldr r5, [r0, #X3] - smlal r3, r4, r6, r12 @ sum += (Kxx * X2) - ldr r12, [r0, #X5] - ldr r6, [r0, #X6] - smlal r3, r4, r7, r5 @ sum += (Kxx * X3) - smlal r3, r4, r8, r12 @ sum += (Kxx * X5) - ldr r12, [r0, #X8] - ldr r5, [r0, #X9] - smlal r3, r4, r9, r6 @ sum += (Kxx * X6) - smlal r3, r4, r10, r12 @ sum += (Kxx * X8) - smlal r3, r4, r11, r5 @ sum += (Kxx * X9) - - ldmia r2!, { r5 - r10 } @ final 6 words from Karray element - - ldr r11, [r0, #X11] - ldr r12, [r0, #X12] - smlal r3, r4, r5, r11 @ sum += (Kxx * X11) - ldr r11, [r0, #X14] - ldr r5, [r0, #X15] - smlal r3, r4, r6, r12 @ sum += (Kxx * X12) - smlal r3, r4, r7, r11 @ sum += (Kxx * X14) - ldr r11, [r0, #X17] - smlal r3, r4, r8, r5 @ sum += (Kxx * X15) - smlal r3, r4, r9, r11 @ sum += (Kxx * X17) - - add r5, sp, r10, lsr #16 @ create index back into stack for required ctxx - - ldmia r5, { r6, r7 } @ r6..r7 = ctxx - - mov r8, r10, lsl #16 @ push ctxx index off the top end - - adds r3, r3, r6 @ add low words - adc r4, r4, r7 @ add high words, with carry - movs r3, r3, lsr #28 - adc r3, r3, r4, lsl #4 @ r3 = bits[59..28] of r3..r4 - - str r3, [r1, r8, lsr #24] @ push completion flag off the bottom end - - movs r8, r8, lsl #8 @ push result location index off the top end - beq loop @ loop back if completion flag not set - b imdct_l_windowing @ branch to windowing stage if looping finished - -imdct36_long_karray: - - .word K17, -K13, K10, -K06, -K05, K01, -K00, K04, -K07, K11, K12, -K16, 0x00000000 - .word K13, K07, K16, K01, K10, -K05, K04, -K11, K00, -K17, K06, -K12, 0x00200800 - .word K11, K17, K05, K12, -K01, K06, -K07, K00, -K13, K04, -K16, K10, 0x00200c00 - .word K07, K00, -K12, K05, -K16, -K10, K11, -K17, K04, K13, K01, K06, 0x00001400 - .word K05, K10, -K00, -K17, K07, -K13, K12, K06, -K16, K01, -K11, -K04, 0x00181800 - .word K01, K05, -K07, -K11, K13, K17, -K16, -K12, K10, K06, -K04, -K00, 0x00102000 - .word -K16, K12, -K11, K07, K04, -K00, -K01, K05, -K06, K10, K13, -K17, 0x00284800 - .word -K12, K06, K17, -K00, -K11, K04, K05, -K10, K01, K16, -K07, -K13, 0x00085000 - .word -K10, K16, K04, -K13, -K00, K07, K06, -K01, -K12, -K05, K17, K11, 0x00105400 - .word -K06, -K01, K13, K04, K17, -K11, -K10, -K16, -K05, K12, K00, K07, 0x00185c00 - .word -K04, -K11, -K01, K16, K06, K12, K13, -K07, -K17, -K00, -K10, -K05, 0x00006000 - .word -K00, -K04, -K06, -K10, -K12, -K16, -K17, -K13, -K11, -K07, -K05, -K01, 0x00206801 - - - @---- - @------------------------------------------------------------------------- - @---- - -imdct_l_windowing: - - ldr r11, [sp, #80] @ fetch function parameter 3 from out of the stack - ldmia r1!, { r0, r2 - r9 } @ load 9 words from x0, update pointer - - @ r0 = x0 - @ r1 = &x[9] - @ r2 = x1 - @ r3 = x2 - @ r4 = x3 - @ r5 = x4 - @ r6 = x5 - @ r7 = x6 - @ r8 = x7 - @ r9 = x8 - @ r10 = . - @ r11 = window mode: (0 == normal), (1 == start block), (3 == stop block) - @ r12 = . - @ lr = . - - cmp r11, #BLOCK_MODE_STOP @ setup flags - rsb r10, r0, #0 @ r10 = -x0 (DONT change flags !!) - beq stop_block_x0_to_x17 - - - @ start and normal blocks are treated the same for x[0]..x[17] - -normal_block_x0_to_x17: - - ldr r12, =WL9 @ r12 = window_l[9] - - rsb r0, r9, #0 @ r0 = -x8 - rsb r9, r2, #0 @ r9 = -x1 - rsb r2, r8, #0 @ r2 = -x7 - rsb r8, r3, #0 @ r8 = -x2 - rsb r3, r7, #0 @ r3 = -x6 - rsb r7, r4, #0 @ r7 = -x3 - rsb r4, r6, #0 @ r4 = -x5 - rsb r6, r5, #0 @ r6 = -x4 - - @ r0 = -x8 - @ r1 = &x[9] - @ r2 = -x7 - @ r3 = -x6 - @ r4 = -x5 - @ r5 = . - @ r6 = -x4 - @ r7 = -x3 - @ r8 = -x2 - @ r9 = -x1 - @ r10 = -x0 - @ r11 = window mode: (0 == normal), (1 == start block), (3 == stop block) - @ r12 = window_l[9] - @ lr = . - - smull r5, lr, r12, r0 @ r5..lr = (window_l[9] * (x[9] == -x[8])) - ldr r12, =WL10 @ r12 = window_l[10] - movs r5, r5, lsr #28 - adc r0, r5, lr, lsl #4 @ r0 = bits[59..28] of windowed x9 - - smull r5, lr, r12, r2 @ r5..lr = (window_l[10] * (x[10] == -x[7])) - ldr r12, =WL11 @ r12 = window_l[11] - movs r5, r5, lsr #28 - adc r2, r5, lr, lsl #4 @ r2 = bits[59..28] of windowed x10 - - smull r5, lr, r12, r3 @ r5..lr = (window_l[11] * (x[11] == -x[6])) - ldr r12, =WL12 @ r12 = window_l[12] - movs r5, r5, lsr #28 - adc r3, r5, lr, lsl #4 @ r3 = bits[59..28] of windowed x11 - - smull r5, lr, r12, r4 @ r5..lr = (window_l[12] * (x[12] == -x[5])) - ldr r12, =WL13 @ r12 = window_l[13] - movs r5, r5, lsr #28 - adc r4, r5, lr, lsl #4 @ r4 = bits[59..28] of windowed x12 - - smull r5, lr, r12, r6 @ r5..lr = (window_l[13] * (x[13] == -x[4])) - ldr r12, =WL14 @ r12 = window_l[14] - movs r5, r5, lsr #28 - adc r6, r5, lr, lsl #4 @ r6 = bits[59..28] of windowed x13 - - smull r5, lr, r12, r7 @ r5..lr = (window_l[14] * (x[14] == -x[3])) - ldr r12, =WL15 @ r12 = window_l[15] - movs r5, r5, lsr #28 - adc r7, r5, lr, lsl #4 @ r7 = bits[59..28] of windowed x14 - - smull r5, lr, r12, r8 @ r5..lr = (window_l[15] * (x[15] == -x[2])) - ldr r12, =WL16 @ r12 = window_l[16] - movs r5, r5, lsr #28 - adc r8, r5, lr, lsl #4 @ r8 = bits[59..28] of windowed x15 - - smull r5, lr, r12, r9 @ r5..lr = (window_l[16] * (x[16] == -x[1])) - ldr r12, =WL17 @ r12 = window_l[17] - movs r5, r5, lsr #28 - adc r9, r5, lr, lsl #4 @ r9 = bits[59..28] of windowed x16 - - smull r5, lr, r12, r10 @ r5..lr = (window_l[17] * (x[17] == -x[0])) - ldr r12, =WL0 @ r12 = window_l[0] - movs r5, r5, lsr #28 - adc r10, r5, lr, lsl #4 @ r10 = bits[59..28] of windowed x17 - - - stmia r1, { r0, r2 - r4, r6 - r10 } @ store windowed x[9] .. x[17] - ldmdb r1!, { r0, r2 - r9 } @ load 9 words downto (and including) x0 - - - smull r10, lr, r12, r0 @ r10..lr = (window_l[0] * x[0]) - ldr r12, =WL1 @ r12 = window_l[1] - movs r10, r10, lsr #28 - adc r0, r10, lr, lsl #4 @ r0 = bits[59..28] of windowed x0 - - smull r10, lr, r12, r2 @ r10..lr = (window_l[1] * x[1]) - ldr r12, =WL2 @ r12 = window_l[2] - movs r10, r10, lsr #28 - adc r2, r10, lr, lsl #4 @ r2 = bits[59..28] of windowed x1 - - smull r10, lr, r12, r3 @ r10..lr = (window_l[2] * x[2]) - ldr r12, =WL3 @ r12 = window_l[3] - movs r10, r10, lsr #28 - adc r3, r10, lr, lsl #4 @ r3 = bits[59..28] of windowed x2 - - smull r10, lr, r12, r4 @ r10..lr = (window_l[3] * x[3]) - ldr r12, =WL4 @ r12 = window_l[4] - movs r10, r10, lsr #28 - adc r4, r10, lr, lsl #4 @ r4 = bits[59..28] of windowed x3 - - smull r10, lr, r12, r5 @ r10..lr = (window_l[4] * x[4]) - ldr r12, =WL5 @ r12 = window_l[5] - movs r10, r10, lsr #28 - adc r5, r10, lr, lsl #4 @ r5 = bits[59..28] of windowed x4 - - smull r10, lr, r12, r6 @ r10..lr = (window_l[5] * x[5]) - ldr r12, =WL6 @ r12 = window_l[6] - movs r10, r10, lsr #28 - adc r6, r10, lr, lsl #4 @ r6 = bits[59..28] of windowed x5 - - smull r10, lr, r12, r7 @ r10..lr = (window_l[6] * x[6]) - ldr r12, =WL7 @ r12 = window_l[7] - movs r10, r10, lsr #28 - adc r7, r10, lr, lsl #4 @ r7 = bits[59..28] of windowed x6 - - smull r10, lr, r12, r8 @ r10..lr = (window_l[7] * x[7]) - ldr r12, =WL8 @ r12 = window_l[8] - movs r10, r10, lsr #28 - adc r8, r10, lr, lsl #4 @ r8 = bits[59..28] of windowed x7 - - smull r10, lr, r12, r9 @ r10..lr = (window_l[8] * x[8]) - movs r10, r10, lsr #28 - adc r9, r10, lr, lsl #4 @ r9 = bits[59..28] of windowed x8 - - stmia r1, { r0, r2 - r9 } @ store windowed x[0] .. x[8] - - cmp r11, #BLOCK_MODE_START - beq start_block_x18_to_x35 - - - @---- - - -normal_block_x18_to_x35: - - ldr r11, =WL3 @ r11 = window_l[3] - ldr r12, =WL4 @ r12 = window_l[4] - - add r1, r1, #(18*4) @ r1 = &x[18] - - ldmia r1!, { r0, r2 - r4, r6 - r10 } @ load 9 words from x18, update pointer - - @ r0 = x18 - @ r1 = &x[27] - @ r2 = x19 - @ r3 = x20 - @ r4 = x21 - @ r5 = . - @ r6 = x22 - @ r7 = x23 - @ r8 = x24 - @ r9 = x25 - @ r10 = x26 - @ r11 = window_l[3] - @ r12 = window_l[4] - @ lr = . - - smull r5, lr, r12, r6 @ r5..lr = (window_l[4] * (x[22] == x[31])) - movs r5, r5, lsr #28 - adc r5, r5, lr, lsl #4 @ r5 = bits[59..28] of windowed x31 - - smull r6, lr, r11, r4 @ r5..lr = (window_l[3] * (x[21] == x[32])) - ldr r12, =WL5 @ r12 = window_l[5] - movs r6, r6, lsr #28 - adc r6, r6, lr, lsl #4 @ r6 = bits[59..28] of windowed x32 - - smull r4, lr, r12, r7 @ r4..lr = (window_l[5] * (x[23] == x[30])) - ldr r11, =WL1 @ r11 = window_l[1] - ldr r12, =WL2 @ r12 = window_l[2] - movs r4, r4, lsr #28 - adc r4, r4, lr, lsl #4 @ r4 = bits[59..28] of windowed x30 - - smull r7, lr, r12, r3 @ r7..lr = (window_l[2] * (x[20] == x[33])) - ldr r12, =WL6 @ r12 = window_l[6] - movs r7, r7, lsr #28 - adc r7, r7, lr, lsl #4 @ r7 = bits[59..28] of windowed x33 - - smull r3, lr, r12, r8 @ r3..lr = (window_l[6] * (x[24] == x[29])) - movs r3, r3, lsr #28 - adc r3, r3, lr, lsl #4 @ r3 = bits[59..28] of windowed x29 - - smull r8, lr, r11, r2 @ r7..lr = (window_l[1] * (x[19] == x[34])) - ldr r12, =WL7 @ r12 = window_l[7] - ldr r11, =WL8 @ r11 = window_l[8] - movs r8, r8, lsr #28 - adc r8, r8, lr, lsl #4 @ r8 = bits[59..28] of windowed x34 - - smull r2, lr, r12, r9 @ r7..lr = (window_l[7] * (x[25] == x[28])) - ldr r12, =WL0 @ r12 = window_l[0] - movs r2, r2, lsr #28 - adc r2, r2, lr, lsl #4 @ r2 = bits[59..28] of windowed x28 - - smull r9, lr, r12, r0 @ r3..lr = (window_l[0] * (x[18] == x[35])) - movs r9, r9, lsr #28 - adc r9, r9, lr, lsl #4 @ r9 = bits[59..28] of windowed x35 - - smull r0, lr, r11, r10 @ r7..lr = (window_l[8] * (x[26] == x[27])) - ldr r11, =WL16 @ r11 = window_l[16] - ldr r12, =WL17 @ r12 = window_l[17] - movs r0, r0, lsr #28 - adc r0, r0, lr, lsl #4 @ r0 = bits[59..28] of windowed x27 - - - stmia r1, { r0, r2 - r9 } @ store windowed x[27] .. x[35] - ldmdb r1!, { r0, r2 - r9 } @ load 9 words downto (and including) x18 - - - smull r10, lr, r12, r0 @ r10..lr = (window_l[17] * x[18]) - movs r10, r10, lsr #28 - adc r0, r10, lr, lsl #4 @ r0 = bits[59..28] of windowed x0 - - smull r10, lr, r11, r2 @ r10..lr = (window_l[16] * x[19]) - ldr r11, =WL14 @ r11 = window_l[14] - ldr r12, =WL15 @ r12 = window_l[15] - movs r10, r10, lsr #28 - adc r2, r10, lr, lsl #4 @ r2 = bits[59..28] of windowed x1 - - smull r10, lr, r12, r3 @ r10..lr = (window_l[15] * x[20]) - movs r10, r10, lsr #28 - adc r3, r10, lr, lsl #4 @ r3 = bits[59..28] of windowed x2 - - smull r10, lr, r11, r4 @ r10..lr = (window_l[14] * x[21]) - ldr r11, =WL12 @ r11 = window_l[12] - ldr r12, =WL13 @ r12 = window_l[13] - movs r10, r10, lsr #28 - adc r4, r10, lr, lsl #4 @ r4 = bits[59..28] of windowed x3 - - smull r10, lr, r12, r5 @ r10..lr = (window_l[13] * x[22]) - movs r10, r10, lsr #28 - adc r5, r10, lr, lsl #4 @ r5 = bits[59..28] of windowed x4 - - smull r10, lr, r11, r6 @ r10..lr = (window_l[12] * x[23]) - ldr r11, =WL10 @ r12 = window_l[10] - ldr r12, =WL11 @ r12 = window_l[11] - movs r10, r10, lsr #28 - adc r6, r10, lr, lsl #4 @ r6 = bits[59..28] of windowed x5 - - smull r10, lr, r12, r7 @ r10..lr = (window_l[11] * x[24]) - movs r10, r10, lsr #28 - adc r7, r10, lr, lsl #4 @ r7 = bits[59..28] of windowed x6 - - smull r10, lr, r11, r8 @ r10..lr = (window_l[10] * x[25]) - ldr r12, =WL9 @ r12 = window_l[9] - movs r10, r10, lsr #28 - adc r8, r10, lr, lsl #4 @ r8 = bits[59..28] of windowed x7 - - smull r10, lr, r12, r9 @ r10..lr = (window_l[9] * x[26]) - - movs r10, r10, lsr #28 - adc r9, r10, lr, lsl #4 @ r9 = bits[59..28] of windowed x8 - - stmia r1, { r0, r2 - r9 } @ store windowed x[18] .. x[26] - - @---- - @ NB there are 2 possible exits from this function - this is only one of them - @---- - - add sp, sp, #(21*4) @ return stack frame - ldmia sp!, { r4 - r11, pc } @ restore callee saved regs, and return - - @---- - - -stop_block_x0_to_x17: - - @ r0 = x0 - @ r1 = &x[9] - @ r2 = x1 - @ r3 = x2 - @ r4 = x3 - @ r5 = x4 - @ r6 = x5 - @ r7 = x6 - @ r8 = x7 - @ r9 = x8 - @ r10 = -x0 - @ r11 = window mode: (0 == normal), (1 == start block), (3 == stop block) - @ r12 = . - @ lr = . - - rsb r0, r6, #0 @ r0 = -x5 - rsb r6, r2, #0 @ r6 = -x1 - rsb r2, r5, #0 @ r2 = -x4 - rsb r5, r3, #0 @ r5 = -x2 - rsb r3, r4, #0 @ r3 = -x3 - - add r1, r1, #(3*4) @ r1 = &x[12] - stmia r1, { r0, r2, r3, r5, r6, r10 } @ store unchanged x[12] .. x[17] - - ldr r0, =WL1 @ r0 = window_l[1] == window_s[0] - - rsb r10, r9, #0 @ r10 = -x8 - rsb r12, r8, #0 @ r12 = -x7 - rsb lr, r7, #0 @ lr = -x6 - - @ r0 = WL1 - @ r1 = &x[12] - @ r2 = . - @ r3 = . - @ r4 = . - @ r5 = . - @ r6 = . - @ r7 = x6 - @ r8 = x7 - @ r9 = x8 - @ r10 = -x8 - @ r11 = window mode: (0 == normal), (1 == start block), (3 == stop block) - @ r12 = -x7 - @ lr = -x6 - - smull r5, r6, r0, r7 @ r5..r6 = (window_l[1] * x[6]) - ldr r2, =WL4 @ r2 = window_l[4] == window_s[1] - movs r5, r5, lsr #28 - adc r7, r5, r6, lsl #4 @ r7 = bits[59..28] of windowed x6 - - smull r5, r6, r2, r8 @ r5..r6 = (window_l[4] * x[7]) - ldr r3, =WL7 @ r3 = window_l[7] == window_s[2] - movs r5, r5, lsr #28 - adc r8, r5, r6, lsl #4 @ r8 = bits[59..28] of windowed x7 - - smull r5, r6, r3, r9 @ r5..r6 = (window_l[7] * x[8]) - ldr r4, =WL10 @ r4 = window_l[10] == window_s[3] - movs r5, r5, lsr #28 - adc r9, r5, r6, lsl #4 @ r9 = bits[59..28] of windowed x8 - - smull r5, r6, r4, r10 @ r5..r6 = (window_l[10] * (x[9] == -x[8])) - ldr r0, =WL13 @ r0 = window_l[13] == window_s[4] - movs r5, r5, lsr #28 - adc r10, r5, r6, lsl #4 @ r10 = bits[59..28] of windowed x9 - - smull r5, r6, r0, r12 @ r5..r6 = (window_l[13] * (x[10] == -x[7])) - ldr r2, =WL16 @ r2 = window_l[16] == window_s[5] - movs r5, r5, lsr #28 - adc r12, r5, r6, lsl #4 @ r10 = bits[59..28] of windowed x9 - - smull r5, r6, r2, lr @ r5..r6 = (window_l[16] * (x[11] == -x[6])) - - ldr r0, =0x00 - - movs r5, r5, lsr #28 - adc lr, r5, r6, lsl #4 @ r10 = bits[59..28] of windowed x9 - - stmdb r1!, { r7 - r10, r12, lr } @ store windowed x[6] .. x[11] - - ldr r5, =0x00 - ldr r6, =0x00 - ldr r2, =0x00 - ldr r3, =0x00 - ldr r4, =0x00 - - stmdb r1!, { r0, r2 - r6 } @ store windowed x[0] .. x[5] - - b normal_block_x18_to_x35 - - - @---- - - -start_block_x18_to_x35: - - ldr r4, =WL1 @ r0 = window_l[1] == window_s[0] - - add r1, r1, #(24*4) @ r1 = &x[24] - - ldmia r1, { r0, r2, r3 } @ load 3 words from x24, dont update pointer - - @ r0 = x24 - @ r1 = &x[24] - @ r2 = x25 - @ r3 = x26 - @ r4 = WL1 - @ r5 = WL4 - @ r6 = WL7 - @ r7 = WL10 - @ r8 = WL13 - @ r9 = WL16 - @ r10 = . - @ r11 = . - @ r12 = . - @ lr = . - - ldr r5, =WL4 @ r5 = window_l[4] == window_s[1] - - smull r10, r11, r4, r0 @ r10..r11 = (window_l[1] * (x[24] == x[29])) - ldr r6, =WL7 @ r6 = window_l[7] == window_s[2] - movs r10, r10, lsr #28 - adc lr, r10, r11, lsl #4 @ lr = bits[59..28] of windowed x29 - - smull r10, r11, r5, r2 @ r10..r11 = (window_l[4] * (x[25] == x[28])) - ldr r7, =WL10 @ r7 = window_l[10] == window_s[3] - movs r10, r10, lsr #28 - adc r12, r10, r11, lsl #4 @ r12 = bits[59..28] of windowed x28 - - smull r10, r11, r6, r3 @ r10..r11 = (window_l[7] * (x[26] == x[27])) - ldr r8, =WL13 @ r8 = window_l[13] == window_s[4] - movs r10, r10, lsr #28 - adc r4, r10, r11, lsl #4 @ r4 = bits[59..28] of windowed x27 - - smull r10, r11, r7, r3 @ r10..r11 = (window_l[10] * x[26]) - ldr r9, =WL16 @ r9 = window_l[16] == window_s[5] - movs r10, r10, lsr #28 - adc r3, r10, r11, lsl #4 @ r3 = bits[59..28] of windowed x26 - - smull r10, r11, r8, r2 @ r10..r11 = (window_l[13] * x[25]) - ldr r5, =0x00 - movs r10, r10, lsr #28 - adc r2, r10, r11, lsl #4 @ r2 = bits[59..28] of windowed x25 - - smull r10, r11, r9, r0 @ r10..r11 = (window_l[16] * x[24]) - ldr r6, =0x00 - movs r10, r10, lsr #28 - adc r0, r10, r11, lsl #4 @ r0 = bits[59..28] of windowed x24 - - stmia r1!, { r0, r2, r3, r4, r12, lr } @ store windowed x[24] .. x[29] - - ldr r7, =0x00 - ldr r8, =0x00 - ldr r9, =0x00 - ldr r10, =0x00 - - stmia r1!, { r5 - r10 } @ store windowed x[30] .. x[35] - - @---- - @ NB there are 2 possible exits from this function - this is only one of them - @---- - - add sp, sp, #(21*4) @ return stack frame - ldmia sp!, { r4 - r11, pc } @ restore callee saved regs, and return - - @---- - @END - @---- - diff --git a/lib-src/libmad/imdct_s.dat b/lib-src/libmad/imdct_s.dat deleted file mode 100644 index 84ff7feed..000000000 --- a/lib-src/libmad/imdct_s.dat +++ /dev/null @@ -1,62 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: imdct_s.dat,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - - /* 0 */ { MAD_F(0x09bd7ca0) /* 0.608761429 */, - -MAD_F(0x0ec835e8) /* -0.923879533 */, - -MAD_F(0x0216a2a2) /* -0.130526192 */, - MAD_F(0x0fdcf549) /* 0.991444861 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - -MAD_F(0x0cb19346) /* -0.793353340 */ }, - - /* 6 */ { -MAD_F(0x0cb19346) /* -0.793353340 */, - MAD_F(0x061f78aa) /* 0.382683432 */, - MAD_F(0x0fdcf549) /* 0.991444861 */, - MAD_F(0x0216a2a2) /* 0.130526192 */, - -MAD_F(0x0ec835e8) /* -0.923879533 */, - -MAD_F(0x09bd7ca0) /* -0.608761429 */ }, - - /* 1 */ { MAD_F(0x061f78aa) /* 0.382683432 */, - -MAD_F(0x0ec835e8) /* -0.923879533 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - MAD_F(0x0ec835e8) /* 0.923879533 */ }, - - /* 7 */ { -MAD_F(0x0ec835e8) /* -0.923879533 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - MAD_F(0x061f78aa) /* 0.382683432 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, - MAD_F(0x061f78aa) /* 0.382683432 */ }, - - /* 2 */ { MAD_F(0x0216a2a2) /* 0.130526192 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - MAD_F(0x09bd7ca0) /* 0.608761429 */, - -MAD_F(0x0cb19346) /* -0.793353340 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, - -MAD_F(0x0fdcf549) /* -0.991444861 */ }, - - /* 8 */ { -MAD_F(0x0fdcf549) /* -0.991444861 */, - -MAD_F(0x0ec835e8) /* -0.923879533 */, - -MAD_F(0x0cb19346) /* -0.793353340 */, - -MAD_F(0x09bd7ca0) /* -0.608761429 */, - -MAD_F(0x061f78aa) /* -0.382683432 */, - -MAD_F(0x0216a2a2) /* -0.130526192 */ } diff --git a/lib-src/libmad/install-sh b/lib-src/libmad/install-sh deleted file mode 100755 index 377bb8687..000000000 --- a/lib-src/libmad/install-sh +++ /dev/null @@ -1,527 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2011-11-20.07; # UTC - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# 'make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. - -nl=' -' -IFS=" "" $nl" - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit=${DOITPROG-} -if test -z "$doit"; then - doit_exec=exec -else - doit_exec=$doit -fi - -# Put in absolute file names if you don't have them in your path; -# or use environment vars. - -chgrpprog=${CHGRPPROG-chgrp} -chmodprog=${CHMODPROG-chmod} -chownprog=${CHOWNPROG-chown} -cmpprog=${CMPPROG-cmp} -cpprog=${CPPROG-cp} -mkdirprog=${MKDIRPROG-mkdir} -mvprog=${MVPROG-mv} -rmprog=${RMPROG-rm} -stripprog=${STRIPPROG-strip} - -posix_glob='?' -initialize_posix_glob=' - test "$posix_glob" != "?" || { - if (set -f) 2>/dev/null; then - posix_glob= - else - posix_glob=: - fi - } -' - -posix_mkdir= - -# Desired mode of installed file. -mode=0755 - -chgrpcmd= -chmodcmd=$chmodprog -chowncmd= -mvcmd=$mvprog -rmcmd="$rmprog -f" -stripcmd= - -src= -dst= -dir_arg= -dst_arg= - -copy_on_change=false -no_target_directory= - -usage="\ -Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: - --help display this help and exit. - --version display version info and exit. - - -c (ignored) - -C install only if different (preserve the last data modification time) - -d create directories instead of installing files. - -g GROUP $chgrpprog installed files to GROUP. - -m MODE $chmodprog installed files to MODE. - -o USER $chownprog installed files to USER. - -s $stripprog installed files. - -t DIRECTORY install into DIRECTORY. - -T report an error if DSTFILE is a directory. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG - RMPROG STRIPPROG -" - -while test $# -ne 0; do - case $1 in - -c) ;; - - -C) copy_on_change=true;; - - -d) dir_arg=true;; - - -g) chgrpcmd="$chgrpprog $2" - shift;; - - --help) echo "$usage"; exit $?;; - - -m) mode=$2 - case $mode in - *' '* | *' '* | *' -'* | *'*'* | *'?'* | *'['*) - echo "$0: invalid mode: $mode" >&2 - exit 1;; - esac - shift;; - - -o) chowncmd="$chownprog $2" - shift;; - - -s) stripcmd=$stripprog;; - - -t) dst_arg=$2 - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - shift;; - - -T) no_target_directory=true;; - - --version) echo "$0 $scriptversion"; exit $?;; - - --) shift - break;; - - -*) echo "$0: invalid option: $1" >&2 - exit 1;; - - *) break;; - esac - shift -done - -if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then - # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dst_arg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dst_arg" - shift # fnord - fi - shift # arg - dst_arg=$arg - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - done -fi - -if test $# -eq 0; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call 'install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -if test -z "$dir_arg"; then - do_exit='(exit $ret); exit $ret' - trap "ret=129; $do_exit" 1 - trap "ret=130; $do_exit" 2 - trap "ret=141; $do_exit" 13 - trap "ret=143; $do_exit" 15 - - # Set umask so as not to create temps with too-generous modes. - # However, 'strip' requires both read and write access to temps. - case $mode in - # Optimize common cases. - *644) cp_umask=133;; - *755) cp_umask=22;; - - *[0-7]) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw='% 200' - fi - cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; - *) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw=,u+rw - fi - cp_umask=$mode$u_plus_rw;; - esac -fi - -for src -do - # Protect names problematic for 'test' and other utilities. - case $src in - -* | [=\(\)!]) src=./$src;; - esac - - if test -n "$dir_arg"; then - dst=$src - dstdir=$dst - test -d "$dstdir" - dstdir_status=$? - else - - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dst_arg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - dst=$dst_arg - - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. - if test -d "$dst"; then - if test -n "$no_target_directory"; then - echo "$0: $dst_arg: Is a directory" >&2 - exit 1 - fi - dstdir=$dst - dst=$dstdir/`basename "$src"` - dstdir_status=0 - else - # Prefer dirname, but fall back on a substitute if dirname fails. - dstdir=` - (dirname "$dst") 2>/dev/null || - expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$dst" : 'X\(//\)[^/]' \| \ - X"$dst" : 'X\(//\)$' \| \ - X"$dst" : 'X\(/\)' \| . 2>/dev/null || - echo X"$dst" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q' - ` - - test -d "$dstdir" - dstdir_status=$? - fi - fi - - obsolete_mkdir_used=false - - if test $dstdir_status != 0; then - case $posix_mkdir in - '') - # Create intermediate dirs using mode 755 as modified by the umask. - # This is like FreeBSD 'install' as of 1997-10-28. - umask=`umask` - case $stripcmd.$umask in - # Optimize common cases. - *[2367][2367]) mkdir_umask=$umask;; - .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; - - *[0-7]) - mkdir_umask=`expr $umask + 22 \ - - $umask % 100 % 40 + $umask % 20 \ - - $umask % 10 % 4 + $umask % 2 - `;; - *) mkdir_umask=$umask,go-w;; - esac - - # With -d, create the new directory with the user-specified mode. - # Otherwise, rely on $mkdir_umask. - if test -n "$dir_arg"; then - mkdir_mode=-m$mode - else - mkdir_mode= - fi - - posix_mkdir=false - case $umask in - *[123567][0-7][0-7]) - # POSIX mkdir -p sets u+wx bits regardless of umask, which - # is incompatible with FreeBSD 'install' when (umask & 300) != 0. - ;; - *) - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 - - if (umask $mkdir_umask && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 - then - if test -z "$dir_arg" || { - # Check for POSIX incompatibilities with -m. - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or - # other-writable bit of parent directory when it shouldn't. - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. - ls_ld_tmpdir=`ls -ld "$tmpdir"` - case $ls_ld_tmpdir in - d????-?r-*) different_mode=700;; - d????-?--*) different_mode=755;; - *) false;; - esac && - $mkdirprog -m$different_mode -p -- "$tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$tmpdir"` - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" - } - } - then posix_mkdir=: - fi - rmdir "$tmpdir/d" "$tmpdir" - else - # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null - fi - trap '' 0;; - esac;; - esac - - if - $posix_mkdir && ( - umask $mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" - ) - then : - else - - # The umask is ridiculous, or mkdir does not conform to POSIX, - # or it failed possibly due to a race condition. Create the - # directory the slow way, step by step, checking for races as we go. - - case $dstdir in - /*) prefix='/';; - [-=\(\)!]*) prefix='./';; - *) prefix='';; - esac - - eval "$initialize_posix_glob" - - oIFS=$IFS - IFS=/ - $posix_glob set -f - set fnord $dstdir - shift - $posix_glob set +f - IFS=$oIFS - - prefixes= - - for d - do - test X"$d" = X && continue - - prefix=$prefix$d - if test -d "$prefix"; then - prefixes= - else - if $posix_mkdir; then - (umask=$mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break - # Don't fail if two instances are running concurrently. - test -d "$prefix" || exit 1 - else - case $prefix in - *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; - *) qprefix=$prefix;; - esac - prefixes="$prefixes '$qprefix'" - fi - fi - prefix=$prefix/ - done - - if test -n "$prefixes"; then - # Don't fail if two instances are running concurrently. - (umask $mkdir_umask && - eval "\$doit_exec \$mkdirprog $prefixes") || - test -d "$dstdir" || exit 1 - obsolete_mkdir_used=true - fi - fi - fi - - if test -n "$dir_arg"; then - { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && - { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || - test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 - else - - # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - - # Copy the file name to the temp name. - (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && - { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && - { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && - - # If -C, don't bother to copy if it wouldn't change the file. - if $copy_on_change && - old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && - new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && - - eval "$initialize_posix_glob" && - $posix_glob set -f && - set X $old && old=:$2:$4:$5:$6 && - set X $new && new=:$2:$4:$5:$6 && - $posix_glob set +f && - - test "$old" = "$new" && - $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 - then - rm -f "$dsttmp" - else - # Rename the file to the real destination. - $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || - - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - { - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - test ! -f "$dst" || - $doit $rmcmd -f "$dst" 2>/dev/null || - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && - { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } - } || - { echo "$0: cannot unlink or rename $dst" >&2 - (exit 1); exit 1 - } - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dst" - } - fi || exit 1 - - trap '' 0 - fi -done - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libmad/layer12.c b/lib-src/libmad/layer12.c deleted file mode 100644 index 8e8deb0b0..000000000 --- a/lib-src/libmad/layer12.c +++ /dev/null @@ -1,536 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: layer12.c,v 1.3 2006-10-19 10:44:19 msmeyer Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# ifdef HAVE_LIMITS_H -# include -# else -# define CHAR_BIT 8 -# endif - -# include "fixed.h" -# include "bit.h" -# include "stream.h" -# include "frame.h" -# include "layer12.h" - -/* - * scalefactor table - * used in both Layer I and Layer II decoding - */ -static -mad_fixed_t const sf_table[64] = { -# include "sf_table.dat" -}; - -/* --- Layer I ------------------------------------------------------------- */ - -/* linear scaling table */ -static -mad_fixed_t const linear_table[14] = { - MAD_F(0x15555555), /* 2^2 / (2^2 - 1) == 1.33333333333333 */ - MAD_F(0x12492492), /* 2^3 / (2^3 - 1) == 1.14285714285714 */ - MAD_F(0x11111111), /* 2^4 / (2^4 - 1) == 1.06666666666667 */ - MAD_F(0x10842108), /* 2^5 / (2^5 - 1) == 1.03225806451613 */ - MAD_F(0x10410410), /* 2^6 / (2^6 - 1) == 1.01587301587302 */ - MAD_F(0x10204081), /* 2^7 / (2^7 - 1) == 1.00787401574803 */ - MAD_F(0x10101010), /* 2^8 / (2^8 - 1) == 1.00392156862745 */ - MAD_F(0x10080402), /* 2^9 / (2^9 - 1) == 1.00195694716243 */ - MAD_F(0x10040100), /* 2^10 / (2^10 - 1) == 1.00097751710655 */ - MAD_F(0x10020040), /* 2^11 / (2^11 - 1) == 1.00048851978505 */ - MAD_F(0x10010010), /* 2^12 / (2^12 - 1) == 1.00024420024420 */ - MAD_F(0x10008004), /* 2^13 / (2^13 - 1) == 1.00012208521548 */ - MAD_F(0x10004001), /* 2^14 / (2^14 - 1) == 1.00006103888177 */ - MAD_F(0x10002000) /* 2^15 / (2^15 - 1) == 1.00003051850948 */ -}; - -/* - * NAME: I_sample() - * DESCRIPTION: decode one requantized Layer I sample from a bitstream - */ -static -mad_fixed_t I_sample(struct mad_bitptr *ptr, unsigned int nb) -{ - mad_fixed_t sample; - - sample = mad_bit_read(ptr, nb); - - /* invert most significant bit, extend sign, then scale to fixed format */ - - sample ^= 1 << (nb - 1); - sample |= -(sample & (1 << (nb - 1))); - - sample <<= MAD_F_FRACBITS - (nb - 1); - - /* requantize the sample */ - - /* s'' = (2^nb / (2^nb - 1)) * (s''' + 2^(-nb + 1)) */ - - sample += MAD_F_ONE >> (nb - 1); - - return mad_f_mul(sample, linear_table[nb - 2]); - - /* s' = factor * s'' */ - /* (to be performed by caller) */ -} - -/* - * NAME: layer->I() - * DESCRIPTION: decode a single Layer I frame - */ -int mad_layer_I(struct mad_stream *stream, struct mad_frame *frame) -{ - struct mad_header *header = &frame->header; - unsigned int nch, bound, ch, s, sb, nb; - unsigned char allocation[2][32], scalefactor[2][32]; - - nch = MAD_NCHANNELS(header); - - bound = 32; - if (header->mode == MAD_MODE_JOINT_STEREO) { - header->flags |= MAD_FLAG_I_STEREO; - bound = 4 + header->mode_extension * 4; - } - - /* check CRC word */ - - if (header->flags & MAD_FLAG_PROTECTION) { - header->crc_check = - mad_bit_crc(stream->ptr, 4 * (bound * nch + (32 - bound)), - header->crc_check); - - if (header->crc_check != header->crc_target && - !(frame->options & MAD_OPTION_IGNORECRC)) { - stream->error = MAD_ERROR_BADCRC; - return -1; - } - } - - /* decode bit allocations */ - - for (sb = 0; sb < bound; ++sb) { - for (ch = 0; ch < nch; ++ch) { - nb = mad_bit_read(&stream->ptr, 4); - - if (nb == 15) { - stream->error = MAD_ERROR_BADBITALLOC; - return -1; - } - - allocation[ch][sb] = nb ? nb + 1 : 0; - } - } - - for (sb = bound; sb < 32; ++sb) { - nb = mad_bit_read(&stream->ptr, 4); - - if (nb == 15) { - stream->error = MAD_ERROR_BADBITALLOC; - return -1; - } - - allocation[0][sb] = - allocation[1][sb] = nb ? nb + 1 : 0; - } - - /* decode scalefactors */ - - for (sb = 0; sb < 32; ++sb) { - for (ch = 0; ch < nch; ++ch) { - if (allocation[ch][sb]) { - scalefactor[ch][sb] = mad_bit_read(&stream->ptr, 6); - -# if defined(OPT_STRICT) - /* - * Scalefactor index 63 does not appear in Table B.1 of - * ISO/IEC 11172-3. Nonetheless, other implementations accept it, - * so we only reject it if OPT_STRICT is defined. - */ - if (scalefactor[ch][sb] == 63) { - stream->error = MAD_ERROR_BADSCALEFACTOR; - return -1; - } -# endif - } - } - } - - /* decode samples */ - - for (s = 0; s < 12; ++s) { - for (sb = 0; sb < bound; ++sb) { - for (ch = 0; ch < nch; ++ch) { - nb = allocation[ch][sb]; - frame->sbsample[ch][s][sb] = nb ? - mad_f_mul(I_sample(&stream->ptr, nb), - sf_table[scalefactor[ch][sb]]) : 0; - } - } - - for (sb = bound; sb < 32; ++sb) { - if ((nb = allocation[0][sb])) { - mad_fixed_t sample; - - sample = I_sample(&stream->ptr, nb); - - for (ch = 0; ch < nch; ++ch) { - frame->sbsample[ch][s][sb] = - mad_f_mul(sample, sf_table[scalefactor[ch][sb]]); - } - } - else { - for (ch = 0; ch < nch; ++ch) - frame->sbsample[ch][s][sb] = 0; - } - } - } - - return 0; -} - -/* --- Layer II ------------------------------------------------------------ */ - -/* possible quantization per subband table */ -static -struct { - unsigned int sblimit; - unsigned char const offsets[30]; -} const sbquant_table[5] = { - /* ISO/IEC 11172-3 Table B.2a */ - { 27, { 7, 7, 7, 6, 6, 6, 6, 6, 6, 6, 6, 3, 3, 3, 3, 3, /* 0 */ - 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0 } }, - /* ISO/IEC 11172-3 Table B.2b */ - { 30, { 7, 7, 7, 6, 6, 6, 6, 6, 6, 6, 6, 3, 3, 3, 3, 3, /* 1 */ - 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0 } }, - /* ISO/IEC 11172-3 Table B.2c */ - { 8, { 5, 5, 2, 2, 2, 2, 2, 2 } }, /* 2 */ - /* ISO/IEC 11172-3 Table B.2d */ - { 12, { 5, 5, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 } }, /* 3 */ - /* ISO/IEC 13818-3 Table B.1 */ - { 30, { 4, 4, 4, 4, 2, 2, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, /* 4 */ - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 } } -}; - -/* bit allocation table */ -static -struct { - unsigned short nbal; - unsigned short offset; -} const bitalloc_table[8] = { - { 2, 0 }, /* 0 */ - { 2, 3 }, /* 1 */ - { 3, 3 }, /* 2 */ - { 3, 1 }, /* 3 */ - { 4, 2 }, /* 4 */ - { 4, 3 }, /* 5 */ - { 4, 4 }, /* 6 */ - { 4, 5 } /* 7 */ -}; - -/* offsets into quantization class table */ -static -unsigned char const offset_table[6][15] = { - { 0, 1, 16 }, /* 0 */ - { 0, 1, 2, 3, 4, 5, 16 }, /* 1 */ - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, /* 2 */ - { 0, 1, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 }, /* 3 */ - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16 }, /* 4 */ - { 0, 2, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16 } /* 5 */ -}; - -/* quantization class table */ -static -struct quantclass { - unsigned short nlevels; - unsigned char group; - unsigned char bits; - mad_fixed_t C; - mad_fixed_t D; -} const qc_table[17] = { -# include "qc_table.dat" -}; - -/* - * NAME: II_samples() - * DESCRIPTION: decode three requantized Layer II samples from a bitstream - */ -static -void II_samples(struct mad_bitptr *ptr, - struct quantclass const *quantclass, - mad_fixed_t output[3]) -{ - unsigned int nb, s, sample[3]; - - if ((nb = quantclass->group)) { - unsigned int c, nlevels; - - /* degrouping */ - c = mad_bit_read(ptr, quantclass->bits); - nlevels = quantclass->nlevels; - - for (s = 0; s < 3; ++s) { - sample[s] = c % nlevels; - c /= nlevels; - } - } - else { - nb = quantclass->bits; - - for (s = 0; s < 3; ++s) - sample[s] = mad_bit_read(ptr, nb); - } - - for (s = 0; s < 3; ++s) { - mad_fixed_t requantized; - - /* invert most significant bit, extend sign, then scale to fixed format */ - - requantized = sample[s] ^ (1 << (nb - 1)); - requantized |= -(requantized & (1 << (nb - 1))); - - requantized <<= MAD_F_FRACBITS - (nb - 1); - - /* requantize the sample */ - - /* s'' = C * (s''' + D) */ - - output[s] = mad_f_mul(requantized + quantclass->D, quantclass->C); - - /* s' = factor * s'' */ - /* (to be performed by caller) */ - } -} - -/* - * NAME: layer->II() - * DESCRIPTION: decode a single Layer II frame - */ -int mad_layer_II(struct mad_stream *stream, struct mad_frame *frame) -{ - struct mad_header *header = &frame->header; - struct mad_bitptr start; - unsigned int index, sblimit, nbal, nch, bound, gr, ch, s, sb; - unsigned char const *offsets; - unsigned char allocation[2][32], scfsi[2][32], scalefactor[2][32][3]; - mad_fixed_t samples[3]; - - nch = MAD_NCHANNELS(header); - - if (header->flags & MAD_FLAG_LSF_EXT) - index = 4; - else if (header->flags & MAD_FLAG_FREEFORMAT) - goto freeformat; - else { - unsigned long bitrate_per_channel; - - bitrate_per_channel = header->bitrate; - if (nch == 2) { - bitrate_per_channel /= 2; - -# if defined(OPT_STRICT) - /* - * ISO/IEC 11172-3 allows only single channel mode for 32, 48, 56, and - * 80 kbps bitrates in Layer II, but some encoders ignore this - * restriction. We enforce it if OPT_STRICT is defined. - */ - if (bitrate_per_channel <= 28000 || bitrate_per_channel == 40000) { - stream->error = MAD_ERROR_BADMODE; - return -1; - } -# endif - } - else { /* nch == 1 */ -#if 0 /* relax restriction, those files do import fine! */ - if (bitrate_per_channel > 192000) { - /* - * ISO/IEC 11172-3 does not allow single channel mode for 224, 256, - * 320, or 384 kbps bitrates in Layer II. - */ - stream->error = MAD_ERROR_BADMODE; - return -1; - } -#endif - } - - if (bitrate_per_channel <= 48000) - index = (header->samplerate == 32000) ? 3 : 2; - else if (bitrate_per_channel <= 80000) - index = 0; - else { - freeformat: - index = (header->samplerate == 48000) ? 0 : 1; - } - } - - sblimit = sbquant_table[index].sblimit; - offsets = sbquant_table[index].offsets; - - bound = 32; - if (header->mode == MAD_MODE_JOINT_STEREO) { - header->flags |= MAD_FLAG_I_STEREO; - bound = 4 + header->mode_extension * 4; - } - - if (bound > sblimit) - bound = sblimit; - - start = stream->ptr; - - /* decode bit allocations */ - - for (sb = 0; sb < bound; ++sb) { - nbal = bitalloc_table[offsets[sb]].nbal; - - for (ch = 0; ch < nch; ++ch) - allocation[ch][sb] = mad_bit_read(&stream->ptr, nbal); - } - - for (sb = bound; sb < sblimit; ++sb) { - nbal = bitalloc_table[offsets[sb]].nbal; - - allocation[0][sb] = - allocation[1][sb] = mad_bit_read(&stream->ptr, nbal); - } - - /* decode scalefactor selection info */ - - for (sb = 0; sb < sblimit; ++sb) { - for (ch = 0; ch < nch; ++ch) { - if (allocation[ch][sb]) - scfsi[ch][sb] = mad_bit_read(&stream->ptr, 2); - } - } - - /* check CRC word */ - - if (header->flags & MAD_FLAG_PROTECTION) { - header->crc_check = - mad_bit_crc(start, mad_bit_length(&start, &stream->ptr), - header->crc_check); - - if (header->crc_check != header->crc_target && - !(frame->options & MAD_OPTION_IGNORECRC)) { - stream->error = MAD_ERROR_BADCRC; - return -1; - } - } - - /* decode scalefactors */ - - for (sb = 0; sb < sblimit; ++sb) { - for (ch = 0; ch < nch; ++ch) { - if (allocation[ch][sb]) { - scalefactor[ch][sb][0] = mad_bit_read(&stream->ptr, 6); - - switch (scfsi[ch][sb]) { - case 2: - scalefactor[ch][sb][2] = - scalefactor[ch][sb][1] = - scalefactor[ch][sb][0]; - break; - - case 0: - scalefactor[ch][sb][1] = mad_bit_read(&stream->ptr, 6); - /* fall through */ - - case 1: - case 3: - scalefactor[ch][sb][2] = mad_bit_read(&stream->ptr, 6); - } - - if (scfsi[ch][sb] & 1) - scalefactor[ch][sb][1] = scalefactor[ch][sb][scfsi[ch][sb] - 1]; - -# if defined(OPT_STRICT) - /* - * Scalefactor index 63 does not appear in Table B.1 of - * ISO/IEC 11172-3. Nonetheless, other implementations accept it, - * so we only reject it if OPT_STRICT is defined. - */ - if (scalefactor[ch][sb][0] == 63 || - scalefactor[ch][sb][1] == 63 || - scalefactor[ch][sb][2] == 63) { - stream->error = MAD_ERROR_BADSCALEFACTOR; - return -1; - } -# endif - } - } - } - - /* decode samples */ - - for (gr = 0; gr < 12; ++gr) { - for (sb = 0; sb < bound; ++sb) { - for (ch = 0; ch < nch; ++ch) { - if ((index = allocation[ch][sb])) { - index = offset_table[bitalloc_table[offsets[sb]].offset][index - 1]; - - II_samples(&stream->ptr, &qc_table[index], samples); - - for (s = 0; s < 3; ++s) { - frame->sbsample[ch][3 * gr + s][sb] = - mad_f_mul(samples[s], sf_table[scalefactor[ch][sb][gr / 4]]); - } - } - else { - for (s = 0; s < 3; ++s) - frame->sbsample[ch][3 * gr + s][sb] = 0; - } - } - } - - for (sb = bound; sb < sblimit; ++sb) { - if ((index = allocation[0][sb])) { - index = offset_table[bitalloc_table[offsets[sb]].offset][index - 1]; - - II_samples(&stream->ptr, &qc_table[index], samples); - - for (ch = 0; ch < nch; ++ch) { - for (s = 0; s < 3; ++s) { - frame->sbsample[ch][3 * gr + s][sb] = - mad_f_mul(samples[s], sf_table[scalefactor[ch][sb][gr / 4]]); - } - } - } - else { - for (ch = 0; ch < nch; ++ch) { - for (s = 0; s < 3; ++s) - frame->sbsample[ch][3 * gr + s][sb] = 0; - } - } - } - - for (ch = 0; ch < nch; ++ch) { - for (s = 0; s < 3; ++s) { - for (sb = sblimit; sb < 32; ++sb) - frame->sbsample[ch][3 * gr + s][sb] = 0; - } - } - } - - return 0; -} diff --git a/lib-src/libmad/layer12.h b/lib-src/libmad/layer12.h deleted file mode 100644 index e8fc8b8ac..000000000 --- a/lib-src/libmad/layer12.h +++ /dev/null @@ -1,31 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: layer12.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_LAYER12_H -# define LIBMAD_LAYER12_H - -# include "stream.h" -# include "frame.h" - -int mad_layer_I(struct mad_stream *, struct mad_frame *); -int mad_layer_II(struct mad_stream *, struct mad_frame *); - -# endif diff --git a/lib-src/libmad/layer3.c b/lib-src/libmad/layer3.c deleted file mode 100644 index 4c8cca61d..000000000 --- a/lib-src/libmad/layer3.c +++ /dev/null @@ -1,2703 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: layer3.c,v 1.3 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# ifdef HAVE_LIMITS_H -# include -# else -# define CHAR_BIT 8 -# endif - -# include "fixed.h" -# include "bit.h" -# include "stream.h" -# include "frame.h" -# include "huffman.h" -# include "layer3.h" - -/* --- Layer III ----------------------------------------------------------- */ - -enum { - count1table_select = 0x01, - scalefac_scale = 0x02, - preflag = 0x04, - mixed_block_flag = 0x08 -}; - -enum { - I_STEREO = 0x1, - MS_STEREO = 0x2 -}; - -struct sideinfo { - unsigned int main_data_begin; - unsigned int private_bits; - - unsigned char scfsi[2]; - - struct granule { - struct channel { - /* from side info */ - unsigned short part2_3_length; - unsigned short big_values; - unsigned short global_gain; - unsigned short scalefac_compress; - - unsigned char flags; - unsigned char block_type; - unsigned char table_select[3]; - unsigned char subblock_gain[3]; - unsigned char region0_count; - unsigned char region1_count; - - /* from main_data */ - unsigned char scalefac[39]; /* scalefac_l and/or scalefac_s */ - } ch[2]; - } gr[2]; -}; - -/* - * scalefactor bit lengths - * derived from section 2.4.2.7 of ISO/IEC 11172-3 - */ -static -struct { - unsigned char slen1; - unsigned char slen2; -} const sflen_table[16] = { - { 0, 0 }, { 0, 1 }, { 0, 2 }, { 0, 3 }, - { 3, 0 }, { 1, 1 }, { 1, 2 }, { 1, 3 }, - { 2, 1 }, { 2, 2 }, { 2, 3 }, { 3, 1 }, - { 3, 2 }, { 3, 3 }, { 4, 2 }, { 4, 3 } -}; - -/* - * number of LSF scalefactor band values - * derived from section 2.4.3.2 of ISO/IEC 13818-3 - */ -static -unsigned char const nsfb_table[6][3][4] = { - { { 6, 5, 5, 5 }, - { 9, 9, 9, 9 }, - { 6, 9, 9, 9 } }, - - { { 6, 5, 7, 3 }, - { 9, 9, 12, 6 }, - { 6, 9, 12, 6 } }, - - { { 11, 10, 0, 0 }, - { 18, 18, 0, 0 }, - { 15, 18, 0, 0 } }, - - { { 7, 7, 7, 0 }, - { 12, 12, 12, 0 }, - { 6, 15, 12, 0 } }, - - { { 6, 6, 6, 3 }, - { 12, 9, 9, 6 }, - { 6, 12, 9, 6 } }, - - { { 8, 8, 5, 0 }, - { 15, 12, 9, 0 }, - { 6, 18, 9, 0 } } -}; - -/* - * MPEG-1 scalefactor band widths - * derived from Table B.8 of ISO/IEC 11172-3 - */ -static -unsigned char const sfb_48000_long[] = { - 4, 4, 4, 4, 4, 4, 6, 6, 6, 8, 10, - 12, 16, 18, 22, 28, 34, 40, 46, 54, 54, 192 -}; - -static -unsigned char const sfb_44100_long[] = { - 4, 4, 4, 4, 4, 4, 6, 6, 8, 8, 10, - 12, 16, 20, 24, 28, 34, 42, 50, 54, 76, 158 -}; - -static -unsigned char const sfb_32000_long[] = { - 4, 4, 4, 4, 4, 4, 6, 6, 8, 10, 12, - 16, 20, 24, 30, 38, 46, 56, 68, 84, 102, 26 -}; - -static -unsigned char const sfb_48000_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, - 6, 6, 6, 6, 6, 10, 10, 10, 12, 12, 12, 14, 14, - 14, 16, 16, 16, 20, 20, 20, 26, 26, 26, 66, 66, 66 -}; - -static -unsigned char const sfb_44100_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, - 6, 6, 8, 8, 8, 10, 10, 10, 12, 12, 12, 14, 14, - 14, 18, 18, 18, 22, 22, 22, 30, 30, 30, 56, 56, 56 -}; - -static -unsigned char const sfb_32000_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, - 6, 6, 8, 8, 8, 12, 12, 12, 16, 16, 16, 20, 20, - 20, 26, 26, 26, 34, 34, 34, 42, 42, 42, 12, 12, 12 -}; - -static -unsigned char const sfb_48000_mixed[] = { - /* long */ 4, 4, 4, 4, 4, 4, 6, 6, - /* short */ 4, 4, 4, 6, 6, 6, 6, 6, 6, 10, - 10, 10, 12, 12, 12, 14, 14, 14, 16, 16, - 16, 20, 20, 20, 26, 26, 26, 66, 66, 66 -}; - -static -unsigned char const sfb_44100_mixed[] = { - /* long */ 4, 4, 4, 4, 4, 4, 6, 6, - /* short */ 4, 4, 4, 6, 6, 6, 8, 8, 8, 10, - 10, 10, 12, 12, 12, 14, 14, 14, 18, 18, - 18, 22, 22, 22, 30, 30, 30, 56, 56, 56 -}; - -static -unsigned char const sfb_32000_mixed[] = { - /* long */ 4, 4, 4, 4, 4, 4, 6, 6, - /* short */ 4, 4, 4, 6, 6, 6, 8, 8, 8, 12, - 12, 12, 16, 16, 16, 20, 20, 20, 26, 26, - 26, 34, 34, 34, 42, 42, 42, 12, 12, 12 -}; - -/* - * MPEG-2 scalefactor band widths - * derived from Table B.2 of ISO/IEC 13818-3 - */ -static -unsigned char const sfb_24000_long[] = { - 6, 6, 6, 6, 6, 6, 8, 10, 12, 14, 16, - 18, 22, 26, 32, 38, 46, 54, 62, 70, 76, 36 -}; - -static -unsigned char const sfb_22050_long[] = { - 6, 6, 6, 6, 6, 6, 8, 10, 12, 14, 16, - 20, 24, 28, 32, 38, 46, 52, 60, 68, 58, 54 -}; - -# define sfb_16000_long sfb_22050_long - -static -unsigned char const sfb_24000_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, 6, 6, 8, - 8, 8, 10, 10, 10, 12, 12, 12, 14, 14, 14, 18, 18, - 18, 24, 24, 24, 32, 32, 32, 44, 44, 44, 12, 12, 12 -}; - -static -unsigned char const sfb_22050_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, 6, 6, 6, - 6, 6, 8, 8, 8, 10, 10, 10, 14, 14, 14, 18, 18, - 18, 26, 26, 26, 32, 32, 32, 42, 42, 42, 18, 18, 18 -}; - -static -unsigned char const sfb_16000_short[] = { - 4, 4, 4, 4, 4, 4, 4, 4, 4, 6, 6, 6, 8, - 8, 8, 10, 10, 10, 12, 12, 12, 14, 14, 14, 18, 18, - 18, 24, 24, 24, 30, 30, 30, 40, 40, 40, 18, 18, 18 -}; - -static -unsigned char const sfb_24000_mixed[] = { - /* long */ 6, 6, 6, 6, 6, 6, - /* short */ 6, 6, 6, 8, 8, 8, 10, 10, 10, 12, - 12, 12, 14, 14, 14, 18, 18, 18, 24, 24, - 24, 32, 32, 32, 44, 44, 44, 12, 12, 12 -}; - -static -unsigned char const sfb_22050_mixed[] = { - /* long */ 6, 6, 6, 6, 6, 6, - /* short */ 6, 6, 6, 6, 6, 6, 8, 8, 8, 10, - 10, 10, 14, 14, 14, 18, 18, 18, 26, 26, - 26, 32, 32, 32, 42, 42, 42, 18, 18, 18 -}; - -static -unsigned char const sfb_16000_mixed[] = { - /* long */ 6, 6, 6, 6, 6, 6, - /* short */ 6, 6, 6, 8, 8, 8, 10, 10, 10, 12, - 12, 12, 14, 14, 14, 18, 18, 18, 24, 24, - 24, 30, 30, 30, 40, 40, 40, 18, 18, 18 -}; - -/* - * MPEG 2.5 scalefactor band widths - * derived from public sources - */ -# define sfb_12000_long sfb_16000_long -# define sfb_11025_long sfb_12000_long - -static -unsigned char const sfb_8000_long[] = { - 12, 12, 12, 12, 12, 12, 16, 20, 24, 28, 32, - 40, 48, 56, 64, 76, 90, 2, 2, 2, 2, 2 -}; - -# define sfb_12000_short sfb_16000_short -# define sfb_11025_short sfb_12000_short - -static -unsigned char const sfb_8000_short[] = { - 8, 8, 8, 8, 8, 8, 8, 8, 8, 12, 12, 12, 16, - 16, 16, 20, 20, 20, 24, 24, 24, 28, 28, 28, 36, 36, - 36, 2, 2, 2, 2, 2, 2, 2, 2, 2, 26, 26, 26 -}; - -# define sfb_12000_mixed sfb_16000_mixed -# define sfb_11025_mixed sfb_12000_mixed - -/* the 8000 Hz short block scalefactor bands do not break after - the first 36 frequency lines, so this is probably wrong */ -static -unsigned char const sfb_8000_mixed[] = { - /* long */ 12, 12, 12, - /* short */ 4, 4, 4, 8, 8, 8, 12, 12, 12, 16, 16, 16, - 20, 20, 20, 24, 24, 24, 28, 28, 28, 36, 36, 36, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 26, 26, 26 -}; - -static -struct { - unsigned char const *l; - unsigned char const *s; - unsigned char const *m; -} const sfbwidth_table[9] = { - { sfb_48000_long, sfb_48000_short, sfb_48000_mixed }, - { sfb_44100_long, sfb_44100_short, sfb_44100_mixed }, - { sfb_32000_long, sfb_32000_short, sfb_32000_mixed }, - { sfb_24000_long, sfb_24000_short, sfb_24000_mixed }, - { sfb_22050_long, sfb_22050_short, sfb_22050_mixed }, - { sfb_16000_long, sfb_16000_short, sfb_16000_mixed }, - { sfb_12000_long, sfb_12000_short, sfb_12000_mixed }, - { sfb_11025_long, sfb_11025_short, sfb_11025_mixed }, - { sfb_8000_long, sfb_8000_short, sfb_8000_mixed } -}; - -/* - * scalefactor band preemphasis (used only when preflag is set) - * derived from Table B.6 of ISO/IEC 11172-3 - */ -static -unsigned char const pretab[22] = { - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 3, 3, 3, 2, 0 -}; - -/* - * table for requantization - * - * rq_table[x].mantissa * 2^(rq_table[x].exponent) = x^(4/3) - */ -static -struct fixedfloat { - unsigned long mantissa : 27; - unsigned short exponent : 5; -} const rq_table[8207] = { -# include "rq_table.dat" -}; - -/* - * fractional powers of two - * used for requantization and joint stereo decoding - * - * root_table[3 + x] = 2^(x/4) - */ -static -mad_fixed_t const root_table[7] = { - MAD_F(0x09837f05) /* 2^(-3/4) == 0.59460355750136 */, - MAD_F(0x0b504f33) /* 2^(-2/4) == 0.70710678118655 */, - MAD_F(0x0d744fcd) /* 2^(-1/4) == 0.84089641525371 */, - MAD_F(0x10000000) /* 2^( 0/4) == 1.00000000000000 */, - MAD_F(0x1306fe0a) /* 2^(+1/4) == 1.18920711500272 */, - MAD_F(0x16a09e66) /* 2^(+2/4) == 1.41421356237310 */, - MAD_F(0x1ae89f99) /* 2^(+3/4) == 1.68179283050743 */ -}; - -/* - * coefficients for aliasing reduction - * derived from Table B.9 of ISO/IEC 11172-3 - * - * c[] = { -0.6, -0.535, -0.33, -0.185, -0.095, -0.041, -0.0142, -0.0037 } - * cs[i] = 1 / sqrt(1 + c[i]^2) - * ca[i] = c[i] / sqrt(1 + c[i]^2) - */ -static -mad_fixed_t const cs[8] = { - +MAD_F(0x0db84a81) /* +0.857492926 */, +MAD_F(0x0e1b9d7f) /* +0.881741997 */, - +MAD_F(0x0f31adcf) /* +0.949628649 */, +MAD_F(0x0fbba815) /* +0.983314592 */, - +MAD_F(0x0feda417) /* +0.995517816 */, +MAD_F(0x0ffc8fc8) /* +0.999160558 */, - +MAD_F(0x0fff964c) /* +0.999899195 */, +MAD_F(0x0ffff8d3) /* +0.999993155 */ -}; - -static -mad_fixed_t const ca[8] = { - -MAD_F(0x083b5fe7) /* -0.514495755 */, -MAD_F(0x078c36d2) /* -0.471731969 */, - -MAD_F(0x05039814) /* -0.313377454 */, -MAD_F(0x02e91dd1) /* -0.181913200 */, - -MAD_F(0x0183603a) /* -0.094574193 */, -MAD_F(0x00a7cb87) /* -0.040965583 */, - -MAD_F(0x003a2847) /* -0.014198569 */, -MAD_F(0x000f27b4) /* -0.003699975 */ -}; - -/* - * IMDCT coefficients for short blocks - * derived from section 2.4.3.4.10.2 of ISO/IEC 11172-3 - * - * imdct_s[i/even][k] = cos((PI / 24) * (2 * (i / 2) + 7) * (2 * k + 1)) - * imdct_s[i /odd][k] = cos((PI / 24) * (2 * (6 + (i-1)/2) + 7) * (2 * k + 1)) - */ -static -mad_fixed_t const imdct_s[6][6] = { -# include "imdct_s.dat" -}; - -# if !defined(ASO_IMDCT) -/* - * windowing coefficients for long blocks - * derived from section 2.4.3.4.10.3 of ISO/IEC 11172-3 - * - * window_l[i] = sin((PI / 36) * (i + 1/2)) - */ -static -mad_fixed_t const window_l[36] = { - MAD_F(0x00b2aa3e) /* 0.043619387 */, MAD_F(0x0216a2a2) /* 0.130526192 */, - MAD_F(0x03768962) /* 0.216439614 */, MAD_F(0x04cfb0e2) /* 0.300705800 */, - MAD_F(0x061f78aa) /* 0.382683432 */, MAD_F(0x07635284) /* 0.461748613 */, - MAD_F(0x0898c779) /* 0.537299608 */, MAD_F(0x09bd7ca0) /* 0.608761429 */, - MAD_F(0x0acf37ad) /* 0.675590208 */, MAD_F(0x0bcbe352) /* 0.737277337 */, - MAD_F(0x0cb19346) /* 0.793353340 */, MAD_F(0x0d7e8807) /* 0.843391446 */, - - MAD_F(0x0e313245) /* 0.887010833 */, MAD_F(0x0ec835e8) /* 0.923879533 */, - MAD_F(0x0f426cb5) /* 0.953716951 */, MAD_F(0x0f9ee890) /* 0.976296007 */, - MAD_F(0x0fdcf549) /* 0.991444861 */, MAD_F(0x0ffc19fd) /* 0.999048222 */, - MAD_F(0x0ffc19fd) /* 0.999048222 */, MAD_F(0x0fdcf549) /* 0.991444861 */, - MAD_F(0x0f9ee890) /* 0.976296007 */, MAD_F(0x0f426cb5) /* 0.953716951 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, MAD_F(0x0e313245) /* 0.887010833 */, - - MAD_F(0x0d7e8807) /* 0.843391446 */, MAD_F(0x0cb19346) /* 0.793353340 */, - MAD_F(0x0bcbe352) /* 0.737277337 */, MAD_F(0x0acf37ad) /* 0.675590208 */, - MAD_F(0x09bd7ca0) /* 0.608761429 */, MAD_F(0x0898c779) /* 0.537299608 */, - MAD_F(0x07635284) /* 0.461748613 */, MAD_F(0x061f78aa) /* 0.382683432 */, - MAD_F(0x04cfb0e2) /* 0.300705800 */, MAD_F(0x03768962) /* 0.216439614 */, - MAD_F(0x0216a2a2) /* 0.130526192 */, MAD_F(0x00b2aa3e) /* 0.043619387 */, -}; -# endif /* ASO_IMDCT */ - -/* - * windowing coefficients for short blocks - * derived from section 2.4.3.4.10.3 of ISO/IEC 11172-3 - * - * window_s[i] = sin((PI / 12) * (i + 1/2)) - */ -static -mad_fixed_t const window_s[12] = { - MAD_F(0x0216a2a2) /* 0.130526192 */, MAD_F(0x061f78aa) /* 0.382683432 */, - MAD_F(0x09bd7ca0) /* 0.608761429 */, MAD_F(0x0cb19346) /* 0.793353340 */, - MAD_F(0x0ec835e8) /* 0.923879533 */, MAD_F(0x0fdcf549) /* 0.991444861 */, - MAD_F(0x0fdcf549) /* 0.991444861 */, MAD_F(0x0ec835e8) /* 0.923879533 */, - MAD_F(0x0cb19346) /* 0.793353340 */, MAD_F(0x09bd7ca0) /* 0.608761429 */, - MAD_F(0x061f78aa) /* 0.382683432 */, MAD_F(0x0216a2a2) /* 0.130526192 */, -}; - -/* - * coefficients for intensity stereo processing - * derived from section 2.4.3.4.9.3 of ISO/IEC 11172-3 - * - * is_ratio[i] = tan(i * (PI / 12)) - * is_table[i] = is_ratio[i] / (1 + is_ratio[i]) - */ -static -mad_fixed_t const is_table[7] = { - MAD_F(0x00000000) /* 0.000000000 */, - MAD_F(0x0361962f) /* 0.211324865 */, - MAD_F(0x05db3d74) /* 0.366025404 */, - MAD_F(0x08000000) /* 0.500000000 */, - MAD_F(0x0a24c28c) /* 0.633974596 */, - MAD_F(0x0c9e69d1) /* 0.788675135 */, - MAD_F(0x10000000) /* 1.000000000 */ -}; - -/* - * coefficients for LSF intensity stereo processing - * derived from section 2.4.3.2 of ISO/IEC 13818-3 - * - * is_lsf_table[0][i] = (1 / sqrt(sqrt(2)))^(i + 1) - * is_lsf_table[1][i] = (1 / sqrt(2)) ^(i + 1) - */ -static -mad_fixed_t const is_lsf_table[2][15] = { - { - MAD_F(0x0d744fcd) /* 0.840896415 */, - MAD_F(0x0b504f33) /* 0.707106781 */, - MAD_F(0x09837f05) /* 0.594603558 */, - MAD_F(0x08000000) /* 0.500000000 */, - MAD_F(0x06ba27e6) /* 0.420448208 */, - MAD_F(0x05a8279a) /* 0.353553391 */, - MAD_F(0x04c1bf83) /* 0.297301779 */, - MAD_F(0x04000000) /* 0.250000000 */, - MAD_F(0x035d13f3) /* 0.210224104 */, - MAD_F(0x02d413cd) /* 0.176776695 */, - MAD_F(0x0260dfc1) /* 0.148650889 */, - MAD_F(0x02000000) /* 0.125000000 */, - MAD_F(0x01ae89fa) /* 0.105112052 */, - MAD_F(0x016a09e6) /* 0.088388348 */, - MAD_F(0x01306fe1) /* 0.074325445 */ - }, { - MAD_F(0x0b504f33) /* 0.707106781 */, - MAD_F(0x08000000) /* 0.500000000 */, - MAD_F(0x05a8279a) /* 0.353553391 */, - MAD_F(0x04000000) /* 0.250000000 */, - MAD_F(0x02d413cd) /* 0.176776695 */, - MAD_F(0x02000000) /* 0.125000000 */, - MAD_F(0x016a09e6) /* 0.088388348 */, - MAD_F(0x01000000) /* 0.062500000 */, - MAD_F(0x00b504f3) /* 0.044194174 */, - MAD_F(0x00800000) /* 0.031250000 */, - MAD_F(0x005a827a) /* 0.022097087 */, - MAD_F(0x00400000) /* 0.015625000 */, - MAD_F(0x002d413d) /* 0.011048543 */, - MAD_F(0x00200000) /* 0.007812500 */, - MAD_F(0x0016a09e) /* 0.005524272 */ - } -}; - -/* - * NAME: III_sideinfo() - * DESCRIPTION: decode frame side information from a bitstream - */ -static -enum mad_error III_sideinfo(struct mad_bitptr *ptr, unsigned int nch, - int lsf, struct sideinfo *si, - unsigned int *data_bitlen, - unsigned int *priv_bitlen) -{ - unsigned int ngr, gr, ch, i; - enum mad_error result = MAD_ERROR_NONE; - - *data_bitlen = 0; - *priv_bitlen = lsf ? ((nch == 1) ? 1 : 2) : ((nch == 1) ? 5 : 3); - - si->main_data_begin = mad_bit_read(ptr, lsf ? 8 : 9); - si->private_bits = mad_bit_read(ptr, *priv_bitlen); - - ngr = 1; - if (!lsf) { - ngr = 2; - - for (ch = 0; ch < nch; ++ch) - si->scfsi[ch] = mad_bit_read(ptr, 4); - } - - for (gr = 0; gr < ngr; ++gr) { - struct granule *granule = &si->gr[gr]; - - for (ch = 0; ch < nch; ++ch) { - struct channel *channel = &granule->ch[ch]; - - channel->part2_3_length = mad_bit_read(ptr, 12); - channel->big_values = mad_bit_read(ptr, 9); - channel->global_gain = mad_bit_read(ptr, 8); - channel->scalefac_compress = mad_bit_read(ptr, lsf ? 9 : 4); - - *data_bitlen += channel->part2_3_length; - - if (channel->big_values > 288 && result == 0) - result = MAD_ERROR_BADBIGVALUES; - - channel->flags = 0; - - /* window_switching_flag */ - if (mad_bit_read(ptr, 1)) { - channel->block_type = mad_bit_read(ptr, 2); - - if (channel->block_type == 0 && result == 0) - result = MAD_ERROR_BADBLOCKTYPE; - - if (!lsf && channel->block_type == 2 && si->scfsi[ch] && result == 0) - result = MAD_ERROR_BADSCFSI; - - channel->region0_count = 7; - channel->region1_count = 36; - - if (mad_bit_read(ptr, 1)) - channel->flags |= mixed_block_flag; - else if (channel->block_type == 2) - channel->region0_count = 8; - - for (i = 0; i < 2; ++i) - channel->table_select[i] = mad_bit_read(ptr, 5); - -# if defined(DEBUG) - channel->table_select[2] = 4; /* not used */ -# endif - - for (i = 0; i < 3; ++i) - channel->subblock_gain[i] = mad_bit_read(ptr, 3); - } - else { - channel->block_type = 0; - - for (i = 0; i < 3; ++i) - channel->table_select[i] = mad_bit_read(ptr, 5); - - channel->region0_count = mad_bit_read(ptr, 4); - channel->region1_count = mad_bit_read(ptr, 3); - } - - /* [preflag,] scalefac_scale, count1table_select */ - channel->flags |= mad_bit_read(ptr, lsf ? 2 : 3); - } - } - - return result; -} - -/* - * NAME: III_scalefactors_lsf() - * DESCRIPTION: decode channel scalefactors for LSF from a bitstream - */ -static -unsigned int III_scalefactors_lsf(struct mad_bitptr *ptr, - struct channel *channel, - struct channel *gr1ch, int mode_extension) -{ - struct mad_bitptr start; - unsigned int scalefac_compress, index, slen[4], part, n, i; - unsigned char const *nsfb; - - start = *ptr; - - scalefac_compress = channel->scalefac_compress; - index = (channel->block_type == 2) ? - ((channel->flags & mixed_block_flag) ? 2 : 1) : 0; - - if (!((mode_extension & I_STEREO) && gr1ch)) { - if (scalefac_compress < 400) { - slen[0] = (scalefac_compress >> 4) / 5; - slen[1] = (scalefac_compress >> 4) % 5; - slen[2] = (scalefac_compress % 16) >> 2; - slen[3] = scalefac_compress % 4; - - nsfb = nsfb_table[0][index]; - } - else if (scalefac_compress < 500) { - scalefac_compress -= 400; - - slen[0] = (scalefac_compress >> 2) / 5; - slen[1] = (scalefac_compress >> 2) % 5; - slen[2] = scalefac_compress % 4; - slen[3] = 0; - - nsfb = nsfb_table[1][index]; - } - else { - scalefac_compress -= 500; - - slen[0] = scalefac_compress / 3; - slen[1] = scalefac_compress % 3; - slen[2] = 0; - slen[3] = 0; - - channel->flags |= preflag; - - nsfb = nsfb_table[2][index]; - } - - n = 0; - for (part = 0; part < 4; ++part) { - for (i = 0; i < nsfb[part]; ++i) - channel->scalefac[n++] = mad_bit_read(ptr, slen[part]); - } - - while (n < 39) - channel->scalefac[n++] = 0; - } - else { /* (mode_extension & I_STEREO) && gr1ch (i.e. ch == 1) */ - scalefac_compress >>= 1; - - if (scalefac_compress < 180) { - slen[0] = scalefac_compress / 36; - slen[1] = (scalefac_compress % 36) / 6; - slen[2] = (scalefac_compress % 36) % 6; - slen[3] = 0; - - nsfb = nsfb_table[3][index]; - } - else if (scalefac_compress < 244) { - scalefac_compress -= 180; - - slen[0] = (scalefac_compress % 64) >> 4; - slen[1] = (scalefac_compress % 16) >> 2; - slen[2] = scalefac_compress % 4; - slen[3] = 0; - - nsfb = nsfb_table[4][index]; - } - else { - scalefac_compress -= 244; - - slen[0] = scalefac_compress / 3; - slen[1] = scalefac_compress % 3; - slen[2] = 0; - slen[3] = 0; - - nsfb = nsfb_table[5][index]; - } - - n = 0; - for (part = 0; part < 4; ++part) { - unsigned int max, is_pos; - - max = (1 << slen[part]) - 1; - - for (i = 0; i < nsfb[part]; ++i) { - is_pos = mad_bit_read(ptr, slen[part]); - - channel->scalefac[n] = is_pos; - gr1ch->scalefac[n++] = (is_pos == max); - } - } - - while (n < 39) { - channel->scalefac[n] = 0; - gr1ch->scalefac[n++] = 0; /* apparently not illegal */ - } - } - - return mad_bit_length(&start, ptr); -} - -/* - * NAME: III_scalefactors() - * DESCRIPTION: decode channel scalefactors of one granule from a bitstream - */ -static -unsigned int III_scalefactors(struct mad_bitptr *ptr, struct channel *channel, - struct channel const *gr0ch, unsigned int scfsi) -{ - struct mad_bitptr start; - unsigned int slen1, slen2, sfbi; - - start = *ptr; - - slen1 = sflen_table[channel->scalefac_compress].slen1; - slen2 = sflen_table[channel->scalefac_compress].slen2; - - if (channel->block_type == 2) { - unsigned int nsfb; - - sfbi = 0; - - nsfb = (channel->flags & mixed_block_flag) ? 8 + 3 * 3 : 6 * 3; - while (nsfb--) - channel->scalefac[sfbi++] = mad_bit_read(ptr, slen1); - - nsfb = 6 * 3; - while (nsfb--) - channel->scalefac[sfbi++] = mad_bit_read(ptr, slen2); - - nsfb = 1 * 3; - while (nsfb--) - channel->scalefac[sfbi++] = 0; - } - else { /* channel->block_type != 2 */ - if (scfsi & 0x8) { - for (sfbi = 0; sfbi < 6; ++sfbi) - channel->scalefac[sfbi] = gr0ch->scalefac[sfbi]; - } - else { - for (sfbi = 0; sfbi < 6; ++sfbi) - channel->scalefac[sfbi] = mad_bit_read(ptr, slen1); - } - - if (scfsi & 0x4) { - for (sfbi = 6; sfbi < 11; ++sfbi) - channel->scalefac[sfbi] = gr0ch->scalefac[sfbi]; - } - else { - for (sfbi = 6; sfbi < 11; ++sfbi) - channel->scalefac[sfbi] = mad_bit_read(ptr, slen1); - } - - if (scfsi & 0x2) { - for (sfbi = 11; sfbi < 16; ++sfbi) - channel->scalefac[sfbi] = gr0ch->scalefac[sfbi]; - } - else { - for (sfbi = 11; sfbi < 16; ++sfbi) - channel->scalefac[sfbi] = mad_bit_read(ptr, slen2); - } - - if (scfsi & 0x1) { - for (sfbi = 16; sfbi < 21; ++sfbi) - channel->scalefac[sfbi] = gr0ch->scalefac[sfbi]; - } - else { - for (sfbi = 16; sfbi < 21; ++sfbi) - channel->scalefac[sfbi] = mad_bit_read(ptr, slen2); - } - - channel->scalefac[21] = 0; - } - - return mad_bit_length(&start, ptr); -} - -/* - * The Layer III formula for requantization and scaling is defined by - * section 2.4.3.4.7.1 of ISO/IEC 11172-3, as follows: - * - * long blocks: - * xr[i] = sign(is[i]) * abs(is[i])^(4/3) * - * 2^((1/4) * (global_gain - 210)) * - * 2^-(scalefac_multiplier * - * (scalefac_l[sfb] + preflag * pretab[sfb])) - * - * short blocks: - * xr[i] = sign(is[i]) * abs(is[i])^(4/3) * - * 2^((1/4) * (global_gain - 210 - 8 * subblock_gain[w])) * - * 2^-(scalefac_multiplier * scalefac_s[sfb][w]) - * - * where: - * scalefac_multiplier = (scalefac_scale + 1) / 2 - * - * The routines III_exponents() and III_requantize() facilitate this - * calculation. - */ - -/* - * NAME: III_exponents() - * DESCRIPTION: calculate scalefactor exponents - */ -static -void III_exponents(struct channel const *channel, - unsigned char const *sfbwidth, signed int exponents[39]) -{ - signed int gain; - unsigned int scalefac_multiplier, sfbi; - - gain = (signed int) channel->global_gain - 210; - scalefac_multiplier = (channel->flags & scalefac_scale) ? 2 : 1; - - if (channel->block_type == 2) { - unsigned int l; - signed int gain0, gain1, gain2; - - sfbi = l = 0; - - if (channel->flags & mixed_block_flag) { - unsigned int premask; - - premask = (channel->flags & preflag) ? ~0 : 0; - - /* long block subbands 0-1 */ - - while (l < 36) { - exponents[sfbi] = gain - - (signed int) ((channel->scalefac[sfbi] + (pretab[sfbi] & premask)) << - scalefac_multiplier); - - l += sfbwidth[sfbi++]; - } - } - - /* this is probably wrong for 8000 Hz short/mixed blocks */ - - gain0 = gain - 8 * (signed int) channel->subblock_gain[0]; - gain1 = gain - 8 * (signed int) channel->subblock_gain[1]; - gain2 = gain - 8 * (signed int) channel->subblock_gain[2]; - - while (l < 576) { - exponents[sfbi + 0] = gain0 - - (signed int) (channel->scalefac[sfbi + 0] << scalefac_multiplier); - exponents[sfbi + 1] = gain1 - - (signed int) (channel->scalefac[sfbi + 1] << scalefac_multiplier); - exponents[sfbi + 2] = gain2 - - (signed int) (channel->scalefac[sfbi + 2] << scalefac_multiplier); - - l += 3 * sfbwidth[sfbi]; - sfbi += 3; - } - } - else { /* channel->block_type != 2 */ - if (channel->flags & preflag) { - for (sfbi = 0; sfbi < 22; ++sfbi) { - exponents[sfbi] = gain - - (signed int) ((channel->scalefac[sfbi] + pretab[sfbi]) << - scalefac_multiplier); - } - } - else { - for (sfbi = 0; sfbi < 22; ++sfbi) { - exponents[sfbi] = gain - - (signed int) (channel->scalefac[sfbi] << scalefac_multiplier); - } - } - } -} - -/* - * NAME: III_requantize() - * DESCRIPTION: requantize one (positive) value - */ -static -mad_fixed_t III_requantize(unsigned int value, signed int exp) -{ - mad_fixed_t requantized; - signed int frac; - struct fixedfloat const *power; - - frac = exp % 4; /* assumes sign(frac) == sign(exp) */ - exp /= 4; - - power = &rq_table[value]; - requantized = power->mantissa; - exp += power->exponent; - - if (exp < 0) { - if (-exp >= sizeof(mad_fixed_t) * CHAR_BIT) { - /* underflow */ - requantized = 0; - } - else { - requantized += 1L << (-exp - 1); - requantized >>= -exp; - } - } - else { - if (exp >= 5) { - /* overflow */ -# if defined(DEBUG) - fprintf(stderr, "requantize overflow (%f * 2^%d)\n", - mad_f_todouble(requantized), exp); -# endif - requantized = MAD_F_MAX; - } - else - requantized <<= exp; - } - - return frac ? mad_f_mul(requantized, root_table[3 + frac]) : requantized; -} - -/* we must take care that sz >= bits and sz < sizeof(long) lest bits == 0 */ -# define MASK(cache, sz, bits) \ - (((cache) >> ((sz) - (bits))) & ((1 << (bits)) - 1)) -# define MASK1BIT(cache, sz) \ - ((cache) & (1 << ((sz) - 1))) - -/* - * NAME: III_huffdecode() - * DESCRIPTION: decode Huffman code words of one channel of one granule - */ -static -enum mad_error III_huffdecode(struct mad_bitptr *ptr, mad_fixed_t xr[576], - struct channel *channel, - unsigned char const *sfbwidth, - unsigned int part2_length) -{ - signed int exponents[39], exp; - signed int const *expptr; - struct mad_bitptr peek; - signed int bits_left, cachesz; - register mad_fixed_t *xrptr; - mad_fixed_t const *sfbound; - register unsigned long bitcache; - - bits_left = (signed) channel->part2_3_length - (signed) part2_length; - if (bits_left < 0) - return MAD_ERROR_BADPART3LEN; - - III_exponents(channel, sfbwidth, exponents); - - peek = *ptr; - mad_bit_skip(ptr, bits_left); - - /* align bit reads to byte boundaries */ - cachesz = mad_bit_bitsleft(&peek); - cachesz += ((32 - 1 - 24) + (24 - cachesz)) & ~7; - - bitcache = mad_bit_read(&peek, cachesz); - bits_left -= cachesz; - - xrptr = &xr[0]; - - /* big_values */ - { - unsigned int region, rcount; - struct hufftable const *entry; - union huffpair const *table; - unsigned int linbits, startbits, big_values, reqhits; - mad_fixed_t reqcache[16]; - - sfbound = xrptr + *sfbwidth++; - rcount = channel->region0_count + 1; - - entry = &mad_huff_pair_table[channel->table_select[region = 0]]; - table = entry->table; - linbits = entry->linbits; - startbits = entry->startbits; - - if (table == 0) - return MAD_ERROR_BADHUFFTABLE; - - expptr = &exponents[0]; - exp = *expptr++; - reqhits = 0; - - big_values = channel->big_values; - - while (big_values-- && cachesz + bits_left > 0) { - union huffpair const *pair; - unsigned int clumpsz, value; - register mad_fixed_t requantized; - - if (xrptr == sfbound) { - sfbound += *sfbwidth++; - - /* change table if region boundary */ - - if (--rcount == 0) { - if (region == 0) - rcount = channel->region1_count + 1; - else - rcount = 0; /* all remaining */ - - entry = &mad_huff_pair_table[channel->table_select[++region]]; - table = entry->table; - linbits = entry->linbits; - startbits = entry->startbits; - - if (table == 0) - return MAD_ERROR_BADHUFFTABLE; - } - - if (exp != *expptr) { - exp = *expptr; - reqhits = 0; - } - - ++expptr; - } - - if (cachesz < 21) { - unsigned int bits; - - bits = ((32 - 1 - 21) + (21 - cachesz)) & ~7; - bitcache = (bitcache << bits) | mad_bit_read(&peek, bits); - cachesz += bits; - bits_left -= bits; - } - - /* hcod (0..19) */ - - clumpsz = startbits; - pair = &table[MASK(bitcache, cachesz, clumpsz)]; - - while (!pair->final) { - cachesz -= clumpsz; - - clumpsz = pair->ptr.bits; - pair = &table[pair->ptr.offset + MASK(bitcache, cachesz, clumpsz)]; - } - - cachesz -= pair->value.hlen; - - if (linbits) { - /* x (0..14) */ - - value = pair->value.x; - - switch (value) { - case 0: - xrptr[0] = 0; - break; - - case 15: - if (cachesz < linbits + 2) { - bitcache = (bitcache << 16) | mad_bit_read(&peek, 16); - cachesz += 16; - bits_left -= 16; - } - - value += MASK(bitcache, cachesz, linbits); - cachesz -= linbits; - - requantized = III_requantize(value, exp); - goto x_final; - - default: - if (reqhits & (1 << value)) - requantized = reqcache[value]; - else { - reqhits |= (1 << value); - requantized = reqcache[value] = III_requantize(value, exp); - } - - x_final: - xrptr[0] = MASK1BIT(bitcache, cachesz--) ? - -requantized : requantized; - } - - /* y (0..14) */ - - value = pair->value.y; - - switch (value) { - case 0: - xrptr[1] = 0; - break; - - case 15: - if (cachesz < linbits + 1) { - bitcache = (bitcache << 16) | mad_bit_read(&peek, 16); - cachesz += 16; - bits_left -= 16; - } - - value += MASK(bitcache, cachesz, linbits); - cachesz -= linbits; - - requantized = III_requantize(value, exp); - goto y_final; - - default: - if (reqhits & (1 << value)) - requantized = reqcache[value]; - else { - reqhits |= (1 << value); - requantized = reqcache[value] = III_requantize(value, exp); - } - - y_final: - xrptr[1] = MASK1BIT(bitcache, cachesz--) ? - -requantized : requantized; - } - } - else { - /* x (0..1) */ - - value = pair->value.x; - - if (value == 0) - xrptr[0] = 0; - else { - if (reqhits & (1 << value)) - requantized = reqcache[value]; - else { - reqhits |= (1 << value); - requantized = reqcache[value] = III_requantize(value, exp); - } - - xrptr[0] = MASK1BIT(bitcache, cachesz--) ? - -requantized : requantized; - } - - /* y (0..1) */ - - value = pair->value.y; - - if (value == 0) - xrptr[1] = 0; - else { - if (reqhits & (1 << value)) - requantized = reqcache[value]; - else { - reqhits |= (1 << value); - requantized = reqcache[value] = III_requantize(value, exp); - } - - xrptr[1] = MASK1BIT(bitcache, cachesz--) ? - -requantized : requantized; - } - } - - xrptr += 2; - } - } - - if (cachesz + bits_left < 0) - return MAD_ERROR_BADHUFFDATA; /* big_values overrun */ - - /* count1 */ - { - union huffquad const *table; - register mad_fixed_t requantized; - - table = mad_huff_quad_table[channel->flags & count1table_select]; - - requantized = III_requantize(1, exp); - - while (cachesz + bits_left > 0 && xrptr <= &xr[572]) { - union huffquad const *quad; - - /* hcod (1..6) */ - - if (cachesz < 10) { - bitcache = (bitcache << 16) | mad_bit_read(&peek, 16); - cachesz += 16; - bits_left -= 16; - } - - quad = &table[MASK(bitcache, cachesz, 4)]; - - /* quad tables guaranteed to have at most one extra lookup */ - if (!quad->final) { - cachesz -= 4; - - quad = &table[quad->ptr.offset + - MASK(bitcache, cachesz, quad->ptr.bits)]; - } - - cachesz -= quad->value.hlen; - - if (xrptr == sfbound) { - sfbound += *sfbwidth++; - - if (exp != *expptr) { - exp = *expptr; - requantized = III_requantize(1, exp); - } - - ++expptr; - } - - /* v (0..1) */ - - xrptr[0] = quad->value.v ? - (MASK1BIT(bitcache, cachesz--) ? -requantized : requantized) : 0; - - /* w (0..1) */ - - xrptr[1] = quad->value.w ? - (MASK1BIT(bitcache, cachesz--) ? -requantized : requantized) : 0; - - xrptr += 2; - - if (xrptr == sfbound) { - sfbound += *sfbwidth++; - - if (exp != *expptr) { - exp = *expptr; - requantized = III_requantize(1, exp); - } - - ++expptr; - } - - /* x (0..1) */ - - xrptr[0] = quad->value.x ? - (MASK1BIT(bitcache, cachesz--) ? -requantized : requantized) : 0; - - /* y (0..1) */ - - xrptr[1] = quad->value.y ? - (MASK1BIT(bitcache, cachesz--) ? -requantized : requantized) : 0; - - xrptr += 2; - } - - if (cachesz + bits_left < 0) { -# if 0 && defined(DEBUG) - fprintf(stderr, "huffman count1 overrun (%d bits)\n", - -(cachesz + bits_left)); -# endif - - /* technically the bitstream is misformatted, but apparently - some encoders are just a bit sloppy with stuffing bits */ - - xrptr -= 4; - } - } - - assert(-bits_left <= MAD_BUFFER_GUARD * CHAR_BIT); - -# if 0 && defined(DEBUG) - if (bits_left < 0) - fprintf(stderr, "read %d bits too many\n", -bits_left); - else if (cachesz + bits_left > 0) - fprintf(stderr, "%d stuffing bits\n", cachesz + bits_left); -# endif - - /* rzero */ - while (xrptr < &xr[576]) { - xrptr[0] = 0; - xrptr[1] = 0; - - xrptr += 2; - } - - return MAD_ERROR_NONE; -} - -# undef MASK -# undef MASK1BIT - -/* - * NAME: III_reorder() - * DESCRIPTION: reorder frequency lines of a short block into subband order - */ -static -void III_reorder(mad_fixed_t xr[576], struct channel const *channel, - unsigned char const sfbwidth[39]) -{ - mad_fixed_t tmp[32][3][6]; - unsigned int sb, l, f, w, sbw[3], sw[3]; - - /* this is probably wrong for 8000 Hz mixed blocks */ - - sb = 0; - if (channel->flags & mixed_block_flag) { - sb = 2; - - l = 0; - while (l < 36) - l += *sfbwidth++; - } - - for (w = 0; w < 3; ++w) { - sbw[w] = sb; - sw[w] = 0; - } - - f = *sfbwidth++; - w = 0; - - for (l = 18 * sb; l < 576; ++l) { - if (f-- == 0) { - f = *sfbwidth++ - 1; - w = (w + 1) % 3; - } - - tmp[sbw[w]][w][sw[w]++] = xr[l]; - - if (sw[w] == 6) { - sw[w] = 0; - ++sbw[w]; - } - } - - memcpy(&xr[18 * sb], &tmp[sb], (576 - 18 * sb) * sizeof(mad_fixed_t)); -} - -/* - * NAME: III_stereo() - * DESCRIPTION: perform joint stereo processing on a granule - */ -static -enum mad_error III_stereo(mad_fixed_t xr[2][576], - struct granule const *granule, - struct mad_header *header, - unsigned char const *sfbwidth) -{ - short modes[39]; - unsigned int sfbi, l, n, i; - - if (granule->ch[0].block_type != - granule->ch[1].block_type || - (granule->ch[0].flags & mixed_block_flag) != - (granule->ch[1].flags & mixed_block_flag)) - return MAD_ERROR_BADSTEREO; - - for (i = 0; i < 39; ++i) - modes[i] = header->mode_extension; - - /* intensity stereo */ - - if (header->mode_extension & I_STEREO) { - struct channel const *right_ch = &granule->ch[1]; - mad_fixed_t const *right_xr = xr[1]; - unsigned int is_pos; - - header->flags |= MAD_FLAG_I_STEREO; - - /* first determine which scalefactor bands are to be processed */ - - if (right_ch->block_type == 2) { - unsigned int lower, start, max, bound[3], w; - - lower = start = max = bound[0] = bound[1] = bound[2] = 0; - - sfbi = l = 0; - - if (right_ch->flags & mixed_block_flag) { - while (l < 36) { - n = sfbwidth[sfbi++]; - - for (i = 0; i < n; ++i) { - if (right_xr[i]) { - lower = sfbi; - break; - } - } - - right_xr += n; - l += n; - } - - start = sfbi; - } - - w = 0; - while (l < 576) { - n = sfbwidth[sfbi++]; - - for (i = 0; i < n; ++i) { - if (right_xr[i]) { - max = bound[w] = sfbi; - break; - } - } - - right_xr += n; - l += n; - w = (w + 1) % 3; - } - - if (max) - lower = start; - - /* long blocks */ - - for (i = 0; i < lower; ++i) - modes[i] = header->mode_extension & ~I_STEREO; - - /* short blocks */ - - w = 0; - for (i = start; i < max; ++i) { - if (i < bound[w]) - modes[i] = header->mode_extension & ~I_STEREO; - - w = (w + 1) % 3; - } - } - else { /* right_ch->block_type != 2 */ - unsigned int bound; - - bound = 0; - for (sfbi = l = 0; l < 576; l += n) { - n = sfbwidth[sfbi++]; - - for (i = 0; i < n; ++i) { - if (right_xr[i]) { - bound = sfbi; - break; - } - } - - right_xr += n; - } - - for (i = 0; i < bound; ++i) - modes[i] = header->mode_extension & ~I_STEREO; - } - - /* now do the actual processing */ - - if (header->flags & MAD_FLAG_LSF_EXT) { - unsigned char const *illegal_pos = granule[1].ch[1].scalefac; - mad_fixed_t const *lsf_scale; - - /* intensity_scale */ - lsf_scale = is_lsf_table[right_ch->scalefac_compress & 0x1]; - - for (sfbi = l = 0; l < 576; ++sfbi, l += n) { - n = sfbwidth[sfbi]; - - if (!(modes[sfbi] & I_STEREO)) - continue; - - if (illegal_pos[sfbi]) { - modes[sfbi] &= ~I_STEREO; - continue; - } - - is_pos = right_ch->scalefac[sfbi]; - - for (i = 0; i < n; ++i) { - register mad_fixed_t left; - - left = xr[0][l + i]; - - if (is_pos == 0) - xr[1][l + i] = left; - else { - register mad_fixed_t opposite; - - opposite = mad_f_mul(left, lsf_scale[(is_pos - 1) / 2]); - - if (is_pos & 1) { - xr[0][l + i] = opposite; - xr[1][l + i] = left; - } - else - xr[1][l + i] = opposite; - } - } - } - } - else { /* !(header->flags & MAD_FLAG_LSF_EXT) */ - for (sfbi = l = 0; l < 576; ++sfbi, l += n) { - n = sfbwidth[sfbi]; - - if (!(modes[sfbi] & I_STEREO)) - continue; - - is_pos = right_ch->scalefac[sfbi]; - - if (is_pos >= 7) { /* illegal intensity position */ - modes[sfbi] &= ~I_STEREO; - continue; - } - - for (i = 0; i < n; ++i) { - register mad_fixed_t left; - - left = xr[0][l + i]; - - xr[0][l + i] = mad_f_mul(left, is_table[ is_pos]); - xr[1][l + i] = mad_f_mul(left, is_table[6 - is_pos]); - } - } - } - } - - /* middle/side stereo */ - - if (header->mode_extension & MS_STEREO) { - register mad_fixed_t invsqrt2; - - header->flags |= MAD_FLAG_MS_STEREO; - - invsqrt2 = root_table[3 + -2]; - - for (sfbi = l = 0; l < 576; ++sfbi, l += n) { - n = sfbwidth[sfbi]; - - if (modes[sfbi] != MS_STEREO) - continue; - - for (i = 0; i < n; ++i) { - register mad_fixed_t m, s; - - m = xr[0][l + i]; - s = xr[1][l + i]; - - xr[0][l + i] = mad_f_mul(m + s, invsqrt2); /* l = (m + s) / sqrt(2) */ - xr[1][l + i] = mad_f_mul(m - s, invsqrt2); /* r = (m - s) / sqrt(2) */ - } - } - } - - return MAD_ERROR_NONE; -} - -/* - * NAME: III_aliasreduce() - * DESCRIPTION: perform frequency line alias reduction - */ -static -void III_aliasreduce(mad_fixed_t xr[576], int lines) -{ - mad_fixed_t const *bound; - int i; - - bound = &xr[lines]; - for (xr += 18; xr < bound; xr += 18) { - for (i = 0; i < 8; ++i) { - register mad_fixed_t a, b; - register mad_fixed64hi_t hi; - register mad_fixed64lo_t lo; - - a = xr[-1 - i]; - b = xr[ i]; - -# if defined(ASO_ZEROCHECK) - if (a | b) { -# endif - MAD_F_ML0(hi, lo, a, cs[i]); - MAD_F_MLA(hi, lo, -b, ca[i]); - - xr[-1 - i] = MAD_F_MLZ(hi, lo); - - MAD_F_ML0(hi, lo, b, cs[i]); - MAD_F_MLA(hi, lo, a, ca[i]); - - xr[ i] = MAD_F_MLZ(hi, lo); -# if defined(ASO_ZEROCHECK) - } -# endif - } - } -} - -# if defined(ASO_IMDCT) -void III_imdct_l(mad_fixed_t const [18], mad_fixed_t [36], unsigned int); -# else -# if 1 -static -void fastsdct(mad_fixed_t const x[9], mad_fixed_t y[18]) -{ - mad_fixed_t a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12; - mad_fixed_t a13, a14, a15, a16, a17, a18, a19, a20, a21, a22, a23, a24, a25; - mad_fixed_t m0, m1, m2, m3, m4, m5, m6, m7; - - enum { - c0 = MAD_F(0x1f838b8d), /* 2 * cos( 1 * PI / 18) */ - c1 = MAD_F(0x1bb67ae8), /* 2 * cos( 3 * PI / 18) */ - c2 = MAD_F(0x18836fa3), /* 2 * cos( 4 * PI / 18) */ - c3 = MAD_F(0x1491b752), /* 2 * cos( 5 * PI / 18) */ - c4 = MAD_F(0x0af1d43a), /* 2 * cos( 7 * PI / 18) */ - c5 = MAD_F(0x058e86a0), /* 2 * cos( 8 * PI / 18) */ - c6 = -MAD_F(0x1e11f642) /* 2 * cos(16 * PI / 18) */ - }; - - a0 = x[3] + x[5]; - a1 = x[3] - x[5]; - a2 = x[6] + x[2]; - a3 = x[6] - x[2]; - a4 = x[1] + x[7]; - a5 = x[1] - x[7]; - a6 = x[8] + x[0]; - a7 = x[8] - x[0]; - - a8 = a0 + a2; - a9 = a0 - a2; - a10 = a0 - a6; - a11 = a2 - a6; - a12 = a8 + a6; - a13 = a1 - a3; - a14 = a13 + a7; - a15 = a3 + a7; - a16 = a1 - a7; - a17 = a1 + a3; - - m0 = mad_f_mul(a17, -c3); - m1 = mad_f_mul(a16, -c0); - m2 = mad_f_mul(a15, -c4); - m3 = mad_f_mul(a14, -c1); - m4 = mad_f_mul(a5, -c1); - m5 = mad_f_mul(a11, -c6); - m6 = mad_f_mul(a10, -c5); - m7 = mad_f_mul(a9, -c2); - - a18 = x[4] + a4; - a19 = 2 * x[4] - a4; - a20 = a19 + m5; - a21 = a19 - m5; - a22 = a19 + m6; - a23 = m4 + m2; - a24 = m4 - m2; - a25 = m4 + m1; - - /* output to every other slot for convenience */ - - y[ 0] = a18 + a12; - y[ 2] = m0 - a25; - y[ 4] = m7 - a20; - y[ 6] = m3; - y[ 8] = a21 - m6; - y[10] = a24 - m1; - y[12] = a12 - 2 * a18; - y[14] = a23 + m0; - y[16] = a22 + m7; -} - -static inline -void sdctII(mad_fixed_t const x[18], mad_fixed_t X[18]) -{ - mad_fixed_t tmp[9]; - int i; - - /* scale[i] = 2 * cos(PI * (2 * i + 1) / (2 * 18)) */ - static mad_fixed_t const scale[9] = { - MAD_F(0x1fe0d3b4), MAD_F(0x1ee8dd47), MAD_F(0x1d007930), - MAD_F(0x1a367e59), MAD_F(0x16a09e66), MAD_F(0x125abcf8), - MAD_F(0x0d8616bc), MAD_F(0x08483ee1), MAD_F(0x02c9fad7) - }; - - /* divide the 18-point SDCT-II into two 9-point SDCT-IIs */ - - /* even input butterfly */ - - for (i = 0; i < 9; i += 3) { - tmp[i + 0] = x[i + 0] + x[18 - (i + 0) - 1]; - tmp[i + 1] = x[i + 1] + x[18 - (i + 1) - 1]; - tmp[i + 2] = x[i + 2] + x[18 - (i + 2) - 1]; - } - - fastsdct(tmp, &X[0]); - - /* odd input butterfly and scaling */ - - for (i = 0; i < 9; i += 3) { - tmp[i + 0] = mad_f_mul(x[i + 0] - x[18 - (i + 0) - 1], scale[i + 0]); - tmp[i + 1] = mad_f_mul(x[i + 1] - x[18 - (i + 1) - 1], scale[i + 1]); - tmp[i + 2] = mad_f_mul(x[i + 2] - x[18 - (i + 2) - 1], scale[i + 2]); - } - - fastsdct(tmp, &X[1]); - - /* output accumulation */ - - for (i = 3; i < 18; i += 8) { - X[i + 0] -= X[(i + 0) - 2]; - X[i + 2] -= X[(i + 2) - 2]; - X[i + 4] -= X[(i + 4) - 2]; - X[i + 6] -= X[(i + 6) - 2]; - } -} - -static inline -void dctIV(mad_fixed_t const y[18], mad_fixed_t X[18]) -{ - mad_fixed_t tmp[18]; - int i; - - /* scale[i] = 2 * cos(PI * (2 * i + 1) / (4 * 18)) */ - static mad_fixed_t const scale[18] = { - MAD_F(0x1ff833fa), MAD_F(0x1fb9ea93), MAD_F(0x1f3dd120), - MAD_F(0x1e84d969), MAD_F(0x1d906bcf), MAD_F(0x1c62648b), - MAD_F(0x1afd100f), MAD_F(0x1963268b), MAD_F(0x1797c6a4), - MAD_F(0x159e6f5b), MAD_F(0x137af940), MAD_F(0x11318ef3), - MAD_F(0x0ec6a507), MAD_F(0x0c3ef153), MAD_F(0x099f61c5), - MAD_F(0x06ed12c5), MAD_F(0x042d4544), MAD_F(0x0165547c) - }; - - /* scaling */ - - for (i = 0; i < 18; i += 3) { - tmp[i + 0] = mad_f_mul(y[i + 0], scale[i + 0]); - tmp[i + 1] = mad_f_mul(y[i + 1], scale[i + 1]); - tmp[i + 2] = mad_f_mul(y[i + 2], scale[i + 2]); - } - - /* SDCT-II */ - - sdctII(tmp, X); - - /* scale reduction and output accumulation */ - - X[0] /= 2; - for (i = 1; i < 17; i += 4) { - X[i + 0] = X[i + 0] / 2 - X[(i + 0) - 1]; - X[i + 1] = X[i + 1] / 2 - X[(i + 1) - 1]; - X[i + 2] = X[i + 2] / 2 - X[(i + 2) - 1]; - X[i + 3] = X[i + 3] / 2 - X[(i + 3) - 1]; - } - X[17] = X[17] / 2 - X[16]; -} - -/* - * NAME: imdct36 - * DESCRIPTION: perform X[18]->x[36] IMDCT using Szu-Wei Lee's fast algorithm - */ -static inline -void imdct36(mad_fixed_t const x[18], mad_fixed_t y[36]) -{ - mad_fixed_t tmp[18]; - int i; - - /* DCT-IV */ - - dctIV(x, tmp); - - /* convert 18-point DCT-IV to 36-point IMDCT */ - - for (i = 0; i < 9; i += 3) { - y[i + 0] = tmp[9 + (i + 0)]; - y[i + 1] = tmp[9 + (i + 1)]; - y[i + 2] = tmp[9 + (i + 2)]; - } - for (i = 9; i < 27; i += 3) { - y[i + 0] = -tmp[36 - (9 + (i + 0)) - 1]; - y[i + 1] = -tmp[36 - (9 + (i + 1)) - 1]; - y[i + 2] = -tmp[36 - (9 + (i + 2)) - 1]; - } - for (i = 27; i < 36; i += 3) { - y[i + 0] = -tmp[(i + 0) - 27]; - y[i + 1] = -tmp[(i + 1) - 27]; - y[i + 2] = -tmp[(i + 2) - 27]; - } -} -# else -/* - * NAME: imdct36 - * DESCRIPTION: perform X[18]->x[36] IMDCT - */ -static inline -void imdct36(mad_fixed_t const X[18], mad_fixed_t x[36]) -{ - mad_fixed_t t0, t1, t2, t3, t4, t5, t6, t7; - mad_fixed_t t8, t9, t10, t11, t12, t13, t14, t15; - register mad_fixed64hi_t hi; - register mad_fixed64lo_t lo; - - MAD_F_ML0(hi, lo, X[4], MAD_F(0x0ec835e8)); - MAD_F_MLA(hi, lo, X[13], MAD_F(0x061f78aa)); - - t6 = MAD_F_MLZ(hi, lo); - - MAD_F_MLA(hi, lo, (t14 = X[1] - X[10]), -MAD_F(0x061f78aa)); - MAD_F_MLA(hi, lo, (t15 = X[7] + X[16]), -MAD_F(0x0ec835e8)); - - t0 = MAD_F_MLZ(hi, lo); - - MAD_F_MLA(hi, lo, (t8 = X[0] - X[11] - X[12]), MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, (t9 = X[2] - X[9] - X[14]), MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, (t10 = X[3] - X[8] - X[15]), -MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, (t11 = X[5] - X[6] - X[17]), -MAD_F(0x0fdcf549)); - - x[7] = MAD_F_MLZ(hi, lo); - x[10] = -x[7]; - - MAD_F_ML0(hi, lo, t8, -MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, t9, MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, t10, MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, t11, -MAD_F(0x09bd7ca0)); - - x[19] = x[34] = MAD_F_MLZ(hi, lo) - t0; - - t12 = X[0] - X[3] + X[8] - X[11] - X[12] + X[15]; - t13 = X[2] + X[5] - X[6] - X[9] - X[14] - X[17]; - - MAD_F_ML0(hi, lo, t12, -MAD_F(0x0ec835e8)); - MAD_F_MLA(hi, lo, t13, MAD_F(0x061f78aa)); - - x[22] = x[31] = MAD_F_MLZ(hi, lo) + t0; - - MAD_F_ML0(hi, lo, X[1], -MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, X[7], MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, X[10], -MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, X[16], MAD_F(0x0cb19346)); - - t1 = MAD_F_MLZ(hi, lo) + t6; - - MAD_F_ML0(hi, lo, X[0], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[11], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0f9ee890)); - - x[6] = MAD_F_MLZ(hi, lo) + t1; - x[11] = -x[6]; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[2], -MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[17], MAD_F(0x04cfb0e2)); - - x[23] = x[30] = MAD_F_MLZ(hi, lo) + t1; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[11], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0acf37ad)); - - x[18] = x[35] = MAD_F_MLZ(hi, lo) - t1; - - MAD_F_ML0(hi, lo, X[4], MAD_F(0x061f78aa)); - MAD_F_MLA(hi, lo, X[13], -MAD_F(0x0ec835e8)); - - t7 = MAD_F_MLZ(hi, lo); - - MAD_F_MLA(hi, lo, X[1], -MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, X[7], MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, X[10], MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, X[16], -MAD_F(0x09bd7ca0)); - - t2 = MAD_F_MLZ(hi, lo); - - MAD_F_MLA(hi, lo, X[0], MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[12], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[17], MAD_F(0x0f426cb5)); - - x[5] = MAD_F_MLZ(hi, lo); - x[12] = -x[5]; - - MAD_F_ML0(hi, lo, X[0], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[2], -MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[11], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0bcbe352)); - - x[0] = MAD_F_MLZ(hi, lo) + t2; - x[17] = -x[0]; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[2], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[14], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x03768962)); - - x[24] = x[29] = MAD_F_MLZ(hi, lo) + t2; - - MAD_F_ML0(hi, lo, X[1], -MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, X[7], -MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, X[10], MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, X[16], MAD_F(0x0fdcf549)); - - t3 = MAD_F_MLZ(hi, lo) + t7; - - MAD_F_ML0(hi, lo, X[0], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[12], MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0ffc19fd)); - - x[8] = MAD_F_MLZ(hi, lo) + t3; - x[9] = -x[8]; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[14], -MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[17], MAD_F(0x07635284)); - - x[21] = x[32] = MAD_F_MLZ(hi, lo) + t3; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[12], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0898c779)); - - x[20] = x[33] = MAD_F_MLZ(hi, lo) - t3; - - MAD_F_ML0(hi, lo, t14, -MAD_F(0x0ec835e8)); - MAD_F_MLA(hi, lo, t15, MAD_F(0x061f78aa)); - - t4 = MAD_F_MLZ(hi, lo) - t7; - - MAD_F_ML0(hi, lo, t12, MAD_F(0x061f78aa)); - MAD_F_MLA(hi, lo, t13, MAD_F(0x0ec835e8)); - - x[4] = MAD_F_MLZ(hi, lo) + t4; - x[13] = -x[4]; - - MAD_F_ML0(hi, lo, t8, MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, t9, -MAD_F(0x0216a2a2)); - MAD_F_MLA(hi, lo, t10, MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, t11, -MAD_F(0x0cb19346)); - - x[1] = MAD_F_MLZ(hi, lo) + t4; - x[16] = -x[1]; - - MAD_F_ML0(hi, lo, t8, -MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, t9, -MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, t10, -MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, t11, -MAD_F(0x0216a2a2)); - - x[25] = x[28] = MAD_F_MLZ(hi, lo) + t4; - - MAD_F_ML0(hi, lo, X[1], -MAD_F(0x0fdcf549)); - MAD_F_MLA(hi, lo, X[7], -MAD_F(0x0cb19346)); - MAD_F_MLA(hi, lo, X[10], -MAD_F(0x09bd7ca0)); - MAD_F_MLA(hi, lo, X[16], -MAD_F(0x0216a2a2)); - - t5 = MAD_F_MLZ(hi, lo) - t6; - - MAD_F_ML0(hi, lo, X[0], MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[6], MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[9], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[12], MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[14], -MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[15], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x0d7e8807)); - - x[2] = MAD_F_MLZ(hi, lo) + t5; - x[15] = -x[2]; - - MAD_F_ML0(hi, lo, X[0], MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[2], MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[3], MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[5], MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x00b2aa3e)); - MAD_F_MLA(hi, lo, X[8], MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[11], MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[14], MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[17], MAD_F(0x0e313245)); - - x[3] = MAD_F_MLZ(hi, lo) + t5; - x[14] = -x[3]; - - MAD_F_ML0(hi, lo, X[0], -MAD_F(0x0ffc19fd)); - MAD_F_MLA(hi, lo, X[2], -MAD_F(0x0f9ee890)); - MAD_F_MLA(hi, lo, X[3], -MAD_F(0x0f426cb5)); - MAD_F_MLA(hi, lo, X[5], -MAD_F(0x0e313245)); - MAD_F_MLA(hi, lo, X[6], -MAD_F(0x0d7e8807)); - MAD_F_MLA(hi, lo, X[8], -MAD_F(0x0bcbe352)); - MAD_F_MLA(hi, lo, X[9], -MAD_F(0x0acf37ad)); - MAD_F_MLA(hi, lo, X[11], -MAD_F(0x0898c779)); - MAD_F_MLA(hi, lo, X[12], -MAD_F(0x07635284)); - MAD_F_MLA(hi, lo, X[14], -MAD_F(0x04cfb0e2)); - MAD_F_MLA(hi, lo, X[15], -MAD_F(0x03768962)); - MAD_F_MLA(hi, lo, X[17], -MAD_F(0x00b2aa3e)); - - x[26] = x[27] = MAD_F_MLZ(hi, lo) + t5; -} -# endif - -/* - * NAME: III_imdct_l() - * DESCRIPTION: perform IMDCT and windowing for long blocks - */ -static -void III_imdct_l(mad_fixed_t const X[18], mad_fixed_t z[36], - unsigned int block_type) -{ - unsigned int i; - - /* IMDCT */ - - imdct36(X, z); - - /* windowing */ - - switch (block_type) { - case 0: /* normal window */ -# if defined(ASO_INTERLEAVE1) - { - register mad_fixed_t tmp1, tmp2; - - tmp1 = window_l[0]; - tmp2 = window_l[1]; - - for (i = 0; i < 34; i += 2) { - z[i + 0] = mad_f_mul(z[i + 0], tmp1); - tmp1 = window_l[i + 2]; - z[i + 1] = mad_f_mul(z[i + 1], tmp2); - tmp2 = window_l[i + 3]; - } - - z[34] = mad_f_mul(z[34], tmp1); - z[35] = mad_f_mul(z[35], tmp2); - } -# elif defined(ASO_INTERLEAVE2) - { - register mad_fixed_t tmp1, tmp2; - - tmp1 = z[0]; - tmp2 = window_l[0]; - - for (i = 0; i < 35; ++i) { - z[i] = mad_f_mul(tmp1, tmp2); - tmp1 = z[i + 1]; - tmp2 = window_l[i + 1]; - } - - z[35] = mad_f_mul(tmp1, tmp2); - } -# elif 1 - for (i = 0; i < 36; i += 4) { - z[i + 0] = mad_f_mul(z[i + 0], window_l[i + 0]); - z[i + 1] = mad_f_mul(z[i + 1], window_l[i + 1]); - z[i + 2] = mad_f_mul(z[i + 2], window_l[i + 2]); - z[i + 3] = mad_f_mul(z[i + 3], window_l[i + 3]); - } -# else - for (i = 0; i < 36; ++i) z[i] = mad_f_mul(z[i], window_l[i]); -# endif - break; - - case 1: /* start block */ - for (i = 0; i < 18; i += 3) { - z[i + 0] = mad_f_mul(z[i + 0], window_l[i + 0]); - z[i + 1] = mad_f_mul(z[i + 1], window_l[i + 1]); - z[i + 2] = mad_f_mul(z[i + 2], window_l[i + 2]); - } - /* (i = 18; i < 24; ++i) z[i] unchanged */ - for (i = 24; i < 30; ++i) z[i] = mad_f_mul(z[i], window_s[i - 18]); - for (i = 30; i < 36; ++i) z[i] = 0; - break; - - case 3: /* stop block */ - for (i = 0; i < 6; ++i) z[i] = 0; - for (i = 6; i < 12; ++i) z[i] = mad_f_mul(z[i], window_s[i - 6]); - /* (i = 12; i < 18; ++i) z[i] unchanged */ - for (i = 18; i < 36; i += 3) { - z[i + 0] = mad_f_mul(z[i + 0], window_l[i + 0]); - z[i + 1] = mad_f_mul(z[i + 1], window_l[i + 1]); - z[i + 2] = mad_f_mul(z[i + 2], window_l[i + 2]); - } - break; - } -} -# endif /* ASO_IMDCT */ - -/* - * NAME: III_imdct_s() - * DESCRIPTION: perform IMDCT and windowing for short blocks - */ -static -void III_imdct_s(mad_fixed_t const X[18], mad_fixed_t z[36]) -{ - mad_fixed_t y[36], *yptr; - mad_fixed_t const *wptr; - int w, i; - register mad_fixed64hi_t hi; - register mad_fixed64lo_t lo; - - /* IMDCT */ - - yptr = &y[0]; - - for (w = 0; w < 3; ++w) { - register mad_fixed_t const (*s)[6]; - - s = imdct_s; - - for (i = 0; i < 3; ++i) { - MAD_F_ML0(hi, lo, X[0], (*s)[0]); - MAD_F_MLA(hi, lo, X[1], (*s)[1]); - MAD_F_MLA(hi, lo, X[2], (*s)[2]); - MAD_F_MLA(hi, lo, X[3], (*s)[3]); - MAD_F_MLA(hi, lo, X[4], (*s)[4]); - MAD_F_MLA(hi, lo, X[5], (*s)[5]); - - yptr[i + 0] = MAD_F_MLZ(hi, lo); - yptr[5 - i] = -yptr[i + 0]; - - ++s; - - MAD_F_ML0(hi, lo, X[0], (*s)[0]); - MAD_F_MLA(hi, lo, X[1], (*s)[1]); - MAD_F_MLA(hi, lo, X[2], (*s)[2]); - MAD_F_MLA(hi, lo, X[3], (*s)[3]); - MAD_F_MLA(hi, lo, X[4], (*s)[4]); - MAD_F_MLA(hi, lo, X[5], (*s)[5]); - - yptr[ i + 6] = MAD_F_MLZ(hi, lo); - yptr[11 - i] = yptr[i + 6]; - - ++s; - } - - yptr += 12; - X += 6; - } - - /* windowing, overlapping and concatenation */ - - yptr = &y[0]; - wptr = &window_s[0]; - - for (i = 0; i < 6; ++i) { - z[i + 0] = 0; - z[i + 6] = mad_f_mul(yptr[ 0 + 0], wptr[0]); - - MAD_F_ML0(hi, lo, yptr[ 0 + 6], wptr[6]); - MAD_F_MLA(hi, lo, yptr[12 + 0], wptr[0]); - - z[i + 12] = MAD_F_MLZ(hi, lo); - - MAD_F_ML0(hi, lo, yptr[12 + 6], wptr[6]); - MAD_F_MLA(hi, lo, yptr[24 + 0], wptr[0]); - - z[i + 18] = MAD_F_MLZ(hi, lo); - - z[i + 24] = mad_f_mul(yptr[24 + 6], wptr[6]); - z[i + 30] = 0; - - ++yptr; - ++wptr; - } -} - -/* - * NAME: III_overlap() - * DESCRIPTION: perform overlap-add of windowed IMDCT outputs - */ -static -void III_overlap(mad_fixed_t const output[36], mad_fixed_t overlap[18], - mad_fixed_t sample[18][32], unsigned int sb) -{ - unsigned int i; - -# if defined(ASO_INTERLEAVE2) - { - register mad_fixed_t tmp1, tmp2; - - tmp1 = overlap[0]; - tmp2 = overlap[1]; - - for (i = 0; i < 16; i += 2) { - sample[i + 0][sb] = output[i + 0 + 0] + tmp1; - overlap[i + 0] = output[i + 0 + 18]; - tmp1 = overlap[i + 2]; - - sample[i + 1][sb] = output[i + 1 + 0] + tmp2; - overlap[i + 1] = output[i + 1 + 18]; - tmp2 = overlap[i + 3]; - } - - sample[16][sb] = output[16 + 0] + tmp1; - overlap[16] = output[16 + 18]; - sample[17][sb] = output[17 + 0] + tmp2; - overlap[17] = output[17 + 18]; - } -# elif 0 - for (i = 0; i < 18; i += 2) { - sample[i + 0][sb] = output[i + 0 + 0] + overlap[i + 0]; - overlap[i + 0] = output[i + 0 + 18]; - - sample[i + 1][sb] = output[i + 1 + 0] + overlap[i + 1]; - overlap[i + 1] = output[i + 1 + 18]; - } -# else - for (i = 0; i < 18; ++i) { - sample[i][sb] = output[i + 0] + overlap[i]; - overlap[i] = output[i + 18]; - } -# endif -} - -/* - * NAME: III_overlap_z() - * DESCRIPTION: perform "overlap-add" of zero IMDCT outputs - */ -static inline -void III_overlap_z(mad_fixed_t overlap[18], - mad_fixed_t sample[18][32], unsigned int sb) -{ - unsigned int i; - -# if defined(ASO_INTERLEAVE2) - { - register mad_fixed_t tmp1, tmp2; - - tmp1 = overlap[0]; - tmp2 = overlap[1]; - - for (i = 0; i < 16; i += 2) { - sample[i + 0][sb] = tmp1; - overlap[i + 0] = 0; - tmp1 = overlap[i + 2]; - - sample[i + 1][sb] = tmp2; - overlap[i + 1] = 0; - tmp2 = overlap[i + 3]; - } - - sample[16][sb] = tmp1; - overlap[16] = 0; - sample[17][sb] = tmp2; - overlap[17] = 0; - } -# else - for (i = 0; i < 18; ++i) { - sample[i][sb] = overlap[i]; - overlap[i] = 0; - } -# endif -} - -/* - * NAME: III_freqinver() - * DESCRIPTION: perform subband frequency inversion for odd sample lines - */ -static -void III_freqinver(mad_fixed_t sample[18][32], unsigned int sb) -{ - unsigned int i; - -# if 1 || defined(ASO_INTERLEAVE1) || defined(ASO_INTERLEAVE2) - { - register mad_fixed_t tmp1, tmp2; - - tmp1 = sample[1][sb]; - tmp2 = sample[3][sb]; - - for (i = 1; i < 13; i += 4) { - sample[i + 0][sb] = -tmp1; - tmp1 = sample[i + 4][sb]; - sample[i + 2][sb] = -tmp2; - tmp2 = sample[i + 6][sb]; - } - - sample[13][sb] = -tmp1; - tmp1 = sample[17][sb]; - sample[15][sb] = -tmp2; - sample[17][sb] = -tmp1; - } -# else - for (i = 1; i < 18; i += 2) - sample[i][sb] = -sample[i][sb]; -# endif -} - -/* - * NAME: III_decode() - * DESCRIPTION: decode frame main_data - */ -static -enum mad_error III_decode(struct mad_bitptr *ptr, struct mad_frame *frame, - struct sideinfo *si, unsigned int nch) -{ - struct mad_header *header = &frame->header; - unsigned int sfreqi, ngr, gr; - - { - unsigned int sfreq; - - sfreq = header->samplerate; - if (header->flags & MAD_FLAG_MPEG_2_5_EXT) - sfreq *= 2; - - /* 48000 => 0, 44100 => 1, 32000 => 2, - 24000 => 3, 22050 => 4, 16000 => 5 */ - sfreqi = ((sfreq >> 7) & 0x000f) + - ((sfreq >> 15) & 0x0001) - 8; - - if (header->flags & MAD_FLAG_MPEG_2_5_EXT) - sfreqi += 3; - } - - /* scalefactors, Huffman decoding, requantization */ - - ngr = (header->flags & MAD_FLAG_LSF_EXT) ? 1 : 2; - - for (gr = 0; gr < ngr; ++gr) { - struct granule *granule = &si->gr[gr]; - unsigned char const *sfbwidth[2]; - mad_fixed_t xr[2][576]; - unsigned int ch; - enum mad_error error; - - for (ch = 0; ch < nch; ++ch) { - struct channel *channel = &granule->ch[ch]; - unsigned int part2_length; - - sfbwidth[ch] = sfbwidth_table[sfreqi].l; - if (channel->block_type == 2) { - sfbwidth[ch] = (channel->flags & mixed_block_flag) ? - sfbwidth_table[sfreqi].m : sfbwidth_table[sfreqi].s; - } - - if (header->flags & MAD_FLAG_LSF_EXT) { - part2_length = III_scalefactors_lsf(ptr, channel, - ch == 0 ? 0 : &si->gr[1].ch[1], - header->mode_extension); - } - else { - part2_length = III_scalefactors(ptr, channel, &si->gr[0].ch[ch], - gr == 0 ? 0 : si->scfsi[ch]); - } - - error = III_huffdecode(ptr, xr[ch], channel, sfbwidth[ch], part2_length); - if (error) - return error; - } - - /* joint stereo processing */ - - if (header->mode == MAD_MODE_JOINT_STEREO && header->mode_extension) { - error = III_stereo(xr, granule, header, sfbwidth[0]); - if (error) - return error; - } - - /* reordering, alias reduction, IMDCT, overlap-add, frequency inversion */ - - for (ch = 0; ch < nch; ++ch) { - struct channel const *channel = &granule->ch[ch]; - mad_fixed_t (*sample)[32] = &frame->sbsample[ch][18 * gr]; - unsigned int sb, l, i, sblimit; - mad_fixed_t output[36]; - - if (channel->block_type == 2) { - III_reorder(xr[ch], channel, sfbwidth[ch]); - -# if !defined(OPT_STRICT) - /* - * According to ISO/IEC 11172-3, "Alias reduction is not applied for - * granules with block_type == 2 (short block)." However, other - * sources suggest alias reduction should indeed be performed on the - * lower two subbands of mixed blocks. Most other implementations do - * this, so by default we will too. - */ - if (channel->flags & mixed_block_flag) - III_aliasreduce(xr[ch], 36); -# endif - } - else - III_aliasreduce(xr[ch], 576); - - l = 0; - - /* subbands 0-1 */ - - if (channel->block_type != 2 || (channel->flags & mixed_block_flag)) { - unsigned int block_type; - - block_type = channel->block_type; - if (channel->flags & mixed_block_flag) - block_type = 0; - - /* long blocks */ - for (sb = 0; sb < 2; ++sb, l += 18) { - III_imdct_l(&xr[ch][l], output, block_type); - III_overlap(output, (*frame->overlap)[ch][sb], sample, sb); - } - } - else { - /* short blocks */ - for (sb = 0; sb < 2; ++sb, l += 18) { - III_imdct_s(&xr[ch][l], output); - III_overlap(output, (*frame->overlap)[ch][sb], sample, sb); - } - } - - III_freqinver(sample, 1); - - /* (nonzero) subbands 2-31 */ - - i = 576; - while (i > 36 && xr[ch][i - 1] == 0) - --i; - - sblimit = 32 - (576 - i) / 18; - - if (channel->block_type != 2) { - /* long blocks */ - for (sb = 2; sb < sblimit; ++sb, l += 18) { - III_imdct_l(&xr[ch][l], output, channel->block_type); - III_overlap(output, (*frame->overlap)[ch][sb], sample, sb); - - if (sb & 1) - III_freqinver(sample, sb); - } - } - else { - /* short blocks */ - for (sb = 2; sb < sblimit; ++sb, l += 18) { - III_imdct_s(&xr[ch][l], output); - III_overlap(output, (*frame->overlap)[ch][sb], sample, sb); - - if (sb & 1) - III_freqinver(sample, sb); - } - } - - /* remaining (zero) subbands */ - - for (sb = sblimit; sb < 32; ++sb) { - III_overlap_z((*frame->overlap)[ch][sb], sample, sb); - - if (sb & 1) - III_freqinver(sample, sb); - } - } - } - - return MAD_ERROR_NONE; -} - -/* - * NAME: layer->III() - * DESCRIPTION: decode a single Layer III frame - */ -int mad_layer_III(struct mad_stream *stream, struct mad_frame *frame) -{ - struct mad_header *header = &frame->header; - unsigned int nch, priv_bitlen, next_md_begin = 0; - unsigned int si_len, data_bitlen, md_len; - unsigned int frame_space, frame_used, frame_free; - struct mad_bitptr ptr; - struct sideinfo si; - enum mad_error error; - int result = 0; - - /* allocate Layer III dynamic structures */ - - if (stream->main_data == 0) { - stream->main_data = malloc(MAD_BUFFER_MDLEN); - if (stream->main_data == 0) { - stream->error = MAD_ERROR_NOMEM; - return -1; - } - } - - if (frame->overlap == 0) { - frame->overlap = calloc(2 * 32 * 18, sizeof(mad_fixed_t)); - if (frame->overlap == 0) { - stream->error = MAD_ERROR_NOMEM; - return -1; - } - } - - nch = MAD_NCHANNELS(header); - si_len = (header->flags & MAD_FLAG_LSF_EXT) ? - (nch == 1 ? 9 : 17) : (nch == 1 ? 17 : 32); - - /* check frame sanity */ - - if (stream->next_frame - mad_bit_nextbyte(&stream->ptr) < - (signed int) si_len) { - stream->error = MAD_ERROR_BADFRAMELEN; - stream->md_len = 0; - return -1; - } - - /* check CRC word */ - - if (header->flags & MAD_FLAG_PROTECTION) { - header->crc_check = - mad_bit_crc(stream->ptr, si_len * CHAR_BIT, header->crc_check); - - if (header->crc_check != header->crc_target && - !(frame->options & MAD_OPTION_IGNORECRC)) { - stream->error = MAD_ERROR_BADCRC; - result = -1; - } - } - - /* decode frame side information */ - - error = III_sideinfo(&stream->ptr, nch, header->flags & MAD_FLAG_LSF_EXT, - &si, &data_bitlen, &priv_bitlen); - if (error && result == 0) { - stream->error = error; - result = -1; - } - - header->flags |= priv_bitlen; - header->private_bits |= si.private_bits; - - /* find main_data of next frame */ - - { - struct mad_bitptr peek; - unsigned long header; - - mad_bit_init(&peek, stream->next_frame); - - header = mad_bit_read(&peek, 32); - if ((header & 0xffe60000L) /* syncword | layer */ == 0xffe20000L) { - if (!(header & 0x00010000L)) /* protection_bit */ - mad_bit_skip(&peek, 16); /* crc_check */ - - next_md_begin = - mad_bit_read(&peek, (header & 0x00080000L) /* ID */ ? 9 : 8); - } - - mad_bit_finish(&peek); - } - - /* find main_data of this frame */ - - frame_space = stream->next_frame - mad_bit_nextbyte(&stream->ptr); - - if (next_md_begin > si.main_data_begin + frame_space) - next_md_begin = 0; - - md_len = si.main_data_begin + frame_space - next_md_begin; - - frame_used = 0; - - if (si.main_data_begin == 0) { - ptr = stream->ptr; - stream->md_len = 0; - - frame_used = md_len; - } - else { - if (si.main_data_begin > stream->md_len) { - if (result == 0) { - stream->error = MAD_ERROR_BADDATAPTR; - result = -1; - } - } - else { - mad_bit_init(&ptr, - *stream->main_data + stream->md_len - si.main_data_begin); - - if (md_len > si.main_data_begin) { - assert(stream->md_len + md_len - - si.main_data_begin <= MAD_BUFFER_MDLEN); - - int nCopy = md_len - si.main_data_begin; - if (nCopy > MAD_BUFFER_MDLEN - stream->md_len) - // PRL defend against an observed violation of the assertion above - nCopy = MAD_BUFFER_MDLEN - stream->md_len; - - memcpy(*stream->main_data + stream->md_len, - mad_bit_nextbyte(&stream->ptr), - frame_used = nCopy); - stream->md_len += frame_used; - } - } - } - - frame_free = frame_space - frame_used; - - /* decode main_data */ - - if (result == 0) { - error = III_decode(&ptr, frame, &si, nch); - if (error) { - stream->error = error; - result = -1; - } - - /* designate ancillary bits */ - - stream->anc_ptr = ptr; - stream->anc_bitlen = md_len * CHAR_BIT - data_bitlen; - } - -# if 0 && defined(DEBUG) - fprintf(stderr, - "main_data_begin:%u, md_len:%u, frame_free:%u, " - "data_bitlen:%u, anc_bitlen: %u\n", - si.main_data_begin, md_len, frame_free, - data_bitlen, stream->anc_bitlen); -# endif - - /* preload main_data buffer with up to 511 bytes for next frame(s) */ - - if (frame_free >= next_md_begin) { - memcpy(*stream->main_data, - stream->next_frame - next_md_begin, next_md_begin); - stream->md_len = next_md_begin; - } - else { - if (md_len < si.main_data_begin) { - unsigned int extra; - - extra = si.main_data_begin - md_len; - if (extra + frame_free > next_md_begin) - extra = next_md_begin - frame_free; - - if (extra < stream->md_len) { - memmove(*stream->main_data, - *stream->main_data + stream->md_len - extra, extra); - stream->md_len = extra; - } - } - else - stream->md_len = 0; - - memcpy(*stream->main_data + stream->md_len, - stream->next_frame - frame_free, frame_free); - stream->md_len += frame_free; - } - - return result; -} diff --git a/lib-src/libmad/layer3.h b/lib-src/libmad/layer3.h deleted file mode 100644 index b1541f97c..000000000 --- a/lib-src/libmad/layer3.h +++ /dev/null @@ -1,30 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: layer3.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_LAYER3_H -# define LIBMAD_LAYER3_H - -# include "stream.h" -# include "frame.h" - -int mad_layer_III(struct mad_stream *, struct mad_frame *); - -# endif diff --git a/lib-src/libmad/libmad-mp2-out-of-spec.patch b/lib-src/libmad/libmad-mp2-out-of-spec.patch deleted file mode 100644 index 1518deef1..000000000 --- a/lib-src/libmad/libmad-mp2-out-of-spec.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- ../../libmad-0.15.1b/layer12.c 2004-02-05 09:02:39.000000000 +0000 -+++ libmad/layer12.c 2006-10-19 11:44:19.000000000 +0100 -@@ -16,7 +16,7 @@ - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * -- * $Id: libmad-mp2-out-of-spec.patch,v 1.1 2008-02-01 20:29:07 richardash1981 Exp $ -+ * $Id: libmad-mp2-out-of-spec.patch,v 1.1 2008-02-01 20:29:07 richardash1981 Exp $ - */ - - # ifdef HAVE_CONFIG_H -@@ -363,6 +363,7 @@ - # endif - } - else { /* nch == 1 */ -+#if 0 /* relax restriction, those files do import fine! */ - if (bitrate_per_channel > 192000) { - /* - * ISO/IEC 11172-3 does not allow single channel mode for 224, 256, -@@ -371,6 +372,7 @@ - stream->error = MAD_ERROR_BADMODE; - return -1; - } -+#endif - } - - if (bitrate_per_channel <= 48000) diff --git a/lib-src/libmad/libmad.list.in b/lib-src/libmad/libmad.list.in deleted file mode 100644 index 4718fef3a..000000000 --- a/lib-src/libmad/libmad.list.in +++ /dev/null @@ -1,21 +0,0 @@ -# @configure_input@ - -# Directories... -$prefix=@prefix@ -$exec_prefix=@exec_prefix@ -$srcdir=@srcdir@ - -# Product information -%product @PACKAGE@ -%copyright GPL -%vendor Underbit Technologies, Inc. -%license @srcdir@/COPYING -%readme @srcdir@/README -%description libmad is an MPEG audio decoder library. -%version @VERSION@ -%packager Giuseppe "Cowo" Corbelli - -%system all -f 0755 root root @libdir@/libmad.la .libs/libmad.lai -f 0644 root root @libdir@/libmad.a .libs/libmad.a -f 0644 root root @includedir@/mad.h mad.h diff --git a/lib-src/libmad/libmad.vcproj b/lib-src/libmad/libmad.vcproj deleted file mode 100644 index 81d16d2f2..000000000 --- a/lib-src/libmad/libmad.vcproj +++ /dev/null @@ -1,1479 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/lib-src/libmad/ltmain.sh b/lib-src/libmad/ltmain.sh deleted file mode 100644 index a356acafa..000000000 --- a/lib-src/libmad/ltmain.sh +++ /dev/null @@ -1,9661 +0,0 @@ - -# libtool (GNU libtool) 2.4.2 -# Written by Gordon Matzigkeit , 1996 - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, -# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, -# or obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - -# Usage: $progname [OPTION]... [MODE-ARG]... -# -# Provide generalized library-building support services. -# -# --config show all configuration variables -# --debug enable verbose shell tracing -# -n, --dry-run display commands without modifying any files -# --features display basic configuration information and exit -# --mode=MODE use operation mode MODE -# --preserve-dup-deps don't remove duplicate dependency libraries -# --quiet, --silent don't print informational messages -# --no-quiet, --no-silent -# print informational messages (default) -# --no-warn don't display warning messages -# --tag=TAG use configuration variables from tag TAG -# -v, --verbose print more informational messages than default -# --no-verbose don't print the extra informational messages -# --version print version information -# -h, --help, --help-all print short, long, or detailed help message -# -# MODE must be one of the following: -# -# clean remove files from the build directory -# compile compile a source file into a libtool object -# execute automatically set library path, then run a program -# finish complete the installation of libtool libraries -# install install libraries or executables -# link create a library or an executable -# uninstall remove libraries from an installed directory -# -# MODE-ARGS vary depending on the MODE. When passed as first option, -# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. -# Try `$progname --help --mode=MODE' for a more detailed description of MODE. -# -# When reporting a bug, please describe a test case to reproduce it and -# include the following information: -# -# host-triplet: $host -# shell: $SHELL -# compiler: $LTCC -# compiler flags: $LTCFLAGS -# linker: $LD (gnu? $with_gnu_ld) -# $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.7ubuntu1 -# automake: $automake_version -# autoconf: $autoconf_version -# -# Report bugs to . -# GNU libtool home page: . -# General help using GNU software: . - -PROGRAM=libtool -PACKAGE=libtool -VERSION="2.4.2 Debian-2.4.2-1.7ubuntu1" -TIMESTAMP="" -package_revision=1.3337 - -# Be Bourne compatible -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' -} - -# NLS nuisances: We save the old values to restore during execute mode. -lt_user_locale= -lt_safe_locale= -for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES -do - eval "if test \"\${$lt_var+set}\" = set; then - save_$lt_var=\$$lt_var - $lt_var=C - export $lt_var - lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" - lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" - fi" -done -LC_ALL=C -LANGUAGE=C -export LANGUAGE LC_ALL - -$lt_unset CDPATH - - -# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh -# is ksh but when the shell is invoked as "sh" and the current value of -# the _XPG environment variable is not equal to 1 (one), the special -# positional parameter $0, within a function call, is the name of the -# function. -progpath="$0" - - - -: ${CP="cp -f"} -test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} -: ${MAKE="make"} -: ${MKDIR="mkdir"} -: ${MV="mv -f"} -: ${RM="rm -f"} -: ${SHELL="${CONFIG_SHELL-/bin/sh}"} -: ${Xsed="$SED -e 1s/^X//"} - -# Global variables: -EXIT_SUCCESS=0 -EXIT_FAILURE=1 -EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. -EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. - -exit_status=$EXIT_SUCCESS - -# Make sure IFS has a sensible default -lt_nl=' -' -IFS=" $lt_nl" - -dirname="s,/[^/]*$,," -basename="s,^.*/,," - -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi -} # func_dirname may be replaced by extended shell implementation - - -# func_basename file -func_basename () -{ - func_basename_result=`$ECHO "${1}" | $SED "$basename"` -} # func_basename may be replaced by extended shell implementation - - -# func_dirname_and_basename file append nondir_replacement -# perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# Implementation must be kept synchronized with func_dirname -# and func_basename. For efficiency, we do not delegate to -# those functions but instead duplicate the functionality here. -func_dirname_and_basename () -{ - # Extract subdirectory from the argument. - func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi - func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` -} # func_dirname_and_basename may be replaced by extended shell implementation - - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# func_strip_suffix prefix name -func_stripname () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; - esac -} # func_stripname may be replaced by extended shell implementation - - -# These SED scripts presuppose an absolute path with a trailing slash. -pathcar='s,^/\([^/]*\).*$,\1,' -pathcdr='s,^/[^/]*,,' -removedotparts=':dotsl - s@/\./@/@g - t dotsl - s,/\.$,/,' -collapseslashes='s@/\{1,\}@/@g' -finalslash='s,/*$,/,' - -# func_normal_abspath PATH -# Remove doubled-up and trailing slashes, "." path components, -# and cancel out any ".." path components in PATH after making -# it an absolute path. -# value returned in "$func_normal_abspath_result" -func_normal_abspath () -{ - # Start from root dir and reassemble the path. - func_normal_abspath_result= - func_normal_abspath_tpath=$1 - func_normal_abspath_altnamespace= - case $func_normal_abspath_tpath in - "") - # Empty path, that just means $cwd. - func_stripname '' '/' "`pwd`" - func_normal_abspath_result=$func_stripname_result - return - ;; - # The next three entries are used to spot a run of precisely - # two leading slashes without using negated character classes; - # we take advantage of case's first-match behaviour. - ///*) - # Unusual form of absolute path, do nothing. - ;; - //*) - # Not necessarily an ordinary path; POSIX reserves leading '//' - # and for example Cygwin uses it to access remote file shares - # over CIFS/SMB, so we conserve a leading double slash if found. - func_normal_abspath_altnamespace=/ - ;; - /*) - # Absolute path, do nothing. - ;; - *) - # Relative path, prepend $cwd. - func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath - ;; - esac - # Cancel out all the simple stuff to save iterations. We also want - # the path to end with a slash for ease of parsing, so make sure - # there is one (and only one) here. - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` - while :; do - # Processed it all yet? - if test "$func_normal_abspath_tpath" = / ; then - # If we ascended to the root using ".." the result may be empty now. - if test -z "$func_normal_abspath_result" ; then - func_normal_abspath_result=/ - fi - break - fi - func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcar"` - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$pathcdr"` - # Figure out what to do with it - case $func_normal_abspath_tcomponent in - "") - # Trailing empty path component, ignore it. - ;; - ..) - # Parent dir; strip last assembled component from result. - func_dirname "$func_normal_abspath_result" - func_normal_abspath_result=$func_dirname_result - ;; - *) - # Actual path component, append it. - func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent - ;; - esac - done - # Restore leading double-slash if one was found on entry. - func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result -} - -# func_relative_path SRCDIR DSTDIR -# generates a relative path from SRCDIR to DSTDIR, with a trailing -# slash if non-empty, suitable for immediately appending a filename -# without needing to append a separator. -# value returned in "$func_relative_path_result" -func_relative_path () -{ - func_relative_path_result= - func_normal_abspath "$1" - func_relative_path_tlibdir=$func_normal_abspath_result - func_normal_abspath "$2" - func_relative_path_tbindir=$func_normal_abspath_result - - # Ascend the tree starting from libdir - while :; do - # check if we have found a prefix of bindir - case $func_relative_path_tbindir in - $func_relative_path_tlibdir) - # found an exact match - func_relative_path_tcancelled= - break - ;; - $func_relative_path_tlibdir*) - # found a matching prefix - func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" - func_relative_path_tcancelled=$func_stripname_result - if test -z "$func_relative_path_result"; then - func_relative_path_result=. - fi - break - ;; - *) - func_dirname $func_relative_path_tlibdir - func_relative_path_tlibdir=${func_dirname_result} - if test "x$func_relative_path_tlibdir" = x ; then - # Have to descend all the way to the root! - func_relative_path_result=../$func_relative_path_result - func_relative_path_tcancelled=$func_relative_path_tbindir - break - fi - func_relative_path_result=../$func_relative_path_result - ;; - esac - done - - # Now calculate path; take care to avoid doubling-up slashes. - func_stripname '' '/' "$func_relative_path_result" - func_relative_path_result=$func_stripname_result - func_stripname '/' '/' "$func_relative_path_tcancelled" - if test "x$func_stripname_result" != x ; then - func_relative_path_result=${func_relative_path_result}/${func_stripname_result} - fi - - # Normalisation. If bindir is libdir, return empty string, - # else relative path ending with a slash; either way, target - # file name can be directly appended. - if test ! -z "$func_relative_path_result"; then - func_stripname './' '' "$func_relative_path_result/" - func_relative_path_result=$func_stripname_result - fi -} - -# The name of this program: -func_dirname_and_basename "$progpath" -progname=$func_basename_result - -# Make sure we have an absolute path for reexecution: -case $progpath in - [\\/]*|[A-Za-z]:\\*) ;; - *[\\/]*) - progdir=$func_dirname_result - progdir=`cd "$progdir" && pwd` - progpath="$progdir/$progname" - ;; - *) - save_IFS="$IFS" - IFS=${PATH_SEPARATOR-:} - for progdir in $PATH; do - IFS="$save_IFS" - test -x "$progdir/$progname" && break - done - IFS="$save_IFS" - test -n "$progdir" || progdir=`pwd` - progpath="$progdir/$progname" - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed="${SED}"' -e 1s/^X//' -sed_quote_subst='s/\([`"$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution that turns a string into a regex matching for the -# string literally. -sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' - -# Sed substitution that converts a w32 file name or path -# which contains forward slashes, into one that contains -# (escaped) backslashes. A very naive implementation. -lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - -# Re-`\' parameter expansions in output of double_quote_subst that were -# `\'-ed in input to the same. If an odd number of `\' preceded a '$' -# in input to double_quote_subst, that '$' was protected from expansion. -# Since each input `\' is now two `\'s, look for any number of runs of -# four `\'s followed by two `\'s and then a '$'. `\' that '$'. -bs='\\' -bs2='\\\\' -bs4='\\\\\\\\' -dollar='\$' -sed_double_backslash="\ - s/$bs4/&\\ -/g - s/^$bs2$dollar/$bs&/ - s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g - s/\n//g" - -# Standard options: -opt_dry_run=false -opt_help=false -opt_quiet=false -opt_verbose=false -opt_warning=: - -# func_echo arg... -# Echo program name prefixed message, along with the current mode -# name if it has been set yet. -func_echo () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }$*" -} - -# func_verbose arg... -# Echo program name prefixed message in verbose mode only. -func_verbose () -{ - $opt_verbose && func_echo ${1+"$@"} - - # A bug in bash halts the script if the last line of a function - # fails when set -e is in force, so we need another command to - # work around that: - : -} - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -# func_error arg... -# Echo program name prefixed message to standard error. -func_error () -{ - $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 -} - -# func_warning arg... -# Echo program name prefixed warning message to standard error. -func_warning () -{ - $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 - - # bash bug again: - : -} - -# func_fatal_error arg... -# Echo program name prefixed message to standard error, and exit. -func_fatal_error () -{ - func_error ${1+"$@"} - exit $EXIT_FAILURE -} - -# func_fatal_help arg... -# Echo program name prefixed message to standard error, followed by -# a help hint, and exit. -func_fatal_help () -{ - func_error ${1+"$@"} - func_fatal_error "$help" -} -help="Try \`$progname --help' for more information." ## default - - -# func_grep expression filename -# Check whether EXPRESSION matches any line of FILENAME, without output. -func_grep () -{ - $GREP "$1" "$2" >/dev/null 2>&1 -} - - -# func_mkdir_p directory-path -# Make sure the entire path to DIRECTORY-PATH is available. -func_mkdir_p () -{ - my_directory_path="$1" - my_dir_list= - - if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then - - # Protect directory names starting with `-' - case $my_directory_path in - -*) my_directory_path="./$my_directory_path" ;; - esac - - # While some portion of DIR does not yet exist... - while test ! -d "$my_directory_path"; do - # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. - my_dir_list="$my_directory_path:$my_dir_list" - - # If the last portion added has no slash in it, the list is done - case $my_directory_path in */*) ;; *) break ;; esac - - # ...otherwise throw away the child directory and loop - my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` - done - my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` - - save_mkdir_p_IFS="$IFS"; IFS=':' - for my_dir in $my_dir_list; do - IFS="$save_mkdir_p_IFS" - # mkdir can fail with a `File exist' error if two processes - # try to create one of the directories concurrently. Don't - # stop in that case! - $MKDIR "$my_dir" 2>/dev/null || : - done - IFS="$save_mkdir_p_IFS" - - # Bail out if we (or some other process) failed to create a directory. - test -d "$my_directory_path" || \ - func_fatal_error "Failed to create \`$1'" - fi -} - - -# func_mktempdir [string] -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, STRING is the basename for that directory. -func_mktempdir () -{ - my_template="${TMPDIR-/tmp}/${1-$progname}" - - if test "$opt_dry_run" = ":"; then - # Return a directory name, but don't create it in dry-run mode - my_tmpdir="${my_template}-$$" - else - - # If mktemp works, use that first and foremost - my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` - - if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" - - save_mktempdir_umask=`umask` - umask 0077 - $MKDIR "$my_tmpdir" - umask $save_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || \ - func_fatal_error "cannot create temporary directory \`$my_tmpdir'" - fi - - $ECHO "$my_tmpdir" -} - - -# func_quote_for_eval arg -# Aesthetically quote ARG to be evaled later. -# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT -# is double-quoted, suitable for a subsequent eval, whereas -# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters -# which are still active within double quotes backslashified. -func_quote_for_eval () -{ - case $1 in - *[\\\`\"\$]*) - func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; - *) - func_quote_for_eval_unquoted_result="$1" ;; - esac - - case $func_quote_for_eval_unquoted_result in - # Double-quote args containing shell metacharacters to delay - # word splitting, command substitution and and variable - # expansion for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" - ;; - *) - func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" - esac -} - - -# func_quote_for_expand arg -# Aesthetically quote ARG to be evaled later; same as above, -# but do not quote variable references. -func_quote_for_expand () -{ - case $1 in - *[\\\`\"]*) - my_arg=`$ECHO "$1" | $SED \ - -e "$double_quote_subst" -e "$sed_double_backslash"` ;; - *) - my_arg="$1" ;; - esac - - case $my_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting and command substitution for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - my_arg="\"$my_arg\"" - ;; - esac - - func_quote_for_expand_result="$my_arg" -} - - -# func_show_eval cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. -func_show_eval () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$my_cmd" - my_status=$? - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - - -# func_show_eval_locale cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. Use the saved locale for evaluation. -func_show_eval_locale () -{ - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$lt_user_locale - $my_cmd" - my_status=$? - eval "$lt_safe_locale" - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi - fi -} - -# func_tr_sh -# Turn $1 into a string suitable for a shell variable name. -# Result is stored in $func_tr_sh_result. All characters -# not in the set a-zA-Z0-9_ are replaced with '_'. Further, -# if $1 begins with a digit, a '_' is prepended as well. -func_tr_sh () -{ - case $1 in - [0-9]* | *[!a-zA-Z0-9_]*) - func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` - ;; - * ) - func_tr_sh_result=$1 - ;; - esac -} - - -# func_version -# Echo version message to standard output and exit. -func_version () -{ - $opt_debug - - $SED -n '/(C)/!b go - :more - /\./!{ - N - s/\n# / / - b more - } - :go - /^# '$PROGRAM' (GNU /,/# warranty; / { - s/^# // - s/^# *$// - s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ - p - }' < "$progpath" - exit $? -} - -# func_usage -# Echo short help message to standard output and exit. -func_usage () -{ - $opt_debug - - $SED -n '/^# Usage:/,/^# *.*--help/ { - s/^# // - s/^# *$// - s/\$progname/'$progname'/ - p - }' < "$progpath" - echo - $ECHO "run \`$progname --help | more' for full usage" - exit $? -} - -# func_help [NOEXIT] -# Echo long help message to standard output and exit, -# unless 'noexit' is passed as argument. -func_help () -{ - $opt_debug - - $SED -n '/^# Usage:/,/# Report bugs to/ { - :print - s/^# // - s/^# *$// - s*\$progname*'$progname'* - s*\$host*'"$host"'* - s*\$SHELL*'"$SHELL"'* - s*\$LTCC*'"$LTCC"'* - s*\$LTCFLAGS*'"$LTCFLAGS"'* - s*\$LD*'"$LD"'* - s/\$with_gnu_ld/'"$with_gnu_ld"'/ - s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/ - s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/ - p - d - } - /^# .* home page:/b print - /^# General help using/b print - ' < "$progpath" - ret=$? - if test -z "$1"; then - exit $ret - fi -} - -# func_missing_arg argname -# Echo program name prefixed message to standard error and set global -# exit_cmd. -func_missing_arg () -{ - $opt_debug - - func_error "missing argument for $1." - exit_cmd=exit -} - - -# func_split_short_opt shortopt -# Set func_split_short_opt_name and func_split_short_opt_arg shell -# variables after splitting SHORTOPT after the 2nd character. -func_split_short_opt () -{ - my_sed_short_opt='1s/^\(..\).*$/\1/;q' - my_sed_short_rest='1s/^..\(.*\)$/\1/;q' - - func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` - func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` -} # func_split_short_opt may be replaced by extended shell implementation - - -# func_split_long_opt longopt -# Set func_split_long_opt_name and func_split_long_opt_arg shell -# variables after splitting LONGOPT at the `=' sign. -func_split_long_opt () -{ - my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' - my_sed_long_arg='1s/^--[^=]*=//' - - func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` - func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` -} # func_split_long_opt may be replaced by extended shell implementation - -exit_cmd=: - - - - - -magic="%%%MAGIC variable%%%" -magic_exe="%%%MAGIC EXE variable%%%" - -# Global variables. -nonopt= -preserve_args= -lo2o="s/\\.lo\$/.${objext}/" -o2lo="s/\\.${objext}\$/.lo/" -extracted_archives= -extracted_serial=0 - -# If this variable is set in any of the actions, the command in it -# will be execed at the end. This prevents here-documents from being -# left over by shells. -exec_cmd= - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "${1}=\$${1}\${2}" -} # func_append may be replaced by extended shell implementation - -# func_append_quoted var value -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -func_append_quoted () -{ - func_quote_for_eval "${2}" - eval "${1}=\$${1}\\ \$func_quote_for_eval_result" -} # func_append_quoted may be replaced by extended shell implementation - - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "${@}"` -} # func_arith may be replaced by extended shell implementation - - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` -} # func_len may be replaced by extended shell implementation - - -# func_lo2o object -func_lo2o () -{ - func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` -} # func_lo2o may be replaced by extended shell implementation - - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` -} # func_xform may be replaced by extended shell implementation - - -# func_fatal_configuration arg... -# Echo program name prefixed message to standard error, followed by -# a configuration failure hint, and exit. -func_fatal_configuration () -{ - func_error ${1+"$@"} - func_error "See the $PACKAGE documentation for more information." - func_fatal_error "Fatal configuration error." -} - - -# func_config -# Display the configuration for all the tags in this script. -func_config () -{ - re_begincf='^# ### BEGIN LIBTOOL' - re_endcf='^# ### END LIBTOOL' - - # Default configuration. - $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" - - # Now print the configurations for the tags. - for tagname in $taglist; do - $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" - done - - exit $? -} - -# func_features -# Display the features supported by this script. -func_features () -{ - echo "host: $host" - if test "$build_libtool_libs" = yes; then - echo "enable shared libraries" - else - echo "disable shared libraries" - fi - if test "$build_old_libs" = yes; then - echo "enable static libraries" - else - echo "disable static libraries" - fi - - exit $? -} - -# func_enable_tag tagname -# Verify that TAGNAME is valid, and either flag an error and exit, or -# enable the TAGNAME tag. We also add TAGNAME to the global $taglist -# variable here. -func_enable_tag () -{ - # Global variable: - tagname="$1" - - re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" - re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" - sed_extractcf="/$re_begincf/,/$re_endcf/p" - - # Validate tagname. - case $tagname in - *[!-_A-Za-z0-9,/]*) - func_fatal_error "invalid tag name: $tagname" - ;; - esac - - # Don't test for the "default" C tag, as we know it's - # there but not specially marked. - case $tagname in - CC) ;; - *) - if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then - taglist="$taglist $tagname" - - # Evaluate the configuration. Be careful to quote the path - # and the sed script, to avoid splitting on whitespace, but - # also don't use non-portable quotes within backquotes within - # quotes we have to do it in 2 steps: - extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` - eval "$extractedcf" - else - func_error "ignoring unknown tag $tagname" - fi - ;; - esac -} - -# func_check_version_match -# Ensure that we are using m4 macros, and libtool script from the same -# release of libtool. -func_check_version_match () -{ - if test "$package_revision" != "$macro_revision"; then - if test "$VERSION" != "$macro_version"; then - if test -z "$macro_version"; then - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from an older release. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - fi - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, -$progname: but the definition of this LT_INIT comes from revision $macro_revision. -$progname: You should recreate aclocal.m4 with macros from revision $package_revision -$progname: of $PACKAGE $VERSION and run autoconf again. -_LT_EOF - fi - - exit $EXIT_MISMATCH - fi -} - - -# Shorthand for --mode=foo, only valid as the first argument -case $1 in -clean|clea|cle|cl) - shift; set dummy --mode clean ${1+"$@"}; shift - ;; -compile|compil|compi|comp|com|co|c) - shift; set dummy --mode compile ${1+"$@"}; shift - ;; -execute|execut|execu|exec|exe|ex|e) - shift; set dummy --mode execute ${1+"$@"}; shift - ;; -finish|finis|fini|fin|fi|f) - shift; set dummy --mode finish ${1+"$@"}; shift - ;; -install|instal|insta|inst|ins|in|i) - shift; set dummy --mode install ${1+"$@"}; shift - ;; -link|lin|li|l) - shift; set dummy --mode link ${1+"$@"}; shift - ;; -uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) - shift; set dummy --mode uninstall ${1+"$@"}; shift - ;; -esac - - - -# Option defaults: -opt_debug=: -opt_dry_run=false -opt_config=false -opt_preserve_dup_deps=false -opt_features=false -opt_finish=false -opt_help=false -opt_help_all=false -opt_silent=: -opt_warning=: -opt_verbose=: -opt_silent=false -opt_verbose=false - - -# Parse options once, thoroughly. This comes as soon as possible in the -# script to make things like `--version' happen as quickly as we can. -{ - # this just eases exit handling - while test $# -gt 0; do - opt="$1" - shift - case $opt in - --debug|-x) opt_debug='set -x' - func_echo "enabling shell trace mode" - $opt_debug - ;; - --dry-run|--dryrun|-n) - opt_dry_run=: - ;; - --config) - opt_config=: -func_config - ;; - --dlopen|-dlopen) - optarg="$1" - opt_dlopen="${opt_dlopen+$opt_dlopen -}$optarg" - shift - ;; - --preserve-dup-deps) - opt_preserve_dup_deps=: - ;; - --features) - opt_features=: -func_features - ;; - --finish) - opt_finish=: -set dummy --mode finish ${1+"$@"}; shift - ;; - --help) - opt_help=: - ;; - --help-all) - opt_help_all=: -opt_help=': help-all' - ;; - --mode) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_mode="$optarg" -case $optarg in - # Valid mode arguments: - clean|compile|execute|finish|install|link|relink|uninstall) ;; - - # Catch anything else as an error - *) func_error "invalid argument for $opt" - exit_cmd=exit - break - ;; -esac - shift - ;; - --no-silent|--no-quiet) - opt_silent=false -func_append preserve_args " $opt" - ;; - --no-warning|--no-warn) - opt_warning=false -func_append preserve_args " $opt" - ;; - --no-verbose) - opt_verbose=false -func_append preserve_args " $opt" - ;; - --silent|--quiet) - opt_silent=: -func_append preserve_args " $opt" - opt_verbose=false - ;; - --verbose|-v) - opt_verbose=: -func_append preserve_args " $opt" -opt_silent=false - ;; - --tag) - test $# = 0 && func_missing_arg $opt && break - optarg="$1" - opt_tag="$optarg" -func_append preserve_args " $opt $optarg" -func_enable_tag "$optarg" - shift - ;; - - -\?|-h) func_usage ;; - --help) func_help ;; - --version) func_version ;; - - # Separate optargs to long options: - --*=*) - func_split_long_opt "$opt" - set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} - shift - ;; - - # Separate non-argument short options: - -\?*|-h*|-n*|-v*) - func_split_short_opt "$opt" - set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - - --) break ;; - -*) func_fatal_help "unrecognized option \`$opt'" ;; - *) set dummy "$opt" ${1+"$@"}; shift; break ;; - esac - done - - # Validate options: - - # save first non-option argument - if test "$#" -gt 0; then - nonopt="$opt" - shift - fi - - # preserve --debug - test "$opt_debug" = : || func_append preserve_args " --debug" - - case $host in - *cygwin* | *mingw* | *pw32* | *cegcc*) - # don't eliminate duplications in $postdeps and $predeps - opt_duplicate_compiler_generated_deps=: - ;; - *) - opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps - ;; - esac - - $opt_help || { - # Sanity checks first: - func_check_version_match - - if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then - func_fatal_configuration "not configured to build any kind of library" - fi - - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" - - # Only execute mode is allowed to have -dlopen flags. - if test -n "$opt_dlopen" && test "$opt_mode" != execute; then - func_error "unrecognized option \`-dlopen'" - $ECHO "$help" 1>&2 - exit $EXIT_FAILURE - fi - - # Change the help message to a mode-specific one. - generic_help="$help" - help="Try \`$progname --help --mode=$opt_mode' for more information." - } - - - # Bail if the options were screwed - $exit_cmd $EXIT_FAILURE -} - - - - -## ----------- ## -## Main. ## -## ----------- ## - -# func_lalib_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_lalib_p () -{ - test -f "$1" && - $SED -e 4q "$1" 2>/dev/null \ - | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 -} - -# func_lalib_unsafe_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function implements the same check as func_lalib_p without -# resorting to external programs. To this end, it redirects stdin and -# closes it afterwards, without saving the original file descriptor. -# As a safety measure, use it only where a negative result would be -# fatal anyway. Works if `file' does not exist. -func_lalib_unsafe_p () -{ - lalib_p=no - if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then - for lalib_p_l in 1 2 3 4 - do - read lalib_p_line - case "$lalib_p_line" in - \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; - esac - done - exec 0<&5 5<&- - fi - test "$lalib_p" = yes -} - -# func_ltwrapper_script_p file -# True iff FILE is a libtool wrapper script -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_script_p () -{ - func_lalib_p "$1" -} - -# func_ltwrapper_executable_p file -# True iff FILE is a libtool wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_executable_p () -{ - func_ltwrapper_exec_suffix= - case $1 in - *.exe) ;; - *) func_ltwrapper_exec_suffix=.exe ;; - esac - $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 -} - -# func_ltwrapper_scriptname file -# Assumes file is an ltwrapper_executable -# uses $file to determine the appropriate filename for a -# temporary ltwrapper_script. -func_ltwrapper_scriptname () -{ - func_dirname_and_basename "$1" "" "." - func_stripname '' '.exe' "$func_basename_result" - func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" -} - -# func_ltwrapper_p file -# True iff FILE is a libtool wrapper script or wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_p () -{ - func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" -} - - -# func_execute_cmds commands fail_cmd -# Execute tilde-delimited COMMANDS. -# If FAIL_CMD is given, eval that upon failure. -# FAIL_CMD may read-access the current command in variable CMD! -func_execute_cmds () -{ - $opt_debug - save_ifs=$IFS; IFS='~' - for cmd in $1; do - IFS=$save_ifs - eval cmd=\"$cmd\" - func_show_eval "$cmd" "${2-:}" - done - IFS=$save_ifs -} - - -# func_source file -# Source FILE, adding directory component if necessary. -# Note that it is not necessary on cygwin/mingw to append a dot to -# FILE even if both FILE and FILE.exe exist: automatic-append-.exe -# behavior happens only for exec(3), not for open(2)! Also, sourcing -# `FILE.' does not work on cygwin managed mounts. -func_source () -{ - $opt_debug - case $1 in - */* | *\\*) . "$1" ;; - *) . "./$1" ;; - esac -} - - -# func_resolve_sysroot PATH -# Replace a leading = in PATH with a sysroot. Store the result into -# func_resolve_sysroot_result -func_resolve_sysroot () -{ - func_resolve_sysroot_result=$1 - case $func_resolve_sysroot_result in - =*) - func_stripname '=' '' "$func_resolve_sysroot_result" - func_resolve_sysroot_result=$lt_sysroot$func_stripname_result - ;; - esac -} - -# func_replace_sysroot PATH -# If PATH begins with the sysroot, replace it with = and -# store the result into func_replace_sysroot_result. -func_replace_sysroot () -{ - case "$lt_sysroot:$1" in - ?*:"$lt_sysroot"*) - func_stripname "$lt_sysroot" '' "$1" - func_replace_sysroot_result="=$func_stripname_result" - ;; - *) - # Including no sysroot. - func_replace_sysroot_result=$1 - ;; - esac -} - -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () -{ - $opt_debug - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. - *) - for z in $available_tags; do - if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case "$@ " in - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - func_echo "unable to infer tagged configuration" - func_fatal_error "specify a tag with \`--tag'" -# else -# func_verbose "using $tagname tagged configuration" - fi - ;; - esac - fi -} - - - -# func_write_libtool_object output_name pic_name nonpic_name -# Create a libtool object file (analogous to a ".la" file), -# but don't create it if we're doing a dry run. -func_write_libtool_object () -{ - write_libobj=${1} - if test "$build_libtool_libs" = yes; then - write_lobj=\'${2}\' - else - write_lobj=none - fi - - if test "$build_old_libs" = yes; then - write_oldobj=\'${3}\' - else - write_oldobj=none - fi - - $opt_dry_run || { - cat >${write_libobj}T </dev/null` - if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then - func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | - $SED -e "$lt_sed_naive_backslashify"` - else - func_convert_core_file_wine_to_w32_result= - fi - fi -} -# end: func_convert_core_file_wine_to_w32 - - -# func_convert_core_path_wine_to_w32 ARG -# Helper function used by path conversion functions when $build is *nix, and -# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly -# configured wine environment available, with the winepath program in $build's -# $PATH. Assumes ARG has no leading or trailing path separator characters. -# -# ARG is path to be converted from $build format to win32. -# Result is available in $func_convert_core_path_wine_to_w32_result. -# Unconvertible file (directory) names in ARG are skipped; if no directory names -# are convertible, then the result may be empty. -func_convert_core_path_wine_to_w32 () -{ - $opt_debug - # unfortunately, winepath doesn't convert paths, only file names - func_convert_core_path_wine_to_w32_result="" - if test -n "$1"; then - oldIFS=$IFS - IFS=: - for func_convert_core_path_wine_to_w32_f in $1; do - IFS=$oldIFS - func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" - if test -n "$func_convert_core_file_wine_to_w32_result" ; then - if test -z "$func_convert_core_path_wine_to_w32_result"; then - func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" - else - func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" - fi - fi - done - IFS=$oldIFS - fi -} -# end: func_convert_core_path_wine_to_w32 - - -# func_cygpath ARGS... -# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when -# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) -# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or -# (2), returns the Cygwin file name or path in func_cygpath_result (input -# file name or path is assumed to be in w32 format, as previously converted -# from $build's *nix or MSYS format). In case (3), returns the w32 file name -# or path in func_cygpath_result (input file name or path is assumed to be in -# Cygwin format). Returns an empty string on error. -# -# ARGS are passed to cygpath, with the last one being the file name or path to -# be converted. -# -# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH -# environment variable; do not put it in $PATH. -func_cygpath () -{ - $opt_debug - if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then - func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` - if test "$?" -ne 0; then - # on failure, ensure result is empty - func_cygpath_result= - fi - else - func_cygpath_result= - func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" - fi -} -#end: func_cygpath - - -# func_convert_core_msys_to_w32 ARG -# Convert file name or path ARG from MSYS format to w32 format. Return -# result in func_convert_core_msys_to_w32_result. -func_convert_core_msys_to_w32 () -{ - $opt_debug - # awkward: cmd appends spaces to result - func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | - $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` -} -#end: func_convert_core_msys_to_w32 - - -# func_convert_file_check ARG1 ARG2 -# Verify that ARG1 (a file name in $build format) was converted to $host -# format in ARG2. Otherwise, emit an error message, but continue (resetting -# func_to_host_file_result to ARG1). -func_convert_file_check () -{ - $opt_debug - if test -z "$2" && test -n "$1" ; then - func_error "Could not determine host file name corresponding to" - func_error " \`$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback: - func_to_host_file_result="$1" - fi -} -# end func_convert_file_check - - -# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH -# Verify that FROM_PATH (a path in $build format) was converted to $host -# format in TO_PATH. Otherwise, emit an error message, but continue, resetting -# func_to_host_file_result to a simplistic fallback value (see below). -func_convert_path_check () -{ - $opt_debug - if test -z "$4" && test -n "$3"; then - func_error "Could not determine the host path corresponding to" - func_error " \`$3'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback. This is a deliberately simplistic "conversion" and - # should not be "improved". See libtool.info. - if test "x$1" != "x$2"; then - lt_replace_pathsep_chars="s|$1|$2|g" - func_to_host_path_result=`echo "$3" | - $SED -e "$lt_replace_pathsep_chars"` - else - func_to_host_path_result="$3" - fi - fi -} -# end func_convert_path_check - - -# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG -# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT -# and appending REPL if ORIG matches BACKPAT. -func_convert_path_front_back_pathsep () -{ - $opt_debug - case $4 in - $1 ) func_to_host_path_result="$3$func_to_host_path_result" - ;; - esac - case $4 in - $2 ) func_append func_to_host_path_result "$3" - ;; - esac -} -# end func_convert_path_front_back_pathsep - - -################################################## -# $build to $host FILE NAME CONVERSION FUNCTIONS # -################################################## -# invoked via `$to_host_file_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# Result will be available in $func_to_host_file_result. - - -# func_to_host_file ARG -# Converts the file name ARG from $build format to $host format. Return result -# in func_to_host_file_result. -func_to_host_file () -{ - $opt_debug - $to_host_file_cmd "$1" -} -# end func_to_host_file - - -# func_to_tool_file ARG LAZY -# converts the file name ARG from $build format to toolchain format. Return -# result in func_to_tool_file_result. If the conversion in use is listed -# in (the comma separated) LAZY, no conversion takes place. -func_to_tool_file () -{ - $opt_debug - case ,$2, in - *,"$to_tool_file_cmd",*) - func_to_tool_file_result=$1 - ;; - *) - $to_tool_file_cmd "$1" - func_to_tool_file_result=$func_to_host_file_result - ;; - esac -} -# end func_to_tool_file - - -# func_convert_file_noop ARG -# Copy ARG to func_to_host_file_result. -func_convert_file_noop () -{ - func_to_host_file_result="$1" -} -# end func_convert_file_noop - - -# func_convert_file_msys_to_w32 ARG -# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_file_result. -func_convert_file_msys_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_to_host_file_result="$func_convert_core_msys_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_w32 - - -# func_convert_file_cygwin_to_w32 ARG -# Convert file name ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_file_cygwin_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # because $build is cygwin, we call "the" cygpath in $PATH; no need to use - # LT_CYGPATH in this case. - func_to_host_file_result=`cygpath -m "$1"` - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_cygwin_to_w32 - - -# func_convert_file_nix_to_w32 ARG -# Convert file name ARG from *nix to w32 format. Requires a wine environment -# and a working winepath. Returns result in func_to_host_file_result. -func_convert_file_nix_to_w32 () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_file_wine_to_w32 "$1" - func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_w32 - - -# func_convert_file_msys_to_cygwin ARG -# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_file_msys_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_cygpath -u "$func_convert_core_msys_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_cygwin - - -# func_convert_file_nix_to_cygwin ARG -# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed -# in a wine environment, working winepath, and LT_CYGPATH set. Returns result -# in func_to_host_file_result. -func_convert_file_nix_to_cygwin () -{ - $opt_debug - func_to_host_file_result="$1" - if test -n "$1"; then - # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. - func_convert_core_file_wine_to_w32 "$1" - func_cygpath -u "$func_convert_core_file_wine_to_w32_result" - func_to_host_file_result="$func_cygpath_result" - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_cygwin - - -############################################# -# $build to $host PATH CONVERSION FUNCTIONS # -############################################# -# invoked via `$to_host_path_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# The result will be available in $func_to_host_path_result. -# -# Path separators are also converted from $build format to $host format. If -# ARG begins or ends with a path separator character, it is preserved (but -# converted to $host format) on output. -# -# All path conversion functions are named using the following convention: -# file name conversion function : func_convert_file_X_to_Y () -# path conversion function : func_convert_path_X_to_Y () -# where, for any given $build/$host combination the 'X_to_Y' value is the -# same. If conversion functions are added for new $build/$host combinations, -# the two new functions must follow this pattern, or func_init_to_host_path_cmd -# will break. - - -# func_init_to_host_path_cmd -# Ensures that function "pointer" variable $to_host_path_cmd is set to the -# appropriate value, based on the value of $to_host_file_cmd. -to_host_path_cmd= -func_init_to_host_path_cmd () -{ - $opt_debug - if test -z "$to_host_path_cmd"; then - func_stripname 'func_convert_file_' '' "$to_host_file_cmd" - to_host_path_cmd="func_convert_path_${func_stripname_result}" - fi -} - - -# func_to_host_path ARG -# Converts the path ARG from $build format to $host format. Return result -# in func_to_host_path_result. -func_to_host_path () -{ - $opt_debug - func_init_to_host_path_cmd - $to_host_path_cmd "$1" -} -# end func_to_host_path - - -# func_convert_path_noop ARG -# Copy ARG to func_to_host_path_result. -func_convert_path_noop () -{ - func_to_host_path_result="$1" -} -# end func_convert_path_noop - - -# func_convert_path_msys_to_w32 ARG -# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_path_result. -func_convert_path_msys_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from ARG. MSYS - # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; - # and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_msys_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_msys_to_w32 - - -# func_convert_path_cygwin_to_w32 ARG -# Convert path ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_path_cygwin_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_cygwin_to_w32 - - -# func_convert_path_nix_to_w32 ARG -# Convert path ARG from *nix to w32 format. Requires a wine environment and -# a working winepath. Returns result in func_to_host_file_result. -func_convert_path_nix_to_w32 () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_nix_to_w32 - - -# func_convert_path_msys_to_cygwin ARG -# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_path_msys_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_msys_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_msys_to_cygwin - - -# func_convert_path_nix_to_cygwin ARG -# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a -# a wine environment, working winepath, and LT_CYGPATH set. Returns result in -# func_to_host_file_result. -func_convert_path_nix_to_cygwin () -{ - $opt_debug - func_to_host_path_result="$1" - if test -n "$1"; then - # Remove leading and trailing path separator characters from - # ARG. msys behavior is inconsistent here, cygpath turns them - # into '.;' and ';.', and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" - func_to_host_path_result="$func_cygpath_result" - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_nix_to_cygwin - - -# func_mode_compile arg... -func_mode_compile () -{ - $opt_debug - # Get the compilation command and the source file. - base_compile= - srcfile="$nonopt" # always keep a non-empty value in "srcfile" - suppress_opt=yes - suppress_output= - arg_mode=normal - libobj= - later= - pie_flag= - - for arg - do - case $arg_mode in - arg ) - # do not "continue". Instead, add this to base_compile - lastarg="$arg" - arg_mode=normal - ;; - - target ) - libobj="$arg" - arg_mode=normal - continue - ;; - - normal ) - # Accept any command-line options. - case $arg in - -o) - test -n "$libobj" && \ - func_fatal_error "you cannot specify \`-o' more than once" - arg_mode=target - continue - ;; - - -pie | -fpie | -fPIE) - func_append pie_flag " $arg" - continue - ;; - - -shared | -static | -prefer-pic | -prefer-non-pic) - func_append later " $arg" - continue - ;; - - -no-suppress) - suppress_opt=no - continue - ;; - - -Xcompiler) - arg_mode=arg # the next one goes into the "base_compile" arg list - continue # The current "srcfile" will either be retained or - ;; # replaced later. I would guess that would be a bug. - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - lastarg= - save_ifs="$IFS"; IFS=',' - for arg in $args; do - IFS="$save_ifs" - func_append_quoted lastarg "$arg" - done - IFS="$save_ifs" - func_stripname ' ' '' "$lastarg" - lastarg=$func_stripname_result - - # Add the arguments to base_compile. - func_append base_compile " $lastarg" - continue - ;; - - *) - # Accept the current argument as the source file. - # The previous "srcfile" becomes the current argument. - # - lastarg="$srcfile" - srcfile="$arg" - ;; - esac # case $arg - ;; - esac # case $arg_mode - - # Aesthetically quote the previous argument. - func_append_quoted base_compile "$lastarg" - done # for arg - - case $arg_mode in - arg) - func_fatal_error "you must specify an argument for -Xcompile" - ;; - target) - func_fatal_error "you must specify a target with \`-o'" - ;; - *) - # Get the name of the library object. - test -z "$libobj" && { - func_basename "$srcfile" - libobj="$func_basename_result" - } - ;; - esac - - # Recognize several different file suffixes. - # If the user specifies -o file.o, it is replaced with file.lo - case $libobj in - *.[cCFSifmso] | \ - *.ada | *.adb | *.ads | *.asm | \ - *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ - *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) - func_xform "$libobj" - libobj=$func_xform_result - ;; - esac - - case $libobj in - *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; - *) - func_fatal_error "cannot determine name of library object from \`$libobj'" - ;; - esac - - func_infer_tag $base_compile - - for arg in $later; do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - continue - ;; - - -static) - build_libtool_libs=no - build_old_libs=yes - continue - ;; - - -prefer-pic) - pic_mode=yes - continue - ;; - - -prefer-non-pic) - pic_mode=no - continue - ;; - esac - done - - func_quote_for_eval "$libobj" - test "X$libobj" != "X$func_quote_for_eval_result" \ - && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && func_warning "libobj name \`$libobj' may not contain shell special characters." - func_dirname_and_basename "$obj" "/" "" - objname="$func_basename_result" - xdir="$func_dirname_result" - lobj=${xdir}$objdir/$objname - - test -z "$base_compile" && \ - func_fatal_help "you must specify a compilation command" - - # Delete any leftover library objects. - if test "$build_old_libs" = yes; then - removelist="$obj $lobj $libobj ${libobj}T" - else - removelist="$lobj $libobj ${libobj}T" - fi - - # On Cygwin there's no "real" PIC flag so we must build both object types - case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) - pic_mode=default - ;; - esac - if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then - # non-PIC code in shared libraries is not supported - pic_mode=default - fi - - # Calculate the filename of the output object if compiler does - # not support -o with -c - if test "$compiler_c_o" = no; then - output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} - lockfile="$output_obj.lock" - else - output_obj= - need_locks=no - lockfile= - fi - - # Lock this critical section if it is needed - # We use this script file to make the link, it avoids creating a new file - if test "$need_locks" = yes; then - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - elif test "$need_locks" = warn; then - if test -f "$lockfile"; then - $ECHO "\ -*** ERROR, $lockfile exists and contains: -`cat $lockfile 2>/dev/null` - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - func_append removelist " $output_obj" - $ECHO "$srcfile" > "$lockfile" - fi - - $opt_dry_run || $RM $removelist - func_append removelist " $lockfile" - trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - - func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 - srcfile=$func_to_tool_file_result - func_quote_for_eval "$srcfile" - qsrcfile=$func_quote_for_eval_result - - # Only build a PIC object if we are building libtool libraries. - if test "$build_libtool_libs" = yes; then - # Without this assignment, base_compile gets emptied. - fbsd_hideous_sh_bug=$base_compile - - if test "$pic_mode" != no; then - command="$base_compile $qsrcfile $pic_flag" - else - # Don't build PIC code - command="$base_compile $qsrcfile" - fi - - func_mkdir_p "$xdir$objdir" - - if test -z "$output_obj"; then - # Place PIC objects in $objdir - func_append command " -o $lobj" - fi - - func_show_eval_locale "$command" \ - 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed, then go on to compile the next one - if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - func_show_eval '$MV "$output_obj" "$lobj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - - # Allow error messages only from the first compilation. - if test "$suppress_opt" = yes; then - suppress_output=' >/dev/null 2>&1' - fi - fi - - # Only build a position-dependent object if we build old libraries. - if test "$build_old_libs" = yes; then - if test "$pic_mode" != yes; then - # Don't build PIC code - command="$base_compile $qsrcfile$pie_flag" - else - command="$base_compile $qsrcfile $pic_flag" - fi - if test "$compiler_c_o" = yes; then - func_append command " -o $obj" - fi - - # Suppress compiler output if we already did a PIC compilation. - func_append command "$suppress_output" - func_show_eval_locale "$command" \ - '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' - - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed - if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - func_show_eval '$MV "$output_obj" "$obj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - fi - - $opt_dry_run || { - func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" - - # Unlock the critical section if it was locked - if test "$need_locks" != no; then - removelist=$lockfile - $RM "$lockfile" - fi - } - - exit $EXIT_SUCCESS -} - -$opt_help || { - test "$opt_mode" = compile && func_mode_compile ${1+"$@"} -} - -func_mode_help () -{ - # We need to display help for each of the modes. - case $opt_mode in - "") - # Generic help is extracted from the usage comments - # at the start of this file. - func_help - ;; - - clean) - $ECHO \ -"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - -Remove files from the build directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, object or program, all the files associated -with it are deleted. Otherwise, only FILE itself is deleted using RM." - ;; - - compile) - $ECHO \ -"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - -Compile a source file into a libtool library object. - -This mode accepts the following additional options: - - -o OUTPUT-FILE set the output file name to OUTPUT-FILE - -no-suppress do not suppress compiler output for multiple passes - -prefer-pic try to build PIC objects only - -prefer-non-pic try to build non-PIC objects only - -shared do not build a \`.o' file suitable for static linking - -static only build a \`.o' file suitable for static linking - -Wc,FLAG pass FLAG directly to the compiler - -COMPILE-COMMAND is a command to be used in creating a \`standard' object file -from the given SOURCEFILE. - -The output file name is determined by removing the directory component from -SOURCEFILE, then substituting the C source code suffix \`.c' with the -library object suffix, \`.lo'." - ;; - - execute) - $ECHO \ -"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... - -Automatically set library path, then run a program. - -This mode accepts the following additional options: - - -dlopen FILE add the directory containing FILE to the library path - -This mode sets the library path environment variable according to \`-dlopen' -flags. - -If any of the ARGS are libtool executable wrappers, then they are translated -into their corresponding uninstalled binary, and any of their required library -directories are added to the library path. - -Then, COMMAND is executed, with ARGS as arguments." - ;; - - finish) - $ECHO \ -"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... - -Complete the installation of libtool libraries. - -Each LIBDIR is a directory that contains libtool libraries. - -The commands that this mode executes may require superuser privileges. Use -the \`--dry-run' option if you just want to see what would be executed." - ;; - - install) - $ECHO \ -"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... - -Install executables or libraries. - -INSTALL-COMMAND is the installation command. The first component should be -either the \`install' or \`cp' program. - -The following components of INSTALL-COMMAND are treated specially: - - -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation - -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; - - link) - $ECHO \ -"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... - -Link object files or libraries together to form another library, or to -create an executable program. - -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. - -The following components of LINK-COMMAND are treated specially: - - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -bindir BINDIR specify path to binaries directory (for systems where - libraries must be found in the PATH setting at runtime) - -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE Use a list of object files found in FILE to specify objects - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -shared only do dynamic linking of libtool libraries - -shrext SUFFIX override the standard shared library file extension - -static do not do any dynamic linking of uninstalled libtool libraries - -static-libtool-libs - do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -weak LIBNAME declare that the target provides the LIBNAME interface - -Wc,FLAG - -Xcompiler FLAG pass linker-specific FLAG directly to the compiler - -Wl,FLAG - -Xlinker FLAG pass linker-specific FLAG directly to the linker - -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) - -All other options (arguments beginning with \`-') are ignored. - -Every other argument is treated as a filename. Files ending in \`.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in \`.la', then a libtool library is created, -only library objects (\`.lo' files) may be specified, and \`-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created -using \`ar' and \`ranlib', or on Windows using \`lib'. - -If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file -is created, otherwise an executable program is created." - ;; - - uninstall) - $ECHO \ -"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... - -Remove libraries from an installation directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; - - *) - func_fatal_help "invalid operation mode \`$opt_mode'" - ;; - esac - - echo - $ECHO "Try \`$progname --help' for more information about other modes." -} - -# Now that we've collected a possible --mode arg, show help if necessary -if $opt_help; then - if test "$opt_help" = :; then - func_mode_help - else - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - func_mode_help - done - } | sed -n '1p; 2,$s/^Usage:/ or: /p' - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - echo - func_mode_help - done - } | - sed '1d - /^When reporting/,/^Report/{ - H - d - } - $x - /information about other modes/d - /more detailed .*MODE/d - s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' - fi - exit $? -fi - - -# func_mode_execute arg... -func_mode_execute () -{ - $opt_debug - # The first argument is the command name. - cmd="$nonopt" - test -z "$cmd" && \ - func_fatal_help "you must specify a COMMAND" - - # Handle -dlopen flags immediately. - for file in $opt_dlopen; do - test -f "$file" \ - || func_fatal_help "\`$file' is not a file" - - dir= - case $file in - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$lib' is not a valid libtool archive" - - # Read the libtool library. - dlname= - library_names= - func_source "$file" - - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && \ - func_warning "\`$file' was not linked with \`-export-dynamic'" - continue - fi - - func_dirname "$file" "" "." - dir="$func_dirname_result" - - if test -f "$dir/$objdir/$dlname"; then - func_append dir "/$objdir" - else - if test ! -f "$dir/$dlname"; then - func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" - fi - fi - ;; - - *.lo) - # Just add the directory containing the .lo file. - func_dirname "$file" "" "." - dir="$func_dirname_result" - ;; - - *) - func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" - continue - ;; - esac - - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir="$absdir" - - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done - - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic="$magic" - - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -* | *.la | *.lo ) ;; - *) - # Do a test to see if this is really a libtool program. - if func_ltwrapper_script_p "$file"; then - func_source "$file" - # Transform arg to wrapped name. - file="$progdir/$program" - elif func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - func_source "$func_ltwrapper_scriptname_result" - # Transform arg to wrapped name. - file="$progdir/$program" - fi - ;; - esac - # Quote arguments (to preserve shell metacharacters). - func_append_quoted args "$file" - done - - if test "X$opt_dry_run" = Xfalse; then - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi - - # Restore saved environment variables - for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES - do - eval "if test \"\${save_$lt_var+set}\" = set; then - $lt_var=\$save_$lt_var; export $lt_var - else - $lt_unset $lt_var - fi" - done - - # Now prepare to actually exec the command. - exec_cmd="\$cmd$args" - else - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - echo "export $shlibpath_var" - fi - $ECHO "$cmd$args" - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = execute && func_mode_execute ${1+"$@"} - - -# func_mode_finish arg... -func_mode_finish () -{ - $opt_debug - libs= - libdirs= - admincmds= - - for opt in "$nonopt" ${1+"$@"} - do - if test -d "$opt"; then - func_append libdirs " $opt" - - elif test -f "$opt"; then - if func_lalib_unsafe_p "$opt"; then - func_append libs " $opt" - else - func_warning "\`$opt' is not a valid libtool archive" - fi - - else - func_fatal_error "invalid argument \`$opt'" - fi - done - - if test -n "$libs"; then - if test -n "$lt_sysroot"; then - sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` - sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" - else - sysroot_cmd= - fi - - # Remove sysroot references - if $opt_dry_run; then - for lib in $libs; do - echo "removing references to $lt_sysroot and \`=' prefixes from $lib" - done - else - tmpdir=`func_mktempdir` - for lib in $libs; do - sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ - > $tmpdir/tmp-la - mv -f $tmpdir/tmp-la $lib - done - ${RM}r "$tmpdir" - fi - fi - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - func_execute_cmds "$finish_cmds" 'admincmds="$admincmds -'"$cmd"'"' - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || func_append admincmds " - $cmds" - fi - done - fi - - # Exit here if they wanted silent mode. - $opt_silent && exit $EXIT_SUCCESS - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - echo "----------------------------------------------------------------------" - echo "Libraries have been installed in:" - for libdir in $libdirs; do - $ECHO " $libdir" - done - echo - echo "If you ever happen to want to link against installed libraries" - echo "in a given directory, LIBDIR, you must either use libtool, and" - echo "specify the full pathname of the library, or use the \`-LLIBDIR'" - echo "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - echo " - add LIBDIR to the \`$shlibpath_var' environment variable" - echo " during execution" - fi - if test -n "$runpath_var"; then - echo " - add LIBDIR to the \`$runpath_var' environment variable" - echo " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" - - $ECHO " - use the \`$flag' linker flag" - fi - if test -n "$admincmds"; then - $ECHO " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" - fi - echo - - echo "See any operating system documentation about shared libraries for" - case $host in - solaris2.[6789]|solaris2.1[0-9]) - echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" - echo "pages." - ;; - *) - echo "more information, such as the ld(1) and ld.so(8) manual pages." - ;; - esac - echo "----------------------------------------------------------------------" - fi - exit $EXIT_SUCCESS -} - -test "$opt_mode" = finish && func_mode_finish ${1+"$@"} - - -# func_mode_install arg... -func_mode_install () -{ - $opt_debug - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || - # Allow the use of GNU shtool's install command. - case $nonopt in *shtool*) :;; *) false;; esac; then - # Aesthetically quote it. - func_quote_for_eval "$nonopt" - install_prog="$func_quote_for_eval_result " - arg=$1 - shift - else - install_prog= - arg=$nonopt - fi - - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - func_quote_for_eval "$arg" - func_append install_prog "$func_quote_for_eval_result" - install_shared_prog=$install_prog - case " $install_prog " in - *[\\\ /]cp\ *) install_cp=: ;; - *) install_cp=false ;; - esac - - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=no - stripme= - no_mode=: - for arg - do - arg2= - if test -n "$dest"; then - func_append files " $dest" - dest=$arg - continue - fi - - case $arg in - -d) isdir=yes ;; - -f) - if $install_cp; then :; else - prev=$arg - fi - ;; - -g | -m | -o) - prev=$arg - ;; - -s) - stripme=" -s" - continue - ;; - -*) - ;; - *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - if test "x$prev" = x-m && test -n "$install_override_mode"; then - arg2=$install_override_mode - no_mode=false - fi - prev= - else - dest=$arg - continue - fi - ;; - esac - - # Aesthetically quote the argument. - func_quote_for_eval "$arg" - func_append install_prog " $func_quote_for_eval_result" - if test -n "$arg2"; then - func_quote_for_eval "$arg2" - fi - func_append install_shared_prog " $func_quote_for_eval_result" - done - - test -z "$install_prog" && \ - func_fatal_help "you must specify an install program" - - test -n "$prev" && \ - func_fatal_help "the \`$prev' option requires an argument" - - if test -n "$install_override_mode" && $no_mode; then - if $install_cp; then :; else - func_quote_for_eval "$install_override_mode" - func_append install_shared_prog " -m $func_quote_for_eval_result" - fi - fi - - if test -z "$files"; then - if test -z "$dest"; then - func_fatal_help "no file or destination specified" - else - func_fatal_help "you must specify a destination" - fi - fi - - # Strip any trailing slash from the destination. - func_stripname '' '/' "$dest" - dest=$func_stripname_result - - # Check to see that the destination is a directory. - test -d "$dest" && isdir=yes - if test "$isdir" = yes; then - destdir="$dest" - destname= - else - func_dirname_and_basename "$dest" "" "." - destdir="$func_dirname_result" - destname="$func_basename_result" - - # Not a directory, so check to see that there is only one file specified. - set dummy $files; shift - test "$#" -gt 1 && \ - func_fatal_help "\`$dest' is not a directory" - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - func_fatal_help "\`$destdir' must be an absolute directory name" - ;; - esac - done - ;; - esac - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do - - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - func_append staticlibs " $file" - ;; - - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$file' is not a valid libtool archive" - - library_names= - old_library= - relink_command= - func_source "$file" - - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in - *" $libdir "*) ;; - *) func_append current_libdirs " $libdir" ;; - esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in - *" $libdir "*) ;; - *) func_append future_libdirs " $libdir" ;; - esac - fi - - func_dirname "$file" "/" "" - dir="$func_dirname_result" - func_append dir "$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` - - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - test "$inst_prefix_dir" = "$destdir" && \ - func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" - - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` - fi - - func_warning "relinking \`$file'" - func_show_eval "$relink_command" \ - 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' - fi - - # See the names of the shared library. - set dummy $library_names; shift - if test -n "$1"; then - realname="$1" - shift - - srcname="$realname" - test -n "$relink_command" && srcname="$realname"T - - # Install the shared library and build the symlinks. - func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ - 'exit $?' - tstripme="$stripme" - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - case $realname in - *.dll.a) - tstripme="" - ;; - esac - ;; - esac - if test -n "$tstripme" && test -n "$striplib"; then - func_show_eval "$striplib $destdir/$realname" 'exit $?' - fi - - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try `ln -sf' first, because the `ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - test "$linkname" != "$realname" \ - && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" - done - fi - - # Do each command in the postinstall commands. - lib="$destdir/$realname" - func_execute_cmds "$postinstall_cmds" 'exit $?' - fi - - # Install the pseudo-library for information purposes. - func_basename "$file" - name="$func_basename_result" - instname="$dir/$name"i - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' - - # Maybe install the static library, too. - test -n "$old_library" && func_append staticlibs " $dir/$old_library" - ;; - - *.lo) - # Install (i.e. copy) a libtool object. - - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - func_lo2o "$destfile" - staticdest=$func_lo2o_result - ;; - *.$objext) - staticdest="$destfile" - destfile= - ;; - *) - func_fatal_help "cannot copy a libtool object to \`$destfile'" - ;; - esac - - # Install the libtool object if requested. - test -n "$destfile" && \ - func_show_eval "$install_prog $file $destfile" 'exit $?' - - # Install the old object if enabled. - if test "$build_old_libs" = yes; then - # Deduce the name of the old-style object file. - func_lo2o "$file" - staticobj=$func_lo2o_result - func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' - fi - exit $EXIT_SUCCESS - ;; - - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi - - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext="" - case $file in - *.exe) - if test ! -f "$file"; then - func_stripname '' '.exe' "$file" - file=$func_stripname_result - stripped_ext=".exe" - fi - ;; - esac - - # Do a test to see if this is really a libtool program. - case $host in - *cygwin* | *mingw*) - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - wrapper=$func_ltwrapper_scriptname_result - else - func_stripname '' '.exe' "$file" - wrapper=$func_stripname_result - fi - ;; - *) - wrapper=$file - ;; - esac - if func_ltwrapper_script_p "$wrapper"; then - notinst_deplibs= - relink_command= - - func_source "$wrapper" - - # Check the variables that should have been set. - test -z "$generated_by_libtool_version" && \ - func_fatal_error "invalid libtool wrapper script \`$wrapper'" - - finalize=yes - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - func_source "$lib" - fi - libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test - if test -n "$libdir" && test ! -f "$libfile"; then - func_warning "\`$lib' has not been installed in \`$libdir'" - finalize=no - fi - done - - relink_command= - func_source "$wrapper" - - outputname= - if test "$fast_install" = no && test -n "$relink_command"; then - $opt_dry_run || { - if test "$finalize" = yes; then - tmpdir=`func_mktempdir` - func_basename "$file$stripped_ext" - file="$func_basename_result" - outputname="$tmpdir/$file" - # Replace the output file specification. - relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` - - $opt_silent || { - func_quote_for_expand "$relink_command" - eval "func_echo $func_quote_for_expand_result" - } - if eval "$relink_command"; then : - else - func_error "error: relink \`$file' with the above command before installing it" - $opt_dry_run || ${RM}r "$tmpdir" - continue - fi - file="$outputname" - else - func_warning "cannot relink \`$file'" - fi - } - else - # Install the binary that we compiled earlier. - file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` - fi - fi - - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - func_stripname '' '.exe' "$destfile" - destfile=$func_stripname_result - ;; - esac - ;; - esac - func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' - $opt_dry_run || if test -n "$outputname"; then - ${RM}r "$tmpdir" - fi - ;; - esac - done - - for file in $staticlibs; do - func_basename "$file" - name="$func_basename_result" - - # Set up the ranlib parameters. - oldlib="$destdir/$name" - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - - func_show_eval "$install_prog \$file \$oldlib" 'exit $?' - - if test -n "$stripme" && test -n "$old_striplib"; then - func_show_eval "$old_striplib $tool_oldlib" 'exit $?' - fi - - # Do each command in the postinstall commands. - func_execute_cmds "$old_postinstall_cmds" 'exit $?' - done - - test -n "$future_libdirs" && \ - func_warning "remember to run \`$progname --finish$future_libdirs'" - - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - $opt_dry_run && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' - else - exit $EXIT_SUCCESS - fi -} - -test "$opt_mode" = install && func_mode_install ${1+"$@"} - - -# func_generate_dlsyms outputname originator pic_p -# Extract symbols from dlprefiles and create ${outputname}S.o with -# a dlpreopen symbol table. -func_generate_dlsyms () -{ - $opt_debug - my_outputname="$1" - my_originator="$2" - my_pic_p="${3-no}" - my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` - my_dlsyms= - - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - my_dlsyms="${my_outputname}S.c" - else - func_error "not configured to extract global symbols from dlpreopened files" - fi - fi - - if test -n "$my_dlsyms"; then - case $my_dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist="$output_objdir/${my_outputname}.nm" - - func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - - # Parse the name list into a source file. - func_verbose "creating $output_objdir/$my_dlsyms" - - $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ -/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ -/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ - -#ifdef __cplusplus -extern \"C\" { -#endif - -#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) -#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" -#endif - -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined(__osf__) -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -/* External symbol declarations for the compiler. */\ -" - - if test "$dlself" = yes; then - func_verbose "generating symbol list for \`$output'" - - $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` - for progfile in $progfiles; do - func_to_tool_file "$progfile" func_convert_file_msys_to_w32 - func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" - $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $opt_dry_run || { - eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - if test -n "$export_symbols_regex"; then - $opt_dry_run || { - eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols="$output_objdir/$outputname.exp" - $opt_dry_run || { - $RM $export_symbols - eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - } - else - $opt_dry_run || { - eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - } - fi - fi - - for dlprefile in $dlprefiles; do - func_verbose "extracting global C symbols from \`$dlprefile'" - func_basename "$dlprefile" - name="$func_basename_result" - case $host in - *cygwin* | *mingw* | *cegcc* ) - # if an import library, we need to obtain dlname - if func_win32_import_lib_p "$dlprefile"; then - func_tr_sh "$dlprefile" - eval "curr_lafile=\$libfile_$func_tr_sh_result" - dlprefile_dlbasename="" - if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then - # Use subshell, to avoid clobbering current variable values - dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` - if test -n "$dlprefile_dlname" ; then - func_basename "$dlprefile_dlname" - dlprefile_dlbasename="$func_basename_result" - else - # no lafile. user explicitly requested -dlpreopen . - $sharedlib_from_linklib_cmd "$dlprefile" - dlprefile_dlbasename=$sharedlib_from_linklib_result - fi - fi - $opt_dry_run || { - if test -n "$dlprefile_dlbasename" ; then - eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' - else - func_warning "Could not compute DLL name from $name" - eval '$ECHO ": $name " >> "$nlist"' - fi - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | - $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" - } - else # not an import lib - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - fi - ;; - *) - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - ;; - esac - done - - $opt_dry_run || { - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $MV "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if $GREP -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - $GREP -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' - else - echo '/* NONE */' >> "$output_objdir/$my_dlsyms" - fi - - echo >> "$output_objdir/$my_dlsyms" "\ - -/* The mapping between symbol names and symbols. */ -typedef struct { - const char *name; - void *address; -} lt_dlsymlist; -extern LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[]; -LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[] = -{\ - { \"$my_originator\", (void *) 0 }," - - case $need_lib_prefix in - no) - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - *) - eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - esac - echo >> "$output_objdir/$my_dlsyms" "\ - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_${my_prefix}_LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif\ -" - } # !$opt_dry_run - - pic_flag_for_symtable= - case "$compile_command " in - *" -static "*) ;; - *) - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; - *-*-hpux*) - pic_flag_for_symtable=" $pic_flag" ;; - *) - if test "X$my_pic_p" != Xno; then - pic_flag_for_symtable=" $pic_flag" - fi - ;; - esac - ;; - esac - symtab_cflags= - for arg in $LTCFLAGS; do - case $arg in - -pie | -fpie | -fPIE) ;; - *) func_append symtab_cflags " $arg" ;; - esac - done - - # Now compile the dynamic symbol file. - func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - - # Clean up the generated files. - func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' - - # Transform the symbol file into the correct name. - symfileobj="$output_objdir/${my_outputname}S.$objext" - case $host in - *cygwin* | *mingw* | *cegcc* ) - if test -f "$output_objdir/$my_outputname.def"; then - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - else - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - fi - ;; - *) - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - ;; - esac - ;; - *) - func_fatal_error "unknown suffix for \`$my_dlsyms'" - ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. - - # Nullify the symbol file. - compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` - fi -} - -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -# Despite the name, also deal with 64 bit binaries. -func_win32_libid () -{ - $opt_debug - win32_libid_type="unknown" - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then - func_to_tool_file "$1" func_convert_file_msys_to_w32 - win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | - $SED -n -e ' - 1,100{ - / I /{ - s,.*,import, - p - q - } - }'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; - esac - ;; - esac - $ECHO "$win32_libid_type" -} - -# func_cygming_dll_for_implib ARG -# -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib () -{ - $opt_debug - sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` -} - -# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs -# -# The is the core of a fallback implementation of a -# platform-specific function to extract the name of the -# DLL associated with the specified import library LIBNAME. -# -# SECTION_NAME is either .idata$6 or .idata$7, depending -# on the platform and compiler that created the implib. -# -# Echos the name of the DLL associated with the -# specified import library. -func_cygming_dll_for_implib_fallback_core () -{ - $opt_debug - match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` - $OBJDUMP -s --section "$1" "$2" 2>/dev/null | - $SED '/^Contents of section '"$match_literal"':/{ - # Place marker at beginning of archive member dllname section - s/.*/====MARK====/ - p - d - } - # These lines can sometimes be longer than 43 characters, but - # are always uninteresting - /:[ ]*file format pe[i]\{,1\}-/d - /^In archive [^:]*:/d - # Ensure marker is printed - /^====MARK====/p - # Remove all lines with less than 43 characters - /^.\{43\}/!d - # From remaining lines, remove first 43 characters - s/^.\{43\}//' | - $SED -n ' - # Join marker and all lines until next marker into a single line - /^====MARK====/ b para - H - $ b para - b - :para - x - s/\n//g - # Remove the marker - s/^====MARK====// - # Remove trailing dots and whitespace - s/[\. \t]*$// - # Print - /./p' | - # we now have a list, one entry per line, of the stringified - # contents of the appropriate section of all members of the - # archive which possess that section. Heuristic: eliminate - # all those which have a first or second character that is - # a '.' (that is, objdump's representation of an unprintable - # character.) This should work for all archives with less than - # 0x302f exports -- but will fail for DLLs whose name actually - # begins with a literal '.' or a single character followed by - # a '.'. - # - # Of those that remain, print the first one. - $SED -e '/^\./d;/^.\./d;q' -} - -# func_cygming_gnu_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is a GNU/binutils-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_gnu_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - 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)$'` - test -n "$func_cygming_gnu_implib_tmp" -} - -# func_cygming_ms_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is an MS-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_ms_implib_p () -{ - $opt_debug - func_to_tool_file "$1" func_convert_file_msys_to_w32 - func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` - test -n "$func_cygming_ms_implib_tmp" -} - -# func_cygming_dll_for_implib_fallback ARG -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# -# This fallback implementation is for use when $DLLTOOL -# does not support the --identify-strict option. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib_fallback () -{ - $opt_debug - if func_cygming_gnu_implib_p "$1" ; then - # binutils import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` - elif func_cygming_ms_implib_p "$1" ; then - # ms-generated import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` - else - # unknown - sharedlib_from_linklib_result="" - fi -} - - -# func_extract_an_archive dir oldlib -func_extract_an_archive () -{ - $opt_debug - f_ex_an_ar_dir="$1"; shift - f_ex_an_ar_oldlib="$1" - if test "$lock_old_archive_extraction" = yes; then - lockfile=$f_ex_an_ar_oldlib.lock - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - fi - func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ - 'stat=$?; rm -f "$lockfile"; exit $stat' - if test "$lock_old_archive_extraction" = yes; then - $opt_dry_run || rm -f "$lockfile" - fi - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" - fi -} - - -# func_extract_archives gentop oldlib ... -func_extract_archives () -{ - $opt_debug - my_gentop="$1"; shift - my_oldlibs=${1+"$@"} - my_oldobjs="" - my_xlib="" - my_xabs="" - my_xdir="" - - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - func_basename "$my_xlib" - my_xlib="$func_basename_result" - my_xlib_u=$my_xlib - while :; do - case " $extracted_archives " in - *" $my_xlib_u "*) - func_arith $extracted_serial + 1 - extracted_serial=$func_arith_result - my_xlib_u=lt$extracted_serial-$my_xlib ;; - *) break ;; - esac - done - extracted_archives="$extracted_archives $my_xlib_u" - my_xdir="$my_gentop/$my_xlib_u" - - func_mkdir_p "$my_xdir" - - case $host in - *-darwin*) - func_verbose "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - $opt_dry_run || { - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - darwin_base_archive=`basename "$darwin_archive"` - darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` - if test -n "$darwin_arches"; then - darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches ; do - func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" - $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" - cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" - func_extract_an_archive "`pwd`" "${darwin_base_archive}" - cd "$darwin_curdir" - $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" - done # $darwin_arches - ## Okay now we've a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` - $LIPO -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - $RM -rf unfat-$$ - cd "$darwin_orig_dir" - else - cd $darwin_orig_dir - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - } # !$opt_dry_run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` - done - - func_extract_archives_result="$my_oldobjs" -} - - -# func_emit_wrapper [arg=no] -# -# Emit a libtool wrapper script on stdout. -# Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw -# wrapper executable. Must ONLY be called from within -# func_mode_link because it depends on a number of variables -# set therein. -# -# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR -# variable will take. If 'yes', then the emitted script -# will assume that the directory in which it is stored is -# the $objdir directory. This is a cygwin/mingw-specific -# behavior. -func_emit_wrapper () -{ - func_emit_wrapper_arg1=${1-no} - - $ECHO "\ -#! $SHELL - -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='$sed_quote_subst' - -# Be Bourne compatible -if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -relink_command=\"$relink_command\" - -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variables: - generated_by_libtool_version='$macro_version' - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$ECHO are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - file=\"\$0\"" - - qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` - $ECHO "\ - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - ECHO=\"$qECHO\" - fi - -# Very basic option parsing. These options are (a) specific to -# the libtool wrapper, (b) are identical between the wrapper -# /script/ and the wrapper /executable/ which is used only on -# windows platforms, and (c) all begin with the string "--lt-" -# (application programs are unlikely to have options which match -# this pattern). -# -# There are only two supported options: --lt-debug and -# --lt-dump-script. There is, deliberately, no --lt-help. -# -# The first argument to this parsing function should be the -# script's $0 value, followed by "$@". -lt_option_debug= -func_parse_lt_options () -{ - lt_script_arg0=\$0 - shift - for lt_opt - do - case \"\$lt_opt\" in - --lt-debug) lt_option_debug=1 ;; - --lt-dump-script) - lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` - test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. - lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` - cat \"\$lt_dump_D/\$lt_dump_F\" - exit 0 - ;; - --lt-*) - \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 - exit 1 - ;; - esac - done - - # Print the debug banner immediately: - if test -n \"\$lt_option_debug\"; then - echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 - fi -} - -# Used when --lt-debug. Prints its arguments to stdout -# (redirection is the responsibility of the caller) -func_lt_dump_args () -{ - lt_dump_args_N=1; - for lt_arg - do - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" - lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` - done -} - -# Core function for launching the target application -func_exec_program_core () -{ -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" - ;; - esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 -} - -# A function to encapsulate launching the target application -# Strips options in the --lt-* namespace from \$@ and -# launches target application with the remaining arguments. -func_exec_program () -{ - case \" \$* \" in - *\\ --lt-*) - for lt_wr_arg - do - case \$lt_wr_arg in - --lt-*) ;; - *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; - esac - shift - done ;; - esac - func_exec_program_core \${1+\"\$@\"} -} - - # Parse options - func_parse_lt_options \"\$0\" \${1+\"\$@\"} - - # Find the directory that this script lives in. - thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. - - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` - - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi - - file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` - done - - # Usually 'no', except on cygwin/mingw when embedded into - # the cwrapper. - WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 - if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then - # special case for '.' - if test \"\$thisdir\" = \".\"; then - thisdir=\`pwd\` - fi - # remove .libs from thisdir - case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; - $objdir ) thisdir=. ;; - esac - fi - - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" - - if test "$fast_install" = yes; then - $ECHO "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" - - if test ! -f \"\$progdir/\$program\" || - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then - - file=\"\$\$-\$program\" - - if test ! -d \"\$progdir\"; then - $MKDIR \"\$progdir\" - else - $RM \"\$progdir/\$file\" - fi" - - $ECHO "\ - - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - $ECHO \"\$relink_command_output\" >&2 - $RM \"\$progdir/\$file\" - exit 1 - fi - fi - - $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $RM \"\$progdir/\$program\"; - $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $RM \"\$progdir/\$file\" - fi" - else - $ECHO "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" - fi - - $ECHO "\ - - if test -f \"\$progdir/\$program\"; then" - - # fixup the dll searchpath if we need to. - # - # Fix the DLL searchpath if we need to. Do this before prepending - # to shlibpath, because on Windows, both are PATH and uninstalled - # libraries must come first. - if test -n "$dllsearchpath"; then - $ECHO "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" - fi - - # Export our shlibpath_var if we have one. - if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $ECHO "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` - - export $shlibpath_var -" - fi - - $ECHO "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. - func_exec_program \${1+\"\$@\"} - fi - else - # The program doesn't exist. - \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 - \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 - \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 - exit 1 - fi -fi\ -" -} - - -# func_emit_cwrapperexe_src -# emit the source code for a wrapper executable on stdout -# Must ONLY be called from within func_mode_link because -# it depends on a number of variable set therein. -func_emit_cwrapperexe_src () -{ - cat < -#include -#ifdef _MSC_VER -# include -# include -# include -#else -# include -# include -# ifdef __CYGWIN__ -# include -# endif -#endif -#include -#include -#include -#include -#include -#include -#include -#include - -/* declarations of non-ANSI functions */ -#if defined(__MINGW32__) -# ifdef __STRICT_ANSI__ -int _putenv (const char *); -# endif -#elif defined(__CYGWIN__) -# ifdef __STRICT_ANSI__ -char *realpath (const char *, char *); -int putenv (char *); -int setenv (const char *, const char *, int); -# endif -/* #elif defined (other platforms) ... */ -#endif - -/* portability defines, excluding path handling macros */ -#if defined(_MSC_VER) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -# define S_IXUSR _S_IEXEC -# ifndef _INTPTR_T_DEFINED -# define _INTPTR_T_DEFINED -# define intptr_t int -# endif -#elif defined(__MINGW32__) -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -#elif defined(__CYGWIN__) -# define HAVE_SETENV -# define FOPEN_WB "wb" -/* #elif defined (other platforms) ... */ -#endif - -#if defined(PATH_MAX) -# define LT_PATHMAX PATH_MAX -#elif defined(MAXPATHLEN) -# define LT_PATHMAX MAXPATHLEN -#else -# define LT_PATHMAX 1024 -#endif - -#ifndef S_IXOTH -# define S_IXOTH 0 -#endif -#ifndef S_IXGRP -# define S_IXGRP 0 -#endif - -/* path handling portability macros */ -#ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' -#endif - -#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ - defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# define FOPEN_WB "wb" -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif -#endif - -#ifndef DIR_SEPARATOR_2 -# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) -#else /* DIR_SEPARATOR_2 */ -# define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) -#endif /* DIR_SEPARATOR_2 */ - -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - -#ifndef FOPEN_WB -# define FOPEN_WB "w" -#endif -#ifndef _O_BINARY -# define _O_BINARY 0 -#endif - -#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) -#define XFREE(stale) do { \ - if (stale) { free ((void *) stale); stale = 0; } \ -} while (0) - -#if defined(LT_DEBUGWRAPPER) -static int lt_debug = 1; -#else -static int lt_debug = 0; -#endif - -const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ - -void *xmalloc (size_t num); -char *xstrdup (const char *string); -const char *base_name (const char *name); -char *find_executable (const char *wrapper); -char *chase_symlinks (const char *pathspec); -int make_executable (const char *path); -int check_executable (const char *path); -char *strendzap (char *str, const char *pat); -void lt_debugprintf (const char *file, int line, const char *fmt, ...); -void lt_fatal (const char *file, int line, const char *message, ...); -static const char *nonnull (const char *s); -static const char *nonempty (const char *s); -void lt_setenv (const char *name, const char *value); -char *lt_extend_str (const char *orig_value, const char *add, int to_end); -void lt_update_exe_path (const char *name, const char *value); -void lt_update_lib_path (const char *name, const char *value); -char **prepare_spawn (char **argv); -void lt_dump_script (FILE *f); -EOF - - cat <= 0) - && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) - return 1; - else - return 0; -} - -int -make_executable (const char *path) -{ - int rval = 0; - struct stat st; - - lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", - nonempty (path)); - if ((!path) || (!*path)) - return 0; - - if (stat (path, &st) >= 0) - { - rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); - } - return rval; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise - Does not chase symlinks, even on platforms that support them. -*/ -char * -find_executable (const char *wrapper) -{ - int has_slash = 0; - const char *p; - const char *p_next; - /* static buffer for getcwd */ - char tmp[LT_PATHMAX + 1]; - int tmp_len; - char *concat_name; - - lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", - nonempty (wrapper)); - - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; - - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } -#endif - - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char *path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char *q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR (*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = - XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = - XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - return NULL; -} - -char * -chase_symlinks (const char *pathspec) -{ -#ifndef S_ISLNK - return xstrdup (pathspec); -#else - char buf[LT_PATHMAX]; - struct stat s; - char *tmp_pathspec = xstrdup (pathspec); - char *p; - int has_symlinks = 0; - while (strlen (tmp_pathspec) && !has_symlinks) - { - lt_debugprintf (__FILE__, __LINE__, - "checking path component for symlinks: %s\n", - tmp_pathspec); - if (lstat (tmp_pathspec, &s) == 0) - { - if (S_ISLNK (s.st_mode) != 0) - { - has_symlinks = 1; - break; - } - - /* search backwards for last DIR_SEPARATOR */ - p = tmp_pathspec + strlen (tmp_pathspec) - 1; - while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - p--; - if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - { - /* no more DIR_SEPARATORS left */ - break; - } - *p = '\0'; - } - else - { - lt_fatal (__FILE__, __LINE__, - "error accessing file \"%s\": %s", - tmp_pathspec, nonnull (strerror (errno))); - } - } - XFREE (tmp_pathspec); - - if (!has_symlinks) - { - return xstrdup (pathspec); - } - - tmp_pathspec = realpath (pathspec, buf); - if (tmp_pathspec == 0) - { - lt_fatal (__FILE__, __LINE__, - "could not follow symlinks for %s", pathspec); - } - return xstrdup (tmp_pathspec); -#endif -} - -char * -strendzap (char *str, const char *pat) -{ - size_t len, patlen; - - assert (str != NULL); - assert (pat != NULL); - - len = strlen (str); - patlen = strlen (pat); - - if (patlen <= len) - { - str += len - patlen; - if (strcmp (str, pat) == 0) - *str = '\0'; - } - return str; -} - -void -lt_debugprintf (const char *file, int line, const char *fmt, ...) -{ - va_list args; - if (lt_debug) - { - (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); - va_start (args, fmt); - (void) vfprintf (stderr, fmt, args); - va_end (args); - } -} - -static void -lt_error_core (int exit_status, const char *file, - int line, const char *mode, - const char *message, va_list ap) -{ - fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); - vfprintf (stderr, message, ap); - fprintf (stderr, ".\n"); - - if (exit_status >= 0) - exit (exit_status); -} - -void -lt_fatal (const char *file, int line, const char *message, ...) -{ - va_list ap; - va_start (ap, message); - lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); - va_end (ap); -} - -static const char * -nonnull (const char *s) -{ - return s ? s : "(null)"; -} - -static const char * -nonempty (const char *s) -{ - return (s && !*s) ? "(empty)" : nonnull (s); -} - -void -lt_setenv (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_setenv) setting '%s' to '%s'\n", - nonnull (name), nonnull (value)); - { -#ifdef HAVE_SETENV - /* always make a copy, for consistency with !HAVE_SETENV */ - char *str = xstrdup (value); - setenv (name, str, 1); -#else - int len = strlen (name) + 1 + strlen (value) + 1; - char *str = XMALLOC (char, len); - sprintf (str, "%s=%s", name, value); - if (putenv (str) != EXIT_SUCCESS) - { - XFREE (str); - } -#endif - } -} - -char * -lt_extend_str (const char *orig_value, const char *add, int to_end) -{ - char *new_value; - if (orig_value && *orig_value) - { - int orig_value_len = strlen (orig_value); - int add_len = strlen (add); - new_value = XMALLOC (char, add_len + orig_value_len + 1); - if (to_end) - { - strcpy (new_value, orig_value); - strcpy (new_value + orig_value_len, add); - } - else - { - strcpy (new_value, add); - strcpy (new_value + add_len, orig_value); - } - } - else - { - new_value = xstrdup (add); - } - return new_value; -} - -void -lt_update_exe_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - /* some systems can't cope with a ':'-terminated path #' */ - int len = strlen (new_value); - while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) - { - new_value[len-1] = '\0'; - } - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -void -lt_update_lib_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -EOF - case $host_os in - mingw*) - cat <<"EOF" - -/* Prepares an argument vector before calling spawn(). - Note that spawn() does not by itself call the command interpreter - (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : - ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); - GetVersionEx(&v); - v.dwPlatformId == VER_PLATFORM_WIN32_NT; - }) ? "cmd.exe" : "command.com"). - Instead it simply concatenates the arguments, separated by ' ', and calls - CreateProcess(). We must quote the arguments since Win32 CreateProcess() - interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a - special way: - - Space and tab are interpreted as delimiters. They are not treated as - delimiters if they are surrounded by double quotes: "...". - - Unescaped double quotes are removed from the input. Their only effect is - that within double quotes, space and tab are treated like normal - characters. - - Backslashes not followed by double quotes are not special. - - But 2*n+1 backslashes followed by a double quote become - n backslashes followed by a double quote (n >= 0): - \" -> " - \\\" -> \" - \\\\\" -> \\" - */ -#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" -#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" -char ** -prepare_spawn (char **argv) -{ - size_t argc; - char **new_argv; - size_t i; - - /* Count number of arguments. */ - for (argc = 0; argv[argc] != NULL; argc++) - ; - - /* Allocate new argument vector. */ - new_argv = XMALLOC (char *, argc + 1); - - /* Put quoted arguments into the new argument vector. */ - for (i = 0; i < argc; i++) - { - const char *string = argv[i]; - - if (string[0] == '\0') - new_argv[i] = xstrdup ("\"\""); - else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) - { - int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); - size_t length; - unsigned int backslashes; - const char *s; - char *quoted_string; - char *p; - - length = 0; - backslashes = 0; - if (quote_around) - length++; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - length += backslashes + 1; - length++; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - length += backslashes + 1; - - quoted_string = XMALLOC (char, length + 1); - - p = quoted_string; - backslashes = 0; - if (quote_around) - *p++ = '"'; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - { - unsigned int j; - for (j = backslashes + 1; j > 0; j--) - *p++ = '\\'; - } - *p++ = c; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - { - unsigned int j; - for (j = backslashes; j > 0; j--) - *p++ = '\\'; - *p++ = '"'; - } - *p = '\0'; - - new_argv[i] = quoted_string; - } - else - new_argv[i] = (char *) string; - } - new_argv[argc] = NULL; - - return new_argv; -} -EOF - ;; - esac - - cat <<"EOF" -void lt_dump_script (FILE* f) -{ -EOF - func_emit_wrapper yes | - $SED -n -e ' -s/^\(.\{79\}\)\(..*\)/\1\ -\2/ -h -s/\([\\"]\)/\\\1/g -s/$/\\n/ -s/\([^\n]*\).*/ fputs ("\1", f);/p -g -D' - cat <<"EOF" -} -EOF -} -# end: func_emit_cwrapperexe_src - -# func_win32_import_lib_p ARG -# True if ARG is an import lib, as indicated by $file_magic_cmd -func_win32_import_lib_p () -{ - $opt_debug - case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in - *import*) : ;; - *) false ;; - esac -} - -# func_mode_link arg... -func_mode_link () -{ - $opt_debug - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - # It is impossible to link a dll without this setting, and - # we shouldn't force the makefile maintainer to figure out - # which system we are compiling for in order to pass an extra - # flag for every libtool invocation. - # allow_undefined=no - - # FIXME: Unfortunately, there are problems with the above when trying - # to make a dll which has undefined symbols, in which case not - # even a static library is built. For now, we need to specify - # -no-undefined on the libtool link line when we can be certain - # that all symbols are satisfied, otherwise we get a static library. - allow_undefined=yes - ;; - *) - allow_undefined=yes - ;; - esac - libtool_args=$nonopt - base_compile="$nonopt $@" - compile_command=$nonopt - finalize_command=$nonopt - - compile_rpath= - finalize_rpath= - compile_shlibpath= - finalize_shlibpath= - convenience= - old_convenience= - deplibs= - old_deplibs= - compiler_flags= - linker_flags= - dllsearchpath= - lib_search_path=`pwd` - inst_prefix_dir= - new_inherited_linker_flags= - - avoid_version=no - bindir= - dlfiles= - dlprefiles= - dlself=no - export_dynamic=no - export_symbols= - export_symbols_regex= - generated= - libobjs= - ltlibs= - module=no - no_install=no - objs= - non_pic_objects= - precious_files_regex= - prefer_static_libs=no - preload=no - prev= - prevarg= - release= - rpath= - xrpath= - perm_rpath= - temp_rpath= - thread_safe=no - vinfo= - vinfo_number=no - weak_libs= - single_module="${wl}-single_module" - func_infer_tag $base_compile - - # We need to know -static, to get the right output filenames. - for arg - do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - break - ;; - -all-static | -static | -static-libtool-libs) - case $arg in - -all-static) - if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then - func_warning "complete static linking is impossible in this configuration" - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - -static) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=built - ;; - -static-libtool-libs) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - esac - build_libtool_libs=no - build_old_libs=yes - break - ;; - esac - done - - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes - - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg="$1" - shift - func_quote_for_eval "$arg" - qarg=$func_quote_for_eval_unquoted_result - func_append libtool_args " $func_quote_for_eval_result" - - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - func_append compile_command " @OUTPUT@" - func_append finalize_command " @OUTPUT@" - ;; - esac - - case $prev in - bindir) - bindir="$arg" - prev= - continue - ;; - dlfiles|dlprefiles) - if test "$preload" = no; then - # Add the symbol object into the linking commands. - func_append compile_command " @SYMFILE@" - func_append finalize_command " @SYMFILE@" - preload=yes - fi - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test "$dlself" = no; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test "$prev" = dlprefiles; then - dlself=yes - elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test "$prev" = dlfiles; then - func_append dlfiles " $arg" - else - func_append dlprefiles " $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols="$arg" - test -f "$arg" \ - || func_fatal_error "symbol file \`$arg' does not exist" - prev= - continue - ;; - expsyms_regex) - export_symbols_regex="$arg" - prev= - continue - ;; - framework) - case $host in - *-*-darwin*) - case "$deplibs " in - *" $qarg.ltframework "*) ;; - *) func_append deplibs " $qarg.ltframework" # this is fixed later - ;; - esac - ;; - esac - prev= - continue - ;; - inst_prefix) - inst_prefix_dir="$arg" - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat "$save_arg"` - do -# func_append moreargs " $fil" - arg=$fil - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - done - else - func_fatal_error "link input file \`$arg' does not exist" - fi - arg=$save_arg - prev= - continue - ;; - precious_regex) - precious_files_regex="$arg" - prev= - continue - ;; - release) - release="-$arg" - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - if test "$prev" = rpath; then - case "$rpath " in - *" $arg "*) ;; - *) func_append rpath " $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) func_append xrpath " $arg" ;; - esac - fi - prev= - continue - ;; - shrext) - shrext_cmds="$arg" - prev= - continue - ;; - weak) - func_append weak_libs " $arg" - prev= - continue - ;; - xcclinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xcompiler) - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xlinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $wl$qarg" - prev= - func_append compile_command " $wl$qarg" - func_append finalize_command " $wl$qarg" - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" - - prevarg="$arg" - - case $arg in - -all-static) - if test -n "$link_static_flag"; then - # See comment for -static flag below, for more details. - func_append compile_command " $link_static_flag" - func_append finalize_command " $link_static_flag" - fi - continue - ;; - - -allow-undefined) - # FIXME: remove this flag sometime in the future. - func_fatal_error "\`-allow-undefined' must not be used because it is the default" - ;; - - -avoid-version) - avoid_version=yes - continue - ;; - - -bindir) - prev=bindir - continue - ;; - - -dlopen) - prev=dlfiles - continue - ;; - - -dlpreopen) - prev=dlprefiles - continue - ;; - - -export-dynamic) - export_dynamic=yes - continue - ;; - - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - func_fatal_error "more than one -exported-symbols argument is not allowed" - fi - if test "X$arg" = "X-export-symbols"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; - - -framework) - prev=framework - continue - ;; - - -inst-prefix-dir) - prev=inst_prefix - continue - ;; - - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - func_append compile_command " $arg" - func_append finalize_command " $arg" - ;; - esac - continue - ;; - - -L*) - func_stripname "-L" '' "$arg" - if test -z "$func_stripname_result"; then - if test "$#" -gt 0; then - func_fatal_error "require no space between \`-L' and \`$1'" - else - func_fatal_error "need path for \`-L' option" - fi - fi - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - test -z "$absdir" && \ - func_fatal_error "cannot determine absolute directory name of \`$dir'" - dir="$absdir" - ;; - esac - case "$deplibs " in - *" -L$dir "* | *" $arg "*) - # Will only happen for absolute or sysroot arguments - ;; - *) - # Preserve sysroot, but never include relative directories - case $dir in - [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; - *) func_append deplibs " -L$dir" ;; - esac - func_append lib_search_path " $dir" - ;; - esac - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$dir:"*) ;; - ::) dllsearchpath=$dir;; - *) func_append dllsearchpath ":$dir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - continue - ;; - - -l*) - if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test "X$arg" = "X-lc" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - test "X$arg" = "X-lc" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - func_append deplibs " System.ltframework" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; - esac - elif test "X$arg" = "X-lc_r"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac - fi - func_append deplibs " $arg" - continue - ;; - - -module) - module=yes - continue - ;; - - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot|--sysroot) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - prev=xcompiler - continue - ;; - - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) func_append new_inherited_linker_flags " $arg" ;; - esac - continue - ;; - - -multi_module) - single_module="${wl}-multi_module" - continue - ;; - - -no-fast-install) - fast_install=no - continue - ;; - - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) - # The PATH hackery in wrapper scripts is required on Windows - # and Darwin in order for the loader to find any dlls it needs. - func_warning "\`-no-install' is ignored for $host" - func_warning "assuming \`-no-fast-install' instead" - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; - - -no-undefined) - allow_undefined=no - continue - ;; - - -objectlist) - prev=objectlist - continue - ;; - - -o) prev=output ;; - - -precious-files-regex) - prev=precious_regex - continue - ;; - - -release) - prev=release - continue - ;; - - -rpath) - prev=rpath - continue - ;; - - -R) - prev=xrpath - continue - ;; - - -R*) - func_stripname '-R' '' "$arg" - dir=$func_stripname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - =*) - func_stripname '=' '' "$dir" - dir=$lt_sysroot$func_stripname_result - ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - continue - ;; - - -shared) - # The effects of -shared are defined in a previous loop. - continue - ;; - - -shrext) - prev=shrext - continue - ;; - - -static | -static-libtool-libs) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; - - -thread-safe) - thread_safe=yes - continue - ;; - - -version-info) - prev=vinfo - continue - ;; - - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; - - -weak) - prev=weak - continue - ;; - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $func_quote_for_eval_result" - func_append compiler_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Wl,*) - func_stripname '-Wl,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - func_append arg " $wl$func_quote_for_eval_result" - func_append compiler_flags " $wl$func_quote_for_eval_result" - func_append linker_flags " $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Xcompiler) - prev=xcompiler - continue - ;; - - -Xlinker) - prev=xlinker - continue - ;; - - -XCClinker) - prev=xcclinker - continue - ;; - - # -msg_* for osf cc - -msg_*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - # Flags to be passed through unchanged, with rationale: - # -64, -mips[0-9] enable 64-bit mode for the SGI compiler - # -r[0-9][0-9]* specify processor for the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler - # +DA*, +DD* enable 64-bit mode for the HP compiler - # -q* compiler args for the IBM compiler - # -m*, -t[45]*, -txscale* architecture-specific flags for GCC - # -F/path path to uninstalled frameworks, gcc on darwin - # -p, -pg, --coverage, -fprofile-* profiling flags for GCC - # @file GCC response files - # -tp=* Portland pgcc target processor selection - # --sysroot=* for sysroot support - # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ - -O*|-flto*|-fwhopr*|-fuse-linker-plugin) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - func_append compile_command " $arg" - func_append finalize_command " $arg" - func_append compiler_flags " $arg" - continue - ;; - - # Some other compiler flag. - -* | +*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - - *.$objext) - # A standard object. - func_append objs " $arg" - ;; - - *.lo) - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi - - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - ;; - - *.$libext) - # An archive. - func_append deplibs " $arg" - func_append old_deplibs " $arg" - continue - ;; - - *.la) - # A libtool-controlled library. - - func_resolve_sysroot "$arg" - if test "$prev" = dlfiles; then - # This library was specified with -dlopen. - func_append dlfiles " $func_resolve_sysroot_result" - prev= - elif test "$prev" = dlprefiles; then - # The library was specified with -dlpreopen. - func_append dlprefiles " $func_resolve_sysroot_result" - prev= - else - func_append deplibs " $func_resolve_sysroot_result" - fi - continue - ;; - - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - esac # arg - - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - done # argument parsing loop - - test -n "$prev" && \ - func_fatal_help "the \`$prevarg' option requires an argument" - - if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - - oldlibs= - # calculate the name of the file, without its directory - func_basename "$output" - outputname="$func_basename_result" - libobjs_save="$libobjs" - - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - - func_dirname "$output" "/" "" - output_objdir="$func_dirname_result$objdir" - func_to_tool_file "$output_objdir/" - tool_output_objdir=$func_to_tool_file_result - # Create the object directory. - func_mkdir_p "$output_objdir" - - # Determine the type of output - case $output in - "") - func_fatal_help "you must specify an output file" - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac - - specialdeplibs= - - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if $opt_preserve_dup_deps ; then - case "$libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append libs " $deplib" - done - - if test "$linkmode" = lib; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" - - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if $opt_duplicate_compiler_generated_deps; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; - esac - func_append pre_post_deps " $pre_post_dep" - done - fi - pre_post_deps= - fi - - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - notinst_path= # paths that contain not-installed libtool libraries - - case $linkmode in - lib) - passes="conv dlpreopen link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=no - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac - - for pass in $passes; do - # The preopen pass in lib mode reverses $deplibs; put it back here - # so that -L comes before libs that need it for instance... - if test "$linkmode,$pass" = "lib,link"; then - ## FIXME: Find the place where the list is rebuilt in the wrong - ## order, and fix it there properly - tmp_deplibs= - for deplib in $deplibs; do - tmp_deplibs="$deplib $tmp_deplibs" - done - deplibs="$tmp_deplibs" - fi - - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan"; then - libs="$deplibs" - deplibs= - fi - if test "$linkmode" = prog; then - case $pass in - dlopen) libs="$dlfiles" ;; - dlpreopen) libs="$dlprefiles" ;; - link) - libs="$deplibs %DEPLIBS%" - test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" - ;; - esac - fi - if test "$linkmode,$pass" = "lib,dlpreopen"; then - # Collect and forward deplibs of preopened libtool libs - for lib in $dlprefiles; do - # Ignore non-libtool-libs - dependency_libs= - func_resolve_sysroot "$lib" - case $lib in - *.la) func_source "$func_resolve_sysroot_result" ;; - esac - - # Collect preopened libtool deplibs, except any this library - # has declared as weak libs - for deplib in $dependency_libs; do - func_basename "$deplib" - deplib_base=$func_basename_result - case " $weak_libs " in - *" $deplib_base "*) ;; - *) func_append deplibs " $deplib" ;; - esac - done - done - libs="$dlprefiles" - fi - if test "$pass" = dlopen; then - # Collect dlpreopened libraries - save_deplibs="$deplibs" - deplibs= - fi - - for deplib in $libs; do - lib= - found=no - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append compiler_flags " $deplib" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -l*) - if test "$linkmode" != lib && test "$linkmode" != prog; then - func_warning "\`-l' is ignored for archives/objects" - continue - fi - func_stripname '-l' '' "$deplib" - name=$func_stripname_result - if test "$linkmode" = lib; then - searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" - else - searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" - fi - for searchdir in $searchdirs; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib="$searchdir/lib${name}${search_ext}" - if test -f "$lib"; then - if test "$search_ext" = ".la"; then - found=yes - else - found=no - fi - break 2 - fi - done - done - if test "$found" != yes; then - # deplib doesn't seem to be a libtool library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - else # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $deplib "*) - if func_lalib_p "$lib"; then - library_names= - old_library= - func_source "$lib" - for l in $old_library $library_names; do - ll="$l" - done - if test "X$ll" = "X$old_library" ; then # only static version available - found=no - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - lib=$ladir/$old_library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - fi - ;; # -l - *.ltframework) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test "$pass" = conv && continue - newdependency_libs="$deplib $newdependency_libs" - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - prog) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - if test "$pass" = scan; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - *) - func_warning "\`-L' is ignored for archives/objects" - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test "$pass" = link; then - func_stripname '-R' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) - func_resolve_sysroot "$deplib" - lib=$func_resolve_sysroot_result - ;; - *.$libext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - # Linking convenience modules into shared libraries is allowed, - # but linking other static libraries is non-portable. - case " $dlpreconveniencelibs " in - *" $deplib "*) ;; - *) - valid_a_lib=no - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=yes - fi - ;; - pass_all) - valid_a_lib=yes - ;; - esac - if test "$valid_a_lib" != yes; then - echo - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because the file extensions .$libext of this argument makes me believe" - echo "*** that it is just a static archive that I should not use here." - else - echo - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - fi - ;; - esac - continue - ;; - prog) - if test "$pass" != link; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - elif test "$linkmode" = prog; then - if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - func_append newdlprefiles " $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append newdlfiles " $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=yes - continue - ;; - esac # case $deplib - - if test "$found" = yes || test -f "$lib"; then : - else - func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" - fi - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$lib" \ - || func_fatal_error "\`$lib' is not a valid libtool archive" - - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - - dlname= - dlopen= - dlpreopen= - libdir= - library_names= - old_library= - inherited_linker_flags= - # If the library was installed with an old release of libtool, - # it will not redefine variables installed, or shouldnotlink - installed=yes - shouldnotlink=no - avoidtemprpath= - - - # Read the .la file - func_source "$lib" - - # Convert "-framework foo" to "foo.ltframework" - if test -n "$inherited_linker_flags"; then - tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` - for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do - case " $new_inherited_linker_flags " in - *" $tmp_inherited_linker_flag "*) ;; - *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; - esac - done - fi - dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan" || - { test "$linkmode" != prog && test "$linkmode" != lib; }; then - test -n "$dlopen" && func_append dlfiles " $dlopen" - test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" - fi - - if test "$pass" = conv; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - # It is a libtool convenience library, so add in its objects. - func_append convenience " $ladir/$objdir/$old_library" - func_append old_convenience " $ladir/$objdir/$old_library" - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done - elif test "$linkmode" != prog && test "$linkmode" != lib; then - func_fatal_error "\`$lib' is not a convenience library" - fi - continue - fi # $pass = conv - - - # Get the name of the library we link against. - linklib= - if test -n "$old_library" && - { test "$prefer_static_libs" = yes || - test "$prefer_static_libs,$installed" = "built,no"; }; then - linklib=$old_library - else - for l in $old_library $library_names; do - linklib="$l" - done - fi - if test -z "$linklib"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - - # This library was specified with -dlopen. - if test "$pass" = dlopen; then - if test -z "$libdir"; then - func_fatal_error "cannot -dlopen a convenience library: \`$lib'" - fi - if test -z "$dlname" || - test "$dlopen_support" != yes || - test "$build_libtool_libs" = no; then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - func_append dlprefiles " $lib $dependency_libs" - else - func_append newdlfiles " $lib" - fi - continue - fi # $pass = dlopen - - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - func_warning "cannot determine absolute directory name of \`$ladir'" - func_warning "passing it literally to the linker, although it might fail" - abs_ladir="$ladir" - fi - ;; - esac - func_basename "$lib" - laname="$func_basename_result" - - # Find the relevant object directory and library name. - if test "X$installed" = Xyes; then - if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - func_warning "library \`$lib' was moved." - dir="$ladir" - absdir="$abs_ladir" - libdir="$abs_ladir" - else - dir="$lt_sysroot$libdir" - absdir="$lt_sysroot$libdir" - fi - test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir="$ladir" - absdir="$abs_ladir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - else - dir="$ladir/$objdir" - absdir="$abs_ladir/$objdir" - # Remove this search path later - func_append notinst_path " $abs_ladir" - fi - fi # $installed = yes - func_stripname 'lib' '.la' "$laname" - name=$func_stripname_result - - # This library was specified with -dlpreopen. - if test "$pass" = dlpreopen; then - if test -z "$libdir" && test "$linkmode" = prog; then - func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" - fi - case "$host" in - # special handling for platforms with PE-DLLs. - *cygwin* | *mingw* | *cegcc* ) - # Linker will automatically link against shared library if both - # static and shared are present. Therefore, ensure we extract - # symbols from the import library if a shared library is present - # (otherwise, the dlopen module name will be incorrect). We do - # this by putting the import library name into $newdlprefiles. - # We recover the dlopen module name by 'saving' the la file - # name in a special purpose variable, and (later) extracting the - # dlname from the la file. - if test -n "$dlname"; then - func_tr_sh "$dir/$linklib" - eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" - func_append newdlprefiles " $dir/$linklib" - else - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - fi - ;; - * ) - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - func_append newdlprefiles " $dir/$dlname" - else - func_append newdlprefiles " $dir/$linklib" - fi - ;; - esac - fi # $pass = dlpreopen - - if test -z "$libdir"; then - # Link the convenience library - if test "$linkmode" = lib; then - deplibs="$dir/$old_library $deplibs" - elif test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi - - - if test "$linkmode" = prog && test "$pass" != link; then - func_append newlib_search_path " $ladir" - deplibs="$lib $deplibs" - - linkalldeplibs=no - if test "$link_all_deplibs" != no || test -z "$library_names" || - test "$build_libtool_libs" = no; then - linkalldeplibs=yes - fi - - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - esac - # Need to link against all dependency_libs? - if test "$linkalldeplibs" = yes; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done # for deplib - continue - fi # $linkmode = prog... - - if test "$linkmode,$pass" = "prog,link"; then - if test -n "$library_names" && - { { test "$prefer_static_libs" = no || - test "$prefer_static_libs,$installed" = "built,yes"; } || - test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then - # Make sure the rpath contains only unique directories. - case "$temp_rpath:" in - *"$absdir:"*) ;; - *) func_append temp_rpath "$absdir:" ;; - esac - fi - - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi # $linkmode,$pass = prog,link... - - if test "$alldeplibs" = yes && - { test "$deplibs_check_method" = pass_all || - { test "$build_libtool_libs" = yes && - test -n "$library_names"; }; }; then - # We only need to search for static libraries - continue - fi - fi - - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes; then - use_static_libs=no - fi - if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc*) - # No point in relinking DLLs because paths are not encoded - func_append notinst_deplibs " $lib" - need_relink=no - ;; - *) - if test "$installed" = no; then - func_append notinst_deplibs " $lib" - need_relink=yes - fi - ;; - esac - # This is a shared library - - # Warn about portability, can't link against -module's on some - # systems (darwin). Don't bleat about dlopened modules though! - dlopenmodule="" - for dlpremoduletest in $dlprefiles; do - if test "X$dlpremoduletest" = "X$lib"; then - dlopenmodule="$dlpremoduletest" - break - fi - done - if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then - echo - if test "$linkmode" = prog; then - $ECHO "*** Warning: Linking the executable $output against the loadable module" - else - $ECHO "*** Warning: Linking the shared library $output against the loadable module" - fi - $ECHO "*** $linklib is not portable!" - fi - if test "$linkmode" = lib && - test "$hardcode_into_libs" = yes; then - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi - - if test -n "$old_archive_from_expsyms_cmds"; then - # figure out the soname - set dummy $library_names - shift - realname="$1" - shift - libname=`eval "\\$ECHO \"$libname_spec\""` - # use dlname if we got it. it's perfectly good, no? - if test -n "$dlname"; then - soname="$dlname" - elif test -n "$soname_spec"; then - # bleh windows - case $host in - *cygwin* | mingw* | *cegcc*) - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - esac - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - - # Make a new name for the extract_expsyms_cmds to use - soroot="$soname" - func_basename "$soroot" - soname="$func_basename_result" - func_stripname 'lib' '.dll' "$soname" - newlib=libimp-$func_stripname_result.a - - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - func_verbose "extracting exported symbol list from \`$soname'" - func_execute_cmds "$extract_expsyms_cmds" 'exit $?' - fi - - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - func_verbose "generating import library for \`$soname'" - func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" - - if test "$linkmode" = prog || test "$opt_mode" != relink; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test "$hardcode_direct" = no; then - add="$dir/$linklib" - case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; - *-*-darwin* ) - # if the lib is a (non-dlopened) module then we can not - # link against it, someone is ignoring the earlier warnings - if /usr/bin/file -L $add 2> /dev/null | - $GREP ": [^:]* bundle" >/dev/null ; then - if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" - if test -z "$old_library" ; then - echo - echo "*** And there doesn't seem to be a static archive available" - echo "*** The link will probably fail, sorry" - else - add="$dir/$old_library" - fi - elif test -n "$old_library"; then - add="$dir/$old_library" - fi - fi - esac - elif test "$hardcode_minus_L" = no; then - case $host in - *-*-sunos*) add_shlibpath="$dir" ;; - esac - add_dir="-L$dir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = no; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - relink) - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$dir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$absdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac - - if test "$lib_linked" != yes; then - func_fatal_configuration "unsupported hardcode properties" - fi - - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) func_append compile_shlibpath "$add_shlibpath:" ;; - esac - fi - if test "$linkmode" = prog; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test "$hardcode_direct" != yes && - test "$hardcode_minus_L" != yes && - test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - fi - fi - fi - - if test "$linkmode" = prog || test "$opt_mode" = relink; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$libdir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$libdir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - add="-l$name" - elif test "$hardcode_automatic" = yes; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib" ; then - add="$inst_prefix_dir$libdir/$linklib" - else - add="$libdir/$linklib" - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir="-L$libdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - fi - - if test "$linkmode" = prog; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test "$linkmode" = prog; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test "$hardcode_direct" != unsupported; then - test -n "$old_library" && linklib="$old_library" - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test "$build_libtool_libs" = yes; then - # Not a shared library - if test "$deplibs_check_method" != pass_all; then - # We're trying link a shared library against a static one - # but the system doesn't support it. - - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - echo - $ECHO "*** Warning: This system can not link to static lib archive $lib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have." - if test "$module" = yes; then - echo "*** But as you try to build a module library, libtool will still create " - echo "*** a static module, that should work as long as the dlopening application" - echo "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? - - if test "$linkmode" = lib; then - if test -n "$dependency_libs" && - { test "$hardcode_into_libs" != yes || - test "$build_old_libs" = yes || - test "$link_static" = yes; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) func_stripname '-R' '' "$libdir" - temp_xrpath=$func_stripname_result - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) func_append xrpath " $temp_xrpath";; - esac;; - *) func_append temp_deplibs " $libdir";; - esac - done - dependency_libs="$temp_deplibs" - fi - - func_append newlib_search_path " $absdir" - # Link against this library - test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result";; - *) func_resolve_sysroot "$deplib" ;; - esac - if $opt_preserve_dup_deps ; then - case "$tmp_libs " in - *" $func_resolve_sysroot_result "*) - func_append specialdeplibs " $func_resolve_sysroot_result" ;; - esac - fi - func_append tmp_libs " $func_resolve_sysroot_result" - done - - if test "$link_all_deplibs" != no; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - path= - case $deplib in - -L*) path="$deplib" ;; - *.la) - func_resolve_sysroot "$deplib" - deplib=$func_resolve_sysroot_result - func_dirname "$deplib" "" "." - dir=$func_dirname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - func_warning "cannot determine absolute directory name of \`$dir'" - absdir="$dir" - fi - ;; - esac - if $GREP "^installed=no" $deplib > /dev/null; then - case $host in - *-*-darwin*) - depdepl= - eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names" ; then - for tmp in $deplibrary_names ; do - depdepl=$tmp - done - if test -f "$absdir/$objdir/$depdepl" ; then - depdepl="$absdir/$objdir/$depdepl" - darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - if test -z "$darwin_install_name"; then - darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - fi - func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" - func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" - path= - fi - fi - ;; - *) - path="-L$absdir/$objdir" - ;; - esac - else - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - test "$absdir" != "$libdir" && \ - func_warning "\`$deplib' seems to be moved" - - path="-L$absdir" - fi - ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - if test "$pass" = link; then - if test "$linkmode" = "prog"; then - compile_deplibs="$new_inherited_linker_flags $compile_deplibs" - finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" - else - compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - fi - fi - dependency_libs="$newdependency_libs" - if test "$pass" = dlpreopen; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test "$pass" != dlopen; then - if test "$pass" != conv; then - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) func_append lib_search_path " $dir" ;; - esac - done - newlib_search_path= - fi - - if test "$linkmode,$pass" != "prog,link"; then - vars="deplibs" - else - vars="compile_deplibs finalize_deplibs" - fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) func_append tmp_libs " $deplib" ;; - esac - ;; - *) func_append tmp_libs " $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs ; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i="" - ;; - esac - if test -n "$i" ; then - func_append tmp_libs " $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test "$linkmode" = prog; then - dlfiles="$newdlfiles" - fi - if test "$linkmode" = prog || test "$linkmode" = lib; then - dlprefiles="$newdlprefiles" - fi - - case $linkmode in - oldlib) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for archives" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for archives" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for archives" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for archives" - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for archives" - - test -n "$release" && \ - func_warning "\`-release' is ignored for archives" - - test -n "$export_symbols$export_symbols_regex" && \ - func_warning "\`-export-symbols' is ignored for archives" - - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs="$output" - func_append objs "$old_deplibs" - ;; - - lib) - # Make sure we only generate libraries of the form `libNAME.la'. - case $outputname in - lib*) - func_stripname 'lib' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - test "$module" = no && \ - func_fatal_help "libtool library \`$output' must begin with \`lib'" - - if test "$need_lib_prefix" != no; then - # Add the "lib" prefix for modules if required - func_stripname '' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - func_stripname '' '.la' "$outputname" - libname=$func_stripname_result - fi - ;; - esac - - if test -n "$objs"; then - if test "$deplibs_check_method" != pass_all; then - func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" - else - echo - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" - func_append libobjs " $objs" - fi - fi - - test "$dlself" != no && \ - func_warning "\`-dlopen self' is ignored for libtool libraries" - - set dummy $rpath - shift - test "$#" -gt 1 && \ - func_warning "ignoring multiple \`-rpath's for a libtool library" - - install_libdir="$1" - - oldlibs= - if test -z "$rpath"; then - if test "$build_libtool_libs" = yes; then - # Building a libtool convenience library. - # Some compilers have problems with a `.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for convenience libraries" - - test -n "$release" && \ - func_warning "\`-release' is ignored for convenience libraries" - else - - # Parse the version information argument. - save_ifs="$IFS"; IFS=':' - set dummy $vinfo 0 0 0 - shift - IFS="$save_ifs" - - test -n "$7" && \ - func_fatal_help "too many parameters to \`-version-info'" - - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible - - case $vinfo_number in - yes) - number_major="$1" - number_minor="$2" - number_revision="$3" - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # which has an extra 1 added just for fun - # - case $version_type in - # correct linux to gnu/linux during the next big refactor - darwin|linux|osf|windows|none) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_revision" - ;; - freebsd-aout|freebsd-elf|qnx|sunos) - current="$number_major" - revision="$number_minor" - age="0" - ;; - irix|nonstopux) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_minor" - lt_irix_increment=no - ;; - *) - func_fatal_configuration "$modename: unknown library version type \`$version_type'" - ;; - esac - ;; - no) - current="$1" - revision="$2" - age="$3" - ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 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]) ;; - *) - func_error "CURRENT \`$current' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $revision in - 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]) ;; - *) - func_error "REVISION \`$revision' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $age in - 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]) ;; - *) - func_error "AGE \`$age' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - if test "$age" -gt "$current"; then - func_error "AGE \`$age' is greater than the current interface number \`$current'" - func_fatal_error "\`$vinfo' is not valid version information" - fi - - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; - - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - # Darwin ld doesn't like 0 for these options... - func_arith $current + 1 - minor_current=$func_arith_result - xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - ;; - - freebsd-aout) - major=".$current" - versuffix=".$current.$revision"; - ;; - - freebsd-elf) - major=".$current" - versuffix=".$current" - ;; - - irix | nonstopux) - if test "X$lt_irix_increment" = "Xno"; then - func_arith $current - $age - else - func_arith $current - $age + 1 - fi - major=$func_arith_result - - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring="$verstring_prefix$major.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$revision - while test "$loop" -ne 0; do - func_arith $revision - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring_prefix$major.$iface:$verstring" - done - - # Before this point, $major must not contain `.'. - major=.$major - versuffix="$major.$revision" - ;; - - linux) # correct to gnu/linux during the next big refactor - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - ;; - - osf) - func_arith $current - $age - major=.$func_arith_result - versuffix=".$current.$age.$revision" - verstring="$current.$age.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$age - while test "$loop" -ne 0; do - func_arith $current - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring:${iface}.0" - done - - # Make executables depend on our current version. - func_append verstring ":${current}.0" - ;; - - qnx) - major=".$current" - versuffix=".$current" - ;; - - sunos) - major=".$current" - versuffix=".$current.$revision" - ;; - - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 filesystems. - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - - *) - func_fatal_configuration "unknown library version type \`$version_type'" - ;; - esac - - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring="0.0" - ;; - esac - if test "$need_version" = no; then - versuffix= - else - versuffix=".0.0" - fi - fi - - # Remove version info from name if versioning should be avoided - if test "$avoid_version" = yes && test "$need_version" = no; then - major= - versuffix= - verstring="" - fi - - # Check to see if the archive will have undefined symbols. - if test "$allow_undefined" = yes; then - if test "$allow_undefined_flag" = unsupported; then - func_warning "undefined symbols not allowed in $host shared libraries" - build_libtool_libs=no - build_old_libs=yes - fi - else - # Don't allow undefined symbols. - allow_undefined_flag="$no_undefined_flag" - fi - - fi - - func_generate_dlsyms "$libname" "$libname" "yes" - func_append libobjs " $symfileobj" - test "X$libobjs" = "X " && libobjs= - - if test "$opt_mode" != relink; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$ECHO "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext | *.gcno) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) - if test "X$precious_files_regex" != "X"; then - if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - func_append removelist " $p" - ;; - *) ;; - esac - done - test -n "$removelist" && \ - func_show_eval "${RM}r \$removelist" - fi - - # Now set the variables for building old libraries. - if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then - func_append oldlibs " $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` - fi - - # Eliminate all temporary directories. - #for path in $notinst_path; do - # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` - # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` - # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` - #done - - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - func_replace_sysroot "$libdir" - func_append temp_xrpath " -R$func_replace_sysroot_result" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then - dependency_libs="$temp_xrpath $dependency_libs" - fi - fi - - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles="$dlfiles" - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) func_append dlfiles " $lib" ;; - esac - done - - # Make sure dlprefiles contains only unique files - old_dlprefiles="$dlprefiles" - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) func_append dlprefiles " $lib" ;; - esac - done - - if test "$build_libtool_libs" = yes; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - func_append deplibs " System.ltframework" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test "$build_libtool_need_lc" = "yes"; then - func_append deplibs " -lc" - fi - ;; - esac - fi - - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release="" - versuffix="" - major="" - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c </dev/null` - $nocaseglob - else - potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` - fi - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null | - $GREP " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib="$potent_lib" - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | - $SED -e 10q | - $EGREP "$file_magic_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - for a_deplib in $deplibs; do - case $a_deplib in - -l*) - func_stripname -l '' "$a_deplib" - name=$func_stripname_result - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $a_deplib "*) - func_append newdeplibs " $a_deplib" - a_deplib="" - ;; - esac - fi - if test -n "$a_deplib" ; then - libname=`eval "\\$ECHO \"$libname_spec\""` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib="$potent_lib" # see symlink-check above in file_magic test - if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ - $EGREP "$match_pattern_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs="" - tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - for i in $predeps $postdeps ; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` - done - fi - case $tmp_deplibs in - *[!\ \ ]*) - echo - if test "X$deplibs_check_method" = "Xnone"; then - echo "*** Warning: inter-library dependencies are not supported in this platform." - else - echo "*** Warning: inter-library dependencies are not known to be supported." - fi - echo "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes - ;; - esac - ;; - esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library with the System framework - newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - if test "$droppeddeps" = yes; then - if test "$module" = yes; then - echo - echo "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - echo "*** a static module, that should work as long as the dlopening" - echo "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - echo "*** The inter-library dependencies that have been dropped here will be" - echo "*** automatically added whenever a program is linked with this library" - echo "*** or is declared to -dlopen it." - - if test "$allow_undefined" = no; then - echo - echo "*** Since this library must not contain undefined symbols," - echo "*** because either the platform does not support them or" - echo "*** it was explicitly requested with -no-undefined," - echo "*** libtool will only create a static version of it." - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - case $host in - *-*-darwin*) - newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - deplibs="$new_libs" - - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= - - # Test again, we may have decided not to build it any more - if test "$build_libtool_libs" = yes; then - # Remove ${wl} instances when linking with ld. - # FIXME: should test the right _cmds variable. - case $archive_cmds in - *\$LD\ *) wl= ;; - esac - if test "$hardcode_into_libs" = yes; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath="$finalize_rpath" - test "$opt_mode" != relink && rpath="$compile_rpath$rpath" - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - func_replace_sysroot "$libdir" - libdir=$func_replace_sysroot_result - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append dep_rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi - - shlibpath="$finalize_shlibpath" - test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi - - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - shift - realname="$1" - shift - - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - if test -z "$dlname"; then - dlname=$soname - fi - - lib="$output_objdir/$realname" - linknames= - for link - do - func_append linknames " $link" - done - - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` - test "X$libobjs" = "X " && libobjs= - - delfiles= - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" - export_symbols="$output_objdir/$libname.uexp" - func_append delfiles " $export_symbols" - fi - - orig_export_symbols= - case $host_os in - cygwin* | mingw* | cegcc*) - if test -n "$export_symbols" && test -z "$export_symbols_regex"; then - # exporting using user supplied symfile - if test "x`$SED 1q $export_symbols`" != xEXPORTS; then - # and it's NOT already a .def file. Must figure out - # which of the given symbols are data symbols and tag - # them as such. So, trigger use of export_symbols_cmds. - # export_symbols gets reassigned inside the "prepare - # the list of exported symbols" if statement, so the - # include_expsyms logic still works. - orig_export_symbols="$export_symbols" - export_symbols= - always_export_symbols=yes - fi - fi - ;; - esac - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - cmds=$export_symbols_cmds - save_ifs="$IFS"; IFS='~' - for cmd1 in $cmds; do - IFS="$save_ifs" - # Take the normal branch if the nm_file_list_spec branch - # doesn't work or if tool conversion is not needed. - case $nm_file_list_spec~$to_tool_file_cmd in - *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) - try_normal_branch=yes - eval cmd=\"$cmd1\" - func_len " $cmd" - len=$func_len_result - ;; - *) - try_normal_branch=no - ;; - esac - if test "$try_normal_branch" = yes \ - && { test "$len" -lt "$max_cmd_len" \ - || test "$max_cmd_len" -le -1; } - then - func_show_eval "$cmd" 'exit $?' - skipped_export=false - elif test -n "$nm_file_list_spec"; then - func_basename "$output" - output_la=$func_basename_result - save_libobjs=$libobjs - save_output=$output - output=${output_objdir}/${output_la}.nm - func_to_tool_file "$output" - libobjs=$nm_file_list_spec$func_to_tool_file_result - func_append delfiles " $output" - func_verbose "creating $NM input file list: $output" - for obj in $save_libobjs; do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > "$output" - eval cmd=\"$cmd1\" - func_show_eval "$cmd" 'exit $?' - output=$save_output - libobjs=$save_libobjs - skipped_export=false - else - # The command line is too long to execute in one step. - func_verbose "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS="$save_ifs" - if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - fi - - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - func_append tmp_deplibs " $test_deplib" - ;; - esac - done - deplibs="$tmp_deplibs" - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec" && - test "$compiler_needs_object" = yes && - test -z "$libobjs"; then - # extract the archives, so we have objects to list. - # TODO: could optimize this to just extract one archive. - whole_archive_flag_spec= - fi - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - else - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - fi - - if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - func_append linker_flags " $flag" - fi - - # Make a backup of the uninstalled library when relinking - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? - fi - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi - - if test "X$skipped_export" != "X:" && - func_len " $test_cmds" && - len=$func_len_result && - test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise - # or, if using GNU ld and skipped_export is not :, use a linker - # script. - - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - func_basename "$output" - output_la=$func_basename_result - - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - last_robj= - k=1 - - if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then - output=${output_objdir}/${output_la}.lnkscript - func_verbose "creating GNU ld script: $output" - echo 'INPUT (' > $output - for obj in $save_libobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - echo ')' >> $output - func_append delfiles " $output" - func_to_tool_file "$output" - output=$func_to_tool_file_result - elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then - output=${output_objdir}/${output_la}.lnk - func_verbose "creating linker input file list: $output" - : > $output - set x $save_libobjs - shift - firstobj= - if test "$compiler_needs_object" = yes; then - firstobj="$1 " - shift - fi - for obj - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - func_append delfiles " $output" - func_to_tool_file "$output" - output=$firstobj\"$file_list_spec$func_to_tool_file_result\" - else - if test -n "$save_libobjs"; then - func_verbose "creating reloadable object files..." - output=$output_objdir/$output_la-${k}.$objext - eval test_cmds=\"$reload_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - if test "X$objlist" = X || - test "$len" -lt "$max_cmd_len"; then - func_append objlist " $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test "$k" -eq 1 ; then - # The first file doesn't have a previous command to add. - reload_objs=$objlist - eval concat_cmds=\"$reload_cmds\" - else - # All subsequent reloadable object files will link in - # the last one created. - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" - fi - last_robj=$output_objdir/$output_la-${k}.$objext - func_arith $k + 1 - k=$func_arith_result - output=$output_objdir/$output_la-${k}.$objext - objlist=" $obj" - func_len " $last_robj" - func_arith $len0 + $func_len_result - len=$func_arith_result - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\${concat_cmds}$reload_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" - fi - func_append delfiles " $output" - - else - output= - fi - - if ${skipped_export-false}; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - libobjs=$output - # Append the command to create the export file. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - fi - - test -n "$save_libobjs" && - func_verbose "creating a temporary reloadable object file: $output" - - # Loop through the commands generated above and execute them. - save_ifs="$IFS"; IFS='~' - for cmd in $concat_cmds; do - IFS="$save_ifs" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - if test -n "$export_symbols_regex" && ${skipped_export-false}; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - - if ${skipped_export-false}; then - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - fi - - libobjs=$output - # Restore the value of output. - output=$save_output - - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. - - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds - else - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds - else - cmds=$archive_cmds - fi - fi - fi - - if test -n "$delfiles"; then - # Append the command to remove temporary files to $cmds. - eval cmds=\"\$cmds~\$RM $delfiles\" - fi - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS="$save_ifs" - - # Restore the uninstalled library and exit - if test "$opt_mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? - - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - func_show_eval '${RM}r "$gentop"' - fi - fi - - exit $EXIT_SUCCESS - fi - - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' - fi - done - - # If -module or -export-dynamic was specified, set the dlname. - if test "$module" = yes || test "$export_dynamic" = yes; then - # On all known operating systems, these are identical. - dlname="$soname" - fi - fi - ;; - - obj) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for objects" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for objects" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for objects" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for objects" - - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for objects" - - test -n "$release" && \ - func_warning "\`-release' is ignored for objects" - - case $output in - *.lo) - test -n "$objs$old_deplibs" && \ - func_fatal_error "cannot build library object \`$output' from non-libtool objects" - - libobj=$output - func_lo2o "$libobj" - obj=$func_lo2o_result - ;; - *) - libobj= - obj="$output" - ;; - esac - - # Delete the old objects. - $opt_dry_run || $RM $obj $libobj - - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # reload_cmds runs $LD directly, so let us get rid of - # -Wl from whole_archive_flag_spec and hope we can get by with - # turning comma into space.. - wl= - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" - reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` - else - gentop="$output_objdir/${obj}x" - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi - - # If we're not building shared, we need to use non_pic_objs - test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" - - # Create the old-style object. - reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test - - output="$obj" - func_execute_cmds "$reload_cmds" 'exit $?' - - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - fi - - if test "$build_libtool_libs" != yes; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - fi - - if test -n "$pic_flag" || test "$pic_mode" != default; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output="$libobj" - func_execute_cmds "$reload_cmds" 'exit $?' - fi - - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - ;; - - prog) - case $host in - *cygwin*) func_stripname '' '.exe' "$output" - output=$func_stripname_result.exe;; - esac - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for programs" - - test -n "$release" && \ - func_warning "\`-release' is ignored for programs" - - test "$preload" = yes \ - && test "$dlopen_support" = unknown \ - && test "$dlopen_self" = unknown \ - && test "$dlopen_self_static" = unknown && \ - func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - case $host in - *-*-darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - # But is supposedly fixed on 10.4 or later (yay!). - if test "$tagname" = CXX ; then - case ${MACOSX_DEPLOYMENT_TARGET-10.0} in - 10.[0123]) - func_append compile_command " ${wl}-bind_at_load" - func_append finalize_command " ${wl}-bind_at_load" - ;; - esac - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - compile_deplibs="$new_libs" - - - func_append compile_command " $compile_deplibs" - func_append finalize_command " $finalize_deplibs" - - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - fi - - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - ::) dllsearchpath=$libdir;; - *) func_append dllsearchpath ":$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath="$rpath" - - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) func_append finalize_perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath="$rpath" - - if test -n "$libobjs" && test "$build_old_libs" = yes; then - # Transform all the library objects into standard objects. - compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - fi - - func_generate_dlsyms "$outputname" "@PROGRAM@" "no" - - # template prelinking step - if test -n "$prelink_cmds"; then - func_execute_cmds "$prelink_cmds" 'exit $?' - fi - - wrappers_required=yes - case $host in - *cegcc* | *mingw32ce*) - # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. - wrappers_required=no - ;; - *cygwin* | *mingw* ) - if test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - *) - if test "$need_relink" = no || test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - esac - if test "$wrappers_required" = no; then - # Replace the output file specification. - compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - link_command="$compile_command$compile_rpath" - - # We have no uninstalled library dependencies, so finalize right now. - exit_status=0 - func_show_eval "$link_command" 'exit_status=$?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Delete the generated files. - if test -f "$output_objdir/${outputname}S.${objext}"; then - func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' - fi - - exit $exit_status - fi - - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi - - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - func_append rpath "$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - fi - - if test "$no_install" = yes; then - # We don't need to create a wrapper script. - link_command="$compile_var$compile_command$compile_rpath" - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $opt_dry_run || $RM $output - # Link the executable and exit - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - exit $EXIT_SUCCESS - fi - - if test "$hardcode_action" = relink; then - # Fast installation is not supported - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - - func_warning "this platform does not like uninstalled shared libraries" - func_warning "\`$output' will be relinked during installation" - else - if test "$fast_install" != no; then - link_command="$finalize_var$compile_command$finalize_rpath" - if test "$fast_install" = yes; then - relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` - else - # fast_install is set to needless - relink_command= - fi - else - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - fi - fi - - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - - # Delete the old output files. - $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname - - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output_objdir/$outputname" - 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'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Now create the wrapper script. - func_verbose "creating $output" - - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - fi - - # Only actually do things if not in dry run mode. - $opt_dry_run || { - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) func_stripname '' '.exe' "$output" - output=$func_stripname_result ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - func_stripname '' '.exe' "$outputname" - outputname=$func_stripname_result ;; - *) exeext= ;; - esac - case $host in - *cygwin* | *mingw* ) - func_dirname_and_basename "$output" "" "." - output_name=$func_basename_result - output_path=$func_dirname_result - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $RM $cwrappersource $cwrapper - trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - - func_emit_cwrapperexe_src > $cwrappersource - - # The wrapper executable is built using the $host compiler, - # because it contains $host paths and files. If cross- - # compiling, it, like the target executable, must be - # executed on the $host or under an emulation environment. - $opt_dry_run || { - $LTCC $LTCFLAGS -o $cwrapper $cwrappersource - $STRIP $cwrapper - } - - # Now, create the wrapper script for func_source use: - func_ltwrapper_scriptname $cwrapper - $RM $func_ltwrapper_scriptname_result - trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 - $opt_dry_run || { - # note: this script will not be executed, so do not chmod. - if test "x$build" = "x$host" ; then - $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result - else - func_emit_wrapper no > $func_ltwrapper_scriptname_result - fi - } - ;; - * ) - $RM $output - trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 - - func_emit_wrapper no > $output - chmod +x $output - ;; - esac - } - exit $EXIT_SUCCESS - ;; - esac - - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do - - if test "$build_libtool_libs" = convenience; then - oldobjs="$libobjs_save $symfileobj" - addlibs="$convenience" - build_libtool_libs=no - else - if test "$build_libtool_libs" = module; then - oldobjs="$libobjs_save" - build_libtool_libs=no - else - oldobjs="$old_deplibs $non_pic_objects" - if test "$preload" = yes && test -f "$symfileobj"; then - func_append oldobjs " $symfileobj" - fi - fi - addlibs="$old_convenience" - fi - - if test -n "$addlibs"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $addlibs - func_append oldobjs " $func_extract_archives_result" - fi - - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then - cmds=$old_archive_from_new_cmds - else - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append oldobjs " $func_extract_archives_result" - fi - - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - func_basename "$obj" - $ECHO "$func_basename_result" - done | sort | sort -uc >/dev/null 2>&1); then - : - else - echo "copying selected object files to avoid basename conflicts..." - gentop="$output_objdir/${outputname}x" - func_append generated " $gentop" - func_mkdir_p "$gentop" - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - func_basename "$obj" - objbase="$func_basename_result" - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - func_arith $counter + 1 - counter=$func_arith_result - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - func_append oldobjs " $gentop/$newobj" - ;; - *) func_append oldobjs " $obj" ;; - esac - done - fi - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - eval cmds=\"$old_archive_cmds\" - - func_len " $cmds" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds - elif test -n "$archiver_list_spec"; then - func_verbose "using command file archive linking..." - for obj in $oldobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > $output_objdir/$libname.libcmd - func_to_tool_file "$output_objdir/$libname.libcmd" - oldobjs=" $archiver_list_spec$func_to_tool_file_result" - cmds=$old_archive_cmds - else - # the command line is too long to link in one step, link in parts - func_verbose "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - oldobjs= - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - eval test_cmds=\"$old_archive_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - for obj in $save_oldobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - func_append objlist " $obj" - if test "$len" -lt "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj" ; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" - objlist= - len=$len0 - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test "X$oldobjs" = "X" ; then - eval cmds=\"\$concat_cmds\" - else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" - fi - fi - fi - func_execute_cmds "$cmds" 'exit $?' - done - - test -n "$generated" && \ - func_show_eval "${RM}r$generated" - - # Now create the libtool archive. - case $output in - *.la) - old_library= - test "$build_old_libs" = yes && old_library="$libname.$libext" - func_verbose "creating $output" - - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` - if test "$hardcode_automatic" = yes ; then - relink_command= - fi - - # Only create the output if not a dry run. - $opt_dry_run || { - for installed in no yes; do - if test "$installed" = yes; then - if test -z "$install_libdir"; then - break - fi - output="$output_objdir/$outputname"i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - func_basename "$deplib" - name="$func_basename_result" - func_resolve_sysroot "$deplib" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" - ;; - -L*) - func_stripname -L '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -L$func_replace_sysroot_result" - ;; - -R*) - func_stripname -R '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -R$func_replace_sysroot_result" - ;; - *) func_append newdependency_libs " $deplib" ;; - esac - done - dependency_libs="$newdependency_libs" - newdlfiles= - - for lib in $dlfiles; do - case $lib in - *.la) - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" - ;; - *) func_append newdlfiles " $lib" ;; - esac - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - *.la) - # Only pass preopened files to the pseudo-archive (for - # eventual linking with the app. that links it) if we - # didn't already link the preopened objects directly into - # the library: - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" - ;; - esac - done - dlprefiles="$newdlprefiles" - else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlfiles " $abs" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlprefiles " $abs" - done - dlprefiles="$newdlprefiles" - fi - $RM $output - # place dlname in correct position for cygwin - # In fact, it would be nice if we could use this code for all target - # systems that can't hard-code library paths into their executables - # and that have no shared library path variable independent of PATH, - # but it turns out we can't easily determine that from inspecting - # libtool variables, so we have to hard-code the OSs to which it - # applies here; at the moment, that means platforms that use the PE - # object format with DLL files. See the long comment at the top of - # tests/bindir.at for full details. - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) - # If a -bindir argument was supplied, place the dll there. - if test "x$bindir" != x ; - then - func_relative_path "$install_libdir" "$bindir" - tdlname=$func_relative_path_result$dlname - else - # Otherwise fall back on heuristic. - tdlname=../bin/$dlname - fi - ;; - esac - $ECHO > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# Please DO NOT delete this file! -# It is necessary for linking the library. - -# The name that we can dlopen(3). -dlname='$tdlname' - -# Names of this library. -library_names='$library_names' - -# The name of the static archive. -old_library='$old_library' - -# Linker flags that can not go in dependency_libs. -inherited_linker_flags='$new_inherited_linker_flags' - -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' - -# Names of additional weak libraries provided by this library -weak_library_names='$weak_libs' - -# Version information for $libname. -current=$current -age=$age -revision=$revision - -# Is this an already installed library? -installed=$installed - -# Should we warn about portability when linking against -modules? -shouldnotlink=$module - -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' - -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test "$installed" = no && test "$need_relink" = yes; then - $ECHO >> $output "\ -relink_command=\"$relink_command\"" - fi - done - } - - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' - ;; - esac - exit $EXIT_SUCCESS -} - -{ test "$opt_mode" = link || test "$opt_mode" = relink; } && - func_mode_link ${1+"$@"} - - -# func_mode_uninstall arg... -func_mode_uninstall () -{ - $opt_debug - RM="$nonopt" - files= - rmforce= - exit_status=0 - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - for arg - do - case $arg in - -f) func_append RM " $arg"; rmforce=yes ;; - -*) func_append RM " $arg" ;; - *) func_append files " $arg" ;; - esac - done - - test -z "$RM" && \ - func_fatal_help "you must specify an RM program" - - rmdirs= - - for file in $files; do - func_dirname "$file" "" "." - dir="$func_dirname_result" - if test "X$dir" = X.; then - odir="$objdir" - else - odir="$dir/$objdir" - fi - func_basename "$file" - name="$func_basename_result" - test "$opt_mode" = uninstall && odir="$dir" - - # Remember odir for removal later, being careful to avoid duplicates - if test "$opt_mode" = clean; then - case " $rmdirs " in - *" $odir "*) ;; - *) func_append rmdirs " $odir" ;; - esac - fi - - # Don't error if the file doesn't exist and rm -f was used. - if { test -L "$file"; } >/dev/null 2>&1 || - { test -h "$file"; } >/dev/null 2>&1 || - test -f "$file"; then - : - elif test -d "$file"; then - exit_status=1 - continue - elif test "$rmforce" = yes; then - continue - fi - - rmfiles="$file" - - case $name in - *.la) - # Possibly a libtool archive, so verify it. - if func_lalib_p "$file"; then - func_source $dir/$name - - # Delete the libtool libraries and symlinks. - for n in $library_names; do - func_append rmfiles " $odir/$n" - done - test -n "$old_library" && func_append rmfiles " $odir/$old_library" - - case "$opt_mode" in - clean) - case " $library_names " in - *" $dlname "*) ;; - *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; - esac - test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" - ;; - uninstall) - if test -n "$library_names"; then - # Do each command in the postuninstall commands. - func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - - if test -n "$old_library"; then - # Do each command in the old_postuninstall commands. - func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' - fi - # FIXME: should reinstall the best remaining shared library. - ;; - esac - fi - ;; - - *.lo) - # Possibly a libtool object, so verify it. - if func_lalib_p "$file"; then - - # Read the .lo file - func_source $dir/$name - - # Add PIC object to the list of files to remove. - if test -n "$pic_object" && - test "$pic_object" != none; then - func_append rmfiles " $dir/$pic_object" - fi - - # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" && - test "$non_pic_object" != none; then - func_append rmfiles " $dir/$non_pic_object" - fi - fi - ;; - - *) - if test "$opt_mode" = clean ; then - noexename=$name - case $file in - *.exe) - func_stripname '' '.exe' "$file" - file=$func_stripname_result - func_stripname '' '.exe' "$name" - noexename=$func_stripname_result - # $file with .exe has already been added to rmfiles, - # add $file without .exe - func_append rmfiles " $file" - ;; - esac - # Do a test to see if this is a libtool program. - if func_ltwrapper_p "$file"; then - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - relink_command= - func_source $func_ltwrapper_scriptname_result - func_append rmfiles " $func_ltwrapper_scriptname_result" - else - relink_command= - func_source $dir/$noexename - fi - - # note $name still contains .exe if it was in $file originally - # as does the version of $file that was added into $rmfiles - func_append rmfiles " $odir/$name $odir/${name}S.${objext}" - if test "$fast_install" = yes && test -n "$relink_command"; then - func_append rmfiles " $odir/lt-$name" - fi - if test "X$noexename" != "X$name" ; then - func_append rmfiles " $odir/lt-${noexename}.c" - fi - fi - fi - ;; - esac - func_show_eval "$RM $rmfiles" 'exit_status=1' - done - - # Try to remove the ${objdir}s in the directories where we deleted files - for dir in $rmdirs; do - if test -d "$dir"; then - func_show_eval "rmdir $dir >/dev/null 2>&1" - fi - done - - exit $exit_status -} - -{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && - func_mode_uninstall ${1+"$@"} - -test -z "$opt_mode" && { - help="$generic_help" - func_fatal_help "you must specify a MODE" -} - -test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode \`$opt_mode'" - -if test -n "$exec_cmd"; then - eval exec "$exec_cmd" - exit $EXIT_FAILURE -fi - -exit $exit_status - - -# The TAGs below are defined such that we never get into a situation -# in which we disable both kinds of libraries. Given conflicting -# choices, we go for a static library, that is the most portable, -# since we can't tell whether shared libraries were disabled because -# the user asked for that or because the platform doesn't support -# them. This is particularly important on AIX, because we don't -# support having both static and shared libraries enabled at the same -# time on that platform, so we default to a shared-only configuration. -# If a disable-shared tag is given, we'll fallback to a static-only -# configuration. But we'll never go from static-only to shared-only. - -# ### BEGIN LIBTOOL TAG CONFIG: disable-shared -build_libtool_libs=no -build_old_libs=yes -# ### END LIBTOOL TAG CONFIG: disable-shared - -# ### BEGIN LIBTOOL TAG CONFIG: disable-static -build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` -# ### END LIBTOOL TAG CONFIG: disable-static - -# Local Variables: -# mode:shell-script -# sh-indentation:2 -# End: -# vi:sw=2 - diff --git a/lib-src/libmad/mad.h.sed b/lib-src/libmad/mad.h.sed deleted file mode 100644 index 7e4c4af5e..000000000 --- a/lib-src/libmad/mad.h.sed +++ /dev/null @@ -1,36 +0,0 @@ -# -# libmad - MPEG audio decoder library -# Copyright (C) 2000-2004 Underbit Technologies, Inc. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -# -# $Id: mad.h.sed,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ -# - -/^\/\*$/{ -N -s/ \* libmad - /&/ -t copy -b next -: copy -g -n -s|^ \* \$\(Id: .*\) \$$|/* \1 */|p -/^ \*\/$/d -b copy -} -/^# *include "/d -: next -p diff --git a/lib-src/libmad/minimad.c b/lib-src/libmad/minimad.c deleted file mode 100644 index 0360df5d5..000000000 --- a/lib-src/libmad/minimad.c +++ /dev/null @@ -1,222 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: minimad.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# include -# include -# include -# include - -# include "mad.h" - -/* - * This is perhaps the simplest example use of the MAD high-level API. - * Standard input is mapped into memory via mmap(), then the high-level API - * is invoked with three callbacks: input, output, and error. The output - * callback converts MAD's high-resolution PCM samples to 16 bits, then - * writes them to standard output in little-endian, stereo-interleaved - * format. - */ - -static int decode(unsigned char const *, unsigned long); - -int main(int argc, char *argv[]) -{ - struct stat stat; - void *fdm; - - if (argc != 1) - return 1; - - if (fstat(STDIN_FILENO, &stat) == -1 || - stat.st_size == 0) - return 2; - - fdm = mmap(0, stat.st_size, PROT_READ, MAP_SHARED, STDIN_FILENO, 0); - if (fdm == MAP_FAILED) - return 3; - - decode(fdm, stat.st_size); - - if (munmap(fdm, stat.st_size) == -1) - return 4; - - return 0; -} - -/* - * This is a private message structure. A generic pointer to this structure - * is passed to each of the callback functions. Put here any data you need - * to access from within the callbacks. - */ - -struct buffer { - unsigned char const *start; - unsigned long length; -}; - -/* - * This is the input callback. The purpose of this callback is to (re)fill - * the stream buffer which is to be decoded. In this example, an entire file - * has been mapped into memory, so we just call mad_stream_buffer() with the - * address and length of the mapping. When this callback is called a second - * time, we are finished decoding. - */ - -static -enum mad_flow input(void *data, - struct mad_stream *stream) -{ - struct buffer *buffer = data; - - if (!buffer->length) - return MAD_FLOW_STOP; - - mad_stream_buffer(stream, buffer->start, buffer->length); - - buffer->length = 0; - - return MAD_FLOW_CONTINUE; -} - -/* - * The following utility routine performs simple rounding, clipping, and - * scaling of MAD's high-resolution samples down to 16 bits. It does not - * perform any dithering or noise shaping, which would be recommended to - * obtain any exceptional audio quality. It is therefore not recommended to - * use this routine if high-quality output is desired. - */ - -static inline -signed int scale(mad_fixed_t sample) -{ - /* round */ - sample += (1L << (MAD_F_FRACBITS - 16)); - - /* clip */ - if (sample >= MAD_F_ONE) - sample = MAD_F_ONE - 1; - else if (sample < -MAD_F_ONE) - sample = -MAD_F_ONE; - - /* quantize */ - return sample >> (MAD_F_FRACBITS + 1 - 16); -} - -/* - * This is the output callback function. It is called after each frame of - * MPEG audio data has been completely decoded. The purpose of this callback - * is to output (or play) the decoded PCM audio. - */ - -static -enum mad_flow output(void *data, - struct mad_header const *header, - struct mad_pcm *pcm) -{ - unsigned int nchannels, nsamples; - mad_fixed_t const *left_ch, *right_ch; - - /* pcm->samplerate contains the sampling frequency */ - - nchannels = pcm->channels; - nsamples = pcm->length; - left_ch = pcm->samples[0]; - right_ch = pcm->samples[1]; - - while (nsamples--) { - signed int sample; - - /* output sample(s) in 16-bit signed little-endian PCM */ - - sample = scale(*left_ch++); - putchar((sample >> 0) & 0xff); - putchar((sample >> 8) & 0xff); - - if (nchannels == 2) { - sample = scale(*right_ch++); - putchar((sample >> 0) & 0xff); - putchar((sample >> 8) & 0xff); - } - } - - return MAD_FLOW_CONTINUE; -} - -/* - * This is the error callback function. It is called whenever a decoding - * error occurs. The error is indicated by stream->error; the list of - * possible MAD_ERROR_* errors can be found in the mad.h (or stream.h) - * header file. - */ - -static -enum mad_flow error(void *data, - struct mad_stream *stream, - struct mad_frame *frame) -{ - struct buffer *buffer = data; - - fprintf(stderr, "decoding error 0x%04x (%s) at byte offset %u\n", - stream->error, mad_stream_errorstr(stream), - stream->this_frame - buffer->start); - - /* return MAD_FLOW_BREAK here to stop decoding (and propagate an error) */ - - return MAD_FLOW_CONTINUE; -} - -/* - * This is the function called by main() above to perform all the decoding. - * It instantiates a decoder object and configures it with the input, - * output, and error callback functions above. A single call to - * mad_decoder_run() continues until a callback function returns - * MAD_FLOW_STOP (to stop decoding) or MAD_FLOW_BREAK (to stop decoding and - * signal an error). - */ - -static -int decode(unsigned char const *start, unsigned long length) -{ - struct buffer buffer; - struct mad_decoder decoder; - int result; - - /* initialize our private message structure */ - - buffer.start = start; - buffer.length = length; - - /* configure input, output, and error functions */ - - mad_decoder_init(&decoder, &buffer, - input, 0 /* header */, 0 /* filter */, output, - error, 0 /* message */); - - /* start decoding */ - - result = mad_decoder_run(&decoder, MAD_DECODER_MODE_SYNC); - - /* release the decoder */ - - mad_decoder_finish(&decoder); - - return result; -} diff --git a/lib-src/libmad/missing b/lib-src/libmad/missing deleted file mode 100755 index db98974ff..000000000 --- a/lib-src/libmad/missing +++ /dev/null @@ -1,215 +0,0 @@ -#! /bin/sh -# Common wrapper for a few potentially missing GNU programs. - -scriptversion=2013-10-28.13; # UTC - -# Copyright (C) 1996-2013 Free Software Foundation, Inc. -# Originally written by Fran,cois Pinard , 1996. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -if test $# -eq 0; then - echo 1>&2 "Try '$0 --help' for more information" - exit 1 -fi - -case $1 in - - --is-lightweight) - # Used by our autoconf macros to check whether the available missing - # script is modern enough. - exit 0 - ;; - - --run) - # Back-compat with the calling convention used by older automake. - shift - ;; - - -h|--h|--he|--hel|--help) - echo "\ -$0 [OPTION]... PROGRAM [ARGUMENT]... - -Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due -to PROGRAM being missing or too old. - -Options: - -h, --help display this help and exit - -v, --version output version information and exit - -Supported PROGRAM values: - aclocal autoconf autoheader autom4te automake makeinfo - bison yacc flex lex help2man - -Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and -'g' are ignored when checking the name. - -Send bug reports to ." - exit $? - ;; - - -v|--v|--ve|--ver|--vers|--versi|--versio|--version) - echo "missing $scriptversion (GNU Automake)" - exit $? - ;; - - -*) - echo 1>&2 "$0: unknown '$1' option" - echo 1>&2 "Try '$0 --help' for more information" - exit 1 - ;; - -esac - -# Run the given program, remember its exit status. -"$@"; st=$? - -# If it succeeded, we are done. -test $st -eq 0 && exit 0 - -# Also exit now if we it failed (or wasn't found), and '--version' was -# passed; such an option is passed most likely to detect whether the -# program is present and works. -case $2 in --version|--help) exit $st;; esac - -# Exit code 63 means version mismatch. This often happens when the user -# tries to use an ancient version of a tool on a file that requires a -# minimum version. -if test $st -eq 63; then - msg="probably too old" -elif test $st -eq 127; then - # Program was missing. - msg="missing on your system" -else - # Program was found and executed, but failed. Give up. - exit $st -fi - -perl_URL=http://www.perl.org/ -flex_URL=http://flex.sourceforge.net/ -gnu_software_URL=http://www.gnu.org/software - -program_details () -{ - case $1 in - aclocal|automake) - echo "The '$1' program is part of the GNU Automake package:" - echo "<$gnu_software_URL/automake>" - echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/autoconf>" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - autoconf|autom4te|autoheader) - echo "The '$1' program is part of the GNU Autoconf package:" - echo "<$gnu_software_URL/autoconf/>" - echo "It also requires GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - esac -} - -give_advice () -{ - # Normalize program name to check for. - normalized_program=`echo "$1" | sed ' - s/^gnu-//; t - s/^gnu//; t - s/^g//; t'` - - printf '%s\n' "'$1' is $msg." - - configure_deps="'configure.ac' or m4 files included by 'configure.ac'" - case $normalized_program in - autoconf*) - echo "You should only need it if you modified 'configure.ac'," - echo "or m4 files included by it." - program_details 'autoconf' - ;; - autoheader*) - echo "You should only need it if you modified 'acconfig.h' or" - echo "$configure_deps." - program_details 'autoheader' - ;; - automake*) - echo "You should only need it if you modified 'Makefile.am' or" - echo "$configure_deps." - program_details 'automake' - ;; - aclocal*) - echo "You should only need it if you modified 'acinclude.m4' or" - echo "$configure_deps." - program_details 'aclocal' - ;; - autom4te*) - echo "You might have modified some maintainer files that require" - echo "the 'autom4te' program to be rebuilt." - program_details 'autom4te' - ;; - bison*|yacc*) - echo "You should only need it if you modified a '.y' file." - echo "You may want to install the GNU Bison package:" - echo "<$gnu_software_URL/bison/>" - ;; - lex*|flex*) - echo "You should only need it if you modified a '.l' file." - echo "You may want to install the Fast Lexical Analyzer package:" - echo "<$flex_URL>" - ;; - help2man*) - echo "You should only need it if you modified a dependency" \ - "of a man page." - echo "You may want to install the GNU Help2man package:" - echo "<$gnu_software_URL/help2man/>" - ;; - makeinfo*) - echo "You should only need it if you modified a '.texi' file, or" - echo "any other file indirectly affecting the aspect of the manual." - echo "You might want to install the Texinfo package:" - echo "<$gnu_software_URL/texinfo/>" - echo "The spurious makeinfo call might also be the consequence of" - echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" - echo "want to install GNU make:" - echo "<$gnu_software_URL/make/>" - ;; - *) - echo "You might have modified some files without having the proper" - echo "tools for further handling them. Check the 'README' file, it" - echo "often tells you about the needed prerequisites for installing" - echo "this package. You may also peek at any GNU archive site, in" - echo "case some other package contains this missing '$1' program." - ;; - esac -} - -give_advice "$1" | sed -e '1s/^/WARNING: /' \ - -e '2,$s/^/ /' >&2 - -# Propagate the correct exit status (expected to be 127 for a program -# not found, 63 for a program that failed due to version mismatch). -exit $st - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libmad/mkinstalldirs b/lib-src/libmad/mkinstalldirs deleted file mode 100755 index 55d537f87..000000000 --- a/lib-src/libmad/mkinstalldirs +++ /dev/null @@ -1,162 +0,0 @@ -#! /bin/sh -# mkinstalldirs --- make directory hierarchy - -scriptversion=2009-04-28.21; # UTC - -# Original author: Noah Friedman -# Created: 1993-05-16 -# Public domain. -# -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -nl=' -' -IFS=" "" $nl" -errstatus=0 -dirmode= - -usage="\ -Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ... - -Create each directory DIR (with mode MODE, if specified), including all -leading file name components. - -Report bugs to ." - -# process command line arguments -while test $# -gt 0 ; do - case $1 in - -h | --help | --h*) # -h for help - echo "$usage" - exit $? - ;; - -m) # -m PERM arg - shift - test $# -eq 0 && { echo "$usage" 1>&2; exit 1; } - dirmode=$1 - shift - ;; - --version) - echo "$0 $scriptversion" - exit $? - ;; - --) # stop option processing - shift - break - ;; - -*) # unknown option - echo "$usage" 1>&2 - exit 1 - ;; - *) # first non-opt arg - break - ;; - esac -done - -for file -do - if test -d "$file"; then - shift - else - break - fi -done - -case $# in - 0) exit 0 ;; -esac - -# Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and -# mkdir -p a/c at the same time, both will detect that a is missing, -# one will create a, then the other will try to create a and die with -# a "File exists" error. This is a problem when calling mkinstalldirs -# from a parallel make. We use --version in the probe to restrict -# ourselves to GNU mkdir, which is thread-safe. -case $dirmode in - '') - if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then - echo "mkdir -p -- $*" - exec mkdir -p -- "$@" - else - # On NextStep and OpenStep, the 'mkdir' command does not - # recognize any option. It will interpret all options as - # directories to create, and then abort because '.' already - # exists. - test -d ./-p && rmdir ./-p - test -d ./--version && rmdir ./--version - fi - ;; - *) - if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 && - test ! -d ./--version; then - echo "mkdir -m $dirmode -p -- $*" - exec mkdir -m "$dirmode" -p -- "$@" - else - # Clean up after NextStep and OpenStep mkdir. - for d in ./-m ./-p ./--version "./$dirmode"; - do - test -d $d && rmdir $d - done - fi - ;; -esac - -for file -do - case $file in - /*) pathcomp=/ ;; - *) pathcomp= ;; - esac - oIFS=$IFS - IFS=/ - set fnord $file - shift - IFS=$oIFS - - for d - do - test "x$d" = x && continue - - pathcomp=$pathcomp$d - case $pathcomp in - -*) pathcomp=./$pathcomp ;; - esac - - if test ! -d "$pathcomp"; then - echo "mkdir $pathcomp" - - mkdir "$pathcomp" || lasterr=$? - - if test ! -d "$pathcomp"; then - errstatus=$lasterr - else - if test ! -z "$dirmode"; then - echo "chmod $dirmode $pathcomp" - lasterr= - chmod "$dirmode" "$pathcomp" || lasterr=$? - - if test ! -z "$lasterr"; then - errstatus=$lasterr - fi - fi - fi - fi - - pathcomp=$pathcomp/ - done -done - -exit $errstatus - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib-src/libmad/msvc++/Makefile.am b/lib-src/libmad/msvc++/Makefile.am deleted file mode 100644 index 1ea15058a..000000000 --- a/lib-src/libmad/msvc++/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -## -## libmad - MPEG audio decoder library -## Copyright (C) 2000-2004 Underbit Technologies, Inc. -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License -## along with this program; if not, write to the Free Software -## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -## -## $Id: Makefile.am,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ -## - -## Process this file with automake to produce Makefile.in - -EXTRA_DIST = mad.h config.h libmad.dsp diff --git a/lib-src/libmad/msvc++/Makefile.in b/lib-src/libmad/msvc++/Makefile.in deleted file mode 100644 index 8dc216960..000000000 --- a/lib-src/libmad/msvc++/Makefile.in +++ /dev/null @@ -1,428 +0,0 @@ -# Makefile.in generated by automake 1.14.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2013 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = msvc++ -DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ - $(top_srcdir)/mkinstalldirs -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -ASO = @ASO@ -ASO_OBJS = @ASO_OBJS@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCAS = @CCAS@ -CCASDEPMODE = @CCASDEPMODE@ -CCASFLAGS = @CCASFLAGS@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FPM = @FPM@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -EXTRA_DIST = mad.h config.h libmad.dsp -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign msvc++/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign msvc++/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib-src/libmad/msvc++/config.h b/lib-src/libmad/msvc++/config.h deleted file mode 100644 index 02683a5f8..000000000 --- a/lib-src/libmad/msvc++/config.h +++ /dev/null @@ -1,130 +0,0 @@ -/* config.h. Generated by configure. */ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to enable diagnostic debugging support. */ -/* #undef DEBUG */ - -/* Define to enable experimental code. */ -/* #undef EXPERIMENTAL */ - -/* Define to 1 if you have the header file. */ -#define HAVE_ASSERT_H 1 - -/* Define to 1 if you have the header file. */ -/* #undef HAVE_DLFCN_H */ - -/* Define to 1 if you have the header file. */ -#define HAVE_ERRNO_H 1 - -/* Define to 1 if you have the `fcntl' function. */ -/* #undef HAVE_FCNTL */ - -/* Define to 1 if you have the header file. */ -#define HAVE_FCNTL_H 1 - -/* Define to 1 if you have the `fork' function. */ -/* #undef HAVE_FORK */ - -/* Define to 1 if you have the header file. */ -#define HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_LIMITS_H 1 - -/* Define if your MIPS CPU supports a 2-operand MADD16 instruction. */ -/* #undef HAVE_MADD16_ASM */ - -/* Define if your MIPS CPU supports a 2-operand MADD instruction. */ -/* #undef HAVE_MADD_ASM */ - -/* Define to 1 if you have the header file. */ -#define HAVE_MEMORY_H 1 - -/* Define to 1 if you have the `pipe' function. */ -/* #undef HAVE_PIPE */ - -/* Define to 1 if you have the header file. */ -#define HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRING_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have that is POSIX.1 compatible. */ -/* #undef HAVE_SYS_WAIT_H */ - -/* Define to 1 if you have the header file. */ -/* #undef HAVE_UNISTD_H */ - -/* Define to 1 if you have the `waitpid' function. */ -/* #undef HAVE_WAITPID */ - -/* Define to disable debugging assertions. */ -/* #undef NDEBUG */ - -/* Define to optimize for accuracy over speed. */ -/* #undef OPT_ACCURACY */ - -/* Define to optimize for speed over accuracy. */ -/* #undef OPT_SPEED */ - -/* Define to enable a fast subband synthesis approximation optimization. */ -/* #undef OPT_SSO */ - -/* Define to influence a strict interpretation of the ISO/IEC standards, even - if this is in opposition with best accepted practices. */ -/* #undef OPT_STRICT */ - -/* Name of package */ -#define PACKAGE "libmad" - -/* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "support@underbit.com" - -/* Define to the full name of this package. */ -#define PACKAGE_NAME "MPEG Audio Decoder" - -/* Define to the full name and version of this package. */ -#define PACKAGE_STRING "MPEG Audio Decoder 0.15.1b" - -/* Define to the one symbol short name of this package. */ -#define PACKAGE_TARNAME "libmad" - -/* Define to the version of this package. */ -#define PACKAGE_VERSION "0.15.1b" - -/* The size of a `int', as computed by sizeof. */ -#define SIZEOF_INT 4 - -/* The size of a `long', as computed by sizeof. */ -#define SIZEOF_LONG 4 - -/* The size of a `long long', as computed by sizeof. */ -#define SIZEOF_LONG_LONG 8 - -/* Define to 1 if you have the ANSI C header files. */ -#define STDC_HEADERS 1 - -/* Version number of package */ -#define VERSION "0.15.1b" - -/* Define to empty if `const' does not conform to ANSI C. */ -/* #undef const */ - -/* Define as `__inline' if that's what the C compiler calls it, or to nothing - if it is not supported. */ -#define inline __inline - -/* Define to `int' if does not define. */ -/* #undef pid_t */ diff --git a/lib-src/libmad/msvc++/libmad.dsp b/lib-src/libmad/msvc++/libmad.dsp deleted file mode 100644 index faf83132f..000000000 --- a/lib-src/libmad/msvc++/libmad.dsp +++ /dev/null @@ -1,214 +0,0 @@ -# Microsoft Developer Studio Project File - Name="libmad" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Static Library" 0x0104 - -CFG=libmad - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "libmad.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "libmad.mak" CFG="libmad - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "libmad - Win32 Release" (based on "Win32 (x86) Static Library") -!MESSAGE "libmad - Win32 Debug" (based on "Win32 (x86) Static Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "libmad - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c -# ADD CPP /nologo /GX /O2 /I "." /D "NDEBUG" /D "FPM_INTEL" /D "WIN32" /D "_MBCS" /D "_LIB" /D "HAVE_CONFIG_H" /D "ASO_ZEROCHECK" /FD /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo - -!ELSEIF "$(CFG)" == "libmad - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c -# ADD CPP /nologo /Gm /GX /ZI /Od /I "." /D "FPM_DEFAULT" /D "_LIB" /D "HAVE_CONFIG_H" /D "ASO_ZEROCHECK" /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "DEBUG" /FD /GZ /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo - -!ENDIF - -# Begin Target - -# Name "libmad - Win32 Release" -# Name "libmad - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "c" -# Begin Source File - -SOURCE=..\bit.c -# End Source File -# Begin Source File - -SOURCE=..\decoder.c -# End Source File -# Begin Source File - -SOURCE=..\fixed.c -# End Source File -# Begin Source File - -SOURCE=..\frame.c -# End Source File -# Begin Source File - -SOURCE=..\huffman.c -# End Source File -# Begin Source File - -SOURCE=..\layer12.c -# End Source File -# Begin Source File - -SOURCE=..\layer3.c -# End Source File -# Begin Source File - -SOURCE=..\stream.c -# End Source File -# Begin Source File - -SOURCE=..\synth.c -# End Source File -# Begin Source File - -SOURCE=..\timer.c -# End Source File -# Begin Source File - -SOURCE=..\version.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h" -# Begin Source File - -SOURCE=..\bit.h -# End Source File -# Begin Source File - -SOURCE=.\config.h -# End Source File -# Begin Source File - -SOURCE=..\decoder.h -# End Source File -# Begin Source File - -SOURCE=..\fixed.h -# End Source File -# Begin Source File - -SOURCE=..\frame.h -# End Source File -# Begin Source File - -SOURCE=..\global.h -# End Source File -# Begin Source File - -SOURCE=..\huffman.h -# End Source File -# Begin Source File - -SOURCE=..\layer12.h -# End Source File -# Begin Source File - -SOURCE=..\layer3.h -# End Source File -# Begin Source File - -SOURCE=..\stream.h -# End Source File -# Begin Source File - -SOURCE=..\synth.h -# End Source File -# Begin Source File - -SOURCE=..\timer.h -# End Source File -# Begin Source File - -SOURCE=..\version.h -# End Source File -# End Group -# Begin Group "Data Files" - -# PROP Default_Filter "dat" -# Begin Source File - -SOURCE=..\D.dat -# End Source File -# Begin Source File - -SOURCE=..\imdct_s.dat -# End Source File -# Begin Source File - -SOURCE=..\qc_table.dat -# End Source File -# Begin Source File - -SOURCE=..\rq_table.dat -# End Source File -# Begin Source File - -SOURCE=..\sf_table.dat -# End Source File -# End Group -# End Target -# End Project diff --git a/lib-src/libmad/msvc++/mad.h b/lib-src/libmad/msvc++/mad.h deleted file mode 100644 index d48347856..000000000 --- a/lib-src/libmad/msvc++/mad.h +++ /dev/null @@ -1,948 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * If you would like to negotiate alternate licensing terms, you may do - * so by contacting: Underbit Technologies, Inc. - */ - -# ifdef __cplusplus -extern "C" { -# endif - -# define FPM_INTEL - - - -# define SIZEOF_INT 4 -# define SIZEOF_LONG 4 -# define SIZEOF_LONG_LONG 8 - - -/* Id: version.h,v 1.24 2003/05/27 22:40:37 rob Exp */ - -# ifndef LIBMAD_VERSION_H -# define LIBMAD_VERSION_H - -# define MAD_VERSION_MAJOR 0 -# define MAD_VERSION_MINOR 15 -# define MAD_VERSION_PATCH 1 -# define MAD_VERSION_EXTRA " (beta)" - -# define MAD_VERSION_STRINGIZE(str) #str -# define MAD_VERSION_STRING(num) MAD_VERSION_STRINGIZE(num) - -# define MAD_VERSION MAD_VERSION_STRING(MAD_VERSION_MAJOR) "." \ - MAD_VERSION_STRING(MAD_VERSION_MINOR) "." \ - MAD_VERSION_STRING(MAD_VERSION_PATCH) \ - MAD_VERSION_EXTRA - -# define MAD_PUBLISHYEAR "2000-2003" -# define MAD_AUTHOR "Underbit Technologies, Inc." -# define MAD_EMAIL "info@underbit.com" - -extern char const mad_version[]; -extern char const mad_copyright[]; -extern char const mad_author[]; -extern char const mad_build[]; - -# endif - -/* Id: fixed.h,v 1.36 2003/05/28 04:36:00 rob Exp */ - -# ifndef LIBMAD_FIXED_H -# define LIBMAD_FIXED_H - -# if SIZEOF_INT >= 4 -typedef signed int mad_fixed_t; - -typedef signed int mad_fixed64hi_t; -typedef unsigned int mad_fixed64lo_t; -# else -typedef signed long mad_fixed_t; - -typedef signed long mad_fixed64hi_t; -typedef unsigned long mad_fixed64lo_t; -# endif - -# if defined(_MSC_VER) -# define mad_fixed64_t signed __int64 -# elif 1 || defined(__GNUC__) -# define mad_fixed64_t signed long long -# endif - -# if defined(FPM_FLOAT) -typedef double mad_sample_t; -# else -typedef mad_fixed_t mad_sample_t; -# endif - -/* - * Fixed-point format: 0xABBBBBBB - * A == whole part (sign + 3 bits) - * B == fractional part (28 bits) - * - * Values are signed two's complement, so the effective range is: - * 0x80000000 to 0x7fffffff - * -8.0 to +7.9999999962747097015380859375 - * - * The smallest representable value is: - * 0x00000001 == 0.0000000037252902984619140625 (i.e. about 3.725e-9) - * - * 28 bits of fractional accuracy represent about - * 8.6 digits of decimal accuracy. - * - * Fixed-point numbers can be added or subtracted as normal - * integers, but multiplication requires shifting the 64-bit result - * from 56 fractional bits back to 28 (and rounding.) - * - * Changing the definition of MAD_F_FRACBITS is only partially - * supported, and must be done with care. - */ - -# define MAD_F_FRACBITS 28 - -# if MAD_F_FRACBITS == 28 -# define MAD_F(x) ((mad_fixed_t) (x##L)) -# else -# if MAD_F_FRACBITS < 28 -# warning "MAD_F_FRACBITS < 28" -# define MAD_F(x) ((mad_fixed_t) \ - (((x##L) + \ - (1L << (28 - MAD_F_FRACBITS - 1))) >> \ - (28 - MAD_F_FRACBITS))) -# elif MAD_F_FRACBITS > 28 -# error "MAD_F_FRACBITS > 28 not currently supported" -# define MAD_F(x) ((mad_fixed_t) \ - ((x##L) << (MAD_F_FRACBITS - 28))) -# endif -# endif - -# define MAD_F_MIN ((mad_fixed_t) -0x80000000L) -# define MAD_F_MAX ((mad_fixed_t) +0x7fffffffL) - -# define MAD_F_ONE MAD_F(0x10000000) - -# define mad_f_tofixed(x) ((mad_fixed_t) \ - ((x) * (double) (1L << MAD_F_FRACBITS) + 0.5)) -# define mad_f_todouble(x) ((double) \ - ((x) / (double) (1L << MAD_F_FRACBITS))) - -# define mad_f_intpart(x) ((x) >> MAD_F_FRACBITS) -# define mad_f_fracpart(x) ((x) & ((1L << MAD_F_FRACBITS) - 1)) - /* (x should be positive) */ - -# define mad_f_fromint(x) ((x) << MAD_F_FRACBITS) - -# define mad_f_add(x, y) ((x) + (y)) -# define mad_f_sub(x, y) ((x) - (y)) - -# if defined(FPM_FLOAT) -# error "FPM_FLOAT not yet supported" - -# undef MAD_F -# define MAD_F(x) mad_f_todouble(x) - -# define mad_f_mul(x, y) ((x) * (y)) -# define mad_f_scale64 - -# undef ASO_ZEROCHECK - -# elif defined(FPM_64BIT) - -/* - * This version should be the most accurate if 64-bit types are supported by - * the compiler, although it may not be the most efficient. - */ -# if defined(OPT_ACCURACY) -# define mad_f_mul(x, y) \ - ((mad_fixed_t) \ - ((((mad_fixed64_t) (x) * (y)) + \ - (1L << (MAD_F_SCALEBITS - 1))) >> MAD_F_SCALEBITS)) -# else -# define mad_f_mul(x, y) \ - ((mad_fixed_t) (((mad_fixed64_t) (x) * (y)) >> MAD_F_SCALEBITS)) -# endif - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- Intel --------------------------------------------------------------- */ - -# elif defined(FPM_INTEL) - -# if defined(_MSC_VER) -# pragma warning(push) -# pragma warning(disable: 4035) /* no return value */ -static __forceinline -mad_fixed_t mad_f_mul_inline(mad_fixed_t x, mad_fixed_t y) -{ - enum { - fracbits = MAD_F_FRACBITS - }; - - __asm { - mov eax, x - imul y - shrd eax, edx, fracbits - } - - /* implicit return of eax */ -} -# pragma warning(pop) - -# define mad_f_mul mad_f_mul_inline -# define mad_f_scale64 -# else -/* - * This Intel version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("imull %3" \ - : "=a" (lo), "=d" (hi) \ - : "%a" (x), "rm" (y) \ - : "cc") - -# if defined(OPT_ACCURACY) -/* - * This gives best accuracy but is not very fast. - */ -# define MAD_F_MLA(hi, lo, x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - asm ("addl %2,%0\n\t" \ - "adcl %3,%1" \ - : "=rm" (lo), "=rm" (hi) \ - : "r" (__lo), "r" (__hi), "0" (lo), "1" (hi) \ - : "cc"); \ - }) -# endif /* OPT_ACCURACY */ - -# if defined(OPT_ACCURACY) -/* - * Surprisingly, this is faster than SHRD followed by ADC. - */ -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed64hi_t __hi_; \ - mad_fixed64lo_t __lo_; \ - mad_fixed_t __result; \ - asm ("addl %4,%2\n\t" \ - "adcl %5,%3" \ - : "=rm" (__lo_), "=rm" (__hi_) \ - : "0" (lo), "1" (hi), \ - "ir" (1L << (MAD_F_SCALEBITS - 1)), "ir" (0) \ - : "cc"); \ - asm ("shrdl %3,%2,%1" \ - : "=rm" (__result) \ - : "0" (__lo_), "r" (__hi_), "I" (MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# else -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("shrdl %3,%2,%1" \ - : "=rm" (__result) \ - : "0" (lo), "r" (hi), "I" (MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# endif /* OPT_ACCURACY */ - -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* --- ARM ----------------------------------------------------------------- */ - -# elif defined(FPM_ARM) - -/* - * This ARM V4 version is as accurate as FPM_64BIT but much faster. The - * least significant bit is properly rounded at no CPU cycle cost! - */ -# if 1 -/* - * This is faster than the default implementation via MAD_F_MLX() and - * mad_f_scale64(). - */ -# define mad_f_mul(x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - mad_fixed_t __result; \ - asm ("smull %0, %1, %3, %4\n\t" \ - "movs %0, %0, lsr %5\n\t" \ - "adc %2, %0, %1, lsl %6" \ - : "=&r" (__lo), "=&r" (__hi), "=r" (__result) \ - : "%r" (x), "r" (y), \ - "M" (MAD_F_SCALEBITS), "M" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) -# endif - -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("smull %0, %1, %2, %3" \ - : "=&r" (lo), "=&r" (hi) \ - : "%r" (x), "r" (y)) - -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("smlal %0, %1, %2, %3" \ - : "+r" (lo), "+r" (hi) \ - : "%r" (x), "r" (y)) - -# define MAD_F_MLN(hi, lo) \ - asm ("rsbs %0, %2, #0\n\t" \ - "rsc %1, %3, #0" \ - : "=r" (lo), "=r" (hi) \ - : "0" (lo), "1" (hi) \ - : "cc") - -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("movs %0, %1, lsr %3\n\t" \ - "adc %0, %0, %2, lsl %4" \ - : "=&r" (__result) \ - : "r" (lo), "r" (hi), \ - "M" (MAD_F_SCALEBITS), "M" (32 - MAD_F_SCALEBITS) \ - : "cc"); \ - __result; \ - }) - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- MIPS ---------------------------------------------------------------- */ - -# elif defined(FPM_MIPS) - -/* - * This MIPS version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("mult %2,%3" \ - : "=l" (lo), "=h" (hi) \ - : "%r" (x), "r" (y)) - -# if defined(HAVE_MADD_ASM) -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("madd %2,%3" \ - : "+l" (lo), "+h" (hi) \ - : "%r" (x), "r" (y)) -# elif defined(HAVE_MADD16_ASM) -/* - * This loses significant accuracy due to the 16-bit integer limit in the - * multiply/accumulate instruction. - */ -# define MAD_F_ML0(hi, lo, x, y) \ - asm ("mult %2,%3" \ - : "=l" (lo), "=h" (hi) \ - : "%r" ((x) >> 12), "r" ((y) >> 16)) -# define MAD_F_MLA(hi, lo, x, y) \ - asm ("madd16 %2,%3" \ - : "+l" (lo), "+h" (hi) \ - : "%r" ((x) >> 12), "r" ((y) >> 16)) -# define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo)) -# endif - -# if defined(OPT_SPEED) -# define mad_f_scale64(hi, lo) \ - ((mad_fixed_t) ((hi) << (32 - MAD_F_SCALEBITS))) -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* --- SPARC --------------------------------------------------------------- */ - -# elif defined(FPM_SPARC) - -/* - * This SPARC V8 version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - asm ("smul %2, %3, %0\n\t" \ - "rd %%y, %1" \ - : "=r" (lo), "=r" (hi) \ - : "%r" (x), "rI" (y)) - -/* --- PowerPC ------------------------------------------------------------- */ - -# elif defined(FPM_PPC) - -/* - * This PowerPC version is fast and accurate; the disposition of the least - * significant bit depends on OPT_ACCURACY via mad_f_scale64(). - */ -# define MAD_F_MLX(hi, lo, x, y) \ - do { \ - asm ("mullw %0,%1,%2" \ - : "=r" (lo) \ - : "%r" (x), "r" (y)); \ - asm ("mulhw %0,%1,%2" \ - : "=r" (hi) \ - : "%r" (x), "r" (y)); \ - } \ - while (0) - -# if defined(OPT_ACCURACY) -/* - * This gives best accuracy but is not very fast. - */ -# define MAD_F_MLA(hi, lo, x, y) \ - ({ mad_fixed64hi_t __hi; \ - mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - asm ("addc %0,%2,%3\n\t" \ - "adde %1,%4,%5" \ - : "=r" (lo), "=r" (hi) \ - : "%r" (lo), "r" (__lo), \ - "%r" (hi), "r" (__hi) \ - : "xer"); \ - }) -# endif - -# if defined(OPT_ACCURACY) -/* - * This is slower than the truncating version below it. - */ -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result, __round; \ - asm ("rotrwi %0,%1,%2" \ - : "=r" (__result) \ - : "r" (lo), "i" (MAD_F_SCALEBITS)); \ - asm ("extrwi %0,%1,1,0" \ - : "=r" (__round) \ - : "r" (__result)); \ - asm ("insrwi %0,%1,%2,0" \ - : "+r" (__result) \ - : "r" (hi), "i" (MAD_F_SCALEBITS)); \ - asm ("add %0,%1,%2" \ - : "=r" (__result) \ - : "%r" (__result), "r" (__round)); \ - __result; \ - }) -# else -# define mad_f_scale64(hi, lo) \ - ({ mad_fixed_t __result; \ - asm ("rotrwi %0,%1,%2" \ - : "=r" (__result) \ - : "r" (lo), "i" (MAD_F_SCALEBITS)); \ - asm ("insrwi %0,%1,%2,0" \ - : "+r" (__result) \ - : "r" (hi), "i" (MAD_F_SCALEBITS)); \ - __result; \ - }) -# endif - -# define MAD_F_SCALEBITS MAD_F_FRACBITS - -/* --- Default ------------------------------------------------------------- */ - -# elif defined(FPM_DEFAULT) - -/* - * This version is the most portable but it loses significant accuracy. - * Furthermore, accuracy is biased against the second argument, so care - * should be taken when ordering operands. - * - * The scale factors are constant as this is not used with SSO. - * - * Pre-rounding is required to stay within the limits of compliance. - */ -# if defined(OPT_SPEED) -# define mad_f_mul(x, y) (((x) >> 12) * ((y) >> 16)) -# else -# define mad_f_mul(x, y) ((((x) + (1L << 11)) >> 12) * \ - (((y) + (1L << 15)) >> 16)) -# endif - -/* ------------------------------------------------------------------------- */ - -# else -# error "no FPM selected" -# endif - -/* default implementations */ - -# if !defined(mad_f_mul) -# define mad_f_mul(x, y) \ - ({ register mad_fixed64hi_t __hi; \ - register mad_fixed64lo_t __lo; \ - MAD_F_MLX(__hi, __lo, (x), (y)); \ - mad_f_scale64(__hi, __lo); \ - }) -# endif - -# if !defined(MAD_F_MLA) -# define MAD_F_ML0(hi, lo, x, y) ((lo) = mad_f_mul((x), (y))) -# define MAD_F_MLA(hi, lo, x, y) ((lo) += mad_f_mul((x), (y))) -# define MAD_F_MLN(hi, lo) ((lo) = -(lo)) -# define MAD_F_MLZ(hi, lo) ((void) (hi), (mad_fixed_t) (lo)) -# endif - -# if !defined(MAD_F_ML0) -# define MAD_F_ML0(hi, lo, x, y) MAD_F_MLX((hi), (lo), (x), (y)) -# endif - -# if !defined(MAD_F_MLN) -# define MAD_F_MLN(hi, lo) ((hi) = ((lo) = -(lo)) ? ~(hi) : -(hi)) -# endif - -# if !defined(MAD_F_MLZ) -# define MAD_F_MLZ(hi, lo) mad_f_scale64((hi), (lo)) -# endif - -# if !defined(mad_f_scale64) -# if defined(OPT_ACCURACY) -# define mad_f_scale64(hi, lo) \ - ((((mad_fixed_t) \ - (((hi) << (32 - (MAD_F_SCALEBITS - 1))) | \ - ((lo) >> (MAD_F_SCALEBITS - 1)))) + 1) >> 1) -# else -# define mad_f_scale64(hi, lo) \ - ((mad_fixed_t) \ - (((hi) << (32 - MAD_F_SCALEBITS)) | \ - ((lo) >> MAD_F_SCALEBITS))) -# endif -# define MAD_F_SCALEBITS MAD_F_FRACBITS -# endif - -/* C routines */ - -mad_fixed_t mad_f_abs(mad_fixed_t); -mad_fixed_t mad_f_div(mad_fixed_t, mad_fixed_t); - -# endif - -/* Id: bit.h,v 1.11 2003/05/27 22:40:36 rob Exp */ - -# ifndef LIBMAD_BIT_H -# define LIBMAD_BIT_H - -struct mad_bitptr { - unsigned char const *byte; - unsigned short cache; - unsigned short left; -}; - -void mad_bit_init(struct mad_bitptr *, unsigned char const *); - -# define mad_bit_finish(bitptr) /* nothing */ - -unsigned int mad_bit_length(struct mad_bitptr const *, - struct mad_bitptr const *); - -# define mad_bit_bitsleft(bitptr) ((bitptr)->left) -unsigned char const *mad_bit_nextbyte(struct mad_bitptr const *); - -void mad_bit_skip(struct mad_bitptr *, unsigned int); -unsigned long mad_bit_read(struct mad_bitptr *, unsigned int); -void mad_bit_write(struct mad_bitptr *, unsigned int, unsigned long); - -unsigned short mad_bit_crc(struct mad_bitptr, unsigned int, unsigned short); - -# endif - -/* Id: timer.h,v 1.15 2003/05/27 22:40:37 rob Exp */ - -# ifndef LIBMAD_TIMER_H -# define LIBMAD_TIMER_H - -typedef struct { - signed long seconds; /* whole seconds */ - unsigned long fraction; /* 1/MAD_TIMER_RESOLUTION seconds */ -} mad_timer_t; - -extern mad_timer_t const mad_timer_zero; - -# define MAD_TIMER_RESOLUTION 352800000UL - -enum mad_units { - MAD_UNITS_HOURS = -2, - MAD_UNITS_MINUTES = -1, - MAD_UNITS_SECONDS = 0, - - /* metric units */ - - MAD_UNITS_DECISECONDS = 10, - MAD_UNITS_CENTISECONDS = 100, - MAD_UNITS_MILLISECONDS = 1000, - - /* audio sample units */ - - MAD_UNITS_8000_HZ = 8000, - MAD_UNITS_11025_HZ = 11025, - MAD_UNITS_12000_HZ = 12000, - - MAD_UNITS_16000_HZ = 16000, - MAD_UNITS_22050_HZ = 22050, - MAD_UNITS_24000_HZ = 24000, - - MAD_UNITS_32000_HZ = 32000, - MAD_UNITS_44100_HZ = 44100, - MAD_UNITS_48000_HZ = 48000, - - /* video frame/field units */ - - MAD_UNITS_24_FPS = 24, - MAD_UNITS_25_FPS = 25, - MAD_UNITS_30_FPS = 30, - MAD_UNITS_48_FPS = 48, - MAD_UNITS_50_FPS = 50, - MAD_UNITS_60_FPS = 60, - - /* CD audio frames */ - - MAD_UNITS_75_FPS = 75, - - /* video drop-frame units */ - - MAD_UNITS_23_976_FPS = -24, - MAD_UNITS_24_975_FPS = -25, - MAD_UNITS_29_97_FPS = -30, - MAD_UNITS_47_952_FPS = -48, - MAD_UNITS_49_95_FPS = -50, - MAD_UNITS_59_94_FPS = -60 -}; - -# define mad_timer_reset(timer) ((void) (*(timer) = mad_timer_zero)) - -int mad_timer_compare(mad_timer_t, mad_timer_t); - -# define mad_timer_sign(timer) mad_timer_compare((timer), mad_timer_zero) - -void mad_timer_negate(mad_timer_t *); -mad_timer_t mad_timer_abs(mad_timer_t); - -void mad_timer_set(mad_timer_t *, unsigned long, unsigned long, unsigned long); -void mad_timer_add(mad_timer_t *, mad_timer_t); -void mad_timer_multiply(mad_timer_t *, signed long); - -signed long mad_timer_count(mad_timer_t, enum mad_units); -unsigned long mad_timer_fraction(mad_timer_t, unsigned long); -void mad_timer_string(mad_timer_t, char *, char const *, - enum mad_units, enum mad_units, unsigned long); - -# endif - -/* Id: stream.h,v 1.18 2003/05/27 22:40:37 rob Exp */ - -# ifndef LIBMAD_STREAM_H -# define LIBMAD_STREAM_H - - -# define MAD_BUFFER_GUARD 8 -# define MAD_BUFFER_MDLEN (511 + 2048 + MAD_BUFFER_GUARD) - -enum mad_error { - MAD_ERROR_NONE = 0x0000, /* no error */ - - MAD_ERROR_BUFLEN = 0x0001, /* input buffer too small (or EOF) */ - MAD_ERROR_BUFPTR = 0x0002, /* invalid (null) buffer pointer */ - - MAD_ERROR_NOMEM = 0x0031, /* not enough memory */ - - MAD_ERROR_LOSTSYNC = 0x0101, /* lost synchronization */ - MAD_ERROR_BADLAYER = 0x0102, /* reserved header layer value */ - MAD_ERROR_BADBITRATE = 0x0103, /* forbidden bitrate value */ - MAD_ERROR_BADSAMPLERATE = 0x0104, /* reserved sample frequency value */ - MAD_ERROR_BADEMPHASIS = 0x0105, /* reserved emphasis value */ - - MAD_ERROR_BADCRC = 0x0201, /* CRC check failed */ - MAD_ERROR_BADBITALLOC = 0x0211, /* forbidden bit allocation value */ - MAD_ERROR_BADSCALEFACTOR = 0x0221, /* bad scalefactor index */ - MAD_ERROR_BADFRAMELEN = 0x0231, /* bad frame length */ - MAD_ERROR_BADBIGVALUES = 0x0232, /* bad big_values count */ - MAD_ERROR_BADBLOCKTYPE = 0x0233, /* reserved block_type */ - MAD_ERROR_BADSCFSI = 0x0234, /* bad scalefactor selection info */ - MAD_ERROR_BADDATAPTR = 0x0235, /* bad main_data_begin pointer */ - MAD_ERROR_BADPART3LEN = 0x0236, /* bad audio data length */ - MAD_ERROR_BADHUFFTABLE = 0x0237, /* bad Huffman table select */ - MAD_ERROR_BADHUFFDATA = 0x0238, /* Huffman data overrun */ - MAD_ERROR_BADSTEREO = 0x0239 /* incompatible block_type for JS */ -}; - -# define MAD_RECOVERABLE(error) ((error) & 0xff00) - -struct mad_stream { - unsigned char const *buffer; /* input bitstream buffer */ - unsigned char const *bufend; /* end of buffer */ - unsigned long skiplen; /* bytes to skip before next frame */ - - int sync; /* stream sync found */ - unsigned long freerate; /* free bitrate (fixed) */ - - unsigned char const *this_frame; /* start of current frame */ - unsigned char const *next_frame; /* start of next frame */ - struct mad_bitptr ptr; /* current processing bit pointer */ - - struct mad_bitptr anc_ptr; /* ancillary bits pointer */ - unsigned int anc_bitlen; /* number of ancillary bits */ - - unsigned char (*main_data)[MAD_BUFFER_MDLEN]; - /* Layer III main_data() */ - unsigned int md_len; /* bytes in main_data */ - - int options; /* decoding options (see below) */ - enum mad_error error; /* error code (see above) */ -}; - -enum { - MAD_OPTION_IGNORECRC = 0x0001, /* ignore CRC errors */ - MAD_OPTION_HALFSAMPLERATE = 0x0002 /* generate PCM at 1/2 sample rate */ -# if 0 /* not yet implemented */ - MAD_OPTION_LEFTCHANNEL = 0x0010, /* decode left channel only */ - MAD_OPTION_RIGHTCHANNEL = 0x0020, /* decode right channel only */ - MAD_OPTION_SINGLECHANNEL = 0x0030 /* combine channels */ -# endif -}; - -void mad_stream_init(struct mad_stream *); -void mad_stream_finish(struct mad_stream *); - -# define mad_stream_options(stream, opts) \ - ((void) ((stream)->options = (opts))) - -void mad_stream_buffer(struct mad_stream *, - unsigned char const *, unsigned long); -void mad_stream_skip(struct mad_stream *, unsigned long); - -int mad_stream_sync(struct mad_stream *); - -char const *mad_stream_errorstr(struct mad_stream const *); - -# endif - -/* Id: frame.h,v 1.19 2003/05/27 22:40:36 rob Exp */ - -# ifndef LIBMAD_FRAME_H -# define LIBMAD_FRAME_H - - -enum mad_layer { - MAD_LAYER_I = 1, /* Layer I */ - MAD_LAYER_II = 2, /* Layer II */ - MAD_LAYER_III = 3 /* Layer III */ -}; - -enum mad_mode { - MAD_MODE_SINGLE_CHANNEL = 0, /* single channel */ - MAD_MODE_DUAL_CHANNEL = 1, /* dual channel */ - MAD_MODE_JOINT_STEREO = 2, /* joint (MS/intensity) stereo */ - MAD_MODE_STEREO = 3 /* normal LR stereo */ -}; - -enum mad_emphasis { - MAD_EMPHASIS_NONE = 0, /* no emphasis */ - MAD_EMPHASIS_50_15_US = 1, /* 50/15 microseconds emphasis */ - MAD_EMPHASIS_CCITT_J_17 = 3, /* CCITT J.17 emphasis */ - MAD_EMPHASIS_RESERVED = 2 /* unknown emphasis */ -}; - -struct mad_header { - enum mad_layer layer; /* audio layer (1, 2, or 3) */ - enum mad_mode mode; /* channel mode (see above) */ - int mode_extension; /* additional mode info */ - enum mad_emphasis emphasis; /* de-emphasis to use (see above) */ - - unsigned long bitrate; /* stream bitrate (bps) */ - unsigned int samplerate; /* sampling frequency (Hz) */ - - unsigned short crc_check; /* frame CRC accumulator */ - unsigned short crc_target; /* final target CRC checksum */ - - int flags; /* flags (see below) */ - int private_bits; /* private bits (see below) */ - - mad_timer_t duration; /* audio playing time of frame */ -}; - -struct mad_frame { - struct mad_header header; /* MPEG audio header */ - - int options; /* decoding options (from stream) */ - - mad_fixed_t sbsample[2][36][32]; /* synthesis subband filter samples */ - mad_fixed_t (*overlap)[2][32][18]; /* Layer III block overlap data */ -}; - -# define MAD_NCHANNELS(header) ((header)->mode ? 2 : 1) -# define MAD_NSBSAMPLES(header) \ - ((header)->layer == MAD_LAYER_I ? 12 : \ - (((header)->layer == MAD_LAYER_III && \ - ((header)->flags & MAD_FLAG_LSF_EXT)) ? 18 : 36)) - -enum { - MAD_FLAG_NPRIVATE_III = 0x0007, /* number of Layer III private bits */ - MAD_FLAG_INCOMPLETE = 0x0008, /* header but not data is decoded */ - - MAD_FLAG_PROTECTION = 0x0010, /* frame has CRC protection */ - MAD_FLAG_COPYRIGHT = 0x0020, /* frame is copyright */ - MAD_FLAG_ORIGINAL = 0x0040, /* frame is original (else copy) */ - MAD_FLAG_PADDING = 0x0080, /* frame has additional slot */ - - MAD_FLAG_I_STEREO = 0x0100, /* uses intensity joint stereo */ - MAD_FLAG_MS_STEREO = 0x0200, /* uses middle/side joint stereo */ - MAD_FLAG_FREEFORMAT = 0x0400, /* uses free format bitrate */ - - MAD_FLAG_LSF_EXT = 0x1000, /* lower sampling freq. extension */ - MAD_FLAG_MC_EXT = 0x2000, /* multichannel audio extension */ - MAD_FLAG_MPEG_2_5_EXT = 0x4000 /* MPEG 2.5 (unofficial) extension */ -}; - -enum { - MAD_PRIVATE_HEADER = 0x0100, /* header private bit */ - MAD_PRIVATE_III = 0x001f /* Layer III private bits (up to 5) */ -}; - -void mad_header_init(struct mad_header *); - -# define mad_header_finish(header) /* nothing */ - -int mad_header_decode(struct mad_header *, struct mad_stream *); - -void mad_frame_init(struct mad_frame *); -void mad_frame_finish(struct mad_frame *); - -int mad_frame_decode(struct mad_frame *, struct mad_stream *); - -void mad_frame_mute(struct mad_frame *); - -# endif - -/* Id: synth.h,v 1.14 2003/05/27 22:40:37 rob Exp */ - -# ifndef LIBMAD_SYNTH_H -# define LIBMAD_SYNTH_H - - -struct mad_pcm { - unsigned int samplerate; /* sampling frequency (Hz) */ - unsigned short channels; /* number of channels */ - unsigned short length; /* number of samples per channel */ - mad_fixed_t samples[2][1152]; /* PCM output samples [ch][sample] */ -}; - -struct mad_synth { - mad_fixed_t filter[2][2][2][16][8]; /* polyphase filterbank outputs */ - /* [ch][eo][peo][s][v] */ - - unsigned int phase; /* current processing phase */ - - struct mad_pcm pcm; /* PCM output */ -}; - -/* single channel PCM selector */ -enum { - MAD_PCM_CHANNEL_SINGLE = 0 -}; - -/* dual channel PCM selector */ -enum { - MAD_PCM_CHANNEL_DUAL_1 = 0, - MAD_PCM_CHANNEL_DUAL_2 = 1 -}; - -/* stereo PCM selector */ -enum { - MAD_PCM_CHANNEL_STEREO_LEFT = 0, - MAD_PCM_CHANNEL_STEREO_RIGHT = 1 -}; - -void mad_synth_init(struct mad_synth *); - -# define mad_synth_finish(synth) /* nothing */ - -void mad_synth_mute(struct mad_synth *); - -void mad_synth_frame(struct mad_synth *, struct mad_frame const *); - -# endif - -/* Id: decoder.h,v 1.16 2003/05/27 22:40:36 rob Exp */ - -# ifndef LIBMAD_DECODER_H -# define LIBMAD_DECODER_H - - -enum mad_decoder_mode { - MAD_DECODER_MODE_SYNC = 0, - MAD_DECODER_MODE_ASYNC -}; - -enum mad_flow { - MAD_FLOW_CONTINUE = 0x0000, /* continue normally */ - MAD_FLOW_STOP = 0x0010, /* stop decoding normally */ - MAD_FLOW_BREAK = 0x0011, /* stop decoding and signal an error */ - MAD_FLOW_IGNORE = 0x0020 /* ignore the current frame */ -}; - -struct mad_decoder { - enum mad_decoder_mode mode; - - int options; - - struct { - long pid; - int in; - int out; - } async; - - struct { - struct mad_stream stream; - struct mad_frame frame; - struct mad_synth synth; - } *sync; - - void *cb_data; - - enum mad_flow (*input_func)(void *, struct mad_stream *); - enum mad_flow (*header_func)(void *, struct mad_header const *); - enum mad_flow (*filter_func)(void *, - struct mad_stream const *, struct mad_frame *); - enum mad_flow (*output_func)(void *, - struct mad_header const *, struct mad_pcm *); - enum mad_flow (*error_func)(void *, struct mad_stream *, struct mad_frame *); - enum mad_flow (*message_func)(void *, void *, unsigned int *); -}; - -void mad_decoder_init(struct mad_decoder *, void *, - enum mad_flow (*)(void *, struct mad_stream *), - enum mad_flow (*)(void *, struct mad_header const *), - enum mad_flow (*)(void *, - struct mad_stream const *, - struct mad_frame *), - enum mad_flow (*)(void *, - struct mad_header const *, - struct mad_pcm *), - enum mad_flow (*)(void *, - struct mad_stream *, - struct mad_frame *), - enum mad_flow (*)(void *, void *, unsigned int *)); -int mad_decoder_finish(struct mad_decoder *); - -# define mad_decoder_options(decoder, opts) \ - ((void) ((decoder)->options = (opts))) - -int mad_decoder_run(struct mad_decoder *, enum mad_decoder_mode); -int mad_decoder_message(struct mad_decoder *, void *, unsigned int *); - -# endif - -# ifdef __cplusplus -} -# endif diff --git a/lib-src/libmad/osx-universal-build.patch b/lib-src/libmad/osx-universal-build.patch deleted file mode 100644 index 15a2e90c2..000000000 --- a/lib-src/libmad/osx-universal-build.patch +++ /dev/null @@ -1,25 +0,0 @@ -Index: fixed.h -=================================================================== -RCS file: /cvsroot/audacity/lib-src/libmad/fixed.h,v -retrieving revision 1.2 -diff -u -r1.2 fixed.h ---- fixed.h 12 Sep 2005 07:01:30 -0000 1.2 -+++ fixed.h 2 Feb 2008 11:35:08 -0000 -@@ -137,7 +137,7 @@ - - /* --- Intel --------------------------------------------------------------- */ - --# elif defined(FPM_INTEL) -+# elif defined(FPM_INTEL) || defined (__i386__) - - # if defined(_MSC_VER) - # pragma warning(push) -@@ -351,7 +351,7 @@ - - /* --- PowerPC ------------------------------------------------------------- */ - --# elif defined(FPM_PPC) -+# elif defined(FPM_PPC) || defined(__ppc__) - - /* - * This PowerPC version is fast and accurate; the disposition of the least diff --git a/lib-src/libmad/qc_table.dat b/lib-src/libmad/qc_table.dat deleted file mode 100644 index 78fa5da92..000000000 --- a/lib-src/libmad/qc_table.dat +++ /dev/null @@ -1,77 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: qc_table.dat,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -/* - * These are the Layer II classes of quantization. - * The table is derived from Table B.4 of ISO/IEC 11172-3. - */ - - { 3, 2, 5, - MAD_F(0x15555555) /* 1.33333333333 => 1.33333333209, e 0.00000000124 */, - MAD_F(0x08000000) /* 0.50000000000 => 0.50000000000, e 0.00000000000 */ }, - { 5, 3, 7, - MAD_F(0x1999999a) /* 1.60000000000 => 1.60000000149, e -0.00000000149 */, - MAD_F(0x08000000) /* 0.50000000000 => 0.50000000000, e 0.00000000000 */ }, - { 7, 0, 3, - MAD_F(0x12492492) /* 1.14285714286 => 1.14285714179, e 0.00000000107 */, - MAD_F(0x04000000) /* 0.25000000000 => 0.25000000000, e 0.00000000000 */ }, - { 9, 4, 10, - MAD_F(0x1c71c71c) /* 1.77777777777 => 1.77777777612, e 0.00000000165 */, - MAD_F(0x08000000) /* 0.50000000000 => 0.50000000000, e 0.00000000000 */ }, - { 15, 0, 4, - MAD_F(0x11111111) /* 1.06666666666 => 1.06666666642, e 0.00000000024 */, - MAD_F(0x02000000) /* 0.12500000000 => 0.12500000000, e 0.00000000000 */ }, - { 31, 0, 5, - MAD_F(0x10842108) /* 1.03225806452 => 1.03225806355, e 0.00000000097 */, - MAD_F(0x01000000) /* 0.06250000000 => 0.06250000000, e 0.00000000000 */ }, - { 63, 0, 6, - MAD_F(0x10410410) /* 1.01587301587 => 1.01587301493, e 0.00000000094 */, - MAD_F(0x00800000) /* 0.03125000000 => 0.03125000000, e 0.00000000000 */ }, - { 127, 0, 7, - MAD_F(0x10204081) /* 1.00787401575 => 1.00787401572, e 0.00000000003 */, - MAD_F(0x00400000) /* 0.01562500000 => 0.01562500000, e 0.00000000000 */ }, - { 255, 0, 8, - MAD_F(0x10101010) /* 1.00392156863 => 1.00392156839, e 0.00000000024 */, - MAD_F(0x00200000) /* 0.00781250000 => 0.00781250000, e 0.00000000000 */ }, - { 511, 0, 9, - MAD_F(0x10080402) /* 1.00195694716 => 1.00195694715, e 0.00000000001 */, - MAD_F(0x00100000) /* 0.00390625000 => 0.00390625000, e 0.00000000000 */ }, - { 1023, 0, 10, - MAD_F(0x10040100) /* 1.00097751711 => 1.00097751617, e 0.00000000094 */, - MAD_F(0x00080000) /* 0.00195312500 => 0.00195312500, e 0.00000000000 */ }, - { 2047, 0, 11, - MAD_F(0x10020040) /* 1.00048851979 => 1.00048851967, e 0.00000000012 */, - MAD_F(0x00040000) /* 0.00097656250 => 0.00097656250, e 0.00000000000 */ }, - { 4095, 0, 12, - MAD_F(0x10010010) /* 1.00024420024 => 1.00024420023, e 0.00000000001 */, - MAD_F(0x00020000) /* 0.00048828125 => 0.00048828125, e 0.00000000000 */ }, - { 8191, 0, 13, - MAD_F(0x10008004) /* 1.00012208522 => 1.00012208521, e 0.00000000001 */, - MAD_F(0x00010000) /* 0.00024414063 => 0.00024414062, e 0.00000000000 */ }, - { 16383, 0, 14, - MAD_F(0x10004001) /* 1.00006103888 => 1.00006103888, e -0.00000000000 */, - MAD_F(0x00008000) /* 0.00012207031 => 0.00012207031, e -0.00000000000 */ }, - { 32767, 0, 15, - MAD_F(0x10002000) /* 1.00003051851 => 1.00003051758, e 0.00000000093 */, - MAD_F(0x00004000) /* 0.00006103516 => 0.00006103516, e 0.00000000000 */ }, - { 65535, 0, 16, - MAD_F(0x10001000) /* 1.00001525902 => 1.00001525879, e 0.00000000023 */, - MAD_F(0x00002000) /* 0.00003051758 => 0.00003051758, e 0.00000000000 */ } diff --git a/lib-src/libmad/rq_table.dat b/lib-src/libmad/rq_table.dat deleted file mode 100644 index 9f124c721..000000000 --- a/lib-src/libmad/rq_table.dat +++ /dev/null @@ -1,8747 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: rq_table.dat,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -/* - * This is the lookup table used to compute x^(4/3) for Layer III - * requantization. To maintain the best possible accuracy, the value is - * stored as a normalized mantissa with exponent. The requantization - * algorithm recombines these parts with appropriate scaling. - */ - - /* 0 */ { MAD_F(0x00000000) /* 0.000000000 */, 0 }, - /* 1 */ { MAD_F(0x04000000) /* 0.250000000 */, 2 }, - /* 2 */ { MAD_F(0x050a28be) /* 0.314980262 */, 3 }, - /* 3 */ { MAD_F(0x0453a5cd) /* 0.270421794 */, 4 }, - /* 4 */ { MAD_F(0x06597fa9) /* 0.396850263 */, 4 }, - /* 5 */ { MAD_F(0x04466275) /* 0.267183742 */, 5 }, - /* 6 */ { MAD_F(0x05738c72) /* 0.340710111 */, 5 }, - /* 7 */ { MAD_F(0x06b1fc81) /* 0.418453696 */, 5 }, - /* 8 */ { MAD_F(0x04000000) /* 0.250000000 */, 6 }, - /* 9 */ { MAD_F(0x04ae20d7) /* 0.292511788 */, 6 }, - /* 10 */ { MAD_F(0x0562d694) /* 0.336630420 */, 6 }, - /* 11 */ { MAD_F(0x061dae96) /* 0.382246578 */, 6 }, - /* 12 */ { MAD_F(0x06de47f4) /* 0.429267841 */, 6 }, - /* 13 */ { MAD_F(0x07a44f7a) /* 0.477614858 */, 6 }, - /* 14 */ { MAD_F(0x0437be65) /* 0.263609310 */, 7 }, - /* 15 */ { MAD_F(0x049fc824) /* 0.289009227 */, 7 }, - - /* 16 */ { MAD_F(0x050a28be) /* 0.314980262 */, 7 }, - /* 17 */ { MAD_F(0x0576c6f5) /* 0.341498336 */, 7 }, - /* 18 */ { MAD_F(0x05e58c0b) /* 0.368541759 */, 7 }, - /* 19 */ { MAD_F(0x06566361) /* 0.396090870 */, 7 }, - /* 20 */ { MAD_F(0x06c93a2e) /* 0.424127753 */, 7 }, - /* 21 */ { MAD_F(0x073dff3e) /* 0.452635998 */, 7 }, - /* 22 */ { MAD_F(0x07b4a2bc) /* 0.481600510 */, 7 }, - /* 23 */ { MAD_F(0x04168b05) /* 0.255503674 */, 8 }, - /* 24 */ { MAD_F(0x0453a5cd) /* 0.270421794 */, 8 }, - /* 25 */ { MAD_F(0x04919b6a) /* 0.285548607 */, 8 }, - /* 26 */ { MAD_F(0x04d065fb) /* 0.300878507 */, 8 }, - /* 27 */ { MAD_F(0x05100000) /* 0.316406250 */, 8 }, - /* 28 */ { MAD_F(0x05506451) /* 0.332126919 */, 8 }, - /* 29 */ { MAD_F(0x05918e15) /* 0.348035890 */, 8 }, - /* 30 */ { MAD_F(0x05d378bb) /* 0.364128809 */, 8 }, - /* 31 */ { MAD_F(0x06161ff3) /* 0.380401563 */, 8 }, - - /* 32 */ { MAD_F(0x06597fa9) /* 0.396850263 */, 8 }, - /* 33 */ { MAD_F(0x069d9400) /* 0.413471222 */, 8 }, - /* 34 */ { MAD_F(0x06e2594c) /* 0.430260942 */, 8 }, - /* 35 */ { MAD_F(0x0727cc11) /* 0.447216097 */, 8 }, - /* 36 */ { MAD_F(0x076de8fc) /* 0.464333519 */, 8 }, - /* 37 */ { MAD_F(0x07b4ace3) /* 0.481610189 */, 8 }, - /* 38 */ { MAD_F(0x07fc14bf) /* 0.499043224 */, 8 }, - /* 39 */ { MAD_F(0x04220ed7) /* 0.258314934 */, 9 }, - /* 40 */ { MAD_F(0x04466275) /* 0.267183742 */, 9 }, - /* 41 */ { MAD_F(0x046b03e7) /* 0.276126771 */, 9 }, - /* 42 */ { MAD_F(0x048ff1e8) /* 0.285142811 */, 9 }, - /* 43 */ { MAD_F(0x04b52b3f) /* 0.294230696 */, 9 }, - /* 44 */ { MAD_F(0x04daaec0) /* 0.303389310 */, 9 }, - /* 45 */ { MAD_F(0x05007b49) /* 0.312617576 */, 9 }, - /* 46 */ { MAD_F(0x05268fc6) /* 0.321914457 */, 9 }, - /* 47 */ { MAD_F(0x054ceb2a) /* 0.331278957 */, 9 }, - - /* 48 */ { MAD_F(0x05738c72) /* 0.340710111 */, 9 }, - /* 49 */ { MAD_F(0x059a72a5) /* 0.350206992 */, 9 }, - /* 50 */ { MAD_F(0x05c19cd3) /* 0.359768701 */, 9 }, - /* 51 */ { MAD_F(0x05e90a12) /* 0.369394372 */, 9 }, - /* 52 */ { MAD_F(0x0610b982) /* 0.379083164 */, 9 }, - /* 53 */ { MAD_F(0x0638aa48) /* 0.388834268 */, 9 }, - /* 54 */ { MAD_F(0x0660db91) /* 0.398646895 */, 9 }, - /* 55 */ { MAD_F(0x06894c90) /* 0.408520284 */, 9 }, - /* 56 */ { MAD_F(0x06b1fc81) /* 0.418453696 */, 9 }, - /* 57 */ { MAD_F(0x06daeaa1) /* 0.428446415 */, 9 }, - /* 58 */ { MAD_F(0x07041636) /* 0.438497744 */, 9 }, - /* 59 */ { MAD_F(0x072d7e8b) /* 0.448607009 */, 9 }, - /* 60 */ { MAD_F(0x075722ef) /* 0.458773552 */, 9 }, - /* 61 */ { MAD_F(0x078102b8) /* 0.468996735 */, 9 }, - /* 62 */ { MAD_F(0x07ab1d3e) /* 0.479275937 */, 9 }, - /* 63 */ { MAD_F(0x07d571e0) /* 0.489610555 */, 9 }, - - /* 64 */ { MAD_F(0x04000000) /* 0.250000000 */, 10 }, - /* 65 */ { MAD_F(0x04156381) /* 0.255221850 */, 10 }, - /* 66 */ { MAD_F(0x042ae32a) /* 0.260470548 */, 10 }, - /* 67 */ { MAD_F(0x04407eb1) /* 0.265745823 */, 10 }, - /* 68 */ { MAD_F(0x045635cf) /* 0.271047409 */, 10 }, - /* 69 */ { MAD_F(0x046c083e) /* 0.276375048 */, 10 }, - /* 70 */ { MAD_F(0x0481f5bb) /* 0.281728487 */, 10 }, - /* 71 */ { MAD_F(0x0497fe03) /* 0.287107481 */, 10 }, - /* 72 */ { MAD_F(0x04ae20d7) /* 0.292511788 */, 10 }, - /* 73 */ { MAD_F(0x04c45df6) /* 0.297941173 */, 10 }, - /* 74 */ { MAD_F(0x04dab524) /* 0.303395408 */, 10 }, - /* 75 */ { MAD_F(0x04f12624) /* 0.308874267 */, 10 }, - /* 76 */ { MAD_F(0x0507b0bc) /* 0.314377532 */, 10 }, - /* 77 */ { MAD_F(0x051e54b1) /* 0.319904987 */, 10 }, - /* 78 */ { MAD_F(0x053511cb) /* 0.325456423 */, 10 }, - /* 79 */ { MAD_F(0x054be7d4) /* 0.331031635 */, 10 }, - - /* 80 */ { MAD_F(0x0562d694) /* 0.336630420 */, 10 }, - /* 81 */ { MAD_F(0x0579ddd8) /* 0.342252584 */, 10 }, - /* 82 */ { MAD_F(0x0590fd6c) /* 0.347897931 */, 10 }, - /* 83 */ { MAD_F(0x05a8351c) /* 0.353566275 */, 10 }, - /* 84 */ { MAD_F(0x05bf84b8) /* 0.359257429 */, 10 }, - /* 85 */ { MAD_F(0x05d6ec0e) /* 0.364971213 */, 10 }, - /* 86 */ { MAD_F(0x05ee6aef) /* 0.370707448 */, 10 }, - /* 87 */ { MAD_F(0x0606012b) /* 0.376465960 */, 10 }, - /* 88 */ { MAD_F(0x061dae96) /* 0.382246578 */, 10 }, - /* 89 */ { MAD_F(0x06357302) /* 0.388049134 */, 10 }, - /* 90 */ { MAD_F(0x064d4e43) /* 0.393873464 */, 10 }, - /* 91 */ { MAD_F(0x0665402d) /* 0.399719406 */, 10 }, - /* 92 */ { MAD_F(0x067d4896) /* 0.405586801 */, 10 }, - /* 93 */ { MAD_F(0x06956753) /* 0.411475493 */, 10 }, - /* 94 */ { MAD_F(0x06ad9c3d) /* 0.417385331 */, 10 }, - /* 95 */ { MAD_F(0x06c5e72b) /* 0.423316162 */, 10 }, - - /* 96 */ { MAD_F(0x06de47f4) /* 0.429267841 */, 10 }, - /* 97 */ { MAD_F(0x06f6be73) /* 0.435240221 */, 10 }, - /* 98 */ { MAD_F(0x070f4a80) /* 0.441233161 */, 10 }, - /* 99 */ { MAD_F(0x0727ebf7) /* 0.447246519 */, 10 }, - /* 100 */ { MAD_F(0x0740a2b2) /* 0.453280160 */, 10 }, - /* 101 */ { MAD_F(0x07596e8d) /* 0.459333946 */, 10 }, - /* 102 */ { MAD_F(0x07724f64) /* 0.465407744 */, 10 }, - /* 103 */ { MAD_F(0x078b4514) /* 0.471501425 */, 10 }, - /* 104 */ { MAD_F(0x07a44f7a) /* 0.477614858 */, 10 }, - /* 105 */ { MAD_F(0x07bd6e75) /* 0.483747918 */, 10 }, - /* 106 */ { MAD_F(0x07d6a1e2) /* 0.489900479 */, 10 }, - /* 107 */ { MAD_F(0x07efe9a1) /* 0.496072418 */, 10 }, - /* 108 */ { MAD_F(0x0404a2c9) /* 0.251131807 */, 11 }, - /* 109 */ { MAD_F(0x04115aca) /* 0.254236974 */, 11 }, - /* 110 */ { MAD_F(0x041e1cc4) /* 0.257351652 */, 11 }, - /* 111 */ { MAD_F(0x042ae8a7) /* 0.260475783 */, 11 }, - - /* 112 */ { MAD_F(0x0437be65) /* 0.263609310 */, 11 }, - /* 113 */ { MAD_F(0x04449dee) /* 0.266752177 */, 11 }, - /* 114 */ { MAD_F(0x04518733) /* 0.269904329 */, 11 }, - /* 115 */ { MAD_F(0x045e7a26) /* 0.273065710 */, 11 }, - /* 116 */ { MAD_F(0x046b76b9) /* 0.276236269 */, 11 }, - /* 117 */ { MAD_F(0x04787cdc) /* 0.279415952 */, 11 }, - /* 118 */ { MAD_F(0x04858c83) /* 0.282604707 */, 11 }, - /* 119 */ { MAD_F(0x0492a59f) /* 0.285802482 */, 11 }, - /* 120 */ { MAD_F(0x049fc824) /* 0.289009227 */, 11 }, - /* 121 */ { MAD_F(0x04acf402) /* 0.292224893 */, 11 }, - /* 122 */ { MAD_F(0x04ba292e) /* 0.295449429 */, 11 }, - /* 123 */ { MAD_F(0x04c7679a) /* 0.298682788 */, 11 }, - /* 124 */ { MAD_F(0x04d4af3a) /* 0.301924921 */, 11 }, - /* 125 */ { MAD_F(0x04e20000) /* 0.305175781 */, 11 }, - /* 126 */ { MAD_F(0x04ef59e0) /* 0.308435322 */, 11 }, - /* 127 */ { MAD_F(0x04fcbcce) /* 0.311703498 */, 11 }, - - /* 128 */ { MAD_F(0x050a28be) /* 0.314980262 */, 11 }, - /* 129 */ { MAD_F(0x05179da4) /* 0.318265572 */, 11 }, - /* 130 */ { MAD_F(0x05251b73) /* 0.321559381 */, 11 }, - /* 131 */ { MAD_F(0x0532a220) /* 0.324861647 */, 11 }, - /* 132 */ { MAD_F(0x054031a0) /* 0.328172327 */, 11 }, - /* 133 */ { MAD_F(0x054dc9e7) /* 0.331491377 */, 11 }, - /* 134 */ { MAD_F(0x055b6ae9) /* 0.334818756 */, 11 }, - /* 135 */ { MAD_F(0x0569149c) /* 0.338154423 */, 11 }, - /* 136 */ { MAD_F(0x0576c6f5) /* 0.341498336 */, 11 }, - /* 137 */ { MAD_F(0x058481e9) /* 0.344850455 */, 11 }, - /* 138 */ { MAD_F(0x0592456d) /* 0.348210741 */, 11 }, - /* 139 */ { MAD_F(0x05a01176) /* 0.351579152 */, 11 }, - /* 140 */ { MAD_F(0x05ade5fa) /* 0.354955651 */, 11 }, - /* 141 */ { MAD_F(0x05bbc2ef) /* 0.358340200 */, 11 }, - /* 142 */ { MAD_F(0x05c9a84a) /* 0.361732758 */, 11 }, - /* 143 */ { MAD_F(0x05d79601) /* 0.365133291 */, 11 }, - - /* 144 */ { MAD_F(0x05e58c0b) /* 0.368541759 */, 11 }, - /* 145 */ { MAD_F(0x05f38a5d) /* 0.371958126 */, 11 }, - /* 146 */ { MAD_F(0x060190ee) /* 0.375382356 */, 11 }, - /* 147 */ { MAD_F(0x060f9fb3) /* 0.378814413 */, 11 }, - /* 148 */ { MAD_F(0x061db6a5) /* 0.382254261 */, 11 }, - /* 149 */ { MAD_F(0x062bd5b8) /* 0.385701865 */, 11 }, - /* 150 */ { MAD_F(0x0639fce4) /* 0.389157191 */, 11 }, - /* 151 */ { MAD_F(0x06482c1f) /* 0.392620204 */, 11 }, - /* 152 */ { MAD_F(0x06566361) /* 0.396090870 */, 11 }, - /* 153 */ { MAD_F(0x0664a2a0) /* 0.399569155 */, 11 }, - /* 154 */ { MAD_F(0x0672e9d4) /* 0.403055027 */, 11 }, - /* 155 */ { MAD_F(0x068138f3) /* 0.406548452 */, 11 }, - /* 156 */ { MAD_F(0x068f8ff5) /* 0.410049398 */, 11 }, - /* 157 */ { MAD_F(0x069deed1) /* 0.413557833 */, 11 }, - /* 158 */ { MAD_F(0x06ac557f) /* 0.417073724 */, 11 }, - /* 159 */ { MAD_F(0x06bac3f6) /* 0.420597041 */, 11 }, - - /* 160 */ { MAD_F(0x06c93a2e) /* 0.424127753 */, 11 }, - /* 161 */ { MAD_F(0x06d7b81f) /* 0.427665827 */, 11 }, - /* 162 */ { MAD_F(0x06e63dc0) /* 0.431211234 */, 11 }, - /* 163 */ { MAD_F(0x06f4cb09) /* 0.434763944 */, 11 }, - /* 164 */ { MAD_F(0x07035ff3) /* 0.438323927 */, 11 }, - /* 165 */ { MAD_F(0x0711fc75) /* 0.441891153 */, 11 }, - /* 166 */ { MAD_F(0x0720a087) /* 0.445465593 */, 11 }, - /* 167 */ { MAD_F(0x072f4c22) /* 0.449047217 */, 11 }, - /* 168 */ { MAD_F(0x073dff3e) /* 0.452635998 */, 11 }, - /* 169 */ { MAD_F(0x074cb9d3) /* 0.456231906 */, 11 }, - /* 170 */ { MAD_F(0x075b7bdb) /* 0.459834914 */, 11 }, - /* 171 */ { MAD_F(0x076a454c) /* 0.463444993 */, 11 }, - /* 172 */ { MAD_F(0x07791620) /* 0.467062117 */, 11 }, - /* 173 */ { MAD_F(0x0787ee50) /* 0.470686258 */, 11 }, - /* 174 */ { MAD_F(0x0796cdd4) /* 0.474317388 */, 11 }, - /* 175 */ { MAD_F(0x07a5b4a5) /* 0.477955481 */, 11 }, - - /* 176 */ { MAD_F(0x07b4a2bc) /* 0.481600510 */, 11 }, - /* 177 */ { MAD_F(0x07c39812) /* 0.485252449 */, 11 }, - /* 178 */ { MAD_F(0x07d294a0) /* 0.488911273 */, 11 }, - /* 179 */ { MAD_F(0x07e1985f) /* 0.492576954 */, 11 }, - /* 180 */ { MAD_F(0x07f0a348) /* 0.496249468 */, 11 }, - /* 181 */ { MAD_F(0x07ffb554) /* 0.499928790 */, 11 }, - /* 182 */ { MAD_F(0x0407673f) /* 0.251807447 */, 12 }, - /* 183 */ { MAD_F(0x040ef75e) /* 0.253653877 */, 12 }, - /* 184 */ { MAD_F(0x04168b05) /* 0.255503674 */, 12 }, - /* 185 */ { MAD_F(0x041e2230) /* 0.257356825 */, 12 }, - /* 186 */ { MAD_F(0x0425bcdd) /* 0.259213318 */, 12 }, - /* 187 */ { MAD_F(0x042d5b07) /* 0.261073141 */, 12 }, - /* 188 */ { MAD_F(0x0434fcad) /* 0.262936282 */, 12 }, - /* 189 */ { MAD_F(0x043ca1c9) /* 0.264802730 */, 12 }, - /* 190 */ { MAD_F(0x04444a5a) /* 0.266672472 */, 12 }, - /* 191 */ { MAD_F(0x044bf65d) /* 0.268545497 */, 12 }, - - /* 192 */ { MAD_F(0x0453a5cd) /* 0.270421794 */, 12 }, - /* 193 */ { MAD_F(0x045b58a9) /* 0.272301352 */, 12 }, - /* 194 */ { MAD_F(0x04630eed) /* 0.274184158 */, 12 }, - /* 195 */ { MAD_F(0x046ac896) /* 0.276070203 */, 12 }, - /* 196 */ { MAD_F(0x047285a2) /* 0.277959474 */, 12 }, - /* 197 */ { MAD_F(0x047a460c) /* 0.279851960 */, 12 }, - /* 198 */ { MAD_F(0x048209d3) /* 0.281747652 */, 12 }, - /* 199 */ { MAD_F(0x0489d0f4) /* 0.283646538 */, 12 }, - /* 200 */ { MAD_F(0x04919b6a) /* 0.285548607 */, 12 }, - /* 201 */ { MAD_F(0x04996935) /* 0.287453849 */, 12 }, - /* 202 */ { MAD_F(0x04a13a50) /* 0.289362253 */, 12 }, - /* 203 */ { MAD_F(0x04a90eba) /* 0.291273810 */, 12 }, - /* 204 */ { MAD_F(0x04b0e66e) /* 0.293188507 */, 12 }, - /* 205 */ { MAD_F(0x04b8c16c) /* 0.295106336 */, 12 }, - /* 206 */ { MAD_F(0x04c09faf) /* 0.297027285 */, 12 }, - /* 207 */ { MAD_F(0x04c88135) /* 0.298951346 */, 12 }, - - /* 208 */ { MAD_F(0x04d065fb) /* 0.300878507 */, 12 }, - /* 209 */ { MAD_F(0x04d84dff) /* 0.302808759 */, 12 }, - /* 210 */ { MAD_F(0x04e0393e) /* 0.304742092 */, 12 }, - /* 211 */ { MAD_F(0x04e827b6) /* 0.306678497 */, 12 }, - /* 212 */ { MAD_F(0x04f01963) /* 0.308617963 */, 12 }, - /* 213 */ { MAD_F(0x04f80e44) /* 0.310560480 */, 12 }, - /* 214 */ { MAD_F(0x05000655) /* 0.312506041 */, 12 }, - /* 215 */ { MAD_F(0x05080195) /* 0.314454634 */, 12 }, - /* 216 */ { MAD_F(0x05100000) /* 0.316406250 */, 12 }, - /* 217 */ { MAD_F(0x05180194) /* 0.318360880 */, 12 }, - /* 218 */ { MAD_F(0x0520064f) /* 0.320318516 */, 12 }, - /* 219 */ { MAD_F(0x05280e2d) /* 0.322279147 */, 12 }, - /* 220 */ { MAD_F(0x0530192e) /* 0.324242764 */, 12 }, - /* 221 */ { MAD_F(0x0538274e) /* 0.326209359 */, 12 }, - /* 222 */ { MAD_F(0x0540388a) /* 0.328178922 */, 12 }, - /* 223 */ { MAD_F(0x05484ce2) /* 0.330151445 */, 12 }, - - /* 224 */ { MAD_F(0x05506451) /* 0.332126919 */, 12 }, - /* 225 */ { MAD_F(0x05587ed5) /* 0.334105334 */, 12 }, - /* 226 */ { MAD_F(0x05609c6e) /* 0.336086683 */, 12 }, - /* 227 */ { MAD_F(0x0568bd17) /* 0.338070956 */, 12 }, - /* 228 */ { MAD_F(0x0570e0cf) /* 0.340058145 */, 12 }, - /* 229 */ { MAD_F(0x05790793) /* 0.342048241 */, 12 }, - /* 230 */ { MAD_F(0x05813162) /* 0.344041237 */, 12 }, - /* 231 */ { MAD_F(0x05895e39) /* 0.346037122 */, 12 }, - /* 232 */ { MAD_F(0x05918e15) /* 0.348035890 */, 12 }, - /* 233 */ { MAD_F(0x0599c0f4) /* 0.350037532 */, 12 }, - /* 234 */ { MAD_F(0x05a1f6d5) /* 0.352042040 */, 12 }, - /* 235 */ { MAD_F(0x05aa2fb5) /* 0.354049405 */, 12 }, - /* 236 */ { MAD_F(0x05b26b92) /* 0.356059619 */, 12 }, - /* 237 */ { MAD_F(0x05baaa69) /* 0.358072674 */, 12 }, - /* 238 */ { MAD_F(0x05c2ec39) /* 0.360088563 */, 12 }, - /* 239 */ { MAD_F(0x05cb3100) /* 0.362107278 */, 12 }, - - /* 240 */ { MAD_F(0x05d378bb) /* 0.364128809 */, 12 }, - /* 241 */ { MAD_F(0x05dbc368) /* 0.366153151 */, 12 }, - /* 242 */ { MAD_F(0x05e41105) /* 0.368180294 */, 12 }, - /* 243 */ { MAD_F(0x05ec6190) /* 0.370210231 */, 12 }, - /* 244 */ { MAD_F(0x05f4b507) /* 0.372242955 */, 12 }, - /* 245 */ { MAD_F(0x05fd0b68) /* 0.374278458 */, 12 }, - /* 246 */ { MAD_F(0x060564b1) /* 0.376316732 */, 12 }, - /* 247 */ { MAD_F(0x060dc0e0) /* 0.378357769 */, 12 }, - /* 248 */ { MAD_F(0x06161ff3) /* 0.380401563 */, 12 }, - /* 249 */ { MAD_F(0x061e81e8) /* 0.382448106 */, 12 }, - /* 250 */ { MAD_F(0x0626e6bc) /* 0.384497391 */, 12 }, - /* 251 */ { MAD_F(0x062f4e6f) /* 0.386549409 */, 12 }, - /* 252 */ { MAD_F(0x0637b8fd) /* 0.388604155 */, 12 }, - /* 253 */ { MAD_F(0x06402666) /* 0.390661620 */, 12 }, - /* 254 */ { MAD_F(0x064896a7) /* 0.392721798 */, 12 }, - /* 255 */ { MAD_F(0x065109be) /* 0.394784681 */, 12 }, - - /* 256 */ { MAD_F(0x06597fa9) /* 0.396850263 */, 12 }, - /* 257 */ { MAD_F(0x0661f867) /* 0.398918536 */, 12 }, - /* 258 */ { MAD_F(0x066a73f5) /* 0.400989493 */, 12 }, - /* 259 */ { MAD_F(0x0672f252) /* 0.403063128 */, 12 }, - /* 260 */ { MAD_F(0x067b737c) /* 0.405139433 */, 12 }, - /* 261 */ { MAD_F(0x0683f771) /* 0.407218402 */, 12 }, - /* 262 */ { MAD_F(0x068c7e2f) /* 0.409300027 */, 12 }, - /* 263 */ { MAD_F(0x069507b5) /* 0.411384303 */, 12 }, - /* 264 */ { MAD_F(0x069d9400) /* 0.413471222 */, 12 }, - /* 265 */ { MAD_F(0x06a6230f) /* 0.415560778 */, 12 }, - /* 266 */ { MAD_F(0x06aeb4e0) /* 0.417652964 */, 12 }, - /* 267 */ { MAD_F(0x06b74971) /* 0.419747773 */, 12 }, - /* 268 */ { MAD_F(0x06bfe0c0) /* 0.421845199 */, 12 }, - /* 269 */ { MAD_F(0x06c87acc) /* 0.423945235 */, 12 }, - /* 270 */ { MAD_F(0x06d11794) /* 0.426047876 */, 12 }, - /* 271 */ { MAD_F(0x06d9b714) /* 0.428153114 */, 12 }, - - /* 272 */ { MAD_F(0x06e2594c) /* 0.430260942 */, 12 }, - /* 273 */ { MAD_F(0x06eafe3a) /* 0.432371356 */, 12 }, - /* 274 */ { MAD_F(0x06f3a5dc) /* 0.434484348 */, 12 }, - /* 275 */ { MAD_F(0x06fc5030) /* 0.436599912 */, 12 }, - /* 276 */ { MAD_F(0x0704fd35) /* 0.438718042 */, 12 }, - /* 277 */ { MAD_F(0x070dacea) /* 0.440838732 */, 12 }, - /* 278 */ { MAD_F(0x07165f4b) /* 0.442961975 */, 12 }, - /* 279 */ { MAD_F(0x071f1459) /* 0.445087765 */, 12 }, - /* 280 */ { MAD_F(0x0727cc11) /* 0.447216097 */, 12 }, - /* 281 */ { MAD_F(0x07308671) /* 0.449346964 */, 12 }, - /* 282 */ { MAD_F(0x07394378) /* 0.451480360 */, 12 }, - /* 283 */ { MAD_F(0x07420325) /* 0.453616280 */, 12 }, - /* 284 */ { MAD_F(0x074ac575) /* 0.455754717 */, 12 }, - /* 285 */ { MAD_F(0x07538a67) /* 0.457895665 */, 12 }, - /* 286 */ { MAD_F(0x075c51fa) /* 0.460039119 */, 12 }, - /* 287 */ { MAD_F(0x07651c2c) /* 0.462185072 */, 12 }, - - /* 288 */ { MAD_F(0x076de8fc) /* 0.464333519 */, 12 }, - /* 289 */ { MAD_F(0x0776b867) /* 0.466484455 */, 12 }, - /* 290 */ { MAD_F(0x077f8a6d) /* 0.468637872 */, 12 }, - /* 291 */ { MAD_F(0x07885f0b) /* 0.470793767 */, 12 }, - /* 292 */ { MAD_F(0x07913641) /* 0.472952132 */, 12 }, - /* 293 */ { MAD_F(0x079a100c) /* 0.475112962 */, 12 }, - /* 294 */ { MAD_F(0x07a2ec6c) /* 0.477276252 */, 12 }, - /* 295 */ { MAD_F(0x07abcb5f) /* 0.479441997 */, 12 }, - /* 296 */ { MAD_F(0x07b4ace3) /* 0.481610189 */, 12 }, - /* 297 */ { MAD_F(0x07bd90f6) /* 0.483780825 */, 12 }, - /* 298 */ { MAD_F(0x07c67798) /* 0.485953899 */, 12 }, - /* 299 */ { MAD_F(0x07cf60c7) /* 0.488129404 */, 12 }, - /* 300 */ { MAD_F(0x07d84c81) /* 0.490307336 */, 12 }, - /* 301 */ { MAD_F(0x07e13ac5) /* 0.492487690 */, 12 }, - /* 302 */ { MAD_F(0x07ea2b92) /* 0.494670459 */, 12 }, - /* 303 */ { MAD_F(0x07f31ee6) /* 0.496855639 */, 12 }, - - /* 304 */ { MAD_F(0x07fc14bf) /* 0.499043224 */, 12 }, - /* 305 */ { MAD_F(0x0402868e) /* 0.250616605 */, 13 }, - /* 306 */ { MAD_F(0x040703ff) /* 0.251712795 */, 13 }, - /* 307 */ { MAD_F(0x040b82b0) /* 0.252810180 */, 13 }, - /* 308 */ { MAD_F(0x041002a1) /* 0.253908756 */, 13 }, - /* 309 */ { MAD_F(0x041483d1) /* 0.255008523 */, 13 }, - /* 310 */ { MAD_F(0x04190640) /* 0.256109476 */, 13 }, - /* 311 */ { MAD_F(0x041d89ed) /* 0.257211614 */, 13 }, - /* 312 */ { MAD_F(0x04220ed7) /* 0.258314934 */, 13 }, - /* 313 */ { MAD_F(0x042694fe) /* 0.259419433 */, 13 }, - /* 314 */ { MAD_F(0x042b1c60) /* 0.260525110 */, 13 }, - /* 315 */ { MAD_F(0x042fa4fe) /* 0.261631960 */, 13 }, - /* 316 */ { MAD_F(0x04342ed7) /* 0.262739982 */, 13 }, - /* 317 */ { MAD_F(0x0438b9e9) /* 0.263849174 */, 13 }, - /* 318 */ { MAD_F(0x043d4635) /* 0.264959533 */, 13 }, - /* 319 */ { MAD_F(0x0441d3b9) /* 0.266071056 */, 13 }, - - /* 320 */ { MAD_F(0x04466275) /* 0.267183742 */, 13 }, - /* 321 */ { MAD_F(0x044af269) /* 0.268297587 */, 13 }, - /* 322 */ { MAD_F(0x044f8393) /* 0.269412589 */, 13 }, - /* 323 */ { MAD_F(0x045415f3) /* 0.270528746 */, 13 }, - /* 324 */ { MAD_F(0x0458a989) /* 0.271646056 */, 13 }, - /* 325 */ { MAD_F(0x045d3e53) /* 0.272764515 */, 13 }, - /* 326 */ { MAD_F(0x0461d451) /* 0.273884123 */, 13 }, - /* 327 */ { MAD_F(0x04666b83) /* 0.275004875 */, 13 }, - /* 328 */ { MAD_F(0x046b03e7) /* 0.276126771 */, 13 }, - /* 329 */ { MAD_F(0x046f9d7e) /* 0.277249808 */, 13 }, - /* 330 */ { MAD_F(0x04743847) /* 0.278373983 */, 13 }, - /* 331 */ { MAD_F(0x0478d440) /* 0.279499294 */, 13 }, - /* 332 */ { MAD_F(0x047d716a) /* 0.280625739 */, 13 }, - /* 333 */ { MAD_F(0x04820fc3) /* 0.281753315 */, 13 }, - /* 334 */ { MAD_F(0x0486af4c) /* 0.282882021 */, 13 }, - /* 335 */ { MAD_F(0x048b5003) /* 0.284011853 */, 13 }, - - /* 336 */ { MAD_F(0x048ff1e8) /* 0.285142811 */, 13 }, - /* 337 */ { MAD_F(0x049494fb) /* 0.286274891 */, 13 }, - /* 338 */ { MAD_F(0x0499393a) /* 0.287408091 */, 13 }, - /* 339 */ { MAD_F(0x049ddea5) /* 0.288542409 */, 13 }, - /* 340 */ { MAD_F(0x04a2853c) /* 0.289677844 */, 13 }, - /* 341 */ { MAD_F(0x04a72cfe) /* 0.290814392 */, 13 }, - /* 342 */ { MAD_F(0x04abd5ea) /* 0.291952051 */, 13 }, - /* 343 */ { MAD_F(0x04b08000) /* 0.293090820 */, 13 }, - /* 344 */ { MAD_F(0x04b52b3f) /* 0.294230696 */, 13 }, - /* 345 */ { MAD_F(0x04b9d7a7) /* 0.295371678 */, 13 }, - /* 346 */ { MAD_F(0x04be8537) /* 0.296513762 */, 13 }, - /* 347 */ { MAD_F(0x04c333ee) /* 0.297656947 */, 13 }, - /* 348 */ { MAD_F(0x04c7e3cc) /* 0.298801231 */, 13 }, - /* 349 */ { MAD_F(0x04cc94d1) /* 0.299946611 */, 13 }, - /* 350 */ { MAD_F(0x04d146fb) /* 0.301093085 */, 13 }, - /* 351 */ { MAD_F(0x04d5fa4b) /* 0.302240653 */, 13 }, - - /* 352 */ { MAD_F(0x04daaec0) /* 0.303389310 */, 13 }, - /* 353 */ { MAD_F(0x04df6458) /* 0.304539056 */, 13 }, - /* 354 */ { MAD_F(0x04e41b14) /* 0.305689888 */, 13 }, - /* 355 */ { MAD_F(0x04e8d2f3) /* 0.306841804 */, 13 }, - /* 356 */ { MAD_F(0x04ed8bf5) /* 0.307994802 */, 13 }, - /* 357 */ { MAD_F(0x04f24618) /* 0.309148880 */, 13 }, - /* 358 */ { MAD_F(0x04f7015d) /* 0.310304037 */, 13 }, - /* 359 */ { MAD_F(0x04fbbdc3) /* 0.311460269 */, 13 }, - /* 360 */ { MAD_F(0x05007b49) /* 0.312617576 */, 13 }, - /* 361 */ { MAD_F(0x050539ef) /* 0.313775954 */, 13 }, - /* 362 */ { MAD_F(0x0509f9b4) /* 0.314935403 */, 13 }, - /* 363 */ { MAD_F(0x050eba98) /* 0.316095920 */, 13 }, - /* 364 */ { MAD_F(0x05137c9a) /* 0.317257503 */, 13 }, - /* 365 */ { MAD_F(0x05183fba) /* 0.318420150 */, 13 }, - /* 366 */ { MAD_F(0x051d03f7) /* 0.319583859 */, 13 }, - /* 367 */ { MAD_F(0x0521c950) /* 0.320748629 */, 13 }, - - /* 368 */ { MAD_F(0x05268fc6) /* 0.321914457 */, 13 }, - /* 369 */ { MAD_F(0x052b5757) /* 0.323081342 */, 13 }, - /* 370 */ { MAD_F(0x05302003) /* 0.324249281 */, 13 }, - /* 371 */ { MAD_F(0x0534e9ca) /* 0.325418273 */, 13 }, - /* 372 */ { MAD_F(0x0539b4ab) /* 0.326588316 */, 13 }, - /* 373 */ { MAD_F(0x053e80a6) /* 0.327759407 */, 13 }, - /* 374 */ { MAD_F(0x05434db9) /* 0.328931546 */, 13 }, - /* 375 */ { MAD_F(0x05481be5) /* 0.330104730 */, 13 }, - /* 376 */ { MAD_F(0x054ceb2a) /* 0.331278957 */, 13 }, - /* 377 */ { MAD_F(0x0551bb85) /* 0.332454225 */, 13 }, - /* 378 */ { MAD_F(0x05568cf8) /* 0.333630533 */, 13 }, - /* 379 */ { MAD_F(0x055b5f81) /* 0.334807879 */, 13 }, - /* 380 */ { MAD_F(0x05603321) /* 0.335986261 */, 13 }, - /* 381 */ { MAD_F(0x056507d6) /* 0.337165677 */, 13 }, - /* 382 */ { MAD_F(0x0569dda0) /* 0.338346125 */, 13 }, - /* 383 */ { MAD_F(0x056eb47f) /* 0.339527604 */, 13 }, - - /* 384 */ { MAD_F(0x05738c72) /* 0.340710111 */, 13 }, - /* 385 */ { MAD_F(0x05786578) /* 0.341893646 */, 13 }, - /* 386 */ { MAD_F(0x057d3f92) /* 0.343078205 */, 13 }, - /* 387 */ { MAD_F(0x05821abf) /* 0.344263788 */, 13 }, - /* 388 */ { MAD_F(0x0586f6fd) /* 0.345450393 */, 13 }, - /* 389 */ { MAD_F(0x058bd44e) /* 0.346638017 */, 13 }, - /* 390 */ { MAD_F(0x0590b2b0) /* 0.347826659 */, 13 }, - /* 391 */ { MAD_F(0x05959222) /* 0.349016318 */, 13 }, - /* 392 */ { MAD_F(0x059a72a5) /* 0.350206992 */, 13 }, - /* 393 */ { MAD_F(0x059f5438) /* 0.351398678 */, 13 }, - /* 394 */ { MAD_F(0x05a436da) /* 0.352591376 */, 13 }, - /* 395 */ { MAD_F(0x05a91a8c) /* 0.353785083 */, 13 }, - /* 396 */ { MAD_F(0x05adff4c) /* 0.354979798 */, 13 }, - /* 397 */ { MAD_F(0x05b2e51a) /* 0.356175519 */, 13 }, - /* 398 */ { MAD_F(0x05b7cbf5) /* 0.357372244 */, 13 }, - /* 399 */ { MAD_F(0x05bcb3de) /* 0.358569972 */, 13 }, - - /* 400 */ { MAD_F(0x05c19cd3) /* 0.359768701 */, 13 }, - /* 401 */ { MAD_F(0x05c686d5) /* 0.360968429 */, 13 }, - /* 402 */ { MAD_F(0x05cb71e2) /* 0.362169156 */, 13 }, - /* 403 */ { MAD_F(0x05d05dfb) /* 0.363370878 */, 13 }, - /* 404 */ { MAD_F(0x05d54b1f) /* 0.364573594 */, 13 }, - /* 405 */ { MAD_F(0x05da394d) /* 0.365777304 */, 13 }, - /* 406 */ { MAD_F(0x05df2885) /* 0.366982004 */, 13 }, - /* 407 */ { MAD_F(0x05e418c7) /* 0.368187694 */, 13 }, - /* 408 */ { MAD_F(0x05e90a12) /* 0.369394372 */, 13 }, - /* 409 */ { MAD_F(0x05edfc66) /* 0.370602036 */, 13 }, - /* 410 */ { MAD_F(0x05f2efc2) /* 0.371810684 */, 13 }, - /* 411 */ { MAD_F(0x05f7e426) /* 0.373020316 */, 13 }, - /* 412 */ { MAD_F(0x05fcd992) /* 0.374230929 */, 13 }, - /* 413 */ { MAD_F(0x0601d004) /* 0.375442522 */, 13 }, - /* 414 */ { MAD_F(0x0606c77d) /* 0.376655093 */, 13 }, - /* 415 */ { MAD_F(0x060bbffd) /* 0.377868641 */, 13 }, - - /* 416 */ { MAD_F(0x0610b982) /* 0.379083164 */, 13 }, - /* 417 */ { MAD_F(0x0615b40c) /* 0.380298661 */, 13 }, - /* 418 */ { MAD_F(0x061aaf9c) /* 0.381515130 */, 13 }, - /* 419 */ { MAD_F(0x061fac2f) /* 0.382732569 */, 13 }, - /* 420 */ { MAD_F(0x0624a9c7) /* 0.383950977 */, 13 }, - /* 421 */ { MAD_F(0x0629a863) /* 0.385170352 */, 13 }, - /* 422 */ { MAD_F(0x062ea802) /* 0.386390694 */, 13 }, - /* 423 */ { MAD_F(0x0633a8a3) /* 0.387611999 */, 13 }, - /* 424 */ { MAD_F(0x0638aa48) /* 0.388834268 */, 13 }, - /* 425 */ { MAD_F(0x063dacee) /* 0.390057497 */, 13 }, - /* 426 */ { MAD_F(0x0642b096) /* 0.391281687 */, 13 }, - /* 427 */ { MAD_F(0x0647b53f) /* 0.392506834 */, 13 }, - /* 428 */ { MAD_F(0x064cbae9) /* 0.393732939 */, 13 }, - /* 429 */ { MAD_F(0x0651c193) /* 0.394959999 */, 13 }, - /* 430 */ { MAD_F(0x0656c93d) /* 0.396188012 */, 13 }, - /* 431 */ { MAD_F(0x065bd1e7) /* 0.397416978 */, 13 }, - - /* 432 */ { MAD_F(0x0660db91) /* 0.398646895 */, 13 }, - /* 433 */ { MAD_F(0x0665e639) /* 0.399877761 */, 13 }, - /* 434 */ { MAD_F(0x066af1df) /* 0.401109575 */, 13 }, - /* 435 */ { MAD_F(0x066ffe84) /* 0.402342335 */, 13 }, - /* 436 */ { MAD_F(0x06750c26) /* 0.403576041 */, 13 }, - /* 437 */ { MAD_F(0x067a1ac6) /* 0.404810690 */, 13 }, - /* 438 */ { MAD_F(0x067f2a62) /* 0.406046281 */, 13 }, - /* 439 */ { MAD_F(0x06843afb) /* 0.407282813 */, 13 }, - /* 440 */ { MAD_F(0x06894c90) /* 0.408520284 */, 13 }, - /* 441 */ { MAD_F(0x068e5f21) /* 0.409758693 */, 13 }, - /* 442 */ { MAD_F(0x069372ae) /* 0.410998038 */, 13 }, - /* 443 */ { MAD_F(0x06988735) /* 0.412238319 */, 13 }, - /* 444 */ { MAD_F(0x069d9cb7) /* 0.413479532 */, 13 }, - /* 445 */ { MAD_F(0x06a2b333) /* 0.414721679 */, 13 }, - /* 446 */ { MAD_F(0x06a7caa9) /* 0.415964756 */, 13 }, - /* 447 */ { MAD_F(0x06ace318) /* 0.417208762 */, 13 }, - - /* 448 */ { MAD_F(0x06b1fc81) /* 0.418453696 */, 13 }, - /* 449 */ { MAD_F(0x06b716e2) /* 0.419699557 */, 13 }, - /* 450 */ { MAD_F(0x06bc323b) /* 0.420946343 */, 13 }, - /* 451 */ { MAD_F(0x06c14e8d) /* 0.422194054 */, 13 }, - /* 452 */ { MAD_F(0x06c66bd6) /* 0.423442686 */, 13 }, - /* 453 */ { MAD_F(0x06cb8a17) /* 0.424692240 */, 13 }, - /* 454 */ { MAD_F(0x06d0a94e) /* 0.425942714 */, 13 }, - /* 455 */ { MAD_F(0x06d5c97c) /* 0.427194106 */, 13 }, - /* 456 */ { MAD_F(0x06daeaa1) /* 0.428446415 */, 13 }, - /* 457 */ { MAD_F(0x06e00cbb) /* 0.429699640 */, 13 }, - /* 458 */ { MAD_F(0x06e52fca) /* 0.430953779 */, 13 }, - /* 459 */ { MAD_F(0x06ea53cf) /* 0.432208832 */, 13 }, - /* 460 */ { MAD_F(0x06ef78c8) /* 0.433464796 */, 13 }, - /* 461 */ { MAD_F(0x06f49eb6) /* 0.434721671 */, 13 }, - /* 462 */ { MAD_F(0x06f9c597) /* 0.435979455 */, 13 }, - /* 463 */ { MAD_F(0x06feed6d) /* 0.437238146 */, 13 }, - - /* 464 */ { MAD_F(0x07041636) /* 0.438497744 */, 13 }, - /* 465 */ { MAD_F(0x07093ff2) /* 0.439758248 */, 13 }, - /* 466 */ { MAD_F(0x070e6aa0) /* 0.441019655 */, 13 }, - /* 467 */ { MAD_F(0x07139641) /* 0.442281965 */, 13 }, - /* 468 */ { MAD_F(0x0718c2d3) /* 0.443545176 */, 13 }, - /* 469 */ { MAD_F(0x071df058) /* 0.444809288 */, 13 }, - /* 470 */ { MAD_F(0x07231ecd) /* 0.446074298 */, 13 }, - /* 471 */ { MAD_F(0x07284e34) /* 0.447340205 */, 13 }, - /* 472 */ { MAD_F(0x072d7e8b) /* 0.448607009 */, 13 }, - /* 473 */ { MAD_F(0x0732afd2) /* 0.449874708 */, 13 }, - /* 474 */ { MAD_F(0x0737e209) /* 0.451143300 */, 13 }, - /* 475 */ { MAD_F(0x073d1530) /* 0.452412785 */, 13 }, - /* 476 */ { MAD_F(0x07424946) /* 0.453683161 */, 13 }, - /* 477 */ { MAD_F(0x07477e4b) /* 0.454954427 */, 13 }, - /* 478 */ { MAD_F(0x074cb43e) /* 0.456226581 */, 13 }, - /* 479 */ { MAD_F(0x0751eb20) /* 0.457499623 */, 13 }, - - /* 480 */ { MAD_F(0x075722ef) /* 0.458773552 */, 13 }, - /* 481 */ { MAD_F(0x075c5bac) /* 0.460048365 */, 13 }, - /* 482 */ { MAD_F(0x07619557) /* 0.461324062 */, 13 }, - /* 483 */ { MAD_F(0x0766cfee) /* 0.462600642 */, 13 }, - /* 484 */ { MAD_F(0x076c0b72) /* 0.463878102 */, 13 }, - /* 485 */ { MAD_F(0x077147e2) /* 0.465156443 */, 13 }, - /* 486 */ { MAD_F(0x0776853e) /* 0.466435663 */, 13 }, - /* 487 */ { MAD_F(0x077bc385) /* 0.467715761 */, 13 }, - /* 488 */ { MAD_F(0x078102b8) /* 0.468996735 */, 13 }, - /* 489 */ { MAD_F(0x078642d6) /* 0.470278584 */, 13 }, - /* 490 */ { MAD_F(0x078b83de) /* 0.471561307 */, 13 }, - /* 491 */ { MAD_F(0x0790c5d1) /* 0.472844904 */, 13 }, - /* 492 */ { MAD_F(0x079608ae) /* 0.474129372 */, 13 }, - /* 493 */ { MAD_F(0x079b4c74) /* 0.475414710 */, 13 }, - /* 494 */ { MAD_F(0x07a09124) /* 0.476700918 */, 13 }, - /* 495 */ { MAD_F(0x07a5d6bd) /* 0.477987994 */, 13 }, - - /* 496 */ { MAD_F(0x07ab1d3e) /* 0.479275937 */, 13 }, - /* 497 */ { MAD_F(0x07b064a8) /* 0.480564746 */, 13 }, - /* 498 */ { MAD_F(0x07b5acfb) /* 0.481854420 */, 13 }, - /* 499 */ { MAD_F(0x07baf635) /* 0.483144957 */, 13 }, - /* 500 */ { MAD_F(0x07c04056) /* 0.484436356 */, 13 }, - /* 501 */ { MAD_F(0x07c58b5f) /* 0.485728617 */, 13 }, - /* 502 */ { MAD_F(0x07cad74e) /* 0.487021738 */, 13 }, - /* 503 */ { MAD_F(0x07d02424) /* 0.488315717 */, 13 }, - /* 504 */ { MAD_F(0x07d571e0) /* 0.489610555 */, 13 }, - /* 505 */ { MAD_F(0x07dac083) /* 0.490906249 */, 13 }, - /* 506 */ { MAD_F(0x07e0100a) /* 0.492202799 */, 13 }, - /* 507 */ { MAD_F(0x07e56078) /* 0.493500203 */, 13 }, - /* 508 */ { MAD_F(0x07eab1ca) /* 0.494798460 */, 13 }, - /* 509 */ { MAD_F(0x07f00401) /* 0.496097570 */, 13 }, - /* 510 */ { MAD_F(0x07f5571d) /* 0.497397530 */, 13 }, - /* 511 */ { MAD_F(0x07faab1c) /* 0.498698341 */, 13 }, - - /* 512 */ { MAD_F(0x04000000) /* 0.250000000 */, 14 }, - /* 513 */ { MAD_F(0x0402aae3) /* 0.250651254 */, 14 }, - /* 514 */ { MAD_F(0x04055638) /* 0.251302930 */, 14 }, - /* 515 */ { MAD_F(0x040801ff) /* 0.251955030 */, 14 }, - /* 516 */ { MAD_F(0x040aae37) /* 0.252607552 */, 14 }, - /* 517 */ { MAD_F(0x040d5ae0) /* 0.253260495 */, 14 }, - /* 518 */ { MAD_F(0x041007fa) /* 0.253913860 */, 14 }, - /* 519 */ { MAD_F(0x0412b586) /* 0.254567645 */, 14 }, - /* 520 */ { MAD_F(0x04156381) /* 0.255221850 */, 14 }, - /* 521 */ { MAD_F(0x041811ee) /* 0.255876475 */, 14 }, - /* 522 */ { MAD_F(0x041ac0cb) /* 0.256531518 */, 14 }, - /* 523 */ { MAD_F(0x041d7018) /* 0.257186980 */, 14 }, - /* 524 */ { MAD_F(0x04201fd5) /* 0.257842860 */, 14 }, - /* 525 */ { MAD_F(0x0422d003) /* 0.258499157 */, 14 }, - /* 526 */ { MAD_F(0x042580a0) /* 0.259155872 */, 14 }, - /* 527 */ { MAD_F(0x042831ad) /* 0.259813002 */, 14 }, - - /* 528 */ { MAD_F(0x042ae32a) /* 0.260470548 */, 14 }, - /* 529 */ { MAD_F(0x042d9516) /* 0.261128510 */, 14 }, - /* 530 */ { MAD_F(0x04304772) /* 0.261786886 */, 14 }, - /* 531 */ { MAD_F(0x0432fa3d) /* 0.262445676 */, 14 }, - /* 532 */ { MAD_F(0x0435ad76) /* 0.263104880 */, 14 }, - /* 533 */ { MAD_F(0x0438611f) /* 0.263764497 */, 14 }, - /* 534 */ { MAD_F(0x043b1536) /* 0.264424527 */, 14 }, - /* 535 */ { MAD_F(0x043dc9bc) /* 0.265084969 */, 14 }, - /* 536 */ { MAD_F(0x04407eb1) /* 0.265745823 */, 14 }, - /* 537 */ { MAD_F(0x04433414) /* 0.266407088 */, 14 }, - /* 538 */ { MAD_F(0x0445e9e5) /* 0.267068763 */, 14 }, - /* 539 */ { MAD_F(0x0448a024) /* 0.267730848 */, 14 }, - /* 540 */ { MAD_F(0x044b56d1) /* 0.268393343 */, 14 }, - /* 541 */ { MAD_F(0x044e0dec) /* 0.269056248 */, 14 }, - /* 542 */ { MAD_F(0x0450c575) /* 0.269719560 */, 14 }, - /* 543 */ { MAD_F(0x04537d6b) /* 0.270383281 */, 14 }, - - /* 544 */ { MAD_F(0x045635cf) /* 0.271047409 */, 14 }, - /* 545 */ { MAD_F(0x0458ee9f) /* 0.271711944 */, 14 }, - /* 546 */ { MAD_F(0x045ba7dd) /* 0.272376886 */, 14 }, - /* 547 */ { MAD_F(0x045e6188) /* 0.273042234 */, 14 }, - /* 548 */ { MAD_F(0x04611ba0) /* 0.273707988 */, 14 }, - /* 549 */ { MAD_F(0x0463d625) /* 0.274374147 */, 14 }, - /* 550 */ { MAD_F(0x04669116) /* 0.275040710 */, 14 }, - /* 551 */ { MAD_F(0x04694c74) /* 0.275707677 */, 14 }, - /* 552 */ { MAD_F(0x046c083e) /* 0.276375048 */, 14 }, - /* 553 */ { MAD_F(0x046ec474) /* 0.277042822 */, 14 }, - /* 554 */ { MAD_F(0x04718116) /* 0.277710999 */, 14 }, - /* 555 */ { MAD_F(0x04743e25) /* 0.278379578 */, 14 }, - /* 556 */ { MAD_F(0x0476fb9f) /* 0.279048558 */, 14 }, - /* 557 */ { MAD_F(0x0479b984) /* 0.279717940 */, 14 }, - /* 558 */ { MAD_F(0x047c77d6) /* 0.280387722 */, 14 }, - /* 559 */ { MAD_F(0x047f3693) /* 0.281057905 */, 14 }, - - /* 560 */ { MAD_F(0x0481f5bb) /* 0.281728487 */, 14 }, - /* 561 */ { MAD_F(0x0484b54e) /* 0.282399469 */, 14 }, - /* 562 */ { MAD_F(0x0487754c) /* 0.283070849 */, 14 }, - /* 563 */ { MAD_F(0x048a35b6) /* 0.283742628 */, 14 }, - /* 564 */ { MAD_F(0x048cf68a) /* 0.284414805 */, 14 }, - /* 565 */ { MAD_F(0x048fb7c8) /* 0.285087379 */, 14 }, - /* 566 */ { MAD_F(0x04927972) /* 0.285760350 */, 14 }, - /* 567 */ { MAD_F(0x04953b85) /* 0.286433717 */, 14 }, - /* 568 */ { MAD_F(0x0497fe03) /* 0.287107481 */, 14 }, - /* 569 */ { MAD_F(0x049ac0eb) /* 0.287781640 */, 14 }, - /* 570 */ { MAD_F(0x049d843e) /* 0.288456194 */, 14 }, - /* 571 */ { MAD_F(0x04a047fa) /* 0.289131142 */, 14 }, - /* 572 */ { MAD_F(0x04a30c20) /* 0.289806485 */, 14 }, - /* 573 */ { MAD_F(0x04a5d0af) /* 0.290482221 */, 14 }, - /* 574 */ { MAD_F(0x04a895a8) /* 0.291158351 */, 14 }, - /* 575 */ { MAD_F(0x04ab5b0b) /* 0.291834873 */, 14 }, - - /* 576 */ { MAD_F(0x04ae20d7) /* 0.292511788 */, 14 }, - /* 577 */ { MAD_F(0x04b0e70c) /* 0.293189094 */, 14 }, - /* 578 */ { MAD_F(0x04b3adaa) /* 0.293866792 */, 14 }, - /* 579 */ { MAD_F(0x04b674b1) /* 0.294544881 */, 14 }, - /* 580 */ { MAD_F(0x04b93c21) /* 0.295223360 */, 14 }, - /* 581 */ { MAD_F(0x04bc03fa) /* 0.295902229 */, 14 }, - /* 582 */ { MAD_F(0x04becc3b) /* 0.296581488 */, 14 }, - /* 583 */ { MAD_F(0x04c194e4) /* 0.297261136 */, 14 }, - /* 584 */ { MAD_F(0x04c45df6) /* 0.297941173 */, 14 }, - /* 585 */ { MAD_F(0x04c72771) /* 0.298621598 */, 14 }, - /* 586 */ { MAD_F(0x04c9f153) /* 0.299302411 */, 14 }, - /* 587 */ { MAD_F(0x04ccbb9d) /* 0.299983611 */, 14 }, - /* 588 */ { MAD_F(0x04cf864f) /* 0.300665198 */, 14 }, - /* 589 */ { MAD_F(0x04d25169) /* 0.301347172 */, 14 }, - /* 590 */ { MAD_F(0x04d51ceb) /* 0.302029532 */, 14 }, - /* 591 */ { MAD_F(0x04d7e8d4) /* 0.302712277 */, 14 }, - - /* 592 */ { MAD_F(0x04dab524) /* 0.303395408 */, 14 }, - /* 593 */ { MAD_F(0x04dd81dc) /* 0.304078923 */, 14 }, - /* 594 */ { MAD_F(0x04e04efb) /* 0.304762823 */, 14 }, - /* 595 */ { MAD_F(0x04e31c81) /* 0.305447106 */, 14 }, - /* 596 */ { MAD_F(0x04e5ea6e) /* 0.306131773 */, 14 }, - /* 597 */ { MAD_F(0x04e8b8c2) /* 0.306816823 */, 14 }, - /* 598 */ { MAD_F(0x04eb877c) /* 0.307502256 */, 14 }, - /* 599 */ { MAD_F(0x04ee569d) /* 0.308188071 */, 14 }, - /* 600 */ { MAD_F(0x04f12624) /* 0.308874267 */, 14 }, - /* 601 */ { MAD_F(0x04f3f612) /* 0.309560845 */, 14 }, - /* 602 */ { MAD_F(0x04f6c666) /* 0.310247804 */, 14 }, - /* 603 */ { MAD_F(0x04f99721) /* 0.310935143 */, 14 }, - /* 604 */ { MAD_F(0x04fc6841) /* 0.311622862 */, 14 }, - /* 605 */ { MAD_F(0x04ff39c7) /* 0.312310961 */, 14 }, - /* 606 */ { MAD_F(0x05020bb3) /* 0.312999439 */, 14 }, - /* 607 */ { MAD_F(0x0504de05) /* 0.313688296 */, 14 }, - - /* 608 */ { MAD_F(0x0507b0bc) /* 0.314377532 */, 14 }, - /* 609 */ { MAD_F(0x050a83d8) /* 0.315067145 */, 14 }, - /* 610 */ { MAD_F(0x050d575b) /* 0.315757136 */, 14 }, - /* 611 */ { MAD_F(0x05102b42) /* 0.316447504 */, 14 }, - /* 612 */ { MAD_F(0x0512ff8e) /* 0.317138249 */, 14 }, - /* 613 */ { MAD_F(0x0515d440) /* 0.317829370 */, 14 }, - /* 614 */ { MAD_F(0x0518a956) /* 0.318520867 */, 14 }, - /* 615 */ { MAD_F(0x051b7ed1) /* 0.319212739 */, 14 }, - /* 616 */ { MAD_F(0x051e54b1) /* 0.319904987 */, 14 }, - /* 617 */ { MAD_F(0x05212af5) /* 0.320597609 */, 14 }, - /* 618 */ { MAD_F(0x0524019e) /* 0.321290606 */, 14 }, - /* 619 */ { MAD_F(0x0526d8ab) /* 0.321983976 */, 14 }, - /* 620 */ { MAD_F(0x0529b01d) /* 0.322677720 */, 14 }, - /* 621 */ { MAD_F(0x052c87f2) /* 0.323371837 */, 14 }, - /* 622 */ { MAD_F(0x052f602c) /* 0.324066327 */, 14 }, - /* 623 */ { MAD_F(0x053238ca) /* 0.324761189 */, 14 }, - - /* 624 */ { MAD_F(0x053511cb) /* 0.325456423 */, 14 }, - /* 625 */ { MAD_F(0x0537eb30) /* 0.326152028 */, 14 }, - /* 626 */ { MAD_F(0x053ac4f9) /* 0.326848005 */, 14 }, - /* 627 */ { MAD_F(0x053d9f25) /* 0.327544352 */, 14 }, - /* 628 */ { MAD_F(0x054079b5) /* 0.328241070 */, 14 }, - /* 629 */ { MAD_F(0x054354a8) /* 0.328938157 */, 14 }, - /* 630 */ { MAD_F(0x05462ffe) /* 0.329635614 */, 14 }, - /* 631 */ { MAD_F(0x05490bb7) /* 0.330333440 */, 14 }, - /* 632 */ { MAD_F(0x054be7d4) /* 0.331031635 */, 14 }, - /* 633 */ { MAD_F(0x054ec453) /* 0.331730198 */, 14 }, - /* 634 */ { MAD_F(0x0551a134) /* 0.332429129 */, 14 }, - /* 635 */ { MAD_F(0x05547e79) /* 0.333128427 */, 14 }, - /* 636 */ { MAD_F(0x05575c20) /* 0.333828093 */, 14 }, - /* 637 */ { MAD_F(0x055a3a2a) /* 0.334528126 */, 14 }, - /* 638 */ { MAD_F(0x055d1896) /* 0.335228525 */, 14 }, - /* 639 */ { MAD_F(0x055ff764) /* 0.335929290 */, 14 }, - - /* 640 */ { MAD_F(0x0562d694) /* 0.336630420 */, 14 }, - /* 641 */ { MAD_F(0x0565b627) /* 0.337331916 */, 14 }, - /* 642 */ { MAD_F(0x0568961b) /* 0.338033777 */, 14 }, - /* 643 */ { MAD_F(0x056b7671) /* 0.338736002 */, 14 }, - /* 644 */ { MAD_F(0x056e5729) /* 0.339438592 */, 14 }, - /* 645 */ { MAD_F(0x05713843) /* 0.340141545 */, 14 }, - /* 646 */ { MAD_F(0x057419be) /* 0.340844862 */, 14 }, - /* 647 */ { MAD_F(0x0576fb9a) /* 0.341548541 */, 14 }, - /* 648 */ { MAD_F(0x0579ddd8) /* 0.342252584 */, 14 }, - /* 649 */ { MAD_F(0x057cc077) /* 0.342956988 */, 14 }, - /* 650 */ { MAD_F(0x057fa378) /* 0.343661754 */, 14 }, - /* 651 */ { MAD_F(0x058286d9) /* 0.344366882 */, 14 }, - /* 652 */ { MAD_F(0x05856a9b) /* 0.345072371 */, 14 }, - /* 653 */ { MAD_F(0x05884ebe) /* 0.345778221 */, 14 }, - /* 654 */ { MAD_F(0x058b3342) /* 0.346484431 */, 14 }, - /* 655 */ { MAD_F(0x058e1827) /* 0.347191002 */, 14 }, - - /* 656 */ { MAD_F(0x0590fd6c) /* 0.347897931 */, 14 }, - /* 657 */ { MAD_F(0x0593e311) /* 0.348605221 */, 14 }, - /* 658 */ { MAD_F(0x0596c917) /* 0.349312869 */, 14 }, - /* 659 */ { MAD_F(0x0599af7d) /* 0.350020876 */, 14 }, - /* 660 */ { MAD_F(0x059c9643) /* 0.350729240 */, 14 }, - /* 661 */ { MAD_F(0x059f7d6a) /* 0.351437963 */, 14 }, - /* 662 */ { MAD_F(0x05a264f0) /* 0.352147044 */, 14 }, - /* 663 */ { MAD_F(0x05a54cd6) /* 0.352856481 */, 14 }, - /* 664 */ { MAD_F(0x05a8351c) /* 0.353566275 */, 14 }, - /* 665 */ { MAD_F(0x05ab1dc2) /* 0.354276426 */, 14 }, - /* 666 */ { MAD_F(0x05ae06c7) /* 0.354986932 */, 14 }, - /* 667 */ { MAD_F(0x05b0f02b) /* 0.355697795 */, 14 }, - /* 668 */ { MAD_F(0x05b3d9f0) /* 0.356409012 */, 14 }, - /* 669 */ { MAD_F(0x05b6c413) /* 0.357120585 */, 14 }, - /* 670 */ { MAD_F(0x05b9ae95) /* 0.357832512 */, 14 }, - /* 671 */ { MAD_F(0x05bc9977) /* 0.358544794 */, 14 }, - - /* 672 */ { MAD_F(0x05bf84b8) /* 0.359257429 */, 14 }, - /* 673 */ { MAD_F(0x05c27057) /* 0.359970419 */, 14 }, - /* 674 */ { MAD_F(0x05c55c56) /* 0.360683761 */, 14 }, - /* 675 */ { MAD_F(0x05c848b3) /* 0.361397456 */, 14 }, - /* 676 */ { MAD_F(0x05cb356e) /* 0.362111504 */, 14 }, - /* 677 */ { MAD_F(0x05ce2289) /* 0.362825904 */, 14 }, - /* 678 */ { MAD_F(0x05d11001) /* 0.363540655 */, 14 }, - /* 679 */ { MAD_F(0x05d3fdd8) /* 0.364255759 */, 14 }, - /* 680 */ { MAD_F(0x05d6ec0e) /* 0.364971213 */, 14 }, - /* 681 */ { MAD_F(0x05d9daa1) /* 0.365687018 */, 14 }, - /* 682 */ { MAD_F(0x05dcc993) /* 0.366403174 */, 14 }, - /* 683 */ { MAD_F(0x05dfb8e2) /* 0.367119680 */, 14 }, - /* 684 */ { MAD_F(0x05e2a890) /* 0.367836535 */, 14 }, - /* 685 */ { MAD_F(0x05e5989b) /* 0.368553740 */, 14 }, - /* 686 */ { MAD_F(0x05e88904) /* 0.369271294 */, 14 }, - /* 687 */ { MAD_F(0x05eb79cb) /* 0.369989197 */, 14 }, - - /* 688 */ { MAD_F(0x05ee6aef) /* 0.370707448 */, 14 }, - /* 689 */ { MAD_F(0x05f15c70) /* 0.371426047 */, 14 }, - /* 690 */ { MAD_F(0x05f44e4f) /* 0.372144994 */, 14 }, - /* 691 */ { MAD_F(0x05f7408b) /* 0.372864289 */, 14 }, - /* 692 */ { MAD_F(0x05fa3324) /* 0.373583930 */, 14 }, - /* 693 */ { MAD_F(0x05fd261b) /* 0.374303918 */, 14 }, - /* 694 */ { MAD_F(0x0600196e) /* 0.375024253 */, 14 }, - /* 695 */ { MAD_F(0x06030d1e) /* 0.375744934 */, 14 }, - /* 696 */ { MAD_F(0x0606012b) /* 0.376465960 */, 14 }, - /* 697 */ { MAD_F(0x0608f595) /* 0.377187332 */, 14 }, - /* 698 */ { MAD_F(0x060bea5c) /* 0.377909049 */, 14 }, - /* 699 */ { MAD_F(0x060edf7f) /* 0.378631110 */, 14 }, - /* 700 */ { MAD_F(0x0611d4fe) /* 0.379353516 */, 14 }, - /* 701 */ { MAD_F(0x0614cada) /* 0.380076266 */, 14 }, - /* 702 */ { MAD_F(0x0617c112) /* 0.380799360 */, 14 }, - /* 703 */ { MAD_F(0x061ab7a6) /* 0.381522798 */, 14 }, - - /* 704 */ { MAD_F(0x061dae96) /* 0.382246578 */, 14 }, - /* 705 */ { MAD_F(0x0620a5e3) /* 0.382970701 */, 14 }, - /* 706 */ { MAD_F(0x06239d8b) /* 0.383695167 */, 14 }, - /* 707 */ { MAD_F(0x0626958f) /* 0.384419975 */, 14 }, - /* 708 */ { MAD_F(0x06298def) /* 0.385145124 */, 14 }, - /* 709 */ { MAD_F(0x062c86aa) /* 0.385870615 */, 14 }, - /* 710 */ { MAD_F(0x062f7fc1) /* 0.386596448 */, 14 }, - /* 711 */ { MAD_F(0x06327934) /* 0.387322621 */, 14 }, - /* 712 */ { MAD_F(0x06357302) /* 0.388049134 */, 14 }, - /* 713 */ { MAD_F(0x06386d2b) /* 0.388775988 */, 14 }, - /* 714 */ { MAD_F(0x063b67b0) /* 0.389503182 */, 14 }, - /* 715 */ { MAD_F(0x063e6290) /* 0.390230715 */, 14 }, - /* 716 */ { MAD_F(0x06415dcb) /* 0.390958588 */, 14 }, - /* 717 */ { MAD_F(0x06445960) /* 0.391686799 */, 14 }, - /* 718 */ { MAD_F(0x06475551) /* 0.392415349 */, 14 }, - /* 719 */ { MAD_F(0x064a519c) /* 0.393144238 */, 14 }, - - /* 720 */ { MAD_F(0x064d4e43) /* 0.393873464 */, 14 }, - /* 721 */ { MAD_F(0x06504b44) /* 0.394603028 */, 14 }, - /* 722 */ { MAD_F(0x0653489f) /* 0.395332930 */, 14 }, - /* 723 */ { MAD_F(0x06564655) /* 0.396063168 */, 14 }, - /* 724 */ { MAD_F(0x06594465) /* 0.396793743 */, 14 }, - /* 725 */ { MAD_F(0x065c42d0) /* 0.397524655 */, 14 }, - /* 726 */ { MAD_F(0x065f4195) /* 0.398255903 */, 14 }, - /* 727 */ { MAD_F(0x066240b4) /* 0.398987487 */, 14 }, - /* 728 */ { MAD_F(0x0665402d) /* 0.399719406 */, 14 }, - /* 729 */ { MAD_F(0x06684000) /* 0.400451660 */, 14 }, - /* 730 */ { MAD_F(0x066b402d) /* 0.401184249 */, 14 }, - /* 731 */ { MAD_F(0x066e40b3) /* 0.401917173 */, 14 }, - /* 732 */ { MAD_F(0x06714194) /* 0.402650431 */, 14 }, - /* 733 */ { MAD_F(0x067442ce) /* 0.403384024 */, 14 }, - /* 734 */ { MAD_F(0x06774462) /* 0.404117949 */, 14 }, - /* 735 */ { MAD_F(0x067a464f) /* 0.404852209 */, 14 }, - - /* 736 */ { MAD_F(0x067d4896) /* 0.405586801 */, 14 }, - /* 737 */ { MAD_F(0x06804b36) /* 0.406321726 */, 14 }, - /* 738 */ { MAD_F(0x06834e2f) /* 0.407056983 */, 14 }, - /* 739 */ { MAD_F(0x06865181) /* 0.407792573 */, 14 }, - /* 740 */ { MAD_F(0x0689552c) /* 0.408528495 */, 14 }, - /* 741 */ { MAD_F(0x068c5931) /* 0.409264748 */, 14 }, - /* 742 */ { MAD_F(0x068f5d8e) /* 0.410001332 */, 14 }, - /* 743 */ { MAD_F(0x06926245) /* 0.410738247 */, 14 }, - /* 744 */ { MAD_F(0x06956753) /* 0.411475493 */, 14 }, - /* 745 */ { MAD_F(0x06986cbb) /* 0.412213070 */, 14 }, - /* 746 */ { MAD_F(0x069b727b) /* 0.412950976 */, 14 }, - /* 747 */ { MAD_F(0x069e7894) /* 0.413689213 */, 14 }, - /* 748 */ { MAD_F(0x06a17f05) /* 0.414427779 */, 14 }, - /* 749 */ { MAD_F(0x06a485cf) /* 0.415166674 */, 14 }, - /* 750 */ { MAD_F(0x06a78cf1) /* 0.415905897 */, 14 }, - /* 751 */ { MAD_F(0x06aa946b) /* 0.416645450 */, 14 }, - - /* 752 */ { MAD_F(0x06ad9c3d) /* 0.417385331 */, 14 }, - /* 753 */ { MAD_F(0x06b0a468) /* 0.418125540 */, 14 }, - /* 754 */ { MAD_F(0x06b3acea) /* 0.418866076 */, 14 }, - /* 755 */ { MAD_F(0x06b6b5c4) /* 0.419606940 */, 14 }, - /* 756 */ { MAD_F(0x06b9bef6) /* 0.420348132 */, 14 }, - /* 757 */ { MAD_F(0x06bcc880) /* 0.421089650 */, 14 }, - /* 758 */ { MAD_F(0x06bfd261) /* 0.421831494 */, 14 }, - /* 759 */ { MAD_F(0x06c2dc9a) /* 0.422573665 */, 14 }, - /* 760 */ { MAD_F(0x06c5e72b) /* 0.423316162 */, 14 }, - /* 761 */ { MAD_F(0x06c8f213) /* 0.424058985 */, 14 }, - /* 762 */ { MAD_F(0x06cbfd52) /* 0.424802133 */, 14 }, - /* 763 */ { MAD_F(0x06cf08e9) /* 0.425545607 */, 14 }, - /* 764 */ { MAD_F(0x06d214d7) /* 0.426289405 */, 14 }, - /* 765 */ { MAD_F(0x06d5211c) /* 0.427033528 */, 14 }, - /* 766 */ { MAD_F(0x06d82db8) /* 0.427777975 */, 14 }, - /* 767 */ { MAD_F(0x06db3aaa) /* 0.428522746 */, 14 }, - - /* 768 */ { MAD_F(0x06de47f4) /* 0.429267841 */, 14 }, - /* 769 */ { MAD_F(0x06e15595) /* 0.430013259 */, 14 }, - /* 770 */ { MAD_F(0x06e4638d) /* 0.430759001 */, 14 }, - /* 771 */ { MAD_F(0x06e771db) /* 0.431505065 */, 14 }, - /* 772 */ { MAD_F(0x06ea807f) /* 0.432251452 */, 14 }, - /* 773 */ { MAD_F(0x06ed8f7b) /* 0.432998162 */, 14 }, - /* 774 */ { MAD_F(0x06f09ecc) /* 0.433745193 */, 14 }, - /* 775 */ { MAD_F(0x06f3ae75) /* 0.434492546 */, 14 }, - /* 776 */ { MAD_F(0x06f6be73) /* 0.435240221 */, 14 }, - /* 777 */ { MAD_F(0x06f9cec8) /* 0.435988217 */, 14 }, - /* 778 */ { MAD_F(0x06fcdf72) /* 0.436736534 */, 14 }, - /* 779 */ { MAD_F(0x06fff073) /* 0.437485172 */, 14 }, - /* 780 */ { MAD_F(0x070301ca) /* 0.438234130 */, 14 }, - /* 781 */ { MAD_F(0x07061377) /* 0.438983408 */, 14 }, - /* 782 */ { MAD_F(0x0709257a) /* 0.439733006 */, 14 }, - /* 783 */ { MAD_F(0x070c37d2) /* 0.440482924 */, 14 }, - - /* 784 */ { MAD_F(0x070f4a80) /* 0.441233161 */, 14 }, - /* 785 */ { MAD_F(0x07125d84) /* 0.441983717 */, 14 }, - /* 786 */ { MAD_F(0x071570de) /* 0.442734592 */, 14 }, - /* 787 */ { MAD_F(0x0718848d) /* 0.443485785 */, 14 }, - /* 788 */ { MAD_F(0x071b9891) /* 0.444237296 */, 14 }, - /* 789 */ { MAD_F(0x071eaceb) /* 0.444989126 */, 14 }, - /* 790 */ { MAD_F(0x0721c19a) /* 0.445741273 */, 14 }, - /* 791 */ { MAD_F(0x0724d69e) /* 0.446493738 */, 14 }, - /* 792 */ { MAD_F(0x0727ebf7) /* 0.447246519 */, 14 }, - /* 793 */ { MAD_F(0x072b01a6) /* 0.447999618 */, 14 }, - /* 794 */ { MAD_F(0x072e17a9) /* 0.448753033 */, 14 }, - /* 795 */ { MAD_F(0x07312e01) /* 0.449506765 */, 14 }, - /* 796 */ { MAD_F(0x073444ae) /* 0.450260813 */, 14 }, - /* 797 */ { MAD_F(0x07375bb0) /* 0.451015176 */, 14 }, - /* 798 */ { MAD_F(0x073a7307) /* 0.451769856 */, 14 }, - /* 799 */ { MAD_F(0x073d8ab2) /* 0.452524850 */, 14 }, - - /* 800 */ { MAD_F(0x0740a2b2) /* 0.453280160 */, 14 }, - /* 801 */ { MAD_F(0x0743bb06) /* 0.454035784 */, 14 }, - /* 802 */ { MAD_F(0x0746d3af) /* 0.454791723 */, 14 }, - /* 803 */ { MAD_F(0x0749ecac) /* 0.455547976 */, 14 }, - /* 804 */ { MAD_F(0x074d05fe) /* 0.456304543 */, 14 }, - /* 805 */ { MAD_F(0x07501fa3) /* 0.457061423 */, 14 }, - /* 806 */ { MAD_F(0x0753399d) /* 0.457818618 */, 14 }, - /* 807 */ { MAD_F(0x075653eb) /* 0.458576125 */, 14 }, - /* 808 */ { MAD_F(0x07596e8d) /* 0.459333946 */, 14 }, - /* 809 */ { MAD_F(0x075c8983) /* 0.460092079 */, 14 }, - /* 810 */ { MAD_F(0x075fa4cc) /* 0.460850524 */, 14 }, - /* 811 */ { MAD_F(0x0762c06a) /* 0.461609282 */, 14 }, - /* 812 */ { MAD_F(0x0765dc5b) /* 0.462368352 */, 14 }, - /* 813 */ { MAD_F(0x0768f8a0) /* 0.463127733 */, 14 }, - /* 814 */ { MAD_F(0x076c1538) /* 0.463887426 */, 14 }, - /* 815 */ { MAD_F(0x076f3224) /* 0.464647430 */, 14 }, - - /* 816 */ { MAD_F(0x07724f64) /* 0.465407744 */, 14 }, - /* 817 */ { MAD_F(0x07756cf7) /* 0.466168370 */, 14 }, - /* 818 */ { MAD_F(0x07788add) /* 0.466929306 */, 14 }, - /* 819 */ { MAD_F(0x077ba916) /* 0.467690552 */, 14 }, - /* 820 */ { MAD_F(0x077ec7a3) /* 0.468452108 */, 14 }, - /* 821 */ { MAD_F(0x0781e683) /* 0.469213973 */, 14 }, - /* 822 */ { MAD_F(0x078505b5) /* 0.469976148 */, 14 }, - /* 823 */ { MAD_F(0x0788253b) /* 0.470738632 */, 14 }, - /* 824 */ { MAD_F(0x078b4514) /* 0.471501425 */, 14 }, - /* 825 */ { MAD_F(0x078e653f) /* 0.472264527 */, 14 }, - /* 826 */ { MAD_F(0x079185be) /* 0.473027937 */, 14 }, - /* 827 */ { MAD_F(0x0794a68f) /* 0.473791655 */, 14 }, - /* 828 */ { MAD_F(0x0797c7b2) /* 0.474555681 */, 14 }, - /* 829 */ { MAD_F(0x079ae929) /* 0.475320014 */, 14 }, - /* 830 */ { MAD_F(0x079e0af1) /* 0.476084655 */, 14 }, - /* 831 */ { MAD_F(0x07a12d0c) /* 0.476849603 */, 14 }, - - /* 832 */ { MAD_F(0x07a44f7a) /* 0.477614858 */, 14 }, - /* 833 */ { MAD_F(0x07a7723a) /* 0.478380420 */, 14 }, - /* 834 */ { MAD_F(0x07aa954c) /* 0.479146288 */, 14 }, - /* 835 */ { MAD_F(0x07adb8b0) /* 0.479912463 */, 14 }, - /* 836 */ { MAD_F(0x07b0dc67) /* 0.480678943 */, 14 }, - /* 837 */ { MAD_F(0x07b4006f) /* 0.481445729 */, 14 }, - /* 838 */ { MAD_F(0x07b724ca) /* 0.482212820 */, 14 }, - /* 839 */ { MAD_F(0x07ba4976) /* 0.482980216 */, 14 }, - /* 840 */ { MAD_F(0x07bd6e75) /* 0.483747918 */, 14 }, - /* 841 */ { MAD_F(0x07c093c5) /* 0.484515924 */, 14 }, - /* 842 */ { MAD_F(0x07c3b967) /* 0.485284235 */, 14 }, - /* 843 */ { MAD_F(0x07c6df5a) /* 0.486052849 */, 14 }, - /* 844 */ { MAD_F(0x07ca059f) /* 0.486821768 */, 14 }, - /* 845 */ { MAD_F(0x07cd2c36) /* 0.487590991 */, 14 }, - /* 846 */ { MAD_F(0x07d0531e) /* 0.488360517 */, 14 }, - /* 847 */ { MAD_F(0x07d37a57) /* 0.489130346 */, 14 }, - - /* 848 */ { MAD_F(0x07d6a1e2) /* 0.489900479 */, 14 }, - /* 849 */ { MAD_F(0x07d9c9be) /* 0.490670914 */, 14 }, - /* 850 */ { MAD_F(0x07dcf1ec) /* 0.491441651 */, 14 }, - /* 851 */ { MAD_F(0x07e01a6a) /* 0.492212691 */, 14 }, - /* 852 */ { MAD_F(0x07e3433a) /* 0.492984033 */, 14 }, - /* 853 */ { MAD_F(0x07e66c5a) /* 0.493755677 */, 14 }, - /* 854 */ { MAD_F(0x07e995cc) /* 0.494527623 */, 14 }, - /* 855 */ { MAD_F(0x07ecbf8e) /* 0.495299870 */, 14 }, - /* 856 */ { MAD_F(0x07efe9a1) /* 0.496072418 */, 14 }, - /* 857 */ { MAD_F(0x07f31405) /* 0.496845266 */, 14 }, - /* 858 */ { MAD_F(0x07f63eba) /* 0.497618416 */, 14 }, - /* 859 */ { MAD_F(0x07f969c0) /* 0.498391866 */, 14 }, - /* 860 */ { MAD_F(0x07fc9516) /* 0.499165616 */, 14 }, - /* 861 */ { MAD_F(0x07ffc0bc) /* 0.499939666 */, 14 }, - /* 862 */ { MAD_F(0x04017659) /* 0.250357008 */, 15 }, - /* 863 */ { MAD_F(0x04030c7d) /* 0.250744333 */, 15 }, - - /* 864 */ { MAD_F(0x0404a2c9) /* 0.251131807 */, 15 }, - /* 865 */ { MAD_F(0x0406393d) /* 0.251519431 */, 15 }, - /* 866 */ { MAD_F(0x0407cfd9) /* 0.251907204 */, 15 }, - /* 867 */ { MAD_F(0x0409669d) /* 0.252295127 */, 15 }, - /* 868 */ { MAD_F(0x040afd89) /* 0.252683198 */, 15 }, - /* 869 */ { MAD_F(0x040c949e) /* 0.253071419 */, 15 }, - /* 870 */ { MAD_F(0x040e2bda) /* 0.253459789 */, 15 }, - /* 871 */ { MAD_F(0x040fc33e) /* 0.253848307 */, 15 }, - /* 872 */ { MAD_F(0x04115aca) /* 0.254236974 */, 15 }, - /* 873 */ { MAD_F(0x0412f27e) /* 0.254625790 */, 15 }, - /* 874 */ { MAD_F(0x04148a5a) /* 0.255014755 */, 15 }, - /* 875 */ { MAD_F(0x0416225d) /* 0.255403867 */, 15 }, - /* 876 */ { MAD_F(0x0417ba89) /* 0.255793128 */, 15 }, - /* 877 */ { MAD_F(0x041952dc) /* 0.256182537 */, 15 }, - /* 878 */ { MAD_F(0x041aeb57) /* 0.256572095 */, 15 }, - /* 879 */ { MAD_F(0x041c83fa) /* 0.256961800 */, 15 }, - - /* 880 */ { MAD_F(0x041e1cc4) /* 0.257351652 */, 15 }, - /* 881 */ { MAD_F(0x041fb5b6) /* 0.257741653 */, 15 }, - /* 882 */ { MAD_F(0x04214ed0) /* 0.258131801 */, 15 }, - /* 883 */ { MAD_F(0x0422e811) /* 0.258522097 */, 15 }, - /* 884 */ { MAD_F(0x04248179) /* 0.258912540 */, 15 }, - /* 885 */ { MAD_F(0x04261b0a) /* 0.259303130 */, 15 }, - /* 886 */ { MAD_F(0x0427b4c2) /* 0.259693868 */, 15 }, - /* 887 */ { MAD_F(0x04294ea1) /* 0.260084752 */, 15 }, - /* 888 */ { MAD_F(0x042ae8a7) /* 0.260475783 */, 15 }, - /* 889 */ { MAD_F(0x042c82d6) /* 0.260866961 */, 15 }, - /* 890 */ { MAD_F(0x042e1d2b) /* 0.261258286 */, 15 }, - /* 891 */ { MAD_F(0x042fb7a8) /* 0.261649758 */, 15 }, - /* 892 */ { MAD_F(0x0431524c) /* 0.262041376 */, 15 }, - /* 893 */ { MAD_F(0x0432ed17) /* 0.262433140 */, 15 }, - /* 894 */ { MAD_F(0x0434880a) /* 0.262825051 */, 15 }, - /* 895 */ { MAD_F(0x04362324) /* 0.263217107 */, 15 }, - - /* 896 */ { MAD_F(0x0437be65) /* 0.263609310 */, 15 }, - /* 897 */ { MAD_F(0x043959cd) /* 0.264001659 */, 15 }, - /* 898 */ { MAD_F(0x043af55d) /* 0.264394153 */, 15 }, - /* 899 */ { MAD_F(0x043c9113) /* 0.264786794 */, 15 }, - /* 900 */ { MAD_F(0x043e2cf1) /* 0.265179580 */, 15 }, - /* 901 */ { MAD_F(0x043fc8f6) /* 0.265572511 */, 15 }, - /* 902 */ { MAD_F(0x04416522) /* 0.265965588 */, 15 }, - /* 903 */ { MAD_F(0x04430174) /* 0.266358810 */, 15 }, - /* 904 */ { MAD_F(0x04449dee) /* 0.266752177 */, 15 }, - /* 905 */ { MAD_F(0x04463a8f) /* 0.267145689 */, 15 }, - /* 906 */ { MAD_F(0x0447d756) /* 0.267539347 */, 15 }, - /* 907 */ { MAD_F(0x04497445) /* 0.267933149 */, 15 }, - /* 908 */ { MAD_F(0x044b115a) /* 0.268327096 */, 15 }, - /* 909 */ { MAD_F(0x044cae96) /* 0.268721187 */, 15 }, - /* 910 */ { MAD_F(0x044e4bf9) /* 0.269115423 */, 15 }, - /* 911 */ { MAD_F(0x044fe983) /* 0.269509804 */, 15 }, - - /* 912 */ { MAD_F(0x04518733) /* 0.269904329 */, 15 }, - /* 913 */ { MAD_F(0x0453250a) /* 0.270298998 */, 15 }, - /* 914 */ { MAD_F(0x0454c308) /* 0.270693811 */, 15 }, - /* 915 */ { MAD_F(0x0456612d) /* 0.271088768 */, 15 }, - /* 916 */ { MAD_F(0x0457ff78) /* 0.271483869 */, 15 }, - /* 917 */ { MAD_F(0x04599dea) /* 0.271879114 */, 15 }, - /* 918 */ { MAD_F(0x045b3c82) /* 0.272274503 */, 15 }, - /* 919 */ { MAD_F(0x045cdb41) /* 0.272670035 */, 15 }, - /* 920 */ { MAD_F(0x045e7a26) /* 0.273065710 */, 15 }, - /* 921 */ { MAD_F(0x04601932) /* 0.273461530 */, 15 }, - /* 922 */ { MAD_F(0x0461b864) /* 0.273857492 */, 15 }, - /* 923 */ { MAD_F(0x046357bd) /* 0.274253597 */, 15 }, - /* 924 */ { MAD_F(0x0464f73c) /* 0.274649846 */, 15 }, - /* 925 */ { MAD_F(0x046696e2) /* 0.275046238 */, 15 }, - /* 926 */ { MAD_F(0x046836ae) /* 0.275442772 */, 15 }, - /* 927 */ { MAD_F(0x0469d6a0) /* 0.275839449 */, 15 }, - - /* 928 */ { MAD_F(0x046b76b9) /* 0.276236269 */, 15 }, - /* 929 */ { MAD_F(0x046d16f7) /* 0.276633232 */, 15 }, - /* 930 */ { MAD_F(0x046eb75c) /* 0.277030337 */, 15 }, - /* 931 */ { MAD_F(0x047057e8) /* 0.277427584 */, 15 }, - /* 932 */ { MAD_F(0x0471f899) /* 0.277824973 */, 15 }, - /* 933 */ { MAD_F(0x04739971) /* 0.278222505 */, 15 }, - /* 934 */ { MAD_F(0x04753a6f) /* 0.278620179 */, 15 }, - /* 935 */ { MAD_F(0x0476db92) /* 0.279017995 */, 15 }, - /* 936 */ { MAD_F(0x04787cdc) /* 0.279415952 */, 15 }, - /* 937 */ { MAD_F(0x047a1e4c) /* 0.279814051 */, 15 }, - /* 938 */ { MAD_F(0x047bbfe2) /* 0.280212292 */, 15 }, - /* 939 */ { MAD_F(0x047d619e) /* 0.280610675 */, 15 }, - /* 940 */ { MAD_F(0x047f0380) /* 0.281009199 */, 15 }, - /* 941 */ { MAD_F(0x0480a588) /* 0.281407864 */, 15 }, - /* 942 */ { MAD_F(0x048247b6) /* 0.281806670 */, 15 }, - /* 943 */ { MAD_F(0x0483ea0a) /* 0.282205618 */, 15 }, - - /* 944 */ { MAD_F(0x04858c83) /* 0.282604707 */, 15 }, - /* 945 */ { MAD_F(0x04872f22) /* 0.283003936 */, 15 }, - /* 946 */ { MAD_F(0x0488d1e8) /* 0.283403307 */, 15 }, - /* 947 */ { MAD_F(0x048a74d3) /* 0.283802818 */, 15 }, - /* 948 */ { MAD_F(0x048c17e3) /* 0.284202470 */, 15 }, - /* 949 */ { MAD_F(0x048dbb1a) /* 0.284602263 */, 15 }, - /* 950 */ { MAD_F(0x048f5e76) /* 0.285002195 */, 15 }, - /* 951 */ { MAD_F(0x049101f8) /* 0.285402269 */, 15 }, - /* 952 */ { MAD_F(0x0492a59f) /* 0.285802482 */, 15 }, - /* 953 */ { MAD_F(0x0494496c) /* 0.286202836 */, 15 }, - /* 954 */ { MAD_F(0x0495ed5f) /* 0.286603329 */, 15 }, - /* 955 */ { MAD_F(0x04979177) /* 0.287003963 */, 15 }, - /* 956 */ { MAD_F(0x049935b5) /* 0.287404737 */, 15 }, - /* 957 */ { MAD_F(0x049ada19) /* 0.287805650 */, 15 }, - /* 958 */ { MAD_F(0x049c7ea1) /* 0.288206703 */, 15 }, - /* 959 */ { MAD_F(0x049e2350) /* 0.288607895 */, 15 }, - - /* 960 */ { MAD_F(0x049fc824) /* 0.289009227 */, 15 }, - /* 961 */ { MAD_F(0x04a16d1d) /* 0.289410699 */, 15 }, - /* 962 */ { MAD_F(0x04a3123b) /* 0.289812309 */, 15 }, - /* 963 */ { MAD_F(0x04a4b77f) /* 0.290214059 */, 15 }, - /* 964 */ { MAD_F(0x04a65ce8) /* 0.290615948 */, 15 }, - /* 965 */ { MAD_F(0x04a80277) /* 0.291017976 */, 15 }, - /* 966 */ { MAD_F(0x04a9a82b) /* 0.291420143 */, 15 }, - /* 967 */ { MAD_F(0x04ab4e04) /* 0.291822449 */, 15 }, - /* 968 */ { MAD_F(0x04acf402) /* 0.292224893 */, 15 }, - /* 969 */ { MAD_F(0x04ae9a26) /* 0.292627476 */, 15 }, - /* 970 */ { MAD_F(0x04b0406e) /* 0.293030197 */, 15 }, - /* 971 */ { MAD_F(0x04b1e6dc) /* 0.293433057 */, 15 }, - /* 972 */ { MAD_F(0x04b38d6f) /* 0.293836055 */, 15 }, - /* 973 */ { MAD_F(0x04b53427) /* 0.294239192 */, 15 }, - /* 974 */ { MAD_F(0x04b6db05) /* 0.294642466 */, 15 }, - /* 975 */ { MAD_F(0x04b88207) /* 0.295045879 */, 15 }, - - /* 976 */ { MAD_F(0x04ba292e) /* 0.295449429 */, 15 }, - /* 977 */ { MAD_F(0x04bbd07a) /* 0.295853118 */, 15 }, - /* 978 */ { MAD_F(0x04bd77ec) /* 0.296256944 */, 15 }, - /* 979 */ { MAD_F(0x04bf1f82) /* 0.296660907 */, 15 }, - /* 980 */ { MAD_F(0x04c0c73d) /* 0.297065009 */, 15 }, - /* 981 */ { MAD_F(0x04c26f1d) /* 0.297469248 */, 15 }, - /* 982 */ { MAD_F(0x04c41722) /* 0.297873624 */, 15 }, - /* 983 */ { MAD_F(0x04c5bf4c) /* 0.298278137 */, 15 }, - /* 984 */ { MAD_F(0x04c7679a) /* 0.298682788 */, 15 }, - /* 985 */ { MAD_F(0x04c9100d) /* 0.299087576 */, 15 }, - /* 986 */ { MAD_F(0x04cab8a6) /* 0.299492500 */, 15 }, - /* 987 */ { MAD_F(0x04cc6163) /* 0.299897562 */, 15 }, - /* 988 */ { MAD_F(0x04ce0a44) /* 0.300302761 */, 15 }, - /* 989 */ { MAD_F(0x04cfb34b) /* 0.300708096 */, 15 }, - /* 990 */ { MAD_F(0x04d15c76) /* 0.301113568 */, 15 }, - /* 991 */ { MAD_F(0x04d305c5) /* 0.301519176 */, 15 }, - - /* 992 */ { MAD_F(0x04d4af3a) /* 0.301924921 */, 15 }, - /* 993 */ { MAD_F(0x04d658d2) /* 0.302330802 */, 15 }, - /* 994 */ { MAD_F(0x04d80290) /* 0.302736820 */, 15 }, - /* 995 */ { MAD_F(0x04d9ac72) /* 0.303142973 */, 15 }, - /* 996 */ { MAD_F(0x04db5679) /* 0.303549263 */, 15 }, - /* 997 */ { MAD_F(0x04dd00a4) /* 0.303955689 */, 15 }, - /* 998 */ { MAD_F(0x04deaaf3) /* 0.304362251 */, 15 }, - /* 999 */ { MAD_F(0x04e05567) /* 0.304768948 */, 15 }, - /* 1000 */ { MAD_F(0x04e20000) /* 0.305175781 */, 15 }, - /* 1001 */ { MAD_F(0x04e3aabd) /* 0.305582750 */, 15 }, - /* 1002 */ { MAD_F(0x04e5559e) /* 0.305989854 */, 15 }, - /* 1003 */ { MAD_F(0x04e700a3) /* 0.306397094 */, 15 }, - /* 1004 */ { MAD_F(0x04e8abcd) /* 0.306804470 */, 15 }, - /* 1005 */ { MAD_F(0x04ea571c) /* 0.307211980 */, 15 }, - /* 1006 */ { MAD_F(0x04ec028e) /* 0.307619626 */, 15 }, - /* 1007 */ { MAD_F(0x04edae25) /* 0.308027406 */, 15 }, - - /* 1008 */ { MAD_F(0x04ef59e0) /* 0.308435322 */, 15 }, - /* 1009 */ { MAD_F(0x04f105bf) /* 0.308843373 */, 15 }, - /* 1010 */ { MAD_F(0x04f2b1c3) /* 0.309251558 */, 15 }, - /* 1011 */ { MAD_F(0x04f45dea) /* 0.309659879 */, 15 }, - /* 1012 */ { MAD_F(0x04f60a36) /* 0.310068333 */, 15 }, - /* 1013 */ { MAD_F(0x04f7b6a6) /* 0.310476923 */, 15 }, - /* 1014 */ { MAD_F(0x04f9633a) /* 0.310885647 */, 15 }, - /* 1015 */ { MAD_F(0x04fb0ff2) /* 0.311294505 */, 15 }, - /* 1016 */ { MAD_F(0x04fcbcce) /* 0.311703498 */, 15 }, - /* 1017 */ { MAD_F(0x04fe69ce) /* 0.312112625 */, 15 }, - /* 1018 */ { MAD_F(0x050016f3) /* 0.312521885 */, 15 }, - /* 1019 */ { MAD_F(0x0501c43b) /* 0.312931280 */, 15 }, - /* 1020 */ { MAD_F(0x050371a7) /* 0.313340809 */, 15 }, - /* 1021 */ { MAD_F(0x05051f37) /* 0.313750472 */, 15 }, - /* 1022 */ { MAD_F(0x0506cceb) /* 0.314160269 */, 15 }, - /* 1023 */ { MAD_F(0x05087ac2) /* 0.314570199 */, 15 }, - - /* 1024 */ { MAD_F(0x050a28be) /* 0.314980262 */, 15 }, - /* 1025 */ { MAD_F(0x050bd6de) /* 0.315390460 */, 15 }, - /* 1026 */ { MAD_F(0x050d8521) /* 0.315800790 */, 15 }, - /* 1027 */ { MAD_F(0x050f3388) /* 0.316211255 */, 15 }, - /* 1028 */ { MAD_F(0x0510e213) /* 0.316621852 */, 15 }, - /* 1029 */ { MAD_F(0x051290c2) /* 0.317032582 */, 15 }, - /* 1030 */ { MAD_F(0x05143f94) /* 0.317443446 */, 15 }, - /* 1031 */ { MAD_F(0x0515ee8a) /* 0.317854442 */, 15 }, - /* 1032 */ { MAD_F(0x05179da4) /* 0.318265572 */, 15 }, - /* 1033 */ { MAD_F(0x05194ce1) /* 0.318676834 */, 15 }, - /* 1034 */ { MAD_F(0x051afc42) /* 0.319088229 */, 15 }, - /* 1035 */ { MAD_F(0x051cabc7) /* 0.319499756 */, 15 }, - /* 1036 */ { MAD_F(0x051e5b6f) /* 0.319911417 */, 15 }, - /* 1037 */ { MAD_F(0x05200b3a) /* 0.320323209 */, 15 }, - /* 1038 */ { MAD_F(0x0521bb2a) /* 0.320735134 */, 15 }, - /* 1039 */ { MAD_F(0x05236b3d) /* 0.321147192 */, 15 }, - - /* 1040 */ { MAD_F(0x05251b73) /* 0.321559381 */, 15 }, - /* 1041 */ { MAD_F(0x0526cbcd) /* 0.321971703 */, 15 }, - /* 1042 */ { MAD_F(0x05287c4a) /* 0.322384156 */, 15 }, - /* 1043 */ { MAD_F(0x052a2cea) /* 0.322796742 */, 15 }, - /* 1044 */ { MAD_F(0x052bddae) /* 0.323209460 */, 15 }, - /* 1045 */ { MAD_F(0x052d8e96) /* 0.323622309 */, 15 }, - /* 1046 */ { MAD_F(0x052f3fa1) /* 0.324035290 */, 15 }, - /* 1047 */ { MAD_F(0x0530f0cf) /* 0.324448403 */, 15 }, - /* 1048 */ { MAD_F(0x0532a220) /* 0.324861647 */, 15 }, - /* 1049 */ { MAD_F(0x05345395) /* 0.325275023 */, 15 }, - /* 1050 */ { MAD_F(0x0536052d) /* 0.325688530 */, 15 }, - /* 1051 */ { MAD_F(0x0537b6e8) /* 0.326102168 */, 15 }, - /* 1052 */ { MAD_F(0x053968c6) /* 0.326515938 */, 15 }, - /* 1053 */ { MAD_F(0x053b1ac8) /* 0.326929839 */, 15 }, - /* 1054 */ { MAD_F(0x053ccced) /* 0.327343870 */, 15 }, - /* 1055 */ { MAD_F(0x053e7f35) /* 0.327758033 */, 15 }, - - /* 1056 */ { MAD_F(0x054031a0) /* 0.328172327 */, 15 }, - /* 1057 */ { MAD_F(0x0541e42e) /* 0.328586751 */, 15 }, - /* 1058 */ { MAD_F(0x054396df) /* 0.329001306 */, 15 }, - /* 1059 */ { MAD_F(0x054549b4) /* 0.329415992 */, 15 }, - /* 1060 */ { MAD_F(0x0546fcab) /* 0.329830808 */, 15 }, - /* 1061 */ { MAD_F(0x0548afc6) /* 0.330245755 */, 15 }, - /* 1062 */ { MAD_F(0x054a6303) /* 0.330660832 */, 15 }, - /* 1063 */ { MAD_F(0x054c1663) /* 0.331076039 */, 15 }, - /* 1064 */ { MAD_F(0x054dc9e7) /* 0.331491377 */, 15 }, - /* 1065 */ { MAD_F(0x054f7d8d) /* 0.331906845 */, 15 }, - /* 1066 */ { MAD_F(0x05513156) /* 0.332322443 */, 15 }, - /* 1067 */ { MAD_F(0x0552e542) /* 0.332738170 */, 15 }, - /* 1068 */ { MAD_F(0x05549951) /* 0.333154028 */, 15 }, - /* 1069 */ { MAD_F(0x05564d83) /* 0.333570016 */, 15 }, - /* 1070 */ { MAD_F(0x055801d8) /* 0.333986133 */, 15 }, - /* 1071 */ { MAD_F(0x0559b64f) /* 0.334402380 */, 15 }, - - /* 1072 */ { MAD_F(0x055b6ae9) /* 0.334818756 */, 15 }, - /* 1073 */ { MAD_F(0x055d1fa6) /* 0.335235262 */, 15 }, - /* 1074 */ { MAD_F(0x055ed486) /* 0.335651898 */, 15 }, - /* 1075 */ { MAD_F(0x05608988) /* 0.336068662 */, 15 }, - /* 1076 */ { MAD_F(0x05623ead) /* 0.336485556 */, 15 }, - /* 1077 */ { MAD_F(0x0563f3f5) /* 0.336902579 */, 15 }, - /* 1078 */ { MAD_F(0x0565a960) /* 0.337319732 */, 15 }, - /* 1079 */ { MAD_F(0x05675eed) /* 0.337737013 */, 15 }, - /* 1080 */ { MAD_F(0x0569149c) /* 0.338154423 */, 15 }, - /* 1081 */ { MAD_F(0x056aca6f) /* 0.338571962 */, 15 }, - /* 1082 */ { MAD_F(0x056c8064) /* 0.338989630 */, 15 }, - /* 1083 */ { MAD_F(0x056e367b) /* 0.339407426 */, 15 }, - /* 1084 */ { MAD_F(0x056fecb5) /* 0.339825351 */, 15 }, - /* 1085 */ { MAD_F(0x0571a311) /* 0.340243405 */, 15 }, - /* 1086 */ { MAD_F(0x05735990) /* 0.340661587 */, 15 }, - /* 1087 */ { MAD_F(0x05751032) /* 0.341079898 */, 15 }, - - /* 1088 */ { MAD_F(0x0576c6f5) /* 0.341498336 */, 15 }, - /* 1089 */ { MAD_F(0x05787ddc) /* 0.341916903 */, 15 }, - /* 1090 */ { MAD_F(0x057a34e4) /* 0.342335598 */, 15 }, - /* 1091 */ { MAD_F(0x057bec0f) /* 0.342754421 */, 15 }, - /* 1092 */ { MAD_F(0x057da35d) /* 0.343173373 */, 15 }, - /* 1093 */ { MAD_F(0x057f5acc) /* 0.343592452 */, 15 }, - /* 1094 */ { MAD_F(0x0581125e) /* 0.344011659 */, 15 }, - /* 1095 */ { MAD_F(0x0582ca12) /* 0.344430993 */, 15 }, - /* 1096 */ { MAD_F(0x058481e9) /* 0.344850455 */, 15 }, - /* 1097 */ { MAD_F(0x058639e2) /* 0.345270045 */, 15 }, - /* 1098 */ { MAD_F(0x0587f1fd) /* 0.345689763 */, 15 }, - /* 1099 */ { MAD_F(0x0589aa3a) /* 0.346109608 */, 15 }, - /* 1100 */ { MAD_F(0x058b629a) /* 0.346529580 */, 15 }, - /* 1101 */ { MAD_F(0x058d1b1b) /* 0.346949679 */, 15 }, - /* 1102 */ { MAD_F(0x058ed3bf) /* 0.347369906 */, 15 }, - /* 1103 */ { MAD_F(0x05908c85) /* 0.347790260 */, 15 }, - - /* 1104 */ { MAD_F(0x0592456d) /* 0.348210741 */, 15 }, - /* 1105 */ { MAD_F(0x0593fe77) /* 0.348631348 */, 15 }, - /* 1106 */ { MAD_F(0x0595b7a3) /* 0.349052083 */, 15 }, - /* 1107 */ { MAD_F(0x059770f1) /* 0.349472945 */, 15 }, - /* 1108 */ { MAD_F(0x05992a61) /* 0.349893933 */, 15 }, - /* 1109 */ { MAD_F(0x059ae3f3) /* 0.350315048 */, 15 }, - /* 1110 */ { MAD_F(0x059c9da8) /* 0.350736290 */, 15 }, - /* 1111 */ { MAD_F(0x059e577e) /* 0.351157658 */, 15 }, - /* 1112 */ { MAD_F(0x05a01176) /* 0.351579152 */, 15 }, - /* 1113 */ { MAD_F(0x05a1cb90) /* 0.352000773 */, 15 }, - /* 1114 */ { MAD_F(0x05a385cc) /* 0.352422520 */, 15 }, - /* 1115 */ { MAD_F(0x05a5402a) /* 0.352844394 */, 15 }, - /* 1116 */ { MAD_F(0x05a6faa9) /* 0.353266393 */, 15 }, - /* 1117 */ { MAD_F(0x05a8b54b) /* 0.353688519 */, 15 }, - /* 1118 */ { MAD_F(0x05aa700e) /* 0.354110771 */, 15 }, - /* 1119 */ { MAD_F(0x05ac2af3) /* 0.354533148 */, 15 }, - - /* 1120 */ { MAD_F(0x05ade5fa) /* 0.354955651 */, 15 }, - /* 1121 */ { MAD_F(0x05afa123) /* 0.355378281 */, 15 }, - /* 1122 */ { MAD_F(0x05b15c6d) /* 0.355801035 */, 15 }, - /* 1123 */ { MAD_F(0x05b317d9) /* 0.356223916 */, 15 }, - /* 1124 */ { MAD_F(0x05b4d367) /* 0.356646922 */, 15 }, - /* 1125 */ { MAD_F(0x05b68f16) /* 0.357070053 */, 15 }, - /* 1126 */ { MAD_F(0x05b84ae7) /* 0.357493310 */, 15 }, - /* 1127 */ { MAD_F(0x05ba06da) /* 0.357916692 */, 15 }, - /* 1128 */ { MAD_F(0x05bbc2ef) /* 0.358340200 */, 15 }, - /* 1129 */ { MAD_F(0x05bd7f25) /* 0.358763832 */, 15 }, - /* 1130 */ { MAD_F(0x05bf3b7c) /* 0.359187590 */, 15 }, - /* 1131 */ { MAD_F(0x05c0f7f5) /* 0.359611472 */, 15 }, - /* 1132 */ { MAD_F(0x05c2b490) /* 0.360035480 */, 15 }, - /* 1133 */ { MAD_F(0x05c4714c) /* 0.360459613 */, 15 }, - /* 1134 */ { MAD_F(0x05c62e2a) /* 0.360883870 */, 15 }, - /* 1135 */ { MAD_F(0x05c7eb29) /* 0.361308252 */, 15 }, - - /* 1136 */ { MAD_F(0x05c9a84a) /* 0.361732758 */, 15 }, - /* 1137 */ { MAD_F(0x05cb658c) /* 0.362157390 */, 15 }, - /* 1138 */ { MAD_F(0x05cd22ef) /* 0.362582145 */, 15 }, - /* 1139 */ { MAD_F(0x05cee074) /* 0.363007026 */, 15 }, - /* 1140 */ { MAD_F(0x05d09e1b) /* 0.363432030 */, 15 }, - /* 1141 */ { MAD_F(0x05d25be2) /* 0.363857159 */, 15 }, - /* 1142 */ { MAD_F(0x05d419cb) /* 0.364282412 */, 15 }, - /* 1143 */ { MAD_F(0x05d5d7d5) /* 0.364707789 */, 15 }, - /* 1144 */ { MAD_F(0x05d79601) /* 0.365133291 */, 15 }, - /* 1145 */ { MAD_F(0x05d9544e) /* 0.365558916 */, 15 }, - /* 1146 */ { MAD_F(0x05db12bc) /* 0.365984665 */, 15 }, - /* 1147 */ { MAD_F(0x05dcd14c) /* 0.366410538 */, 15 }, - /* 1148 */ { MAD_F(0x05de8ffc) /* 0.366836535 */, 15 }, - /* 1149 */ { MAD_F(0x05e04ece) /* 0.367262655 */, 15 }, - /* 1150 */ { MAD_F(0x05e20dc1) /* 0.367688900 */, 15 }, - /* 1151 */ { MAD_F(0x05e3ccd5) /* 0.368115267 */, 15 }, - - /* 1152 */ { MAD_F(0x05e58c0b) /* 0.368541759 */, 15 }, - /* 1153 */ { MAD_F(0x05e74b61) /* 0.368968373 */, 15 }, - /* 1154 */ { MAD_F(0x05e90ad9) /* 0.369395111 */, 15 }, - /* 1155 */ { MAD_F(0x05eaca72) /* 0.369821973 */, 15 }, - /* 1156 */ { MAD_F(0x05ec8a2b) /* 0.370248957 */, 15 }, - /* 1157 */ { MAD_F(0x05ee4a06) /* 0.370676065 */, 15 }, - /* 1158 */ { MAD_F(0x05f00a02) /* 0.371103295 */, 15 }, - /* 1159 */ { MAD_F(0x05f1ca1f) /* 0.371530649 */, 15 }, - /* 1160 */ { MAD_F(0x05f38a5d) /* 0.371958126 */, 15 }, - /* 1161 */ { MAD_F(0x05f54abc) /* 0.372385725 */, 15 }, - /* 1162 */ { MAD_F(0x05f70b3c) /* 0.372813448 */, 15 }, - /* 1163 */ { MAD_F(0x05f8cbdc) /* 0.373241292 */, 15 }, - /* 1164 */ { MAD_F(0x05fa8c9e) /* 0.373669260 */, 15 }, - /* 1165 */ { MAD_F(0x05fc4d81) /* 0.374097350 */, 15 }, - /* 1166 */ { MAD_F(0x05fe0e84) /* 0.374525563 */, 15 }, - /* 1167 */ { MAD_F(0x05ffcfa8) /* 0.374953898 */, 15 }, - - /* 1168 */ { MAD_F(0x060190ee) /* 0.375382356 */, 15 }, - /* 1169 */ { MAD_F(0x06035254) /* 0.375810936 */, 15 }, - /* 1170 */ { MAD_F(0x060513da) /* 0.376239638 */, 15 }, - /* 1171 */ { MAD_F(0x0606d582) /* 0.376668462 */, 15 }, - /* 1172 */ { MAD_F(0x0608974a) /* 0.377097408 */, 15 }, - /* 1173 */ { MAD_F(0x060a5934) /* 0.377526476 */, 15 }, - /* 1174 */ { MAD_F(0x060c1b3d) /* 0.377955667 */, 15 }, - /* 1175 */ { MAD_F(0x060ddd68) /* 0.378384979 */, 15 }, - /* 1176 */ { MAD_F(0x060f9fb3) /* 0.378814413 */, 15 }, - /* 1177 */ { MAD_F(0x0611621f) /* 0.379243968 */, 15 }, - /* 1178 */ { MAD_F(0x061324ac) /* 0.379673646 */, 15 }, - /* 1179 */ { MAD_F(0x0614e759) /* 0.380103444 */, 15 }, - /* 1180 */ { MAD_F(0x0616aa27) /* 0.380533365 */, 15 }, - /* 1181 */ { MAD_F(0x06186d16) /* 0.380963407 */, 15 }, - /* 1182 */ { MAD_F(0x061a3025) /* 0.381393570 */, 15 }, - /* 1183 */ { MAD_F(0x061bf354) /* 0.381823855 */, 15 }, - - /* 1184 */ { MAD_F(0x061db6a5) /* 0.382254261 */, 15 }, - /* 1185 */ { MAD_F(0x061f7a15) /* 0.382684788 */, 15 }, - /* 1186 */ { MAD_F(0x06213da7) /* 0.383115436 */, 15 }, - /* 1187 */ { MAD_F(0x06230158) /* 0.383546205 */, 15 }, - /* 1188 */ { MAD_F(0x0624c52a) /* 0.383977096 */, 15 }, - /* 1189 */ { MAD_F(0x0626891d) /* 0.384408107 */, 15 }, - /* 1190 */ { MAD_F(0x06284d30) /* 0.384839239 */, 15 }, - /* 1191 */ { MAD_F(0x062a1164) /* 0.385270492 */, 15 }, - /* 1192 */ { MAD_F(0x062bd5b8) /* 0.385701865 */, 15 }, - /* 1193 */ { MAD_F(0x062d9a2c) /* 0.386133359 */, 15 }, - /* 1194 */ { MAD_F(0x062f5ec1) /* 0.386564974 */, 15 }, - /* 1195 */ { MAD_F(0x06312376) /* 0.386996709 */, 15 }, - /* 1196 */ { MAD_F(0x0632e84b) /* 0.387428565 */, 15 }, - /* 1197 */ { MAD_F(0x0634ad41) /* 0.387860541 */, 15 }, - /* 1198 */ { MAD_F(0x06367257) /* 0.388292637 */, 15 }, - /* 1199 */ { MAD_F(0x0638378d) /* 0.388724854 */, 15 }, - - /* 1200 */ { MAD_F(0x0639fce4) /* 0.389157191 */, 15 }, - /* 1201 */ { MAD_F(0x063bc25b) /* 0.389589648 */, 15 }, - /* 1202 */ { MAD_F(0x063d87f2) /* 0.390022225 */, 15 }, - /* 1203 */ { MAD_F(0x063f4da9) /* 0.390454922 */, 15 }, - /* 1204 */ { MAD_F(0x06411380) /* 0.390887739 */, 15 }, - /* 1205 */ { MAD_F(0x0642d978) /* 0.391320675 */, 15 }, - /* 1206 */ { MAD_F(0x06449f8f) /* 0.391753732 */, 15 }, - /* 1207 */ { MAD_F(0x064665c7) /* 0.392186908 */, 15 }, - /* 1208 */ { MAD_F(0x06482c1f) /* 0.392620204 */, 15 }, - /* 1209 */ { MAD_F(0x0649f297) /* 0.393053619 */, 15 }, - /* 1210 */ { MAD_F(0x064bb92f) /* 0.393487154 */, 15 }, - /* 1211 */ { MAD_F(0x064d7fe8) /* 0.393920808 */, 15 }, - /* 1212 */ { MAD_F(0x064f46c0) /* 0.394354582 */, 15 }, - /* 1213 */ { MAD_F(0x06510db8) /* 0.394788475 */, 15 }, - /* 1214 */ { MAD_F(0x0652d4d0) /* 0.395222488 */, 15 }, - /* 1215 */ { MAD_F(0x06549c09) /* 0.395656619 */, 15 }, - - /* 1216 */ { MAD_F(0x06566361) /* 0.396090870 */, 15 }, - /* 1217 */ { MAD_F(0x06582ad9) /* 0.396525239 */, 15 }, - /* 1218 */ { MAD_F(0x0659f271) /* 0.396959728 */, 15 }, - /* 1219 */ { MAD_F(0x065bba29) /* 0.397394336 */, 15 }, - /* 1220 */ { MAD_F(0x065d8201) /* 0.397829062 */, 15 }, - /* 1221 */ { MAD_F(0x065f49f9) /* 0.398263907 */, 15 }, - /* 1222 */ { MAD_F(0x06611211) /* 0.398698871 */, 15 }, - /* 1223 */ { MAD_F(0x0662da49) /* 0.399133954 */, 15 }, - /* 1224 */ { MAD_F(0x0664a2a0) /* 0.399569155 */, 15 }, - /* 1225 */ { MAD_F(0x06666b17) /* 0.400004475 */, 15 }, - /* 1226 */ { MAD_F(0x066833ae) /* 0.400439913 */, 15 }, - /* 1227 */ { MAD_F(0x0669fc65) /* 0.400875470 */, 15 }, - /* 1228 */ { MAD_F(0x066bc53c) /* 0.401311145 */, 15 }, - /* 1229 */ { MAD_F(0x066d8e32) /* 0.401746938 */, 15 }, - /* 1230 */ { MAD_F(0x066f5748) /* 0.402182850 */, 15 }, - /* 1231 */ { MAD_F(0x0671207e) /* 0.402618879 */, 15 }, - - /* 1232 */ { MAD_F(0x0672e9d4) /* 0.403055027 */, 15 }, - /* 1233 */ { MAD_F(0x0674b349) /* 0.403491293 */, 15 }, - /* 1234 */ { MAD_F(0x06767cde) /* 0.403927676 */, 15 }, - /* 1235 */ { MAD_F(0x06784692) /* 0.404364178 */, 15 }, - /* 1236 */ { MAD_F(0x067a1066) /* 0.404800797 */, 15 }, - /* 1237 */ { MAD_F(0x067bda5a) /* 0.405237535 */, 15 }, - /* 1238 */ { MAD_F(0x067da46d) /* 0.405674390 */, 15 }, - /* 1239 */ { MAD_F(0x067f6ea0) /* 0.406111362 */, 15 }, - /* 1240 */ { MAD_F(0x068138f3) /* 0.406548452 */, 15 }, - /* 1241 */ { MAD_F(0x06830365) /* 0.406985660 */, 15 }, - /* 1242 */ { MAD_F(0x0684cdf6) /* 0.407422985 */, 15 }, - /* 1243 */ { MAD_F(0x068698a8) /* 0.407860427 */, 15 }, - /* 1244 */ { MAD_F(0x06886378) /* 0.408297987 */, 15 }, - /* 1245 */ { MAD_F(0x068a2e68) /* 0.408735664 */, 15 }, - /* 1246 */ { MAD_F(0x068bf978) /* 0.409173458 */, 15 }, - /* 1247 */ { MAD_F(0x068dc4a7) /* 0.409611370 */, 15 }, - - /* 1248 */ { MAD_F(0x068f8ff5) /* 0.410049398 */, 15 }, - /* 1249 */ { MAD_F(0x06915b63) /* 0.410487544 */, 15 }, - /* 1250 */ { MAD_F(0x069326f0) /* 0.410925806 */, 15 }, - /* 1251 */ { MAD_F(0x0694f29c) /* 0.411364185 */, 15 }, - /* 1252 */ { MAD_F(0x0696be68) /* 0.411802681 */, 15 }, - /* 1253 */ { MAD_F(0x06988a54) /* 0.412241294 */, 15 }, - /* 1254 */ { MAD_F(0x069a565e) /* 0.412680024 */, 15 }, - /* 1255 */ { MAD_F(0x069c2288) /* 0.413118870 */, 15 }, - /* 1256 */ { MAD_F(0x069deed1) /* 0.413557833 */, 15 }, - /* 1257 */ { MAD_F(0x069fbb3a) /* 0.413996912 */, 15 }, - /* 1258 */ { MAD_F(0x06a187c1) /* 0.414436108 */, 15 }, - /* 1259 */ { MAD_F(0x06a35468) /* 0.414875420 */, 15 }, - /* 1260 */ { MAD_F(0x06a5212f) /* 0.415314849 */, 15 }, - /* 1261 */ { MAD_F(0x06a6ee14) /* 0.415754393 */, 15 }, - /* 1262 */ { MAD_F(0x06a8bb18) /* 0.416194054 */, 15 }, - /* 1263 */ { MAD_F(0x06aa883c) /* 0.416633831 */, 15 }, - - /* 1264 */ { MAD_F(0x06ac557f) /* 0.417073724 */, 15 }, - /* 1265 */ { MAD_F(0x06ae22e1) /* 0.417513734 */, 15 }, - /* 1266 */ { MAD_F(0x06aff062) /* 0.417953859 */, 15 }, - /* 1267 */ { MAD_F(0x06b1be03) /* 0.418394100 */, 15 }, - /* 1268 */ { MAD_F(0x06b38bc2) /* 0.418834457 */, 15 }, - /* 1269 */ { MAD_F(0x06b559a1) /* 0.419274929 */, 15 }, - /* 1270 */ { MAD_F(0x06b7279e) /* 0.419715518 */, 15 }, - /* 1271 */ { MAD_F(0x06b8f5bb) /* 0.420156222 */, 15 }, - /* 1272 */ { MAD_F(0x06bac3f6) /* 0.420597041 */, 15 }, - /* 1273 */ { MAD_F(0x06bc9251) /* 0.421037977 */, 15 }, - /* 1274 */ { MAD_F(0x06be60cb) /* 0.421479027 */, 15 }, - /* 1275 */ { MAD_F(0x06c02f63) /* 0.421920193 */, 15 }, - /* 1276 */ { MAD_F(0x06c1fe1b) /* 0.422361475 */, 15 }, - /* 1277 */ { MAD_F(0x06c3ccf1) /* 0.422802871 */, 15 }, - /* 1278 */ { MAD_F(0x06c59be7) /* 0.423244383 */, 15 }, - /* 1279 */ { MAD_F(0x06c76afb) /* 0.423686010 */, 15 }, - - /* 1280 */ { MAD_F(0x06c93a2e) /* 0.424127753 */, 15 }, - /* 1281 */ { MAD_F(0x06cb0981) /* 0.424569610 */, 15 }, - /* 1282 */ { MAD_F(0x06ccd8f2) /* 0.425011582 */, 15 }, - /* 1283 */ { MAD_F(0x06cea881) /* 0.425453669 */, 15 }, - /* 1284 */ { MAD_F(0x06d07830) /* 0.425895871 */, 15 }, - /* 1285 */ { MAD_F(0x06d247fe) /* 0.426338188 */, 15 }, - /* 1286 */ { MAD_F(0x06d417ea) /* 0.426780620 */, 15 }, - /* 1287 */ { MAD_F(0x06d5e7f5) /* 0.427223166 */, 15 }, - /* 1288 */ { MAD_F(0x06d7b81f) /* 0.427665827 */, 15 }, - /* 1289 */ { MAD_F(0x06d98868) /* 0.428108603 */, 15 }, - /* 1290 */ { MAD_F(0x06db58cf) /* 0.428551493 */, 15 }, - /* 1291 */ { MAD_F(0x06dd2955) /* 0.428994497 */, 15 }, - /* 1292 */ { MAD_F(0x06def9fa) /* 0.429437616 */, 15 }, - /* 1293 */ { MAD_F(0x06e0cabe) /* 0.429880849 */, 15 }, - /* 1294 */ { MAD_F(0x06e29ba0) /* 0.430324197 */, 15 }, - /* 1295 */ { MAD_F(0x06e46ca1) /* 0.430767659 */, 15 }, - - /* 1296 */ { MAD_F(0x06e63dc0) /* 0.431211234 */, 15 }, - /* 1297 */ { MAD_F(0x06e80efe) /* 0.431654924 */, 15 }, - /* 1298 */ { MAD_F(0x06e9e05b) /* 0.432098728 */, 15 }, - /* 1299 */ { MAD_F(0x06ebb1d6) /* 0.432542647 */, 15 }, - /* 1300 */ { MAD_F(0x06ed8370) /* 0.432986678 */, 15 }, - /* 1301 */ { MAD_F(0x06ef5529) /* 0.433430824 */, 15 }, - /* 1302 */ { MAD_F(0x06f12700) /* 0.433875084 */, 15 }, - /* 1303 */ { MAD_F(0x06f2f8f5) /* 0.434319457 */, 15 }, - /* 1304 */ { MAD_F(0x06f4cb09) /* 0.434763944 */, 15 }, - /* 1305 */ { MAD_F(0x06f69d3c) /* 0.435208545 */, 15 }, - /* 1306 */ { MAD_F(0x06f86f8d) /* 0.435653259 */, 15 }, - /* 1307 */ { MAD_F(0x06fa41fd) /* 0.436098087 */, 15 }, - /* 1308 */ { MAD_F(0x06fc148b) /* 0.436543029 */, 15 }, - /* 1309 */ { MAD_F(0x06fde737) /* 0.436988083 */, 15 }, - /* 1310 */ { MAD_F(0x06ffba02) /* 0.437433251 */, 15 }, - /* 1311 */ { MAD_F(0x07018ceb) /* 0.437878533 */, 15 }, - - /* 1312 */ { MAD_F(0x07035ff3) /* 0.438323927 */, 15 }, - /* 1313 */ { MAD_F(0x07053319) /* 0.438769435 */, 15 }, - /* 1314 */ { MAD_F(0x0707065d) /* 0.439215056 */, 15 }, - /* 1315 */ { MAD_F(0x0708d9c0) /* 0.439660790 */, 15 }, - /* 1316 */ { MAD_F(0x070aad41) /* 0.440106636 */, 15 }, - /* 1317 */ { MAD_F(0x070c80e1) /* 0.440552596 */, 15 }, - /* 1318 */ { MAD_F(0x070e549f) /* 0.440998669 */, 15 }, - /* 1319 */ { MAD_F(0x0710287b) /* 0.441444855 */, 15 }, - /* 1320 */ { MAD_F(0x0711fc75) /* 0.441891153 */, 15 }, - /* 1321 */ { MAD_F(0x0713d08d) /* 0.442337564 */, 15 }, - /* 1322 */ { MAD_F(0x0715a4c4) /* 0.442784088 */, 15 }, - /* 1323 */ { MAD_F(0x07177919) /* 0.443230724 */, 15 }, - /* 1324 */ { MAD_F(0x07194d8c) /* 0.443677473 */, 15 }, - /* 1325 */ { MAD_F(0x071b221e) /* 0.444124334 */, 15 }, - /* 1326 */ { MAD_F(0x071cf6ce) /* 0.444571308 */, 15 }, - /* 1327 */ { MAD_F(0x071ecb9b) /* 0.445018394 */, 15 }, - - /* 1328 */ { MAD_F(0x0720a087) /* 0.445465593 */, 15 }, - /* 1329 */ { MAD_F(0x07227591) /* 0.445912903 */, 15 }, - /* 1330 */ { MAD_F(0x07244ab9) /* 0.446360326 */, 15 }, - /* 1331 */ { MAD_F(0x07262000) /* 0.446807861 */, 15 }, - /* 1332 */ { MAD_F(0x0727f564) /* 0.447255509 */, 15 }, - /* 1333 */ { MAD_F(0x0729cae7) /* 0.447703268 */, 15 }, - /* 1334 */ { MAD_F(0x072ba087) /* 0.448151139 */, 15 }, - /* 1335 */ { MAD_F(0x072d7646) /* 0.448599122 */, 15 }, - /* 1336 */ { MAD_F(0x072f4c22) /* 0.449047217 */, 15 }, - /* 1337 */ { MAD_F(0x0731221d) /* 0.449495424 */, 15 }, - /* 1338 */ { MAD_F(0x0732f835) /* 0.449943742 */, 15 }, - /* 1339 */ { MAD_F(0x0734ce6c) /* 0.450392173 */, 15 }, - /* 1340 */ { MAD_F(0x0736a4c1) /* 0.450840715 */, 15 }, - /* 1341 */ { MAD_F(0x07387b33) /* 0.451289368 */, 15 }, - /* 1342 */ { MAD_F(0x073a51c4) /* 0.451738133 */, 15 }, - /* 1343 */ { MAD_F(0x073c2872) /* 0.452187010 */, 15 }, - - /* 1344 */ { MAD_F(0x073dff3e) /* 0.452635998 */, 15 }, - /* 1345 */ { MAD_F(0x073fd628) /* 0.453085097 */, 15 }, - /* 1346 */ { MAD_F(0x0741ad30) /* 0.453534308 */, 15 }, - /* 1347 */ { MAD_F(0x07438456) /* 0.453983630 */, 15 }, - /* 1348 */ { MAD_F(0x07455b9a) /* 0.454433063 */, 15 }, - /* 1349 */ { MAD_F(0x074732fc) /* 0.454882607 */, 15 }, - /* 1350 */ { MAD_F(0x07490a7b) /* 0.455332262 */, 15 }, - /* 1351 */ { MAD_F(0x074ae218) /* 0.455782029 */, 15 }, - /* 1352 */ { MAD_F(0x074cb9d3) /* 0.456231906 */, 15 }, - /* 1353 */ { MAD_F(0x074e91ac) /* 0.456681894 */, 15 }, - /* 1354 */ { MAD_F(0x075069a3) /* 0.457131993 */, 15 }, - /* 1355 */ { MAD_F(0x075241b7) /* 0.457582203 */, 15 }, - /* 1356 */ { MAD_F(0x075419e9) /* 0.458032524 */, 15 }, - /* 1357 */ { MAD_F(0x0755f239) /* 0.458482956 */, 15 }, - /* 1358 */ { MAD_F(0x0757caa7) /* 0.458933498 */, 15 }, - /* 1359 */ { MAD_F(0x0759a332) /* 0.459384151 */, 15 }, - - /* 1360 */ { MAD_F(0x075b7bdb) /* 0.459834914 */, 15 }, - /* 1361 */ { MAD_F(0x075d54a1) /* 0.460285788 */, 15 }, - /* 1362 */ { MAD_F(0x075f2d85) /* 0.460736772 */, 15 }, - /* 1363 */ { MAD_F(0x07610687) /* 0.461187867 */, 15 }, - /* 1364 */ { MAD_F(0x0762dfa6) /* 0.461639071 */, 15 }, - /* 1365 */ { MAD_F(0x0764b8e3) /* 0.462090387 */, 15 }, - /* 1366 */ { MAD_F(0x0766923e) /* 0.462541812 */, 15 }, - /* 1367 */ { MAD_F(0x07686bb6) /* 0.462993348 */, 15 }, - /* 1368 */ { MAD_F(0x076a454c) /* 0.463444993 */, 15 }, - /* 1369 */ { MAD_F(0x076c1eff) /* 0.463896749 */, 15 }, - /* 1370 */ { MAD_F(0x076df8d0) /* 0.464348615 */, 15 }, - /* 1371 */ { MAD_F(0x076fd2be) /* 0.464800591 */, 15 }, - /* 1372 */ { MAD_F(0x0771acca) /* 0.465252676 */, 15 }, - /* 1373 */ { MAD_F(0x077386f3) /* 0.465704872 */, 15 }, - /* 1374 */ { MAD_F(0x0775613a) /* 0.466157177 */, 15 }, - /* 1375 */ { MAD_F(0x07773b9e) /* 0.466609592 */, 15 }, - - /* 1376 */ { MAD_F(0x07791620) /* 0.467062117 */, 15 }, - /* 1377 */ { MAD_F(0x077af0bf) /* 0.467514751 */, 15 }, - /* 1378 */ { MAD_F(0x077ccb7c) /* 0.467967495 */, 15 }, - /* 1379 */ { MAD_F(0x077ea656) /* 0.468420349 */, 15 }, - /* 1380 */ { MAD_F(0x0780814d) /* 0.468873312 */, 15 }, - /* 1381 */ { MAD_F(0x07825c62) /* 0.469326384 */, 15 }, - /* 1382 */ { MAD_F(0x07843794) /* 0.469779566 */, 15 }, - /* 1383 */ { MAD_F(0x078612e3) /* 0.470232857 */, 15 }, - /* 1384 */ { MAD_F(0x0787ee50) /* 0.470686258 */, 15 }, - /* 1385 */ { MAD_F(0x0789c9da) /* 0.471139767 */, 15 }, - /* 1386 */ { MAD_F(0x078ba581) /* 0.471593386 */, 15 }, - /* 1387 */ { MAD_F(0x078d8146) /* 0.472047114 */, 15 }, - /* 1388 */ { MAD_F(0x078f5d28) /* 0.472500951 */, 15 }, - /* 1389 */ { MAD_F(0x07913927) /* 0.472954896 */, 15 }, - /* 1390 */ { MAD_F(0x07931543) /* 0.473408951 */, 15 }, - /* 1391 */ { MAD_F(0x0794f17d) /* 0.473863115 */, 15 }, - - /* 1392 */ { MAD_F(0x0796cdd4) /* 0.474317388 */, 15 }, - /* 1393 */ { MAD_F(0x0798aa48) /* 0.474771769 */, 15 }, - /* 1394 */ { MAD_F(0x079a86d9) /* 0.475226259 */, 15 }, - /* 1395 */ { MAD_F(0x079c6388) /* 0.475680858 */, 15 }, - /* 1396 */ { MAD_F(0x079e4053) /* 0.476135565 */, 15 }, - /* 1397 */ { MAD_F(0x07a01d3c) /* 0.476590381 */, 15 }, - /* 1398 */ { MAD_F(0x07a1fa42) /* 0.477045306 */, 15 }, - /* 1399 */ { MAD_F(0x07a3d765) /* 0.477500339 */, 15 }, - /* 1400 */ { MAD_F(0x07a5b4a5) /* 0.477955481 */, 15 }, - /* 1401 */ { MAD_F(0x07a79202) /* 0.478410731 */, 15 }, - /* 1402 */ { MAD_F(0x07a96f7d) /* 0.478866089 */, 15 }, - /* 1403 */ { MAD_F(0x07ab4d14) /* 0.479321555 */, 15 }, - /* 1404 */ { MAD_F(0x07ad2ac8) /* 0.479777130 */, 15 }, - /* 1405 */ { MAD_F(0x07af089a) /* 0.480232813 */, 15 }, - /* 1406 */ { MAD_F(0x07b0e688) /* 0.480688604 */, 15 }, - /* 1407 */ { MAD_F(0x07b2c494) /* 0.481144503 */, 15 }, - - /* 1408 */ { MAD_F(0x07b4a2bc) /* 0.481600510 */, 15 }, - /* 1409 */ { MAD_F(0x07b68102) /* 0.482056625 */, 15 }, - /* 1410 */ { MAD_F(0x07b85f64) /* 0.482512848 */, 15 }, - /* 1411 */ { MAD_F(0x07ba3de4) /* 0.482969179 */, 15 }, - /* 1412 */ { MAD_F(0x07bc1c80) /* 0.483425618 */, 15 }, - /* 1413 */ { MAD_F(0x07bdfb39) /* 0.483882164 */, 15 }, - /* 1414 */ { MAD_F(0x07bfda0f) /* 0.484338818 */, 15 }, - /* 1415 */ { MAD_F(0x07c1b902) /* 0.484795580 */, 15 }, - /* 1416 */ { MAD_F(0x07c39812) /* 0.485252449 */, 15 }, - /* 1417 */ { MAD_F(0x07c5773f) /* 0.485709426 */, 15 }, - /* 1418 */ { MAD_F(0x07c75689) /* 0.486166511 */, 15 }, - /* 1419 */ { MAD_F(0x07c935ef) /* 0.486623703 */, 15 }, - /* 1420 */ { MAD_F(0x07cb1573) /* 0.487081002 */, 15 }, - /* 1421 */ { MAD_F(0x07ccf513) /* 0.487538409 */, 15 }, - /* 1422 */ { MAD_F(0x07ced4d0) /* 0.487995923 */, 15 }, - /* 1423 */ { MAD_F(0x07d0b4aa) /* 0.488453544 */, 15 }, - - /* 1424 */ { MAD_F(0x07d294a0) /* 0.488911273 */, 15 }, - /* 1425 */ { MAD_F(0x07d474b3) /* 0.489369108 */, 15 }, - /* 1426 */ { MAD_F(0x07d654e4) /* 0.489827051 */, 15 }, - /* 1427 */ { MAD_F(0x07d83530) /* 0.490285101 */, 15 }, - /* 1428 */ { MAD_F(0x07da159a) /* 0.490743258 */, 15 }, - /* 1429 */ { MAD_F(0x07dbf620) /* 0.491201522 */, 15 }, - /* 1430 */ { MAD_F(0x07ddd6c3) /* 0.491659892 */, 15 }, - /* 1431 */ { MAD_F(0x07dfb783) /* 0.492118370 */, 15 }, - /* 1432 */ { MAD_F(0x07e1985f) /* 0.492576954 */, 15 }, - /* 1433 */ { MAD_F(0x07e37958) /* 0.493035645 */, 15 }, - /* 1434 */ { MAD_F(0x07e55a6e) /* 0.493494443 */, 15 }, - /* 1435 */ { MAD_F(0x07e73ba0) /* 0.493953348 */, 15 }, - /* 1436 */ { MAD_F(0x07e91cef) /* 0.494412359 */, 15 }, - /* 1437 */ { MAD_F(0x07eafe5a) /* 0.494871476 */, 15 }, - /* 1438 */ { MAD_F(0x07ecdfe2) /* 0.495330701 */, 15 }, - /* 1439 */ { MAD_F(0x07eec187) /* 0.495790031 */, 15 }, - - /* 1440 */ { MAD_F(0x07f0a348) /* 0.496249468 */, 15 }, - /* 1441 */ { MAD_F(0x07f28526) /* 0.496709012 */, 15 }, - /* 1442 */ { MAD_F(0x07f46720) /* 0.497168662 */, 15 }, - /* 1443 */ { MAD_F(0x07f64937) /* 0.497628418 */, 15 }, - /* 1444 */ { MAD_F(0x07f82b6a) /* 0.498088280 */, 15 }, - /* 1445 */ { MAD_F(0x07fa0dba) /* 0.498548248 */, 15 }, - /* 1446 */ { MAD_F(0x07fbf026) /* 0.499008323 */, 15 }, - /* 1447 */ { MAD_F(0x07fdd2af) /* 0.499468503 */, 15 }, - /* 1448 */ { MAD_F(0x07ffb554) /* 0.499928790 */, 15 }, - /* 1449 */ { MAD_F(0x0400cc0b) /* 0.250194591 */, 16 }, - /* 1450 */ { MAD_F(0x0401bd7a) /* 0.250424840 */, 16 }, - /* 1451 */ { MAD_F(0x0402aef7) /* 0.250655143 */, 16 }, - /* 1452 */ { MAD_F(0x0403a083) /* 0.250885498 */, 16 }, - /* 1453 */ { MAD_F(0x0404921c) /* 0.251115906 */, 16 }, - /* 1454 */ { MAD_F(0x040583c4) /* 0.251346367 */, 16 }, - /* 1455 */ { MAD_F(0x0406757a) /* 0.251576880 */, 16 }, - - /* 1456 */ { MAD_F(0x0407673f) /* 0.251807447 */, 16 }, - /* 1457 */ { MAD_F(0x04085911) /* 0.252038066 */, 16 }, - /* 1458 */ { MAD_F(0x04094af1) /* 0.252268738 */, 16 }, - /* 1459 */ { MAD_F(0x040a3ce0) /* 0.252499463 */, 16 }, - /* 1460 */ { MAD_F(0x040b2edd) /* 0.252730240 */, 16 }, - /* 1461 */ { MAD_F(0x040c20e8) /* 0.252961071 */, 16 }, - /* 1462 */ { MAD_F(0x040d1301) /* 0.253191953 */, 16 }, - /* 1463 */ { MAD_F(0x040e0529) /* 0.253422889 */, 16 }, - /* 1464 */ { MAD_F(0x040ef75e) /* 0.253653877 */, 16 }, - /* 1465 */ { MAD_F(0x040fe9a1) /* 0.253884918 */, 16 }, - /* 1466 */ { MAD_F(0x0410dbf3) /* 0.254116011 */, 16 }, - /* 1467 */ { MAD_F(0x0411ce53) /* 0.254347157 */, 16 }, - /* 1468 */ { MAD_F(0x0412c0c1) /* 0.254578356 */, 16 }, - /* 1469 */ { MAD_F(0x0413b33d) /* 0.254809606 */, 16 }, - /* 1470 */ { MAD_F(0x0414a5c7) /* 0.255040910 */, 16 }, - /* 1471 */ { MAD_F(0x0415985f) /* 0.255272266 */, 16 }, - - /* 1472 */ { MAD_F(0x04168b05) /* 0.255503674 */, 16 }, - /* 1473 */ { MAD_F(0x04177db9) /* 0.255735135 */, 16 }, - /* 1474 */ { MAD_F(0x0418707c) /* 0.255966648 */, 16 }, - /* 1475 */ { MAD_F(0x0419634c) /* 0.256198213 */, 16 }, - /* 1476 */ { MAD_F(0x041a562a) /* 0.256429831 */, 16 }, - /* 1477 */ { MAD_F(0x041b4917) /* 0.256661501 */, 16 }, - /* 1478 */ { MAD_F(0x041c3c11) /* 0.256893223 */, 16 }, - /* 1479 */ { MAD_F(0x041d2f1a) /* 0.257124998 */, 16 }, - /* 1480 */ { MAD_F(0x041e2230) /* 0.257356825 */, 16 }, - /* 1481 */ { MAD_F(0x041f1555) /* 0.257588704 */, 16 }, - /* 1482 */ { MAD_F(0x04200888) /* 0.257820635 */, 16 }, - /* 1483 */ { MAD_F(0x0420fbc8) /* 0.258052619 */, 16 }, - /* 1484 */ { MAD_F(0x0421ef17) /* 0.258284654 */, 16 }, - /* 1485 */ { MAD_F(0x0422e273) /* 0.258516742 */, 16 }, - /* 1486 */ { MAD_F(0x0423d5de) /* 0.258748882 */, 16 }, - /* 1487 */ { MAD_F(0x0424c956) /* 0.258981074 */, 16 }, - - /* 1488 */ { MAD_F(0x0425bcdd) /* 0.259213318 */, 16 }, - /* 1489 */ { MAD_F(0x0426b071) /* 0.259445614 */, 16 }, - /* 1490 */ { MAD_F(0x0427a414) /* 0.259677962 */, 16 }, - /* 1491 */ { MAD_F(0x042897c4) /* 0.259910362 */, 16 }, - /* 1492 */ { MAD_F(0x04298b83) /* 0.260142814 */, 16 }, - /* 1493 */ { MAD_F(0x042a7f4f) /* 0.260375318 */, 16 }, - /* 1494 */ { MAD_F(0x042b7329) /* 0.260607874 */, 16 }, - /* 1495 */ { MAD_F(0x042c6711) /* 0.260840481 */, 16 }, - /* 1496 */ { MAD_F(0x042d5b07) /* 0.261073141 */, 16 }, - /* 1497 */ { MAD_F(0x042e4f0b) /* 0.261305852 */, 16 }, - /* 1498 */ { MAD_F(0x042f431d) /* 0.261538616 */, 16 }, - /* 1499 */ { MAD_F(0x0430373d) /* 0.261771431 */, 16 }, - /* 1500 */ { MAD_F(0x04312b6b) /* 0.262004297 */, 16 }, - /* 1501 */ { MAD_F(0x04321fa6) /* 0.262237216 */, 16 }, - /* 1502 */ { MAD_F(0x043313f0) /* 0.262470186 */, 16 }, - /* 1503 */ { MAD_F(0x04340847) /* 0.262703208 */, 16 }, - - /* 1504 */ { MAD_F(0x0434fcad) /* 0.262936282 */, 16 }, - /* 1505 */ { MAD_F(0x0435f120) /* 0.263169407 */, 16 }, - /* 1506 */ { MAD_F(0x0436e5a1) /* 0.263402584 */, 16 }, - /* 1507 */ { MAD_F(0x0437da2f) /* 0.263635813 */, 16 }, - /* 1508 */ { MAD_F(0x0438cecc) /* 0.263869093 */, 16 }, - /* 1509 */ { MAD_F(0x0439c377) /* 0.264102425 */, 16 }, - /* 1510 */ { MAD_F(0x043ab82f) /* 0.264335808 */, 16 }, - /* 1511 */ { MAD_F(0x043bacf5) /* 0.264569243 */, 16 }, - /* 1512 */ { MAD_F(0x043ca1c9) /* 0.264802730 */, 16 }, - /* 1513 */ { MAD_F(0x043d96ab) /* 0.265036267 */, 16 }, - /* 1514 */ { MAD_F(0x043e8b9b) /* 0.265269857 */, 16 }, - /* 1515 */ { MAD_F(0x043f8098) /* 0.265503498 */, 16 }, - /* 1516 */ { MAD_F(0x044075a3) /* 0.265737190 */, 16 }, - /* 1517 */ { MAD_F(0x04416abc) /* 0.265970933 */, 16 }, - /* 1518 */ { MAD_F(0x04425fe3) /* 0.266204728 */, 16 }, - /* 1519 */ { MAD_F(0x04435518) /* 0.266438574 */, 16 }, - - /* 1520 */ { MAD_F(0x04444a5a) /* 0.266672472 */, 16 }, - /* 1521 */ { MAD_F(0x04453fab) /* 0.266906421 */, 16 }, - /* 1522 */ { MAD_F(0x04463508) /* 0.267140421 */, 16 }, - /* 1523 */ { MAD_F(0x04472a74) /* 0.267374472 */, 16 }, - /* 1524 */ { MAD_F(0x04481fee) /* 0.267608575 */, 16 }, - /* 1525 */ { MAD_F(0x04491575) /* 0.267842729 */, 16 }, - /* 1526 */ { MAD_F(0x044a0b0a) /* 0.268076934 */, 16 }, - /* 1527 */ { MAD_F(0x044b00ac) /* 0.268311190 */, 16 }, - /* 1528 */ { MAD_F(0x044bf65d) /* 0.268545497 */, 16 }, - /* 1529 */ { MAD_F(0x044cec1b) /* 0.268779856 */, 16 }, - /* 1530 */ { MAD_F(0x044de1e7) /* 0.269014265 */, 16 }, - /* 1531 */ { MAD_F(0x044ed7c0) /* 0.269248726 */, 16 }, - /* 1532 */ { MAD_F(0x044fcda8) /* 0.269483238 */, 16 }, - /* 1533 */ { MAD_F(0x0450c39c) /* 0.269717800 */, 16 }, - /* 1534 */ { MAD_F(0x0451b99f) /* 0.269952414 */, 16 }, - /* 1535 */ { MAD_F(0x0452afaf) /* 0.270187079 */, 16 }, - - /* 1536 */ { MAD_F(0x0453a5cd) /* 0.270421794 */, 16 }, - /* 1537 */ { MAD_F(0x04549bf9) /* 0.270656561 */, 16 }, - /* 1538 */ { MAD_F(0x04559232) /* 0.270891379 */, 16 }, - /* 1539 */ { MAD_F(0x04568879) /* 0.271126247 */, 16 }, - /* 1540 */ { MAD_F(0x04577ece) /* 0.271361166 */, 16 }, - /* 1541 */ { MAD_F(0x04587530) /* 0.271596136 */, 16 }, - /* 1542 */ { MAD_F(0x04596ba0) /* 0.271831157 */, 16 }, - /* 1543 */ { MAD_F(0x045a621e) /* 0.272066229 */, 16 }, - /* 1544 */ { MAD_F(0x045b58a9) /* 0.272301352 */, 16 }, - /* 1545 */ { MAD_F(0x045c4f42) /* 0.272536525 */, 16 }, - /* 1546 */ { MAD_F(0x045d45e9) /* 0.272771749 */, 16 }, - /* 1547 */ { MAD_F(0x045e3c9d) /* 0.273007024 */, 16 }, - /* 1548 */ { MAD_F(0x045f335e) /* 0.273242350 */, 16 }, - /* 1549 */ { MAD_F(0x04602a2e) /* 0.273477726 */, 16 }, - /* 1550 */ { MAD_F(0x0461210b) /* 0.273713153 */, 16 }, - /* 1551 */ { MAD_F(0x046217f5) /* 0.273948630 */, 16 }, - - /* 1552 */ { MAD_F(0x04630eed) /* 0.274184158 */, 16 }, - /* 1553 */ { MAD_F(0x046405f3) /* 0.274419737 */, 16 }, - /* 1554 */ { MAD_F(0x0464fd06) /* 0.274655366 */, 16 }, - /* 1555 */ { MAD_F(0x0465f427) /* 0.274891046 */, 16 }, - /* 1556 */ { MAD_F(0x0466eb55) /* 0.275126776 */, 16 }, - /* 1557 */ { MAD_F(0x0467e291) /* 0.275362557 */, 16 }, - /* 1558 */ { MAD_F(0x0468d9db) /* 0.275598389 */, 16 }, - /* 1559 */ { MAD_F(0x0469d132) /* 0.275834270 */, 16 }, - /* 1560 */ { MAD_F(0x046ac896) /* 0.276070203 */, 16 }, - /* 1561 */ { MAD_F(0x046bc009) /* 0.276306185 */, 16 }, - /* 1562 */ { MAD_F(0x046cb788) /* 0.276542218 */, 16 }, - /* 1563 */ { MAD_F(0x046daf15) /* 0.276778302 */, 16 }, - /* 1564 */ { MAD_F(0x046ea6b0) /* 0.277014435 */, 16 }, - /* 1565 */ { MAD_F(0x046f9e58) /* 0.277250619 */, 16 }, - /* 1566 */ { MAD_F(0x0470960e) /* 0.277486854 */, 16 }, - /* 1567 */ { MAD_F(0x04718dd1) /* 0.277723139 */, 16 }, - - /* 1568 */ { MAD_F(0x047285a2) /* 0.277959474 */, 16 }, - /* 1569 */ { MAD_F(0x04737d80) /* 0.278195859 */, 16 }, - /* 1570 */ { MAD_F(0x0474756c) /* 0.278432294 */, 16 }, - /* 1571 */ { MAD_F(0x04756d65) /* 0.278668780 */, 16 }, - /* 1572 */ { MAD_F(0x0476656b) /* 0.278905316 */, 16 }, - /* 1573 */ { MAD_F(0x04775d7f) /* 0.279141902 */, 16 }, - /* 1574 */ { MAD_F(0x047855a1) /* 0.279378538 */, 16 }, - /* 1575 */ { MAD_F(0x04794dd0) /* 0.279615224 */, 16 }, - /* 1576 */ { MAD_F(0x047a460c) /* 0.279851960 */, 16 }, - /* 1577 */ { MAD_F(0x047b3e56) /* 0.280088747 */, 16 }, - /* 1578 */ { MAD_F(0x047c36ae) /* 0.280325583 */, 16 }, - /* 1579 */ { MAD_F(0x047d2f12) /* 0.280562470 */, 16 }, - /* 1580 */ { MAD_F(0x047e2784) /* 0.280799406 */, 16 }, - /* 1581 */ { MAD_F(0x047f2004) /* 0.281036393 */, 16 }, - /* 1582 */ { MAD_F(0x04801891) /* 0.281273429 */, 16 }, - /* 1583 */ { MAD_F(0x0481112b) /* 0.281510516 */, 16 }, - - /* 1584 */ { MAD_F(0x048209d3) /* 0.281747652 */, 16 }, - /* 1585 */ { MAD_F(0x04830288) /* 0.281984838 */, 16 }, - /* 1586 */ { MAD_F(0x0483fb4b) /* 0.282222075 */, 16 }, - /* 1587 */ { MAD_F(0x0484f41b) /* 0.282459361 */, 16 }, - /* 1588 */ { MAD_F(0x0485ecf8) /* 0.282696697 */, 16 }, - /* 1589 */ { MAD_F(0x0486e5e3) /* 0.282934082 */, 16 }, - /* 1590 */ { MAD_F(0x0487dedb) /* 0.283171518 */, 16 }, - /* 1591 */ { MAD_F(0x0488d7e1) /* 0.283409003 */, 16 }, - /* 1592 */ { MAD_F(0x0489d0f4) /* 0.283646538 */, 16 }, - /* 1593 */ { MAD_F(0x048aca14) /* 0.283884123 */, 16 }, - /* 1594 */ { MAD_F(0x048bc341) /* 0.284121757 */, 16 }, - /* 1595 */ { MAD_F(0x048cbc7c) /* 0.284359441 */, 16 }, - /* 1596 */ { MAD_F(0x048db5c4) /* 0.284597175 */, 16 }, - /* 1597 */ { MAD_F(0x048eaf1a) /* 0.284834959 */, 16 }, - /* 1598 */ { MAD_F(0x048fa87d) /* 0.285072792 */, 16 }, - /* 1599 */ { MAD_F(0x0490a1ed) /* 0.285310675 */, 16 }, - - /* 1600 */ { MAD_F(0x04919b6a) /* 0.285548607 */, 16 }, - /* 1601 */ { MAD_F(0x049294f5) /* 0.285786589 */, 16 }, - /* 1602 */ { MAD_F(0x04938e8d) /* 0.286024621 */, 16 }, - /* 1603 */ { MAD_F(0x04948833) /* 0.286262702 */, 16 }, - /* 1604 */ { MAD_F(0x049581e5) /* 0.286500832 */, 16 }, - /* 1605 */ { MAD_F(0x04967ba5) /* 0.286739012 */, 16 }, - /* 1606 */ { MAD_F(0x04977573) /* 0.286977242 */, 16 }, - /* 1607 */ { MAD_F(0x04986f4d) /* 0.287215521 */, 16 }, - /* 1608 */ { MAD_F(0x04996935) /* 0.287453849 */, 16 }, - /* 1609 */ { MAD_F(0x049a632a) /* 0.287692227 */, 16 }, - /* 1610 */ { MAD_F(0x049b5d2c) /* 0.287930654 */, 16 }, - /* 1611 */ { MAD_F(0x049c573c) /* 0.288169131 */, 16 }, - /* 1612 */ { MAD_F(0x049d5159) /* 0.288407657 */, 16 }, - /* 1613 */ { MAD_F(0x049e4b83) /* 0.288646232 */, 16 }, - /* 1614 */ { MAD_F(0x049f45ba) /* 0.288884857 */, 16 }, - /* 1615 */ { MAD_F(0x04a03ffe) /* 0.289123530 */, 16 }, - - /* 1616 */ { MAD_F(0x04a13a50) /* 0.289362253 */, 16 }, - /* 1617 */ { MAD_F(0x04a234af) /* 0.289601026 */, 16 }, - /* 1618 */ { MAD_F(0x04a32f1b) /* 0.289839847 */, 16 }, - /* 1619 */ { MAD_F(0x04a42995) /* 0.290078718 */, 16 }, - /* 1620 */ { MAD_F(0x04a5241b) /* 0.290317638 */, 16 }, - /* 1621 */ { MAD_F(0x04a61eaf) /* 0.290556607 */, 16 }, - /* 1622 */ { MAD_F(0x04a71950) /* 0.290795626 */, 16 }, - /* 1623 */ { MAD_F(0x04a813fe) /* 0.291034693 */, 16 }, - /* 1624 */ { MAD_F(0x04a90eba) /* 0.291273810 */, 16 }, - /* 1625 */ { MAD_F(0x04aa0982) /* 0.291512975 */, 16 }, - /* 1626 */ { MAD_F(0x04ab0458) /* 0.291752190 */, 16 }, - /* 1627 */ { MAD_F(0x04abff3b) /* 0.291991453 */, 16 }, - /* 1628 */ { MAD_F(0x04acfa2b) /* 0.292230766 */, 16 }, - /* 1629 */ { MAD_F(0x04adf528) /* 0.292470128 */, 16 }, - /* 1630 */ { MAD_F(0x04aef032) /* 0.292709539 */, 16 }, - /* 1631 */ { MAD_F(0x04afeb4a) /* 0.292948998 */, 16 }, - - /* 1632 */ { MAD_F(0x04b0e66e) /* 0.293188507 */, 16 }, - /* 1633 */ { MAD_F(0x04b1e1a0) /* 0.293428065 */, 16 }, - /* 1634 */ { MAD_F(0x04b2dcdf) /* 0.293667671 */, 16 }, - /* 1635 */ { MAD_F(0x04b3d82b) /* 0.293907326 */, 16 }, - /* 1636 */ { MAD_F(0x04b4d384) /* 0.294147031 */, 16 }, - /* 1637 */ { MAD_F(0x04b5ceea) /* 0.294386784 */, 16 }, - /* 1638 */ { MAD_F(0x04b6ca5e) /* 0.294626585 */, 16 }, - /* 1639 */ { MAD_F(0x04b7c5de) /* 0.294866436 */, 16 }, - /* 1640 */ { MAD_F(0x04b8c16c) /* 0.295106336 */, 16 }, - /* 1641 */ { MAD_F(0x04b9bd06) /* 0.295346284 */, 16 }, - /* 1642 */ { MAD_F(0x04bab8ae) /* 0.295586281 */, 16 }, - /* 1643 */ { MAD_F(0x04bbb463) /* 0.295826327 */, 16 }, - /* 1644 */ { MAD_F(0x04bcb024) /* 0.296066421 */, 16 }, - /* 1645 */ { MAD_F(0x04bdabf3) /* 0.296306564 */, 16 }, - /* 1646 */ { MAD_F(0x04bea7cf) /* 0.296546756 */, 16 }, - /* 1647 */ { MAD_F(0x04bfa3b8) /* 0.296786996 */, 16 }, - - /* 1648 */ { MAD_F(0x04c09faf) /* 0.297027285 */, 16 }, - /* 1649 */ { MAD_F(0x04c19bb2) /* 0.297267623 */, 16 }, - /* 1650 */ { MAD_F(0x04c297c2) /* 0.297508009 */, 16 }, - /* 1651 */ { MAD_F(0x04c393df) /* 0.297748444 */, 16 }, - /* 1652 */ { MAD_F(0x04c49009) /* 0.297988927 */, 16 }, - /* 1653 */ { MAD_F(0x04c58c41) /* 0.298229459 */, 16 }, - /* 1654 */ { MAD_F(0x04c68885) /* 0.298470039 */, 16 }, - /* 1655 */ { MAD_F(0x04c784d6) /* 0.298710668 */, 16 }, - /* 1656 */ { MAD_F(0x04c88135) /* 0.298951346 */, 16 }, - /* 1657 */ { MAD_F(0x04c97da0) /* 0.299192071 */, 16 }, - /* 1658 */ { MAD_F(0x04ca7a18) /* 0.299432846 */, 16 }, - /* 1659 */ { MAD_F(0x04cb769e) /* 0.299673668 */, 16 }, - /* 1660 */ { MAD_F(0x04cc7330) /* 0.299914539 */, 16 }, - /* 1661 */ { MAD_F(0x04cd6fcf) /* 0.300155459 */, 16 }, - /* 1662 */ { MAD_F(0x04ce6c7b) /* 0.300396426 */, 16 }, - /* 1663 */ { MAD_F(0x04cf6935) /* 0.300637443 */, 16 }, - - /* 1664 */ { MAD_F(0x04d065fb) /* 0.300878507 */, 16 }, - /* 1665 */ { MAD_F(0x04d162ce) /* 0.301119620 */, 16 }, - /* 1666 */ { MAD_F(0x04d25fae) /* 0.301360781 */, 16 }, - /* 1667 */ { MAD_F(0x04d35c9b) /* 0.301601990 */, 16 }, - /* 1668 */ { MAD_F(0x04d45995) /* 0.301843247 */, 16 }, - /* 1669 */ { MAD_F(0x04d5569c) /* 0.302084553 */, 16 }, - /* 1670 */ { MAD_F(0x04d653b0) /* 0.302325907 */, 16 }, - /* 1671 */ { MAD_F(0x04d750d1) /* 0.302567309 */, 16 }, - /* 1672 */ { MAD_F(0x04d84dff) /* 0.302808759 */, 16 }, - /* 1673 */ { MAD_F(0x04d94b3a) /* 0.303050257 */, 16 }, - /* 1674 */ { MAD_F(0x04da4881) /* 0.303291804 */, 16 }, - /* 1675 */ { MAD_F(0x04db45d6) /* 0.303533399 */, 16 }, - /* 1676 */ { MAD_F(0x04dc4337) /* 0.303775041 */, 16 }, - /* 1677 */ { MAD_F(0x04dd40a6) /* 0.304016732 */, 16 }, - /* 1678 */ { MAD_F(0x04de3e21) /* 0.304258471 */, 16 }, - /* 1679 */ { MAD_F(0x04df3ba9) /* 0.304500257 */, 16 }, - - /* 1680 */ { MAD_F(0x04e0393e) /* 0.304742092 */, 16 }, - /* 1681 */ { MAD_F(0x04e136e0) /* 0.304983975 */, 16 }, - /* 1682 */ { MAD_F(0x04e2348f) /* 0.305225906 */, 16 }, - /* 1683 */ { MAD_F(0x04e3324b) /* 0.305467885 */, 16 }, - /* 1684 */ { MAD_F(0x04e43013) /* 0.305709911 */, 16 }, - /* 1685 */ { MAD_F(0x04e52de9) /* 0.305951986 */, 16 }, - /* 1686 */ { MAD_F(0x04e62bcb) /* 0.306194108 */, 16 }, - /* 1687 */ { MAD_F(0x04e729ba) /* 0.306436279 */, 16 }, - /* 1688 */ { MAD_F(0x04e827b6) /* 0.306678497 */, 16 }, - /* 1689 */ { MAD_F(0x04e925bf) /* 0.306920763 */, 16 }, - /* 1690 */ { MAD_F(0x04ea23d4) /* 0.307163077 */, 16 }, - /* 1691 */ { MAD_F(0x04eb21f7) /* 0.307405438 */, 16 }, - /* 1692 */ { MAD_F(0x04ec2026) /* 0.307647848 */, 16 }, - /* 1693 */ { MAD_F(0x04ed1e62) /* 0.307890305 */, 16 }, - /* 1694 */ { MAD_F(0x04ee1cab) /* 0.308132810 */, 16 }, - /* 1695 */ { MAD_F(0x04ef1b01) /* 0.308375362 */, 16 }, - - /* 1696 */ { MAD_F(0x04f01963) /* 0.308617963 */, 16 }, - /* 1697 */ { MAD_F(0x04f117d3) /* 0.308860611 */, 16 }, - /* 1698 */ { MAD_F(0x04f2164f) /* 0.309103306 */, 16 }, - /* 1699 */ { MAD_F(0x04f314d8) /* 0.309346050 */, 16 }, - /* 1700 */ { MAD_F(0x04f4136d) /* 0.309588841 */, 16 }, - /* 1701 */ { MAD_F(0x04f51210) /* 0.309831679 */, 16 }, - /* 1702 */ { MAD_F(0x04f610bf) /* 0.310074565 */, 16 }, - /* 1703 */ { MAD_F(0x04f70f7b) /* 0.310317499 */, 16 }, - /* 1704 */ { MAD_F(0x04f80e44) /* 0.310560480 */, 16 }, - /* 1705 */ { MAD_F(0x04f90d19) /* 0.310803509 */, 16 }, - /* 1706 */ { MAD_F(0x04fa0bfc) /* 0.311046586 */, 16 }, - /* 1707 */ { MAD_F(0x04fb0aeb) /* 0.311289710 */, 16 }, - /* 1708 */ { MAD_F(0x04fc09e7) /* 0.311532881 */, 16 }, - /* 1709 */ { MAD_F(0x04fd08ef) /* 0.311776100 */, 16 }, - /* 1710 */ { MAD_F(0x04fe0805) /* 0.312019366 */, 16 }, - /* 1711 */ { MAD_F(0x04ff0727) /* 0.312262680 */, 16 }, - - /* 1712 */ { MAD_F(0x05000655) /* 0.312506041 */, 16 }, - /* 1713 */ { MAD_F(0x05010591) /* 0.312749449 */, 16 }, - /* 1714 */ { MAD_F(0x050204d9) /* 0.312992905 */, 16 }, - /* 1715 */ { MAD_F(0x0503042e) /* 0.313236408 */, 16 }, - /* 1716 */ { MAD_F(0x0504038f) /* 0.313479959 */, 16 }, - /* 1717 */ { MAD_F(0x050502fe) /* 0.313723556 */, 16 }, - /* 1718 */ { MAD_F(0x05060279) /* 0.313967202 */, 16 }, - /* 1719 */ { MAD_F(0x05070200) /* 0.314210894 */, 16 }, - /* 1720 */ { MAD_F(0x05080195) /* 0.314454634 */, 16 }, - /* 1721 */ { MAD_F(0x05090136) /* 0.314698420 */, 16 }, - /* 1722 */ { MAD_F(0x050a00e3) /* 0.314942255 */, 16 }, - /* 1723 */ { MAD_F(0x050b009e) /* 0.315186136 */, 16 }, - /* 1724 */ { MAD_F(0x050c0065) /* 0.315430064 */, 16 }, - /* 1725 */ { MAD_F(0x050d0039) /* 0.315674040 */, 16 }, - /* 1726 */ { MAD_F(0x050e0019) /* 0.315918063 */, 16 }, - /* 1727 */ { MAD_F(0x050f0006) /* 0.316162133 */, 16 }, - - /* 1728 */ { MAD_F(0x05100000) /* 0.316406250 */, 16 }, - /* 1729 */ { MAD_F(0x05110006) /* 0.316650414 */, 16 }, - /* 1730 */ { MAD_F(0x05120019) /* 0.316894625 */, 16 }, - /* 1731 */ { MAD_F(0x05130039) /* 0.317138884 */, 16 }, - /* 1732 */ { MAD_F(0x05140065) /* 0.317383189 */, 16 }, - /* 1733 */ { MAD_F(0x0515009e) /* 0.317627541 */, 16 }, - /* 1734 */ { MAD_F(0x051600e3) /* 0.317871941 */, 16 }, - /* 1735 */ { MAD_F(0x05170135) /* 0.318116387 */, 16 }, - /* 1736 */ { MAD_F(0x05180194) /* 0.318360880 */, 16 }, - /* 1737 */ { MAD_F(0x051901ff) /* 0.318605421 */, 16 }, - /* 1738 */ { MAD_F(0x051a0277) /* 0.318850008 */, 16 }, - /* 1739 */ { MAD_F(0x051b02fc) /* 0.319094642 */, 16 }, - /* 1740 */ { MAD_F(0x051c038d) /* 0.319339323 */, 16 }, - /* 1741 */ { MAD_F(0x051d042a) /* 0.319584051 */, 16 }, - /* 1742 */ { MAD_F(0x051e04d4) /* 0.319828826 */, 16 }, - /* 1743 */ { MAD_F(0x051f058b) /* 0.320073647 */, 16 }, - - /* 1744 */ { MAD_F(0x0520064f) /* 0.320318516 */, 16 }, - /* 1745 */ { MAD_F(0x0521071f) /* 0.320563431 */, 16 }, - /* 1746 */ { MAD_F(0x052207fb) /* 0.320808393 */, 16 }, - /* 1747 */ { MAD_F(0x052308e4) /* 0.321053402 */, 16 }, - /* 1748 */ { MAD_F(0x052409da) /* 0.321298457 */, 16 }, - /* 1749 */ { MAD_F(0x05250adc) /* 0.321543560 */, 16 }, - /* 1750 */ { MAD_F(0x05260bea) /* 0.321788709 */, 16 }, - /* 1751 */ { MAD_F(0x05270d06) /* 0.322033904 */, 16 }, - /* 1752 */ { MAD_F(0x05280e2d) /* 0.322279147 */, 16 }, - /* 1753 */ { MAD_F(0x05290f62) /* 0.322524436 */, 16 }, - /* 1754 */ { MAD_F(0x052a10a3) /* 0.322769771 */, 16 }, - /* 1755 */ { MAD_F(0x052b11f0) /* 0.323015154 */, 16 }, - /* 1756 */ { MAD_F(0x052c134a) /* 0.323260583 */, 16 }, - /* 1757 */ { MAD_F(0x052d14b0) /* 0.323506058 */, 16 }, - /* 1758 */ { MAD_F(0x052e1623) /* 0.323751580 */, 16 }, - /* 1759 */ { MAD_F(0x052f17a2) /* 0.323997149 */, 16 }, - - /* 1760 */ { MAD_F(0x0530192e) /* 0.324242764 */, 16 }, - /* 1761 */ { MAD_F(0x05311ac6) /* 0.324488426 */, 16 }, - /* 1762 */ { MAD_F(0x05321c6b) /* 0.324734134 */, 16 }, - /* 1763 */ { MAD_F(0x05331e1c) /* 0.324979889 */, 16 }, - /* 1764 */ { MAD_F(0x05341fda) /* 0.325225690 */, 16 }, - /* 1765 */ { MAD_F(0x053521a4) /* 0.325471538 */, 16 }, - /* 1766 */ { MAD_F(0x0536237b) /* 0.325717432 */, 16 }, - /* 1767 */ { MAD_F(0x0537255e) /* 0.325963372 */, 16 }, - /* 1768 */ { MAD_F(0x0538274e) /* 0.326209359 */, 16 }, - /* 1769 */ { MAD_F(0x0539294a) /* 0.326455392 */, 16 }, - /* 1770 */ { MAD_F(0x053a2b52) /* 0.326701472 */, 16 }, - /* 1771 */ { MAD_F(0x053b2d67) /* 0.326947598 */, 16 }, - /* 1772 */ { MAD_F(0x053c2f89) /* 0.327193770 */, 16 }, - /* 1773 */ { MAD_F(0x053d31b6) /* 0.327439989 */, 16 }, - /* 1774 */ { MAD_F(0x053e33f1) /* 0.327686254 */, 16 }, - /* 1775 */ { MAD_F(0x053f3637) /* 0.327932565 */, 16 }, - - /* 1776 */ { MAD_F(0x0540388a) /* 0.328178922 */, 16 }, - /* 1777 */ { MAD_F(0x05413aea) /* 0.328425326 */, 16 }, - /* 1778 */ { MAD_F(0x05423d56) /* 0.328671776 */, 16 }, - /* 1779 */ { MAD_F(0x05433fce) /* 0.328918272 */, 16 }, - /* 1780 */ { MAD_F(0x05444253) /* 0.329164814 */, 16 }, - /* 1781 */ { MAD_F(0x054544e4) /* 0.329411403 */, 16 }, - /* 1782 */ { MAD_F(0x05464781) /* 0.329658038 */, 16 }, - /* 1783 */ { MAD_F(0x05474a2b) /* 0.329904718 */, 16 }, - /* 1784 */ { MAD_F(0x05484ce2) /* 0.330151445 */, 16 }, - /* 1785 */ { MAD_F(0x05494fa4) /* 0.330398218 */, 16 }, - /* 1786 */ { MAD_F(0x054a5273) /* 0.330645037 */, 16 }, - /* 1787 */ { MAD_F(0x054b554e) /* 0.330891903 */, 16 }, - /* 1788 */ { MAD_F(0x054c5836) /* 0.331138814 */, 16 }, - /* 1789 */ { MAD_F(0x054d5b2a) /* 0.331385771 */, 16 }, - /* 1790 */ { MAD_F(0x054e5e2b) /* 0.331632774 */, 16 }, - /* 1791 */ { MAD_F(0x054f6138) /* 0.331879824 */, 16 }, - - /* 1792 */ { MAD_F(0x05506451) /* 0.332126919 */, 16 }, - /* 1793 */ { MAD_F(0x05516776) /* 0.332374060 */, 16 }, - /* 1794 */ { MAD_F(0x05526aa8) /* 0.332621247 */, 16 }, - /* 1795 */ { MAD_F(0x05536de6) /* 0.332868480 */, 16 }, - /* 1796 */ { MAD_F(0x05547131) /* 0.333115759 */, 16 }, - /* 1797 */ { MAD_F(0x05557487) /* 0.333363084 */, 16 }, - /* 1798 */ { MAD_F(0x055677ea) /* 0.333610455 */, 16 }, - /* 1799 */ { MAD_F(0x05577b5a) /* 0.333857872 */, 16 }, - /* 1800 */ { MAD_F(0x05587ed5) /* 0.334105334 */, 16 }, - /* 1801 */ { MAD_F(0x0559825e) /* 0.334352843 */, 16 }, - /* 1802 */ { MAD_F(0x055a85f2) /* 0.334600397 */, 16 }, - /* 1803 */ { MAD_F(0x055b8992) /* 0.334847997 */, 16 }, - /* 1804 */ { MAD_F(0x055c8d3f) /* 0.335095642 */, 16 }, - /* 1805 */ { MAD_F(0x055d90f9) /* 0.335343334 */, 16 }, - /* 1806 */ { MAD_F(0x055e94be) /* 0.335591071 */, 16 }, - /* 1807 */ { MAD_F(0x055f9890) /* 0.335838854 */, 16 }, - - /* 1808 */ { MAD_F(0x05609c6e) /* 0.336086683 */, 16 }, - /* 1809 */ { MAD_F(0x0561a058) /* 0.336334557 */, 16 }, - /* 1810 */ { MAD_F(0x0562a44f) /* 0.336582477 */, 16 }, - /* 1811 */ { MAD_F(0x0563a851) /* 0.336830443 */, 16 }, - /* 1812 */ { MAD_F(0x0564ac60) /* 0.337078454 */, 16 }, - /* 1813 */ { MAD_F(0x0565b07c) /* 0.337326511 */, 16 }, - /* 1814 */ { MAD_F(0x0566b4a3) /* 0.337574614 */, 16 }, - /* 1815 */ { MAD_F(0x0567b8d7) /* 0.337822762 */, 16 }, - /* 1816 */ { MAD_F(0x0568bd17) /* 0.338070956 */, 16 }, - /* 1817 */ { MAD_F(0x0569c163) /* 0.338319195 */, 16 }, - /* 1818 */ { MAD_F(0x056ac5bc) /* 0.338567480 */, 16 }, - /* 1819 */ { MAD_F(0x056bca20) /* 0.338815811 */, 16 }, - /* 1820 */ { MAD_F(0x056cce91) /* 0.339064186 */, 16 }, - /* 1821 */ { MAD_F(0x056dd30e) /* 0.339312608 */, 16 }, - /* 1822 */ { MAD_F(0x056ed798) /* 0.339561075 */, 16 }, - /* 1823 */ { MAD_F(0x056fdc2d) /* 0.339809587 */, 16 }, - - /* 1824 */ { MAD_F(0x0570e0cf) /* 0.340058145 */, 16 }, - /* 1825 */ { MAD_F(0x0571e57d) /* 0.340306748 */, 16 }, - /* 1826 */ { MAD_F(0x0572ea37) /* 0.340555397 */, 16 }, - /* 1827 */ { MAD_F(0x0573eefd) /* 0.340804091 */, 16 }, - /* 1828 */ { MAD_F(0x0574f3d0) /* 0.341052830 */, 16 }, - /* 1829 */ { MAD_F(0x0575f8ae) /* 0.341301615 */, 16 }, - /* 1830 */ { MAD_F(0x0576fd99) /* 0.341550445 */, 16 }, - /* 1831 */ { MAD_F(0x05780290) /* 0.341799321 */, 16 }, - /* 1832 */ { MAD_F(0x05790793) /* 0.342048241 */, 16 }, - /* 1833 */ { MAD_F(0x057a0ca3) /* 0.342297207 */, 16 }, - /* 1834 */ { MAD_F(0x057b11be) /* 0.342546219 */, 16 }, - /* 1835 */ { MAD_F(0x057c16e6) /* 0.342795275 */, 16 }, - /* 1836 */ { MAD_F(0x057d1c1a) /* 0.343044377 */, 16 }, - /* 1837 */ { MAD_F(0x057e2159) /* 0.343293524 */, 16 }, - /* 1838 */ { MAD_F(0x057f26a6) /* 0.343542717 */, 16 }, - /* 1839 */ { MAD_F(0x05802bfe) /* 0.343791954 */, 16 }, - - /* 1840 */ { MAD_F(0x05813162) /* 0.344041237 */, 16 }, - /* 1841 */ { MAD_F(0x058236d2) /* 0.344290564 */, 16 }, - /* 1842 */ { MAD_F(0x05833c4f) /* 0.344539937 */, 16 }, - /* 1843 */ { MAD_F(0x058441d8) /* 0.344789356 */, 16 }, - /* 1844 */ { MAD_F(0x0585476c) /* 0.345038819 */, 16 }, - /* 1845 */ { MAD_F(0x05864d0d) /* 0.345288327 */, 16 }, - /* 1846 */ { MAD_F(0x058752ba) /* 0.345537880 */, 16 }, - /* 1847 */ { MAD_F(0x05885873) /* 0.345787479 */, 16 }, - /* 1848 */ { MAD_F(0x05895e39) /* 0.346037122 */, 16 }, - /* 1849 */ { MAD_F(0x058a640a) /* 0.346286811 */, 16 }, - /* 1850 */ { MAD_F(0x058b69e7) /* 0.346536545 */, 16 }, - /* 1851 */ { MAD_F(0x058c6fd1) /* 0.346786323 */, 16 }, - /* 1852 */ { MAD_F(0x058d75c6) /* 0.347036147 */, 16 }, - /* 1853 */ { MAD_F(0x058e7bc8) /* 0.347286015 */, 16 }, - /* 1854 */ { MAD_F(0x058f81d5) /* 0.347535929 */, 16 }, - /* 1855 */ { MAD_F(0x059087ef) /* 0.347785887 */, 16 }, - - /* 1856 */ { MAD_F(0x05918e15) /* 0.348035890 */, 16 }, - /* 1857 */ { MAD_F(0x05929447) /* 0.348285939 */, 16 }, - /* 1858 */ { MAD_F(0x05939a84) /* 0.348536032 */, 16 }, - /* 1859 */ { MAD_F(0x0594a0ce) /* 0.348786170 */, 16 }, - /* 1860 */ { MAD_F(0x0595a724) /* 0.349036353 */, 16 }, - /* 1861 */ { MAD_F(0x0596ad86) /* 0.349286580 */, 16 }, - /* 1862 */ { MAD_F(0x0597b3f4) /* 0.349536853 */, 16 }, - /* 1863 */ { MAD_F(0x0598ba6e) /* 0.349787170 */, 16 }, - /* 1864 */ { MAD_F(0x0599c0f4) /* 0.350037532 */, 16 }, - /* 1865 */ { MAD_F(0x059ac786) /* 0.350287939 */, 16 }, - /* 1866 */ { MAD_F(0x059bce25) /* 0.350538391 */, 16 }, - /* 1867 */ { MAD_F(0x059cd4cf) /* 0.350788887 */, 16 }, - /* 1868 */ { MAD_F(0x059ddb85) /* 0.351039428 */, 16 }, - /* 1869 */ { MAD_F(0x059ee247) /* 0.351290014 */, 16 }, - /* 1870 */ { MAD_F(0x059fe915) /* 0.351540645 */, 16 }, - /* 1871 */ { MAD_F(0x05a0efef) /* 0.351791320 */, 16 }, - - /* 1872 */ { MAD_F(0x05a1f6d5) /* 0.352042040 */, 16 }, - /* 1873 */ { MAD_F(0x05a2fdc7) /* 0.352292804 */, 16 }, - /* 1874 */ { MAD_F(0x05a404c5) /* 0.352543613 */, 16 }, - /* 1875 */ { MAD_F(0x05a50bcf) /* 0.352794467 */, 16 }, - /* 1876 */ { MAD_F(0x05a612e5) /* 0.353045365 */, 16 }, - /* 1877 */ { MAD_F(0x05a71a07) /* 0.353296308 */, 16 }, - /* 1878 */ { MAD_F(0x05a82135) /* 0.353547296 */, 16 }, - /* 1879 */ { MAD_F(0x05a9286f) /* 0.353798328 */, 16 }, - /* 1880 */ { MAD_F(0x05aa2fb5) /* 0.354049405 */, 16 }, - /* 1881 */ { MAD_F(0x05ab3707) /* 0.354300526 */, 16 }, - /* 1882 */ { MAD_F(0x05ac3e65) /* 0.354551691 */, 16 }, - /* 1883 */ { MAD_F(0x05ad45ce) /* 0.354802901 */, 16 }, - /* 1884 */ { MAD_F(0x05ae4d44) /* 0.355054156 */, 16 }, - /* 1885 */ { MAD_F(0x05af54c6) /* 0.355305455 */, 16 }, - /* 1886 */ { MAD_F(0x05b05c53) /* 0.355556799 */, 16 }, - /* 1887 */ { MAD_F(0x05b163ed) /* 0.355808187 */, 16 }, - - /* 1888 */ { MAD_F(0x05b26b92) /* 0.356059619 */, 16 }, - /* 1889 */ { MAD_F(0x05b37343) /* 0.356311096 */, 16 }, - /* 1890 */ { MAD_F(0x05b47b00) /* 0.356562617 */, 16 }, - /* 1891 */ { MAD_F(0x05b582c9) /* 0.356814182 */, 16 }, - /* 1892 */ { MAD_F(0x05b68a9e) /* 0.357065792 */, 16 }, - /* 1893 */ { MAD_F(0x05b7927f) /* 0.357317446 */, 16 }, - /* 1894 */ { MAD_F(0x05b89a6c) /* 0.357569145 */, 16 }, - /* 1895 */ { MAD_F(0x05b9a265) /* 0.357820887 */, 16 }, - /* 1896 */ { MAD_F(0x05baaa69) /* 0.358072674 */, 16 }, - /* 1897 */ { MAD_F(0x05bbb27a) /* 0.358324506 */, 16 }, - /* 1898 */ { MAD_F(0x05bcba96) /* 0.358576381 */, 16 }, - /* 1899 */ { MAD_F(0x05bdc2be) /* 0.358828301 */, 16 }, - /* 1900 */ { MAD_F(0x05becaf2) /* 0.359080265 */, 16 }, - /* 1901 */ { MAD_F(0x05bfd332) /* 0.359332273 */, 16 }, - /* 1902 */ { MAD_F(0x05c0db7e) /* 0.359584326 */, 16 }, - /* 1903 */ { MAD_F(0x05c1e3d6) /* 0.359836423 */, 16 }, - - /* 1904 */ { MAD_F(0x05c2ec39) /* 0.360088563 */, 16 }, - /* 1905 */ { MAD_F(0x05c3f4a9) /* 0.360340748 */, 16 }, - /* 1906 */ { MAD_F(0x05c4fd24) /* 0.360592977 */, 16 }, - /* 1907 */ { MAD_F(0x05c605ab) /* 0.360845251 */, 16 }, - /* 1908 */ { MAD_F(0x05c70e3e) /* 0.361097568 */, 16 }, - /* 1909 */ { MAD_F(0x05c816dd) /* 0.361349929 */, 16 }, - /* 1910 */ { MAD_F(0x05c91f87) /* 0.361602335 */, 16 }, - /* 1911 */ { MAD_F(0x05ca283e) /* 0.361854784 */, 16 }, - /* 1912 */ { MAD_F(0x05cb3100) /* 0.362107278 */, 16 }, - /* 1913 */ { MAD_F(0x05cc39ce) /* 0.362359815 */, 16 }, - /* 1914 */ { MAD_F(0x05cd42a8) /* 0.362612397 */, 16 }, - /* 1915 */ { MAD_F(0x05ce4b8d) /* 0.362865022 */, 16 }, - /* 1916 */ { MAD_F(0x05cf547f) /* 0.363117692 */, 16 }, - /* 1917 */ { MAD_F(0x05d05d7c) /* 0.363370405 */, 16 }, - /* 1918 */ { MAD_F(0x05d16685) /* 0.363623163 */, 16 }, - /* 1919 */ { MAD_F(0x05d26f9a) /* 0.363875964 */, 16 }, - - /* 1920 */ { MAD_F(0x05d378bb) /* 0.364128809 */, 16 }, - /* 1921 */ { MAD_F(0x05d481e7) /* 0.364381698 */, 16 }, - /* 1922 */ { MAD_F(0x05d58b1f) /* 0.364634632 */, 16 }, - /* 1923 */ { MAD_F(0x05d69463) /* 0.364887608 */, 16 }, - /* 1924 */ { MAD_F(0x05d79db3) /* 0.365140629 */, 16 }, - /* 1925 */ { MAD_F(0x05d8a70f) /* 0.365393694 */, 16 }, - /* 1926 */ { MAD_F(0x05d9b076) /* 0.365646802 */, 16 }, - /* 1927 */ { MAD_F(0x05dab9e9) /* 0.365899955 */, 16 }, - /* 1928 */ { MAD_F(0x05dbc368) /* 0.366153151 */, 16 }, - /* 1929 */ { MAD_F(0x05dcccf2) /* 0.366406390 */, 16 }, - /* 1930 */ { MAD_F(0x05ddd689) /* 0.366659674 */, 16 }, - /* 1931 */ { MAD_F(0x05dee02b) /* 0.366913001 */, 16 }, - /* 1932 */ { MAD_F(0x05dfe9d8) /* 0.367166372 */, 16 }, - /* 1933 */ { MAD_F(0x05e0f392) /* 0.367419787 */, 16 }, - /* 1934 */ { MAD_F(0x05e1fd57) /* 0.367673246 */, 16 }, - /* 1935 */ { MAD_F(0x05e30728) /* 0.367926748 */, 16 }, - - /* 1936 */ { MAD_F(0x05e41105) /* 0.368180294 */, 16 }, - /* 1937 */ { MAD_F(0x05e51aed) /* 0.368433883 */, 16 }, - /* 1938 */ { MAD_F(0x05e624e1) /* 0.368687517 */, 16 }, - /* 1939 */ { MAD_F(0x05e72ee1) /* 0.368941193 */, 16 }, - /* 1940 */ { MAD_F(0x05e838ed) /* 0.369194914 */, 16 }, - /* 1941 */ { MAD_F(0x05e94304) /* 0.369448678 */, 16 }, - /* 1942 */ { MAD_F(0x05ea4d27) /* 0.369702485 */, 16 }, - /* 1943 */ { MAD_F(0x05eb5756) /* 0.369956336 */, 16 }, - /* 1944 */ { MAD_F(0x05ec6190) /* 0.370210231 */, 16 }, - /* 1945 */ { MAD_F(0x05ed6bd6) /* 0.370464169 */, 16 }, - /* 1946 */ { MAD_F(0x05ee7628) /* 0.370718151 */, 16 }, - /* 1947 */ { MAD_F(0x05ef8085) /* 0.370972177 */, 16 }, - /* 1948 */ { MAD_F(0x05f08aee) /* 0.371226245 */, 16 }, - /* 1949 */ { MAD_F(0x05f19563) /* 0.371480358 */, 16 }, - /* 1950 */ { MAD_F(0x05f29fe3) /* 0.371734513 */, 16 }, - /* 1951 */ { MAD_F(0x05f3aa6f) /* 0.371988712 */, 16 }, - - /* 1952 */ { MAD_F(0x05f4b507) /* 0.372242955 */, 16 }, - /* 1953 */ { MAD_F(0x05f5bfab) /* 0.372497241 */, 16 }, - /* 1954 */ { MAD_F(0x05f6ca5a) /* 0.372751570 */, 16 }, - /* 1955 */ { MAD_F(0x05f7d514) /* 0.373005943 */, 16 }, - /* 1956 */ { MAD_F(0x05f8dfdb) /* 0.373260359 */, 16 }, - /* 1957 */ { MAD_F(0x05f9eaad) /* 0.373514819 */, 16 }, - /* 1958 */ { MAD_F(0x05faf58a) /* 0.373769322 */, 16 }, - /* 1959 */ { MAD_F(0x05fc0073) /* 0.374023868 */, 16 }, - /* 1960 */ { MAD_F(0x05fd0b68) /* 0.374278458 */, 16 }, - /* 1961 */ { MAD_F(0x05fe1669) /* 0.374533091 */, 16 }, - /* 1962 */ { MAD_F(0x05ff2175) /* 0.374787767 */, 16 }, - /* 1963 */ { MAD_F(0x06002c8d) /* 0.375042486 */, 16 }, - /* 1964 */ { MAD_F(0x060137b0) /* 0.375297249 */, 16 }, - /* 1965 */ { MAD_F(0x060242df) /* 0.375552055 */, 16 }, - /* 1966 */ { MAD_F(0x06034e19) /* 0.375806904 */, 16 }, - /* 1967 */ { MAD_F(0x0604595f) /* 0.376061796 */, 16 }, - - /* 1968 */ { MAD_F(0x060564b1) /* 0.376316732 */, 16 }, - /* 1969 */ { MAD_F(0x0606700f) /* 0.376571710 */, 16 }, - /* 1970 */ { MAD_F(0x06077b77) /* 0.376826732 */, 16 }, - /* 1971 */ { MAD_F(0x060886ec) /* 0.377081797 */, 16 }, - /* 1972 */ { MAD_F(0x0609926c) /* 0.377336905 */, 16 }, - /* 1973 */ { MAD_F(0x060a9df8) /* 0.377592057 */, 16 }, - /* 1974 */ { MAD_F(0x060ba98f) /* 0.377847251 */, 16 }, - /* 1975 */ { MAD_F(0x060cb532) /* 0.378102489 */, 16 }, - /* 1976 */ { MAD_F(0x060dc0e0) /* 0.378357769 */, 16 }, - /* 1977 */ { MAD_F(0x060ecc9a) /* 0.378613093 */, 16 }, - /* 1978 */ { MAD_F(0x060fd860) /* 0.378868460 */, 16 }, - /* 1979 */ { MAD_F(0x0610e431) /* 0.379123870 */, 16 }, - /* 1980 */ { MAD_F(0x0611f00d) /* 0.379379322 */, 16 }, - /* 1981 */ { MAD_F(0x0612fbf5) /* 0.379634818 */, 16 }, - /* 1982 */ { MAD_F(0x061407e9) /* 0.379890357 */, 16 }, - /* 1983 */ { MAD_F(0x061513e8) /* 0.380145939 */, 16 }, - - /* 1984 */ { MAD_F(0x06161ff3) /* 0.380401563 */, 16 }, - /* 1985 */ { MAD_F(0x06172c09) /* 0.380657231 */, 16 }, - /* 1986 */ { MAD_F(0x0618382b) /* 0.380912942 */, 16 }, - /* 1987 */ { MAD_F(0x06194458) /* 0.381168695 */, 16 }, - /* 1988 */ { MAD_F(0x061a5091) /* 0.381424492 */, 16 }, - /* 1989 */ { MAD_F(0x061b5cd5) /* 0.381680331 */, 16 }, - /* 1990 */ { MAD_F(0x061c6925) /* 0.381936213 */, 16 }, - /* 1991 */ { MAD_F(0x061d7581) /* 0.382192138 */, 16 }, - /* 1992 */ { MAD_F(0x061e81e8) /* 0.382448106 */, 16 }, - /* 1993 */ { MAD_F(0x061f8e5a) /* 0.382704117 */, 16 }, - /* 1994 */ { MAD_F(0x06209ad8) /* 0.382960171 */, 16 }, - /* 1995 */ { MAD_F(0x0621a761) /* 0.383216267 */, 16 }, - /* 1996 */ { MAD_F(0x0622b3f6) /* 0.383472406 */, 16 }, - /* 1997 */ { MAD_F(0x0623c096) /* 0.383728588 */, 16 }, - /* 1998 */ { MAD_F(0x0624cd42) /* 0.383984813 */, 16 }, - /* 1999 */ { MAD_F(0x0625d9f9) /* 0.384241080 */, 16 }, - - /* 2000 */ { MAD_F(0x0626e6bc) /* 0.384497391 */, 16 }, - /* 2001 */ { MAD_F(0x0627f38a) /* 0.384753744 */, 16 }, - /* 2002 */ { MAD_F(0x06290064) /* 0.385010139 */, 16 }, - /* 2003 */ { MAD_F(0x062a0d49) /* 0.385266578 */, 16 }, - /* 2004 */ { MAD_F(0x062b1a3a) /* 0.385523059 */, 16 }, - /* 2005 */ { MAD_F(0x062c2736) /* 0.385779582 */, 16 }, - /* 2006 */ { MAD_F(0x062d343d) /* 0.386036149 */, 16 }, - /* 2007 */ { MAD_F(0x062e4150) /* 0.386292758 */, 16 }, - /* 2008 */ { MAD_F(0x062f4e6f) /* 0.386549409 */, 16 }, - /* 2009 */ { MAD_F(0x06305b99) /* 0.386806104 */, 16 }, - /* 2010 */ { MAD_F(0x063168ce) /* 0.387062840 */, 16 }, - /* 2011 */ { MAD_F(0x0632760f) /* 0.387319620 */, 16 }, - /* 2012 */ { MAD_F(0x0633835b) /* 0.387576442 */, 16 }, - /* 2013 */ { MAD_F(0x063490b2) /* 0.387833306 */, 16 }, - /* 2014 */ { MAD_F(0x06359e15) /* 0.388090213 */, 16 }, - /* 2015 */ { MAD_F(0x0636ab83) /* 0.388347163 */, 16 }, - - /* 2016 */ { MAD_F(0x0637b8fd) /* 0.388604155 */, 16 }, - /* 2017 */ { MAD_F(0x0638c682) /* 0.388861190 */, 16 }, - /* 2018 */ { MAD_F(0x0639d413) /* 0.389118267 */, 16 }, - /* 2019 */ { MAD_F(0x063ae1af) /* 0.389375386 */, 16 }, - /* 2020 */ { MAD_F(0x063bef56) /* 0.389632548 */, 16 }, - /* 2021 */ { MAD_F(0x063cfd09) /* 0.389889752 */, 16 }, - /* 2022 */ { MAD_F(0x063e0ac7) /* 0.390146999 */, 16 }, - /* 2023 */ { MAD_F(0x063f1891) /* 0.390404289 */, 16 }, - /* 2024 */ { MAD_F(0x06402666) /* 0.390661620 */, 16 }, - /* 2025 */ { MAD_F(0x06413446) /* 0.390918994 */, 16 }, - /* 2026 */ { MAD_F(0x06424232) /* 0.391176411 */, 16 }, - /* 2027 */ { MAD_F(0x06435029) /* 0.391433869 */, 16 }, - /* 2028 */ { MAD_F(0x06445e2b) /* 0.391691371 */, 16 }, - /* 2029 */ { MAD_F(0x06456c39) /* 0.391948914 */, 16 }, - /* 2030 */ { MAD_F(0x06467a52) /* 0.392206500 */, 16 }, - /* 2031 */ { MAD_F(0x06478877) /* 0.392464128 */, 16 }, - - /* 2032 */ { MAD_F(0x064896a7) /* 0.392721798 */, 16 }, - /* 2033 */ { MAD_F(0x0649a4e2) /* 0.392979511 */, 16 }, - /* 2034 */ { MAD_F(0x064ab328) /* 0.393237266 */, 16 }, - /* 2035 */ { MAD_F(0x064bc17a) /* 0.393495063 */, 16 }, - /* 2036 */ { MAD_F(0x064ccfd8) /* 0.393752902 */, 16 }, - /* 2037 */ { MAD_F(0x064dde40) /* 0.394010784 */, 16 }, - /* 2038 */ { MAD_F(0x064eecb4) /* 0.394268707 */, 16 }, - /* 2039 */ { MAD_F(0x064ffb33) /* 0.394526673 */, 16 }, - /* 2040 */ { MAD_F(0x065109be) /* 0.394784681 */, 16 }, - /* 2041 */ { MAD_F(0x06521854) /* 0.395042732 */, 16 }, - /* 2042 */ { MAD_F(0x065326f5) /* 0.395300824 */, 16 }, - /* 2043 */ { MAD_F(0x065435a1) /* 0.395558959 */, 16 }, - /* 2044 */ { MAD_F(0x06554459) /* 0.395817135 */, 16 }, - /* 2045 */ { MAD_F(0x0656531c) /* 0.396075354 */, 16 }, - /* 2046 */ { MAD_F(0x065761ea) /* 0.396333615 */, 16 }, - /* 2047 */ { MAD_F(0x065870c4) /* 0.396591918 */, 16 }, - - /* 2048 */ { MAD_F(0x06597fa9) /* 0.396850263 */, 16 }, - /* 2049 */ { MAD_F(0x065a8e99) /* 0.397108650 */, 16 }, - /* 2050 */ { MAD_F(0x065b9d95) /* 0.397367079 */, 16 }, - /* 2051 */ { MAD_F(0x065cac9c) /* 0.397625550 */, 16 }, - /* 2052 */ { MAD_F(0x065dbbae) /* 0.397884063 */, 16 }, - /* 2053 */ { MAD_F(0x065ecacb) /* 0.398142619 */, 16 }, - /* 2054 */ { MAD_F(0x065fd9f4) /* 0.398401216 */, 16 }, - /* 2055 */ { MAD_F(0x0660e928) /* 0.398659855 */, 16 }, - /* 2056 */ { MAD_F(0x0661f867) /* 0.398918536 */, 16 }, - /* 2057 */ { MAD_F(0x066307b1) /* 0.399177259 */, 16 }, - /* 2058 */ { MAD_F(0x06641707) /* 0.399436024 */, 16 }, - /* 2059 */ { MAD_F(0x06652668) /* 0.399694831 */, 16 }, - /* 2060 */ { MAD_F(0x066635d4) /* 0.399953679 */, 16 }, - /* 2061 */ { MAD_F(0x0667454c) /* 0.400212570 */, 16 }, - /* 2062 */ { MAD_F(0x066854ce) /* 0.400471503 */, 16 }, - /* 2063 */ { MAD_F(0x0669645c) /* 0.400730477 */, 16 }, - - /* 2064 */ { MAD_F(0x066a73f5) /* 0.400989493 */, 16 }, - /* 2065 */ { MAD_F(0x066b839a) /* 0.401248551 */, 16 }, - /* 2066 */ { MAD_F(0x066c9349) /* 0.401507651 */, 16 }, - /* 2067 */ { MAD_F(0x066da304) /* 0.401766793 */, 16 }, - /* 2068 */ { MAD_F(0x066eb2ca) /* 0.402025976 */, 16 }, - /* 2069 */ { MAD_F(0x066fc29b) /* 0.402285202 */, 16 }, - /* 2070 */ { MAD_F(0x0670d278) /* 0.402544469 */, 16 }, - /* 2071 */ { MAD_F(0x0671e25f) /* 0.402803777 */, 16 }, - /* 2072 */ { MAD_F(0x0672f252) /* 0.403063128 */, 16 }, - /* 2073 */ { MAD_F(0x06740250) /* 0.403322520 */, 16 }, - /* 2074 */ { MAD_F(0x0675125a) /* 0.403581954 */, 16 }, - /* 2075 */ { MAD_F(0x0676226e) /* 0.403841430 */, 16 }, - /* 2076 */ { MAD_F(0x0677328e) /* 0.404100947 */, 16 }, - /* 2077 */ { MAD_F(0x067842b9) /* 0.404360506 */, 16 }, - /* 2078 */ { MAD_F(0x067952ef) /* 0.404620107 */, 16 }, - /* 2079 */ { MAD_F(0x067a6330) /* 0.404879749 */, 16 }, - - /* 2080 */ { MAD_F(0x067b737c) /* 0.405139433 */, 16 }, - /* 2081 */ { MAD_F(0x067c83d4) /* 0.405399159 */, 16 }, - /* 2082 */ { MAD_F(0x067d9436) /* 0.405658926 */, 16 }, - /* 2083 */ { MAD_F(0x067ea4a4) /* 0.405918735 */, 16 }, - /* 2084 */ { MAD_F(0x067fb51d) /* 0.406178585 */, 16 }, - /* 2085 */ { MAD_F(0x0680c5a2) /* 0.406438477 */, 16 }, - /* 2086 */ { MAD_F(0x0681d631) /* 0.406698410 */, 16 }, - /* 2087 */ { MAD_F(0x0682e6cb) /* 0.406958385 */, 16 }, - /* 2088 */ { MAD_F(0x0683f771) /* 0.407218402 */, 16 }, - /* 2089 */ { MAD_F(0x06850822) /* 0.407478460 */, 16 }, - /* 2090 */ { MAD_F(0x068618de) /* 0.407738559 */, 16 }, - /* 2091 */ { MAD_F(0x068729a5) /* 0.407998700 */, 16 }, - /* 2092 */ { MAD_F(0x06883a77) /* 0.408258883 */, 16 }, - /* 2093 */ { MAD_F(0x06894b55) /* 0.408519107 */, 16 }, - /* 2094 */ { MAD_F(0x068a5c3d) /* 0.408779372 */, 16 }, - /* 2095 */ { MAD_F(0x068b6d31) /* 0.409039679 */, 16 }, - - /* 2096 */ { MAD_F(0x068c7e2f) /* 0.409300027 */, 16 }, - /* 2097 */ { MAD_F(0x068d8f39) /* 0.409560417 */, 16 }, - /* 2098 */ { MAD_F(0x068ea04e) /* 0.409820848 */, 16 }, - /* 2099 */ { MAD_F(0x068fb16e) /* 0.410081321 */, 16 }, - /* 2100 */ { MAD_F(0x0690c299) /* 0.410341834 */, 16 }, - /* 2101 */ { MAD_F(0x0691d3cf) /* 0.410602390 */, 16 }, - /* 2102 */ { MAD_F(0x0692e511) /* 0.410862986 */, 16 }, - /* 2103 */ { MAD_F(0x0693f65d) /* 0.411123624 */, 16 }, - /* 2104 */ { MAD_F(0x069507b5) /* 0.411384303 */, 16 }, - /* 2105 */ { MAD_F(0x06961917) /* 0.411645024 */, 16 }, - /* 2106 */ { MAD_F(0x06972a85) /* 0.411905785 */, 16 }, - /* 2107 */ { MAD_F(0x06983bfe) /* 0.412166588 */, 16 }, - /* 2108 */ { MAD_F(0x06994d82) /* 0.412427433 */, 16 }, - /* 2109 */ { MAD_F(0x069a5f11) /* 0.412688318 */, 16 }, - /* 2110 */ { MAD_F(0x069b70ab) /* 0.412949245 */, 16 }, - /* 2111 */ { MAD_F(0x069c8250) /* 0.413210213 */, 16 }, - - /* 2112 */ { MAD_F(0x069d9400) /* 0.413471222 */, 16 }, - /* 2113 */ { MAD_F(0x069ea5bb) /* 0.413732273 */, 16 }, - /* 2114 */ { MAD_F(0x069fb781) /* 0.413993364 */, 16 }, - /* 2115 */ { MAD_F(0x06a0c953) /* 0.414254497 */, 16 }, - /* 2116 */ { MAD_F(0x06a1db2f) /* 0.414515671 */, 16 }, - /* 2117 */ { MAD_F(0x06a2ed16) /* 0.414776886 */, 16 }, - /* 2118 */ { MAD_F(0x06a3ff09) /* 0.415038142 */, 16 }, - /* 2119 */ { MAD_F(0x06a51106) /* 0.415299440 */, 16 }, - /* 2120 */ { MAD_F(0x06a6230f) /* 0.415560778 */, 16 }, - /* 2121 */ { MAD_F(0x06a73522) /* 0.415822157 */, 16 }, - /* 2122 */ { MAD_F(0x06a84741) /* 0.416083578 */, 16 }, - /* 2123 */ { MAD_F(0x06a9596a) /* 0.416345040 */, 16 }, - /* 2124 */ { MAD_F(0x06aa6b9f) /* 0.416606542 */, 16 }, - /* 2125 */ { MAD_F(0x06ab7ddf) /* 0.416868086 */, 16 }, - /* 2126 */ { MAD_F(0x06ac9029) /* 0.417129671 */, 16 }, - /* 2127 */ { MAD_F(0x06ada27f) /* 0.417391297 */, 16 }, - - /* 2128 */ { MAD_F(0x06aeb4e0) /* 0.417652964 */, 16 }, - /* 2129 */ { MAD_F(0x06afc74b) /* 0.417914672 */, 16 }, - /* 2130 */ { MAD_F(0x06b0d9c2) /* 0.418176420 */, 16 }, - /* 2131 */ { MAD_F(0x06b1ec43) /* 0.418438210 */, 16 }, - /* 2132 */ { MAD_F(0x06b2fed0) /* 0.418700041 */, 16 }, - /* 2133 */ { MAD_F(0x06b41168) /* 0.418961912 */, 16 }, - /* 2134 */ { MAD_F(0x06b5240a) /* 0.419223825 */, 16 }, - /* 2135 */ { MAD_F(0x06b636b8) /* 0.419485778 */, 16 }, - /* 2136 */ { MAD_F(0x06b74971) /* 0.419747773 */, 16 }, - /* 2137 */ { MAD_F(0x06b85c34) /* 0.420009808 */, 16 }, - /* 2138 */ { MAD_F(0x06b96f03) /* 0.420271884 */, 16 }, - /* 2139 */ { MAD_F(0x06ba81dc) /* 0.420534001 */, 16 }, - /* 2140 */ { MAD_F(0x06bb94c1) /* 0.420796159 */, 16 }, - /* 2141 */ { MAD_F(0x06bca7b0) /* 0.421058358 */, 16 }, - /* 2142 */ { MAD_F(0x06bdbaaa) /* 0.421320597 */, 16 }, - /* 2143 */ { MAD_F(0x06becdb0) /* 0.421582878 */, 16 }, - - /* 2144 */ { MAD_F(0x06bfe0c0) /* 0.421845199 */, 16 }, - /* 2145 */ { MAD_F(0x06c0f3db) /* 0.422107561 */, 16 }, - /* 2146 */ { MAD_F(0x06c20702) /* 0.422369964 */, 16 }, - /* 2147 */ { MAD_F(0x06c31a33) /* 0.422632407 */, 16 }, - /* 2148 */ { MAD_F(0x06c42d6f) /* 0.422894891 */, 16 }, - /* 2149 */ { MAD_F(0x06c540b6) /* 0.423157416 */, 16 }, - /* 2150 */ { MAD_F(0x06c65408) /* 0.423419982 */, 16 }, - /* 2151 */ { MAD_F(0x06c76765) /* 0.423682588 */, 16 }, - /* 2152 */ { MAD_F(0x06c87acc) /* 0.423945235 */, 16 }, - /* 2153 */ { MAD_F(0x06c98e3f) /* 0.424207923 */, 16 }, - /* 2154 */ { MAD_F(0x06caa1bd) /* 0.424470652 */, 16 }, - /* 2155 */ { MAD_F(0x06cbb545) /* 0.424733421 */, 16 }, - /* 2156 */ { MAD_F(0x06ccc8d9) /* 0.424996230 */, 16 }, - /* 2157 */ { MAD_F(0x06cddc77) /* 0.425259081 */, 16 }, - /* 2158 */ { MAD_F(0x06cef020) /* 0.425521972 */, 16 }, - /* 2159 */ { MAD_F(0x06d003d4) /* 0.425784903 */, 16 }, - - /* 2160 */ { MAD_F(0x06d11794) /* 0.426047876 */, 16 }, - /* 2161 */ { MAD_F(0x06d22b5e) /* 0.426310889 */, 16 }, - /* 2162 */ { MAD_F(0x06d33f32) /* 0.426573942 */, 16 }, - /* 2163 */ { MAD_F(0x06d45312) /* 0.426837036 */, 16 }, - /* 2164 */ { MAD_F(0x06d566fd) /* 0.427100170 */, 16 }, - /* 2165 */ { MAD_F(0x06d67af2) /* 0.427363345 */, 16 }, - /* 2166 */ { MAD_F(0x06d78ef3) /* 0.427626561 */, 16 }, - /* 2167 */ { MAD_F(0x06d8a2fe) /* 0.427889817 */, 16 }, - /* 2168 */ { MAD_F(0x06d9b714) /* 0.428153114 */, 16 }, - /* 2169 */ { MAD_F(0x06dacb35) /* 0.428416451 */, 16 }, - /* 2170 */ { MAD_F(0x06dbdf61) /* 0.428679828 */, 16 }, - /* 2171 */ { MAD_F(0x06dcf398) /* 0.428943246 */, 16 }, - /* 2172 */ { MAD_F(0x06de07d9) /* 0.429206704 */, 16 }, - /* 2173 */ { MAD_F(0x06df1c26) /* 0.429470203 */, 16 }, - /* 2174 */ { MAD_F(0x06e0307d) /* 0.429733743 */, 16 }, - /* 2175 */ { MAD_F(0x06e144df) /* 0.429997322 */, 16 }, - - /* 2176 */ { MAD_F(0x06e2594c) /* 0.430260942 */, 16 }, - /* 2177 */ { MAD_F(0x06e36dc4) /* 0.430524603 */, 16 }, - /* 2178 */ { MAD_F(0x06e48246) /* 0.430788304 */, 16 }, - /* 2179 */ { MAD_F(0x06e596d4) /* 0.431052045 */, 16 }, - /* 2180 */ { MAD_F(0x06e6ab6c) /* 0.431315826 */, 16 }, - /* 2181 */ { MAD_F(0x06e7c00f) /* 0.431579648 */, 16 }, - /* 2182 */ { MAD_F(0x06e8d4bd) /* 0.431843511 */, 16 }, - /* 2183 */ { MAD_F(0x06e9e976) /* 0.432107413 */, 16 }, - /* 2184 */ { MAD_F(0x06eafe3a) /* 0.432371356 */, 16 }, - /* 2185 */ { MAD_F(0x06ec1308) /* 0.432635339 */, 16 }, - /* 2186 */ { MAD_F(0x06ed27e2) /* 0.432899362 */, 16 }, - /* 2187 */ { MAD_F(0x06ee3cc6) /* 0.433163426 */, 16 }, - /* 2188 */ { MAD_F(0x06ef51b4) /* 0.433427530 */, 16 }, - /* 2189 */ { MAD_F(0x06f066ae) /* 0.433691674 */, 16 }, - /* 2190 */ { MAD_F(0x06f17bb3) /* 0.433955859 */, 16 }, - /* 2191 */ { MAD_F(0x06f290c2) /* 0.434220083 */, 16 }, - - /* 2192 */ { MAD_F(0x06f3a5dc) /* 0.434484348 */, 16 }, - /* 2193 */ { MAD_F(0x06f4bb01) /* 0.434748653 */, 16 }, - /* 2194 */ { MAD_F(0x06f5d030) /* 0.435012998 */, 16 }, - /* 2195 */ { MAD_F(0x06f6e56b) /* 0.435277383 */, 16 }, - /* 2196 */ { MAD_F(0x06f7fab0) /* 0.435541809 */, 16 }, - /* 2197 */ { MAD_F(0x06f91000) /* 0.435806274 */, 16 }, - /* 2198 */ { MAD_F(0x06fa255a) /* 0.436070780 */, 16 }, - /* 2199 */ { MAD_F(0x06fb3ac0) /* 0.436335326 */, 16 }, - /* 2200 */ { MAD_F(0x06fc5030) /* 0.436599912 */, 16 }, - /* 2201 */ { MAD_F(0x06fd65ab) /* 0.436864538 */, 16 }, - /* 2202 */ { MAD_F(0x06fe7b31) /* 0.437129204 */, 16 }, - /* 2203 */ { MAD_F(0x06ff90c2) /* 0.437393910 */, 16 }, - /* 2204 */ { MAD_F(0x0700a65d) /* 0.437658657 */, 16 }, - /* 2205 */ { MAD_F(0x0701bc03) /* 0.437923443 */, 16 }, - /* 2206 */ { MAD_F(0x0702d1b4) /* 0.438188269 */, 16 }, - /* 2207 */ { MAD_F(0x0703e76f) /* 0.438453136 */, 16 }, - - /* 2208 */ { MAD_F(0x0704fd35) /* 0.438718042 */, 16 }, - /* 2209 */ { MAD_F(0x07061306) /* 0.438982988 */, 16 }, - /* 2210 */ { MAD_F(0x070728e2) /* 0.439247975 */, 16 }, - /* 2211 */ { MAD_F(0x07083ec9) /* 0.439513001 */, 16 }, - /* 2212 */ { MAD_F(0x070954ba) /* 0.439778067 */, 16 }, - /* 2213 */ { MAD_F(0x070a6ab6) /* 0.440043173 */, 16 }, - /* 2214 */ { MAD_F(0x070b80bc) /* 0.440308320 */, 16 }, - /* 2215 */ { MAD_F(0x070c96ce) /* 0.440573506 */, 16 }, - /* 2216 */ { MAD_F(0x070dacea) /* 0.440838732 */, 16 }, - /* 2217 */ { MAD_F(0x070ec310) /* 0.441103997 */, 16 }, - /* 2218 */ { MAD_F(0x070fd942) /* 0.441369303 */, 16 }, - /* 2219 */ { MAD_F(0x0710ef7e) /* 0.441634649 */, 16 }, - /* 2220 */ { MAD_F(0x071205c5) /* 0.441900034 */, 16 }, - /* 2221 */ { MAD_F(0x07131c17) /* 0.442165460 */, 16 }, - /* 2222 */ { MAD_F(0x07143273) /* 0.442430925 */, 16 }, - /* 2223 */ { MAD_F(0x071548da) /* 0.442696430 */, 16 }, - - /* 2224 */ { MAD_F(0x07165f4b) /* 0.442961975 */, 16 }, - /* 2225 */ { MAD_F(0x071775c8) /* 0.443227559 */, 16 }, - /* 2226 */ { MAD_F(0x07188c4f) /* 0.443493184 */, 16 }, - /* 2227 */ { MAD_F(0x0719a2e0) /* 0.443758848 */, 16 }, - /* 2228 */ { MAD_F(0x071ab97d) /* 0.444024552 */, 16 }, - /* 2229 */ { MAD_F(0x071bd024) /* 0.444290296 */, 16 }, - /* 2230 */ { MAD_F(0x071ce6d6) /* 0.444556079 */, 16 }, - /* 2231 */ { MAD_F(0x071dfd92) /* 0.444821902 */, 16 }, - /* 2232 */ { MAD_F(0x071f1459) /* 0.445087765 */, 16 }, - /* 2233 */ { MAD_F(0x07202b2b) /* 0.445353668 */, 16 }, - /* 2234 */ { MAD_F(0x07214207) /* 0.445619610 */, 16 }, - /* 2235 */ { MAD_F(0x072258ee) /* 0.445885592 */, 16 }, - /* 2236 */ { MAD_F(0x07236fe0) /* 0.446151614 */, 16 }, - /* 2237 */ { MAD_F(0x072486dc) /* 0.446417675 */, 16 }, - /* 2238 */ { MAD_F(0x07259de3) /* 0.446683776 */, 16 }, - /* 2239 */ { MAD_F(0x0726b4f4) /* 0.446949917 */, 16 }, - - /* 2240 */ { MAD_F(0x0727cc11) /* 0.447216097 */, 16 }, - /* 2241 */ { MAD_F(0x0728e338) /* 0.447482317 */, 16 }, - /* 2242 */ { MAD_F(0x0729fa69) /* 0.447748576 */, 16 }, - /* 2243 */ { MAD_F(0x072b11a5) /* 0.448014875 */, 16 }, - /* 2244 */ { MAD_F(0x072c28ec) /* 0.448281214 */, 16 }, - /* 2245 */ { MAD_F(0x072d403d) /* 0.448547592 */, 16 }, - /* 2246 */ { MAD_F(0x072e5799) /* 0.448814010 */, 16 }, - /* 2247 */ { MAD_F(0x072f6f00) /* 0.449080467 */, 16 }, - /* 2248 */ { MAD_F(0x07308671) /* 0.449346964 */, 16 }, - /* 2249 */ { MAD_F(0x07319ded) /* 0.449613501 */, 16 }, - /* 2250 */ { MAD_F(0x0732b573) /* 0.449880076 */, 16 }, - /* 2251 */ { MAD_F(0x0733cd04) /* 0.450146692 */, 16 }, - /* 2252 */ { MAD_F(0x0734e4a0) /* 0.450413347 */, 16 }, - /* 2253 */ { MAD_F(0x0735fc46) /* 0.450680041 */, 16 }, - /* 2254 */ { MAD_F(0x073713f7) /* 0.450946775 */, 16 }, - /* 2255 */ { MAD_F(0x07382bb2) /* 0.451213548 */, 16 }, - - /* 2256 */ { MAD_F(0x07394378) /* 0.451480360 */, 16 }, - /* 2257 */ { MAD_F(0x073a5b49) /* 0.451747213 */, 16 }, - /* 2258 */ { MAD_F(0x073b7324) /* 0.452014104 */, 16 }, - /* 2259 */ { MAD_F(0x073c8b0a) /* 0.452281035 */, 16 }, - /* 2260 */ { MAD_F(0x073da2fa) /* 0.452548005 */, 16 }, - /* 2261 */ { MAD_F(0x073ebaf5) /* 0.452815015 */, 16 }, - /* 2262 */ { MAD_F(0x073fd2fa) /* 0.453082064 */, 16 }, - /* 2263 */ { MAD_F(0x0740eb0a) /* 0.453349152 */, 16 }, - /* 2264 */ { MAD_F(0x07420325) /* 0.453616280 */, 16 }, - /* 2265 */ { MAD_F(0x07431b4a) /* 0.453883447 */, 16 }, - /* 2266 */ { MAD_F(0x0744337a) /* 0.454150653 */, 16 }, - /* 2267 */ { MAD_F(0x07454bb4) /* 0.454417899 */, 16 }, - /* 2268 */ { MAD_F(0x074663f8) /* 0.454685184 */, 16 }, - /* 2269 */ { MAD_F(0x07477c48) /* 0.454952508 */, 16 }, - /* 2270 */ { MAD_F(0x074894a2) /* 0.455219872 */, 16 }, - /* 2271 */ { MAD_F(0x0749ad06) /* 0.455487275 */, 16 }, - - /* 2272 */ { MAD_F(0x074ac575) /* 0.455754717 */, 16 }, - /* 2273 */ { MAD_F(0x074bddee) /* 0.456022198 */, 16 }, - /* 2274 */ { MAD_F(0x074cf672) /* 0.456289719 */, 16 }, - /* 2275 */ { MAD_F(0x074e0f01) /* 0.456557278 */, 16 }, - /* 2276 */ { MAD_F(0x074f279a) /* 0.456824877 */, 16 }, - /* 2277 */ { MAD_F(0x0750403e) /* 0.457092516 */, 16 }, - /* 2278 */ { MAD_F(0x075158ec) /* 0.457360193 */, 16 }, - /* 2279 */ { MAD_F(0x075271a4) /* 0.457627909 */, 16 }, - /* 2280 */ { MAD_F(0x07538a67) /* 0.457895665 */, 16 }, - /* 2281 */ { MAD_F(0x0754a335) /* 0.458163460 */, 16 }, - /* 2282 */ { MAD_F(0x0755bc0d) /* 0.458431294 */, 16 }, - /* 2283 */ { MAD_F(0x0756d4f0) /* 0.458699167 */, 16 }, - /* 2284 */ { MAD_F(0x0757eddd) /* 0.458967079 */, 16 }, - /* 2285 */ { MAD_F(0x075906d5) /* 0.459235030 */, 16 }, - /* 2286 */ { MAD_F(0x075a1fd7) /* 0.459503021 */, 16 }, - /* 2287 */ { MAD_F(0x075b38e3) /* 0.459771050 */, 16 }, - - /* 2288 */ { MAD_F(0x075c51fa) /* 0.460039119 */, 16 }, - /* 2289 */ { MAD_F(0x075d6b1c) /* 0.460307226 */, 16 }, - /* 2290 */ { MAD_F(0x075e8448) /* 0.460575373 */, 16 }, - /* 2291 */ { MAD_F(0x075f9d7f) /* 0.460843559 */, 16 }, - /* 2292 */ { MAD_F(0x0760b6c0) /* 0.461111783 */, 16 }, - /* 2293 */ { MAD_F(0x0761d00b) /* 0.461380047 */, 16 }, - /* 2294 */ { MAD_F(0x0762e961) /* 0.461648350 */, 16 }, - /* 2295 */ { MAD_F(0x076402c1) /* 0.461916691 */, 16 }, - /* 2296 */ { MAD_F(0x07651c2c) /* 0.462185072 */, 16 }, - /* 2297 */ { MAD_F(0x076635a2) /* 0.462453492 */, 16 }, - /* 2298 */ { MAD_F(0x07674f22) /* 0.462721950 */, 16 }, - /* 2299 */ { MAD_F(0x076868ac) /* 0.462990448 */, 16 }, - /* 2300 */ { MAD_F(0x07698240) /* 0.463258984 */, 16 }, - /* 2301 */ { MAD_F(0x076a9be0) /* 0.463527560 */, 16 }, - /* 2302 */ { MAD_F(0x076bb589) /* 0.463796174 */, 16 }, - /* 2303 */ { MAD_F(0x076ccf3d) /* 0.464064827 */, 16 }, - - /* 2304 */ { MAD_F(0x076de8fc) /* 0.464333519 */, 16 }, - /* 2305 */ { MAD_F(0x076f02c5) /* 0.464602250 */, 16 }, - /* 2306 */ { MAD_F(0x07701c98) /* 0.464871020 */, 16 }, - /* 2307 */ { MAD_F(0x07713676) /* 0.465139829 */, 16 }, - /* 2308 */ { MAD_F(0x0772505e) /* 0.465408676 */, 16 }, - /* 2309 */ { MAD_F(0x07736a51) /* 0.465677563 */, 16 }, - /* 2310 */ { MAD_F(0x0774844e) /* 0.465946488 */, 16 }, - /* 2311 */ { MAD_F(0x07759e55) /* 0.466215452 */, 16 }, - /* 2312 */ { MAD_F(0x0776b867) /* 0.466484455 */, 16 }, - /* 2313 */ { MAD_F(0x0777d283) /* 0.466753496 */, 16 }, - /* 2314 */ { MAD_F(0x0778ecaa) /* 0.467022577 */, 16 }, - /* 2315 */ { MAD_F(0x077a06db) /* 0.467291696 */, 16 }, - /* 2316 */ { MAD_F(0x077b2117) /* 0.467560854 */, 16 }, - /* 2317 */ { MAD_F(0x077c3b5d) /* 0.467830050 */, 16 }, - /* 2318 */ { MAD_F(0x077d55ad) /* 0.468099285 */, 16 }, - /* 2319 */ { MAD_F(0x077e7008) /* 0.468368560 */, 16 }, - - /* 2320 */ { MAD_F(0x077f8a6d) /* 0.468637872 */, 16 }, - /* 2321 */ { MAD_F(0x0780a4dc) /* 0.468907224 */, 16 }, - /* 2322 */ { MAD_F(0x0781bf56) /* 0.469176614 */, 16 }, - /* 2323 */ { MAD_F(0x0782d9da) /* 0.469446043 */, 16 }, - /* 2324 */ { MAD_F(0x0783f469) /* 0.469715510 */, 16 }, - /* 2325 */ { MAD_F(0x07850f02) /* 0.469985016 */, 16 }, - /* 2326 */ { MAD_F(0x078629a5) /* 0.470254561 */, 16 }, - /* 2327 */ { MAD_F(0x07874453) /* 0.470524145 */, 16 }, - /* 2328 */ { MAD_F(0x07885f0b) /* 0.470793767 */, 16 }, - /* 2329 */ { MAD_F(0x078979ce) /* 0.471063427 */, 16 }, - /* 2330 */ { MAD_F(0x078a949a) /* 0.471333126 */, 16 }, - /* 2331 */ { MAD_F(0x078baf72) /* 0.471602864 */, 16 }, - /* 2332 */ { MAD_F(0x078cca53) /* 0.471872641 */, 16 }, - /* 2333 */ { MAD_F(0x078de53f) /* 0.472142456 */, 16 }, - /* 2334 */ { MAD_F(0x078f0035) /* 0.472412309 */, 16 }, - /* 2335 */ { MAD_F(0x07901b36) /* 0.472682201 */, 16 }, - - /* 2336 */ { MAD_F(0x07913641) /* 0.472952132 */, 16 }, - /* 2337 */ { MAD_F(0x07925156) /* 0.473222101 */, 16 }, - /* 2338 */ { MAD_F(0x07936c76) /* 0.473492108 */, 16 }, - /* 2339 */ { MAD_F(0x079487a0) /* 0.473762155 */, 16 }, - /* 2340 */ { MAD_F(0x0795a2d4) /* 0.474032239 */, 16 }, - /* 2341 */ { MAD_F(0x0796be13) /* 0.474302362 */, 16 }, - /* 2342 */ { MAD_F(0x0797d95c) /* 0.474572524 */, 16 }, - /* 2343 */ { MAD_F(0x0798f4af) /* 0.474842724 */, 16 }, - /* 2344 */ { MAD_F(0x079a100c) /* 0.475112962 */, 16 }, - /* 2345 */ { MAD_F(0x079b2b74) /* 0.475383239 */, 16 }, - /* 2346 */ { MAD_F(0x079c46e7) /* 0.475653554 */, 16 }, - /* 2347 */ { MAD_F(0x079d6263) /* 0.475923908 */, 16 }, - /* 2348 */ { MAD_F(0x079e7dea) /* 0.476194300 */, 16 }, - /* 2349 */ { MAD_F(0x079f997b) /* 0.476464731 */, 16 }, - /* 2350 */ { MAD_F(0x07a0b516) /* 0.476735200 */, 16 }, - /* 2351 */ { MAD_F(0x07a1d0bc) /* 0.477005707 */, 16 }, - - /* 2352 */ { MAD_F(0x07a2ec6c) /* 0.477276252 */, 16 }, - /* 2353 */ { MAD_F(0x07a40827) /* 0.477546836 */, 16 }, - /* 2354 */ { MAD_F(0x07a523eb) /* 0.477817459 */, 16 }, - /* 2355 */ { MAD_F(0x07a63fba) /* 0.478088119 */, 16 }, - /* 2356 */ { MAD_F(0x07a75b93) /* 0.478358818 */, 16 }, - /* 2357 */ { MAD_F(0x07a87777) /* 0.478629555 */, 16 }, - /* 2358 */ { MAD_F(0x07a99364) /* 0.478900331 */, 16 }, - /* 2359 */ { MAD_F(0x07aaaf5c) /* 0.479171145 */, 16 }, - /* 2360 */ { MAD_F(0x07abcb5f) /* 0.479441997 */, 16 }, - /* 2361 */ { MAD_F(0x07ace76b) /* 0.479712887 */, 16 }, - /* 2362 */ { MAD_F(0x07ae0382) /* 0.479983816 */, 16 }, - /* 2363 */ { MAD_F(0x07af1fa3) /* 0.480254782 */, 16 }, - /* 2364 */ { MAD_F(0x07b03bcf) /* 0.480525787 */, 16 }, - /* 2365 */ { MAD_F(0x07b15804) /* 0.480796831 */, 16 }, - /* 2366 */ { MAD_F(0x07b27444) /* 0.481067912 */, 16 }, - /* 2367 */ { MAD_F(0x07b3908e) /* 0.481339032 */, 16 }, - - /* 2368 */ { MAD_F(0x07b4ace3) /* 0.481610189 */, 16 }, - /* 2369 */ { MAD_F(0x07b5c941) /* 0.481881385 */, 16 }, - /* 2370 */ { MAD_F(0x07b6e5aa) /* 0.482152620 */, 16 }, - /* 2371 */ { MAD_F(0x07b8021d) /* 0.482423892 */, 16 }, - /* 2372 */ { MAD_F(0x07b91e9b) /* 0.482695202 */, 16 }, - /* 2373 */ { MAD_F(0x07ba3b22) /* 0.482966551 */, 16 }, - /* 2374 */ { MAD_F(0x07bb57b4) /* 0.483237938 */, 16 }, - /* 2375 */ { MAD_F(0x07bc7450) /* 0.483509362 */, 16 }, - /* 2376 */ { MAD_F(0x07bd90f6) /* 0.483780825 */, 16 }, - /* 2377 */ { MAD_F(0x07beada7) /* 0.484052326 */, 16 }, - /* 2378 */ { MAD_F(0x07bfca61) /* 0.484323865 */, 16 }, - /* 2379 */ { MAD_F(0x07c0e726) /* 0.484595443 */, 16 }, - /* 2380 */ { MAD_F(0x07c203f5) /* 0.484867058 */, 16 }, - /* 2381 */ { MAD_F(0x07c320cf) /* 0.485138711 */, 16 }, - /* 2382 */ { MAD_F(0x07c43db2) /* 0.485410402 */, 16 }, - /* 2383 */ { MAD_F(0x07c55aa0) /* 0.485682131 */, 16 }, - - /* 2384 */ { MAD_F(0x07c67798) /* 0.485953899 */, 16 }, - /* 2385 */ { MAD_F(0x07c7949a) /* 0.486225704 */, 16 }, - /* 2386 */ { MAD_F(0x07c8b1a7) /* 0.486497547 */, 16 }, - /* 2387 */ { MAD_F(0x07c9cebd) /* 0.486769429 */, 16 }, - /* 2388 */ { MAD_F(0x07caebde) /* 0.487041348 */, 16 }, - /* 2389 */ { MAD_F(0x07cc0909) /* 0.487313305 */, 16 }, - /* 2390 */ { MAD_F(0x07cd263e) /* 0.487585300 */, 16 }, - /* 2391 */ { MAD_F(0x07ce437d) /* 0.487857333 */, 16 }, - /* 2392 */ { MAD_F(0x07cf60c7) /* 0.488129404 */, 16 }, - /* 2393 */ { MAD_F(0x07d07e1b) /* 0.488401513 */, 16 }, - /* 2394 */ { MAD_F(0x07d19b79) /* 0.488673660 */, 16 }, - /* 2395 */ { MAD_F(0x07d2b8e1) /* 0.488945845 */, 16 }, - /* 2396 */ { MAD_F(0x07d3d653) /* 0.489218067 */, 16 }, - /* 2397 */ { MAD_F(0x07d4f3cf) /* 0.489490328 */, 16 }, - /* 2398 */ { MAD_F(0x07d61156) /* 0.489762626 */, 16 }, - /* 2399 */ { MAD_F(0x07d72ee6) /* 0.490034962 */, 16 }, - - /* 2400 */ { MAD_F(0x07d84c81) /* 0.490307336 */, 16 }, - /* 2401 */ { MAD_F(0x07d96a26) /* 0.490579748 */, 16 }, - /* 2402 */ { MAD_F(0x07da87d5) /* 0.490852198 */, 16 }, - /* 2403 */ { MAD_F(0x07dba58f) /* 0.491124686 */, 16 }, - /* 2404 */ { MAD_F(0x07dcc352) /* 0.491397211 */, 16 }, - /* 2405 */ { MAD_F(0x07dde120) /* 0.491669774 */, 16 }, - /* 2406 */ { MAD_F(0x07defef7) /* 0.491942375 */, 16 }, - /* 2407 */ { MAD_F(0x07e01cd9) /* 0.492215014 */, 16 }, - /* 2408 */ { MAD_F(0x07e13ac5) /* 0.492487690 */, 16 }, - /* 2409 */ { MAD_F(0x07e258bc) /* 0.492760404 */, 16 }, - /* 2410 */ { MAD_F(0x07e376bc) /* 0.493033156 */, 16 }, - /* 2411 */ { MAD_F(0x07e494c6) /* 0.493305946 */, 16 }, - /* 2412 */ { MAD_F(0x07e5b2db) /* 0.493578773 */, 16 }, - /* 2413 */ { MAD_F(0x07e6d0f9) /* 0.493851638 */, 16 }, - /* 2414 */ { MAD_F(0x07e7ef22) /* 0.494124541 */, 16 }, - /* 2415 */ { MAD_F(0x07e90d55) /* 0.494397481 */, 16 }, - - /* 2416 */ { MAD_F(0x07ea2b92) /* 0.494670459 */, 16 }, - /* 2417 */ { MAD_F(0x07eb49d9) /* 0.494943475 */, 16 }, - /* 2418 */ { MAD_F(0x07ec682a) /* 0.495216529 */, 16 }, - /* 2419 */ { MAD_F(0x07ed8686) /* 0.495489620 */, 16 }, - /* 2420 */ { MAD_F(0x07eea4eb) /* 0.495762748 */, 16 }, - /* 2421 */ { MAD_F(0x07efc35b) /* 0.496035915 */, 16 }, - /* 2422 */ { MAD_F(0x07f0e1d4) /* 0.496309119 */, 16 }, - /* 2423 */ { MAD_F(0x07f20058) /* 0.496582360 */, 16 }, - /* 2424 */ { MAD_F(0x07f31ee6) /* 0.496855639 */, 16 }, - /* 2425 */ { MAD_F(0x07f43d7e) /* 0.497128956 */, 16 }, - /* 2426 */ { MAD_F(0x07f55c20) /* 0.497402310 */, 16 }, - /* 2427 */ { MAD_F(0x07f67acc) /* 0.497675702 */, 16 }, - /* 2428 */ { MAD_F(0x07f79982) /* 0.497949132 */, 16 }, - /* 2429 */ { MAD_F(0x07f8b842) /* 0.498222598 */, 16 }, - /* 2430 */ { MAD_F(0x07f9d70c) /* 0.498496103 */, 16 }, - /* 2431 */ { MAD_F(0x07faf5e1) /* 0.498769645 */, 16 }, - - /* 2432 */ { MAD_F(0x07fc14bf) /* 0.499043224 */, 16 }, - /* 2433 */ { MAD_F(0x07fd33a8) /* 0.499316841 */, 16 }, - /* 2434 */ { MAD_F(0x07fe529a) /* 0.499590496 */, 16 }, - /* 2435 */ { MAD_F(0x07ff7197) /* 0.499864188 */, 16 }, - /* 2436 */ { MAD_F(0x0400484f) /* 0.250068959 */, 17 }, - /* 2437 */ { MAD_F(0x0400d7d7) /* 0.250205842 */, 17 }, - /* 2438 */ { MAD_F(0x04016764) /* 0.250342744 */, 17 }, - /* 2439 */ { MAD_F(0x0401f6f7) /* 0.250479665 */, 17 }, - /* 2440 */ { MAD_F(0x0402868e) /* 0.250616605 */, 17 }, - /* 2441 */ { MAD_F(0x0403162b) /* 0.250753563 */, 17 }, - /* 2442 */ { MAD_F(0x0403a5cc) /* 0.250890540 */, 17 }, - /* 2443 */ { MAD_F(0x04043573) /* 0.251027536 */, 17 }, - /* 2444 */ { MAD_F(0x0404c51e) /* 0.251164550 */, 17 }, - /* 2445 */ { MAD_F(0x040554cf) /* 0.251301583 */, 17 }, - /* 2446 */ { MAD_F(0x0405e484) /* 0.251438635 */, 17 }, - /* 2447 */ { MAD_F(0x0406743f) /* 0.251575706 */, 17 }, - - /* 2448 */ { MAD_F(0x040703ff) /* 0.251712795 */, 17 }, - /* 2449 */ { MAD_F(0x040793c3) /* 0.251849903 */, 17 }, - /* 2450 */ { MAD_F(0x0408238d) /* 0.251987029 */, 17 }, - /* 2451 */ { MAD_F(0x0408b35b) /* 0.252124174 */, 17 }, - /* 2452 */ { MAD_F(0x0409432f) /* 0.252261338 */, 17 }, - /* 2453 */ { MAD_F(0x0409d308) /* 0.252398520 */, 17 }, - /* 2454 */ { MAD_F(0x040a62e5) /* 0.252535721 */, 17 }, - /* 2455 */ { MAD_F(0x040af2c8) /* 0.252672941 */, 17 }, - /* 2456 */ { MAD_F(0x040b82b0) /* 0.252810180 */, 17 }, - /* 2457 */ { MAD_F(0x040c129c) /* 0.252947436 */, 17 }, - /* 2458 */ { MAD_F(0x040ca28e) /* 0.253084712 */, 17 }, - /* 2459 */ { MAD_F(0x040d3284) /* 0.253222006 */, 17 }, - /* 2460 */ { MAD_F(0x040dc280) /* 0.253359319 */, 17 }, - /* 2461 */ { MAD_F(0x040e5281) /* 0.253496651 */, 17 }, - /* 2462 */ { MAD_F(0x040ee286) /* 0.253634001 */, 17 }, - /* 2463 */ { MAD_F(0x040f7291) /* 0.253771369 */, 17 }, - - /* 2464 */ { MAD_F(0x041002a1) /* 0.253908756 */, 17 }, - /* 2465 */ { MAD_F(0x041092b5) /* 0.254046162 */, 17 }, - /* 2466 */ { MAD_F(0x041122cf) /* 0.254183587 */, 17 }, - /* 2467 */ { MAD_F(0x0411b2ed) /* 0.254321030 */, 17 }, - /* 2468 */ { MAD_F(0x04124311) /* 0.254458491 */, 17 }, - /* 2469 */ { MAD_F(0x0412d339) /* 0.254595971 */, 17 }, - /* 2470 */ { MAD_F(0x04136367) /* 0.254733470 */, 17 }, - /* 2471 */ { MAD_F(0x0413f399) /* 0.254870987 */, 17 }, - /* 2472 */ { MAD_F(0x041483d1) /* 0.255008523 */, 17 }, - /* 2473 */ { MAD_F(0x0415140d) /* 0.255146077 */, 17 }, - /* 2474 */ { MAD_F(0x0415a44f) /* 0.255283650 */, 17 }, - /* 2475 */ { MAD_F(0x04163495) /* 0.255421241 */, 17 }, - /* 2476 */ { MAD_F(0x0416c4e1) /* 0.255558851 */, 17 }, - /* 2477 */ { MAD_F(0x04175531) /* 0.255696480 */, 17 }, - /* 2478 */ { MAD_F(0x0417e586) /* 0.255834127 */, 17 }, - /* 2479 */ { MAD_F(0x041875e1) /* 0.255971792 */, 17 }, - - /* 2480 */ { MAD_F(0x04190640) /* 0.256109476 */, 17 }, - /* 2481 */ { MAD_F(0x041996a4) /* 0.256247179 */, 17 }, - /* 2482 */ { MAD_F(0x041a270d) /* 0.256384900 */, 17 }, - /* 2483 */ { MAD_F(0x041ab77b) /* 0.256522639 */, 17 }, - /* 2484 */ { MAD_F(0x041b47ef) /* 0.256660397 */, 17 }, - /* 2485 */ { MAD_F(0x041bd867) /* 0.256798174 */, 17 }, - /* 2486 */ { MAD_F(0x041c68e4) /* 0.256935969 */, 17 }, - /* 2487 */ { MAD_F(0x041cf966) /* 0.257073782 */, 17 }, - /* 2488 */ { MAD_F(0x041d89ed) /* 0.257211614 */, 17 }, - /* 2489 */ { MAD_F(0x041e1a79) /* 0.257349465 */, 17 }, - /* 2490 */ { MAD_F(0x041eab0a) /* 0.257487334 */, 17 }, - /* 2491 */ { MAD_F(0x041f3b9f) /* 0.257625221 */, 17 }, - /* 2492 */ { MAD_F(0x041fcc3a) /* 0.257763127 */, 17 }, - /* 2493 */ { MAD_F(0x04205cda) /* 0.257901051 */, 17 }, - /* 2494 */ { MAD_F(0x0420ed7f) /* 0.258038994 */, 17 }, - /* 2495 */ { MAD_F(0x04217e28) /* 0.258176955 */, 17 }, - - /* 2496 */ { MAD_F(0x04220ed7) /* 0.258314934 */, 17 }, - /* 2497 */ { MAD_F(0x04229f8a) /* 0.258452932 */, 17 }, - /* 2498 */ { MAD_F(0x04233043) /* 0.258590948 */, 17 }, - /* 2499 */ { MAD_F(0x0423c100) /* 0.258728983 */, 17 }, - /* 2500 */ { MAD_F(0x042451c3) /* 0.258867036 */, 17 }, - /* 2501 */ { MAD_F(0x0424e28a) /* 0.259005108 */, 17 }, - /* 2502 */ { MAD_F(0x04257356) /* 0.259143198 */, 17 }, - /* 2503 */ { MAD_F(0x04260428) /* 0.259281307 */, 17 }, - /* 2504 */ { MAD_F(0x042694fe) /* 0.259419433 */, 17 }, - /* 2505 */ { MAD_F(0x042725d9) /* 0.259557579 */, 17 }, - /* 2506 */ { MAD_F(0x0427b6b9) /* 0.259695742 */, 17 }, - /* 2507 */ { MAD_F(0x0428479e) /* 0.259833924 */, 17 }, - /* 2508 */ { MAD_F(0x0428d888) /* 0.259972124 */, 17 }, - /* 2509 */ { MAD_F(0x04296976) /* 0.260110343 */, 17 }, - /* 2510 */ { MAD_F(0x0429fa6a) /* 0.260248580 */, 17 }, - /* 2511 */ { MAD_F(0x042a8b63) /* 0.260386836 */, 17 }, - - /* 2512 */ { MAD_F(0x042b1c60) /* 0.260525110 */, 17 }, - /* 2513 */ { MAD_F(0x042bad63) /* 0.260663402 */, 17 }, - /* 2514 */ { MAD_F(0x042c3e6a) /* 0.260801712 */, 17 }, - /* 2515 */ { MAD_F(0x042ccf77) /* 0.260940041 */, 17 }, - /* 2516 */ { MAD_F(0x042d6088) /* 0.261078388 */, 17 }, - /* 2517 */ { MAD_F(0x042df19e) /* 0.261216754 */, 17 }, - /* 2518 */ { MAD_F(0x042e82b9) /* 0.261355137 */, 17 }, - /* 2519 */ { MAD_F(0x042f13d9) /* 0.261493540 */, 17 }, - /* 2520 */ { MAD_F(0x042fa4fe) /* 0.261631960 */, 17 }, - /* 2521 */ { MAD_F(0x04303628) /* 0.261770399 */, 17 }, - /* 2522 */ { MAD_F(0x0430c757) /* 0.261908856 */, 17 }, - /* 2523 */ { MAD_F(0x0431588b) /* 0.262047331 */, 17 }, - /* 2524 */ { MAD_F(0x0431e9c3) /* 0.262185825 */, 17 }, - /* 2525 */ { MAD_F(0x04327b01) /* 0.262324337 */, 17 }, - /* 2526 */ { MAD_F(0x04330c43) /* 0.262462867 */, 17 }, - /* 2527 */ { MAD_F(0x04339d8a) /* 0.262601416 */, 17 }, - - /* 2528 */ { MAD_F(0x04342ed7) /* 0.262739982 */, 17 }, - /* 2529 */ { MAD_F(0x0434c028) /* 0.262878568 */, 17 }, - /* 2530 */ { MAD_F(0x0435517e) /* 0.263017171 */, 17 }, - /* 2531 */ { MAD_F(0x0435e2d9) /* 0.263155792 */, 17 }, - /* 2532 */ { MAD_F(0x04367439) /* 0.263294432 */, 17 }, - /* 2533 */ { MAD_F(0x0437059e) /* 0.263433090 */, 17 }, - /* 2534 */ { MAD_F(0x04379707) /* 0.263571767 */, 17 }, - /* 2535 */ { MAD_F(0x04382876) /* 0.263710461 */, 17 }, - /* 2536 */ { MAD_F(0x0438b9e9) /* 0.263849174 */, 17 }, - /* 2537 */ { MAD_F(0x04394b61) /* 0.263987905 */, 17 }, - /* 2538 */ { MAD_F(0x0439dcdf) /* 0.264126655 */, 17 }, - /* 2539 */ { MAD_F(0x043a6e61) /* 0.264265422 */, 17 }, - /* 2540 */ { MAD_F(0x043affe8) /* 0.264404208 */, 17 }, - /* 2541 */ { MAD_F(0x043b9174) /* 0.264543012 */, 17 }, - /* 2542 */ { MAD_F(0x043c2305) /* 0.264681834 */, 17 }, - /* 2543 */ { MAD_F(0x043cb49a) /* 0.264820674 */, 17 }, - - /* 2544 */ { MAD_F(0x043d4635) /* 0.264959533 */, 17 }, - /* 2545 */ { MAD_F(0x043dd7d4) /* 0.265098410 */, 17 }, - /* 2546 */ { MAD_F(0x043e6979) /* 0.265237305 */, 17 }, - /* 2547 */ { MAD_F(0x043efb22) /* 0.265376218 */, 17 }, - /* 2548 */ { MAD_F(0x043f8cd0) /* 0.265515149 */, 17 }, - /* 2549 */ { MAD_F(0x04401e83) /* 0.265654099 */, 17 }, - /* 2550 */ { MAD_F(0x0440b03b) /* 0.265793066 */, 17 }, - /* 2551 */ { MAD_F(0x044141f7) /* 0.265932052 */, 17 }, - /* 2552 */ { MAD_F(0x0441d3b9) /* 0.266071056 */, 17 }, - /* 2553 */ { MAD_F(0x04426580) /* 0.266210078 */, 17 }, - /* 2554 */ { MAD_F(0x0442f74b) /* 0.266349119 */, 17 }, - /* 2555 */ { MAD_F(0x0443891b) /* 0.266488177 */, 17 }, - /* 2556 */ { MAD_F(0x04441af0) /* 0.266627254 */, 17 }, - /* 2557 */ { MAD_F(0x0444acca) /* 0.266766349 */, 17 }, - /* 2558 */ { MAD_F(0x04453ea9) /* 0.266905462 */, 17 }, - /* 2559 */ { MAD_F(0x0445d08d) /* 0.267044593 */, 17 }, - - /* 2560 */ { MAD_F(0x04466275) /* 0.267183742 */, 17 }, - /* 2561 */ { MAD_F(0x0446f463) /* 0.267322909 */, 17 }, - /* 2562 */ { MAD_F(0x04478655) /* 0.267462094 */, 17 }, - /* 2563 */ { MAD_F(0x0448184c) /* 0.267601298 */, 17 }, - /* 2564 */ { MAD_F(0x0448aa48) /* 0.267740519 */, 17 }, - /* 2565 */ { MAD_F(0x04493c49) /* 0.267879759 */, 17 }, - /* 2566 */ { MAD_F(0x0449ce4f) /* 0.268019017 */, 17 }, - /* 2567 */ { MAD_F(0x044a6059) /* 0.268158293 */, 17 }, - /* 2568 */ { MAD_F(0x044af269) /* 0.268297587 */, 17 }, - /* 2569 */ { MAD_F(0x044b847d) /* 0.268436899 */, 17 }, - /* 2570 */ { MAD_F(0x044c1696) /* 0.268576229 */, 17 }, - /* 2571 */ { MAD_F(0x044ca8b4) /* 0.268715577 */, 17 }, - /* 2572 */ { MAD_F(0x044d3ad7) /* 0.268854943 */, 17 }, - /* 2573 */ { MAD_F(0x044dccff) /* 0.268994328 */, 17 }, - /* 2574 */ { MAD_F(0x044e5f2b) /* 0.269133730 */, 17 }, - /* 2575 */ { MAD_F(0x044ef15d) /* 0.269273150 */, 17 }, - - /* 2576 */ { MAD_F(0x044f8393) /* 0.269412589 */, 17 }, - /* 2577 */ { MAD_F(0x045015ce) /* 0.269552045 */, 17 }, - /* 2578 */ { MAD_F(0x0450a80e) /* 0.269691520 */, 17 }, - /* 2579 */ { MAD_F(0x04513a53) /* 0.269831013 */, 17 }, - /* 2580 */ { MAD_F(0x0451cc9c) /* 0.269970523 */, 17 }, - /* 2581 */ { MAD_F(0x04525eeb) /* 0.270110052 */, 17 }, - /* 2582 */ { MAD_F(0x0452f13e) /* 0.270249599 */, 17 }, - /* 2583 */ { MAD_F(0x04538396) /* 0.270389163 */, 17 }, - /* 2584 */ { MAD_F(0x045415f3) /* 0.270528746 */, 17 }, - /* 2585 */ { MAD_F(0x0454a855) /* 0.270668347 */, 17 }, - /* 2586 */ { MAD_F(0x04553abb) /* 0.270807965 */, 17 }, - /* 2587 */ { MAD_F(0x0455cd27) /* 0.270947602 */, 17 }, - /* 2588 */ { MAD_F(0x04565f97) /* 0.271087257 */, 17 }, - /* 2589 */ { MAD_F(0x0456f20c) /* 0.271226930 */, 17 }, - /* 2590 */ { MAD_F(0x04578486) /* 0.271366620 */, 17 }, - /* 2591 */ { MAD_F(0x04581705) /* 0.271506329 */, 17 }, - - /* 2592 */ { MAD_F(0x0458a989) /* 0.271646056 */, 17 }, - /* 2593 */ { MAD_F(0x04593c11) /* 0.271785800 */, 17 }, - /* 2594 */ { MAD_F(0x0459ce9e) /* 0.271925563 */, 17 }, - /* 2595 */ { MAD_F(0x045a6130) /* 0.272065343 */, 17 }, - /* 2596 */ { MAD_F(0x045af3c7) /* 0.272205142 */, 17 }, - /* 2597 */ { MAD_F(0x045b8663) /* 0.272344958 */, 17 }, - /* 2598 */ { MAD_F(0x045c1903) /* 0.272484793 */, 17 }, - /* 2599 */ { MAD_F(0x045caba9) /* 0.272624645 */, 17 }, - /* 2600 */ { MAD_F(0x045d3e53) /* 0.272764515 */, 17 }, - /* 2601 */ { MAD_F(0x045dd102) /* 0.272904403 */, 17 }, - /* 2602 */ { MAD_F(0x045e63b6) /* 0.273044310 */, 17 }, - /* 2603 */ { MAD_F(0x045ef66e) /* 0.273184234 */, 17 }, - /* 2604 */ { MAD_F(0x045f892b) /* 0.273324176 */, 17 }, - /* 2605 */ { MAD_F(0x04601bee) /* 0.273464136 */, 17 }, - /* 2606 */ { MAD_F(0x0460aeb5) /* 0.273604113 */, 17 }, - /* 2607 */ { MAD_F(0x04614180) /* 0.273744109 */, 17 }, - - /* 2608 */ { MAD_F(0x0461d451) /* 0.273884123 */, 17 }, - /* 2609 */ { MAD_F(0x04626727) /* 0.274024154 */, 17 }, - /* 2610 */ { MAD_F(0x0462fa01) /* 0.274164204 */, 17 }, - /* 2611 */ { MAD_F(0x04638ce0) /* 0.274304271 */, 17 }, - /* 2612 */ { MAD_F(0x04641fc4) /* 0.274444356 */, 17 }, - /* 2613 */ { MAD_F(0x0464b2ac) /* 0.274584459 */, 17 }, - /* 2614 */ { MAD_F(0x0465459a) /* 0.274724580 */, 17 }, - /* 2615 */ { MAD_F(0x0465d88c) /* 0.274864719 */, 17 }, - /* 2616 */ { MAD_F(0x04666b83) /* 0.275004875 */, 17 }, - /* 2617 */ { MAD_F(0x0466fe7f) /* 0.275145050 */, 17 }, - /* 2618 */ { MAD_F(0x0467917f) /* 0.275285242 */, 17 }, - /* 2619 */ { MAD_F(0x04682485) /* 0.275425452 */, 17 }, - /* 2620 */ { MAD_F(0x0468b78f) /* 0.275565681 */, 17 }, - /* 2621 */ { MAD_F(0x04694a9e) /* 0.275705926 */, 17 }, - /* 2622 */ { MAD_F(0x0469ddb2) /* 0.275846190 */, 17 }, - /* 2623 */ { MAD_F(0x046a70ca) /* 0.275986472 */, 17 }, - - /* 2624 */ { MAD_F(0x046b03e7) /* 0.276126771 */, 17 }, - /* 2625 */ { MAD_F(0x046b970a) /* 0.276267088 */, 17 }, - /* 2626 */ { MAD_F(0x046c2a31) /* 0.276407423 */, 17 }, - /* 2627 */ { MAD_F(0x046cbd5c) /* 0.276547776 */, 17 }, - /* 2628 */ { MAD_F(0x046d508d) /* 0.276688147 */, 17 }, - /* 2629 */ { MAD_F(0x046de3c2) /* 0.276828535 */, 17 }, - /* 2630 */ { MAD_F(0x046e76fc) /* 0.276968942 */, 17 }, - /* 2631 */ { MAD_F(0x046f0a3b) /* 0.277109366 */, 17 }, - /* 2632 */ { MAD_F(0x046f9d7e) /* 0.277249808 */, 17 }, - /* 2633 */ { MAD_F(0x047030c7) /* 0.277390267 */, 17 }, - /* 2634 */ { MAD_F(0x0470c414) /* 0.277530745 */, 17 }, - /* 2635 */ { MAD_F(0x04715766) /* 0.277671240 */, 17 }, - /* 2636 */ { MAD_F(0x0471eabc) /* 0.277811753 */, 17 }, - /* 2637 */ { MAD_F(0x04727e18) /* 0.277952284 */, 17 }, - /* 2638 */ { MAD_F(0x04731178) /* 0.278092832 */, 17 }, - /* 2639 */ { MAD_F(0x0473a4dd) /* 0.278233399 */, 17 }, - - /* 2640 */ { MAD_F(0x04743847) /* 0.278373983 */, 17 }, - /* 2641 */ { MAD_F(0x0474cbb5) /* 0.278514584 */, 17 }, - /* 2642 */ { MAD_F(0x04755f29) /* 0.278655204 */, 17 }, - /* 2643 */ { MAD_F(0x0475f2a1) /* 0.278795841 */, 17 }, - /* 2644 */ { MAD_F(0x0476861d) /* 0.278936496 */, 17 }, - /* 2645 */ { MAD_F(0x0477199f) /* 0.279077169 */, 17 }, - /* 2646 */ { MAD_F(0x0477ad25) /* 0.279217860 */, 17 }, - /* 2647 */ { MAD_F(0x047840b0) /* 0.279358568 */, 17 }, - /* 2648 */ { MAD_F(0x0478d440) /* 0.279499294 */, 17 }, - /* 2649 */ { MAD_F(0x047967d5) /* 0.279640037 */, 17 }, - /* 2650 */ { MAD_F(0x0479fb6e) /* 0.279780799 */, 17 }, - /* 2651 */ { MAD_F(0x047a8f0c) /* 0.279921578 */, 17 }, - /* 2652 */ { MAD_F(0x047b22af) /* 0.280062375 */, 17 }, - /* 2653 */ { MAD_F(0x047bb657) /* 0.280203189 */, 17 }, - /* 2654 */ { MAD_F(0x047c4a03) /* 0.280344021 */, 17 }, - /* 2655 */ { MAD_F(0x047cddb4) /* 0.280484871 */, 17 }, - - /* 2656 */ { MAD_F(0x047d716a) /* 0.280625739 */, 17 }, - /* 2657 */ { MAD_F(0x047e0524) /* 0.280766624 */, 17 }, - /* 2658 */ { MAD_F(0x047e98e4) /* 0.280907527 */, 17 }, - /* 2659 */ { MAD_F(0x047f2ca8) /* 0.281048447 */, 17 }, - /* 2660 */ { MAD_F(0x047fc071) /* 0.281189385 */, 17 }, - /* 2661 */ { MAD_F(0x0480543e) /* 0.281330341 */, 17 }, - /* 2662 */ { MAD_F(0x0480e811) /* 0.281471315 */, 17 }, - /* 2663 */ { MAD_F(0x04817be8) /* 0.281612306 */, 17 }, - /* 2664 */ { MAD_F(0x04820fc3) /* 0.281753315 */, 17 }, - /* 2665 */ { MAD_F(0x0482a3a4) /* 0.281894341 */, 17 }, - /* 2666 */ { MAD_F(0x04833789) /* 0.282035386 */, 17 }, - /* 2667 */ { MAD_F(0x0483cb73) /* 0.282176447 */, 17 }, - /* 2668 */ { MAD_F(0x04845f62) /* 0.282317527 */, 17 }, - /* 2669 */ { MAD_F(0x0484f355) /* 0.282458624 */, 17 }, - /* 2670 */ { MAD_F(0x0485874d) /* 0.282599738 */, 17 }, - /* 2671 */ { MAD_F(0x04861b4a) /* 0.282740871 */, 17 }, - - /* 2672 */ { MAD_F(0x0486af4c) /* 0.282882021 */, 17 }, - /* 2673 */ { MAD_F(0x04874352) /* 0.283023188 */, 17 }, - /* 2674 */ { MAD_F(0x0487d75d) /* 0.283164373 */, 17 }, - /* 2675 */ { MAD_F(0x04886b6d) /* 0.283305576 */, 17 }, - /* 2676 */ { MAD_F(0x0488ff82) /* 0.283446796 */, 17 }, - /* 2677 */ { MAD_F(0x0489939b) /* 0.283588034 */, 17 }, - /* 2678 */ { MAD_F(0x048a27b9) /* 0.283729290 */, 17 }, - /* 2679 */ { MAD_F(0x048abbdc) /* 0.283870563 */, 17 }, - /* 2680 */ { MAD_F(0x048b5003) /* 0.284011853 */, 17 }, - /* 2681 */ { MAD_F(0x048be42f) /* 0.284153161 */, 17 }, - /* 2682 */ { MAD_F(0x048c7860) /* 0.284294487 */, 17 }, - /* 2683 */ { MAD_F(0x048d0c96) /* 0.284435831 */, 17 }, - /* 2684 */ { MAD_F(0x048da0d0) /* 0.284577192 */, 17 }, - /* 2685 */ { MAD_F(0x048e350f) /* 0.284718570 */, 17 }, - /* 2686 */ { MAD_F(0x048ec953) /* 0.284859966 */, 17 }, - /* 2687 */ { MAD_F(0x048f5d9b) /* 0.285001380 */, 17 }, - - /* 2688 */ { MAD_F(0x048ff1e8) /* 0.285142811 */, 17 }, - /* 2689 */ { MAD_F(0x0490863a) /* 0.285284259 */, 17 }, - /* 2690 */ { MAD_F(0x04911a91) /* 0.285425726 */, 17 }, - /* 2691 */ { MAD_F(0x0491aeec) /* 0.285567209 */, 17 }, - /* 2692 */ { MAD_F(0x0492434c) /* 0.285708711 */, 17 }, - /* 2693 */ { MAD_F(0x0492d7b0) /* 0.285850229 */, 17 }, - /* 2694 */ { MAD_F(0x04936c1a) /* 0.285991766 */, 17 }, - /* 2695 */ { MAD_F(0x04940088) /* 0.286133319 */, 17 }, - /* 2696 */ { MAD_F(0x049494fb) /* 0.286274891 */, 17 }, - /* 2697 */ { MAD_F(0x04952972) /* 0.286416480 */, 17 }, - /* 2698 */ { MAD_F(0x0495bdee) /* 0.286558086 */, 17 }, - /* 2699 */ { MAD_F(0x0496526f) /* 0.286699710 */, 17 }, - /* 2700 */ { MAD_F(0x0496e6f5) /* 0.286841351 */, 17 }, - /* 2701 */ { MAD_F(0x04977b7f) /* 0.286983010 */, 17 }, - /* 2702 */ { MAD_F(0x0498100e) /* 0.287124686 */, 17 }, - /* 2703 */ { MAD_F(0x0498a4a1) /* 0.287266380 */, 17 }, - - /* 2704 */ { MAD_F(0x0499393a) /* 0.287408091 */, 17 }, - /* 2705 */ { MAD_F(0x0499cdd7) /* 0.287549820 */, 17 }, - /* 2706 */ { MAD_F(0x049a6278) /* 0.287691566 */, 17 }, - /* 2707 */ { MAD_F(0x049af71f) /* 0.287833330 */, 17 }, - /* 2708 */ { MAD_F(0x049b8bca) /* 0.287975111 */, 17 }, - /* 2709 */ { MAD_F(0x049c207a) /* 0.288116909 */, 17 }, - /* 2710 */ { MAD_F(0x049cb52e) /* 0.288258725 */, 17 }, - /* 2711 */ { MAD_F(0x049d49e7) /* 0.288400559 */, 17 }, - /* 2712 */ { MAD_F(0x049ddea5) /* 0.288542409 */, 17 }, - /* 2713 */ { MAD_F(0x049e7367) /* 0.288684278 */, 17 }, - /* 2714 */ { MAD_F(0x049f082f) /* 0.288826163 */, 17 }, - /* 2715 */ { MAD_F(0x049f9cfa) /* 0.288968067 */, 17 }, - /* 2716 */ { MAD_F(0x04a031cb) /* 0.289109987 */, 17 }, - /* 2717 */ { MAD_F(0x04a0c6a0) /* 0.289251925 */, 17 }, - /* 2718 */ { MAD_F(0x04a15b7a) /* 0.289393881 */, 17 }, - /* 2719 */ { MAD_F(0x04a1f059) /* 0.289535854 */, 17 }, - - /* 2720 */ { MAD_F(0x04a2853c) /* 0.289677844 */, 17 }, - /* 2721 */ { MAD_F(0x04a31a24) /* 0.289819851 */, 17 }, - /* 2722 */ { MAD_F(0x04a3af10) /* 0.289961876 */, 17 }, - /* 2723 */ { MAD_F(0x04a44401) /* 0.290103919 */, 17 }, - /* 2724 */ { MAD_F(0x04a4d8f7) /* 0.290245979 */, 17 }, - /* 2725 */ { MAD_F(0x04a56df2) /* 0.290388056 */, 17 }, - /* 2726 */ { MAD_F(0x04a602f1) /* 0.290530150 */, 17 }, - /* 2727 */ { MAD_F(0x04a697f5) /* 0.290672262 */, 17 }, - /* 2728 */ { MAD_F(0x04a72cfe) /* 0.290814392 */, 17 }, - /* 2729 */ { MAD_F(0x04a7c20b) /* 0.290956538 */, 17 }, - /* 2730 */ { MAD_F(0x04a8571d) /* 0.291098703 */, 17 }, - /* 2731 */ { MAD_F(0x04a8ec33) /* 0.291240884 */, 17 }, - /* 2732 */ { MAD_F(0x04a9814e) /* 0.291383083 */, 17 }, - /* 2733 */ { MAD_F(0x04aa166e) /* 0.291525299 */, 17 }, - /* 2734 */ { MAD_F(0x04aaab93) /* 0.291667532 */, 17 }, - /* 2735 */ { MAD_F(0x04ab40bc) /* 0.291809783 */, 17 }, - - /* 2736 */ { MAD_F(0x04abd5ea) /* 0.291952051 */, 17 }, - /* 2737 */ { MAD_F(0x04ac6b1c) /* 0.292094337 */, 17 }, - /* 2738 */ { MAD_F(0x04ad0053) /* 0.292236640 */, 17 }, - /* 2739 */ { MAD_F(0x04ad958f) /* 0.292378960 */, 17 }, - /* 2740 */ { MAD_F(0x04ae2ad0) /* 0.292521297 */, 17 }, - /* 2741 */ { MAD_F(0x04aec015) /* 0.292663652 */, 17 }, - /* 2742 */ { MAD_F(0x04af555e) /* 0.292806024 */, 17 }, - /* 2743 */ { MAD_F(0x04afeaad) /* 0.292948414 */, 17 }, - /* 2744 */ { MAD_F(0x04b08000) /* 0.293090820 */, 17 }, - /* 2745 */ { MAD_F(0x04b11557) /* 0.293233244 */, 17 }, - /* 2746 */ { MAD_F(0x04b1aab4) /* 0.293375686 */, 17 }, - /* 2747 */ { MAD_F(0x04b24015) /* 0.293518144 */, 17 }, - /* 2748 */ { MAD_F(0x04b2d57a) /* 0.293660620 */, 17 }, - /* 2749 */ { MAD_F(0x04b36ae4) /* 0.293803113 */, 17 }, - /* 2750 */ { MAD_F(0x04b40053) /* 0.293945624 */, 17 }, - /* 2751 */ { MAD_F(0x04b495c7) /* 0.294088151 */, 17 }, - - /* 2752 */ { MAD_F(0x04b52b3f) /* 0.294230696 */, 17 }, - /* 2753 */ { MAD_F(0x04b5c0bc) /* 0.294373259 */, 17 }, - /* 2754 */ { MAD_F(0x04b6563d) /* 0.294515838 */, 17 }, - /* 2755 */ { MAD_F(0x04b6ebc3) /* 0.294658435 */, 17 }, - /* 2756 */ { MAD_F(0x04b7814e) /* 0.294801049 */, 17 }, - /* 2757 */ { MAD_F(0x04b816dd) /* 0.294943680 */, 17 }, - /* 2758 */ { MAD_F(0x04b8ac71) /* 0.295086329 */, 17 }, - /* 2759 */ { MAD_F(0x04b9420a) /* 0.295228995 */, 17 }, - /* 2760 */ { MAD_F(0x04b9d7a7) /* 0.295371678 */, 17 }, - /* 2761 */ { MAD_F(0x04ba6d49) /* 0.295514378 */, 17 }, - /* 2762 */ { MAD_F(0x04bb02ef) /* 0.295657095 */, 17 }, - /* 2763 */ { MAD_F(0x04bb989a) /* 0.295799830 */, 17 }, - /* 2764 */ { MAD_F(0x04bc2e4a) /* 0.295942582 */, 17 }, - /* 2765 */ { MAD_F(0x04bcc3fe) /* 0.296085351 */, 17 }, - /* 2766 */ { MAD_F(0x04bd59b7) /* 0.296228138 */, 17 }, - /* 2767 */ { MAD_F(0x04bdef74) /* 0.296370941 */, 17 }, - - /* 2768 */ { MAD_F(0x04be8537) /* 0.296513762 */, 17 }, - /* 2769 */ { MAD_F(0x04bf1afd) /* 0.296656600 */, 17 }, - /* 2770 */ { MAD_F(0x04bfb0c9) /* 0.296799455 */, 17 }, - /* 2771 */ { MAD_F(0x04c04699) /* 0.296942327 */, 17 }, - /* 2772 */ { MAD_F(0x04c0dc6d) /* 0.297085217 */, 17 }, - /* 2773 */ { MAD_F(0x04c17247) /* 0.297228124 */, 17 }, - /* 2774 */ { MAD_F(0x04c20824) /* 0.297371048 */, 17 }, - /* 2775 */ { MAD_F(0x04c29e07) /* 0.297513989 */, 17 }, - /* 2776 */ { MAD_F(0x04c333ee) /* 0.297656947 */, 17 }, - /* 2777 */ { MAD_F(0x04c3c9da) /* 0.297799922 */, 17 }, - /* 2778 */ { MAD_F(0x04c45fca) /* 0.297942915 */, 17 }, - /* 2779 */ { MAD_F(0x04c4f5bf) /* 0.298085925 */, 17 }, - /* 2780 */ { MAD_F(0x04c58bb8) /* 0.298228951 */, 17 }, - /* 2781 */ { MAD_F(0x04c621b6) /* 0.298371996 */, 17 }, - /* 2782 */ { MAD_F(0x04c6b7b9) /* 0.298515057 */, 17 }, - /* 2783 */ { MAD_F(0x04c74dc0) /* 0.298658135 */, 17 }, - - /* 2784 */ { MAD_F(0x04c7e3cc) /* 0.298801231 */, 17 }, - /* 2785 */ { MAD_F(0x04c879dd) /* 0.298944343 */, 17 }, - /* 2786 */ { MAD_F(0x04c90ff2) /* 0.299087473 */, 17 }, - /* 2787 */ { MAD_F(0x04c9a60c) /* 0.299230620 */, 17 }, - /* 2788 */ { MAD_F(0x04ca3c2a) /* 0.299373784 */, 17 }, - /* 2789 */ { MAD_F(0x04cad24d) /* 0.299516965 */, 17 }, - /* 2790 */ { MAD_F(0x04cb6874) /* 0.299660163 */, 17 }, - /* 2791 */ { MAD_F(0x04cbfea0) /* 0.299803378 */, 17 }, - /* 2792 */ { MAD_F(0x04cc94d1) /* 0.299946611 */, 17 }, - /* 2793 */ { MAD_F(0x04cd2b06) /* 0.300089860 */, 17 }, - /* 2794 */ { MAD_F(0x04cdc140) /* 0.300233127 */, 17 }, - /* 2795 */ { MAD_F(0x04ce577f) /* 0.300376411 */, 17 }, - /* 2796 */ { MAD_F(0x04ceedc2) /* 0.300519711 */, 17 }, - /* 2797 */ { MAD_F(0x04cf8409) /* 0.300663029 */, 17 }, - /* 2798 */ { MAD_F(0x04d01a55) /* 0.300806364 */, 17 }, - /* 2799 */ { MAD_F(0x04d0b0a6) /* 0.300949716 */, 17 }, - - /* 2800 */ { MAD_F(0x04d146fb) /* 0.301093085 */, 17 }, - /* 2801 */ { MAD_F(0x04d1dd55) /* 0.301236472 */, 17 }, - /* 2802 */ { MAD_F(0x04d273b4) /* 0.301379875 */, 17 }, - /* 2803 */ { MAD_F(0x04d30a17) /* 0.301523295 */, 17 }, - /* 2804 */ { MAD_F(0x04d3a07f) /* 0.301666733 */, 17 }, - /* 2805 */ { MAD_F(0x04d436eb) /* 0.301810187 */, 17 }, - /* 2806 */ { MAD_F(0x04d4cd5c) /* 0.301953659 */, 17 }, - /* 2807 */ { MAD_F(0x04d563d1) /* 0.302097147 */, 17 }, - /* 2808 */ { MAD_F(0x04d5fa4b) /* 0.302240653 */, 17 }, - /* 2809 */ { MAD_F(0x04d690ca) /* 0.302384175 */, 17 }, - /* 2810 */ { MAD_F(0x04d7274d) /* 0.302527715 */, 17 }, - /* 2811 */ { MAD_F(0x04d7bdd5) /* 0.302671271 */, 17 }, - /* 2812 */ { MAD_F(0x04d85461) /* 0.302814845 */, 17 }, - /* 2813 */ { MAD_F(0x04d8eaf2) /* 0.302958436 */, 17 }, - /* 2814 */ { MAD_F(0x04d98187) /* 0.303102044 */, 17 }, - /* 2815 */ { MAD_F(0x04da1821) /* 0.303245668 */, 17 }, - - /* 2816 */ { MAD_F(0x04daaec0) /* 0.303389310 */, 17 }, - /* 2817 */ { MAD_F(0x04db4563) /* 0.303532969 */, 17 }, - /* 2818 */ { MAD_F(0x04dbdc0a) /* 0.303676645 */, 17 }, - /* 2819 */ { MAD_F(0x04dc72b7) /* 0.303820337 */, 17 }, - /* 2820 */ { MAD_F(0x04dd0967) /* 0.303964047 */, 17 }, - /* 2821 */ { MAD_F(0x04dda01d) /* 0.304107774 */, 17 }, - /* 2822 */ { MAD_F(0x04de36d7) /* 0.304251517 */, 17 }, - /* 2823 */ { MAD_F(0x04decd95) /* 0.304395278 */, 17 }, - /* 2824 */ { MAD_F(0x04df6458) /* 0.304539056 */, 17 }, - /* 2825 */ { MAD_F(0x04dffb20) /* 0.304682850 */, 17 }, - /* 2826 */ { MAD_F(0x04e091ec) /* 0.304826662 */, 17 }, - /* 2827 */ { MAD_F(0x04e128bc) /* 0.304970491 */, 17 }, - /* 2828 */ { MAD_F(0x04e1bf92) /* 0.305114336 */, 17 }, - /* 2829 */ { MAD_F(0x04e2566b) /* 0.305258199 */, 17 }, - /* 2830 */ { MAD_F(0x04e2ed4a) /* 0.305402078 */, 17 }, - /* 2831 */ { MAD_F(0x04e3842d) /* 0.305545974 */, 17 }, - - /* 2832 */ { MAD_F(0x04e41b14) /* 0.305689888 */, 17 }, - /* 2833 */ { MAD_F(0x04e4b200) /* 0.305833818 */, 17 }, - /* 2834 */ { MAD_F(0x04e548f1) /* 0.305977765 */, 17 }, - /* 2835 */ { MAD_F(0x04e5dfe6) /* 0.306121729 */, 17 }, - /* 2836 */ { MAD_F(0x04e676df) /* 0.306265710 */, 17 }, - /* 2837 */ { MAD_F(0x04e70dde) /* 0.306409708 */, 17 }, - /* 2838 */ { MAD_F(0x04e7a4e0) /* 0.306553723 */, 17 }, - /* 2839 */ { MAD_F(0x04e83be7) /* 0.306697755 */, 17 }, - /* 2840 */ { MAD_F(0x04e8d2f3) /* 0.306841804 */, 17 }, - /* 2841 */ { MAD_F(0x04e96a04) /* 0.306985869 */, 17 }, - /* 2842 */ { MAD_F(0x04ea0118) /* 0.307129952 */, 17 }, - /* 2843 */ { MAD_F(0x04ea9832) /* 0.307274051 */, 17 }, - /* 2844 */ { MAD_F(0x04eb2f50) /* 0.307418168 */, 17 }, - /* 2845 */ { MAD_F(0x04ebc672) /* 0.307562301 */, 17 }, - /* 2846 */ { MAD_F(0x04ec5d99) /* 0.307706451 */, 17 }, - /* 2847 */ { MAD_F(0x04ecf4c5) /* 0.307850618 */, 17 }, - - /* 2848 */ { MAD_F(0x04ed8bf5) /* 0.307994802 */, 17 }, - /* 2849 */ { MAD_F(0x04ee2329) /* 0.308139003 */, 17 }, - /* 2850 */ { MAD_F(0x04eeba63) /* 0.308283220 */, 17 }, - /* 2851 */ { MAD_F(0x04ef51a0) /* 0.308427455 */, 17 }, - /* 2852 */ { MAD_F(0x04efe8e2) /* 0.308571706 */, 17 }, - /* 2853 */ { MAD_F(0x04f08029) /* 0.308715974 */, 17 }, - /* 2854 */ { MAD_F(0x04f11774) /* 0.308860260 */, 17 }, - /* 2855 */ { MAD_F(0x04f1aec4) /* 0.309004561 */, 17 }, - /* 2856 */ { MAD_F(0x04f24618) /* 0.309148880 */, 17 }, - /* 2857 */ { MAD_F(0x04f2dd71) /* 0.309293216 */, 17 }, - /* 2858 */ { MAD_F(0x04f374cf) /* 0.309437568 */, 17 }, - /* 2859 */ { MAD_F(0x04f40c30) /* 0.309581938 */, 17 }, - /* 2860 */ { MAD_F(0x04f4a397) /* 0.309726324 */, 17 }, - /* 2861 */ { MAD_F(0x04f53b02) /* 0.309870727 */, 17 }, - /* 2862 */ { MAD_F(0x04f5d271) /* 0.310015147 */, 17 }, - /* 2863 */ { MAD_F(0x04f669e5) /* 0.310159583 */, 17 }, - - /* 2864 */ { MAD_F(0x04f7015d) /* 0.310304037 */, 17 }, - /* 2865 */ { MAD_F(0x04f798da) /* 0.310448507 */, 17 }, - /* 2866 */ { MAD_F(0x04f8305c) /* 0.310592994 */, 17 }, - /* 2867 */ { MAD_F(0x04f8c7e2) /* 0.310737498 */, 17 }, - /* 2868 */ { MAD_F(0x04f95f6c) /* 0.310882018 */, 17 }, - /* 2869 */ { MAD_F(0x04f9f6fb) /* 0.311026556 */, 17 }, - /* 2870 */ { MAD_F(0x04fa8e8f) /* 0.311171110 */, 17 }, - /* 2871 */ { MAD_F(0x04fb2627) /* 0.311315681 */, 17 }, - /* 2872 */ { MAD_F(0x04fbbdc3) /* 0.311460269 */, 17 }, - /* 2873 */ { MAD_F(0x04fc5564) /* 0.311604874 */, 17 }, - /* 2874 */ { MAD_F(0x04fced0a) /* 0.311749495 */, 17 }, - /* 2875 */ { MAD_F(0x04fd84b4) /* 0.311894133 */, 17 }, - /* 2876 */ { MAD_F(0x04fe1c62) /* 0.312038788 */, 17 }, - /* 2877 */ { MAD_F(0x04feb415) /* 0.312183460 */, 17 }, - /* 2878 */ { MAD_F(0x04ff4bcd) /* 0.312328148 */, 17 }, - /* 2879 */ { MAD_F(0x04ffe389) /* 0.312472854 */, 17 }, - - /* 2880 */ { MAD_F(0x05007b49) /* 0.312617576 */, 17 }, - /* 2881 */ { MAD_F(0x0501130e) /* 0.312762314 */, 17 }, - /* 2882 */ { MAD_F(0x0501aad8) /* 0.312907070 */, 17 }, - /* 2883 */ { MAD_F(0x050242a6) /* 0.313051842 */, 17 }, - /* 2884 */ { MAD_F(0x0502da78) /* 0.313196631 */, 17 }, - /* 2885 */ { MAD_F(0x0503724f) /* 0.313341437 */, 17 }, - /* 2886 */ { MAD_F(0x05040a2b) /* 0.313486259 */, 17 }, - /* 2887 */ { MAD_F(0x0504a20b) /* 0.313631098 */, 17 }, - /* 2888 */ { MAD_F(0x050539ef) /* 0.313775954 */, 17 }, - /* 2889 */ { MAD_F(0x0505d1d8) /* 0.313920827 */, 17 }, - /* 2890 */ { MAD_F(0x050669c5) /* 0.314065716 */, 17 }, - /* 2891 */ { MAD_F(0x050701b7) /* 0.314210622 */, 17 }, - /* 2892 */ { MAD_F(0x050799ae) /* 0.314355545 */, 17 }, - /* 2893 */ { MAD_F(0x050831a9) /* 0.314500484 */, 17 }, - /* 2894 */ { MAD_F(0x0508c9a8) /* 0.314645440 */, 17 }, - /* 2895 */ { MAD_F(0x050961ac) /* 0.314790413 */, 17 }, - - /* 2896 */ { MAD_F(0x0509f9b4) /* 0.314935403 */, 17 }, - /* 2897 */ { MAD_F(0x050a91c1) /* 0.315080409 */, 17 }, - /* 2898 */ { MAD_F(0x050b29d2) /* 0.315225432 */, 17 }, - /* 2899 */ { MAD_F(0x050bc1e8) /* 0.315370472 */, 17 }, - /* 2900 */ { MAD_F(0x050c5a02) /* 0.315515528 */, 17 }, - /* 2901 */ { MAD_F(0x050cf221) /* 0.315660601 */, 17 }, - /* 2902 */ { MAD_F(0x050d8a44) /* 0.315805690 */, 17 }, - /* 2903 */ { MAD_F(0x050e226c) /* 0.315950797 */, 17 }, - /* 2904 */ { MAD_F(0x050eba98) /* 0.316095920 */, 17 }, - /* 2905 */ { MAD_F(0x050f52c9) /* 0.316241059 */, 17 }, - /* 2906 */ { MAD_F(0x050feafe) /* 0.316386216 */, 17 }, - /* 2907 */ { MAD_F(0x05108337) /* 0.316531388 */, 17 }, - /* 2908 */ { MAD_F(0x05111b75) /* 0.316676578 */, 17 }, - /* 2909 */ { MAD_F(0x0511b3b8) /* 0.316821784 */, 17 }, - /* 2910 */ { MAD_F(0x05124bff) /* 0.316967007 */, 17 }, - /* 2911 */ { MAD_F(0x0512e44a) /* 0.317112247 */, 17 }, - - /* 2912 */ { MAD_F(0x05137c9a) /* 0.317257503 */, 17 }, - /* 2913 */ { MAD_F(0x051414ee) /* 0.317402775 */, 17 }, - /* 2914 */ { MAD_F(0x0514ad47) /* 0.317548065 */, 17 }, - /* 2915 */ { MAD_F(0x051545a5) /* 0.317693371 */, 17 }, - /* 2916 */ { MAD_F(0x0515de06) /* 0.317838693 */, 17 }, - /* 2917 */ { MAD_F(0x0516766d) /* 0.317984033 */, 17 }, - /* 2918 */ { MAD_F(0x05170ed7) /* 0.318129388 */, 17 }, - /* 2919 */ { MAD_F(0x0517a746) /* 0.318274761 */, 17 }, - /* 2920 */ { MAD_F(0x05183fba) /* 0.318420150 */, 17 }, - /* 2921 */ { MAD_F(0x0518d832) /* 0.318565555 */, 17 }, - /* 2922 */ { MAD_F(0x051970ae) /* 0.318710978 */, 17 }, - /* 2923 */ { MAD_F(0x051a092f) /* 0.318856416 */, 17 }, - /* 2924 */ { MAD_F(0x051aa1b5) /* 0.319001872 */, 17 }, - /* 2925 */ { MAD_F(0x051b3a3f) /* 0.319147344 */, 17 }, - /* 2926 */ { MAD_F(0x051bd2cd) /* 0.319292832 */, 17 }, - /* 2927 */ { MAD_F(0x051c6b60) /* 0.319438338 */, 17 }, - - /* 2928 */ { MAD_F(0x051d03f7) /* 0.319583859 */, 17 }, - /* 2929 */ { MAD_F(0x051d9c92) /* 0.319729398 */, 17 }, - /* 2930 */ { MAD_F(0x051e3532) /* 0.319874952 */, 17 }, - /* 2931 */ { MAD_F(0x051ecdd7) /* 0.320020524 */, 17 }, - /* 2932 */ { MAD_F(0x051f6680) /* 0.320166112 */, 17 }, - /* 2933 */ { MAD_F(0x051fff2d) /* 0.320311716 */, 17 }, - /* 2934 */ { MAD_F(0x052097df) /* 0.320457337 */, 17 }, - /* 2935 */ { MAD_F(0x05213095) /* 0.320602975 */, 17 }, - /* 2936 */ { MAD_F(0x0521c950) /* 0.320748629 */, 17 }, - /* 2937 */ { MAD_F(0x0522620f) /* 0.320894300 */, 17 }, - /* 2938 */ { MAD_F(0x0522fad3) /* 0.321039987 */, 17 }, - /* 2939 */ { MAD_F(0x0523939b) /* 0.321185691 */, 17 }, - /* 2940 */ { MAD_F(0x05242c68) /* 0.321331411 */, 17 }, - /* 2941 */ { MAD_F(0x0524c538) /* 0.321477148 */, 17 }, - /* 2942 */ { MAD_F(0x05255e0e) /* 0.321622901 */, 17 }, - /* 2943 */ { MAD_F(0x0525f6e8) /* 0.321768671 */, 17 }, - - /* 2944 */ { MAD_F(0x05268fc6) /* 0.321914457 */, 17 }, - /* 2945 */ { MAD_F(0x052728a9) /* 0.322060260 */, 17 }, - /* 2946 */ { MAD_F(0x0527c190) /* 0.322206079 */, 17 }, - /* 2947 */ { MAD_F(0x05285a7b) /* 0.322351915 */, 17 }, - /* 2948 */ { MAD_F(0x0528f36b) /* 0.322497768 */, 17 }, - /* 2949 */ { MAD_F(0x05298c5f) /* 0.322643636 */, 17 }, - /* 2950 */ { MAD_F(0x052a2558) /* 0.322789522 */, 17 }, - /* 2951 */ { MAD_F(0x052abe55) /* 0.322935424 */, 17 }, - /* 2952 */ { MAD_F(0x052b5757) /* 0.323081342 */, 17 }, - /* 2953 */ { MAD_F(0x052bf05d) /* 0.323227277 */, 17 }, - /* 2954 */ { MAD_F(0x052c8968) /* 0.323373228 */, 17 }, - /* 2955 */ { MAD_F(0x052d2277) /* 0.323519196 */, 17 }, - /* 2956 */ { MAD_F(0x052dbb8a) /* 0.323665180 */, 17 }, - /* 2957 */ { MAD_F(0x052e54a2) /* 0.323811180 */, 17 }, - /* 2958 */ { MAD_F(0x052eedbe) /* 0.323957197 */, 17 }, - /* 2959 */ { MAD_F(0x052f86de) /* 0.324103231 */, 17 }, - - /* 2960 */ { MAD_F(0x05302003) /* 0.324249281 */, 17 }, - /* 2961 */ { MAD_F(0x0530b92d) /* 0.324395347 */, 17 }, - /* 2962 */ { MAD_F(0x0531525b) /* 0.324541430 */, 17 }, - /* 2963 */ { MAD_F(0x0531eb8d) /* 0.324687530 */, 17 }, - /* 2964 */ { MAD_F(0x053284c4) /* 0.324833646 */, 17 }, - /* 2965 */ { MAD_F(0x05331dff) /* 0.324979778 */, 17 }, - /* 2966 */ { MAD_F(0x0533b73e) /* 0.325125926 */, 17 }, - /* 2967 */ { MAD_F(0x05345082) /* 0.325272091 */, 17 }, - /* 2968 */ { MAD_F(0x0534e9ca) /* 0.325418273 */, 17 }, - /* 2969 */ { MAD_F(0x05358317) /* 0.325564471 */, 17 }, - /* 2970 */ { MAD_F(0x05361c68) /* 0.325710685 */, 17 }, - /* 2971 */ { MAD_F(0x0536b5be) /* 0.325856916 */, 17 }, - /* 2972 */ { MAD_F(0x05374f17) /* 0.326003163 */, 17 }, - /* 2973 */ { MAD_F(0x0537e876) /* 0.326149427 */, 17 }, - /* 2974 */ { MAD_F(0x053881d9) /* 0.326295707 */, 17 }, - /* 2975 */ { MAD_F(0x05391b40) /* 0.326442003 */, 17 }, - - /* 2976 */ { MAD_F(0x0539b4ab) /* 0.326588316 */, 17 }, - /* 2977 */ { MAD_F(0x053a4e1b) /* 0.326734645 */, 17 }, - /* 2978 */ { MAD_F(0x053ae78f) /* 0.326880990 */, 17 }, - /* 2979 */ { MAD_F(0x053b8108) /* 0.327027352 */, 17 }, - /* 2980 */ { MAD_F(0x053c1a85) /* 0.327173730 */, 17 }, - /* 2981 */ { MAD_F(0x053cb407) /* 0.327320125 */, 17 }, - /* 2982 */ { MAD_F(0x053d4d8d) /* 0.327466536 */, 17 }, - /* 2983 */ { MAD_F(0x053de717) /* 0.327612963 */, 17 }, - /* 2984 */ { MAD_F(0x053e80a6) /* 0.327759407 */, 17 }, - /* 2985 */ { MAD_F(0x053f1a39) /* 0.327905867 */, 17 }, - /* 2986 */ { MAD_F(0x053fb3d0) /* 0.328052344 */, 17 }, - /* 2987 */ { MAD_F(0x05404d6c) /* 0.328198837 */, 17 }, - /* 2988 */ { MAD_F(0x0540e70c) /* 0.328345346 */, 17 }, - /* 2989 */ { MAD_F(0x054180b1) /* 0.328491871 */, 17 }, - /* 2990 */ { MAD_F(0x05421a5a) /* 0.328638413 */, 17 }, - /* 2991 */ { MAD_F(0x0542b407) /* 0.328784971 */, 17 }, - - /* 2992 */ { MAD_F(0x05434db9) /* 0.328931546 */, 17 }, - /* 2993 */ { MAD_F(0x0543e76f) /* 0.329078137 */, 17 }, - /* 2994 */ { MAD_F(0x0544812a) /* 0.329224744 */, 17 }, - /* 2995 */ { MAD_F(0x05451ae9) /* 0.329371367 */, 17 }, - /* 2996 */ { MAD_F(0x0545b4ac) /* 0.329518007 */, 17 }, - /* 2997 */ { MAD_F(0x05464e74) /* 0.329664663 */, 17 }, - /* 2998 */ { MAD_F(0x0546e840) /* 0.329811336 */, 17 }, - /* 2999 */ { MAD_F(0x05478211) /* 0.329958024 */, 17 }, - /* 3000 */ { MAD_F(0x05481be5) /* 0.330104730 */, 17 }, - /* 3001 */ { MAD_F(0x0548b5bf) /* 0.330251451 */, 17 }, - /* 3002 */ { MAD_F(0x05494f9c) /* 0.330398189 */, 17 }, - /* 3003 */ { MAD_F(0x0549e97e) /* 0.330544943 */, 17 }, - /* 3004 */ { MAD_F(0x054a8364) /* 0.330691713 */, 17 }, - /* 3005 */ { MAD_F(0x054b1d4f) /* 0.330838499 */, 17 }, - /* 3006 */ { MAD_F(0x054bb73e) /* 0.330985302 */, 17 }, - /* 3007 */ { MAD_F(0x054c5132) /* 0.331132121 */, 17 }, - - /* 3008 */ { MAD_F(0x054ceb2a) /* 0.331278957 */, 17 }, - /* 3009 */ { MAD_F(0x054d8526) /* 0.331425808 */, 17 }, - /* 3010 */ { MAD_F(0x054e1f26) /* 0.331572676 */, 17 }, - /* 3011 */ { MAD_F(0x054eb92b) /* 0.331719560 */, 17 }, - /* 3012 */ { MAD_F(0x054f5334) /* 0.331866461 */, 17 }, - /* 3013 */ { MAD_F(0x054fed42) /* 0.332013377 */, 17 }, - /* 3014 */ { MAD_F(0x05508754) /* 0.332160310 */, 17 }, - /* 3015 */ { MAD_F(0x0551216b) /* 0.332307260 */, 17 }, - /* 3016 */ { MAD_F(0x0551bb85) /* 0.332454225 */, 17 }, - /* 3017 */ { MAD_F(0x055255a4) /* 0.332601207 */, 17 }, - /* 3018 */ { MAD_F(0x0552efc8) /* 0.332748205 */, 17 }, - /* 3019 */ { MAD_F(0x055389f0) /* 0.332895219 */, 17 }, - /* 3020 */ { MAD_F(0x0554241c) /* 0.333042249 */, 17 }, - /* 3021 */ { MAD_F(0x0554be4c) /* 0.333189296 */, 17 }, - /* 3022 */ { MAD_F(0x05555881) /* 0.333336359 */, 17 }, - /* 3023 */ { MAD_F(0x0555f2ba) /* 0.333483438 */, 17 }, - - /* 3024 */ { MAD_F(0x05568cf8) /* 0.333630533 */, 17 }, - /* 3025 */ { MAD_F(0x0557273a) /* 0.333777645 */, 17 }, - /* 3026 */ { MAD_F(0x0557c180) /* 0.333924772 */, 17 }, - /* 3027 */ { MAD_F(0x05585bcb) /* 0.334071916 */, 17 }, - /* 3028 */ { MAD_F(0x0558f61a) /* 0.334219076 */, 17 }, - /* 3029 */ { MAD_F(0x0559906d) /* 0.334366253 */, 17 }, - /* 3030 */ { MAD_F(0x055a2ac5) /* 0.334513445 */, 17 }, - /* 3031 */ { MAD_F(0x055ac521) /* 0.334660654 */, 17 }, - /* 3032 */ { MAD_F(0x055b5f81) /* 0.334807879 */, 17 }, - /* 3033 */ { MAD_F(0x055bf9e6) /* 0.334955120 */, 17 }, - /* 3034 */ { MAD_F(0x055c944f) /* 0.335102377 */, 17 }, - /* 3035 */ { MAD_F(0x055d2ebd) /* 0.335249651 */, 17 }, - /* 3036 */ { MAD_F(0x055dc92e) /* 0.335396941 */, 17 }, - /* 3037 */ { MAD_F(0x055e63a5) /* 0.335544246 */, 17 }, - /* 3038 */ { MAD_F(0x055efe1f) /* 0.335691568 */, 17 }, - /* 3039 */ { MAD_F(0x055f989e) /* 0.335838906 */, 17 }, - - /* 3040 */ { MAD_F(0x05603321) /* 0.335986261 */, 17 }, - /* 3041 */ { MAD_F(0x0560cda8) /* 0.336133631 */, 17 }, - /* 3042 */ { MAD_F(0x05616834) /* 0.336281018 */, 17 }, - /* 3043 */ { MAD_F(0x056202c4) /* 0.336428421 */, 17 }, - /* 3044 */ { MAD_F(0x05629d59) /* 0.336575840 */, 17 }, - /* 3045 */ { MAD_F(0x056337f2) /* 0.336723275 */, 17 }, - /* 3046 */ { MAD_F(0x0563d28f) /* 0.336870726 */, 17 }, - /* 3047 */ { MAD_F(0x05646d30) /* 0.337018193 */, 17 }, - /* 3048 */ { MAD_F(0x056507d6) /* 0.337165677 */, 17 }, - /* 3049 */ { MAD_F(0x0565a280) /* 0.337313176 */, 17 }, - /* 3050 */ { MAD_F(0x05663d2f) /* 0.337460692 */, 17 }, - /* 3051 */ { MAD_F(0x0566d7e1) /* 0.337608224 */, 17 }, - /* 3052 */ { MAD_F(0x05677298) /* 0.337755772 */, 17 }, - /* 3053 */ { MAD_F(0x05680d54) /* 0.337903336 */, 17 }, - /* 3054 */ { MAD_F(0x0568a814) /* 0.338050916 */, 17 }, - /* 3055 */ { MAD_F(0x056942d8) /* 0.338198513 */, 17 }, - - /* 3056 */ { MAD_F(0x0569dda0) /* 0.338346125 */, 17 }, - /* 3057 */ { MAD_F(0x056a786d) /* 0.338493753 */, 17 }, - /* 3058 */ { MAD_F(0x056b133e) /* 0.338641398 */, 17 }, - /* 3059 */ { MAD_F(0x056bae13) /* 0.338789059 */, 17 }, - /* 3060 */ { MAD_F(0x056c48ed) /* 0.338936736 */, 17 }, - /* 3061 */ { MAD_F(0x056ce3cb) /* 0.339084429 */, 17 }, - /* 3062 */ { MAD_F(0x056d7ead) /* 0.339232138 */, 17 }, - /* 3063 */ { MAD_F(0x056e1994) /* 0.339379863 */, 17 }, - /* 3064 */ { MAD_F(0x056eb47f) /* 0.339527604 */, 17 }, - /* 3065 */ { MAD_F(0x056f4f6e) /* 0.339675361 */, 17 }, - /* 3066 */ { MAD_F(0x056fea62) /* 0.339823134 */, 17 }, - /* 3067 */ { MAD_F(0x0570855a) /* 0.339970924 */, 17 }, - /* 3068 */ { MAD_F(0x05712056) /* 0.340118729 */, 17 }, - /* 3069 */ { MAD_F(0x0571bb56) /* 0.340266550 */, 17 }, - /* 3070 */ { MAD_F(0x0572565b) /* 0.340414388 */, 17 }, - /* 3071 */ { MAD_F(0x0572f164) /* 0.340562242 */, 17 }, - - /* 3072 */ { MAD_F(0x05738c72) /* 0.340710111 */, 17 }, - /* 3073 */ { MAD_F(0x05742784) /* 0.340857997 */, 17 }, - /* 3074 */ { MAD_F(0x0574c29a) /* 0.341005899 */, 17 }, - /* 3075 */ { MAD_F(0x05755db4) /* 0.341153816 */, 17 }, - /* 3076 */ { MAD_F(0x0575f8d3) /* 0.341301750 */, 17 }, - /* 3077 */ { MAD_F(0x057693f6) /* 0.341449700 */, 17 }, - /* 3078 */ { MAD_F(0x05772f1d) /* 0.341597666 */, 17 }, - /* 3079 */ { MAD_F(0x0577ca49) /* 0.341745648 */, 17 }, - /* 3080 */ { MAD_F(0x05786578) /* 0.341893646 */, 17 }, - /* 3081 */ { MAD_F(0x057900ad) /* 0.342041659 */, 17 }, - /* 3082 */ { MAD_F(0x05799be5) /* 0.342189689 */, 17 }, - /* 3083 */ { MAD_F(0x057a3722) /* 0.342337735 */, 17 }, - /* 3084 */ { MAD_F(0x057ad263) /* 0.342485797 */, 17 }, - /* 3085 */ { MAD_F(0x057b6da8) /* 0.342633875 */, 17 }, - /* 3086 */ { MAD_F(0x057c08f2) /* 0.342781969 */, 17 }, - /* 3087 */ { MAD_F(0x057ca440) /* 0.342930079 */, 17 }, - - /* 3088 */ { MAD_F(0x057d3f92) /* 0.343078205 */, 17 }, - /* 3089 */ { MAD_F(0x057ddae9) /* 0.343226347 */, 17 }, - /* 3090 */ { MAD_F(0x057e7644) /* 0.343374505 */, 17 }, - /* 3091 */ { MAD_F(0x057f11a3) /* 0.343522679 */, 17 }, - /* 3092 */ { MAD_F(0x057fad06) /* 0.343670869 */, 17 }, - /* 3093 */ { MAD_F(0x0580486e) /* 0.343819075 */, 17 }, - /* 3094 */ { MAD_F(0x0580e3da) /* 0.343967296 */, 17 }, - /* 3095 */ { MAD_F(0x05817f4a) /* 0.344115534 */, 17 }, - /* 3096 */ { MAD_F(0x05821abf) /* 0.344263788 */, 17 }, - /* 3097 */ { MAD_F(0x0582b638) /* 0.344412058 */, 17 }, - /* 3098 */ { MAD_F(0x058351b5) /* 0.344560343 */, 17 }, - /* 3099 */ { MAD_F(0x0583ed36) /* 0.344708645 */, 17 }, - /* 3100 */ { MAD_F(0x058488bc) /* 0.344856963 */, 17 }, - /* 3101 */ { MAD_F(0x05852446) /* 0.345005296 */, 17 }, - /* 3102 */ { MAD_F(0x0585bfd4) /* 0.345153646 */, 17 }, - /* 3103 */ { MAD_F(0x05865b67) /* 0.345302011 */, 17 }, - - /* 3104 */ { MAD_F(0x0586f6fd) /* 0.345450393 */, 17 }, - /* 3105 */ { MAD_F(0x05879298) /* 0.345598790 */, 17 }, - /* 3106 */ { MAD_F(0x05882e38) /* 0.345747203 */, 17 }, - /* 3107 */ { MAD_F(0x0588c9dc) /* 0.345895632 */, 17 }, - /* 3108 */ { MAD_F(0x05896583) /* 0.346044077 */, 17 }, - /* 3109 */ { MAD_F(0x058a0130) /* 0.346192538 */, 17 }, - /* 3110 */ { MAD_F(0x058a9ce0) /* 0.346341015 */, 17 }, - /* 3111 */ { MAD_F(0x058b3895) /* 0.346489508 */, 17 }, - /* 3112 */ { MAD_F(0x058bd44e) /* 0.346638017 */, 17 }, - /* 3113 */ { MAD_F(0x058c700b) /* 0.346786542 */, 17 }, - /* 3114 */ { MAD_F(0x058d0bcd) /* 0.346935082 */, 17 }, - /* 3115 */ { MAD_F(0x058da793) /* 0.347083639 */, 17 }, - /* 3116 */ { MAD_F(0x058e435d) /* 0.347232211 */, 17 }, - /* 3117 */ { MAD_F(0x058edf2b) /* 0.347380799 */, 17 }, - /* 3118 */ { MAD_F(0x058f7afe) /* 0.347529403 */, 17 }, - /* 3119 */ { MAD_F(0x059016d5) /* 0.347678023 */, 17 }, - - /* 3120 */ { MAD_F(0x0590b2b0) /* 0.347826659 */, 17 }, - /* 3121 */ { MAD_F(0x05914e8f) /* 0.347975311 */, 17 }, - /* 3122 */ { MAD_F(0x0591ea73) /* 0.348123979 */, 17 }, - /* 3123 */ { MAD_F(0x0592865b) /* 0.348272662 */, 17 }, - /* 3124 */ { MAD_F(0x05932247) /* 0.348421362 */, 17 }, - /* 3125 */ { MAD_F(0x0593be37) /* 0.348570077 */, 17 }, - /* 3126 */ { MAD_F(0x05945a2c) /* 0.348718808 */, 17 }, - /* 3127 */ { MAD_F(0x0594f625) /* 0.348867555 */, 17 }, - /* 3128 */ { MAD_F(0x05959222) /* 0.349016318 */, 17 }, - /* 3129 */ { MAD_F(0x05962e24) /* 0.349165097 */, 17 }, - /* 3130 */ { MAD_F(0x0596ca2a) /* 0.349313892 */, 17 }, - /* 3131 */ { MAD_F(0x05976634) /* 0.349462702 */, 17 }, - /* 3132 */ { MAD_F(0x05980242) /* 0.349611528 */, 17 }, - /* 3133 */ { MAD_F(0x05989e54) /* 0.349760370 */, 17 }, - /* 3134 */ { MAD_F(0x05993a6b) /* 0.349909228 */, 17 }, - /* 3135 */ { MAD_F(0x0599d686) /* 0.350058102 */, 17 }, - - /* 3136 */ { MAD_F(0x059a72a5) /* 0.350206992 */, 17 }, - /* 3137 */ { MAD_F(0x059b0ec9) /* 0.350355897 */, 17 }, - /* 3138 */ { MAD_F(0x059baaf1) /* 0.350504818 */, 17 }, - /* 3139 */ { MAD_F(0x059c471d) /* 0.350653756 */, 17 }, - /* 3140 */ { MAD_F(0x059ce34d) /* 0.350802708 */, 17 }, - /* 3141 */ { MAD_F(0x059d7f81) /* 0.350951677 */, 17 }, - /* 3142 */ { MAD_F(0x059e1bba) /* 0.351100662 */, 17 }, - /* 3143 */ { MAD_F(0x059eb7f7) /* 0.351249662 */, 17 }, - /* 3144 */ { MAD_F(0x059f5438) /* 0.351398678 */, 17 }, - /* 3145 */ { MAD_F(0x059ff07e) /* 0.351547710 */, 17 }, - /* 3146 */ { MAD_F(0x05a08cc7) /* 0.351696758 */, 17 }, - /* 3147 */ { MAD_F(0x05a12915) /* 0.351845821 */, 17 }, - /* 3148 */ { MAD_F(0x05a1c567) /* 0.351994901 */, 17 }, - /* 3149 */ { MAD_F(0x05a261be) /* 0.352143996 */, 17 }, - /* 3150 */ { MAD_F(0x05a2fe18) /* 0.352293107 */, 17 }, - /* 3151 */ { MAD_F(0x05a39a77) /* 0.352442233 */, 17 }, - - /* 3152 */ { MAD_F(0x05a436da) /* 0.352591376 */, 17 }, - /* 3153 */ { MAD_F(0x05a4d342) /* 0.352740534 */, 17 }, - /* 3154 */ { MAD_F(0x05a56fad) /* 0.352889708 */, 17 }, - /* 3155 */ { MAD_F(0x05a60c1d) /* 0.353038898 */, 17 }, - /* 3156 */ { MAD_F(0x05a6a891) /* 0.353188103 */, 17 }, - /* 3157 */ { MAD_F(0x05a7450a) /* 0.353337325 */, 17 }, - /* 3158 */ { MAD_F(0x05a7e186) /* 0.353486562 */, 17 }, - /* 3159 */ { MAD_F(0x05a87e07) /* 0.353635814 */, 17 }, - /* 3160 */ { MAD_F(0x05a91a8c) /* 0.353785083 */, 17 }, - /* 3161 */ { MAD_F(0x05a9b715) /* 0.353934367 */, 17 }, - /* 3162 */ { MAD_F(0x05aa53a2) /* 0.354083667 */, 17 }, - /* 3163 */ { MAD_F(0x05aaf034) /* 0.354232983 */, 17 }, - /* 3164 */ { MAD_F(0x05ab8cca) /* 0.354382314 */, 17 }, - /* 3165 */ { MAD_F(0x05ac2964) /* 0.354531662 */, 17 }, - /* 3166 */ { MAD_F(0x05acc602) /* 0.354681025 */, 17 }, - /* 3167 */ { MAD_F(0x05ad62a5) /* 0.354830403 */, 17 }, - - /* 3168 */ { MAD_F(0x05adff4c) /* 0.354979798 */, 17 }, - /* 3169 */ { MAD_F(0x05ae9bf7) /* 0.355129208 */, 17 }, - /* 3170 */ { MAD_F(0x05af38a6) /* 0.355278634 */, 17 }, - /* 3171 */ { MAD_F(0x05afd559) /* 0.355428075 */, 17 }, - /* 3172 */ { MAD_F(0x05b07211) /* 0.355577533 */, 17 }, - /* 3173 */ { MAD_F(0x05b10ecd) /* 0.355727006 */, 17 }, - /* 3174 */ { MAD_F(0x05b1ab8d) /* 0.355876494 */, 17 }, - /* 3175 */ { MAD_F(0x05b24851) /* 0.356025999 */, 17 }, - /* 3176 */ { MAD_F(0x05b2e51a) /* 0.356175519 */, 17 }, - /* 3177 */ { MAD_F(0x05b381e6) /* 0.356325054 */, 17 }, - /* 3178 */ { MAD_F(0x05b41eb7) /* 0.356474606 */, 17 }, - /* 3179 */ { MAD_F(0x05b4bb8c) /* 0.356624173 */, 17 }, - /* 3180 */ { MAD_F(0x05b55866) /* 0.356773756 */, 17 }, - /* 3181 */ { MAD_F(0x05b5f543) /* 0.356923354 */, 17 }, - /* 3182 */ { MAD_F(0x05b69225) /* 0.357072969 */, 17 }, - /* 3183 */ { MAD_F(0x05b72f0b) /* 0.357222598 */, 17 }, - - /* 3184 */ { MAD_F(0x05b7cbf5) /* 0.357372244 */, 17 }, - /* 3185 */ { MAD_F(0x05b868e3) /* 0.357521905 */, 17 }, - /* 3186 */ { MAD_F(0x05b905d6) /* 0.357671582 */, 17 }, - /* 3187 */ { MAD_F(0x05b9a2cd) /* 0.357821275 */, 17 }, - /* 3188 */ { MAD_F(0x05ba3fc8) /* 0.357970983 */, 17 }, - /* 3189 */ { MAD_F(0x05badcc7) /* 0.358120707 */, 17 }, - /* 3190 */ { MAD_F(0x05bb79ca) /* 0.358270446 */, 17 }, - /* 3191 */ { MAD_F(0x05bc16d2) /* 0.358420201 */, 17 }, - /* 3192 */ { MAD_F(0x05bcb3de) /* 0.358569972 */, 17 }, - /* 3193 */ { MAD_F(0x05bd50ee) /* 0.358719758 */, 17 }, - /* 3194 */ { MAD_F(0x05bdee02) /* 0.358869560 */, 17 }, - /* 3195 */ { MAD_F(0x05be8b1a) /* 0.359019378 */, 17 }, - /* 3196 */ { MAD_F(0x05bf2837) /* 0.359169211 */, 17 }, - /* 3197 */ { MAD_F(0x05bfc558) /* 0.359319060 */, 17 }, - /* 3198 */ { MAD_F(0x05c0627d) /* 0.359468925 */, 17 }, - /* 3199 */ { MAD_F(0x05c0ffa6) /* 0.359618805 */, 17 }, - - /* 3200 */ { MAD_F(0x05c19cd3) /* 0.359768701 */, 17 }, - /* 3201 */ { MAD_F(0x05c23a05) /* 0.359918612 */, 17 }, - /* 3202 */ { MAD_F(0x05c2d73a) /* 0.360068540 */, 17 }, - /* 3203 */ { MAD_F(0x05c37474) /* 0.360218482 */, 17 }, - /* 3204 */ { MAD_F(0x05c411b2) /* 0.360368440 */, 17 }, - /* 3205 */ { MAD_F(0x05c4aef5) /* 0.360518414 */, 17 }, - /* 3206 */ { MAD_F(0x05c54c3b) /* 0.360668404 */, 17 }, - /* 3207 */ { MAD_F(0x05c5e986) /* 0.360818409 */, 17 }, - /* 3208 */ { MAD_F(0x05c686d5) /* 0.360968429 */, 17 }, - /* 3209 */ { MAD_F(0x05c72428) /* 0.361118466 */, 17 }, - /* 3210 */ { MAD_F(0x05c7c17f) /* 0.361268517 */, 17 }, - /* 3211 */ { MAD_F(0x05c85eda) /* 0.361418585 */, 17 }, - /* 3212 */ { MAD_F(0x05c8fc3a) /* 0.361568668 */, 17 }, - /* 3213 */ { MAD_F(0x05c9999e) /* 0.361718766 */, 17 }, - /* 3214 */ { MAD_F(0x05ca3706) /* 0.361868881 */, 17 }, - /* 3215 */ { MAD_F(0x05cad472) /* 0.362019010 */, 17 }, - - /* 3216 */ { MAD_F(0x05cb71e2) /* 0.362169156 */, 17 }, - /* 3217 */ { MAD_F(0x05cc0f57) /* 0.362319316 */, 17 }, - /* 3218 */ { MAD_F(0x05ccaccf) /* 0.362469493 */, 17 }, - /* 3219 */ { MAD_F(0x05cd4a4c) /* 0.362619685 */, 17 }, - /* 3220 */ { MAD_F(0x05cde7cd) /* 0.362769892 */, 17 }, - /* 3221 */ { MAD_F(0x05ce8552) /* 0.362920115 */, 17 }, - /* 3222 */ { MAD_F(0x05cf22dc) /* 0.363070354 */, 17 }, - /* 3223 */ { MAD_F(0x05cfc069) /* 0.363220608 */, 17 }, - /* 3224 */ { MAD_F(0x05d05dfb) /* 0.363370878 */, 17 }, - /* 3225 */ { MAD_F(0x05d0fb91) /* 0.363521163 */, 17 }, - /* 3226 */ { MAD_F(0x05d1992b) /* 0.363671464 */, 17 }, - /* 3227 */ { MAD_F(0x05d236c9) /* 0.363821780 */, 17 }, - /* 3228 */ { MAD_F(0x05d2d46c) /* 0.363972112 */, 17 }, - /* 3229 */ { MAD_F(0x05d37212) /* 0.364122459 */, 17 }, - /* 3230 */ { MAD_F(0x05d40fbd) /* 0.364272822 */, 17 }, - /* 3231 */ { MAD_F(0x05d4ad6c) /* 0.364423200 */, 17 }, - - /* 3232 */ { MAD_F(0x05d54b1f) /* 0.364573594 */, 17 }, - /* 3233 */ { MAD_F(0x05d5e8d6) /* 0.364724004 */, 17 }, - /* 3234 */ { MAD_F(0x05d68691) /* 0.364874429 */, 17 }, - /* 3235 */ { MAD_F(0x05d72451) /* 0.365024869 */, 17 }, - /* 3236 */ { MAD_F(0x05d7c215) /* 0.365175325 */, 17 }, - /* 3237 */ { MAD_F(0x05d85fdc) /* 0.365325796 */, 17 }, - /* 3238 */ { MAD_F(0x05d8fda8) /* 0.365476283 */, 17 }, - /* 3239 */ { MAD_F(0x05d99b79) /* 0.365626786 */, 17 }, - /* 3240 */ { MAD_F(0x05da394d) /* 0.365777304 */, 17 }, - /* 3241 */ { MAD_F(0x05dad726) /* 0.365927837 */, 17 }, - /* 3242 */ { MAD_F(0x05db7502) /* 0.366078386 */, 17 }, - /* 3243 */ { MAD_F(0x05dc12e3) /* 0.366228950 */, 17 }, - /* 3244 */ { MAD_F(0x05dcb0c8) /* 0.366379530 */, 17 }, - /* 3245 */ { MAD_F(0x05dd4eb1) /* 0.366530125 */, 17 }, - /* 3246 */ { MAD_F(0x05ddec9e) /* 0.366680736 */, 17 }, - /* 3247 */ { MAD_F(0x05de8a90) /* 0.366831362 */, 17 }, - - /* 3248 */ { MAD_F(0x05df2885) /* 0.366982004 */, 17 }, - /* 3249 */ { MAD_F(0x05dfc67f) /* 0.367132661 */, 17 }, - /* 3250 */ { MAD_F(0x05e0647d) /* 0.367283334 */, 17 }, - /* 3251 */ { MAD_F(0x05e1027f) /* 0.367434022 */, 17 }, - /* 3252 */ { MAD_F(0x05e1a085) /* 0.367584725 */, 17 }, - /* 3253 */ { MAD_F(0x05e23e8f) /* 0.367735444 */, 17 }, - /* 3254 */ { MAD_F(0x05e2dc9e) /* 0.367886179 */, 17 }, - /* 3255 */ { MAD_F(0x05e37ab0) /* 0.368036929 */, 17 }, - /* 3256 */ { MAD_F(0x05e418c7) /* 0.368187694 */, 17 }, - /* 3257 */ { MAD_F(0x05e4b6e2) /* 0.368338475 */, 17 }, - /* 3258 */ { MAD_F(0x05e55501) /* 0.368489271 */, 17 }, - /* 3259 */ { MAD_F(0x05e5f324) /* 0.368640082 */, 17 }, - /* 3260 */ { MAD_F(0x05e6914c) /* 0.368790909 */, 17 }, - /* 3261 */ { MAD_F(0x05e72f77) /* 0.368941752 */, 17 }, - /* 3262 */ { MAD_F(0x05e7cda7) /* 0.369092610 */, 17 }, - /* 3263 */ { MAD_F(0x05e86bda) /* 0.369243483 */, 17 }, - - /* 3264 */ { MAD_F(0x05e90a12) /* 0.369394372 */, 17 }, - /* 3265 */ { MAD_F(0x05e9a84e) /* 0.369545276 */, 17 }, - /* 3266 */ { MAD_F(0x05ea468e) /* 0.369696195 */, 17 }, - /* 3267 */ { MAD_F(0x05eae4d3) /* 0.369847130 */, 17 }, - /* 3268 */ { MAD_F(0x05eb831b) /* 0.369998080 */, 17 }, - /* 3269 */ { MAD_F(0x05ec2168) /* 0.370149046 */, 17 }, - /* 3270 */ { MAD_F(0x05ecbfb8) /* 0.370300027 */, 17 }, - /* 3271 */ { MAD_F(0x05ed5e0d) /* 0.370451024 */, 17 }, - /* 3272 */ { MAD_F(0x05edfc66) /* 0.370602036 */, 17 }, - /* 3273 */ { MAD_F(0x05ee9ac3) /* 0.370753063 */, 17 }, - /* 3274 */ { MAD_F(0x05ef3924) /* 0.370904105 */, 17 }, - /* 3275 */ { MAD_F(0x05efd78a) /* 0.371055163 */, 17 }, - /* 3276 */ { MAD_F(0x05f075f3) /* 0.371206237 */, 17 }, - /* 3277 */ { MAD_F(0x05f11461) /* 0.371357326 */, 17 }, - /* 3278 */ { MAD_F(0x05f1b2d3) /* 0.371508430 */, 17 }, - /* 3279 */ { MAD_F(0x05f25148) /* 0.371659549 */, 17 }, - - /* 3280 */ { MAD_F(0x05f2efc2) /* 0.371810684 */, 17 }, - /* 3281 */ { MAD_F(0x05f38e40) /* 0.371961834 */, 17 }, - /* 3282 */ { MAD_F(0x05f42cc3) /* 0.372113000 */, 17 }, - /* 3283 */ { MAD_F(0x05f4cb49) /* 0.372264181 */, 17 }, - /* 3284 */ { MAD_F(0x05f569d3) /* 0.372415377 */, 17 }, - /* 3285 */ { MAD_F(0x05f60862) /* 0.372566589 */, 17 }, - /* 3286 */ { MAD_F(0x05f6a6f5) /* 0.372717816 */, 17 }, - /* 3287 */ { MAD_F(0x05f7458b) /* 0.372869058 */, 17 }, - /* 3288 */ { MAD_F(0x05f7e426) /* 0.373020316 */, 17 }, - /* 3289 */ { MAD_F(0x05f882c5) /* 0.373171589 */, 17 }, - /* 3290 */ { MAD_F(0x05f92169) /* 0.373322877 */, 17 }, - /* 3291 */ { MAD_F(0x05f9c010) /* 0.373474181 */, 17 }, - /* 3292 */ { MAD_F(0x05fa5ebb) /* 0.373625500 */, 17 }, - /* 3293 */ { MAD_F(0x05fafd6b) /* 0.373776834 */, 17 }, - /* 3294 */ { MAD_F(0x05fb9c1e) /* 0.373928184 */, 17 }, - /* 3295 */ { MAD_F(0x05fc3ad6) /* 0.374079549 */, 17 }, - - /* 3296 */ { MAD_F(0x05fcd992) /* 0.374230929 */, 17 }, - /* 3297 */ { MAD_F(0x05fd7852) /* 0.374382325 */, 17 }, - /* 3298 */ { MAD_F(0x05fe1716) /* 0.374533735 */, 17 }, - /* 3299 */ { MAD_F(0x05feb5de) /* 0.374685162 */, 17 }, - /* 3300 */ { MAD_F(0x05ff54aa) /* 0.374836603 */, 17 }, - /* 3301 */ { MAD_F(0x05fff37b) /* 0.374988060 */, 17 }, - /* 3302 */ { MAD_F(0x0600924f) /* 0.375139532 */, 17 }, - /* 3303 */ { MAD_F(0x06013128) /* 0.375291019 */, 17 }, - /* 3304 */ { MAD_F(0x0601d004) /* 0.375442522 */, 17 }, - /* 3305 */ { MAD_F(0x06026ee5) /* 0.375594040 */, 17 }, - /* 3306 */ { MAD_F(0x06030dca) /* 0.375745573 */, 17 }, - /* 3307 */ { MAD_F(0x0603acb3) /* 0.375897122 */, 17 }, - /* 3308 */ { MAD_F(0x06044ba0) /* 0.376048685 */, 17 }, - /* 3309 */ { MAD_F(0x0604ea91) /* 0.376200265 */, 17 }, - /* 3310 */ { MAD_F(0x06058987) /* 0.376351859 */, 17 }, - /* 3311 */ { MAD_F(0x06062880) /* 0.376503468 */, 17 }, - - /* 3312 */ { MAD_F(0x0606c77d) /* 0.376655093 */, 17 }, - /* 3313 */ { MAD_F(0x0607667f) /* 0.376806733 */, 17 }, - /* 3314 */ { MAD_F(0x06080585) /* 0.376958389 */, 17 }, - /* 3315 */ { MAD_F(0x0608a48f) /* 0.377110059 */, 17 }, - /* 3316 */ { MAD_F(0x0609439c) /* 0.377261745 */, 17 }, - /* 3317 */ { MAD_F(0x0609e2ae) /* 0.377413446 */, 17 }, - /* 3318 */ { MAD_F(0x060a81c4) /* 0.377565163 */, 17 }, - /* 3319 */ { MAD_F(0x060b20df) /* 0.377716894 */, 17 }, - /* 3320 */ { MAD_F(0x060bbffd) /* 0.377868641 */, 17 }, - /* 3321 */ { MAD_F(0x060c5f1f) /* 0.378020403 */, 17 }, - /* 3322 */ { MAD_F(0x060cfe46) /* 0.378172181 */, 17 }, - /* 3323 */ { MAD_F(0x060d9d70) /* 0.378323973 */, 17 }, - /* 3324 */ { MAD_F(0x060e3c9f) /* 0.378475781 */, 17 }, - /* 3325 */ { MAD_F(0x060edbd1) /* 0.378627604 */, 17 }, - /* 3326 */ { MAD_F(0x060f7b08) /* 0.378779442 */, 17 }, - /* 3327 */ { MAD_F(0x06101a43) /* 0.378931296 */, 17 }, - - /* 3328 */ { MAD_F(0x0610b982) /* 0.379083164 */, 17 }, - /* 3329 */ { MAD_F(0x061158c5) /* 0.379235048 */, 17 }, - /* 3330 */ { MAD_F(0x0611f80c) /* 0.379386947 */, 17 }, - /* 3331 */ { MAD_F(0x06129757) /* 0.379538862 */, 17 }, - /* 3332 */ { MAD_F(0x061336a6) /* 0.379690791 */, 17 }, - /* 3333 */ { MAD_F(0x0613d5fa) /* 0.379842736 */, 17 }, - /* 3334 */ { MAD_F(0x06147551) /* 0.379994696 */, 17 }, - /* 3335 */ { MAD_F(0x061514ad) /* 0.380146671 */, 17 }, - /* 3336 */ { MAD_F(0x0615b40c) /* 0.380298661 */, 17 }, - /* 3337 */ { MAD_F(0x06165370) /* 0.380450666 */, 17 }, - /* 3338 */ { MAD_F(0x0616f2d8) /* 0.380602687 */, 17 }, - /* 3339 */ { MAD_F(0x06179243) /* 0.380754723 */, 17 }, - /* 3340 */ { MAD_F(0x061831b3) /* 0.380906774 */, 17 }, - /* 3341 */ { MAD_F(0x0618d127) /* 0.381058840 */, 17 }, - /* 3342 */ { MAD_F(0x0619709f) /* 0.381210921 */, 17 }, - /* 3343 */ { MAD_F(0x061a101b) /* 0.381363018 */, 17 }, - - /* 3344 */ { MAD_F(0x061aaf9c) /* 0.381515130 */, 17 }, - /* 3345 */ { MAD_F(0x061b4f20) /* 0.381667257 */, 17 }, - /* 3346 */ { MAD_F(0x061beea8) /* 0.381819399 */, 17 }, - /* 3347 */ { MAD_F(0x061c8e34) /* 0.381971556 */, 17 }, - /* 3348 */ { MAD_F(0x061d2dc5) /* 0.382123728 */, 17 }, - /* 3349 */ { MAD_F(0x061dcd59) /* 0.382275916 */, 17 }, - /* 3350 */ { MAD_F(0x061e6cf2) /* 0.382428118 */, 17 }, - /* 3351 */ { MAD_F(0x061f0c8f) /* 0.382580336 */, 17 }, - /* 3352 */ { MAD_F(0x061fac2f) /* 0.382732569 */, 17 }, - /* 3353 */ { MAD_F(0x06204bd4) /* 0.382884817 */, 17 }, - /* 3354 */ { MAD_F(0x0620eb7d) /* 0.383037080 */, 17 }, - /* 3355 */ { MAD_F(0x06218b2a) /* 0.383189358 */, 17 }, - /* 3356 */ { MAD_F(0x06222adb) /* 0.383341652 */, 17 }, - /* 3357 */ { MAD_F(0x0622ca90) /* 0.383493960 */, 17 }, - /* 3358 */ { MAD_F(0x06236a49) /* 0.383646284 */, 17 }, - /* 3359 */ { MAD_F(0x06240a06) /* 0.383798623 */, 17 }, - - /* 3360 */ { MAD_F(0x0624a9c7) /* 0.383950977 */, 17 }, - /* 3361 */ { MAD_F(0x0625498d) /* 0.384103346 */, 17 }, - /* 3362 */ { MAD_F(0x0625e956) /* 0.384255730 */, 17 }, - /* 3363 */ { MAD_F(0x06268923) /* 0.384408129 */, 17 }, - /* 3364 */ { MAD_F(0x062728f5) /* 0.384560544 */, 17 }, - /* 3365 */ { MAD_F(0x0627c8ca) /* 0.384712973 */, 17 }, - /* 3366 */ { MAD_F(0x062868a4) /* 0.384865418 */, 17 }, - /* 3367 */ { MAD_F(0x06290881) /* 0.385017878 */, 17 }, - /* 3368 */ { MAD_F(0x0629a863) /* 0.385170352 */, 17 }, - /* 3369 */ { MAD_F(0x062a4849) /* 0.385322842 */, 17 }, - /* 3370 */ { MAD_F(0x062ae832) /* 0.385475347 */, 17 }, - /* 3371 */ { MAD_F(0x062b8820) /* 0.385627867 */, 17 }, - /* 3372 */ { MAD_F(0x062c2812) /* 0.385780402 */, 17 }, - /* 3373 */ { MAD_F(0x062cc808) /* 0.385932953 */, 17 }, - /* 3374 */ { MAD_F(0x062d6802) /* 0.386085518 */, 17 }, - /* 3375 */ { MAD_F(0x062e0800) /* 0.386238098 */, 17 }, - - /* 3376 */ { MAD_F(0x062ea802) /* 0.386390694 */, 17 }, - /* 3377 */ { MAD_F(0x062f4808) /* 0.386543304 */, 17 }, - /* 3378 */ { MAD_F(0x062fe812) /* 0.386695930 */, 17 }, - /* 3379 */ { MAD_F(0x06308820) /* 0.386848570 */, 17 }, - /* 3380 */ { MAD_F(0x06312832) /* 0.387001226 */, 17 }, - /* 3381 */ { MAD_F(0x0631c849) /* 0.387153897 */, 17 }, - /* 3382 */ { MAD_F(0x06326863) /* 0.387306582 */, 17 }, - /* 3383 */ { MAD_F(0x06330881) /* 0.387459283 */, 17 }, - /* 3384 */ { MAD_F(0x0633a8a3) /* 0.387611999 */, 17 }, - /* 3385 */ { MAD_F(0x063448ca) /* 0.387764730 */, 17 }, - /* 3386 */ { MAD_F(0x0634e8f4) /* 0.387917476 */, 17 }, - /* 3387 */ { MAD_F(0x06358923) /* 0.388070237 */, 17 }, - /* 3388 */ { MAD_F(0x06362955) /* 0.388223013 */, 17 }, - /* 3389 */ { MAD_F(0x0636c98c) /* 0.388375804 */, 17 }, - /* 3390 */ { MAD_F(0x063769c6) /* 0.388528610 */, 17 }, - /* 3391 */ { MAD_F(0x06380a05) /* 0.388681431 */, 17 }, - - /* 3392 */ { MAD_F(0x0638aa48) /* 0.388834268 */, 17 }, - /* 3393 */ { MAD_F(0x06394a8e) /* 0.388987119 */, 17 }, - /* 3394 */ { MAD_F(0x0639ead9) /* 0.389139985 */, 17 }, - /* 3395 */ { MAD_F(0x063a8b28) /* 0.389292866 */, 17 }, - /* 3396 */ { MAD_F(0x063b2b7b) /* 0.389445762 */, 17 }, - /* 3397 */ { MAD_F(0x063bcbd1) /* 0.389598674 */, 17 }, - /* 3398 */ { MAD_F(0x063c6c2c) /* 0.389751600 */, 17 }, - /* 3399 */ { MAD_F(0x063d0c8b) /* 0.389904541 */, 17 }, - /* 3400 */ { MAD_F(0x063dacee) /* 0.390057497 */, 17 }, - /* 3401 */ { MAD_F(0x063e4d55) /* 0.390210468 */, 17 }, - /* 3402 */ { MAD_F(0x063eedc0) /* 0.390363455 */, 17 }, - /* 3403 */ { MAD_F(0x063f8e2f) /* 0.390516456 */, 17 }, - /* 3404 */ { MAD_F(0x06402ea2) /* 0.390669472 */, 17 }, - /* 3405 */ { MAD_F(0x0640cf19) /* 0.390822503 */, 17 }, - /* 3406 */ { MAD_F(0x06416f94) /* 0.390975549 */, 17 }, - /* 3407 */ { MAD_F(0x06421013) /* 0.391128611 */, 17 }, - - /* 3408 */ { MAD_F(0x0642b096) /* 0.391281687 */, 17 }, - /* 3409 */ { MAD_F(0x0643511d) /* 0.391434778 */, 17 }, - /* 3410 */ { MAD_F(0x0643f1a8) /* 0.391587884 */, 17 }, - /* 3411 */ { MAD_F(0x06449237) /* 0.391741005 */, 17 }, - /* 3412 */ { MAD_F(0x064532ca) /* 0.391894141 */, 17 }, - /* 3413 */ { MAD_F(0x0645d361) /* 0.392047292 */, 17 }, - /* 3414 */ { MAD_F(0x064673fc) /* 0.392200458 */, 17 }, - /* 3415 */ { MAD_F(0x0647149c) /* 0.392353638 */, 17 }, - /* 3416 */ { MAD_F(0x0647b53f) /* 0.392506834 */, 17 }, - /* 3417 */ { MAD_F(0x064855e6) /* 0.392660045 */, 17 }, - /* 3418 */ { MAD_F(0x0648f691) /* 0.392813271 */, 17 }, - /* 3419 */ { MAD_F(0x06499740) /* 0.392966511 */, 17 }, - /* 3420 */ { MAD_F(0x064a37f4) /* 0.393119767 */, 17 }, - /* 3421 */ { MAD_F(0x064ad8ab) /* 0.393273038 */, 17 }, - /* 3422 */ { MAD_F(0x064b7966) /* 0.393426323 */, 17 }, - /* 3423 */ { MAD_F(0x064c1a25) /* 0.393579623 */, 17 }, - - /* 3424 */ { MAD_F(0x064cbae9) /* 0.393732939 */, 17 }, - /* 3425 */ { MAD_F(0x064d5bb0) /* 0.393886269 */, 17 }, - /* 3426 */ { MAD_F(0x064dfc7b) /* 0.394039614 */, 17 }, - /* 3427 */ { MAD_F(0x064e9d4b) /* 0.394192974 */, 17 }, - /* 3428 */ { MAD_F(0x064f3e1e) /* 0.394346349 */, 17 }, - /* 3429 */ { MAD_F(0x064fdef5) /* 0.394499739 */, 17 }, - /* 3430 */ { MAD_F(0x06507fd0) /* 0.394653144 */, 17 }, - /* 3431 */ { MAD_F(0x065120b0) /* 0.394806564 */, 17 }, - /* 3432 */ { MAD_F(0x0651c193) /* 0.394959999 */, 17 }, - /* 3433 */ { MAD_F(0x0652627a) /* 0.395113448 */, 17 }, - /* 3434 */ { MAD_F(0x06530366) /* 0.395266913 */, 17 }, - /* 3435 */ { MAD_F(0x0653a455) /* 0.395420392 */, 17 }, - /* 3436 */ { MAD_F(0x06544548) /* 0.395573886 */, 17 }, - /* 3437 */ { MAD_F(0x0654e640) /* 0.395727395 */, 17 }, - /* 3438 */ { MAD_F(0x0655873b) /* 0.395880919 */, 17 }, - /* 3439 */ { MAD_F(0x0656283a) /* 0.396034458 */, 17 }, - - /* 3440 */ { MAD_F(0x0656c93d) /* 0.396188012 */, 17 }, - /* 3441 */ { MAD_F(0x06576a45) /* 0.396341581 */, 17 }, - /* 3442 */ { MAD_F(0x06580b50) /* 0.396495164 */, 17 }, - /* 3443 */ { MAD_F(0x0658ac5f) /* 0.396648763 */, 17 }, - /* 3444 */ { MAD_F(0x06594d73) /* 0.396802376 */, 17 }, - /* 3445 */ { MAD_F(0x0659ee8a) /* 0.396956004 */, 17 }, - /* 3446 */ { MAD_F(0x065a8fa5) /* 0.397109647 */, 17 }, - /* 3447 */ { MAD_F(0x065b30c4) /* 0.397263305 */, 17 }, - /* 3448 */ { MAD_F(0x065bd1e7) /* 0.397416978 */, 17 }, - /* 3449 */ { MAD_F(0x065c730f) /* 0.397570666 */, 17 }, - /* 3450 */ { MAD_F(0x065d143a) /* 0.397724368 */, 17 }, - /* 3451 */ { MAD_F(0x065db569) /* 0.397878085 */, 17 }, - /* 3452 */ { MAD_F(0x065e569c) /* 0.398031818 */, 17 }, - /* 3453 */ { MAD_F(0x065ef7d3) /* 0.398185565 */, 17 }, - /* 3454 */ { MAD_F(0x065f990e) /* 0.398339326 */, 17 }, - /* 3455 */ { MAD_F(0x06603a4e) /* 0.398493103 */, 17 }, - - /* 3456 */ { MAD_F(0x0660db91) /* 0.398646895 */, 17 }, - /* 3457 */ { MAD_F(0x06617cd8) /* 0.398800701 */, 17 }, - /* 3458 */ { MAD_F(0x06621e23) /* 0.398954522 */, 17 }, - /* 3459 */ { MAD_F(0x0662bf72) /* 0.399108358 */, 17 }, - /* 3460 */ { MAD_F(0x066360c5) /* 0.399262209 */, 17 }, - /* 3461 */ { MAD_F(0x0664021c) /* 0.399416075 */, 17 }, - /* 3462 */ { MAD_F(0x0664a377) /* 0.399569955 */, 17 }, - /* 3463 */ { MAD_F(0x066544d6) /* 0.399723851 */, 17 }, - /* 3464 */ { MAD_F(0x0665e639) /* 0.399877761 */, 17 }, - /* 3465 */ { MAD_F(0x066687a0) /* 0.400031686 */, 17 }, - /* 3466 */ { MAD_F(0x0667290b) /* 0.400185625 */, 17 }, - /* 3467 */ { MAD_F(0x0667ca79) /* 0.400339580 */, 17 }, - /* 3468 */ { MAD_F(0x06686bec) /* 0.400493549 */, 17 }, - /* 3469 */ { MAD_F(0x06690d63) /* 0.400647534 */, 17 }, - /* 3470 */ { MAD_F(0x0669aede) /* 0.400801533 */, 17 }, - /* 3471 */ { MAD_F(0x066a505d) /* 0.400955546 */, 17 }, - - /* 3472 */ { MAD_F(0x066af1df) /* 0.401109575 */, 17 }, - /* 3473 */ { MAD_F(0x066b9366) /* 0.401263618 */, 17 }, - /* 3474 */ { MAD_F(0x066c34f1) /* 0.401417676 */, 17 }, - /* 3475 */ { MAD_F(0x066cd67f) /* 0.401571749 */, 17 }, - /* 3476 */ { MAD_F(0x066d7812) /* 0.401725837 */, 17 }, - /* 3477 */ { MAD_F(0x066e19a9) /* 0.401879939 */, 17 }, - /* 3478 */ { MAD_F(0x066ebb43) /* 0.402034056 */, 17 }, - /* 3479 */ { MAD_F(0x066f5ce2) /* 0.402188188 */, 17 }, - /* 3480 */ { MAD_F(0x066ffe84) /* 0.402342335 */, 17 }, - /* 3481 */ { MAD_F(0x0670a02a) /* 0.402496497 */, 17 }, - /* 3482 */ { MAD_F(0x067141d5) /* 0.402650673 */, 17 }, - /* 3483 */ { MAD_F(0x0671e383) /* 0.402804864 */, 17 }, - /* 3484 */ { MAD_F(0x06728535) /* 0.402959070 */, 17 }, - /* 3485 */ { MAD_F(0x067326ec) /* 0.403113291 */, 17 }, - /* 3486 */ { MAD_F(0x0673c8a6) /* 0.403267526 */, 17 }, - /* 3487 */ { MAD_F(0x06746a64) /* 0.403421776 */, 17 }, - - /* 3488 */ { MAD_F(0x06750c26) /* 0.403576041 */, 17 }, - /* 3489 */ { MAD_F(0x0675adec) /* 0.403730320 */, 17 }, - /* 3490 */ { MAD_F(0x06764fb6) /* 0.403884615 */, 17 }, - /* 3491 */ { MAD_F(0x0676f184) /* 0.404038924 */, 17 }, - /* 3492 */ { MAD_F(0x06779356) /* 0.404193247 */, 17 }, - /* 3493 */ { MAD_F(0x0678352c) /* 0.404347586 */, 17 }, - /* 3494 */ { MAD_F(0x0678d706) /* 0.404501939 */, 17 }, - /* 3495 */ { MAD_F(0x067978e4) /* 0.404656307 */, 17 }, - /* 3496 */ { MAD_F(0x067a1ac6) /* 0.404810690 */, 17 }, - /* 3497 */ { MAD_F(0x067abcac) /* 0.404965087 */, 17 }, - /* 3498 */ { MAD_F(0x067b5e95) /* 0.405119499 */, 17 }, - /* 3499 */ { MAD_F(0x067c0083) /* 0.405273926 */, 17 }, - /* 3500 */ { MAD_F(0x067ca275) /* 0.405428368 */, 17 }, - /* 3501 */ { MAD_F(0x067d446a) /* 0.405582824 */, 17 }, - /* 3502 */ { MAD_F(0x067de664) /* 0.405737295 */, 17 }, - /* 3503 */ { MAD_F(0x067e8861) /* 0.405891781 */, 17 }, - - /* 3504 */ { MAD_F(0x067f2a62) /* 0.406046281 */, 17 }, - /* 3505 */ { MAD_F(0x067fcc68) /* 0.406200796 */, 17 }, - /* 3506 */ { MAD_F(0x06806e71) /* 0.406355326 */, 17 }, - /* 3507 */ { MAD_F(0x0681107e) /* 0.406509870 */, 17 }, - /* 3508 */ { MAD_F(0x0681b28f) /* 0.406664429 */, 17 }, - /* 3509 */ { MAD_F(0x068254a4) /* 0.406819003 */, 17 }, - /* 3510 */ { MAD_F(0x0682f6bd) /* 0.406973592 */, 17 }, - /* 3511 */ { MAD_F(0x068398da) /* 0.407128195 */, 17 }, - /* 3512 */ { MAD_F(0x06843afb) /* 0.407282813 */, 17 }, - /* 3513 */ { MAD_F(0x0684dd20) /* 0.407437445 */, 17 }, - /* 3514 */ { MAD_F(0x06857f49) /* 0.407592093 */, 17 }, - /* 3515 */ { MAD_F(0x06862176) /* 0.407746754 */, 17 }, - /* 3516 */ { MAD_F(0x0686c3a6) /* 0.407901431 */, 17 }, - /* 3517 */ { MAD_F(0x068765db) /* 0.408056122 */, 17 }, - /* 3518 */ { MAD_F(0x06880814) /* 0.408210828 */, 17 }, - /* 3519 */ { MAD_F(0x0688aa50) /* 0.408365549 */, 17 }, - - /* 3520 */ { MAD_F(0x06894c90) /* 0.408520284 */, 17 }, - /* 3521 */ { MAD_F(0x0689eed5) /* 0.408675034 */, 17 }, - /* 3522 */ { MAD_F(0x068a911d) /* 0.408829798 */, 17 }, - /* 3523 */ { MAD_F(0x068b3369) /* 0.408984577 */, 17 }, - /* 3524 */ { MAD_F(0x068bd5b9) /* 0.409139371 */, 17 }, - /* 3525 */ { MAD_F(0x068c780e) /* 0.409294180 */, 17 }, - /* 3526 */ { MAD_F(0x068d1a66) /* 0.409449003 */, 17 }, - /* 3527 */ { MAD_F(0x068dbcc1) /* 0.409603840 */, 17 }, - /* 3528 */ { MAD_F(0x068e5f21) /* 0.409758693 */, 17 }, - /* 3529 */ { MAD_F(0x068f0185) /* 0.409913560 */, 17 }, - /* 3530 */ { MAD_F(0x068fa3ed) /* 0.410068441 */, 17 }, - /* 3531 */ { MAD_F(0x06904658) /* 0.410223338 */, 17 }, - /* 3532 */ { MAD_F(0x0690e8c8) /* 0.410378249 */, 17 }, - /* 3533 */ { MAD_F(0x06918b3c) /* 0.410533174 */, 17 }, - /* 3534 */ { MAD_F(0x06922db3) /* 0.410688114 */, 17 }, - /* 3535 */ { MAD_F(0x0692d02e) /* 0.410843069 */, 17 }, - - /* 3536 */ { MAD_F(0x069372ae) /* 0.410998038 */, 17 }, - /* 3537 */ { MAD_F(0x06941531) /* 0.411153022 */, 17 }, - /* 3538 */ { MAD_F(0x0694b7b8) /* 0.411308021 */, 17 }, - /* 3539 */ { MAD_F(0x06955a43) /* 0.411463034 */, 17 }, - /* 3540 */ { MAD_F(0x0695fcd2) /* 0.411618062 */, 17 }, - /* 3541 */ { MAD_F(0x06969f65) /* 0.411773104 */, 17 }, - /* 3542 */ { MAD_F(0x069741fb) /* 0.411928161 */, 17 }, - /* 3543 */ { MAD_F(0x0697e496) /* 0.412083232 */, 17 }, - /* 3544 */ { MAD_F(0x06988735) /* 0.412238319 */, 17 }, - /* 3545 */ { MAD_F(0x069929d7) /* 0.412393419 */, 17 }, - /* 3546 */ { MAD_F(0x0699cc7e) /* 0.412548535 */, 17 }, - /* 3547 */ { MAD_F(0x069a6f28) /* 0.412703664 */, 17 }, - /* 3548 */ { MAD_F(0x069b11d6) /* 0.412858809 */, 17 }, - /* 3549 */ { MAD_F(0x069bb489) /* 0.413013968 */, 17 }, - /* 3550 */ { MAD_F(0x069c573f) /* 0.413169142 */, 17 }, - /* 3551 */ { MAD_F(0x069cf9f9) /* 0.413324330 */, 17 }, - - /* 3552 */ { MAD_F(0x069d9cb7) /* 0.413479532 */, 17 }, - /* 3553 */ { MAD_F(0x069e3f78) /* 0.413634750 */, 17 }, - /* 3554 */ { MAD_F(0x069ee23e) /* 0.413789982 */, 17 }, - /* 3555 */ { MAD_F(0x069f8508) /* 0.413945228 */, 17 }, - /* 3556 */ { MAD_F(0x06a027d5) /* 0.414100489 */, 17 }, - /* 3557 */ { MAD_F(0x06a0caa7) /* 0.414255765 */, 17 }, - /* 3558 */ { MAD_F(0x06a16d7c) /* 0.414411055 */, 17 }, - /* 3559 */ { MAD_F(0x06a21055) /* 0.414566359 */, 17 }, - /* 3560 */ { MAD_F(0x06a2b333) /* 0.414721679 */, 17 }, - /* 3561 */ { MAD_F(0x06a35614) /* 0.414877012 */, 17 }, - /* 3562 */ { MAD_F(0x06a3f8f9) /* 0.415032361 */, 17 }, - /* 3563 */ { MAD_F(0x06a49be2) /* 0.415187723 */, 17 }, - /* 3564 */ { MAD_F(0x06a53ece) /* 0.415343101 */, 17 }, - /* 3565 */ { MAD_F(0x06a5e1bf) /* 0.415498493 */, 17 }, - /* 3566 */ { MAD_F(0x06a684b4) /* 0.415653899 */, 17 }, - /* 3567 */ { MAD_F(0x06a727ac) /* 0.415809320 */, 17 }, - - /* 3568 */ { MAD_F(0x06a7caa9) /* 0.415964756 */, 17 }, - /* 3569 */ { MAD_F(0x06a86da9) /* 0.416120206 */, 17 }, - /* 3570 */ { MAD_F(0x06a910ad) /* 0.416275670 */, 17 }, - /* 3571 */ { MAD_F(0x06a9b3b5) /* 0.416431149 */, 17 }, - /* 3572 */ { MAD_F(0x06aa56c1) /* 0.416586643 */, 17 }, - /* 3573 */ { MAD_F(0x06aaf9d1) /* 0.416742151 */, 17 }, - /* 3574 */ { MAD_F(0x06ab9ce5) /* 0.416897673 */, 17 }, - /* 3575 */ { MAD_F(0x06ac3ffc) /* 0.417053210 */, 17 }, - /* 3576 */ { MAD_F(0x06ace318) /* 0.417208762 */, 17 }, - /* 3577 */ { MAD_F(0x06ad8637) /* 0.417364328 */, 17 }, - /* 3578 */ { MAD_F(0x06ae295b) /* 0.417519909 */, 17 }, - /* 3579 */ { MAD_F(0x06aecc82) /* 0.417675504 */, 17 }, - /* 3580 */ { MAD_F(0x06af6fad) /* 0.417831113 */, 17 }, - /* 3581 */ { MAD_F(0x06b012dc) /* 0.417986737 */, 17 }, - /* 3582 */ { MAD_F(0x06b0b60f) /* 0.418142376 */, 17 }, - /* 3583 */ { MAD_F(0x06b15946) /* 0.418298029 */, 17 }, - - /* 3584 */ { MAD_F(0x06b1fc81) /* 0.418453696 */, 17 }, - /* 3585 */ { MAD_F(0x06b29fbf) /* 0.418609378 */, 17 }, - /* 3586 */ { MAD_F(0x06b34302) /* 0.418765075 */, 17 }, - /* 3587 */ { MAD_F(0x06b3e648) /* 0.418920786 */, 17 }, - /* 3588 */ { MAD_F(0x06b48992) /* 0.419076511 */, 17 }, - /* 3589 */ { MAD_F(0x06b52ce0) /* 0.419232251 */, 17 }, - /* 3590 */ { MAD_F(0x06b5d032) /* 0.419388005 */, 17 }, - /* 3591 */ { MAD_F(0x06b67388) /* 0.419543774 */, 17 }, - /* 3592 */ { MAD_F(0x06b716e2) /* 0.419699557 */, 17 }, - /* 3593 */ { MAD_F(0x06b7ba3f) /* 0.419855355 */, 17 }, - /* 3594 */ { MAD_F(0x06b85da1) /* 0.420011167 */, 17 }, - /* 3595 */ { MAD_F(0x06b90106) /* 0.420166994 */, 17 }, - /* 3596 */ { MAD_F(0x06b9a470) /* 0.420322835 */, 17 }, - /* 3597 */ { MAD_F(0x06ba47dd) /* 0.420478690 */, 17 }, - /* 3598 */ { MAD_F(0x06baeb4e) /* 0.420634560 */, 17 }, - /* 3599 */ { MAD_F(0x06bb8ec3) /* 0.420790445 */, 17 }, - - /* 3600 */ { MAD_F(0x06bc323b) /* 0.420946343 */, 17 }, - /* 3601 */ { MAD_F(0x06bcd5b8) /* 0.421102257 */, 17 }, - /* 3602 */ { MAD_F(0x06bd7939) /* 0.421258184 */, 17 }, - /* 3603 */ { MAD_F(0x06be1cbd) /* 0.421414127 */, 17 }, - /* 3604 */ { MAD_F(0x06bec045) /* 0.421570083 */, 17 }, - /* 3605 */ { MAD_F(0x06bf63d1) /* 0.421726054 */, 17 }, - /* 3606 */ { MAD_F(0x06c00761) /* 0.421882040 */, 17 }, - /* 3607 */ { MAD_F(0x06c0aaf5) /* 0.422038039 */, 17 }, - /* 3608 */ { MAD_F(0x06c14e8d) /* 0.422194054 */, 17 }, - /* 3609 */ { MAD_F(0x06c1f229) /* 0.422350082 */, 17 }, - /* 3610 */ { MAD_F(0x06c295c8) /* 0.422506125 */, 17 }, - /* 3611 */ { MAD_F(0x06c3396c) /* 0.422662183 */, 17 }, - /* 3612 */ { MAD_F(0x06c3dd13) /* 0.422818255 */, 17 }, - /* 3613 */ { MAD_F(0x06c480be) /* 0.422974341 */, 17 }, - /* 3614 */ { MAD_F(0x06c5246d) /* 0.423130442 */, 17 }, - /* 3615 */ { MAD_F(0x06c5c820) /* 0.423286557 */, 17 }, - - /* 3616 */ { MAD_F(0x06c66bd6) /* 0.423442686 */, 17 }, - /* 3617 */ { MAD_F(0x06c70f91) /* 0.423598830 */, 17 }, - /* 3618 */ { MAD_F(0x06c7b34f) /* 0.423754988 */, 17 }, - /* 3619 */ { MAD_F(0x06c85712) /* 0.423911161 */, 17 }, - /* 3620 */ { MAD_F(0x06c8fad8) /* 0.424067348 */, 17 }, - /* 3621 */ { MAD_F(0x06c99ea2) /* 0.424223550 */, 17 }, - /* 3622 */ { MAD_F(0x06ca4270) /* 0.424379765 */, 17 }, - /* 3623 */ { MAD_F(0x06cae641) /* 0.424535996 */, 17 }, - /* 3624 */ { MAD_F(0x06cb8a17) /* 0.424692240 */, 17 }, - /* 3625 */ { MAD_F(0x06cc2df0) /* 0.424848499 */, 17 }, - /* 3626 */ { MAD_F(0x06ccd1ce) /* 0.425004772 */, 17 }, - /* 3627 */ { MAD_F(0x06cd75af) /* 0.425161060 */, 17 }, - /* 3628 */ { MAD_F(0x06ce1994) /* 0.425317362 */, 17 }, - /* 3629 */ { MAD_F(0x06cebd7d) /* 0.425473678 */, 17 }, - /* 3630 */ { MAD_F(0x06cf6169) /* 0.425630009 */, 17 }, - /* 3631 */ { MAD_F(0x06d0055a) /* 0.425786354 */, 17 }, - - /* 3632 */ { MAD_F(0x06d0a94e) /* 0.425942714 */, 17 }, - /* 3633 */ { MAD_F(0x06d14d47) /* 0.426099088 */, 17 }, - /* 3634 */ { MAD_F(0x06d1f143) /* 0.426255476 */, 17 }, - /* 3635 */ { MAD_F(0x06d29543) /* 0.426411878 */, 17 }, - /* 3636 */ { MAD_F(0x06d33947) /* 0.426568295 */, 17 }, - /* 3637 */ { MAD_F(0x06d3dd4e) /* 0.426724726 */, 17 }, - /* 3638 */ { MAD_F(0x06d4815a) /* 0.426881172 */, 17 }, - /* 3639 */ { MAD_F(0x06d52569) /* 0.427037632 */, 17 }, - /* 3640 */ { MAD_F(0x06d5c97c) /* 0.427194106 */, 17 }, - /* 3641 */ { MAD_F(0x06d66d93) /* 0.427350594 */, 17 }, - /* 3642 */ { MAD_F(0x06d711ae) /* 0.427507097 */, 17 }, - /* 3643 */ { MAD_F(0x06d7b5cd) /* 0.427663614 */, 17 }, - /* 3644 */ { MAD_F(0x06d859f0) /* 0.427820146 */, 17 }, - /* 3645 */ { MAD_F(0x06d8fe16) /* 0.427976692 */, 17 }, - /* 3646 */ { MAD_F(0x06d9a240) /* 0.428133252 */, 17 }, - /* 3647 */ { MAD_F(0x06da466f) /* 0.428289826 */, 17 }, - - /* 3648 */ { MAD_F(0x06daeaa1) /* 0.428446415 */, 17 }, - /* 3649 */ { MAD_F(0x06db8ed6) /* 0.428603018 */, 17 }, - /* 3650 */ { MAD_F(0x06dc3310) /* 0.428759635 */, 17 }, - /* 3651 */ { MAD_F(0x06dcd74d) /* 0.428916267 */, 17 }, - /* 3652 */ { MAD_F(0x06dd7b8f) /* 0.429072913 */, 17 }, - /* 3653 */ { MAD_F(0x06de1fd4) /* 0.429229573 */, 17 }, - /* 3654 */ { MAD_F(0x06dec41d) /* 0.429386248 */, 17 }, - /* 3655 */ { MAD_F(0x06df686a) /* 0.429542937 */, 17 }, - /* 3656 */ { MAD_F(0x06e00cbb) /* 0.429699640 */, 17 }, - /* 3657 */ { MAD_F(0x06e0b10f) /* 0.429856357 */, 17 }, - /* 3658 */ { MAD_F(0x06e15567) /* 0.430013089 */, 17 }, - /* 3659 */ { MAD_F(0x06e1f9c4) /* 0.430169835 */, 17 }, - /* 3660 */ { MAD_F(0x06e29e24) /* 0.430326595 */, 17 }, - /* 3661 */ { MAD_F(0x06e34287) /* 0.430483370 */, 17 }, - /* 3662 */ { MAD_F(0x06e3e6ef) /* 0.430640159 */, 17 }, - /* 3663 */ { MAD_F(0x06e48b5b) /* 0.430796962 */, 17 }, - - /* 3664 */ { MAD_F(0x06e52fca) /* 0.430953779 */, 17 }, - /* 3665 */ { MAD_F(0x06e5d43d) /* 0.431110611 */, 17 }, - /* 3666 */ { MAD_F(0x06e678b4) /* 0.431267457 */, 17 }, - /* 3667 */ { MAD_F(0x06e71d2f) /* 0.431424317 */, 17 }, - /* 3668 */ { MAD_F(0x06e7c1ae) /* 0.431581192 */, 17 }, - /* 3669 */ { MAD_F(0x06e86630) /* 0.431738080 */, 17 }, - /* 3670 */ { MAD_F(0x06e90ab7) /* 0.431894983 */, 17 }, - /* 3671 */ { MAD_F(0x06e9af41) /* 0.432051900 */, 17 }, - /* 3672 */ { MAD_F(0x06ea53cf) /* 0.432208832 */, 17 }, - /* 3673 */ { MAD_F(0x06eaf860) /* 0.432365778 */, 17 }, - /* 3674 */ { MAD_F(0x06eb9cf6) /* 0.432522737 */, 17 }, - /* 3675 */ { MAD_F(0x06ec418f) /* 0.432679712 */, 17 }, - /* 3676 */ { MAD_F(0x06ece62d) /* 0.432836700 */, 17 }, - /* 3677 */ { MAD_F(0x06ed8ace) /* 0.432993703 */, 17 }, - /* 3678 */ { MAD_F(0x06ee2f73) /* 0.433150720 */, 17 }, - /* 3679 */ { MAD_F(0x06eed41b) /* 0.433307751 */, 17 }, - - /* 3680 */ { MAD_F(0x06ef78c8) /* 0.433464796 */, 17 }, - /* 3681 */ { MAD_F(0x06f01d78) /* 0.433621856 */, 17 }, - /* 3682 */ { MAD_F(0x06f0c22c) /* 0.433778929 */, 17 }, - /* 3683 */ { MAD_F(0x06f166e4) /* 0.433936017 */, 17 }, - /* 3684 */ { MAD_F(0x06f20ba0) /* 0.434093120 */, 17 }, - /* 3685 */ { MAD_F(0x06f2b060) /* 0.434250236 */, 17 }, - /* 3686 */ { MAD_F(0x06f35523) /* 0.434407367 */, 17 }, - /* 3687 */ { MAD_F(0x06f3f9eb) /* 0.434564512 */, 17 }, - /* 3688 */ { MAD_F(0x06f49eb6) /* 0.434721671 */, 17 }, - /* 3689 */ { MAD_F(0x06f54385) /* 0.434878844 */, 17 }, - /* 3690 */ { MAD_F(0x06f5e857) /* 0.435036032 */, 17 }, - /* 3691 */ { MAD_F(0x06f68d2e) /* 0.435193233 */, 17 }, - /* 3692 */ { MAD_F(0x06f73208) /* 0.435350449 */, 17 }, - /* 3693 */ { MAD_F(0x06f7d6e6) /* 0.435507679 */, 17 }, - /* 3694 */ { MAD_F(0x06f87bc8) /* 0.435664924 */, 17 }, - /* 3695 */ { MAD_F(0x06f920ae) /* 0.435822182 */, 17 }, - - /* 3696 */ { MAD_F(0x06f9c597) /* 0.435979455 */, 17 }, - /* 3697 */ { MAD_F(0x06fa6a85) /* 0.436136741 */, 17 }, - /* 3698 */ { MAD_F(0x06fb0f76) /* 0.436294042 */, 17 }, - /* 3699 */ { MAD_F(0x06fbb46b) /* 0.436451358 */, 17 }, - /* 3700 */ { MAD_F(0x06fc5964) /* 0.436608687 */, 17 }, - /* 3701 */ { MAD_F(0x06fcfe60) /* 0.436766031 */, 17 }, - /* 3702 */ { MAD_F(0x06fda361) /* 0.436923388 */, 17 }, - /* 3703 */ { MAD_F(0x06fe4865) /* 0.437080760 */, 17 }, - /* 3704 */ { MAD_F(0x06feed6d) /* 0.437238146 */, 17 }, - /* 3705 */ { MAD_F(0x06ff9279) /* 0.437395547 */, 17 }, - /* 3706 */ { MAD_F(0x07003788) /* 0.437552961 */, 17 }, - /* 3707 */ { MAD_F(0x0700dc9c) /* 0.437710389 */, 17 }, - /* 3708 */ { MAD_F(0x070181b3) /* 0.437867832 */, 17 }, - /* 3709 */ { MAD_F(0x070226ce) /* 0.438025289 */, 17 }, - /* 3710 */ { MAD_F(0x0702cbed) /* 0.438182760 */, 17 }, - /* 3711 */ { MAD_F(0x0703710f) /* 0.438340245 */, 17 }, - - /* 3712 */ { MAD_F(0x07041636) /* 0.438497744 */, 17 }, - /* 3713 */ { MAD_F(0x0704bb60) /* 0.438655258 */, 17 }, - /* 3714 */ { MAD_F(0x0705608e) /* 0.438812785 */, 17 }, - /* 3715 */ { MAD_F(0x070605c0) /* 0.438970327 */, 17 }, - /* 3716 */ { MAD_F(0x0706aaf5) /* 0.439127883 */, 17 }, - /* 3717 */ { MAD_F(0x0707502f) /* 0.439285453 */, 17 }, - /* 3718 */ { MAD_F(0x0707f56c) /* 0.439443037 */, 17 }, - /* 3719 */ { MAD_F(0x07089aad) /* 0.439600635 */, 17 }, - /* 3720 */ { MAD_F(0x07093ff2) /* 0.439758248 */, 17 }, - /* 3721 */ { MAD_F(0x0709e53a) /* 0.439915874 */, 17 }, - /* 3722 */ { MAD_F(0x070a8a86) /* 0.440073515 */, 17 }, - /* 3723 */ { MAD_F(0x070b2fd7) /* 0.440231170 */, 17 }, - /* 3724 */ { MAD_F(0x070bd52a) /* 0.440388839 */, 17 }, - /* 3725 */ { MAD_F(0x070c7a82) /* 0.440546522 */, 17 }, - /* 3726 */ { MAD_F(0x070d1fde) /* 0.440704219 */, 17 }, - /* 3727 */ { MAD_F(0x070dc53d) /* 0.440861930 */, 17 }, - - /* 3728 */ { MAD_F(0x070e6aa0) /* 0.441019655 */, 17 }, - /* 3729 */ { MAD_F(0x070f1007) /* 0.441177395 */, 17 }, - /* 3730 */ { MAD_F(0x070fb571) /* 0.441335148 */, 17 }, - /* 3731 */ { MAD_F(0x07105ae0) /* 0.441492916 */, 17 }, - /* 3732 */ { MAD_F(0x07110052) /* 0.441650697 */, 17 }, - /* 3733 */ { MAD_F(0x0711a5c8) /* 0.441808493 */, 17 }, - /* 3734 */ { MAD_F(0x07124b42) /* 0.441966303 */, 17 }, - /* 3735 */ { MAD_F(0x0712f0bf) /* 0.442124127 */, 17 }, - /* 3736 */ { MAD_F(0x07139641) /* 0.442281965 */, 17 }, - /* 3737 */ { MAD_F(0x07143bc6) /* 0.442439817 */, 17 }, - /* 3738 */ { MAD_F(0x0714e14f) /* 0.442597683 */, 17 }, - /* 3739 */ { MAD_F(0x071586db) /* 0.442755564 */, 17 }, - /* 3740 */ { MAD_F(0x07162c6c) /* 0.442913458 */, 17 }, - /* 3741 */ { MAD_F(0x0716d200) /* 0.443071366 */, 17 }, - /* 3742 */ { MAD_F(0x07177798) /* 0.443229289 */, 17 }, - /* 3743 */ { MAD_F(0x07181d34) /* 0.443387226 */, 17 }, - - /* 3744 */ { MAD_F(0x0718c2d3) /* 0.443545176 */, 17 }, - /* 3745 */ { MAD_F(0x07196877) /* 0.443703141 */, 17 }, - /* 3746 */ { MAD_F(0x071a0e1e) /* 0.443861120 */, 17 }, - /* 3747 */ { MAD_F(0x071ab3c9) /* 0.444019113 */, 17 }, - /* 3748 */ { MAD_F(0x071b5977) /* 0.444177119 */, 17 }, - /* 3749 */ { MAD_F(0x071bff2a) /* 0.444335140 */, 17 }, - /* 3750 */ { MAD_F(0x071ca4e0) /* 0.444493175 */, 17 }, - /* 3751 */ { MAD_F(0x071d4a9a) /* 0.444651224 */, 17 }, - /* 3752 */ { MAD_F(0x071df058) /* 0.444809288 */, 17 }, - /* 3753 */ { MAD_F(0x071e9619) /* 0.444967365 */, 17 }, - /* 3754 */ { MAD_F(0x071f3bde) /* 0.445125456 */, 17 }, - /* 3755 */ { MAD_F(0x071fe1a8) /* 0.445283561 */, 17 }, - /* 3756 */ { MAD_F(0x07208774) /* 0.445441680 */, 17 }, - /* 3757 */ { MAD_F(0x07212d45) /* 0.445599814 */, 17 }, - /* 3758 */ { MAD_F(0x0721d319) /* 0.445757961 */, 17 }, - /* 3759 */ { MAD_F(0x072278f1) /* 0.445916122 */, 17 }, - - /* 3760 */ { MAD_F(0x07231ecd) /* 0.446074298 */, 17 }, - /* 3761 */ { MAD_F(0x0723c4ad) /* 0.446232487 */, 17 }, - /* 3762 */ { MAD_F(0x07246a90) /* 0.446390690 */, 17 }, - /* 3763 */ { MAD_F(0x07251077) /* 0.446548908 */, 17 }, - /* 3764 */ { MAD_F(0x0725b662) /* 0.446707139 */, 17 }, - /* 3765 */ { MAD_F(0x07265c51) /* 0.446865385 */, 17 }, - /* 3766 */ { MAD_F(0x07270244) /* 0.447023644 */, 17 }, - /* 3767 */ { MAD_F(0x0727a83a) /* 0.447181918 */, 17 }, - /* 3768 */ { MAD_F(0x07284e34) /* 0.447340205 */, 17 }, - /* 3769 */ { MAD_F(0x0728f431) /* 0.447498507 */, 17 }, - /* 3770 */ { MAD_F(0x07299a33) /* 0.447656822 */, 17 }, - /* 3771 */ { MAD_F(0x072a4038) /* 0.447815152 */, 17 }, - /* 3772 */ { MAD_F(0x072ae641) /* 0.447973495 */, 17 }, - /* 3773 */ { MAD_F(0x072b8c4e) /* 0.448131853 */, 17 }, - /* 3774 */ { MAD_F(0x072c325e) /* 0.448290224 */, 17 }, - /* 3775 */ { MAD_F(0x072cd873) /* 0.448448609 */, 17 }, - - /* 3776 */ { MAD_F(0x072d7e8b) /* 0.448607009 */, 17 }, - /* 3777 */ { MAD_F(0x072e24a7) /* 0.448765422 */, 17 }, - /* 3778 */ { MAD_F(0x072ecac6) /* 0.448923850 */, 17 }, - /* 3779 */ { MAD_F(0x072f70e9) /* 0.449082291 */, 17 }, - /* 3780 */ { MAD_F(0x07301710) /* 0.449240746 */, 17 }, - /* 3781 */ { MAD_F(0x0730bd3b) /* 0.449399216 */, 17 }, - /* 3782 */ { MAD_F(0x0731636a) /* 0.449557699 */, 17 }, - /* 3783 */ { MAD_F(0x0732099c) /* 0.449716196 */, 17 }, - /* 3784 */ { MAD_F(0x0732afd2) /* 0.449874708 */, 17 }, - /* 3785 */ { MAD_F(0x0733560c) /* 0.450033233 */, 17 }, - /* 3786 */ { MAD_F(0x0733fc49) /* 0.450191772 */, 17 }, - /* 3787 */ { MAD_F(0x0734a28b) /* 0.450350325 */, 17 }, - /* 3788 */ { MAD_F(0x073548d0) /* 0.450508892 */, 17 }, - /* 3789 */ { MAD_F(0x0735ef18) /* 0.450667473 */, 17 }, - /* 3790 */ { MAD_F(0x07369565) /* 0.450826068 */, 17 }, - /* 3791 */ { MAD_F(0x07373bb5) /* 0.450984677 */, 17 }, - - /* 3792 */ { MAD_F(0x0737e209) /* 0.451143300 */, 17 }, - /* 3793 */ { MAD_F(0x07388861) /* 0.451301937 */, 17 }, - /* 3794 */ { MAD_F(0x07392ebc) /* 0.451460588 */, 17 }, - /* 3795 */ { MAD_F(0x0739d51c) /* 0.451619252 */, 17 }, - /* 3796 */ { MAD_F(0x073a7b7f) /* 0.451777931 */, 17 }, - /* 3797 */ { MAD_F(0x073b21e5) /* 0.451936623 */, 17 }, - /* 3798 */ { MAD_F(0x073bc850) /* 0.452095330 */, 17 }, - /* 3799 */ { MAD_F(0x073c6ebe) /* 0.452254050 */, 17 }, - /* 3800 */ { MAD_F(0x073d1530) /* 0.452412785 */, 17 }, - /* 3801 */ { MAD_F(0x073dbba6) /* 0.452571533 */, 17 }, - /* 3802 */ { MAD_F(0x073e621f) /* 0.452730295 */, 17 }, - /* 3803 */ { MAD_F(0x073f089c) /* 0.452889071 */, 17 }, - /* 3804 */ { MAD_F(0x073faf1d) /* 0.453047861 */, 17 }, - /* 3805 */ { MAD_F(0x074055a2) /* 0.453206665 */, 17 }, - /* 3806 */ { MAD_F(0x0740fc2a) /* 0.453365483 */, 17 }, - /* 3807 */ { MAD_F(0x0741a2b6) /* 0.453524315 */, 17 }, - - /* 3808 */ { MAD_F(0x07424946) /* 0.453683161 */, 17 }, - /* 3809 */ { MAD_F(0x0742efd9) /* 0.453842020 */, 17 }, - /* 3810 */ { MAD_F(0x07439671) /* 0.454000894 */, 17 }, - /* 3811 */ { MAD_F(0x07443d0c) /* 0.454159781 */, 17 }, - /* 3812 */ { MAD_F(0x0744e3aa) /* 0.454318683 */, 17 }, - /* 3813 */ { MAD_F(0x07458a4d) /* 0.454477598 */, 17 }, - /* 3814 */ { MAD_F(0x074630f3) /* 0.454636527 */, 17 }, - /* 3815 */ { MAD_F(0x0746d79d) /* 0.454795470 */, 17 }, - /* 3816 */ { MAD_F(0x07477e4b) /* 0.454954427 */, 17 }, - /* 3817 */ { MAD_F(0x074824fc) /* 0.455113397 */, 17 }, - /* 3818 */ { MAD_F(0x0748cbb1) /* 0.455272382 */, 17 }, - /* 3819 */ { MAD_F(0x0749726a) /* 0.455431381 */, 17 }, - /* 3820 */ { MAD_F(0x074a1927) /* 0.455590393 */, 17 }, - /* 3821 */ { MAD_F(0x074abfe7) /* 0.455749419 */, 17 }, - /* 3822 */ { MAD_F(0x074b66ab) /* 0.455908459 */, 17 }, - /* 3823 */ { MAD_F(0x074c0d73) /* 0.456067513 */, 17 }, - - /* 3824 */ { MAD_F(0x074cb43e) /* 0.456226581 */, 17 }, - /* 3825 */ { MAD_F(0x074d5b0d) /* 0.456385663 */, 17 }, - /* 3826 */ { MAD_F(0x074e01e0) /* 0.456544759 */, 17 }, - /* 3827 */ { MAD_F(0x074ea8b7) /* 0.456703868 */, 17 }, - /* 3828 */ { MAD_F(0x074f4f91) /* 0.456862992 */, 17 }, - /* 3829 */ { MAD_F(0x074ff66f) /* 0.457022129 */, 17 }, - /* 3830 */ { MAD_F(0x07509d51) /* 0.457181280 */, 17 }, - /* 3831 */ { MAD_F(0x07514437) /* 0.457340445 */, 17 }, - /* 3832 */ { MAD_F(0x0751eb20) /* 0.457499623 */, 17 }, - /* 3833 */ { MAD_F(0x0752920d) /* 0.457658816 */, 17 }, - /* 3834 */ { MAD_F(0x075338fd) /* 0.457818022 */, 17 }, - /* 3835 */ { MAD_F(0x0753dff2) /* 0.457977243 */, 17 }, - /* 3836 */ { MAD_F(0x075486ea) /* 0.458136477 */, 17 }, - /* 3837 */ { MAD_F(0x07552de6) /* 0.458295725 */, 17 }, - /* 3838 */ { MAD_F(0x0755d4e5) /* 0.458454987 */, 17 }, - /* 3839 */ { MAD_F(0x07567be8) /* 0.458614262 */, 17 }, - - /* 3840 */ { MAD_F(0x075722ef) /* 0.458773552 */, 17 }, - /* 3841 */ { MAD_F(0x0757c9fa) /* 0.458932855 */, 17 }, - /* 3842 */ { MAD_F(0x07587108) /* 0.459092172 */, 17 }, - /* 3843 */ { MAD_F(0x0759181a) /* 0.459251503 */, 17 }, - /* 3844 */ { MAD_F(0x0759bf30) /* 0.459410848 */, 17 }, - /* 3845 */ { MAD_F(0x075a664a) /* 0.459570206 */, 17 }, - /* 3846 */ { MAD_F(0x075b0d67) /* 0.459729579 */, 17 }, - /* 3847 */ { MAD_F(0x075bb488) /* 0.459888965 */, 17 }, - /* 3848 */ { MAD_F(0x075c5bac) /* 0.460048365 */, 17 }, - /* 3849 */ { MAD_F(0x075d02d5) /* 0.460207779 */, 17 }, - /* 3850 */ { MAD_F(0x075daa01) /* 0.460367206 */, 17 }, - /* 3851 */ { MAD_F(0x075e5130) /* 0.460526648 */, 17 }, - /* 3852 */ { MAD_F(0x075ef864) /* 0.460686103 */, 17 }, - /* 3853 */ { MAD_F(0x075f9f9b) /* 0.460845572 */, 17 }, - /* 3854 */ { MAD_F(0x076046d6) /* 0.461005055 */, 17 }, - /* 3855 */ { MAD_F(0x0760ee14) /* 0.461164552 */, 17 }, - - /* 3856 */ { MAD_F(0x07619557) /* 0.461324062 */, 17 }, - /* 3857 */ { MAD_F(0x07623c9d) /* 0.461483586 */, 17 }, - /* 3858 */ { MAD_F(0x0762e3e6) /* 0.461643124 */, 17 }, - /* 3859 */ { MAD_F(0x07638b34) /* 0.461802676 */, 17 }, - /* 3860 */ { MAD_F(0x07643285) /* 0.461962242 */, 17 }, - /* 3861 */ { MAD_F(0x0764d9d9) /* 0.462121821 */, 17 }, - /* 3862 */ { MAD_F(0x07658132) /* 0.462281414 */, 17 }, - /* 3863 */ { MAD_F(0x0766288e) /* 0.462441021 */, 17 }, - /* 3864 */ { MAD_F(0x0766cfee) /* 0.462600642 */, 17 }, - /* 3865 */ { MAD_F(0x07677751) /* 0.462760276 */, 17 }, - /* 3866 */ { MAD_F(0x07681eb9) /* 0.462919924 */, 17 }, - /* 3867 */ { MAD_F(0x0768c624) /* 0.463079586 */, 17 }, - /* 3868 */ { MAD_F(0x07696d92) /* 0.463239262 */, 17 }, - /* 3869 */ { MAD_F(0x076a1505) /* 0.463398951 */, 17 }, - /* 3870 */ { MAD_F(0x076abc7b) /* 0.463558655 */, 17 }, - /* 3871 */ { MAD_F(0x076b63f4) /* 0.463718372 */, 17 }, - - /* 3872 */ { MAD_F(0x076c0b72) /* 0.463878102 */, 17 }, - /* 3873 */ { MAD_F(0x076cb2f3) /* 0.464037847 */, 17 }, - /* 3874 */ { MAD_F(0x076d5a78) /* 0.464197605 */, 17 }, - /* 3875 */ { MAD_F(0x076e0200) /* 0.464357377 */, 17 }, - /* 3876 */ { MAD_F(0x076ea98c) /* 0.464517163 */, 17 }, - /* 3877 */ { MAD_F(0x076f511c) /* 0.464676962 */, 17 }, - /* 3878 */ { MAD_F(0x076ff8b0) /* 0.464836776 */, 17 }, - /* 3879 */ { MAD_F(0x0770a047) /* 0.464996603 */, 17 }, - /* 3880 */ { MAD_F(0x077147e2) /* 0.465156443 */, 17 }, - /* 3881 */ { MAD_F(0x0771ef80) /* 0.465316298 */, 17 }, - /* 3882 */ { MAD_F(0x07729723) /* 0.465476166 */, 17 }, - /* 3883 */ { MAD_F(0x07733ec9) /* 0.465636048 */, 17 }, - /* 3884 */ { MAD_F(0x0773e672) /* 0.465795943 */, 17 }, - /* 3885 */ { MAD_F(0x07748e20) /* 0.465955853 */, 17 }, - /* 3886 */ { MAD_F(0x077535d1) /* 0.466115776 */, 17 }, - /* 3887 */ { MAD_F(0x0775dd85) /* 0.466275713 */, 17 }, - - /* 3888 */ { MAD_F(0x0776853e) /* 0.466435663 */, 17 }, - /* 3889 */ { MAD_F(0x07772cfa) /* 0.466595627 */, 17 }, - /* 3890 */ { MAD_F(0x0777d4ba) /* 0.466755605 */, 17 }, - /* 3891 */ { MAD_F(0x07787c7d) /* 0.466915597 */, 17 }, - /* 3892 */ { MAD_F(0x07792444) /* 0.467075602 */, 17 }, - /* 3893 */ { MAD_F(0x0779cc0f) /* 0.467235621 */, 17 }, - /* 3894 */ { MAD_F(0x077a73dd) /* 0.467395654 */, 17 }, - /* 3895 */ { MAD_F(0x077b1baf) /* 0.467555701 */, 17 }, - /* 3896 */ { MAD_F(0x077bc385) /* 0.467715761 */, 17 }, - /* 3897 */ { MAD_F(0x077c6b5f) /* 0.467875835 */, 17 }, - /* 3898 */ { MAD_F(0x077d133c) /* 0.468035922 */, 17 }, - /* 3899 */ { MAD_F(0x077dbb1d) /* 0.468196023 */, 17 }, - /* 3900 */ { MAD_F(0x077e6301) /* 0.468356138 */, 17 }, - /* 3901 */ { MAD_F(0x077f0ae9) /* 0.468516267 */, 17 }, - /* 3902 */ { MAD_F(0x077fb2d5) /* 0.468676409 */, 17 }, - /* 3903 */ { MAD_F(0x07805ac5) /* 0.468836565 */, 17 }, - - /* 3904 */ { MAD_F(0x078102b8) /* 0.468996735 */, 17 }, - /* 3905 */ { MAD_F(0x0781aaaf) /* 0.469156918 */, 17 }, - /* 3906 */ { MAD_F(0x078252aa) /* 0.469317115 */, 17 }, - /* 3907 */ { MAD_F(0x0782faa8) /* 0.469477326 */, 17 }, - /* 3908 */ { MAD_F(0x0783a2aa) /* 0.469637550 */, 17 }, - /* 3909 */ { MAD_F(0x07844aaf) /* 0.469797788 */, 17 }, - /* 3910 */ { MAD_F(0x0784f2b8) /* 0.469958040 */, 17 }, - /* 3911 */ { MAD_F(0x07859ac5) /* 0.470118305 */, 17 }, - /* 3912 */ { MAD_F(0x078642d6) /* 0.470278584 */, 17 }, - /* 3913 */ { MAD_F(0x0786eaea) /* 0.470438877 */, 17 }, - /* 3914 */ { MAD_F(0x07879302) /* 0.470599183 */, 17 }, - /* 3915 */ { MAD_F(0x07883b1e) /* 0.470759503 */, 17 }, - /* 3916 */ { MAD_F(0x0788e33d) /* 0.470919836 */, 17 }, - /* 3917 */ { MAD_F(0x07898b60) /* 0.471080184 */, 17 }, - /* 3918 */ { MAD_F(0x078a3386) /* 0.471240545 */, 17 }, - /* 3919 */ { MAD_F(0x078adbb0) /* 0.471400919 */, 17 }, - - /* 3920 */ { MAD_F(0x078b83de) /* 0.471561307 */, 17 }, - /* 3921 */ { MAD_F(0x078c2c10) /* 0.471721709 */, 17 }, - /* 3922 */ { MAD_F(0x078cd445) /* 0.471882125 */, 17 }, - /* 3923 */ { MAD_F(0x078d7c7e) /* 0.472042554 */, 17 }, - /* 3924 */ { MAD_F(0x078e24ba) /* 0.472202996 */, 17 }, - /* 3925 */ { MAD_F(0x078eccfb) /* 0.472363453 */, 17 }, - /* 3926 */ { MAD_F(0x078f753e) /* 0.472523923 */, 17 }, - /* 3927 */ { MAD_F(0x07901d86) /* 0.472684406 */, 17 }, - /* 3928 */ { MAD_F(0x0790c5d1) /* 0.472844904 */, 17 }, - /* 3929 */ { MAD_F(0x07916e20) /* 0.473005414 */, 17 }, - /* 3930 */ { MAD_F(0x07921672) /* 0.473165939 */, 17 }, - /* 3931 */ { MAD_F(0x0792bec8) /* 0.473326477 */, 17 }, - /* 3932 */ { MAD_F(0x07936722) /* 0.473487029 */, 17 }, - /* 3933 */ { MAD_F(0x07940f80) /* 0.473647594 */, 17 }, - /* 3934 */ { MAD_F(0x0794b7e1) /* 0.473808173 */, 17 }, - /* 3935 */ { MAD_F(0x07956045) /* 0.473968765 */, 17 }, - - /* 3936 */ { MAD_F(0x079608ae) /* 0.474129372 */, 17 }, - /* 3937 */ { MAD_F(0x0796b11a) /* 0.474289991 */, 17 }, - /* 3938 */ { MAD_F(0x0797598a) /* 0.474450625 */, 17 }, - /* 3939 */ { MAD_F(0x079801fd) /* 0.474611272 */, 17 }, - /* 3940 */ { MAD_F(0x0798aa74) /* 0.474771932 */, 17 }, - /* 3941 */ { MAD_F(0x079952ee) /* 0.474932606 */, 17 }, - /* 3942 */ { MAD_F(0x0799fb6d) /* 0.475093294 */, 17 }, - /* 3943 */ { MAD_F(0x079aa3ef) /* 0.475253995 */, 17 }, - /* 3944 */ { MAD_F(0x079b4c74) /* 0.475414710 */, 17 }, - /* 3945 */ { MAD_F(0x079bf4fd) /* 0.475575439 */, 17 }, - /* 3946 */ { MAD_F(0x079c9d8a) /* 0.475736181 */, 17 }, - /* 3947 */ { MAD_F(0x079d461b) /* 0.475896936 */, 17 }, - /* 3948 */ { MAD_F(0x079deeaf) /* 0.476057705 */, 17 }, - /* 3949 */ { MAD_F(0x079e9747) /* 0.476218488 */, 17 }, - /* 3950 */ { MAD_F(0x079f3fe2) /* 0.476379285 */, 17 }, - /* 3951 */ { MAD_F(0x079fe881) /* 0.476540095 */, 17 }, - - /* 3952 */ { MAD_F(0x07a09124) /* 0.476700918 */, 17 }, - /* 3953 */ { MAD_F(0x07a139ca) /* 0.476861755 */, 17 }, - /* 3954 */ { MAD_F(0x07a1e274) /* 0.477022606 */, 17 }, - /* 3955 */ { MAD_F(0x07a28b22) /* 0.477183470 */, 17 }, - /* 3956 */ { MAD_F(0x07a333d3) /* 0.477344348 */, 17 }, - /* 3957 */ { MAD_F(0x07a3dc88) /* 0.477505239 */, 17 }, - /* 3958 */ { MAD_F(0x07a48541) /* 0.477666144 */, 17 }, - /* 3959 */ { MAD_F(0x07a52dfd) /* 0.477827062 */, 17 }, - /* 3960 */ { MAD_F(0x07a5d6bd) /* 0.477987994 */, 17 }, - /* 3961 */ { MAD_F(0x07a67f80) /* 0.478148940 */, 17 }, - /* 3962 */ { MAD_F(0x07a72847) /* 0.478309899 */, 17 }, - /* 3963 */ { MAD_F(0x07a7d112) /* 0.478470871 */, 17 }, - /* 3964 */ { MAD_F(0x07a879e1) /* 0.478631857 */, 17 }, - /* 3965 */ { MAD_F(0x07a922b3) /* 0.478792857 */, 17 }, - /* 3966 */ { MAD_F(0x07a9cb88) /* 0.478953870 */, 17 }, - /* 3967 */ { MAD_F(0x07aa7462) /* 0.479114897 */, 17 }, - - /* 3968 */ { MAD_F(0x07ab1d3e) /* 0.479275937 */, 17 }, - /* 3969 */ { MAD_F(0x07abc61f) /* 0.479436991 */, 17 }, - /* 3970 */ { MAD_F(0x07ac6f03) /* 0.479598058 */, 17 }, - /* 3971 */ { MAD_F(0x07ad17eb) /* 0.479759139 */, 17 }, - /* 3972 */ { MAD_F(0x07adc0d6) /* 0.479920233 */, 17 }, - /* 3973 */ { MAD_F(0x07ae69c6) /* 0.480081341 */, 17 }, - /* 3974 */ { MAD_F(0x07af12b8) /* 0.480242463 */, 17 }, - /* 3975 */ { MAD_F(0x07afbbaf) /* 0.480403598 */, 17 }, - /* 3976 */ { MAD_F(0x07b064a8) /* 0.480564746 */, 17 }, - /* 3977 */ { MAD_F(0x07b10da6) /* 0.480725908 */, 17 }, - /* 3978 */ { MAD_F(0x07b1b6a7) /* 0.480887083 */, 17 }, - /* 3979 */ { MAD_F(0x07b25fac) /* 0.481048272 */, 17 }, - /* 3980 */ { MAD_F(0x07b308b5) /* 0.481209475 */, 17 }, - /* 3981 */ { MAD_F(0x07b3b1c1) /* 0.481370691 */, 17 }, - /* 3982 */ { MAD_F(0x07b45ad0) /* 0.481531920 */, 17 }, - /* 3983 */ { MAD_F(0x07b503e4) /* 0.481693163 */, 17 }, - - /* 3984 */ { MAD_F(0x07b5acfb) /* 0.481854420 */, 17 }, - /* 3985 */ { MAD_F(0x07b65615) /* 0.482015690 */, 17 }, - /* 3986 */ { MAD_F(0x07b6ff33) /* 0.482176973 */, 17 }, - /* 3987 */ { MAD_F(0x07b7a855) /* 0.482338270 */, 17 }, - /* 3988 */ { MAD_F(0x07b8517b) /* 0.482499580 */, 17 }, - /* 3989 */ { MAD_F(0x07b8faa4) /* 0.482660904 */, 17 }, - /* 3990 */ { MAD_F(0x07b9a3d0) /* 0.482822242 */, 17 }, - /* 3991 */ { MAD_F(0x07ba4d01) /* 0.482983592 */, 17 }, - /* 3992 */ { MAD_F(0x07baf635) /* 0.483144957 */, 17 }, - /* 3993 */ { MAD_F(0x07bb9f6c) /* 0.483306335 */, 17 }, - /* 3994 */ { MAD_F(0x07bc48a7) /* 0.483467726 */, 17 }, - /* 3995 */ { MAD_F(0x07bcf1e6) /* 0.483629131 */, 17 }, - /* 3996 */ { MAD_F(0x07bd9b28) /* 0.483790549 */, 17 }, - /* 3997 */ { MAD_F(0x07be446e) /* 0.483951980 */, 17 }, - /* 3998 */ { MAD_F(0x07beedb8) /* 0.484113426 */, 17 }, - /* 3999 */ { MAD_F(0x07bf9705) /* 0.484274884 */, 17 }, - - /* 4000 */ { MAD_F(0x07c04056) /* 0.484436356 */, 17 }, - /* 4001 */ { MAD_F(0x07c0e9aa) /* 0.484597842 */, 17 }, - /* 4002 */ { MAD_F(0x07c19302) /* 0.484759341 */, 17 }, - /* 4003 */ { MAD_F(0x07c23c5e) /* 0.484920853 */, 17 }, - /* 4004 */ { MAD_F(0x07c2e5bd) /* 0.485082379 */, 17 }, - /* 4005 */ { MAD_F(0x07c38f20) /* 0.485243918 */, 17 }, - /* 4006 */ { MAD_F(0x07c43887) /* 0.485405471 */, 17 }, - /* 4007 */ { MAD_F(0x07c4e1f1) /* 0.485567037 */, 17 }, - /* 4008 */ { MAD_F(0x07c58b5f) /* 0.485728617 */, 17 }, - /* 4009 */ { MAD_F(0x07c634d0) /* 0.485890210 */, 17 }, - /* 4010 */ { MAD_F(0x07c6de45) /* 0.486051817 */, 17 }, - /* 4011 */ { MAD_F(0x07c787bd) /* 0.486213436 */, 17 }, - /* 4012 */ { MAD_F(0x07c83139) /* 0.486375070 */, 17 }, - /* 4013 */ { MAD_F(0x07c8dab9) /* 0.486536717 */, 17 }, - /* 4014 */ { MAD_F(0x07c9843c) /* 0.486698377 */, 17 }, - /* 4015 */ { MAD_F(0x07ca2dc3) /* 0.486860051 */, 17 }, - - /* 4016 */ { MAD_F(0x07cad74e) /* 0.487021738 */, 17 }, - /* 4017 */ { MAD_F(0x07cb80dc) /* 0.487183438 */, 17 }, - /* 4018 */ { MAD_F(0x07cc2a6e) /* 0.487345152 */, 17 }, - /* 4019 */ { MAD_F(0x07ccd403) /* 0.487506879 */, 17 }, - /* 4020 */ { MAD_F(0x07cd7d9c) /* 0.487668620 */, 17 }, - /* 4021 */ { MAD_F(0x07ce2739) /* 0.487830374 */, 17 }, - /* 4022 */ { MAD_F(0x07ced0d9) /* 0.487992142 */, 17 }, - /* 4023 */ { MAD_F(0x07cf7a7d) /* 0.488153923 */, 17 }, - /* 4024 */ { MAD_F(0x07d02424) /* 0.488315717 */, 17 }, - /* 4025 */ { MAD_F(0x07d0cdcf) /* 0.488477525 */, 17 }, - /* 4026 */ { MAD_F(0x07d1777e) /* 0.488639346 */, 17 }, - /* 4027 */ { MAD_F(0x07d22130) /* 0.488801181 */, 17 }, - /* 4028 */ { MAD_F(0x07d2cae5) /* 0.488963029 */, 17 }, - /* 4029 */ { MAD_F(0x07d3749f) /* 0.489124890 */, 17 }, - /* 4030 */ { MAD_F(0x07d41e5c) /* 0.489286765 */, 17 }, - /* 4031 */ { MAD_F(0x07d4c81c) /* 0.489448653 */, 17 }, - - /* 4032 */ { MAD_F(0x07d571e0) /* 0.489610555 */, 17 }, - /* 4033 */ { MAD_F(0x07d61ba8) /* 0.489772470 */, 17 }, - /* 4034 */ { MAD_F(0x07d6c573) /* 0.489934398 */, 17 }, - /* 4035 */ { MAD_F(0x07d76f42) /* 0.490096340 */, 17 }, - /* 4036 */ { MAD_F(0x07d81915) /* 0.490258295 */, 17 }, - /* 4037 */ { MAD_F(0x07d8c2eb) /* 0.490420263 */, 17 }, - /* 4038 */ { MAD_F(0x07d96cc4) /* 0.490582245 */, 17 }, - /* 4039 */ { MAD_F(0x07da16a2) /* 0.490744240 */, 17 }, - /* 4040 */ { MAD_F(0x07dac083) /* 0.490906249 */, 17 }, - /* 4041 */ { MAD_F(0x07db6a67) /* 0.491068271 */, 17 }, - /* 4042 */ { MAD_F(0x07dc144f) /* 0.491230306 */, 17 }, - /* 4043 */ { MAD_F(0x07dcbe3b) /* 0.491392355 */, 17 }, - /* 4044 */ { MAD_F(0x07dd682a) /* 0.491554417 */, 17 }, - /* 4045 */ { MAD_F(0x07de121d) /* 0.491716492 */, 17 }, - /* 4046 */ { MAD_F(0x07debc13) /* 0.491878581 */, 17 }, - /* 4047 */ { MAD_F(0x07df660d) /* 0.492040683 */, 17 }, - - /* 4048 */ { MAD_F(0x07e0100a) /* 0.492202799 */, 17 }, - /* 4049 */ { MAD_F(0x07e0ba0c) /* 0.492364928 */, 17 }, - /* 4050 */ { MAD_F(0x07e16410) /* 0.492527070 */, 17 }, - /* 4051 */ { MAD_F(0x07e20e19) /* 0.492689225 */, 17 }, - /* 4052 */ { MAD_F(0x07e2b824) /* 0.492851394 */, 17 }, - /* 4053 */ { MAD_F(0x07e36234) /* 0.493013576 */, 17 }, - /* 4054 */ { MAD_F(0x07e40c47) /* 0.493175772 */, 17 }, - /* 4055 */ { MAD_F(0x07e4b65e) /* 0.493337981 */, 17 }, - /* 4056 */ { MAD_F(0x07e56078) /* 0.493500203 */, 17 }, - /* 4057 */ { MAD_F(0x07e60a95) /* 0.493662438 */, 17 }, - /* 4058 */ { MAD_F(0x07e6b4b7) /* 0.493824687 */, 17 }, - /* 4059 */ { MAD_F(0x07e75edc) /* 0.493986949 */, 17 }, - /* 4060 */ { MAD_F(0x07e80904) /* 0.494149225 */, 17 }, - /* 4061 */ { MAD_F(0x07e8b330) /* 0.494311514 */, 17 }, - /* 4062 */ { MAD_F(0x07e95d60) /* 0.494473816 */, 17 }, - /* 4063 */ { MAD_F(0x07ea0793) /* 0.494636131 */, 17 }, - - /* 4064 */ { MAD_F(0x07eab1ca) /* 0.494798460 */, 17 }, - /* 4065 */ { MAD_F(0x07eb5c04) /* 0.494960802 */, 17 }, - /* 4066 */ { MAD_F(0x07ec0642) /* 0.495123158 */, 17 }, - /* 4067 */ { MAD_F(0x07ecb084) /* 0.495285526 */, 17 }, - /* 4068 */ { MAD_F(0x07ed5ac9) /* 0.495447908 */, 17 }, - /* 4069 */ { MAD_F(0x07ee0512) /* 0.495610304 */, 17 }, - /* 4070 */ { MAD_F(0x07eeaf5e) /* 0.495772712 */, 17 }, - /* 4071 */ { MAD_F(0x07ef59ae) /* 0.495935134 */, 17 }, - /* 4072 */ { MAD_F(0x07f00401) /* 0.496097570 */, 17 }, - /* 4073 */ { MAD_F(0x07f0ae58) /* 0.496260018 */, 17 }, - /* 4074 */ { MAD_F(0x07f158b3) /* 0.496422480 */, 17 }, - /* 4075 */ { MAD_F(0x07f20311) /* 0.496584955 */, 17 }, - /* 4076 */ { MAD_F(0x07f2ad72) /* 0.496747444 */, 17 }, - /* 4077 */ { MAD_F(0x07f357d8) /* 0.496909945 */, 17 }, - /* 4078 */ { MAD_F(0x07f40240) /* 0.497072460 */, 17 }, - /* 4079 */ { MAD_F(0x07f4acad) /* 0.497234989 */, 17 }, - - /* 4080 */ { MAD_F(0x07f5571d) /* 0.497397530 */, 17 }, - /* 4081 */ { MAD_F(0x07f60190) /* 0.497560085 */, 17 }, - /* 4082 */ { MAD_F(0x07f6ac07) /* 0.497722653 */, 17 }, - /* 4083 */ { MAD_F(0x07f75682) /* 0.497885235 */, 17 }, - /* 4084 */ { MAD_F(0x07f80100) /* 0.498047829 */, 17 }, - /* 4085 */ { MAD_F(0x07f8ab82) /* 0.498210437 */, 17 }, - /* 4086 */ { MAD_F(0x07f95607) /* 0.498373058 */, 17 }, - /* 4087 */ { MAD_F(0x07fa0090) /* 0.498535693 */, 17 }, - /* 4088 */ { MAD_F(0x07faab1c) /* 0.498698341 */, 17 }, - /* 4089 */ { MAD_F(0x07fb55ac) /* 0.498861002 */, 17 }, - /* 4090 */ { MAD_F(0x07fc0040) /* 0.499023676 */, 17 }, - /* 4091 */ { MAD_F(0x07fcaad7) /* 0.499186364 */, 17 }, - /* 4092 */ { MAD_F(0x07fd5572) /* 0.499349064 */, 17 }, - /* 4093 */ { MAD_F(0x07fe0010) /* 0.499511778 */, 17 }, - /* 4094 */ { MAD_F(0x07feaab2) /* 0.499674506 */, 17 }, - /* 4095 */ { MAD_F(0x07ff5557) /* 0.499837246 */, 17 }, - - /* 4096 */ { MAD_F(0x04000000) /* 0.250000000 */, 18 }, - /* 4097 */ { MAD_F(0x04005556) /* 0.250081384 */, 18 }, - /* 4098 */ { MAD_F(0x0400aaae) /* 0.250162774 */, 18 }, - /* 4099 */ { MAD_F(0x04010008) /* 0.250244170 */, 18 }, - /* 4100 */ { MAD_F(0x04015563) /* 0.250325574 */, 18 }, - /* 4101 */ { MAD_F(0x0401aac1) /* 0.250406984 */, 18 }, - /* 4102 */ { MAD_F(0x04020020) /* 0.250488400 */, 18 }, - /* 4103 */ { MAD_F(0x04025581) /* 0.250569824 */, 18 }, - /* 4104 */ { MAD_F(0x0402aae3) /* 0.250651254 */, 18 }, - /* 4105 */ { MAD_F(0x04030048) /* 0.250732690 */, 18 }, - /* 4106 */ { MAD_F(0x040355ae) /* 0.250814133 */, 18 }, - /* 4107 */ { MAD_F(0x0403ab16) /* 0.250895583 */, 18 }, - /* 4108 */ { MAD_F(0x04040080) /* 0.250977039 */, 18 }, - /* 4109 */ { MAD_F(0x040455eb) /* 0.251058502 */, 18 }, - /* 4110 */ { MAD_F(0x0404ab59) /* 0.251139971 */, 18 }, - /* 4111 */ { MAD_F(0x040500c8) /* 0.251221448 */, 18 }, - - /* 4112 */ { MAD_F(0x04055638) /* 0.251302930 */, 18 }, - /* 4113 */ { MAD_F(0x0405abab) /* 0.251384420 */, 18 }, - /* 4114 */ { MAD_F(0x0406011f) /* 0.251465916 */, 18 }, - /* 4115 */ { MAD_F(0x04065696) /* 0.251547418 */, 18 }, - /* 4116 */ { MAD_F(0x0406ac0e) /* 0.251628927 */, 18 }, - /* 4117 */ { MAD_F(0x04070187) /* 0.251710443 */, 18 }, - /* 4118 */ { MAD_F(0x04075703) /* 0.251791965 */, 18 }, - /* 4119 */ { MAD_F(0x0407ac80) /* 0.251873494 */, 18 }, - /* 4120 */ { MAD_F(0x040801ff) /* 0.251955030 */, 18 }, - /* 4121 */ { MAD_F(0x04085780) /* 0.252036572 */, 18 }, - /* 4122 */ { MAD_F(0x0408ad02) /* 0.252118121 */, 18 }, - /* 4123 */ { MAD_F(0x04090287) /* 0.252199676 */, 18 }, - /* 4124 */ { MAD_F(0x0409580d) /* 0.252281238 */, 18 }, - /* 4125 */ { MAD_F(0x0409ad95) /* 0.252362807 */, 18 }, - /* 4126 */ { MAD_F(0x040a031e) /* 0.252444382 */, 18 }, - /* 4127 */ { MAD_F(0x040a58aa) /* 0.252525963 */, 18 }, - - /* 4128 */ { MAD_F(0x040aae37) /* 0.252607552 */, 18 }, - /* 4129 */ { MAD_F(0x040b03c6) /* 0.252689147 */, 18 }, - /* 4130 */ { MAD_F(0x040b5957) /* 0.252770748 */, 18 }, - /* 4131 */ { MAD_F(0x040baee9) /* 0.252852356 */, 18 }, - /* 4132 */ { MAD_F(0x040c047e) /* 0.252933971 */, 18 }, - /* 4133 */ { MAD_F(0x040c5a14) /* 0.253015592 */, 18 }, - /* 4134 */ { MAD_F(0x040cafab) /* 0.253097220 */, 18 }, - /* 4135 */ { MAD_F(0x040d0545) /* 0.253178854 */, 18 }, - /* 4136 */ { MAD_F(0x040d5ae0) /* 0.253260495 */, 18 }, - /* 4137 */ { MAD_F(0x040db07d) /* 0.253342143 */, 18 }, - /* 4138 */ { MAD_F(0x040e061c) /* 0.253423797 */, 18 }, - /* 4139 */ { MAD_F(0x040e5bbd) /* 0.253505457 */, 18 }, - /* 4140 */ { MAD_F(0x040eb15f) /* 0.253587125 */, 18 }, - /* 4141 */ { MAD_F(0x040f0703) /* 0.253668799 */, 18 }, - /* 4142 */ { MAD_F(0x040f5ca9) /* 0.253750479 */, 18 }, - /* 4143 */ { MAD_F(0x040fb251) /* 0.253832166 */, 18 }, - - /* 4144 */ { MAD_F(0x041007fa) /* 0.253913860 */, 18 }, - /* 4145 */ { MAD_F(0x04105da6) /* 0.253995560 */, 18 }, - /* 4146 */ { MAD_F(0x0410b353) /* 0.254077266 */, 18 }, - /* 4147 */ { MAD_F(0x04110901) /* 0.254158980 */, 18 }, - /* 4148 */ { MAD_F(0x04115eb2) /* 0.254240700 */, 18 }, - /* 4149 */ { MAD_F(0x0411b464) /* 0.254322426 */, 18 }, - /* 4150 */ { MAD_F(0x04120a18) /* 0.254404159 */, 18 }, - /* 4151 */ { MAD_F(0x04125fce) /* 0.254485899 */, 18 }, - /* 4152 */ { MAD_F(0x0412b586) /* 0.254567645 */, 18 }, - /* 4153 */ { MAD_F(0x04130b3f) /* 0.254649397 */, 18 }, - /* 4154 */ { MAD_F(0x041360fa) /* 0.254731157 */, 18 }, - /* 4155 */ { MAD_F(0x0413b6b7) /* 0.254812922 */, 18 }, - /* 4156 */ { MAD_F(0x04140c75) /* 0.254894695 */, 18 }, - /* 4157 */ { MAD_F(0x04146236) /* 0.254976474 */, 18 }, - /* 4158 */ { MAD_F(0x0414b7f8) /* 0.255058259 */, 18 }, - /* 4159 */ { MAD_F(0x04150dbc) /* 0.255140051 */, 18 }, - - /* 4160 */ { MAD_F(0x04156381) /* 0.255221850 */, 18 }, - /* 4161 */ { MAD_F(0x0415b949) /* 0.255303655 */, 18 }, - /* 4162 */ { MAD_F(0x04160f12) /* 0.255385467 */, 18 }, - /* 4163 */ { MAD_F(0x041664dd) /* 0.255467285 */, 18 }, - /* 4164 */ { MAD_F(0x0416baaa) /* 0.255549110 */, 18 }, - /* 4165 */ { MAD_F(0x04171078) /* 0.255630941 */, 18 }, - /* 4166 */ { MAD_F(0x04176648) /* 0.255712779 */, 18 }, - /* 4167 */ { MAD_F(0x0417bc1a) /* 0.255794624 */, 18 }, - /* 4168 */ { MAD_F(0x041811ee) /* 0.255876475 */, 18 }, - /* 4169 */ { MAD_F(0x041867c3) /* 0.255958332 */, 18 }, - /* 4170 */ { MAD_F(0x0418bd9b) /* 0.256040196 */, 18 }, - /* 4171 */ { MAD_F(0x04191374) /* 0.256122067 */, 18 }, - /* 4172 */ { MAD_F(0x0419694e) /* 0.256203944 */, 18 }, - /* 4173 */ { MAD_F(0x0419bf2b) /* 0.256285828 */, 18 }, - /* 4174 */ { MAD_F(0x041a1509) /* 0.256367718 */, 18 }, - /* 4175 */ { MAD_F(0x041a6ae9) /* 0.256449615 */, 18 }, - - /* 4176 */ { MAD_F(0x041ac0cb) /* 0.256531518 */, 18 }, - /* 4177 */ { MAD_F(0x041b16ae) /* 0.256613428 */, 18 }, - /* 4178 */ { MAD_F(0x041b6c94) /* 0.256695344 */, 18 }, - /* 4179 */ { MAD_F(0x041bc27b) /* 0.256777267 */, 18 }, - /* 4180 */ { MAD_F(0x041c1863) /* 0.256859197 */, 18 }, - /* 4181 */ { MAD_F(0x041c6e4e) /* 0.256941133 */, 18 }, - /* 4182 */ { MAD_F(0x041cc43a) /* 0.257023076 */, 18 }, - /* 4183 */ { MAD_F(0x041d1a28) /* 0.257105025 */, 18 }, - /* 4184 */ { MAD_F(0x041d7018) /* 0.257186980 */, 18 }, - /* 4185 */ { MAD_F(0x041dc60a) /* 0.257268942 */, 18 }, - /* 4186 */ { MAD_F(0x041e1bfd) /* 0.257350911 */, 18 }, - /* 4187 */ { MAD_F(0x041e71f2) /* 0.257432886 */, 18 }, - /* 4188 */ { MAD_F(0x041ec7e9) /* 0.257514868 */, 18 }, - /* 4189 */ { MAD_F(0x041f1de1) /* 0.257596856 */, 18 }, - /* 4190 */ { MAD_F(0x041f73dc) /* 0.257678851 */, 18 }, - /* 4191 */ { MAD_F(0x041fc9d8) /* 0.257760852 */, 18 }, - - /* 4192 */ { MAD_F(0x04201fd5) /* 0.257842860 */, 18 }, - /* 4193 */ { MAD_F(0x042075d5) /* 0.257924875 */, 18 }, - /* 4194 */ { MAD_F(0x0420cbd6) /* 0.258006895 */, 18 }, - /* 4195 */ { MAD_F(0x042121d9) /* 0.258088923 */, 18 }, - /* 4196 */ { MAD_F(0x042177de) /* 0.258170957 */, 18 }, - /* 4197 */ { MAD_F(0x0421cde5) /* 0.258252997 */, 18 }, - /* 4198 */ { MAD_F(0x042223ed) /* 0.258335044 */, 18 }, - /* 4199 */ { MAD_F(0x042279f7) /* 0.258417097 */, 18 }, - /* 4200 */ { MAD_F(0x0422d003) /* 0.258499157 */, 18 }, - /* 4201 */ { MAD_F(0x04232611) /* 0.258581224 */, 18 }, - /* 4202 */ { MAD_F(0x04237c20) /* 0.258663297 */, 18 }, - /* 4203 */ { MAD_F(0x0423d231) /* 0.258745376 */, 18 }, - /* 4204 */ { MAD_F(0x04242844) /* 0.258827462 */, 18 }, - /* 4205 */ { MAD_F(0x04247e58) /* 0.258909555 */, 18 }, - /* 4206 */ { MAD_F(0x0424d46e) /* 0.258991654 */, 18 }, - /* 4207 */ { MAD_F(0x04252a87) /* 0.259073760 */, 18 }, - - /* 4208 */ { MAD_F(0x042580a0) /* 0.259155872 */, 18 }, - /* 4209 */ { MAD_F(0x0425d6bc) /* 0.259237990 */, 18 }, - /* 4210 */ { MAD_F(0x04262cd9) /* 0.259320115 */, 18 }, - /* 4211 */ { MAD_F(0x042682f8) /* 0.259402247 */, 18 }, - /* 4212 */ { MAD_F(0x0426d919) /* 0.259484385 */, 18 }, - /* 4213 */ { MAD_F(0x04272f3b) /* 0.259566529 */, 18 }, - /* 4214 */ { MAD_F(0x04278560) /* 0.259648680 */, 18 }, - /* 4215 */ { MAD_F(0x0427db86) /* 0.259730838 */, 18 }, - /* 4216 */ { MAD_F(0x042831ad) /* 0.259813002 */, 18 }, - /* 4217 */ { MAD_F(0x042887d7) /* 0.259895173 */, 18 }, - /* 4218 */ { MAD_F(0x0428de02) /* 0.259977350 */, 18 }, - /* 4219 */ { MAD_F(0x0429342f) /* 0.260059533 */, 18 }, - /* 4220 */ { MAD_F(0x04298a5e) /* 0.260141723 */, 18 }, - /* 4221 */ { MAD_F(0x0429e08e) /* 0.260223920 */, 18 }, - /* 4222 */ { MAD_F(0x042a36c0) /* 0.260306123 */, 18 }, - /* 4223 */ { MAD_F(0x042a8cf4) /* 0.260388332 */, 18 }, - - /* 4224 */ { MAD_F(0x042ae32a) /* 0.260470548 */, 18 }, - /* 4225 */ { MAD_F(0x042b3962) /* 0.260552771 */, 18 }, - /* 4226 */ { MAD_F(0x042b8f9b) /* 0.260635000 */, 18 }, - /* 4227 */ { MAD_F(0x042be5d6) /* 0.260717235 */, 18 }, - /* 4228 */ { MAD_F(0x042c3c12) /* 0.260799477 */, 18 }, - /* 4229 */ { MAD_F(0x042c9251) /* 0.260881725 */, 18 }, - /* 4230 */ { MAD_F(0x042ce891) /* 0.260963980 */, 18 }, - /* 4231 */ { MAD_F(0x042d3ed3) /* 0.261046242 */, 18 }, - /* 4232 */ { MAD_F(0x042d9516) /* 0.261128510 */, 18 }, - /* 4233 */ { MAD_F(0x042deb5c) /* 0.261210784 */, 18 }, - /* 4234 */ { MAD_F(0x042e41a3) /* 0.261293065 */, 18 }, - /* 4235 */ { MAD_F(0x042e97ec) /* 0.261375352 */, 18 }, - /* 4236 */ { MAD_F(0x042eee36) /* 0.261457646 */, 18 }, - /* 4237 */ { MAD_F(0x042f4482) /* 0.261539946 */, 18 }, - /* 4238 */ { MAD_F(0x042f9ad1) /* 0.261622253 */, 18 }, - /* 4239 */ { MAD_F(0x042ff120) /* 0.261704566 */, 18 }, - - /* 4240 */ { MAD_F(0x04304772) /* 0.261786886 */, 18 }, - /* 4241 */ { MAD_F(0x04309dc5) /* 0.261869212 */, 18 }, - /* 4242 */ { MAD_F(0x0430f41a) /* 0.261951545 */, 18 }, - /* 4243 */ { MAD_F(0x04314a71) /* 0.262033884 */, 18 }, - /* 4244 */ { MAD_F(0x0431a0c9) /* 0.262116229 */, 18 }, - /* 4245 */ { MAD_F(0x0431f723) /* 0.262198581 */, 18 }, - /* 4246 */ { MAD_F(0x04324d7f) /* 0.262280940 */, 18 }, - /* 4247 */ { MAD_F(0x0432a3dd) /* 0.262363305 */, 18 }, - /* 4248 */ { MAD_F(0x0432fa3d) /* 0.262445676 */, 18 }, - /* 4249 */ { MAD_F(0x0433509e) /* 0.262528054 */, 18 }, - /* 4250 */ { MAD_F(0x0433a701) /* 0.262610438 */, 18 }, - /* 4251 */ { MAD_F(0x0433fd65) /* 0.262692829 */, 18 }, - /* 4252 */ { MAD_F(0x043453cc) /* 0.262775227 */, 18 }, - /* 4253 */ { MAD_F(0x0434aa34) /* 0.262857630 */, 18 }, - /* 4254 */ { MAD_F(0x0435009d) /* 0.262940040 */, 18 }, - /* 4255 */ { MAD_F(0x04355709) /* 0.263022457 */, 18 }, - - /* 4256 */ { MAD_F(0x0435ad76) /* 0.263104880 */, 18 }, - /* 4257 */ { MAD_F(0x043603e5) /* 0.263187310 */, 18 }, - /* 4258 */ { MAD_F(0x04365a56) /* 0.263269746 */, 18 }, - /* 4259 */ { MAD_F(0x0436b0c9) /* 0.263352188 */, 18 }, - /* 4260 */ { MAD_F(0x0437073d) /* 0.263434637 */, 18 }, - /* 4261 */ { MAD_F(0x04375db3) /* 0.263517093 */, 18 }, - /* 4262 */ { MAD_F(0x0437b42a) /* 0.263599554 */, 18 }, - /* 4263 */ { MAD_F(0x04380aa4) /* 0.263682023 */, 18 }, - /* 4264 */ { MAD_F(0x0438611f) /* 0.263764497 */, 18 }, - /* 4265 */ { MAD_F(0x0438b79c) /* 0.263846979 */, 18 }, - /* 4266 */ { MAD_F(0x04390e1a) /* 0.263929466 */, 18 }, - /* 4267 */ { MAD_F(0x0439649b) /* 0.264011960 */, 18 }, - /* 4268 */ { MAD_F(0x0439bb1d) /* 0.264094461 */, 18 }, - /* 4269 */ { MAD_F(0x043a11a1) /* 0.264176968 */, 18 }, - /* 4270 */ { MAD_F(0x043a6826) /* 0.264259481 */, 18 }, - /* 4271 */ { MAD_F(0x043abead) /* 0.264342001 */, 18 }, - - /* 4272 */ { MAD_F(0x043b1536) /* 0.264424527 */, 18 }, - /* 4273 */ { MAD_F(0x043b6bc1) /* 0.264507060 */, 18 }, - /* 4274 */ { MAD_F(0x043bc24d) /* 0.264589599 */, 18 }, - /* 4275 */ { MAD_F(0x043c18dc) /* 0.264672145 */, 18 }, - /* 4276 */ { MAD_F(0x043c6f6c) /* 0.264754697 */, 18 }, - /* 4277 */ { MAD_F(0x043cc5fd) /* 0.264837255 */, 18 }, - /* 4278 */ { MAD_F(0x043d1c91) /* 0.264919820 */, 18 }, - /* 4279 */ { MAD_F(0x043d7326) /* 0.265002392 */, 18 }, - /* 4280 */ { MAD_F(0x043dc9bc) /* 0.265084969 */, 18 }, - /* 4281 */ { MAD_F(0x043e2055) /* 0.265167554 */, 18 }, - /* 4282 */ { MAD_F(0x043e76ef) /* 0.265250144 */, 18 }, - /* 4283 */ { MAD_F(0x043ecd8b) /* 0.265332741 */, 18 }, - /* 4284 */ { MAD_F(0x043f2429) /* 0.265415345 */, 18 }, - /* 4285 */ { MAD_F(0x043f7ac8) /* 0.265497955 */, 18 }, - /* 4286 */ { MAD_F(0x043fd169) /* 0.265580571 */, 18 }, - /* 4287 */ { MAD_F(0x0440280c) /* 0.265663194 */, 18 }, - - /* 4288 */ { MAD_F(0x04407eb1) /* 0.265745823 */, 18 }, - /* 4289 */ { MAD_F(0x0440d557) /* 0.265828459 */, 18 }, - /* 4290 */ { MAD_F(0x04412bff) /* 0.265911101 */, 18 }, - /* 4291 */ { MAD_F(0x044182a9) /* 0.265993749 */, 18 }, - /* 4292 */ { MAD_F(0x0441d955) /* 0.266076404 */, 18 }, - /* 4293 */ { MAD_F(0x04423002) /* 0.266159065 */, 18 }, - /* 4294 */ { MAD_F(0x044286b1) /* 0.266241733 */, 18 }, - /* 4295 */ { MAD_F(0x0442dd61) /* 0.266324407 */, 18 }, - /* 4296 */ { MAD_F(0x04433414) /* 0.266407088 */, 18 }, - /* 4297 */ { MAD_F(0x04438ac8) /* 0.266489775 */, 18 }, - /* 4298 */ { MAD_F(0x0443e17e) /* 0.266572468 */, 18 }, - /* 4299 */ { MAD_F(0x04443835) /* 0.266655168 */, 18 }, - /* 4300 */ { MAD_F(0x04448eef) /* 0.266737874 */, 18 }, - /* 4301 */ { MAD_F(0x0444e5aa) /* 0.266820587 */, 18 }, - /* 4302 */ { MAD_F(0x04453c66) /* 0.266903306 */, 18 }, - /* 4303 */ { MAD_F(0x04459325) /* 0.266986031 */, 18 }, - - /* 4304 */ { MAD_F(0x0445e9e5) /* 0.267068763 */, 18 }, - /* 4305 */ { MAD_F(0x044640a7) /* 0.267151501 */, 18 }, - /* 4306 */ { MAD_F(0x0446976a) /* 0.267234246 */, 18 }, - /* 4307 */ { MAD_F(0x0446ee30) /* 0.267316997 */, 18 }, - /* 4308 */ { MAD_F(0x044744f7) /* 0.267399755 */, 18 }, - /* 4309 */ { MAD_F(0x04479bc0) /* 0.267482518 */, 18 }, - /* 4310 */ { MAD_F(0x0447f28a) /* 0.267565289 */, 18 }, - /* 4311 */ { MAD_F(0x04484956) /* 0.267648065 */, 18 }, - /* 4312 */ { MAD_F(0x0448a024) /* 0.267730848 */, 18 }, - /* 4313 */ { MAD_F(0x0448f6f4) /* 0.267813638 */, 18 }, - /* 4314 */ { MAD_F(0x04494dc5) /* 0.267896434 */, 18 }, - /* 4315 */ { MAD_F(0x0449a498) /* 0.267979236 */, 18 }, - /* 4316 */ { MAD_F(0x0449fb6d) /* 0.268062045 */, 18 }, - /* 4317 */ { MAD_F(0x044a5243) /* 0.268144860 */, 18 }, - /* 4318 */ { MAD_F(0x044aa91c) /* 0.268227681 */, 18 }, - /* 4319 */ { MAD_F(0x044afff6) /* 0.268310509 */, 18 }, - - /* 4320 */ { MAD_F(0x044b56d1) /* 0.268393343 */, 18 }, - /* 4321 */ { MAD_F(0x044badaf) /* 0.268476184 */, 18 }, - /* 4322 */ { MAD_F(0x044c048e) /* 0.268559031 */, 18 }, - /* 4323 */ { MAD_F(0x044c5b6f) /* 0.268641885 */, 18 }, - /* 4324 */ { MAD_F(0x044cb251) /* 0.268724744 */, 18 }, - /* 4325 */ { MAD_F(0x044d0935) /* 0.268807611 */, 18 }, - /* 4326 */ { MAD_F(0x044d601b) /* 0.268890483 */, 18 }, - /* 4327 */ { MAD_F(0x044db703) /* 0.268973362 */, 18 }, - /* 4328 */ { MAD_F(0x044e0dec) /* 0.269056248 */, 18 }, - /* 4329 */ { MAD_F(0x044e64d7) /* 0.269139139 */, 18 }, - /* 4330 */ { MAD_F(0x044ebbc4) /* 0.269222037 */, 18 }, - /* 4331 */ { MAD_F(0x044f12b3) /* 0.269304942 */, 18 }, - /* 4332 */ { MAD_F(0x044f69a3) /* 0.269387853 */, 18 }, - /* 4333 */ { MAD_F(0x044fc095) /* 0.269470770 */, 18 }, - /* 4334 */ { MAD_F(0x04501788) /* 0.269553694 */, 18 }, - /* 4335 */ { MAD_F(0x04506e7e) /* 0.269636624 */, 18 }, - - /* 4336 */ { MAD_F(0x0450c575) /* 0.269719560 */, 18 }, - /* 4337 */ { MAD_F(0x04511c6e) /* 0.269802503 */, 18 }, - /* 4338 */ { MAD_F(0x04517368) /* 0.269885452 */, 18 }, - /* 4339 */ { MAD_F(0x0451ca64) /* 0.269968408 */, 18 }, - /* 4340 */ { MAD_F(0x04522162) /* 0.270051370 */, 18 }, - /* 4341 */ { MAD_F(0x04527862) /* 0.270134338 */, 18 }, - /* 4342 */ { MAD_F(0x0452cf63) /* 0.270217312 */, 18 }, - /* 4343 */ { MAD_F(0x04532666) /* 0.270300293 */, 18 }, - /* 4344 */ { MAD_F(0x04537d6b) /* 0.270383281 */, 18 }, - /* 4345 */ { MAD_F(0x0453d472) /* 0.270466275 */, 18 }, - /* 4346 */ { MAD_F(0x04542b7a) /* 0.270549275 */, 18 }, - /* 4347 */ { MAD_F(0x04548284) /* 0.270632281 */, 18 }, - /* 4348 */ { MAD_F(0x0454d98f) /* 0.270715294 */, 18 }, - /* 4349 */ { MAD_F(0x0455309c) /* 0.270798313 */, 18 }, - /* 4350 */ { MAD_F(0x045587ab) /* 0.270881339 */, 18 }, - /* 4351 */ { MAD_F(0x0455debc) /* 0.270964371 */, 18 }, - - /* 4352 */ { MAD_F(0x045635cf) /* 0.271047409 */, 18 }, - /* 4353 */ { MAD_F(0x04568ce3) /* 0.271130454 */, 18 }, - /* 4354 */ { MAD_F(0x0456e3f9) /* 0.271213505 */, 18 }, - /* 4355 */ { MAD_F(0x04573b10) /* 0.271296562 */, 18 }, - /* 4356 */ { MAD_F(0x04579229) /* 0.271379626 */, 18 }, - /* 4357 */ { MAD_F(0x0457e944) /* 0.271462696 */, 18 }, - /* 4358 */ { MAD_F(0x04584061) /* 0.271545772 */, 18 }, - /* 4359 */ { MAD_F(0x0458977f) /* 0.271628855 */, 18 }, - /* 4360 */ { MAD_F(0x0458ee9f) /* 0.271711944 */, 18 }, - /* 4361 */ { MAD_F(0x045945c1) /* 0.271795040 */, 18 }, - /* 4362 */ { MAD_F(0x04599ce5) /* 0.271878142 */, 18 }, - /* 4363 */ { MAD_F(0x0459f40a) /* 0.271961250 */, 18 }, - /* 4364 */ { MAD_F(0x045a4b31) /* 0.272044365 */, 18 }, - /* 4365 */ { MAD_F(0x045aa259) /* 0.272127486 */, 18 }, - /* 4366 */ { MAD_F(0x045af984) /* 0.272210613 */, 18 }, - /* 4367 */ { MAD_F(0x045b50b0) /* 0.272293746 */, 18 }, - - /* 4368 */ { MAD_F(0x045ba7dd) /* 0.272376886 */, 18 }, - /* 4369 */ { MAD_F(0x045bff0d) /* 0.272460033 */, 18 }, - /* 4370 */ { MAD_F(0x045c563e) /* 0.272543185 */, 18 }, - /* 4371 */ { MAD_F(0x045cad71) /* 0.272626344 */, 18 }, - /* 4372 */ { MAD_F(0x045d04a5) /* 0.272709510 */, 18 }, - /* 4373 */ { MAD_F(0x045d5bdc) /* 0.272792681 */, 18 }, - /* 4374 */ { MAD_F(0x045db313) /* 0.272875859 */, 18 }, - /* 4375 */ { MAD_F(0x045e0a4d) /* 0.272959044 */, 18 }, - /* 4376 */ { MAD_F(0x045e6188) /* 0.273042234 */, 18 }, - /* 4377 */ { MAD_F(0x045eb8c5) /* 0.273125431 */, 18 }, - /* 4378 */ { MAD_F(0x045f1004) /* 0.273208635 */, 18 }, - /* 4379 */ { MAD_F(0x045f6745) /* 0.273291844 */, 18 }, - /* 4380 */ { MAD_F(0x045fbe87) /* 0.273375060 */, 18 }, - /* 4381 */ { MAD_F(0x046015cb) /* 0.273458283 */, 18 }, - /* 4382 */ { MAD_F(0x04606d10) /* 0.273541511 */, 18 }, - /* 4383 */ { MAD_F(0x0460c457) /* 0.273624747 */, 18 }, - - /* 4384 */ { MAD_F(0x04611ba0) /* 0.273707988 */, 18 }, - /* 4385 */ { MAD_F(0x046172eb) /* 0.273791236 */, 18 }, - /* 4386 */ { MAD_F(0x0461ca37) /* 0.273874490 */, 18 }, - /* 4387 */ { MAD_F(0x04622185) /* 0.273957750 */, 18 }, - /* 4388 */ { MAD_F(0x046278d5) /* 0.274041017 */, 18 }, - /* 4389 */ { MAD_F(0x0462d026) /* 0.274124290 */, 18 }, - /* 4390 */ { MAD_F(0x0463277a) /* 0.274207569 */, 18 }, - /* 4391 */ { MAD_F(0x04637ece) /* 0.274290855 */, 18 }, - /* 4392 */ { MAD_F(0x0463d625) /* 0.274374147 */, 18 }, - /* 4393 */ { MAD_F(0x04642d7d) /* 0.274457445 */, 18 }, - /* 4394 */ { MAD_F(0x046484d7) /* 0.274540749 */, 18 }, - /* 4395 */ { MAD_F(0x0464dc33) /* 0.274624060 */, 18 }, - /* 4396 */ { MAD_F(0x04653390) /* 0.274707378 */, 18 }, - /* 4397 */ { MAD_F(0x04658aef) /* 0.274790701 */, 18 }, - /* 4398 */ { MAD_F(0x0465e250) /* 0.274874031 */, 18 }, - /* 4399 */ { MAD_F(0x046639b2) /* 0.274957367 */, 18 }, - - /* 4400 */ { MAD_F(0x04669116) /* 0.275040710 */, 18 }, - /* 4401 */ { MAD_F(0x0466e87c) /* 0.275124059 */, 18 }, - /* 4402 */ { MAD_F(0x04673fe3) /* 0.275207414 */, 18 }, - /* 4403 */ { MAD_F(0x0467974d) /* 0.275290775 */, 18 }, - /* 4404 */ { MAD_F(0x0467eeb7) /* 0.275374143 */, 18 }, - /* 4405 */ { MAD_F(0x04684624) /* 0.275457517 */, 18 }, - /* 4406 */ { MAD_F(0x04689d92) /* 0.275540897 */, 18 }, - /* 4407 */ { MAD_F(0x0468f502) /* 0.275624284 */, 18 }, - /* 4408 */ { MAD_F(0x04694c74) /* 0.275707677 */, 18 }, - /* 4409 */ { MAD_F(0x0469a3e7) /* 0.275791076 */, 18 }, - /* 4410 */ { MAD_F(0x0469fb5c) /* 0.275874482 */, 18 }, - /* 4411 */ { MAD_F(0x046a52d3) /* 0.275957894 */, 18 }, - /* 4412 */ { MAD_F(0x046aaa4b) /* 0.276041312 */, 18 }, - /* 4413 */ { MAD_F(0x046b01c5) /* 0.276124737 */, 18 }, - /* 4414 */ { MAD_F(0x046b5941) /* 0.276208167 */, 18 }, - /* 4415 */ { MAD_F(0x046bb0bf) /* 0.276291605 */, 18 }, - - /* 4416 */ { MAD_F(0x046c083e) /* 0.276375048 */, 18 }, - /* 4417 */ { MAD_F(0x046c5fbf) /* 0.276458498 */, 18 }, - /* 4418 */ { MAD_F(0x046cb741) /* 0.276541954 */, 18 }, - /* 4419 */ { MAD_F(0x046d0ec5) /* 0.276625416 */, 18 }, - /* 4420 */ { MAD_F(0x046d664b) /* 0.276708885 */, 18 }, - /* 4421 */ { MAD_F(0x046dbdd3) /* 0.276792360 */, 18 }, - /* 4422 */ { MAD_F(0x046e155c) /* 0.276875841 */, 18 }, - /* 4423 */ { MAD_F(0x046e6ce7) /* 0.276959328 */, 18 }, - /* 4424 */ { MAD_F(0x046ec474) /* 0.277042822 */, 18 }, - /* 4425 */ { MAD_F(0x046f1c02) /* 0.277126322 */, 18 }, - /* 4426 */ { MAD_F(0x046f7392) /* 0.277209829 */, 18 }, - /* 4427 */ { MAD_F(0x046fcb24) /* 0.277293341 */, 18 }, - /* 4428 */ { MAD_F(0x047022b8) /* 0.277376860 */, 18 }, - /* 4429 */ { MAD_F(0x04707a4d) /* 0.277460385 */, 18 }, - /* 4430 */ { MAD_F(0x0470d1e4) /* 0.277543917 */, 18 }, - /* 4431 */ { MAD_F(0x0471297c) /* 0.277627455 */, 18 }, - - /* 4432 */ { MAD_F(0x04718116) /* 0.277710999 */, 18 }, - /* 4433 */ { MAD_F(0x0471d8b2) /* 0.277794549 */, 18 }, - /* 4434 */ { MAD_F(0x04723050) /* 0.277878106 */, 18 }, - /* 4435 */ { MAD_F(0x047287ef) /* 0.277961669 */, 18 }, - /* 4436 */ { MAD_F(0x0472df90) /* 0.278045238 */, 18 }, - /* 4437 */ { MAD_F(0x04733733) /* 0.278128813 */, 18 }, - /* 4438 */ { MAD_F(0x04738ed7) /* 0.278212395 */, 18 }, - /* 4439 */ { MAD_F(0x0473e67d) /* 0.278295983 */, 18 }, - /* 4440 */ { MAD_F(0x04743e25) /* 0.278379578 */, 18 }, - /* 4441 */ { MAD_F(0x047495ce) /* 0.278463178 */, 18 }, - /* 4442 */ { MAD_F(0x0474ed79) /* 0.278546785 */, 18 }, - /* 4443 */ { MAD_F(0x04754526) /* 0.278630398 */, 18 }, - /* 4444 */ { MAD_F(0x04759cd4) /* 0.278714018 */, 18 }, - /* 4445 */ { MAD_F(0x0475f484) /* 0.278797643 */, 18 }, - /* 4446 */ { MAD_F(0x04764c36) /* 0.278881275 */, 18 }, - /* 4447 */ { MAD_F(0x0476a3ea) /* 0.278964914 */, 18 }, - - /* 4448 */ { MAD_F(0x0476fb9f) /* 0.279048558 */, 18 }, - /* 4449 */ { MAD_F(0x04775356) /* 0.279132209 */, 18 }, - /* 4450 */ { MAD_F(0x0477ab0e) /* 0.279215866 */, 18 }, - /* 4451 */ { MAD_F(0x047802c8) /* 0.279299529 */, 18 }, - /* 4452 */ { MAD_F(0x04785a84) /* 0.279383199 */, 18 }, - /* 4453 */ { MAD_F(0x0478b242) /* 0.279466875 */, 18 }, - /* 4454 */ { MAD_F(0x04790a01) /* 0.279550557 */, 18 }, - /* 4455 */ { MAD_F(0x047961c2) /* 0.279634245 */, 18 }, - /* 4456 */ { MAD_F(0x0479b984) /* 0.279717940 */, 18 }, - /* 4457 */ { MAD_F(0x047a1149) /* 0.279801641 */, 18 }, - /* 4458 */ { MAD_F(0x047a690f) /* 0.279885348 */, 18 }, - /* 4459 */ { MAD_F(0x047ac0d6) /* 0.279969061 */, 18 }, - /* 4460 */ { MAD_F(0x047b18a0) /* 0.280052781 */, 18 }, - /* 4461 */ { MAD_F(0x047b706b) /* 0.280136507 */, 18 }, - /* 4462 */ { MAD_F(0x047bc837) /* 0.280220239 */, 18 }, - /* 4463 */ { MAD_F(0x047c2006) /* 0.280303978 */, 18 }, - - /* 4464 */ { MAD_F(0x047c77d6) /* 0.280387722 */, 18 }, - /* 4465 */ { MAD_F(0x047ccfa8) /* 0.280471473 */, 18 }, - /* 4466 */ { MAD_F(0x047d277b) /* 0.280555230 */, 18 }, - /* 4467 */ { MAD_F(0x047d7f50) /* 0.280638994 */, 18 }, - /* 4468 */ { MAD_F(0x047dd727) /* 0.280722764 */, 18 }, - /* 4469 */ { MAD_F(0x047e2eff) /* 0.280806540 */, 18 }, - /* 4470 */ { MAD_F(0x047e86d9) /* 0.280890322 */, 18 }, - /* 4471 */ { MAD_F(0x047edeb5) /* 0.280974110 */, 18 }, - /* 4472 */ { MAD_F(0x047f3693) /* 0.281057905 */, 18 }, - /* 4473 */ { MAD_F(0x047f8e72) /* 0.281141706 */, 18 }, - /* 4474 */ { MAD_F(0x047fe653) /* 0.281225513 */, 18 }, - /* 4475 */ { MAD_F(0x04803e35) /* 0.281309326 */, 18 }, - /* 4476 */ { MAD_F(0x04809619) /* 0.281393146 */, 18 }, - /* 4477 */ { MAD_F(0x0480edff) /* 0.281476972 */, 18 }, - /* 4478 */ { MAD_F(0x048145e7) /* 0.281560804 */, 18 }, - /* 4479 */ { MAD_F(0x04819dd0) /* 0.281644643 */, 18 }, - - /* 4480 */ { MAD_F(0x0481f5bb) /* 0.281728487 */, 18 }, - /* 4481 */ { MAD_F(0x04824da7) /* 0.281812338 */, 18 }, - /* 4482 */ { MAD_F(0x0482a595) /* 0.281896195 */, 18 }, - /* 4483 */ { MAD_F(0x0482fd85) /* 0.281980059 */, 18 }, - /* 4484 */ { MAD_F(0x04835577) /* 0.282063928 */, 18 }, - /* 4485 */ { MAD_F(0x0483ad6a) /* 0.282147804 */, 18 }, - /* 4486 */ { MAD_F(0x0484055f) /* 0.282231686 */, 18 }, - /* 4487 */ { MAD_F(0x04845d56) /* 0.282315574 */, 18 }, - /* 4488 */ { MAD_F(0x0484b54e) /* 0.282399469 */, 18 }, - /* 4489 */ { MAD_F(0x04850d48) /* 0.282483370 */, 18 }, - /* 4490 */ { MAD_F(0x04856544) /* 0.282567277 */, 18 }, - /* 4491 */ { MAD_F(0x0485bd41) /* 0.282651190 */, 18 }, - /* 4492 */ { MAD_F(0x04861540) /* 0.282735109 */, 18 }, - /* 4493 */ { MAD_F(0x04866d40) /* 0.282819035 */, 18 }, - /* 4494 */ { MAD_F(0x0486c543) /* 0.282902967 */, 18 }, - /* 4495 */ { MAD_F(0x04871d47) /* 0.282986905 */, 18 }, - - /* 4496 */ { MAD_F(0x0487754c) /* 0.283070849 */, 18 }, - /* 4497 */ { MAD_F(0x0487cd54) /* 0.283154800 */, 18 }, - /* 4498 */ { MAD_F(0x0488255d) /* 0.283238757 */, 18 }, - /* 4499 */ { MAD_F(0x04887d67) /* 0.283322720 */, 18 }, - /* 4500 */ { MAD_F(0x0488d574) /* 0.283406689 */, 18 }, - /* 4501 */ { MAD_F(0x04892d82) /* 0.283490665 */, 18 }, - /* 4502 */ { MAD_F(0x04898591) /* 0.283574646 */, 18 }, - /* 4503 */ { MAD_F(0x0489dda3) /* 0.283658634 */, 18 }, - /* 4504 */ { MAD_F(0x048a35b6) /* 0.283742628 */, 18 }, - /* 4505 */ { MAD_F(0x048a8dca) /* 0.283826629 */, 18 }, - /* 4506 */ { MAD_F(0x048ae5e1) /* 0.283910635 */, 18 }, - /* 4507 */ { MAD_F(0x048b3df9) /* 0.283994648 */, 18 }, - /* 4508 */ { MAD_F(0x048b9612) /* 0.284078667 */, 18 }, - /* 4509 */ { MAD_F(0x048bee2e) /* 0.284162692 */, 18 }, - /* 4510 */ { MAD_F(0x048c464b) /* 0.284246723 */, 18 }, - /* 4511 */ { MAD_F(0x048c9e69) /* 0.284330761 */, 18 }, - - /* 4512 */ { MAD_F(0x048cf68a) /* 0.284414805 */, 18 }, - /* 4513 */ { MAD_F(0x048d4eac) /* 0.284498855 */, 18 }, - /* 4514 */ { MAD_F(0x048da6cf) /* 0.284582911 */, 18 }, - /* 4515 */ { MAD_F(0x048dfef5) /* 0.284666974 */, 18 }, - /* 4516 */ { MAD_F(0x048e571c) /* 0.284751042 */, 18 }, - /* 4517 */ { MAD_F(0x048eaf44) /* 0.284835117 */, 18 }, - /* 4518 */ { MAD_F(0x048f076f) /* 0.284919198 */, 18 }, - /* 4519 */ { MAD_F(0x048f5f9b) /* 0.285003285 */, 18 }, - /* 4520 */ { MAD_F(0x048fb7c8) /* 0.285087379 */, 18 }, - /* 4521 */ { MAD_F(0x04900ff8) /* 0.285171479 */, 18 }, - /* 4522 */ { MAD_F(0x04906829) /* 0.285255584 */, 18 }, - /* 4523 */ { MAD_F(0x0490c05b) /* 0.285339697 */, 18 }, - /* 4524 */ { MAD_F(0x04911890) /* 0.285423815 */, 18 }, - /* 4525 */ { MAD_F(0x049170c6) /* 0.285507939 */, 18 }, - /* 4526 */ { MAD_F(0x0491c8fd) /* 0.285592070 */, 18 }, - /* 4527 */ { MAD_F(0x04922137) /* 0.285676207 */, 18 }, - - /* 4528 */ { MAD_F(0x04927972) /* 0.285760350 */, 18 }, - /* 4529 */ { MAD_F(0x0492d1ae) /* 0.285844499 */, 18 }, - /* 4530 */ { MAD_F(0x049329ed) /* 0.285928655 */, 18 }, - /* 4531 */ { MAD_F(0x0493822c) /* 0.286012816 */, 18 }, - /* 4532 */ { MAD_F(0x0493da6e) /* 0.286096984 */, 18 }, - /* 4533 */ { MAD_F(0x049432b1) /* 0.286181158 */, 18 }, - /* 4534 */ { MAD_F(0x04948af6) /* 0.286265338 */, 18 }, - /* 4535 */ { MAD_F(0x0494e33d) /* 0.286349525 */, 18 }, - /* 4536 */ { MAD_F(0x04953b85) /* 0.286433717 */, 18 }, - /* 4537 */ { MAD_F(0x049593cf) /* 0.286517916 */, 18 }, - /* 4538 */ { MAD_F(0x0495ec1b) /* 0.286602121 */, 18 }, - /* 4539 */ { MAD_F(0x04964468) /* 0.286686332 */, 18 }, - /* 4540 */ { MAD_F(0x04969cb7) /* 0.286770550 */, 18 }, - /* 4541 */ { MAD_F(0x0496f508) /* 0.286854773 */, 18 }, - /* 4542 */ { MAD_F(0x04974d5a) /* 0.286939003 */, 18 }, - /* 4543 */ { MAD_F(0x0497a5ae) /* 0.287023239 */, 18 }, - - /* 4544 */ { MAD_F(0x0497fe03) /* 0.287107481 */, 18 }, - /* 4545 */ { MAD_F(0x0498565a) /* 0.287191729 */, 18 }, - /* 4546 */ { MAD_F(0x0498aeb3) /* 0.287275983 */, 18 }, - /* 4547 */ { MAD_F(0x0499070e) /* 0.287360244 */, 18 }, - /* 4548 */ { MAD_F(0x04995f6a) /* 0.287444511 */, 18 }, - /* 4549 */ { MAD_F(0x0499b7c8) /* 0.287528784 */, 18 }, - /* 4550 */ { MAD_F(0x049a1027) /* 0.287613063 */, 18 }, - /* 4551 */ { MAD_F(0x049a6889) /* 0.287697348 */, 18 }, - /* 4552 */ { MAD_F(0x049ac0eb) /* 0.287781640 */, 18 }, - /* 4553 */ { MAD_F(0x049b1950) /* 0.287865937 */, 18 }, - /* 4554 */ { MAD_F(0x049b71b6) /* 0.287950241 */, 18 }, - /* 4555 */ { MAD_F(0x049bca1e) /* 0.288034551 */, 18 }, - /* 4556 */ { MAD_F(0x049c2287) /* 0.288118867 */, 18 }, - /* 4557 */ { MAD_F(0x049c7af2) /* 0.288203190 */, 18 }, - /* 4558 */ { MAD_F(0x049cd35f) /* 0.288287518 */, 18 }, - /* 4559 */ { MAD_F(0x049d2bce) /* 0.288371853 */, 18 }, - - /* 4560 */ { MAD_F(0x049d843e) /* 0.288456194 */, 18 }, - /* 4561 */ { MAD_F(0x049ddcaf) /* 0.288540541 */, 18 }, - /* 4562 */ { MAD_F(0x049e3523) /* 0.288624894 */, 18 }, - /* 4563 */ { MAD_F(0x049e8d98) /* 0.288709253 */, 18 }, - /* 4564 */ { MAD_F(0x049ee60e) /* 0.288793619 */, 18 }, - /* 4565 */ { MAD_F(0x049f3e87) /* 0.288877990 */, 18 }, - /* 4566 */ { MAD_F(0x049f9701) /* 0.288962368 */, 18 }, - /* 4567 */ { MAD_F(0x049fef7c) /* 0.289046752 */, 18 }, - /* 4568 */ { MAD_F(0x04a047fa) /* 0.289131142 */, 18 }, - /* 4569 */ { MAD_F(0x04a0a079) /* 0.289215538 */, 18 }, - /* 4570 */ { MAD_F(0x04a0f8f9) /* 0.289299941 */, 18 }, - /* 4571 */ { MAD_F(0x04a1517c) /* 0.289384349 */, 18 }, - /* 4572 */ { MAD_F(0x04a1a9ff) /* 0.289468764 */, 18 }, - /* 4573 */ { MAD_F(0x04a20285) /* 0.289553185 */, 18 }, - /* 4574 */ { MAD_F(0x04a25b0c) /* 0.289637612 */, 18 }, - /* 4575 */ { MAD_F(0x04a2b395) /* 0.289722045 */, 18 }, - - /* 4576 */ { MAD_F(0x04a30c20) /* 0.289806485 */, 18 }, - /* 4577 */ { MAD_F(0x04a364ac) /* 0.289890930 */, 18 }, - /* 4578 */ { MAD_F(0x04a3bd3a) /* 0.289975382 */, 18 }, - /* 4579 */ { MAD_F(0x04a415c9) /* 0.290059840 */, 18 }, - /* 4580 */ { MAD_F(0x04a46e5a) /* 0.290144304 */, 18 }, - /* 4581 */ { MAD_F(0x04a4c6ed) /* 0.290228774 */, 18 }, - /* 4582 */ { MAD_F(0x04a51f81) /* 0.290313250 */, 18 }, - /* 4583 */ { MAD_F(0x04a57818) /* 0.290397733 */, 18 }, - /* 4584 */ { MAD_F(0x04a5d0af) /* 0.290482221 */, 18 }, - /* 4585 */ { MAD_F(0x04a62949) /* 0.290566716 */, 18 }, - /* 4586 */ { MAD_F(0x04a681e4) /* 0.290651217 */, 18 }, - /* 4587 */ { MAD_F(0x04a6da80) /* 0.290735724 */, 18 }, - /* 4588 */ { MAD_F(0x04a7331f) /* 0.290820237 */, 18 }, - /* 4589 */ { MAD_F(0x04a78bbf) /* 0.290904756 */, 18 }, - /* 4590 */ { MAD_F(0x04a7e460) /* 0.290989281 */, 18 }, - /* 4591 */ { MAD_F(0x04a83d03) /* 0.291073813 */, 18 }, - - /* 4592 */ { MAD_F(0x04a895a8) /* 0.291158351 */, 18 }, - /* 4593 */ { MAD_F(0x04a8ee4f) /* 0.291242894 */, 18 }, - /* 4594 */ { MAD_F(0x04a946f7) /* 0.291327444 */, 18 }, - /* 4595 */ { MAD_F(0x04a99fa1) /* 0.291412001 */, 18 }, - /* 4596 */ { MAD_F(0x04a9f84c) /* 0.291496563 */, 18 }, - /* 4597 */ { MAD_F(0x04aa50fa) /* 0.291581131 */, 18 }, - /* 4598 */ { MAD_F(0x04aaa9a8) /* 0.291665706 */, 18 }, - /* 4599 */ { MAD_F(0x04ab0259) /* 0.291750286 */, 18 }, - /* 4600 */ { MAD_F(0x04ab5b0b) /* 0.291834873 */, 18 }, - /* 4601 */ { MAD_F(0x04abb3bf) /* 0.291919466 */, 18 }, - /* 4602 */ { MAD_F(0x04ac0c74) /* 0.292004065 */, 18 }, - /* 4603 */ { MAD_F(0x04ac652b) /* 0.292088670 */, 18 }, - /* 4604 */ { MAD_F(0x04acbde4) /* 0.292173281 */, 18 }, - /* 4605 */ { MAD_F(0x04ad169e) /* 0.292257899 */, 18 }, - /* 4606 */ { MAD_F(0x04ad6f5a) /* 0.292342522 */, 18 }, - /* 4607 */ { MAD_F(0x04adc818) /* 0.292427152 */, 18 }, - - /* 4608 */ { MAD_F(0x04ae20d7) /* 0.292511788 */, 18 }, - /* 4609 */ { MAD_F(0x04ae7998) /* 0.292596430 */, 18 }, - /* 4610 */ { MAD_F(0x04aed25a) /* 0.292681078 */, 18 }, - /* 4611 */ { MAD_F(0x04af2b1e) /* 0.292765732 */, 18 }, - /* 4612 */ { MAD_F(0x04af83e4) /* 0.292850392 */, 18 }, - /* 4613 */ { MAD_F(0x04afdcac) /* 0.292935058 */, 18 }, - /* 4614 */ { MAD_F(0x04b03575) /* 0.293019731 */, 18 }, - /* 4615 */ { MAD_F(0x04b08e40) /* 0.293104409 */, 18 }, - /* 4616 */ { MAD_F(0x04b0e70c) /* 0.293189094 */, 18 }, - /* 4617 */ { MAD_F(0x04b13fda) /* 0.293273785 */, 18 }, - /* 4618 */ { MAD_F(0x04b198aa) /* 0.293358482 */, 18 }, - /* 4619 */ { MAD_F(0x04b1f17b) /* 0.293443185 */, 18 }, - /* 4620 */ { MAD_F(0x04b24a4e) /* 0.293527894 */, 18 }, - /* 4621 */ { MAD_F(0x04b2a322) /* 0.293612609 */, 18 }, - /* 4622 */ { MAD_F(0x04b2fbf9) /* 0.293697331 */, 18 }, - /* 4623 */ { MAD_F(0x04b354d1) /* 0.293782058 */, 18 }, - - /* 4624 */ { MAD_F(0x04b3adaa) /* 0.293866792 */, 18 }, - /* 4625 */ { MAD_F(0x04b40685) /* 0.293951532 */, 18 }, - /* 4626 */ { MAD_F(0x04b45f62) /* 0.294036278 */, 18 }, - /* 4627 */ { MAD_F(0x04b4b840) /* 0.294121029 */, 18 }, - /* 4628 */ { MAD_F(0x04b51120) /* 0.294205788 */, 18 }, - /* 4629 */ { MAD_F(0x04b56a02) /* 0.294290552 */, 18 }, - /* 4630 */ { MAD_F(0x04b5c2e6) /* 0.294375322 */, 18 }, - /* 4631 */ { MAD_F(0x04b61bcb) /* 0.294460098 */, 18 }, - /* 4632 */ { MAD_F(0x04b674b1) /* 0.294544881 */, 18 }, - /* 4633 */ { MAD_F(0x04b6cd99) /* 0.294629669 */, 18 }, - /* 4634 */ { MAD_F(0x04b72683) /* 0.294714464 */, 18 }, - /* 4635 */ { MAD_F(0x04b77f6f) /* 0.294799265 */, 18 }, - /* 4636 */ { MAD_F(0x04b7d85c) /* 0.294884072 */, 18 }, - /* 4637 */ { MAD_F(0x04b8314b) /* 0.294968885 */, 18 }, - /* 4638 */ { MAD_F(0x04b88a3b) /* 0.295053704 */, 18 }, - /* 4639 */ { MAD_F(0x04b8e32d) /* 0.295138529 */, 18 }, - - /* 4640 */ { MAD_F(0x04b93c21) /* 0.295223360 */, 18 }, - /* 4641 */ { MAD_F(0x04b99516) /* 0.295308197 */, 18 }, - /* 4642 */ { MAD_F(0x04b9ee0d) /* 0.295393041 */, 18 }, - /* 4643 */ { MAD_F(0x04ba4706) /* 0.295477890 */, 18 }, - /* 4644 */ { MAD_F(0x04baa000) /* 0.295562746 */, 18 }, - /* 4645 */ { MAD_F(0x04baf8fc) /* 0.295647608 */, 18 }, - /* 4646 */ { MAD_F(0x04bb51fa) /* 0.295732476 */, 18 }, - /* 4647 */ { MAD_F(0x04bbaaf9) /* 0.295817349 */, 18 }, - /* 4648 */ { MAD_F(0x04bc03fa) /* 0.295902229 */, 18 }, - /* 4649 */ { MAD_F(0x04bc5cfc) /* 0.295987115 */, 18 }, - /* 4650 */ { MAD_F(0x04bcb600) /* 0.296072008 */, 18 }, - /* 4651 */ { MAD_F(0x04bd0f06) /* 0.296156906 */, 18 }, - /* 4652 */ { MAD_F(0x04bd680d) /* 0.296241810 */, 18 }, - /* 4653 */ { MAD_F(0x04bdc116) /* 0.296326721 */, 18 }, - /* 4654 */ { MAD_F(0x04be1a21) /* 0.296411637 */, 18 }, - /* 4655 */ { MAD_F(0x04be732d) /* 0.296496560 */, 18 }, - - /* 4656 */ { MAD_F(0x04becc3b) /* 0.296581488 */, 18 }, - /* 4657 */ { MAD_F(0x04bf254a) /* 0.296666423 */, 18 }, - /* 4658 */ { MAD_F(0x04bf7e5b) /* 0.296751364 */, 18 }, - /* 4659 */ { MAD_F(0x04bfd76e) /* 0.296836311 */, 18 }, - /* 4660 */ { MAD_F(0x04c03083) /* 0.296921264 */, 18 }, - /* 4661 */ { MAD_F(0x04c08999) /* 0.297006223 */, 18 }, - /* 4662 */ { MAD_F(0x04c0e2b0) /* 0.297091188 */, 18 }, - /* 4663 */ { MAD_F(0x04c13bca) /* 0.297176159 */, 18 }, - /* 4664 */ { MAD_F(0x04c194e4) /* 0.297261136 */, 18 }, - /* 4665 */ { MAD_F(0x04c1ee01) /* 0.297346120 */, 18 }, - /* 4666 */ { MAD_F(0x04c2471f) /* 0.297431109 */, 18 }, - /* 4667 */ { MAD_F(0x04c2a03f) /* 0.297516105 */, 18 }, - /* 4668 */ { MAD_F(0x04c2f960) /* 0.297601106 */, 18 }, - /* 4669 */ { MAD_F(0x04c35283) /* 0.297686114 */, 18 }, - /* 4670 */ { MAD_F(0x04c3aba8) /* 0.297771128 */, 18 }, - /* 4671 */ { MAD_F(0x04c404ce) /* 0.297856147 */, 18 }, - - /* 4672 */ { MAD_F(0x04c45df6) /* 0.297941173 */, 18 }, - /* 4673 */ { MAD_F(0x04c4b720) /* 0.298026205 */, 18 }, - /* 4674 */ { MAD_F(0x04c5104b) /* 0.298111243 */, 18 }, - /* 4675 */ { MAD_F(0x04c56978) /* 0.298196287 */, 18 }, - /* 4676 */ { MAD_F(0x04c5c2a7) /* 0.298281337 */, 18 }, - /* 4677 */ { MAD_F(0x04c61bd7) /* 0.298366393 */, 18 }, - /* 4678 */ { MAD_F(0x04c67508) /* 0.298451456 */, 18 }, - /* 4679 */ { MAD_F(0x04c6ce3c) /* 0.298536524 */, 18 }, - /* 4680 */ { MAD_F(0x04c72771) /* 0.298621598 */, 18 }, - /* 4681 */ { MAD_F(0x04c780a7) /* 0.298706679 */, 18 }, - /* 4682 */ { MAD_F(0x04c7d9df) /* 0.298791765 */, 18 }, - /* 4683 */ { MAD_F(0x04c83319) /* 0.298876858 */, 18 }, - /* 4684 */ { MAD_F(0x04c88c55) /* 0.298961956 */, 18 }, - /* 4685 */ { MAD_F(0x04c8e592) /* 0.299047061 */, 18 }, - /* 4686 */ { MAD_F(0x04c93ed1) /* 0.299132172 */, 18 }, - /* 4687 */ { MAD_F(0x04c99811) /* 0.299217288 */, 18 }, - - /* 4688 */ { MAD_F(0x04c9f153) /* 0.299302411 */, 18 }, - /* 4689 */ { MAD_F(0x04ca4a97) /* 0.299387540 */, 18 }, - /* 4690 */ { MAD_F(0x04caa3dc) /* 0.299472675 */, 18 }, - /* 4691 */ { MAD_F(0x04cafd23) /* 0.299557816 */, 18 }, - /* 4692 */ { MAD_F(0x04cb566b) /* 0.299642963 */, 18 }, - /* 4693 */ { MAD_F(0x04cbafb5) /* 0.299728116 */, 18 }, - /* 4694 */ { MAD_F(0x04cc0901) /* 0.299813275 */, 18 }, - /* 4695 */ { MAD_F(0x04cc624e) /* 0.299898440 */, 18 }, - /* 4696 */ { MAD_F(0x04ccbb9d) /* 0.299983611 */, 18 }, - /* 4697 */ { MAD_F(0x04cd14ee) /* 0.300068789 */, 18 }, - /* 4698 */ { MAD_F(0x04cd6e40) /* 0.300153972 */, 18 }, - /* 4699 */ { MAD_F(0x04cdc794) /* 0.300239161 */, 18 }, - /* 4700 */ { MAD_F(0x04ce20e9) /* 0.300324357 */, 18 }, - /* 4701 */ { MAD_F(0x04ce7a40) /* 0.300409558 */, 18 }, - /* 4702 */ { MAD_F(0x04ced399) /* 0.300494765 */, 18 }, - /* 4703 */ { MAD_F(0x04cf2cf3) /* 0.300579979 */, 18 }, - - /* 4704 */ { MAD_F(0x04cf864f) /* 0.300665198 */, 18 }, - /* 4705 */ { MAD_F(0x04cfdfad) /* 0.300750424 */, 18 }, - /* 4706 */ { MAD_F(0x04d0390c) /* 0.300835656 */, 18 }, - /* 4707 */ { MAD_F(0x04d0926d) /* 0.300920893 */, 18 }, - /* 4708 */ { MAD_F(0x04d0ebcf) /* 0.301006137 */, 18 }, - /* 4709 */ { MAD_F(0x04d14533) /* 0.301091387 */, 18 }, - /* 4710 */ { MAD_F(0x04d19e99) /* 0.301176643 */, 18 }, - /* 4711 */ { MAD_F(0x04d1f800) /* 0.301261904 */, 18 }, - /* 4712 */ { MAD_F(0x04d25169) /* 0.301347172 */, 18 }, - /* 4713 */ { MAD_F(0x04d2aad4) /* 0.301432446 */, 18 }, - /* 4714 */ { MAD_F(0x04d30440) /* 0.301517726 */, 18 }, - /* 4715 */ { MAD_F(0x04d35dae) /* 0.301603012 */, 18 }, - /* 4716 */ { MAD_F(0x04d3b71d) /* 0.301688304 */, 18 }, - /* 4717 */ { MAD_F(0x04d4108e) /* 0.301773602 */, 18 }, - /* 4718 */ { MAD_F(0x04d46a01) /* 0.301858906 */, 18 }, - /* 4719 */ { MAD_F(0x04d4c375) /* 0.301944216 */, 18 }, - - /* 4720 */ { MAD_F(0x04d51ceb) /* 0.302029532 */, 18 }, - /* 4721 */ { MAD_F(0x04d57662) /* 0.302114854 */, 18 }, - /* 4722 */ { MAD_F(0x04d5cfdb) /* 0.302200182 */, 18 }, - /* 4723 */ { MAD_F(0x04d62956) /* 0.302285516 */, 18 }, - /* 4724 */ { MAD_F(0x04d682d2) /* 0.302370856 */, 18 }, - /* 4725 */ { MAD_F(0x04d6dc50) /* 0.302456203 */, 18 }, - /* 4726 */ { MAD_F(0x04d735d0) /* 0.302541555 */, 18 }, - /* 4727 */ { MAD_F(0x04d78f51) /* 0.302626913 */, 18 }, - /* 4728 */ { MAD_F(0x04d7e8d4) /* 0.302712277 */, 18 }, - /* 4729 */ { MAD_F(0x04d84258) /* 0.302797648 */, 18 }, - /* 4730 */ { MAD_F(0x04d89bde) /* 0.302883024 */, 18 }, - /* 4731 */ { MAD_F(0x04d8f566) /* 0.302968406 */, 18 }, - /* 4732 */ { MAD_F(0x04d94eef) /* 0.303053794 */, 18 }, - /* 4733 */ { MAD_F(0x04d9a87a) /* 0.303139189 */, 18 }, - /* 4734 */ { MAD_F(0x04da0207) /* 0.303224589 */, 18 }, - /* 4735 */ { MAD_F(0x04da5b95) /* 0.303309995 */, 18 }, - - /* 4736 */ { MAD_F(0x04dab524) /* 0.303395408 */, 18 }, - /* 4737 */ { MAD_F(0x04db0eb6) /* 0.303480826 */, 18 }, - /* 4738 */ { MAD_F(0x04db6849) /* 0.303566251 */, 18 }, - /* 4739 */ { MAD_F(0x04dbc1dd) /* 0.303651681 */, 18 }, - /* 4740 */ { MAD_F(0x04dc1b73) /* 0.303737117 */, 18 }, - /* 4741 */ { MAD_F(0x04dc750b) /* 0.303822560 */, 18 }, - /* 4742 */ { MAD_F(0x04dccea5) /* 0.303908008 */, 18 }, - /* 4743 */ { MAD_F(0x04dd2840) /* 0.303993463 */, 18 }, - /* 4744 */ { MAD_F(0x04dd81dc) /* 0.304078923 */, 18 }, - /* 4745 */ { MAD_F(0x04dddb7a) /* 0.304164390 */, 18 }, - /* 4746 */ { MAD_F(0x04de351a) /* 0.304249862 */, 18 }, - /* 4747 */ { MAD_F(0x04de8ebc) /* 0.304335340 */, 18 }, - /* 4748 */ { MAD_F(0x04dee85f) /* 0.304420825 */, 18 }, - /* 4749 */ { MAD_F(0x04df4203) /* 0.304506315 */, 18 }, - /* 4750 */ { MAD_F(0x04df9baa) /* 0.304591812 */, 18 }, - /* 4751 */ { MAD_F(0x04dff552) /* 0.304677314 */, 18 }, - - /* 4752 */ { MAD_F(0x04e04efb) /* 0.304762823 */, 18 }, - /* 4753 */ { MAD_F(0x04e0a8a6) /* 0.304848337 */, 18 }, - /* 4754 */ { MAD_F(0x04e10253) /* 0.304933858 */, 18 }, - /* 4755 */ { MAD_F(0x04e15c01) /* 0.305019384 */, 18 }, - /* 4756 */ { MAD_F(0x04e1b5b1) /* 0.305104917 */, 18 }, - /* 4757 */ { MAD_F(0x04e20f63) /* 0.305190455 */, 18 }, - /* 4758 */ { MAD_F(0x04e26916) /* 0.305275999 */, 18 }, - /* 4759 */ { MAD_F(0x04e2c2cb) /* 0.305361550 */, 18 }, - /* 4760 */ { MAD_F(0x04e31c81) /* 0.305447106 */, 18 }, - /* 4761 */ { MAD_F(0x04e37639) /* 0.305532669 */, 18 }, - /* 4762 */ { MAD_F(0x04e3cff3) /* 0.305618237 */, 18 }, - /* 4763 */ { MAD_F(0x04e429ae) /* 0.305703811 */, 18 }, - /* 4764 */ { MAD_F(0x04e4836b) /* 0.305789392 */, 18 }, - /* 4765 */ { MAD_F(0x04e4dd29) /* 0.305874978 */, 18 }, - /* 4766 */ { MAD_F(0x04e536e9) /* 0.305960571 */, 18 }, - /* 4767 */ { MAD_F(0x04e590ab) /* 0.306046169 */, 18 }, - - /* 4768 */ { MAD_F(0x04e5ea6e) /* 0.306131773 */, 18 }, - /* 4769 */ { MAD_F(0x04e64433) /* 0.306217383 */, 18 }, - /* 4770 */ { MAD_F(0x04e69df9) /* 0.306303000 */, 18 }, - /* 4771 */ { MAD_F(0x04e6f7c1) /* 0.306388622 */, 18 }, - /* 4772 */ { MAD_F(0x04e7518b) /* 0.306474250 */, 18 }, - /* 4773 */ { MAD_F(0x04e7ab56) /* 0.306559885 */, 18 }, - /* 4774 */ { MAD_F(0x04e80523) /* 0.306645525 */, 18 }, - /* 4775 */ { MAD_F(0x04e85ef2) /* 0.306731171 */, 18 }, - /* 4776 */ { MAD_F(0x04e8b8c2) /* 0.306816823 */, 18 }, - /* 4777 */ { MAD_F(0x04e91293) /* 0.306902481 */, 18 }, - /* 4778 */ { MAD_F(0x04e96c67) /* 0.306988145 */, 18 }, - /* 4779 */ { MAD_F(0x04e9c63b) /* 0.307073816 */, 18 }, - /* 4780 */ { MAD_F(0x04ea2012) /* 0.307159492 */, 18 }, - /* 4781 */ { MAD_F(0x04ea79ea) /* 0.307245174 */, 18 }, - /* 4782 */ { MAD_F(0x04ead3c4) /* 0.307330862 */, 18 }, - /* 4783 */ { MAD_F(0x04eb2d9f) /* 0.307416556 */, 18 }, - - /* 4784 */ { MAD_F(0x04eb877c) /* 0.307502256 */, 18 }, - /* 4785 */ { MAD_F(0x04ebe15b) /* 0.307587962 */, 18 }, - /* 4786 */ { MAD_F(0x04ec3b3b) /* 0.307673674 */, 18 }, - /* 4787 */ { MAD_F(0x04ec951c) /* 0.307759392 */, 18 }, - /* 4788 */ { MAD_F(0x04ecef00) /* 0.307845115 */, 18 }, - /* 4789 */ { MAD_F(0x04ed48e5) /* 0.307930845 */, 18 }, - /* 4790 */ { MAD_F(0x04eda2cb) /* 0.308016581 */, 18 }, - /* 4791 */ { MAD_F(0x04edfcb3) /* 0.308102323 */, 18 }, - /* 4792 */ { MAD_F(0x04ee569d) /* 0.308188071 */, 18 }, - /* 4793 */ { MAD_F(0x04eeb088) /* 0.308273824 */, 18 }, - /* 4794 */ { MAD_F(0x04ef0a75) /* 0.308359584 */, 18 }, - /* 4795 */ { MAD_F(0x04ef6464) /* 0.308445350 */, 18 }, - /* 4796 */ { MAD_F(0x04efbe54) /* 0.308531121 */, 18 }, - /* 4797 */ { MAD_F(0x04f01846) /* 0.308616899 */, 18 }, - /* 4798 */ { MAD_F(0x04f07239) /* 0.308702682 */, 18 }, - /* 4799 */ { MAD_F(0x04f0cc2e) /* 0.308788472 */, 18 }, - - /* 4800 */ { MAD_F(0x04f12624) /* 0.308874267 */, 18 }, - /* 4801 */ { MAD_F(0x04f1801d) /* 0.308960068 */, 18 }, - /* 4802 */ { MAD_F(0x04f1da16) /* 0.309045876 */, 18 }, - /* 4803 */ { MAD_F(0x04f23412) /* 0.309131689 */, 18 }, - /* 4804 */ { MAD_F(0x04f28e0f) /* 0.309217508 */, 18 }, - /* 4805 */ { MAD_F(0x04f2e80d) /* 0.309303334 */, 18 }, - /* 4806 */ { MAD_F(0x04f3420d) /* 0.309389165 */, 18 }, - /* 4807 */ { MAD_F(0x04f39c0f) /* 0.309475002 */, 18 }, - /* 4808 */ { MAD_F(0x04f3f612) /* 0.309560845 */, 18 }, - /* 4809 */ { MAD_F(0x04f45017) /* 0.309646694 */, 18 }, - /* 4810 */ { MAD_F(0x04f4aa1e) /* 0.309732549 */, 18 }, - /* 4811 */ { MAD_F(0x04f50426) /* 0.309818410 */, 18 }, - /* 4812 */ { MAD_F(0x04f55e30) /* 0.309904277 */, 18 }, - /* 4813 */ { MAD_F(0x04f5b83b) /* 0.309990150 */, 18 }, - /* 4814 */ { MAD_F(0x04f61248) /* 0.310076028 */, 18 }, - /* 4815 */ { MAD_F(0x04f66c56) /* 0.310161913 */, 18 }, - - /* 4816 */ { MAD_F(0x04f6c666) /* 0.310247804 */, 18 }, - /* 4817 */ { MAD_F(0x04f72078) /* 0.310333700 */, 18 }, - /* 4818 */ { MAD_F(0x04f77a8b) /* 0.310419603 */, 18 }, - /* 4819 */ { MAD_F(0x04f7d4a0) /* 0.310505511 */, 18 }, - /* 4820 */ { MAD_F(0x04f82eb7) /* 0.310591426 */, 18 }, - /* 4821 */ { MAD_F(0x04f888cf) /* 0.310677346 */, 18 }, - /* 4822 */ { MAD_F(0x04f8e2e9) /* 0.310763272 */, 18 }, - /* 4823 */ { MAD_F(0x04f93d04) /* 0.310849205 */, 18 }, - /* 4824 */ { MAD_F(0x04f99721) /* 0.310935143 */, 18 }, - /* 4825 */ { MAD_F(0x04f9f13f) /* 0.311021087 */, 18 }, - /* 4826 */ { MAD_F(0x04fa4b5f) /* 0.311107037 */, 18 }, - /* 4827 */ { MAD_F(0x04faa581) /* 0.311192993 */, 18 }, - /* 4828 */ { MAD_F(0x04faffa4) /* 0.311278955 */, 18 }, - /* 4829 */ { MAD_F(0x04fb59c9) /* 0.311364923 */, 18 }, - /* 4830 */ { MAD_F(0x04fbb3ef) /* 0.311450897 */, 18 }, - /* 4831 */ { MAD_F(0x04fc0e17) /* 0.311536877 */, 18 }, - - /* 4832 */ { MAD_F(0x04fc6841) /* 0.311622862 */, 18 }, - /* 4833 */ { MAD_F(0x04fcc26c) /* 0.311708854 */, 18 }, - /* 4834 */ { MAD_F(0x04fd1c99) /* 0.311794851 */, 18 }, - /* 4835 */ { MAD_F(0x04fd76c7) /* 0.311880855 */, 18 }, - /* 4836 */ { MAD_F(0x04fdd0f7) /* 0.311966864 */, 18 }, - /* 4837 */ { MAD_F(0x04fe2b29) /* 0.312052880 */, 18 }, - /* 4838 */ { MAD_F(0x04fe855c) /* 0.312138901 */, 18 }, - /* 4839 */ { MAD_F(0x04fedf91) /* 0.312224928 */, 18 }, - /* 4840 */ { MAD_F(0x04ff39c7) /* 0.312310961 */, 18 }, - /* 4841 */ { MAD_F(0x04ff93ff) /* 0.312397000 */, 18 }, - /* 4842 */ { MAD_F(0x04ffee38) /* 0.312483045 */, 18 }, - /* 4843 */ { MAD_F(0x05004874) /* 0.312569096 */, 18 }, - /* 4844 */ { MAD_F(0x0500a2b0) /* 0.312655153 */, 18 }, - /* 4845 */ { MAD_F(0x0500fcef) /* 0.312741216 */, 18 }, - /* 4846 */ { MAD_F(0x0501572e) /* 0.312827284 */, 18 }, - /* 4847 */ { MAD_F(0x0501b170) /* 0.312913359 */, 18 }, - - /* 4848 */ { MAD_F(0x05020bb3) /* 0.312999439 */, 18 }, - /* 4849 */ { MAD_F(0x050265f8) /* 0.313085526 */, 18 }, - /* 4850 */ { MAD_F(0x0502c03e) /* 0.313171618 */, 18 }, - /* 4851 */ { MAD_F(0x05031a86) /* 0.313257716 */, 18 }, - /* 4852 */ { MAD_F(0x050374cf) /* 0.313343820 */, 18 }, - /* 4853 */ { MAD_F(0x0503cf1a) /* 0.313429931 */, 18 }, - /* 4854 */ { MAD_F(0x05042967) /* 0.313516047 */, 18 }, - /* 4855 */ { MAD_F(0x050483b5) /* 0.313602168 */, 18 }, - /* 4856 */ { MAD_F(0x0504de05) /* 0.313688296 */, 18 }, - /* 4857 */ { MAD_F(0x05053856) /* 0.313774430 */, 18 }, - /* 4858 */ { MAD_F(0x050592a9) /* 0.313860570 */, 18 }, - /* 4859 */ { MAD_F(0x0505ecfd) /* 0.313946715 */, 18 }, - /* 4860 */ { MAD_F(0x05064754) /* 0.314032867 */, 18 }, - /* 4861 */ { MAD_F(0x0506a1ab) /* 0.314119024 */, 18 }, - /* 4862 */ { MAD_F(0x0506fc04) /* 0.314205187 */, 18 }, - /* 4863 */ { MAD_F(0x0507565f) /* 0.314291357 */, 18 }, - - /* 4864 */ { MAD_F(0x0507b0bc) /* 0.314377532 */, 18 }, - /* 4865 */ { MAD_F(0x05080b1a) /* 0.314463713 */, 18 }, - /* 4866 */ { MAD_F(0x05086579) /* 0.314549900 */, 18 }, - /* 4867 */ { MAD_F(0x0508bfdb) /* 0.314636092 */, 18 }, - /* 4868 */ { MAD_F(0x05091a3d) /* 0.314722291 */, 18 }, - /* 4869 */ { MAD_F(0x050974a2) /* 0.314808496 */, 18 }, - /* 4870 */ { MAD_F(0x0509cf08) /* 0.314894706 */, 18 }, - /* 4871 */ { MAD_F(0x050a296f) /* 0.314980923 */, 18 }, - /* 4872 */ { MAD_F(0x050a83d8) /* 0.315067145 */, 18 }, - /* 4873 */ { MAD_F(0x050ade43) /* 0.315153373 */, 18 }, - /* 4874 */ { MAD_F(0x050b38af) /* 0.315239607 */, 18 }, - /* 4875 */ { MAD_F(0x050b931d) /* 0.315325847 */, 18 }, - /* 4876 */ { MAD_F(0x050bed8d) /* 0.315412093 */, 18 }, - /* 4877 */ { MAD_F(0x050c47fe) /* 0.315498345 */, 18 }, - /* 4878 */ { MAD_F(0x050ca271) /* 0.315584603 */, 18 }, - /* 4879 */ { MAD_F(0x050cfce5) /* 0.315670866 */, 18 }, - - /* 4880 */ { MAD_F(0x050d575b) /* 0.315757136 */, 18 }, - /* 4881 */ { MAD_F(0x050db1d2) /* 0.315843411 */, 18 }, - /* 4882 */ { MAD_F(0x050e0c4b) /* 0.315929693 */, 18 }, - /* 4883 */ { MAD_F(0x050e66c5) /* 0.316015980 */, 18 }, - /* 4884 */ { MAD_F(0x050ec141) /* 0.316102273 */, 18 }, - /* 4885 */ { MAD_F(0x050f1bbf) /* 0.316188572 */, 18 }, - /* 4886 */ { MAD_F(0x050f763e) /* 0.316274877 */, 18 }, - /* 4887 */ { MAD_F(0x050fd0bf) /* 0.316361187 */, 18 }, - /* 4888 */ { MAD_F(0x05102b42) /* 0.316447504 */, 18 }, - /* 4889 */ { MAD_F(0x051085c6) /* 0.316533826 */, 18 }, - /* 4890 */ { MAD_F(0x0510e04b) /* 0.316620155 */, 18 }, - /* 4891 */ { MAD_F(0x05113ad3) /* 0.316706489 */, 18 }, - /* 4892 */ { MAD_F(0x0511955b) /* 0.316792829 */, 18 }, - /* 4893 */ { MAD_F(0x0511efe6) /* 0.316879175 */, 18 }, - /* 4894 */ { MAD_F(0x05124a72) /* 0.316965527 */, 18 }, - /* 4895 */ { MAD_F(0x0512a4ff) /* 0.317051885 */, 18 }, - - /* 4896 */ { MAD_F(0x0512ff8e) /* 0.317138249 */, 18 }, - /* 4897 */ { MAD_F(0x05135a1f) /* 0.317224618 */, 18 }, - /* 4898 */ { MAD_F(0x0513b4b1) /* 0.317310994 */, 18 }, - /* 4899 */ { MAD_F(0x05140f45) /* 0.317397375 */, 18 }, - /* 4900 */ { MAD_F(0x051469da) /* 0.317483762 */, 18 }, - /* 4901 */ { MAD_F(0x0514c471) /* 0.317570155 */, 18 }, - /* 4902 */ { MAD_F(0x05151f0a) /* 0.317656554 */, 18 }, - /* 4903 */ { MAD_F(0x051579a4) /* 0.317742959 */, 18 }, - /* 4904 */ { MAD_F(0x0515d440) /* 0.317829370 */, 18 }, - /* 4905 */ { MAD_F(0x05162edd) /* 0.317915786 */, 18 }, - /* 4906 */ { MAD_F(0x0516897c) /* 0.318002209 */, 18 }, - /* 4907 */ { MAD_F(0x0516e41c) /* 0.318088637 */, 18 }, - /* 4908 */ { MAD_F(0x05173ebe) /* 0.318175071 */, 18 }, - /* 4909 */ { MAD_F(0x05179962) /* 0.318261511 */, 18 }, - /* 4910 */ { MAD_F(0x0517f407) /* 0.318347957 */, 18 }, - /* 4911 */ { MAD_F(0x05184eae) /* 0.318434409 */, 18 }, - - /* 4912 */ { MAD_F(0x0518a956) /* 0.318520867 */, 18 }, - /* 4913 */ { MAD_F(0x05190400) /* 0.318607330 */, 18 }, - /* 4914 */ { MAD_F(0x05195eab) /* 0.318693800 */, 18 }, - /* 4915 */ { MAD_F(0x0519b958) /* 0.318780275 */, 18 }, - /* 4916 */ { MAD_F(0x051a1407) /* 0.318866756 */, 18 }, - /* 4917 */ { MAD_F(0x051a6eb7) /* 0.318953243 */, 18 }, - /* 4918 */ { MAD_F(0x051ac969) /* 0.319039736 */, 18 }, - /* 4919 */ { MAD_F(0x051b241c) /* 0.319126235 */, 18 }, - /* 4920 */ { MAD_F(0x051b7ed1) /* 0.319212739 */, 18 }, - /* 4921 */ { MAD_F(0x051bd987) /* 0.319299250 */, 18 }, - /* 4922 */ { MAD_F(0x051c3440) /* 0.319385766 */, 18 }, - /* 4923 */ { MAD_F(0x051c8ef9) /* 0.319472288 */, 18 }, - /* 4924 */ { MAD_F(0x051ce9b4) /* 0.319558816 */, 18 }, - /* 4925 */ { MAD_F(0x051d4471) /* 0.319645350 */, 18 }, - /* 4926 */ { MAD_F(0x051d9f2f) /* 0.319731890 */, 18 }, - /* 4927 */ { MAD_F(0x051df9ef) /* 0.319818435 */, 18 }, - - /* 4928 */ { MAD_F(0x051e54b1) /* 0.319904987 */, 18 }, - /* 4929 */ { MAD_F(0x051eaf74) /* 0.319991544 */, 18 }, - /* 4930 */ { MAD_F(0x051f0a38) /* 0.320078107 */, 18 }, - /* 4931 */ { MAD_F(0x051f64ff) /* 0.320164676 */, 18 }, - /* 4932 */ { MAD_F(0x051fbfc6) /* 0.320251251 */, 18 }, - /* 4933 */ { MAD_F(0x05201a90) /* 0.320337832 */, 18 }, - /* 4934 */ { MAD_F(0x0520755b) /* 0.320424419 */, 18 }, - /* 4935 */ { MAD_F(0x0520d027) /* 0.320511011 */, 18 }, - /* 4936 */ { MAD_F(0x05212af5) /* 0.320597609 */, 18 }, - /* 4937 */ { MAD_F(0x052185c5) /* 0.320684213 */, 18 }, - /* 4938 */ { MAD_F(0x0521e096) /* 0.320770823 */, 18 }, - /* 4939 */ { MAD_F(0x05223b69) /* 0.320857439 */, 18 }, - /* 4940 */ { MAD_F(0x0522963d) /* 0.320944061 */, 18 }, - /* 4941 */ { MAD_F(0x0522f113) /* 0.321030688 */, 18 }, - /* 4942 */ { MAD_F(0x05234bea) /* 0.321117322 */, 18 }, - /* 4943 */ { MAD_F(0x0523a6c3) /* 0.321203961 */, 18 }, - - /* 4944 */ { MAD_F(0x0524019e) /* 0.321290606 */, 18 }, - /* 4945 */ { MAD_F(0x05245c7a) /* 0.321377257 */, 18 }, - /* 4946 */ { MAD_F(0x0524b758) /* 0.321463913 */, 18 }, - /* 4947 */ { MAD_F(0x05251237) /* 0.321550576 */, 18 }, - /* 4948 */ { MAD_F(0x05256d18) /* 0.321637244 */, 18 }, - /* 4949 */ { MAD_F(0x0525c7fb) /* 0.321723919 */, 18 }, - /* 4950 */ { MAD_F(0x052622df) /* 0.321810599 */, 18 }, - /* 4951 */ { MAD_F(0x05267dc4) /* 0.321897285 */, 18 }, - /* 4952 */ { MAD_F(0x0526d8ab) /* 0.321983976 */, 18 }, - /* 4953 */ { MAD_F(0x05273394) /* 0.322070674 */, 18 }, - /* 4954 */ { MAD_F(0x05278e7e) /* 0.322157377 */, 18 }, - /* 4955 */ { MAD_F(0x0527e96a) /* 0.322244087 */, 18 }, - /* 4956 */ { MAD_F(0x05284457) /* 0.322330802 */, 18 }, - /* 4957 */ { MAD_F(0x05289f46) /* 0.322417523 */, 18 }, - /* 4958 */ { MAD_F(0x0528fa37) /* 0.322504249 */, 18 }, - /* 4959 */ { MAD_F(0x05295529) /* 0.322590982 */, 18 }, - - /* 4960 */ { MAD_F(0x0529b01d) /* 0.322677720 */, 18 }, - /* 4961 */ { MAD_F(0x052a0b12) /* 0.322764465 */, 18 }, - /* 4962 */ { MAD_F(0x052a6609) /* 0.322851215 */, 18 }, - /* 4963 */ { MAD_F(0x052ac101) /* 0.322937971 */, 18 }, - /* 4964 */ { MAD_F(0x052b1bfb) /* 0.323024732 */, 18 }, - /* 4965 */ { MAD_F(0x052b76f7) /* 0.323111500 */, 18 }, - /* 4966 */ { MAD_F(0x052bd1f4) /* 0.323198273 */, 18 }, - /* 4967 */ { MAD_F(0x052c2cf2) /* 0.323285052 */, 18 }, - /* 4968 */ { MAD_F(0x052c87f2) /* 0.323371837 */, 18 }, - /* 4969 */ { MAD_F(0x052ce2f4) /* 0.323458628 */, 18 }, - /* 4970 */ { MAD_F(0x052d3df7) /* 0.323545425 */, 18 }, - /* 4971 */ { MAD_F(0x052d98fc) /* 0.323632227 */, 18 }, - /* 4972 */ { MAD_F(0x052df403) /* 0.323719036 */, 18 }, - /* 4973 */ { MAD_F(0x052e4f0b) /* 0.323805850 */, 18 }, - /* 4974 */ { MAD_F(0x052eaa14) /* 0.323892670 */, 18 }, - /* 4975 */ { MAD_F(0x052f051f) /* 0.323979496 */, 18 }, - - /* 4976 */ { MAD_F(0x052f602c) /* 0.324066327 */, 18 }, - /* 4977 */ { MAD_F(0x052fbb3a) /* 0.324153165 */, 18 }, - /* 4978 */ { MAD_F(0x0530164a) /* 0.324240008 */, 18 }, - /* 4979 */ { MAD_F(0x0530715b) /* 0.324326857 */, 18 }, - /* 4980 */ { MAD_F(0x0530cc6e) /* 0.324413712 */, 18 }, - /* 4981 */ { MAD_F(0x05312783) /* 0.324500572 */, 18 }, - /* 4982 */ { MAD_F(0x05318299) /* 0.324587439 */, 18 }, - /* 4983 */ { MAD_F(0x0531ddb0) /* 0.324674311 */, 18 }, - /* 4984 */ { MAD_F(0x053238ca) /* 0.324761189 */, 18 }, - /* 4985 */ { MAD_F(0x053293e4) /* 0.324848073 */, 18 }, - /* 4986 */ { MAD_F(0x0532ef01) /* 0.324934963 */, 18 }, - /* 4987 */ { MAD_F(0x05334a1e) /* 0.325021858 */, 18 }, - /* 4988 */ { MAD_F(0x0533a53e) /* 0.325108760 */, 18 }, - /* 4989 */ { MAD_F(0x0534005f) /* 0.325195667 */, 18 }, - /* 4990 */ { MAD_F(0x05345b81) /* 0.325282580 */, 18 }, - /* 4991 */ { MAD_F(0x0534b6a5) /* 0.325369498 */, 18 }, - - /* 4992 */ { MAD_F(0x053511cb) /* 0.325456423 */, 18 }, - /* 4993 */ { MAD_F(0x05356cf2) /* 0.325543353 */, 18 }, - /* 4994 */ { MAD_F(0x0535c81b) /* 0.325630290 */, 18 }, - /* 4995 */ { MAD_F(0x05362345) /* 0.325717232 */, 18 }, - /* 4996 */ { MAD_F(0x05367e71) /* 0.325804179 */, 18 }, - /* 4997 */ { MAD_F(0x0536d99f) /* 0.325891133 */, 18 }, - /* 4998 */ { MAD_F(0x053734ce) /* 0.325978092 */, 18 }, - /* 4999 */ { MAD_F(0x05378ffe) /* 0.326065057 */, 18 }, - /* 5000 */ { MAD_F(0x0537eb30) /* 0.326152028 */, 18 }, - /* 5001 */ { MAD_F(0x05384664) /* 0.326239005 */, 18 }, - /* 5002 */ { MAD_F(0x0538a199) /* 0.326325988 */, 18 }, - /* 5003 */ { MAD_F(0x0538fcd0) /* 0.326412976 */, 18 }, - /* 5004 */ { MAD_F(0x05395808) /* 0.326499970 */, 18 }, - /* 5005 */ { MAD_F(0x0539b342) /* 0.326586970 */, 18 }, - /* 5006 */ { MAD_F(0x053a0e7d) /* 0.326673976 */, 18 }, - /* 5007 */ { MAD_F(0x053a69ba) /* 0.326760988 */, 18 }, - - /* 5008 */ { MAD_F(0x053ac4f9) /* 0.326848005 */, 18 }, - /* 5009 */ { MAD_F(0x053b2039) /* 0.326935028 */, 18 }, - /* 5010 */ { MAD_F(0x053b7b7b) /* 0.327022057 */, 18 }, - /* 5011 */ { MAD_F(0x053bd6be) /* 0.327109092 */, 18 }, - /* 5012 */ { MAD_F(0x053c3203) /* 0.327196132 */, 18 }, - /* 5013 */ { MAD_F(0x053c8d49) /* 0.327283178 */, 18 }, - /* 5014 */ { MAD_F(0x053ce891) /* 0.327370231 */, 18 }, - /* 5015 */ { MAD_F(0x053d43da) /* 0.327457288 */, 18 }, - /* 5016 */ { MAD_F(0x053d9f25) /* 0.327544352 */, 18 }, - /* 5017 */ { MAD_F(0x053dfa72) /* 0.327631421 */, 18 }, - /* 5018 */ { MAD_F(0x053e55c0) /* 0.327718497 */, 18 }, - /* 5019 */ { MAD_F(0x053eb10f) /* 0.327805578 */, 18 }, - /* 5020 */ { MAD_F(0x053f0c61) /* 0.327892665 */, 18 }, - /* 5021 */ { MAD_F(0x053f67b3) /* 0.327979757 */, 18 }, - /* 5022 */ { MAD_F(0x053fc308) /* 0.328066855 */, 18 }, - /* 5023 */ { MAD_F(0x05401e5e) /* 0.328153960 */, 18 }, - - /* 5024 */ { MAD_F(0x054079b5) /* 0.328241070 */, 18 }, - /* 5025 */ { MAD_F(0x0540d50e) /* 0.328328185 */, 18 }, - /* 5026 */ { MAD_F(0x05413068) /* 0.328415307 */, 18 }, - /* 5027 */ { MAD_F(0x05418bc4) /* 0.328502434 */, 18 }, - /* 5028 */ { MAD_F(0x0541e722) /* 0.328589567 */, 18 }, - /* 5029 */ { MAD_F(0x05424281) /* 0.328676706 */, 18 }, - /* 5030 */ { MAD_F(0x05429de2) /* 0.328763850 */, 18 }, - /* 5031 */ { MAD_F(0x0542f944) /* 0.328851001 */, 18 }, - /* 5032 */ { MAD_F(0x054354a8) /* 0.328938157 */, 18 }, - /* 5033 */ { MAD_F(0x0543b00d) /* 0.329025319 */, 18 }, - /* 5034 */ { MAD_F(0x05440b74) /* 0.329112486 */, 18 }, - /* 5035 */ { MAD_F(0x054466dd) /* 0.329199660 */, 18 }, - /* 5036 */ { MAD_F(0x0544c247) /* 0.329286839 */, 18 }, - /* 5037 */ { MAD_F(0x05451db2) /* 0.329374024 */, 18 }, - /* 5038 */ { MAD_F(0x0545791f) /* 0.329461215 */, 18 }, - /* 5039 */ { MAD_F(0x0545d48e) /* 0.329548411 */, 18 }, - - /* 5040 */ { MAD_F(0x05462ffe) /* 0.329635614 */, 18 }, - /* 5041 */ { MAD_F(0x05468b70) /* 0.329722822 */, 18 }, - /* 5042 */ { MAD_F(0x0546e6e3) /* 0.329810036 */, 18 }, - /* 5043 */ { MAD_F(0x05474258) /* 0.329897255 */, 18 }, - /* 5044 */ { MAD_F(0x05479dce) /* 0.329984481 */, 18 }, - /* 5045 */ { MAD_F(0x0547f946) /* 0.330071712 */, 18 }, - /* 5046 */ { MAD_F(0x054854c0) /* 0.330158949 */, 18 }, - /* 5047 */ { MAD_F(0x0548b03b) /* 0.330246191 */, 18 }, - /* 5048 */ { MAD_F(0x05490bb7) /* 0.330333440 */, 18 }, - /* 5049 */ { MAD_F(0x05496735) /* 0.330420694 */, 18 }, - /* 5050 */ { MAD_F(0x0549c2b5) /* 0.330507954 */, 18 }, - /* 5051 */ { MAD_F(0x054a1e36) /* 0.330595220 */, 18 }, - /* 5052 */ { MAD_F(0x054a79b9) /* 0.330682491 */, 18 }, - /* 5053 */ { MAD_F(0x054ad53d) /* 0.330769768 */, 18 }, - /* 5054 */ { MAD_F(0x054b30c3) /* 0.330857051 */, 18 }, - /* 5055 */ { MAD_F(0x054b8c4b) /* 0.330944340 */, 18 }, - - /* 5056 */ { MAD_F(0x054be7d4) /* 0.331031635 */, 18 }, - /* 5057 */ { MAD_F(0x054c435e) /* 0.331118935 */, 18 }, - /* 5058 */ { MAD_F(0x054c9eea) /* 0.331206241 */, 18 }, - /* 5059 */ { MAD_F(0x054cfa78) /* 0.331293553 */, 18 }, - /* 5060 */ { MAD_F(0x054d5607) /* 0.331380870 */, 18 }, - /* 5061 */ { MAD_F(0x054db197) /* 0.331468193 */, 18 }, - /* 5062 */ { MAD_F(0x054e0d2a) /* 0.331555522 */, 18 }, - /* 5063 */ { MAD_F(0x054e68bd) /* 0.331642857 */, 18 }, - /* 5064 */ { MAD_F(0x054ec453) /* 0.331730198 */, 18 }, - /* 5065 */ { MAD_F(0x054f1fe9) /* 0.331817544 */, 18 }, - /* 5066 */ { MAD_F(0x054f7b82) /* 0.331904896 */, 18 }, - /* 5067 */ { MAD_F(0x054fd71c) /* 0.331992254 */, 18 }, - /* 5068 */ { MAD_F(0x055032b7) /* 0.332079617 */, 18 }, - /* 5069 */ { MAD_F(0x05508e54) /* 0.332166986 */, 18 }, - /* 5070 */ { MAD_F(0x0550e9f3) /* 0.332254361 */, 18 }, - /* 5071 */ { MAD_F(0x05514593) /* 0.332341742 */, 18 }, - - /* 5072 */ { MAD_F(0x0551a134) /* 0.332429129 */, 18 }, - /* 5073 */ { MAD_F(0x0551fcd8) /* 0.332516521 */, 18 }, - /* 5074 */ { MAD_F(0x0552587c) /* 0.332603919 */, 18 }, - /* 5075 */ { MAD_F(0x0552b423) /* 0.332691323 */, 18 }, - /* 5076 */ { MAD_F(0x05530fca) /* 0.332778732 */, 18 }, - /* 5077 */ { MAD_F(0x05536b74) /* 0.332866147 */, 18 }, - /* 5078 */ { MAD_F(0x0553c71f) /* 0.332953568 */, 18 }, - /* 5079 */ { MAD_F(0x055422cb) /* 0.333040995 */, 18 }, - /* 5080 */ { MAD_F(0x05547e79) /* 0.333128427 */, 18 }, - /* 5081 */ { MAD_F(0x0554da29) /* 0.333215865 */, 18 }, - /* 5082 */ { MAD_F(0x055535da) /* 0.333303309 */, 18 }, - /* 5083 */ { MAD_F(0x0555918c) /* 0.333390759 */, 18 }, - /* 5084 */ { MAD_F(0x0555ed40) /* 0.333478214 */, 18 }, - /* 5085 */ { MAD_F(0x055648f6) /* 0.333565675 */, 18 }, - /* 5086 */ { MAD_F(0x0556a4ad) /* 0.333653142 */, 18 }, - /* 5087 */ { MAD_F(0x05570066) /* 0.333740615 */, 18 }, - - /* 5088 */ { MAD_F(0x05575c20) /* 0.333828093 */, 18 }, - /* 5089 */ { MAD_F(0x0557b7dc) /* 0.333915577 */, 18 }, - /* 5090 */ { MAD_F(0x05581399) /* 0.334003067 */, 18 }, - /* 5091 */ { MAD_F(0x05586f58) /* 0.334090562 */, 18 }, - /* 5092 */ { MAD_F(0x0558cb19) /* 0.334178063 */, 18 }, - /* 5093 */ { MAD_F(0x055926db) /* 0.334265570 */, 18 }, - /* 5094 */ { MAD_F(0x0559829e) /* 0.334353083 */, 18 }, - /* 5095 */ { MAD_F(0x0559de63) /* 0.334440601 */, 18 }, - /* 5096 */ { MAD_F(0x055a3a2a) /* 0.334528126 */, 18 }, - /* 5097 */ { MAD_F(0x055a95f2) /* 0.334615655 */, 18 }, - /* 5098 */ { MAD_F(0x055af1bb) /* 0.334703191 */, 18 }, - /* 5099 */ { MAD_F(0x055b4d87) /* 0.334790732 */, 18 }, - /* 5100 */ { MAD_F(0x055ba953) /* 0.334878279 */, 18 }, - /* 5101 */ { MAD_F(0x055c0522) /* 0.334965832 */, 18 }, - /* 5102 */ { MAD_F(0x055c60f1) /* 0.335053391 */, 18 }, - /* 5103 */ { MAD_F(0x055cbcc3) /* 0.335140955 */, 18 }, - - /* 5104 */ { MAD_F(0x055d1896) /* 0.335228525 */, 18 }, - /* 5105 */ { MAD_F(0x055d746a) /* 0.335316100 */, 18 }, - /* 5106 */ { MAD_F(0x055dd040) /* 0.335403682 */, 18 }, - /* 5107 */ { MAD_F(0x055e2c17) /* 0.335491269 */, 18 }, - /* 5108 */ { MAD_F(0x055e87f0) /* 0.335578861 */, 18 }, - /* 5109 */ { MAD_F(0x055ee3cb) /* 0.335666460 */, 18 }, - /* 5110 */ { MAD_F(0x055f3fa7) /* 0.335754064 */, 18 }, - /* 5111 */ { MAD_F(0x055f9b85) /* 0.335841674 */, 18 }, - /* 5112 */ { MAD_F(0x055ff764) /* 0.335929290 */, 18 }, - /* 5113 */ { MAD_F(0x05605344) /* 0.336016911 */, 18 }, - /* 5114 */ { MAD_F(0x0560af27) /* 0.336104538 */, 18 }, - /* 5115 */ { MAD_F(0x05610b0a) /* 0.336192171 */, 18 }, - /* 5116 */ { MAD_F(0x056166f0) /* 0.336279809 */, 18 }, - /* 5117 */ { MAD_F(0x0561c2d7) /* 0.336367453 */, 18 }, - /* 5118 */ { MAD_F(0x05621ebf) /* 0.336455103 */, 18 }, - /* 5119 */ { MAD_F(0x05627aa9) /* 0.336542759 */, 18 }, - - /* 5120 */ { MAD_F(0x0562d694) /* 0.336630420 */, 18 }, - /* 5121 */ { MAD_F(0x05633281) /* 0.336718087 */, 18 }, - /* 5122 */ { MAD_F(0x05638e70) /* 0.336805760 */, 18 }, - /* 5123 */ { MAD_F(0x0563ea60) /* 0.336893439 */, 18 }, - /* 5124 */ { MAD_F(0x05644651) /* 0.336981123 */, 18 }, - /* 5125 */ { MAD_F(0x0564a244) /* 0.337068813 */, 18 }, - /* 5126 */ { MAD_F(0x0564fe39) /* 0.337156508 */, 18 }, - /* 5127 */ { MAD_F(0x05655a2f) /* 0.337244209 */, 18 }, - /* 5128 */ { MAD_F(0x0565b627) /* 0.337331916 */, 18 }, - /* 5129 */ { MAD_F(0x05661220) /* 0.337419629 */, 18 }, - /* 5130 */ { MAD_F(0x05666e1a) /* 0.337507347 */, 18 }, - /* 5131 */ { MAD_F(0x0566ca17) /* 0.337595071 */, 18 }, - /* 5132 */ { MAD_F(0x05672614) /* 0.337682801 */, 18 }, - /* 5133 */ { MAD_F(0x05678214) /* 0.337770537 */, 18 }, - /* 5134 */ { MAD_F(0x0567de15) /* 0.337858278 */, 18 }, - /* 5135 */ { MAD_F(0x05683a17) /* 0.337946025 */, 18 }, - - /* 5136 */ { MAD_F(0x0568961b) /* 0.338033777 */, 18 }, - /* 5137 */ { MAD_F(0x0568f220) /* 0.338121535 */, 18 }, - /* 5138 */ { MAD_F(0x05694e27) /* 0.338209299 */, 18 }, - /* 5139 */ { MAD_F(0x0569aa30) /* 0.338297069 */, 18 }, - /* 5140 */ { MAD_F(0x056a063a) /* 0.338384844 */, 18 }, - /* 5141 */ { MAD_F(0x056a6245) /* 0.338472625 */, 18 }, - /* 5142 */ { MAD_F(0x056abe52) /* 0.338560412 */, 18 }, - /* 5143 */ { MAD_F(0x056b1a61) /* 0.338648204 */, 18 }, - /* 5144 */ { MAD_F(0x056b7671) /* 0.338736002 */, 18 }, - /* 5145 */ { MAD_F(0x056bd283) /* 0.338823806 */, 18 }, - /* 5146 */ { MAD_F(0x056c2e96) /* 0.338911616 */, 18 }, - /* 5147 */ { MAD_F(0x056c8aab) /* 0.338999431 */, 18 }, - /* 5148 */ { MAD_F(0x056ce6c1) /* 0.339087252 */, 18 }, - /* 5149 */ { MAD_F(0x056d42d9) /* 0.339175078 */, 18 }, - /* 5150 */ { MAD_F(0x056d9ef2) /* 0.339262910 */, 18 }, - /* 5151 */ { MAD_F(0x056dfb0d) /* 0.339350748 */, 18 }, - - /* 5152 */ { MAD_F(0x056e5729) /* 0.339438592 */, 18 }, - /* 5153 */ { MAD_F(0x056eb347) /* 0.339526441 */, 18 }, - /* 5154 */ { MAD_F(0x056f0f66) /* 0.339614296 */, 18 }, - /* 5155 */ { MAD_F(0x056f6b87) /* 0.339702157 */, 18 }, - /* 5156 */ { MAD_F(0x056fc7aa) /* 0.339790023 */, 18 }, - /* 5157 */ { MAD_F(0x057023cd) /* 0.339877895 */, 18 }, - /* 5158 */ { MAD_F(0x05707ff3) /* 0.339965773 */, 18 }, - /* 5159 */ { MAD_F(0x0570dc1a) /* 0.340053656 */, 18 }, - /* 5160 */ { MAD_F(0x05713843) /* 0.340141545 */, 18 }, - /* 5161 */ { MAD_F(0x0571946d) /* 0.340229440 */, 18 }, - /* 5162 */ { MAD_F(0x0571f098) /* 0.340317340 */, 18 }, - /* 5163 */ { MAD_F(0x05724cc5) /* 0.340405246 */, 18 }, - /* 5164 */ { MAD_F(0x0572a8f4) /* 0.340493158 */, 18 }, - /* 5165 */ { MAD_F(0x05730524) /* 0.340581075 */, 18 }, - /* 5166 */ { MAD_F(0x05736156) /* 0.340668999 */, 18 }, - /* 5167 */ { MAD_F(0x0573bd89) /* 0.340756927 */, 18 }, - - /* 5168 */ { MAD_F(0x057419be) /* 0.340844862 */, 18 }, - /* 5169 */ { MAD_F(0x057475f4) /* 0.340932802 */, 18 }, - /* 5170 */ { MAD_F(0x0574d22c) /* 0.341020748 */, 18 }, - /* 5171 */ { MAD_F(0x05752e65) /* 0.341108699 */, 18 }, - /* 5172 */ { MAD_F(0x05758aa0) /* 0.341196656 */, 18 }, - /* 5173 */ { MAD_F(0x0575e6dc) /* 0.341284619 */, 18 }, - /* 5174 */ { MAD_F(0x0576431a) /* 0.341372587 */, 18 }, - /* 5175 */ { MAD_F(0x05769f59) /* 0.341460562 */, 18 }, - /* 5176 */ { MAD_F(0x0576fb9a) /* 0.341548541 */, 18 }, - /* 5177 */ { MAD_F(0x057757dd) /* 0.341636527 */, 18 }, - /* 5178 */ { MAD_F(0x0577b421) /* 0.341724518 */, 18 }, - /* 5179 */ { MAD_F(0x05781066) /* 0.341812515 */, 18 }, - /* 5180 */ { MAD_F(0x05786cad) /* 0.341900517 */, 18 }, - /* 5181 */ { MAD_F(0x0578c8f5) /* 0.341988525 */, 18 }, - /* 5182 */ { MAD_F(0x0579253f) /* 0.342076539 */, 18 }, - /* 5183 */ { MAD_F(0x0579818b) /* 0.342164558 */, 18 }, - - /* 5184 */ { MAD_F(0x0579ddd8) /* 0.342252584 */, 18 }, - /* 5185 */ { MAD_F(0x057a3a27) /* 0.342340614 */, 18 }, - /* 5186 */ { MAD_F(0x057a9677) /* 0.342428651 */, 18 }, - /* 5187 */ { MAD_F(0x057af2c8) /* 0.342516693 */, 18 }, - /* 5188 */ { MAD_F(0x057b4f1c) /* 0.342604741 */, 18 }, - /* 5189 */ { MAD_F(0x057bab70) /* 0.342692794 */, 18 }, - /* 5190 */ { MAD_F(0x057c07c6) /* 0.342780853 */, 18 }, - /* 5191 */ { MAD_F(0x057c641e) /* 0.342868918 */, 18 }, - /* 5192 */ { MAD_F(0x057cc077) /* 0.342956988 */, 18 }, - /* 5193 */ { MAD_F(0x057d1cd2) /* 0.343045064 */, 18 }, - /* 5194 */ { MAD_F(0x057d792e) /* 0.343133146 */, 18 }, - /* 5195 */ { MAD_F(0x057dd58c) /* 0.343221233 */, 18 }, - /* 5196 */ { MAD_F(0x057e31eb) /* 0.343309326 */, 18 }, - /* 5197 */ { MAD_F(0x057e8e4c) /* 0.343397425 */, 18 }, - /* 5198 */ { MAD_F(0x057eeaae) /* 0.343485529 */, 18 }, - /* 5199 */ { MAD_F(0x057f4712) /* 0.343573639 */, 18 }, - - /* 5200 */ { MAD_F(0x057fa378) /* 0.343661754 */, 18 }, - /* 5201 */ { MAD_F(0x057fffde) /* 0.343749876 */, 18 }, - /* 5202 */ { MAD_F(0x05805c47) /* 0.343838003 */, 18 }, - /* 5203 */ { MAD_F(0x0580b8b1) /* 0.343926135 */, 18 }, - /* 5204 */ { MAD_F(0x0581151c) /* 0.344014273 */, 18 }, - /* 5205 */ { MAD_F(0x05817189) /* 0.344102417 */, 18 }, - /* 5206 */ { MAD_F(0x0581cdf7) /* 0.344190566 */, 18 }, - /* 5207 */ { MAD_F(0x05822a67) /* 0.344278722 */, 18 }, - /* 5208 */ { MAD_F(0x058286d9) /* 0.344366882 */, 18 }, - /* 5209 */ { MAD_F(0x0582e34c) /* 0.344455049 */, 18 }, - /* 5210 */ { MAD_F(0x05833fc0) /* 0.344543221 */, 18 }, - /* 5211 */ { MAD_F(0x05839c36) /* 0.344631398 */, 18 }, - /* 5212 */ { MAD_F(0x0583f8ae) /* 0.344719582 */, 18 }, - /* 5213 */ { MAD_F(0x05845527) /* 0.344807771 */, 18 }, - /* 5214 */ { MAD_F(0x0584b1a1) /* 0.344895965 */, 18 }, - /* 5215 */ { MAD_F(0x05850e1e) /* 0.344984165 */, 18 }, - - /* 5216 */ { MAD_F(0x05856a9b) /* 0.345072371 */, 18 }, - /* 5217 */ { MAD_F(0x0585c71a) /* 0.345160583 */, 18 }, - /* 5218 */ { MAD_F(0x0586239b) /* 0.345248800 */, 18 }, - /* 5219 */ { MAD_F(0x0586801d) /* 0.345337023 */, 18 }, - /* 5220 */ { MAD_F(0x0586dca1) /* 0.345425251 */, 18 }, - /* 5221 */ { MAD_F(0x05873926) /* 0.345513485 */, 18 }, - /* 5222 */ { MAD_F(0x058795ac) /* 0.345601725 */, 18 }, - /* 5223 */ { MAD_F(0x0587f235) /* 0.345689970 */, 18 }, - /* 5224 */ { MAD_F(0x05884ebe) /* 0.345778221 */, 18 }, - /* 5225 */ { MAD_F(0x0588ab49) /* 0.345866478 */, 18 }, - /* 5226 */ { MAD_F(0x058907d6) /* 0.345954740 */, 18 }, - /* 5227 */ { MAD_F(0x05896464) /* 0.346043008 */, 18 }, - /* 5228 */ { MAD_F(0x0589c0f4) /* 0.346131281 */, 18 }, - /* 5229 */ { MAD_F(0x058a1d85) /* 0.346219560 */, 18 }, - /* 5230 */ { MAD_F(0x058a7a18) /* 0.346307845 */, 18 }, - /* 5231 */ { MAD_F(0x058ad6ac) /* 0.346396135 */, 18 }, - - /* 5232 */ { MAD_F(0x058b3342) /* 0.346484431 */, 18 }, - /* 5233 */ { MAD_F(0x058b8fd9) /* 0.346572733 */, 18 }, - /* 5234 */ { MAD_F(0x058bec72) /* 0.346661040 */, 18 }, - /* 5235 */ { MAD_F(0x058c490c) /* 0.346749353 */, 18 }, - /* 5236 */ { MAD_F(0x058ca5a8) /* 0.346837671 */, 18 }, - /* 5237 */ { MAD_F(0x058d0246) /* 0.346925996 */, 18 }, - /* 5238 */ { MAD_F(0x058d5ee4) /* 0.347014325 */, 18 }, - /* 5239 */ { MAD_F(0x058dbb85) /* 0.347102661 */, 18 }, - /* 5240 */ { MAD_F(0x058e1827) /* 0.347191002 */, 18 }, - /* 5241 */ { MAD_F(0x058e74ca) /* 0.347279348 */, 18 }, - /* 5242 */ { MAD_F(0x058ed16f) /* 0.347367700 */, 18 }, - /* 5243 */ { MAD_F(0x058f2e15) /* 0.347456058 */, 18 }, - /* 5244 */ { MAD_F(0x058f8abd) /* 0.347544422 */, 18 }, - /* 5245 */ { MAD_F(0x058fe766) /* 0.347632791 */, 18 }, - /* 5246 */ { MAD_F(0x05904411) /* 0.347721165 */, 18 }, - /* 5247 */ { MAD_F(0x0590a0be) /* 0.347809546 */, 18 }, - - /* 5248 */ { MAD_F(0x0590fd6c) /* 0.347897931 */, 18 }, - /* 5249 */ { MAD_F(0x05915a1b) /* 0.347986323 */, 18 }, - /* 5250 */ { MAD_F(0x0591b6cc) /* 0.348074720 */, 18 }, - /* 5251 */ { MAD_F(0x0592137e) /* 0.348163123 */, 18 }, - /* 5252 */ { MAD_F(0x05927032) /* 0.348251531 */, 18 }, - /* 5253 */ { MAD_F(0x0592cce8) /* 0.348339945 */, 18 }, - /* 5254 */ { MAD_F(0x0593299f) /* 0.348428365 */, 18 }, - /* 5255 */ { MAD_F(0x05938657) /* 0.348516790 */, 18 }, - /* 5256 */ { MAD_F(0x0593e311) /* 0.348605221 */, 18 }, - /* 5257 */ { MAD_F(0x05943fcd) /* 0.348693657 */, 18 }, - /* 5258 */ { MAD_F(0x05949c8a) /* 0.348782099 */, 18 }, - /* 5259 */ { MAD_F(0x0594f948) /* 0.348870547 */, 18 }, - /* 5260 */ { MAD_F(0x05955608) /* 0.348959000 */, 18 }, - /* 5261 */ { MAD_F(0x0595b2ca) /* 0.349047459 */, 18 }, - /* 5262 */ { MAD_F(0x05960f8c) /* 0.349135923 */, 18 }, - /* 5263 */ { MAD_F(0x05966c51) /* 0.349224393 */, 18 }, - - /* 5264 */ { MAD_F(0x0596c917) /* 0.349312869 */, 18 }, - /* 5265 */ { MAD_F(0x059725de) /* 0.349401350 */, 18 }, - /* 5266 */ { MAD_F(0x059782a7) /* 0.349489837 */, 18 }, - /* 5267 */ { MAD_F(0x0597df72) /* 0.349578329 */, 18 }, - /* 5268 */ { MAD_F(0x05983c3e) /* 0.349666827 */, 18 }, - /* 5269 */ { MAD_F(0x0598990c) /* 0.349755331 */, 18 }, - /* 5270 */ { MAD_F(0x0598f5db) /* 0.349843840 */, 18 }, - /* 5271 */ { MAD_F(0x059952ab) /* 0.349932355 */, 18 }, - /* 5272 */ { MAD_F(0x0599af7d) /* 0.350020876 */, 18 }, - /* 5273 */ { MAD_F(0x059a0c51) /* 0.350109402 */, 18 }, - /* 5274 */ { MAD_F(0x059a6926) /* 0.350197933 */, 18 }, - /* 5275 */ { MAD_F(0x059ac5fc) /* 0.350286470 */, 18 }, - /* 5276 */ { MAD_F(0x059b22d4) /* 0.350375013 */, 18 }, - /* 5277 */ { MAD_F(0x059b7fae) /* 0.350463562 */, 18 }, - /* 5278 */ { MAD_F(0x059bdc89) /* 0.350552116 */, 18 }, - /* 5279 */ { MAD_F(0x059c3965) /* 0.350640675 */, 18 }, - - /* 5280 */ { MAD_F(0x059c9643) /* 0.350729240 */, 18 }, - /* 5281 */ { MAD_F(0x059cf323) /* 0.350817811 */, 18 }, - /* 5282 */ { MAD_F(0x059d5004) /* 0.350906388 */, 18 }, - /* 5283 */ { MAD_F(0x059dace6) /* 0.350994970 */, 18 }, - /* 5284 */ { MAD_F(0x059e09cb) /* 0.351083557 */, 18 }, - /* 5285 */ { MAD_F(0x059e66b0) /* 0.351172150 */, 18 }, - /* 5286 */ { MAD_F(0x059ec397) /* 0.351260749 */, 18 }, - /* 5287 */ { MAD_F(0x059f2080) /* 0.351349353 */, 18 }, - /* 5288 */ { MAD_F(0x059f7d6a) /* 0.351437963 */, 18 }, - /* 5289 */ { MAD_F(0x059fda55) /* 0.351526579 */, 18 }, - /* 5290 */ { MAD_F(0x05a03742) /* 0.351615200 */, 18 }, - /* 5291 */ { MAD_F(0x05a09431) /* 0.351703827 */, 18 }, - /* 5292 */ { MAD_F(0x05a0f121) /* 0.351792459 */, 18 }, - /* 5293 */ { MAD_F(0x05a14e12) /* 0.351881097 */, 18 }, - /* 5294 */ { MAD_F(0x05a1ab05) /* 0.351969740 */, 18 }, - /* 5295 */ { MAD_F(0x05a207fa) /* 0.352058389 */, 18 }, - - /* 5296 */ { MAD_F(0x05a264f0) /* 0.352147044 */, 18 }, - /* 5297 */ { MAD_F(0x05a2c1e7) /* 0.352235704 */, 18 }, - /* 5298 */ { MAD_F(0x05a31ee1) /* 0.352324369 */, 18 }, - /* 5299 */ { MAD_F(0x05a37bdb) /* 0.352413041 */, 18 }, - /* 5300 */ { MAD_F(0x05a3d8d7) /* 0.352501718 */, 18 }, - /* 5301 */ { MAD_F(0x05a435d5) /* 0.352590400 */, 18 }, - /* 5302 */ { MAD_F(0x05a492d4) /* 0.352679088 */, 18 }, - /* 5303 */ { MAD_F(0x05a4efd4) /* 0.352767782 */, 18 }, - /* 5304 */ { MAD_F(0x05a54cd6) /* 0.352856481 */, 18 }, - /* 5305 */ { MAD_F(0x05a5a9da) /* 0.352945186 */, 18 }, - /* 5306 */ { MAD_F(0x05a606df) /* 0.353033896 */, 18 }, - /* 5307 */ { MAD_F(0x05a663e5) /* 0.353122612 */, 18 }, - /* 5308 */ { MAD_F(0x05a6c0ed) /* 0.353211333 */, 18 }, - /* 5309 */ { MAD_F(0x05a71df7) /* 0.353300061 */, 18 }, - /* 5310 */ { MAD_F(0x05a77b02) /* 0.353388793 */, 18 }, - /* 5311 */ { MAD_F(0x05a7d80e) /* 0.353477531 */, 18 }, - - /* 5312 */ { MAD_F(0x05a8351c) /* 0.353566275 */, 18 }, - /* 5313 */ { MAD_F(0x05a8922c) /* 0.353655024 */, 18 }, - /* 5314 */ { MAD_F(0x05a8ef3c) /* 0.353743779 */, 18 }, - /* 5315 */ { MAD_F(0x05a94c4f) /* 0.353832540 */, 18 }, - /* 5316 */ { MAD_F(0x05a9a963) /* 0.353921306 */, 18 }, - /* 5317 */ { MAD_F(0x05aa0678) /* 0.354010077 */, 18 }, - /* 5318 */ { MAD_F(0x05aa638f) /* 0.354098855 */, 18 }, - /* 5319 */ { MAD_F(0x05aac0a8) /* 0.354187637 */, 18 }, - /* 5320 */ { MAD_F(0x05ab1dc2) /* 0.354276426 */, 18 }, - /* 5321 */ { MAD_F(0x05ab7add) /* 0.354365220 */, 18 }, - /* 5322 */ { MAD_F(0x05abd7fa) /* 0.354454019 */, 18 }, - /* 5323 */ { MAD_F(0x05ac3518) /* 0.354542824 */, 18 }, - /* 5324 */ { MAD_F(0x05ac9238) /* 0.354631635 */, 18 }, - /* 5325 */ { MAD_F(0x05acef5a) /* 0.354720451 */, 18 }, - /* 5326 */ { MAD_F(0x05ad4c7d) /* 0.354809272 */, 18 }, - /* 5327 */ { MAD_F(0x05ada9a1) /* 0.354898100 */, 18 }, - - /* 5328 */ { MAD_F(0x05ae06c7) /* 0.354986932 */, 18 }, - /* 5329 */ { MAD_F(0x05ae63ee) /* 0.355075771 */, 18 }, - /* 5330 */ { MAD_F(0x05aec117) /* 0.355164615 */, 18 }, - /* 5331 */ { MAD_F(0x05af1e41) /* 0.355253464 */, 18 }, - /* 5332 */ { MAD_F(0x05af7b6d) /* 0.355342319 */, 18 }, - /* 5333 */ { MAD_F(0x05afd89b) /* 0.355431180 */, 18 }, - /* 5334 */ { MAD_F(0x05b035c9) /* 0.355520046 */, 18 }, - /* 5335 */ { MAD_F(0x05b092fa) /* 0.355608917 */, 18 }, - /* 5336 */ { MAD_F(0x05b0f02b) /* 0.355697795 */, 18 }, - /* 5337 */ { MAD_F(0x05b14d5f) /* 0.355786677 */, 18 }, - /* 5338 */ { MAD_F(0x05b1aa94) /* 0.355875566 */, 18 }, - /* 5339 */ { MAD_F(0x05b207ca) /* 0.355964460 */, 18 }, - /* 5340 */ { MAD_F(0x05b26502) /* 0.356053359 */, 18 }, - /* 5341 */ { MAD_F(0x05b2c23b) /* 0.356142264 */, 18 }, - /* 5342 */ { MAD_F(0x05b31f76) /* 0.356231175 */, 18 }, - /* 5343 */ { MAD_F(0x05b37cb2) /* 0.356320091 */, 18 }, - - /* 5344 */ { MAD_F(0x05b3d9f0) /* 0.356409012 */, 18 }, - /* 5345 */ { MAD_F(0x05b4372f) /* 0.356497940 */, 18 }, - /* 5346 */ { MAD_F(0x05b4946f) /* 0.356586872 */, 18 }, - /* 5347 */ { MAD_F(0x05b4f1b2) /* 0.356675811 */, 18 }, - /* 5348 */ { MAD_F(0x05b54ef5) /* 0.356764754 */, 18 }, - /* 5349 */ { MAD_F(0x05b5ac3a) /* 0.356853704 */, 18 }, - /* 5350 */ { MAD_F(0x05b60981) /* 0.356942659 */, 18 }, - /* 5351 */ { MAD_F(0x05b666c9) /* 0.357031619 */, 18 }, - /* 5352 */ { MAD_F(0x05b6c413) /* 0.357120585 */, 18 }, - /* 5353 */ { MAD_F(0x05b7215e) /* 0.357209557 */, 18 }, - /* 5354 */ { MAD_F(0x05b77eab) /* 0.357298534 */, 18 }, - /* 5355 */ { MAD_F(0x05b7dbf9) /* 0.357387516 */, 18 }, - /* 5356 */ { MAD_F(0x05b83948) /* 0.357476504 */, 18 }, - /* 5357 */ { MAD_F(0x05b89699) /* 0.357565498 */, 18 }, - /* 5358 */ { MAD_F(0x05b8f3ec) /* 0.357654497 */, 18 }, - /* 5359 */ { MAD_F(0x05b95140) /* 0.357743502 */, 18 }, - - /* 5360 */ { MAD_F(0x05b9ae95) /* 0.357832512 */, 18 }, - /* 5361 */ { MAD_F(0x05ba0bec) /* 0.357921528 */, 18 }, - /* 5362 */ { MAD_F(0x05ba6945) /* 0.358010550 */, 18 }, - /* 5363 */ { MAD_F(0x05bac69f) /* 0.358099576 */, 18 }, - /* 5364 */ { MAD_F(0x05bb23fa) /* 0.358188609 */, 18 }, - /* 5365 */ { MAD_F(0x05bb8157) /* 0.358277647 */, 18 }, - /* 5366 */ { MAD_F(0x05bbdeb6) /* 0.358366690 */, 18 }, - /* 5367 */ { MAD_F(0x05bc3c16) /* 0.358455739 */, 18 }, - /* 5368 */ { MAD_F(0x05bc9977) /* 0.358544794 */, 18 }, - /* 5369 */ { MAD_F(0x05bcf6da) /* 0.358633854 */, 18 }, - /* 5370 */ { MAD_F(0x05bd543e) /* 0.358722920 */, 18 }, - /* 5371 */ { MAD_F(0x05bdb1a4) /* 0.358811991 */, 18 }, - /* 5372 */ { MAD_F(0x05be0f0b) /* 0.358901067 */, 18 }, - /* 5373 */ { MAD_F(0x05be6c74) /* 0.358990150 */, 18 }, - /* 5374 */ { MAD_F(0x05bec9df) /* 0.359079237 */, 18 }, - /* 5375 */ { MAD_F(0x05bf274a) /* 0.359168331 */, 18 }, - - /* 5376 */ { MAD_F(0x05bf84b8) /* 0.359257429 */, 18 }, - /* 5377 */ { MAD_F(0x05bfe226) /* 0.359346534 */, 18 }, - /* 5378 */ { MAD_F(0x05c03f97) /* 0.359435644 */, 18 }, - /* 5379 */ { MAD_F(0x05c09d08) /* 0.359524759 */, 18 }, - /* 5380 */ { MAD_F(0x05c0fa7c) /* 0.359613880 */, 18 }, - /* 5381 */ { MAD_F(0x05c157f0) /* 0.359703006 */, 18 }, - /* 5382 */ { MAD_F(0x05c1b566) /* 0.359792138 */, 18 }, - /* 5383 */ { MAD_F(0x05c212de) /* 0.359881276 */, 18 }, - /* 5384 */ { MAD_F(0x05c27057) /* 0.359970419 */, 18 }, - /* 5385 */ { MAD_F(0x05c2cdd2) /* 0.360059567 */, 18 }, - /* 5386 */ { MAD_F(0x05c32b4e) /* 0.360148721 */, 18 }, - /* 5387 */ { MAD_F(0x05c388cb) /* 0.360237881 */, 18 }, - /* 5388 */ { MAD_F(0x05c3e64b) /* 0.360327046 */, 18 }, - /* 5389 */ { MAD_F(0x05c443cb) /* 0.360416216 */, 18 }, - /* 5390 */ { MAD_F(0x05c4a14d) /* 0.360505392 */, 18 }, - /* 5391 */ { MAD_F(0x05c4fed1) /* 0.360594574 */, 18 }, - - /* 5392 */ { MAD_F(0x05c55c56) /* 0.360683761 */, 18 }, - /* 5393 */ { MAD_F(0x05c5b9dc) /* 0.360772953 */, 18 }, - /* 5394 */ { MAD_F(0x05c61764) /* 0.360862152 */, 18 }, - /* 5395 */ { MAD_F(0x05c674ed) /* 0.360951355 */, 18 }, - /* 5396 */ { MAD_F(0x05c6d278) /* 0.361040564 */, 18 }, - /* 5397 */ { MAD_F(0x05c73005) /* 0.361129779 */, 18 }, - /* 5398 */ { MAD_F(0x05c78d93) /* 0.361218999 */, 18 }, - /* 5399 */ { MAD_F(0x05c7eb22) /* 0.361308225 */, 18 }, - /* 5400 */ { MAD_F(0x05c848b3) /* 0.361397456 */, 18 }, - /* 5401 */ { MAD_F(0x05c8a645) /* 0.361486693 */, 18 }, - /* 5402 */ { MAD_F(0x05c903d9) /* 0.361575935 */, 18 }, - /* 5403 */ { MAD_F(0x05c9616e) /* 0.361665183 */, 18 }, - /* 5404 */ { MAD_F(0x05c9bf05) /* 0.361754436 */, 18 }, - /* 5405 */ { MAD_F(0x05ca1c9d) /* 0.361843695 */, 18 }, - /* 5406 */ { MAD_F(0x05ca7a37) /* 0.361932959 */, 18 }, - /* 5407 */ { MAD_F(0x05cad7d2) /* 0.362022229 */, 18 }, - - /* 5408 */ { MAD_F(0x05cb356e) /* 0.362111504 */, 18 }, - /* 5409 */ { MAD_F(0x05cb930d) /* 0.362200785 */, 18 }, - /* 5410 */ { MAD_F(0x05cbf0ac) /* 0.362290071 */, 18 }, - /* 5411 */ { MAD_F(0x05cc4e4d) /* 0.362379362 */, 18 }, - /* 5412 */ { MAD_F(0x05ccabf0) /* 0.362468660 */, 18 }, - /* 5413 */ { MAD_F(0x05cd0994) /* 0.362557962 */, 18 }, - /* 5414 */ { MAD_F(0x05cd6739) /* 0.362647271 */, 18 }, - /* 5415 */ { MAD_F(0x05cdc4e0) /* 0.362736584 */, 18 }, - /* 5416 */ { MAD_F(0x05ce2289) /* 0.362825904 */, 18 }, - /* 5417 */ { MAD_F(0x05ce8033) /* 0.362915228 */, 18 }, - /* 5418 */ { MAD_F(0x05ceddde) /* 0.363004559 */, 18 }, - /* 5419 */ { MAD_F(0x05cf3b8b) /* 0.363093894 */, 18 }, - /* 5420 */ { MAD_F(0x05cf9939) /* 0.363183236 */, 18 }, - /* 5421 */ { MAD_F(0x05cff6e9) /* 0.363272582 */, 18 }, - /* 5422 */ { MAD_F(0x05d0549a) /* 0.363361935 */, 18 }, - /* 5423 */ { MAD_F(0x05d0b24d) /* 0.363451292 */, 18 }, - - /* 5424 */ { MAD_F(0x05d11001) /* 0.363540655 */, 18 }, - /* 5425 */ { MAD_F(0x05d16db7) /* 0.363630024 */, 18 }, - /* 5426 */ { MAD_F(0x05d1cb6e) /* 0.363719398 */, 18 }, - /* 5427 */ { MAD_F(0x05d22927) /* 0.363808778 */, 18 }, - /* 5428 */ { MAD_F(0x05d286e1) /* 0.363898163 */, 18 }, - /* 5429 */ { MAD_F(0x05d2e49d) /* 0.363987554 */, 18 }, - /* 5430 */ { MAD_F(0x05d3425a) /* 0.364076950 */, 18 }, - /* 5431 */ { MAD_F(0x05d3a018) /* 0.364166352 */, 18 }, - /* 5432 */ { MAD_F(0x05d3fdd8) /* 0.364255759 */, 18 }, - /* 5433 */ { MAD_F(0x05d45b9a) /* 0.364345171 */, 18 }, - /* 5434 */ { MAD_F(0x05d4b95d) /* 0.364434589 */, 18 }, - /* 5435 */ { MAD_F(0x05d51721) /* 0.364524013 */, 18 }, - /* 5436 */ { MAD_F(0x05d574e7) /* 0.364613442 */, 18 }, - /* 5437 */ { MAD_F(0x05d5d2af) /* 0.364702877 */, 18 }, - /* 5438 */ { MAD_F(0x05d63078) /* 0.364792317 */, 18 }, - /* 5439 */ { MAD_F(0x05d68e42) /* 0.364881762 */, 18 }, - - /* 5440 */ { MAD_F(0x05d6ec0e) /* 0.364971213 */, 18 }, - /* 5441 */ { MAD_F(0x05d749db) /* 0.365060669 */, 18 }, - /* 5442 */ { MAD_F(0x05d7a7aa) /* 0.365150131 */, 18 }, - /* 5443 */ { MAD_F(0x05d8057a) /* 0.365239599 */, 18 }, - /* 5444 */ { MAD_F(0x05d8634c) /* 0.365329072 */, 18 }, - /* 5445 */ { MAD_F(0x05d8c11f) /* 0.365418550 */, 18 }, - /* 5446 */ { MAD_F(0x05d91ef4) /* 0.365508034 */, 18 }, - /* 5447 */ { MAD_F(0x05d97cca) /* 0.365597523 */, 18 }, - /* 5448 */ { MAD_F(0x05d9daa1) /* 0.365687018 */, 18 }, - /* 5449 */ { MAD_F(0x05da387a) /* 0.365776518 */, 18 }, - /* 5450 */ { MAD_F(0x05da9655) /* 0.365866024 */, 18 }, - /* 5451 */ { MAD_F(0x05daf431) /* 0.365955536 */, 18 }, - /* 5452 */ { MAD_F(0x05db520e) /* 0.366045052 */, 18 }, - /* 5453 */ { MAD_F(0x05dbafed) /* 0.366134574 */, 18 }, - /* 5454 */ { MAD_F(0x05dc0dce) /* 0.366224102 */, 18 }, - /* 5455 */ { MAD_F(0x05dc6baf) /* 0.366313635 */, 18 }, - - /* 5456 */ { MAD_F(0x05dcc993) /* 0.366403174 */, 18 }, - /* 5457 */ { MAD_F(0x05dd2778) /* 0.366492718 */, 18 }, - /* 5458 */ { MAD_F(0x05dd855e) /* 0.366582267 */, 18 }, - /* 5459 */ { MAD_F(0x05dde346) /* 0.366671822 */, 18 }, - /* 5460 */ { MAD_F(0x05de412f) /* 0.366761383 */, 18 }, - /* 5461 */ { MAD_F(0x05de9f1a) /* 0.366850949 */, 18 }, - /* 5462 */ { MAD_F(0x05defd06) /* 0.366940520 */, 18 }, - /* 5463 */ { MAD_F(0x05df5af3) /* 0.367030097 */, 18 }, - /* 5464 */ { MAD_F(0x05dfb8e2) /* 0.367119680 */, 18 }, - /* 5465 */ { MAD_F(0x05e016d3) /* 0.367209267 */, 18 }, - /* 5466 */ { MAD_F(0x05e074c5) /* 0.367298861 */, 18 }, - /* 5467 */ { MAD_F(0x05e0d2b8) /* 0.367388459 */, 18 }, - /* 5468 */ { MAD_F(0x05e130ad) /* 0.367478064 */, 18 }, - /* 5469 */ { MAD_F(0x05e18ea4) /* 0.367567673 */, 18 }, - /* 5470 */ { MAD_F(0x05e1ec9c) /* 0.367657288 */, 18 }, - /* 5471 */ { MAD_F(0x05e24a95) /* 0.367746909 */, 18 }, - - /* 5472 */ { MAD_F(0x05e2a890) /* 0.367836535 */, 18 }, - /* 5473 */ { MAD_F(0x05e3068c) /* 0.367926167 */, 18 }, - /* 5474 */ { MAD_F(0x05e3648a) /* 0.368015804 */, 18 }, - /* 5475 */ { MAD_F(0x05e3c289) /* 0.368105446 */, 18 }, - /* 5476 */ { MAD_F(0x05e4208a) /* 0.368195094 */, 18 }, - /* 5477 */ { MAD_F(0x05e47e8c) /* 0.368284747 */, 18 }, - /* 5478 */ { MAD_F(0x05e4dc8f) /* 0.368374406 */, 18 }, - /* 5479 */ { MAD_F(0x05e53a94) /* 0.368464070 */, 18 }, - /* 5480 */ { MAD_F(0x05e5989b) /* 0.368553740 */, 18 }, - /* 5481 */ { MAD_F(0x05e5f6a3) /* 0.368643415 */, 18 }, - /* 5482 */ { MAD_F(0x05e654ac) /* 0.368733096 */, 18 }, - /* 5483 */ { MAD_F(0x05e6b2b7) /* 0.368822782 */, 18 }, - /* 5484 */ { MAD_F(0x05e710c4) /* 0.368912473 */, 18 }, - /* 5485 */ { MAD_F(0x05e76ed2) /* 0.369002170 */, 18 }, - /* 5486 */ { MAD_F(0x05e7cce1) /* 0.369091873 */, 18 }, - /* 5487 */ { MAD_F(0x05e82af2) /* 0.369181581 */, 18 }, - - /* 5488 */ { MAD_F(0x05e88904) /* 0.369271294 */, 18 }, - /* 5489 */ { MAD_F(0x05e8e718) /* 0.369361013 */, 18 }, - /* 5490 */ { MAD_F(0x05e9452d) /* 0.369450737 */, 18 }, - /* 5491 */ { MAD_F(0x05e9a343) /* 0.369540467 */, 18 }, - /* 5492 */ { MAD_F(0x05ea015c) /* 0.369630202 */, 18 }, - /* 5493 */ { MAD_F(0x05ea5f75) /* 0.369719942 */, 18 }, - /* 5494 */ { MAD_F(0x05eabd90) /* 0.369809688 */, 18 }, - /* 5495 */ { MAD_F(0x05eb1bad) /* 0.369899440 */, 18 }, - /* 5496 */ { MAD_F(0x05eb79cb) /* 0.369989197 */, 18 }, - /* 5497 */ { MAD_F(0x05ebd7ea) /* 0.370078959 */, 18 }, - /* 5498 */ { MAD_F(0x05ec360b) /* 0.370168727 */, 18 }, - /* 5499 */ { MAD_F(0x05ec942d) /* 0.370258500 */, 18 }, - /* 5500 */ { MAD_F(0x05ecf251) /* 0.370348279 */, 18 }, - /* 5501 */ { MAD_F(0x05ed5076) /* 0.370438063 */, 18 }, - /* 5502 */ { MAD_F(0x05edae9d) /* 0.370527853 */, 18 }, - /* 5503 */ { MAD_F(0x05ee0cc5) /* 0.370617648 */, 18 }, - - /* 5504 */ { MAD_F(0x05ee6aef) /* 0.370707448 */, 18 }, - /* 5505 */ { MAD_F(0x05eec91a) /* 0.370797254 */, 18 }, - /* 5506 */ { MAD_F(0x05ef2746) /* 0.370887065 */, 18 }, - /* 5507 */ { MAD_F(0x05ef8574) /* 0.370976882 */, 18 }, - /* 5508 */ { MAD_F(0x05efe3a4) /* 0.371066704 */, 18 }, - /* 5509 */ { MAD_F(0x05f041d5) /* 0.371156532 */, 18 }, - /* 5510 */ { MAD_F(0x05f0a007) /* 0.371246365 */, 18 }, - /* 5511 */ { MAD_F(0x05f0fe3b) /* 0.371336203 */, 18 }, - /* 5512 */ { MAD_F(0x05f15c70) /* 0.371426047 */, 18 }, - /* 5513 */ { MAD_F(0x05f1baa7) /* 0.371515897 */, 18 }, - /* 5514 */ { MAD_F(0x05f218df) /* 0.371605751 */, 18 }, - /* 5515 */ { MAD_F(0x05f27719) /* 0.371695612 */, 18 }, - /* 5516 */ { MAD_F(0x05f2d554) /* 0.371785477 */, 18 }, - /* 5517 */ { MAD_F(0x05f33390) /* 0.371875348 */, 18 }, - /* 5518 */ { MAD_F(0x05f391cf) /* 0.371965225 */, 18 }, - /* 5519 */ { MAD_F(0x05f3f00e) /* 0.372055107 */, 18 }, - - /* 5520 */ { MAD_F(0x05f44e4f) /* 0.372144994 */, 18 }, - /* 5521 */ { MAD_F(0x05f4ac91) /* 0.372234887 */, 18 }, - /* 5522 */ { MAD_F(0x05f50ad5) /* 0.372324785 */, 18 }, - /* 5523 */ { MAD_F(0x05f5691b) /* 0.372414689 */, 18 }, - /* 5524 */ { MAD_F(0x05f5c761) /* 0.372504598 */, 18 }, - /* 5525 */ { MAD_F(0x05f625aa) /* 0.372594513 */, 18 }, - /* 5526 */ { MAD_F(0x05f683f3) /* 0.372684433 */, 18 }, - /* 5527 */ { MAD_F(0x05f6e23f) /* 0.372774358 */, 18 }, - /* 5528 */ { MAD_F(0x05f7408b) /* 0.372864289 */, 18 }, - /* 5529 */ { MAD_F(0x05f79ed9) /* 0.372954225 */, 18 }, - /* 5530 */ { MAD_F(0x05f7fd29) /* 0.373044167 */, 18 }, - /* 5531 */ { MAD_F(0x05f85b7a) /* 0.373134114 */, 18 }, - /* 5532 */ { MAD_F(0x05f8b9cc) /* 0.373224066 */, 18 }, - /* 5533 */ { MAD_F(0x05f91820) /* 0.373314024 */, 18 }, - /* 5534 */ { MAD_F(0x05f97675) /* 0.373403987 */, 18 }, - /* 5535 */ { MAD_F(0x05f9d4cc) /* 0.373493956 */, 18 }, - - /* 5536 */ { MAD_F(0x05fa3324) /* 0.373583930 */, 18 }, - /* 5537 */ { MAD_F(0x05fa917e) /* 0.373673910 */, 18 }, - /* 5538 */ { MAD_F(0x05faefd9) /* 0.373763895 */, 18 }, - /* 5539 */ { MAD_F(0x05fb4e36) /* 0.373853885 */, 18 }, - /* 5540 */ { MAD_F(0x05fbac94) /* 0.373943881 */, 18 }, - /* 5541 */ { MAD_F(0x05fc0af3) /* 0.374033882 */, 18 }, - /* 5542 */ { MAD_F(0x05fc6954) /* 0.374123889 */, 18 }, - /* 5543 */ { MAD_F(0x05fcc7b7) /* 0.374213901 */, 18 }, - /* 5544 */ { MAD_F(0x05fd261b) /* 0.374303918 */, 18 }, - /* 5545 */ { MAD_F(0x05fd8480) /* 0.374393941 */, 18 }, - /* 5546 */ { MAD_F(0x05fde2e7) /* 0.374483970 */, 18 }, - /* 5547 */ { MAD_F(0x05fe414f) /* 0.374574003 */, 18 }, - /* 5548 */ { MAD_F(0x05fe9fb9) /* 0.374664042 */, 18 }, - /* 5549 */ { MAD_F(0x05fefe24) /* 0.374754087 */, 18 }, - /* 5550 */ { MAD_F(0x05ff5c91) /* 0.374844137 */, 18 }, - /* 5551 */ { MAD_F(0x05ffbaff) /* 0.374934192 */, 18 }, - - /* 5552 */ { MAD_F(0x0600196e) /* 0.375024253 */, 18 }, - /* 5553 */ { MAD_F(0x060077df) /* 0.375114319 */, 18 }, - /* 5554 */ { MAD_F(0x0600d651) /* 0.375204391 */, 18 }, - /* 5555 */ { MAD_F(0x060134c5) /* 0.375294468 */, 18 }, - /* 5556 */ { MAD_F(0x0601933b) /* 0.375384550 */, 18 }, - /* 5557 */ { MAD_F(0x0601f1b1) /* 0.375474638 */, 18 }, - /* 5558 */ { MAD_F(0x0602502a) /* 0.375564731 */, 18 }, - /* 5559 */ { MAD_F(0x0602aea3) /* 0.375654830 */, 18 }, - /* 5560 */ { MAD_F(0x06030d1e) /* 0.375744934 */, 18 }, - /* 5561 */ { MAD_F(0x06036b9b) /* 0.375835043 */, 18 }, - /* 5562 */ { MAD_F(0x0603ca19) /* 0.375925158 */, 18 }, - /* 5563 */ { MAD_F(0x06042898) /* 0.376015278 */, 18 }, - /* 5564 */ { MAD_F(0x06048719) /* 0.376105404 */, 18 }, - /* 5565 */ { MAD_F(0x0604e59c) /* 0.376195535 */, 18 }, - /* 5566 */ { MAD_F(0x0605441f) /* 0.376285671 */, 18 }, - /* 5567 */ { MAD_F(0x0605a2a5) /* 0.376375813 */, 18 }, - - /* 5568 */ { MAD_F(0x0606012b) /* 0.376465960 */, 18 }, - /* 5569 */ { MAD_F(0x06065fb4) /* 0.376556113 */, 18 }, - /* 5570 */ { MAD_F(0x0606be3d) /* 0.376646271 */, 18 }, - /* 5571 */ { MAD_F(0x06071cc8) /* 0.376736434 */, 18 }, - /* 5572 */ { MAD_F(0x06077b55) /* 0.376826603 */, 18 }, - /* 5573 */ { MAD_F(0x0607d9e3) /* 0.376916777 */, 18 }, - /* 5574 */ { MAD_F(0x06083872) /* 0.377006957 */, 18 }, - /* 5575 */ { MAD_F(0x06089703) /* 0.377097141 */, 18 }, - /* 5576 */ { MAD_F(0x0608f595) /* 0.377187332 */, 18 }, - /* 5577 */ { MAD_F(0x06095429) /* 0.377277528 */, 18 }, - /* 5578 */ { MAD_F(0x0609b2be) /* 0.377367729 */, 18 }, - /* 5579 */ { MAD_F(0x060a1155) /* 0.377457935 */, 18 }, - /* 5580 */ { MAD_F(0x060a6fed) /* 0.377548147 */, 18 }, - /* 5581 */ { MAD_F(0x060ace86) /* 0.377638364 */, 18 }, - /* 5582 */ { MAD_F(0x060b2d21) /* 0.377728587 */, 18 }, - /* 5583 */ { MAD_F(0x060b8bbe) /* 0.377818815 */, 18 }, - - /* 5584 */ { MAD_F(0x060bea5c) /* 0.377909049 */, 18 }, - /* 5585 */ { MAD_F(0x060c48fb) /* 0.377999288 */, 18 }, - /* 5586 */ { MAD_F(0x060ca79c) /* 0.378089532 */, 18 }, - /* 5587 */ { MAD_F(0x060d063e) /* 0.378179781 */, 18 }, - /* 5588 */ { MAD_F(0x060d64e1) /* 0.378270036 */, 18 }, - /* 5589 */ { MAD_F(0x060dc387) /* 0.378360297 */, 18 }, - /* 5590 */ { MAD_F(0x060e222d) /* 0.378450563 */, 18 }, - /* 5591 */ { MAD_F(0x060e80d5) /* 0.378540834 */, 18 }, - /* 5592 */ { MAD_F(0x060edf7f) /* 0.378631110 */, 18 }, - /* 5593 */ { MAD_F(0x060f3e29) /* 0.378721392 */, 18 }, - /* 5594 */ { MAD_F(0x060f9cd6) /* 0.378811680 */, 18 }, - /* 5595 */ { MAD_F(0x060ffb83) /* 0.378901972 */, 18 }, - /* 5596 */ { MAD_F(0x06105a33) /* 0.378992270 */, 18 }, - /* 5597 */ { MAD_F(0x0610b8e3) /* 0.379082574 */, 18 }, - /* 5598 */ { MAD_F(0x06111795) /* 0.379172883 */, 18 }, - /* 5599 */ { MAD_F(0x06117649) /* 0.379263197 */, 18 }, - - /* 5600 */ { MAD_F(0x0611d4fe) /* 0.379353516 */, 18 }, - /* 5601 */ { MAD_F(0x061233b4) /* 0.379443841 */, 18 }, - /* 5602 */ { MAD_F(0x0612926c) /* 0.379534172 */, 18 }, - /* 5603 */ { MAD_F(0x0612f125) /* 0.379624507 */, 18 }, - /* 5604 */ { MAD_F(0x06134fe0) /* 0.379714848 */, 18 }, - /* 5605 */ { MAD_F(0x0613ae9c) /* 0.379805195 */, 18 }, - /* 5606 */ { MAD_F(0x06140d5a) /* 0.379895547 */, 18 }, - /* 5607 */ { MAD_F(0x06146c19) /* 0.379985904 */, 18 }, - /* 5608 */ { MAD_F(0x0614cada) /* 0.380076266 */, 18 }, - /* 5609 */ { MAD_F(0x0615299c) /* 0.380166634 */, 18 }, - /* 5610 */ { MAD_F(0x0615885f) /* 0.380257008 */, 18 }, - /* 5611 */ { MAD_F(0x0615e724) /* 0.380347386 */, 18 }, - /* 5612 */ { MAD_F(0x061645ea) /* 0.380437770 */, 18 }, - /* 5613 */ { MAD_F(0x0616a4b2) /* 0.380528160 */, 18 }, - /* 5614 */ { MAD_F(0x0617037b) /* 0.380618555 */, 18 }, - /* 5615 */ { MAD_F(0x06176246) /* 0.380708955 */, 18 }, - - /* 5616 */ { MAD_F(0x0617c112) /* 0.380799360 */, 18 }, - /* 5617 */ { MAD_F(0x06181fdf) /* 0.380889771 */, 18 }, - /* 5618 */ { MAD_F(0x06187eae) /* 0.380980187 */, 18 }, - /* 5619 */ { MAD_F(0x0618dd7e) /* 0.381070609 */, 18 }, - /* 5620 */ { MAD_F(0x06193c50) /* 0.381161036 */, 18 }, - /* 5621 */ { MAD_F(0x06199b24) /* 0.381251468 */, 18 }, - /* 5622 */ { MAD_F(0x0619f9f8) /* 0.381341906 */, 18 }, - /* 5623 */ { MAD_F(0x061a58ce) /* 0.381432349 */, 18 }, - /* 5624 */ { MAD_F(0x061ab7a6) /* 0.381522798 */, 18 }, - /* 5625 */ { MAD_F(0x061b167f) /* 0.381613251 */, 18 }, - /* 5626 */ { MAD_F(0x061b7559) /* 0.381703711 */, 18 }, - /* 5627 */ { MAD_F(0x061bd435) /* 0.381794175 */, 18 }, - /* 5628 */ { MAD_F(0x061c3313) /* 0.381884645 */, 18 }, - /* 5629 */ { MAD_F(0x061c91f1) /* 0.381975120 */, 18 }, - /* 5630 */ { MAD_F(0x061cf0d2) /* 0.382065601 */, 18 }, - /* 5631 */ { MAD_F(0x061d4fb3) /* 0.382156087 */, 18 }, - - /* 5632 */ { MAD_F(0x061dae96) /* 0.382246578 */, 18 }, - /* 5633 */ { MAD_F(0x061e0d7b) /* 0.382337075 */, 18 }, - /* 5634 */ { MAD_F(0x061e6c61) /* 0.382427577 */, 18 }, - /* 5635 */ { MAD_F(0x061ecb48) /* 0.382518084 */, 18 }, - /* 5636 */ { MAD_F(0x061f2a31) /* 0.382608597 */, 18 }, - /* 5637 */ { MAD_F(0x061f891b) /* 0.382699115 */, 18 }, - /* 5638 */ { MAD_F(0x061fe807) /* 0.382789638 */, 18 }, - /* 5639 */ { MAD_F(0x062046f4) /* 0.382880167 */, 18 }, - /* 5640 */ { MAD_F(0x0620a5e3) /* 0.382970701 */, 18 }, - /* 5641 */ { MAD_F(0x062104d3) /* 0.383061241 */, 18 }, - /* 5642 */ { MAD_F(0x062163c4) /* 0.383151786 */, 18 }, - /* 5643 */ { MAD_F(0x0621c2b7) /* 0.383242336 */, 18 }, - /* 5644 */ { MAD_F(0x062221ab) /* 0.383332891 */, 18 }, - /* 5645 */ { MAD_F(0x062280a1) /* 0.383423452 */, 18 }, - /* 5646 */ { MAD_F(0x0622df98) /* 0.383514018 */, 18 }, - /* 5647 */ { MAD_F(0x06233e91) /* 0.383604590 */, 18 }, - - /* 5648 */ { MAD_F(0x06239d8b) /* 0.383695167 */, 18 }, - /* 5649 */ { MAD_F(0x0623fc86) /* 0.383785749 */, 18 }, - /* 5650 */ { MAD_F(0x06245b83) /* 0.383876337 */, 18 }, - /* 5651 */ { MAD_F(0x0624ba82) /* 0.383966930 */, 18 }, - /* 5652 */ { MAD_F(0x06251981) /* 0.384057528 */, 18 }, - /* 5653 */ { MAD_F(0x06257883) /* 0.384148132 */, 18 }, - /* 5654 */ { MAD_F(0x0625d785) /* 0.384238741 */, 18 }, - /* 5655 */ { MAD_F(0x06263689) /* 0.384329355 */, 18 }, - /* 5656 */ { MAD_F(0x0626958f) /* 0.384419975 */, 18 }, - /* 5657 */ { MAD_F(0x0626f496) /* 0.384510600 */, 18 }, - /* 5658 */ { MAD_F(0x0627539e) /* 0.384601230 */, 18 }, - /* 5659 */ { MAD_F(0x0627b2a8) /* 0.384691866 */, 18 }, - /* 5660 */ { MAD_F(0x062811b3) /* 0.384782507 */, 18 }, - /* 5661 */ { MAD_F(0x062870c0) /* 0.384873153 */, 18 }, - /* 5662 */ { MAD_F(0x0628cfce) /* 0.384963805 */, 18 }, - /* 5663 */ { MAD_F(0x06292ede) /* 0.385054462 */, 18 }, - - /* 5664 */ { MAD_F(0x06298def) /* 0.385145124 */, 18 }, - /* 5665 */ { MAD_F(0x0629ed01) /* 0.385235792 */, 18 }, - /* 5666 */ { MAD_F(0x062a4c15) /* 0.385326465 */, 18 }, - /* 5667 */ { MAD_F(0x062aab2a) /* 0.385417143 */, 18 }, - /* 5668 */ { MAD_F(0x062b0a41) /* 0.385507827 */, 18 }, - /* 5669 */ { MAD_F(0x062b6959) /* 0.385598516 */, 18 }, - /* 5670 */ { MAD_F(0x062bc873) /* 0.385689211 */, 18 }, - /* 5671 */ { MAD_F(0x062c278e) /* 0.385779910 */, 18 }, - /* 5672 */ { MAD_F(0x062c86aa) /* 0.385870615 */, 18 }, - /* 5673 */ { MAD_F(0x062ce5c8) /* 0.385961326 */, 18 }, - /* 5674 */ { MAD_F(0x062d44e8) /* 0.386052041 */, 18 }, - /* 5675 */ { MAD_F(0x062da408) /* 0.386142762 */, 18 }, - /* 5676 */ { MAD_F(0x062e032a) /* 0.386233489 */, 18 }, - /* 5677 */ { MAD_F(0x062e624e) /* 0.386324221 */, 18 }, - /* 5678 */ { MAD_F(0x062ec173) /* 0.386414958 */, 18 }, - /* 5679 */ { MAD_F(0x062f209a) /* 0.386505700 */, 18 }, - - /* 5680 */ { MAD_F(0x062f7fc1) /* 0.386596448 */, 18 }, - /* 5681 */ { MAD_F(0x062fdeeb) /* 0.386687201 */, 18 }, - /* 5682 */ { MAD_F(0x06303e16) /* 0.386777959 */, 18 }, - /* 5683 */ { MAD_F(0x06309d42) /* 0.386868723 */, 18 }, - /* 5684 */ { MAD_F(0x0630fc6f) /* 0.386959492 */, 18 }, - /* 5685 */ { MAD_F(0x06315b9e) /* 0.387050266 */, 18 }, - /* 5686 */ { MAD_F(0x0631bacf) /* 0.387141045 */, 18 }, - /* 5687 */ { MAD_F(0x06321a01) /* 0.387231830 */, 18 }, - /* 5688 */ { MAD_F(0x06327934) /* 0.387322621 */, 18 }, - /* 5689 */ { MAD_F(0x0632d869) /* 0.387413416 */, 18 }, - /* 5690 */ { MAD_F(0x0633379f) /* 0.387504217 */, 18 }, - /* 5691 */ { MAD_F(0x063396d7) /* 0.387595023 */, 18 }, - /* 5692 */ { MAD_F(0x0633f610) /* 0.387685835 */, 18 }, - /* 5693 */ { MAD_F(0x0634554a) /* 0.387776652 */, 18 }, - /* 5694 */ { MAD_F(0x0634b486) /* 0.387867474 */, 18 }, - /* 5695 */ { MAD_F(0x063513c3) /* 0.387958301 */, 18 }, - - /* 5696 */ { MAD_F(0x06357302) /* 0.388049134 */, 18 }, - /* 5697 */ { MAD_F(0x0635d242) /* 0.388139972 */, 18 }, - /* 5698 */ { MAD_F(0x06363184) /* 0.388230816 */, 18 }, - /* 5699 */ { MAD_F(0x063690c7) /* 0.388321665 */, 18 }, - /* 5700 */ { MAD_F(0x0636f00b) /* 0.388412519 */, 18 }, - /* 5701 */ { MAD_F(0x06374f51) /* 0.388503378 */, 18 }, - /* 5702 */ { MAD_F(0x0637ae99) /* 0.388594243 */, 18 }, - /* 5703 */ { MAD_F(0x06380de1) /* 0.388685113 */, 18 }, - /* 5704 */ { MAD_F(0x06386d2b) /* 0.388775988 */, 18 }, - /* 5705 */ { MAD_F(0x0638cc77) /* 0.388866869 */, 18 }, - /* 5706 */ { MAD_F(0x06392bc4) /* 0.388957755 */, 18 }, - /* 5707 */ { MAD_F(0x06398b12) /* 0.389048646 */, 18 }, - /* 5708 */ { MAD_F(0x0639ea62) /* 0.389139542 */, 18 }, - /* 5709 */ { MAD_F(0x063a49b4) /* 0.389230444 */, 18 }, - /* 5710 */ { MAD_F(0x063aa906) /* 0.389321352 */, 18 }, - /* 5711 */ { MAD_F(0x063b085a) /* 0.389412264 */, 18 }, - - /* 5712 */ { MAD_F(0x063b67b0) /* 0.389503182 */, 18 }, - /* 5713 */ { MAD_F(0x063bc707) /* 0.389594105 */, 18 }, - /* 5714 */ { MAD_F(0x063c265f) /* 0.389685033 */, 18 }, - /* 5715 */ { MAD_F(0x063c85b9) /* 0.389775967 */, 18 }, - /* 5716 */ { MAD_F(0x063ce514) /* 0.389866906 */, 18 }, - /* 5717 */ { MAD_F(0x063d4471) /* 0.389957850 */, 18 }, - /* 5718 */ { MAD_F(0x063da3cf) /* 0.390048800 */, 18 }, - /* 5719 */ { MAD_F(0x063e032f) /* 0.390139755 */, 18 }, - /* 5720 */ { MAD_F(0x063e6290) /* 0.390230715 */, 18 }, - /* 5721 */ { MAD_F(0x063ec1f2) /* 0.390321681 */, 18 }, - /* 5722 */ { MAD_F(0x063f2156) /* 0.390412651 */, 18 }, - /* 5723 */ { MAD_F(0x063f80bb) /* 0.390503628 */, 18 }, - /* 5724 */ { MAD_F(0x063fe022) /* 0.390594609 */, 18 }, - /* 5725 */ { MAD_F(0x06403f8a) /* 0.390685596 */, 18 }, - /* 5726 */ { MAD_F(0x06409ef3) /* 0.390776588 */, 18 }, - /* 5727 */ { MAD_F(0x0640fe5e) /* 0.390867585 */, 18 }, - - /* 5728 */ { MAD_F(0x06415dcb) /* 0.390958588 */, 18 }, - /* 5729 */ { MAD_F(0x0641bd38) /* 0.391049596 */, 18 }, - /* 5730 */ { MAD_F(0x06421ca7) /* 0.391140609 */, 18 }, - /* 5731 */ { MAD_F(0x06427c18) /* 0.391231627 */, 18 }, - /* 5732 */ { MAD_F(0x0642db8a) /* 0.391322651 */, 18 }, - /* 5733 */ { MAD_F(0x06433afd) /* 0.391413680 */, 18 }, - /* 5734 */ { MAD_F(0x06439a72) /* 0.391504714 */, 18 }, - /* 5735 */ { MAD_F(0x0643f9e9) /* 0.391595754 */, 18 }, - /* 5736 */ { MAD_F(0x06445960) /* 0.391686799 */, 18 }, - /* 5737 */ { MAD_F(0x0644b8d9) /* 0.391777849 */, 18 }, - /* 5738 */ { MAD_F(0x06451854) /* 0.391868905 */, 18 }, - /* 5739 */ { MAD_F(0x064577d0) /* 0.391959966 */, 18 }, - /* 5740 */ { MAD_F(0x0645d74d) /* 0.392051032 */, 18 }, - /* 5741 */ { MAD_F(0x064636cc) /* 0.392142103 */, 18 }, - /* 5742 */ { MAD_F(0x0646964c) /* 0.392233180 */, 18 }, - /* 5743 */ { MAD_F(0x0646f5ce) /* 0.392324262 */, 18 }, - - /* 5744 */ { MAD_F(0x06475551) /* 0.392415349 */, 18 }, - /* 5745 */ { MAD_F(0x0647b4d5) /* 0.392506442 */, 18 }, - /* 5746 */ { MAD_F(0x0648145b) /* 0.392597540 */, 18 }, - /* 5747 */ { MAD_F(0x064873e3) /* 0.392688643 */, 18 }, - /* 5748 */ { MAD_F(0x0648d36b) /* 0.392779751 */, 18 }, - /* 5749 */ { MAD_F(0x064932f6) /* 0.392870865 */, 18 }, - /* 5750 */ { MAD_F(0x06499281) /* 0.392961984 */, 18 }, - /* 5751 */ { MAD_F(0x0649f20e) /* 0.393053108 */, 18 }, - /* 5752 */ { MAD_F(0x064a519c) /* 0.393144238 */, 18 }, - /* 5753 */ { MAD_F(0x064ab12c) /* 0.393235372 */, 18 }, - /* 5754 */ { MAD_F(0x064b10be) /* 0.393326513 */, 18 }, - /* 5755 */ { MAD_F(0x064b7050) /* 0.393417658 */, 18 }, - /* 5756 */ { MAD_F(0x064bcfe4) /* 0.393508809 */, 18 }, - /* 5757 */ { MAD_F(0x064c2f7a) /* 0.393599965 */, 18 }, - /* 5758 */ { MAD_F(0x064c8f11) /* 0.393691126 */, 18 }, - /* 5759 */ { MAD_F(0x064ceea9) /* 0.393782292 */, 18 }, - - /* 5760 */ { MAD_F(0x064d4e43) /* 0.393873464 */, 18 }, - /* 5761 */ { MAD_F(0x064dadde) /* 0.393964641 */, 18 }, - /* 5762 */ { MAD_F(0x064e0d7a) /* 0.394055823 */, 18 }, - /* 5763 */ { MAD_F(0x064e6d18) /* 0.394147011 */, 18 }, - /* 5764 */ { MAD_F(0x064eccb8) /* 0.394238204 */, 18 }, - /* 5765 */ { MAD_F(0x064f2c59) /* 0.394329402 */, 18 }, - /* 5766 */ { MAD_F(0x064f8bfb) /* 0.394420605 */, 18 }, - /* 5767 */ { MAD_F(0x064feb9e) /* 0.394511814 */, 18 }, - /* 5768 */ { MAD_F(0x06504b44) /* 0.394603028 */, 18 }, - /* 5769 */ { MAD_F(0x0650aaea) /* 0.394694247 */, 18 }, - /* 5770 */ { MAD_F(0x06510a92) /* 0.394785472 */, 18 }, - /* 5771 */ { MAD_F(0x06516a3b) /* 0.394876702 */, 18 }, - /* 5772 */ { MAD_F(0x0651c9e6) /* 0.394967937 */, 18 }, - /* 5773 */ { MAD_F(0x06522992) /* 0.395059177 */, 18 }, - /* 5774 */ { MAD_F(0x06528940) /* 0.395150423 */, 18 }, - /* 5775 */ { MAD_F(0x0652e8ef) /* 0.395241673 */, 18 }, - - /* 5776 */ { MAD_F(0x0653489f) /* 0.395332930 */, 18 }, - /* 5777 */ { MAD_F(0x0653a851) /* 0.395424191 */, 18 }, - /* 5778 */ { MAD_F(0x06540804) /* 0.395515458 */, 18 }, - /* 5779 */ { MAD_F(0x065467b9) /* 0.395606730 */, 18 }, - /* 5780 */ { MAD_F(0x0654c76f) /* 0.395698007 */, 18 }, - /* 5781 */ { MAD_F(0x06552726) /* 0.395789289 */, 18 }, - /* 5782 */ { MAD_F(0x065586df) /* 0.395880577 */, 18 }, - /* 5783 */ { MAD_F(0x0655e699) /* 0.395971870 */, 18 }, - /* 5784 */ { MAD_F(0x06564655) /* 0.396063168 */, 18 }, - /* 5785 */ { MAD_F(0x0656a612) /* 0.396154472 */, 18 }, - /* 5786 */ { MAD_F(0x065705d0) /* 0.396245780 */, 18 }, - /* 5787 */ { MAD_F(0x06576590) /* 0.396337094 */, 18 }, - /* 5788 */ { MAD_F(0x0657c552) /* 0.396428414 */, 18 }, - /* 5789 */ { MAD_F(0x06582514) /* 0.396519738 */, 18 }, - /* 5790 */ { MAD_F(0x065884d9) /* 0.396611068 */, 18 }, - /* 5791 */ { MAD_F(0x0658e49e) /* 0.396702403 */, 18 }, - - /* 5792 */ { MAD_F(0x06594465) /* 0.396793743 */, 18 }, - /* 5793 */ { MAD_F(0x0659a42e) /* 0.396885089 */, 18 }, - /* 5794 */ { MAD_F(0x065a03f7) /* 0.396976440 */, 18 }, - /* 5795 */ { MAD_F(0x065a63c3) /* 0.397067796 */, 18 }, - /* 5796 */ { MAD_F(0x065ac38f) /* 0.397159157 */, 18 }, - /* 5797 */ { MAD_F(0x065b235d) /* 0.397250524 */, 18 }, - /* 5798 */ { MAD_F(0x065b832d) /* 0.397341896 */, 18 }, - /* 5799 */ { MAD_F(0x065be2fe) /* 0.397433273 */, 18 }, - /* 5800 */ { MAD_F(0x065c42d0) /* 0.397524655 */, 18 }, - /* 5801 */ { MAD_F(0x065ca2a3) /* 0.397616043 */, 18 }, - /* 5802 */ { MAD_F(0x065d0279) /* 0.397707436 */, 18 }, - /* 5803 */ { MAD_F(0x065d624f) /* 0.397798834 */, 18 }, - /* 5804 */ { MAD_F(0x065dc227) /* 0.397890237 */, 18 }, - /* 5805 */ { MAD_F(0x065e2200) /* 0.397981646 */, 18 }, - /* 5806 */ { MAD_F(0x065e81db) /* 0.398073059 */, 18 }, - /* 5807 */ { MAD_F(0x065ee1b7) /* 0.398164479 */, 18 }, - - /* 5808 */ { MAD_F(0x065f4195) /* 0.398255903 */, 18 }, - /* 5809 */ { MAD_F(0x065fa174) /* 0.398347333 */, 18 }, - /* 5810 */ { MAD_F(0x06600154) /* 0.398438767 */, 18 }, - /* 5811 */ { MAD_F(0x06606136) /* 0.398530207 */, 18 }, - /* 5812 */ { MAD_F(0x0660c119) /* 0.398621653 */, 18 }, - /* 5813 */ { MAD_F(0x066120fd) /* 0.398713103 */, 18 }, - /* 5814 */ { MAD_F(0x066180e3) /* 0.398804559 */, 18 }, - /* 5815 */ { MAD_F(0x0661e0cb) /* 0.398896020 */, 18 }, - /* 5816 */ { MAD_F(0x066240b4) /* 0.398987487 */, 18 }, - /* 5817 */ { MAD_F(0x0662a09e) /* 0.399078958 */, 18 }, - /* 5818 */ { MAD_F(0x06630089) /* 0.399170435 */, 18 }, - /* 5819 */ { MAD_F(0x06636077) /* 0.399261917 */, 18 }, - /* 5820 */ { MAD_F(0x0663c065) /* 0.399353404 */, 18 }, - /* 5821 */ { MAD_F(0x06642055) /* 0.399444897 */, 18 }, - /* 5822 */ { MAD_F(0x06648046) /* 0.399536395 */, 18 }, - /* 5823 */ { MAD_F(0x0664e039) /* 0.399627898 */, 18 }, - - /* 5824 */ { MAD_F(0x0665402d) /* 0.399719406 */, 18 }, - /* 5825 */ { MAD_F(0x0665a022) /* 0.399810919 */, 18 }, - /* 5826 */ { MAD_F(0x06660019) /* 0.399902438 */, 18 }, - /* 5827 */ { MAD_F(0x06666011) /* 0.399993962 */, 18 }, - /* 5828 */ { MAD_F(0x0666c00b) /* 0.400085491 */, 18 }, - /* 5829 */ { MAD_F(0x06672006) /* 0.400177026 */, 18 }, - /* 5830 */ { MAD_F(0x06678003) /* 0.400268565 */, 18 }, - /* 5831 */ { MAD_F(0x0667e000) /* 0.400360110 */, 18 }, - /* 5832 */ { MAD_F(0x06684000) /* 0.400451660 */, 18 }, - /* 5833 */ { MAD_F(0x0668a000) /* 0.400543216 */, 18 }, - /* 5834 */ { MAD_F(0x06690003) /* 0.400634776 */, 18 }, - /* 5835 */ { MAD_F(0x06696006) /* 0.400726342 */, 18 }, - /* 5836 */ { MAD_F(0x0669c00b) /* 0.400817913 */, 18 }, - /* 5837 */ { MAD_F(0x066a2011) /* 0.400909489 */, 18 }, - /* 5838 */ { MAD_F(0x066a8019) /* 0.401001071 */, 18 }, - /* 5839 */ { MAD_F(0x066ae022) /* 0.401092657 */, 18 }, - - /* 5840 */ { MAD_F(0x066b402d) /* 0.401184249 */, 18 }, - /* 5841 */ { MAD_F(0x066ba039) /* 0.401275847 */, 18 }, - /* 5842 */ { MAD_F(0x066c0046) /* 0.401367449 */, 18 }, - /* 5843 */ { MAD_F(0x066c6055) /* 0.401459057 */, 18 }, - /* 5844 */ { MAD_F(0x066cc065) /* 0.401550670 */, 18 }, - /* 5845 */ { MAD_F(0x066d2076) /* 0.401642288 */, 18 }, - /* 5846 */ { MAD_F(0x066d8089) /* 0.401733911 */, 18 }, - /* 5847 */ { MAD_F(0x066de09e) /* 0.401825540 */, 18 }, - /* 5848 */ { MAD_F(0x066e40b3) /* 0.401917173 */, 18 }, - /* 5849 */ { MAD_F(0x066ea0cb) /* 0.402008812 */, 18 }, - /* 5850 */ { MAD_F(0x066f00e3) /* 0.402100457 */, 18 }, - /* 5851 */ { MAD_F(0x066f60fd) /* 0.402192106 */, 18 }, - /* 5852 */ { MAD_F(0x066fc118) /* 0.402283761 */, 18 }, - /* 5853 */ { MAD_F(0x06702135) /* 0.402375420 */, 18 }, - /* 5854 */ { MAD_F(0x06708153) /* 0.402467086 */, 18 }, - /* 5855 */ { MAD_F(0x0670e173) /* 0.402558756 */, 18 }, - - /* 5856 */ { MAD_F(0x06714194) /* 0.402650431 */, 18 }, - /* 5857 */ { MAD_F(0x0671a1b6) /* 0.402742112 */, 18 }, - /* 5858 */ { MAD_F(0x067201da) /* 0.402833798 */, 18 }, - /* 5859 */ { MAD_F(0x067261ff) /* 0.402925489 */, 18 }, - /* 5860 */ { MAD_F(0x0672c226) /* 0.403017186 */, 18 }, - /* 5861 */ { MAD_F(0x0673224e) /* 0.403108887 */, 18 }, - /* 5862 */ { MAD_F(0x06738277) /* 0.403200594 */, 18 }, - /* 5863 */ { MAD_F(0x0673e2a2) /* 0.403292306 */, 18 }, - /* 5864 */ { MAD_F(0x067442ce) /* 0.403384024 */, 18 }, - /* 5865 */ { MAD_F(0x0674a2fc) /* 0.403475746 */, 18 }, - /* 5866 */ { MAD_F(0x0675032b) /* 0.403567474 */, 18 }, - /* 5867 */ { MAD_F(0x0675635b) /* 0.403659207 */, 18 }, - /* 5868 */ { MAD_F(0x0675c38d) /* 0.403750945 */, 18 }, - /* 5869 */ { MAD_F(0x067623c0) /* 0.403842688 */, 18 }, - /* 5870 */ { MAD_F(0x067683f4) /* 0.403934437 */, 18 }, - /* 5871 */ { MAD_F(0x0676e42a) /* 0.404026190 */, 18 }, - - /* 5872 */ { MAD_F(0x06774462) /* 0.404117949 */, 18 }, - /* 5873 */ { MAD_F(0x0677a49b) /* 0.404209714 */, 18 }, - /* 5874 */ { MAD_F(0x067804d5) /* 0.404301483 */, 18 }, - /* 5875 */ { MAD_F(0x06786510) /* 0.404393258 */, 18 }, - /* 5876 */ { MAD_F(0x0678c54d) /* 0.404485037 */, 18 }, - /* 5877 */ { MAD_F(0x0679258c) /* 0.404576822 */, 18 }, - /* 5878 */ { MAD_F(0x067985cb) /* 0.404668613 */, 18 }, - /* 5879 */ { MAD_F(0x0679e60c) /* 0.404760408 */, 18 }, - /* 5880 */ { MAD_F(0x067a464f) /* 0.404852209 */, 18 }, - /* 5881 */ { MAD_F(0x067aa693) /* 0.404944014 */, 18 }, - /* 5882 */ { MAD_F(0x067b06d8) /* 0.405035825 */, 18 }, - /* 5883 */ { MAD_F(0x067b671f) /* 0.405127642 */, 18 }, - /* 5884 */ { MAD_F(0x067bc767) /* 0.405219463 */, 18 }, - /* 5885 */ { MAD_F(0x067c27b1) /* 0.405311290 */, 18 }, - /* 5886 */ { MAD_F(0x067c87fc) /* 0.405403122 */, 18 }, - /* 5887 */ { MAD_F(0x067ce848) /* 0.405494959 */, 18 }, - - /* 5888 */ { MAD_F(0x067d4896) /* 0.405586801 */, 18 }, - /* 5889 */ { MAD_F(0x067da8e5) /* 0.405678648 */, 18 }, - /* 5890 */ { MAD_F(0x067e0935) /* 0.405770501 */, 18 }, - /* 5891 */ { MAD_F(0x067e6987) /* 0.405862359 */, 18 }, - /* 5892 */ { MAD_F(0x067ec9da) /* 0.405954222 */, 18 }, - /* 5893 */ { MAD_F(0x067f2a2f) /* 0.406046090 */, 18 }, - /* 5894 */ { MAD_F(0x067f8a85) /* 0.406137963 */, 18 }, - /* 5895 */ { MAD_F(0x067feadd) /* 0.406229842 */, 18 }, - /* 5896 */ { MAD_F(0x06804b36) /* 0.406321726 */, 18 }, - /* 5897 */ { MAD_F(0x0680ab90) /* 0.406413615 */, 18 }, - /* 5898 */ { MAD_F(0x06810beb) /* 0.406505509 */, 18 }, - /* 5899 */ { MAD_F(0x06816c49) /* 0.406597408 */, 18 }, - /* 5900 */ { MAD_F(0x0681cca7) /* 0.406689313 */, 18 }, - /* 5901 */ { MAD_F(0x06822d07) /* 0.406781223 */, 18 }, - /* 5902 */ { MAD_F(0x06828d68) /* 0.406873138 */, 18 }, - /* 5903 */ { MAD_F(0x0682edcb) /* 0.406965058 */, 18 }, - - /* 5904 */ { MAD_F(0x06834e2f) /* 0.407056983 */, 18 }, - /* 5905 */ { MAD_F(0x0683ae94) /* 0.407148914 */, 18 }, - /* 5906 */ { MAD_F(0x06840efb) /* 0.407240850 */, 18 }, - /* 5907 */ { MAD_F(0x06846f63) /* 0.407332791 */, 18 }, - /* 5908 */ { MAD_F(0x0684cfcd) /* 0.407424737 */, 18 }, - /* 5909 */ { MAD_F(0x06853038) /* 0.407516688 */, 18 }, - /* 5910 */ { MAD_F(0x068590a4) /* 0.407608645 */, 18 }, - /* 5911 */ { MAD_F(0x0685f112) /* 0.407700606 */, 18 }, - /* 5912 */ { MAD_F(0x06865181) /* 0.407792573 */, 18 }, - /* 5913 */ { MAD_F(0x0686b1f2) /* 0.407884545 */, 18 }, - /* 5914 */ { MAD_F(0x06871264) /* 0.407976522 */, 18 }, - /* 5915 */ { MAD_F(0x068772d7) /* 0.408068505 */, 18 }, - /* 5916 */ { MAD_F(0x0687d34c) /* 0.408160492 */, 18 }, - /* 5917 */ { MAD_F(0x068833c2) /* 0.408252485 */, 18 }, - /* 5918 */ { MAD_F(0x06889439) /* 0.408344483 */, 18 }, - /* 5919 */ { MAD_F(0x0688f4b2) /* 0.408436486 */, 18 }, - - /* 5920 */ { MAD_F(0x0689552c) /* 0.408528495 */, 18 }, - /* 5921 */ { MAD_F(0x0689b5a8) /* 0.408620508 */, 18 }, - /* 5922 */ { MAD_F(0x068a1625) /* 0.408712527 */, 18 }, - /* 5923 */ { MAD_F(0x068a76a4) /* 0.408804551 */, 18 }, - /* 5924 */ { MAD_F(0x068ad724) /* 0.408896580 */, 18 }, - /* 5925 */ { MAD_F(0x068b37a5) /* 0.408988614 */, 18 }, - /* 5926 */ { MAD_F(0x068b9827) /* 0.409080653 */, 18 }, - /* 5927 */ { MAD_F(0x068bf8ac) /* 0.409172698 */, 18 }, - /* 5928 */ { MAD_F(0x068c5931) /* 0.409264748 */, 18 }, - /* 5929 */ { MAD_F(0x068cb9b8) /* 0.409356803 */, 18 }, - /* 5930 */ { MAD_F(0x068d1a40) /* 0.409448863 */, 18 }, - /* 5931 */ { MAD_F(0x068d7aca) /* 0.409540928 */, 18 }, - /* 5932 */ { MAD_F(0x068ddb54) /* 0.409632999 */, 18 }, - /* 5933 */ { MAD_F(0x068e3be1) /* 0.409725074 */, 18 }, - /* 5934 */ { MAD_F(0x068e9c6f) /* 0.409817155 */, 18 }, - /* 5935 */ { MAD_F(0x068efcfe) /* 0.409909241 */, 18 }, - - /* 5936 */ { MAD_F(0x068f5d8e) /* 0.410001332 */, 18 }, - /* 5937 */ { MAD_F(0x068fbe20) /* 0.410093428 */, 18 }, - /* 5938 */ { MAD_F(0x06901eb4) /* 0.410185530 */, 18 }, - /* 5939 */ { MAD_F(0x06907f48) /* 0.410277637 */, 18 }, - /* 5940 */ { MAD_F(0x0690dfde) /* 0.410369748 */, 18 }, - /* 5941 */ { MAD_F(0x06914076) /* 0.410461865 */, 18 }, - /* 5942 */ { MAD_F(0x0691a10f) /* 0.410553988 */, 18 }, - /* 5943 */ { MAD_F(0x069201a9) /* 0.410646115 */, 18 }, - /* 5944 */ { MAD_F(0x06926245) /* 0.410738247 */, 18 }, - /* 5945 */ { MAD_F(0x0692c2e2) /* 0.410830385 */, 18 }, - /* 5946 */ { MAD_F(0x06932380) /* 0.410922528 */, 18 }, - /* 5947 */ { MAD_F(0x06938420) /* 0.411014676 */, 18 }, - /* 5948 */ { MAD_F(0x0693e4c1) /* 0.411106829 */, 18 }, - /* 5949 */ { MAD_F(0x06944563) /* 0.411198987 */, 18 }, - /* 5950 */ { MAD_F(0x0694a607) /* 0.411291151 */, 18 }, - /* 5951 */ { MAD_F(0x069506ad) /* 0.411383320 */, 18 }, - - /* 5952 */ { MAD_F(0x06956753) /* 0.411475493 */, 18 }, - /* 5953 */ { MAD_F(0x0695c7fc) /* 0.411567672 */, 18 }, - /* 5954 */ { MAD_F(0x069628a5) /* 0.411659857 */, 18 }, - /* 5955 */ { MAD_F(0x06968950) /* 0.411752046 */, 18 }, - /* 5956 */ { MAD_F(0x0696e9fc) /* 0.411844240 */, 18 }, - /* 5957 */ { MAD_F(0x06974aaa) /* 0.411936440 */, 18 }, - /* 5958 */ { MAD_F(0x0697ab59) /* 0.412028645 */, 18 }, - /* 5959 */ { MAD_F(0x06980c09) /* 0.412120855 */, 18 }, - /* 5960 */ { MAD_F(0x06986cbb) /* 0.412213070 */, 18 }, - /* 5961 */ { MAD_F(0x0698cd6e) /* 0.412305290 */, 18 }, - /* 5962 */ { MAD_F(0x06992e23) /* 0.412397516 */, 18 }, - /* 5963 */ { MAD_F(0x06998ed9) /* 0.412489746 */, 18 }, - /* 5964 */ { MAD_F(0x0699ef90) /* 0.412581982 */, 18 }, - /* 5965 */ { MAD_F(0x069a5049) /* 0.412674223 */, 18 }, - /* 5966 */ { MAD_F(0x069ab103) /* 0.412766469 */, 18 }, - /* 5967 */ { MAD_F(0x069b11bf) /* 0.412858720 */, 18 }, - - /* 5968 */ { MAD_F(0x069b727b) /* 0.412950976 */, 18 }, - /* 5969 */ { MAD_F(0x069bd33a) /* 0.413043238 */, 18 }, - /* 5970 */ { MAD_F(0x069c33f9) /* 0.413135505 */, 18 }, - /* 5971 */ { MAD_F(0x069c94ba) /* 0.413227776 */, 18 }, - /* 5972 */ { MAD_F(0x069cf57d) /* 0.413320053 */, 18 }, - /* 5973 */ { MAD_F(0x069d5641) /* 0.413412335 */, 18 }, - /* 5974 */ { MAD_F(0x069db706) /* 0.413504623 */, 18 }, - /* 5975 */ { MAD_F(0x069e17cc) /* 0.413596915 */, 18 }, - /* 5976 */ { MAD_F(0x069e7894) /* 0.413689213 */, 18 }, - /* 5977 */ { MAD_F(0x069ed95e) /* 0.413781515 */, 18 }, - /* 5978 */ { MAD_F(0x069f3a28) /* 0.413873823 */, 18 }, - /* 5979 */ { MAD_F(0x069f9af4) /* 0.413966136 */, 18 }, - /* 5980 */ { MAD_F(0x069ffbc2) /* 0.414058454 */, 18 }, - /* 5981 */ { MAD_F(0x06a05c91) /* 0.414150778 */, 18 }, - /* 5982 */ { MAD_F(0x06a0bd61) /* 0.414243106 */, 18 }, - /* 5983 */ { MAD_F(0x06a11e32) /* 0.414335440 */, 18 }, - - /* 5984 */ { MAD_F(0x06a17f05) /* 0.414427779 */, 18 }, - /* 5985 */ { MAD_F(0x06a1dfda) /* 0.414520122 */, 18 }, - /* 5986 */ { MAD_F(0x06a240b0) /* 0.414612471 */, 18 }, - /* 5987 */ { MAD_F(0x06a2a187) /* 0.414704826 */, 18 }, - /* 5988 */ { MAD_F(0x06a3025f) /* 0.414797185 */, 18 }, - /* 5989 */ { MAD_F(0x06a36339) /* 0.414889549 */, 18 }, - /* 5990 */ { MAD_F(0x06a3c414) /* 0.414981919 */, 18 }, - /* 5991 */ { MAD_F(0x06a424f1) /* 0.415074294 */, 18 }, - /* 5992 */ { MAD_F(0x06a485cf) /* 0.415166674 */, 18 }, - /* 5993 */ { MAD_F(0x06a4e6ae) /* 0.415259059 */, 18 }, - /* 5994 */ { MAD_F(0x06a5478f) /* 0.415351449 */, 18 }, - /* 5995 */ { MAD_F(0x06a5a871) /* 0.415443844 */, 18 }, - /* 5996 */ { MAD_F(0x06a60955) /* 0.415536244 */, 18 }, - /* 5997 */ { MAD_F(0x06a66a3a) /* 0.415628650 */, 18 }, - /* 5998 */ { MAD_F(0x06a6cb20) /* 0.415721061 */, 18 }, - /* 5999 */ { MAD_F(0x06a72c08) /* 0.415813476 */, 18 }, - - /* 6000 */ { MAD_F(0x06a78cf1) /* 0.415905897 */, 18 }, - /* 6001 */ { MAD_F(0x06a7eddb) /* 0.415998324 */, 18 }, - /* 6002 */ { MAD_F(0x06a84ec7) /* 0.416090755 */, 18 }, - /* 6003 */ { MAD_F(0x06a8afb4) /* 0.416183191 */, 18 }, - /* 6004 */ { MAD_F(0x06a910a3) /* 0.416275633 */, 18 }, - /* 6005 */ { MAD_F(0x06a97193) /* 0.416368079 */, 18 }, - /* 6006 */ { MAD_F(0x06a9d284) /* 0.416460531 */, 18 }, - /* 6007 */ { MAD_F(0x06aa3377) /* 0.416552988 */, 18 }, - /* 6008 */ { MAD_F(0x06aa946b) /* 0.416645450 */, 18 }, - /* 6009 */ { MAD_F(0x06aaf561) /* 0.416737917 */, 18 }, - /* 6010 */ { MAD_F(0x06ab5657) /* 0.416830389 */, 18 }, - /* 6011 */ { MAD_F(0x06abb750) /* 0.416922867 */, 18 }, - /* 6012 */ { MAD_F(0x06ac1849) /* 0.417015349 */, 18 }, - /* 6013 */ { MAD_F(0x06ac7944) /* 0.417107837 */, 18 }, - /* 6014 */ { MAD_F(0x06acda41) /* 0.417200330 */, 18 }, - /* 6015 */ { MAD_F(0x06ad3b3e) /* 0.417292828 */, 18 }, - - /* 6016 */ { MAD_F(0x06ad9c3d) /* 0.417385331 */, 18 }, - /* 6017 */ { MAD_F(0x06adfd3e) /* 0.417477839 */, 18 }, - /* 6018 */ { MAD_F(0x06ae5e40) /* 0.417570352 */, 18 }, - /* 6019 */ { MAD_F(0x06aebf43) /* 0.417662871 */, 18 }, - /* 6020 */ { MAD_F(0x06af2047) /* 0.417755394 */, 18 }, - /* 6021 */ { MAD_F(0x06af814d) /* 0.417847923 */, 18 }, - /* 6022 */ { MAD_F(0x06afe255) /* 0.417940457 */, 18 }, - /* 6023 */ { MAD_F(0x06b0435e) /* 0.418032996 */, 18 }, - /* 6024 */ { MAD_F(0x06b0a468) /* 0.418125540 */, 18 }, - /* 6025 */ { MAD_F(0x06b10573) /* 0.418218089 */, 18 }, - /* 6026 */ { MAD_F(0x06b16680) /* 0.418310643 */, 18 }, - /* 6027 */ { MAD_F(0x06b1c78e) /* 0.418403203 */, 18 }, - /* 6028 */ { MAD_F(0x06b2289e) /* 0.418495767 */, 18 }, - /* 6029 */ { MAD_F(0x06b289af) /* 0.418588337 */, 18 }, - /* 6030 */ { MAD_F(0x06b2eac1) /* 0.418680911 */, 18 }, - /* 6031 */ { MAD_F(0x06b34bd5) /* 0.418773491 */, 18 }, - - /* 6032 */ { MAD_F(0x06b3acea) /* 0.418866076 */, 18 }, - /* 6033 */ { MAD_F(0x06b40e00) /* 0.418958666 */, 18 }, - /* 6034 */ { MAD_F(0x06b46f18) /* 0.419051262 */, 18 }, - /* 6035 */ { MAD_F(0x06b4d031) /* 0.419143862 */, 18 }, - /* 6036 */ { MAD_F(0x06b5314c) /* 0.419236467 */, 18 }, - /* 6037 */ { MAD_F(0x06b59268) /* 0.419329078 */, 18 }, - /* 6038 */ { MAD_F(0x06b5f385) /* 0.419421694 */, 18 }, - /* 6039 */ { MAD_F(0x06b654a4) /* 0.419514314 */, 18 }, - /* 6040 */ { MAD_F(0x06b6b5c4) /* 0.419606940 */, 18 }, - /* 6041 */ { MAD_F(0x06b716e6) /* 0.419699571 */, 18 }, - /* 6042 */ { MAD_F(0x06b77808) /* 0.419792208 */, 18 }, - /* 6043 */ { MAD_F(0x06b7d92d) /* 0.419884849 */, 18 }, - /* 6044 */ { MAD_F(0x06b83a52) /* 0.419977495 */, 18 }, - /* 6045 */ { MAD_F(0x06b89b79) /* 0.420070147 */, 18 }, - /* 6046 */ { MAD_F(0x06b8fca1) /* 0.420162803 */, 18 }, - /* 6047 */ { MAD_F(0x06b95dcb) /* 0.420255465 */, 18 }, - - /* 6048 */ { MAD_F(0x06b9bef6) /* 0.420348132 */, 18 }, - /* 6049 */ { MAD_F(0x06ba2023) /* 0.420440803 */, 18 }, - /* 6050 */ { MAD_F(0x06ba8150) /* 0.420533481 */, 18 }, - /* 6051 */ { MAD_F(0x06bae280) /* 0.420626163 */, 18 }, - /* 6052 */ { MAD_F(0x06bb43b0) /* 0.420718850 */, 18 }, - /* 6053 */ { MAD_F(0x06bba4e2) /* 0.420811542 */, 18 }, - /* 6054 */ { MAD_F(0x06bc0615) /* 0.420904240 */, 18 }, - /* 6055 */ { MAD_F(0x06bc674a) /* 0.420996942 */, 18 }, - /* 6056 */ { MAD_F(0x06bcc880) /* 0.421089650 */, 18 }, - /* 6057 */ { MAD_F(0x06bd29b7) /* 0.421182362 */, 18 }, - /* 6058 */ { MAD_F(0x06bd8af0) /* 0.421275080 */, 18 }, - /* 6059 */ { MAD_F(0x06bdec2a) /* 0.421367803 */, 18 }, - /* 6060 */ { MAD_F(0x06be4d66) /* 0.421460531 */, 18 }, - /* 6061 */ { MAD_F(0x06beaea3) /* 0.421553264 */, 18 }, - /* 6062 */ { MAD_F(0x06bf0fe1) /* 0.421646003 */, 18 }, - /* 6063 */ { MAD_F(0x06bf7120) /* 0.421738746 */, 18 }, - - /* 6064 */ { MAD_F(0x06bfd261) /* 0.421831494 */, 18 }, - /* 6065 */ { MAD_F(0x06c033a4) /* 0.421924248 */, 18 }, - /* 6066 */ { MAD_F(0x06c094e7) /* 0.422017007 */, 18 }, - /* 6067 */ { MAD_F(0x06c0f62c) /* 0.422109770 */, 18 }, - /* 6068 */ { MAD_F(0x06c15773) /* 0.422202539 */, 18 }, - /* 6069 */ { MAD_F(0x06c1b8bb) /* 0.422295313 */, 18 }, - /* 6070 */ { MAD_F(0x06c21a04) /* 0.422388092 */, 18 }, - /* 6071 */ { MAD_F(0x06c27b4e) /* 0.422480876 */, 18 }, - /* 6072 */ { MAD_F(0x06c2dc9a) /* 0.422573665 */, 18 }, - /* 6073 */ { MAD_F(0x06c33de8) /* 0.422666460 */, 18 }, - /* 6074 */ { MAD_F(0x06c39f36) /* 0.422759259 */, 18 }, - /* 6075 */ { MAD_F(0x06c40086) /* 0.422852064 */, 18 }, - /* 6076 */ { MAD_F(0x06c461d8) /* 0.422944873 */, 18 }, - /* 6077 */ { MAD_F(0x06c4c32a) /* 0.423037688 */, 18 }, - /* 6078 */ { MAD_F(0x06c5247f) /* 0.423130508 */, 18 }, - /* 6079 */ { MAD_F(0x06c585d4) /* 0.423223333 */, 18 }, - - /* 6080 */ { MAD_F(0x06c5e72b) /* 0.423316162 */, 18 }, - /* 6081 */ { MAD_F(0x06c64883) /* 0.423408997 */, 18 }, - /* 6082 */ { MAD_F(0x06c6a9dd) /* 0.423501838 */, 18 }, - /* 6083 */ { MAD_F(0x06c70b38) /* 0.423594683 */, 18 }, - /* 6084 */ { MAD_F(0x06c76c94) /* 0.423687533 */, 18 }, - /* 6085 */ { MAD_F(0x06c7cdf2) /* 0.423780389 */, 18 }, - /* 6086 */ { MAD_F(0x06c82f51) /* 0.423873249 */, 18 }, - /* 6087 */ { MAD_F(0x06c890b1) /* 0.423966115 */, 18 }, - /* 6088 */ { MAD_F(0x06c8f213) /* 0.424058985 */, 18 }, - /* 6089 */ { MAD_F(0x06c95376) /* 0.424151861 */, 18 }, - /* 6090 */ { MAD_F(0x06c9b4da) /* 0.424244742 */, 18 }, - /* 6091 */ { MAD_F(0x06ca1640) /* 0.424337628 */, 18 }, - /* 6092 */ { MAD_F(0x06ca77a8) /* 0.424430519 */, 18 }, - /* 6093 */ { MAD_F(0x06cad910) /* 0.424523415 */, 18 }, - /* 6094 */ { MAD_F(0x06cb3a7a) /* 0.424616316 */, 18 }, - /* 6095 */ { MAD_F(0x06cb9be5) /* 0.424709222 */, 18 }, - - /* 6096 */ { MAD_F(0x06cbfd52) /* 0.424802133 */, 18 }, - /* 6097 */ { MAD_F(0x06cc5ec0) /* 0.424895050 */, 18 }, - /* 6098 */ { MAD_F(0x06ccc030) /* 0.424987971 */, 18 }, - /* 6099 */ { MAD_F(0x06cd21a0) /* 0.425080898 */, 18 }, - /* 6100 */ { MAD_F(0x06cd8313) /* 0.425173829 */, 18 }, - /* 6101 */ { MAD_F(0x06cde486) /* 0.425266766 */, 18 }, - /* 6102 */ { MAD_F(0x06ce45fb) /* 0.425359708 */, 18 }, - /* 6103 */ { MAD_F(0x06cea771) /* 0.425452655 */, 18 }, - /* 6104 */ { MAD_F(0x06cf08e9) /* 0.425545607 */, 18 }, - /* 6105 */ { MAD_F(0x06cf6a62) /* 0.425638564 */, 18 }, - /* 6106 */ { MAD_F(0x06cfcbdc) /* 0.425731526 */, 18 }, - /* 6107 */ { MAD_F(0x06d02d58) /* 0.425824493 */, 18 }, - /* 6108 */ { MAD_F(0x06d08ed5) /* 0.425917465 */, 18 }, - /* 6109 */ { MAD_F(0x06d0f053) /* 0.426010443 */, 18 }, - /* 6110 */ { MAD_F(0x06d151d3) /* 0.426103425 */, 18 }, - /* 6111 */ { MAD_F(0x06d1b354) /* 0.426196412 */, 18 }, - - /* 6112 */ { MAD_F(0x06d214d7) /* 0.426289405 */, 18 }, - /* 6113 */ { MAD_F(0x06d2765a) /* 0.426382403 */, 18 }, - /* 6114 */ { MAD_F(0x06d2d7e0) /* 0.426475405 */, 18 }, - /* 6115 */ { MAD_F(0x06d33966) /* 0.426568413 */, 18 }, - /* 6116 */ { MAD_F(0x06d39aee) /* 0.426661426 */, 18 }, - /* 6117 */ { MAD_F(0x06d3fc77) /* 0.426754444 */, 18 }, - /* 6118 */ { MAD_F(0x06d45e02) /* 0.426847467 */, 18 }, - /* 6119 */ { MAD_F(0x06d4bf8e) /* 0.426940495 */, 18 }, - /* 6120 */ { MAD_F(0x06d5211c) /* 0.427033528 */, 18 }, - /* 6121 */ { MAD_F(0x06d582aa) /* 0.427126566 */, 18 }, - /* 6122 */ { MAD_F(0x06d5e43a) /* 0.427219609 */, 18 }, - /* 6123 */ { MAD_F(0x06d645cc) /* 0.427312657 */, 18 }, - /* 6124 */ { MAD_F(0x06d6a75f) /* 0.427405711 */, 18 }, - /* 6125 */ { MAD_F(0x06d708f3) /* 0.427498769 */, 18 }, - /* 6126 */ { MAD_F(0x06d76a88) /* 0.427591833 */, 18 }, - /* 6127 */ { MAD_F(0x06d7cc1f) /* 0.427684901 */, 18 }, - - /* 6128 */ { MAD_F(0x06d82db8) /* 0.427777975 */, 18 }, - /* 6129 */ { MAD_F(0x06d88f51) /* 0.427871054 */, 18 }, - /* 6130 */ { MAD_F(0x06d8f0ec) /* 0.427964137 */, 18 }, - /* 6131 */ { MAD_F(0x06d95288) /* 0.428057226 */, 18 }, - /* 6132 */ { MAD_F(0x06d9b426) /* 0.428150320 */, 18 }, - /* 6133 */ { MAD_F(0x06da15c5) /* 0.428243419 */, 18 }, - /* 6134 */ { MAD_F(0x06da7766) /* 0.428336523 */, 18 }, - /* 6135 */ { MAD_F(0x06dad907) /* 0.428429632 */, 18 }, - /* 6136 */ { MAD_F(0x06db3aaa) /* 0.428522746 */, 18 }, - /* 6137 */ { MAD_F(0x06db9c4f) /* 0.428615865 */, 18 }, - /* 6138 */ { MAD_F(0x06dbfdf5) /* 0.428708989 */, 18 }, - /* 6139 */ { MAD_F(0x06dc5f9c) /* 0.428802119 */, 18 }, - /* 6140 */ { MAD_F(0x06dcc145) /* 0.428895253 */, 18 }, - /* 6141 */ { MAD_F(0x06dd22ee) /* 0.428988392 */, 18 }, - /* 6142 */ { MAD_F(0x06dd849a) /* 0.429081537 */, 18 }, - /* 6143 */ { MAD_F(0x06dde646) /* 0.429174686 */, 18 }, - - /* 6144 */ { MAD_F(0x06de47f4) /* 0.429267841 */, 18 }, - /* 6145 */ { MAD_F(0x06dea9a4) /* 0.429361001 */, 18 }, - /* 6146 */ { MAD_F(0x06df0b54) /* 0.429454165 */, 18 }, - /* 6147 */ { MAD_F(0x06df6d06) /* 0.429547335 */, 18 }, - /* 6148 */ { MAD_F(0x06dfceba) /* 0.429640510 */, 18 }, - /* 6149 */ { MAD_F(0x06e0306f) /* 0.429733690 */, 18 }, - /* 6150 */ { MAD_F(0x06e09225) /* 0.429826874 */, 18 }, - /* 6151 */ { MAD_F(0x06e0f3dc) /* 0.429920064 */, 18 }, - /* 6152 */ { MAD_F(0x06e15595) /* 0.430013259 */, 18 }, - /* 6153 */ { MAD_F(0x06e1b74f) /* 0.430106459 */, 18 }, - /* 6154 */ { MAD_F(0x06e2190b) /* 0.430199664 */, 18 }, - /* 6155 */ { MAD_F(0x06e27ac8) /* 0.430292875 */, 18 }, - /* 6156 */ { MAD_F(0x06e2dc86) /* 0.430386090 */, 18 }, - /* 6157 */ { MAD_F(0x06e33e46) /* 0.430479310 */, 18 }, - /* 6158 */ { MAD_F(0x06e3a007) /* 0.430572535 */, 18 }, - /* 6159 */ { MAD_F(0x06e401c9) /* 0.430665765 */, 18 }, - - /* 6160 */ { MAD_F(0x06e4638d) /* 0.430759001 */, 18 }, - /* 6161 */ { MAD_F(0x06e4c552) /* 0.430852241 */, 18 }, - /* 6162 */ { MAD_F(0x06e52718) /* 0.430945487 */, 18 }, - /* 6163 */ { MAD_F(0x06e588e0) /* 0.431038737 */, 18 }, - /* 6164 */ { MAD_F(0x06e5eaa9) /* 0.431131993 */, 18 }, - /* 6165 */ { MAD_F(0x06e64c73) /* 0.431225253 */, 18 }, - /* 6166 */ { MAD_F(0x06e6ae3f) /* 0.431318519 */, 18 }, - /* 6167 */ { MAD_F(0x06e7100c) /* 0.431411790 */, 18 }, - /* 6168 */ { MAD_F(0x06e771db) /* 0.431505065 */, 18 }, - /* 6169 */ { MAD_F(0x06e7d3ab) /* 0.431598346 */, 18 }, - /* 6170 */ { MAD_F(0x06e8357c) /* 0.431691632 */, 18 }, - /* 6171 */ { MAD_F(0x06e8974e) /* 0.431784923 */, 18 }, - /* 6172 */ { MAD_F(0x06e8f922) /* 0.431878218 */, 18 }, - /* 6173 */ { MAD_F(0x06e95af8) /* 0.431971519 */, 18 }, - /* 6174 */ { MAD_F(0x06e9bcce) /* 0.432064825 */, 18 }, - /* 6175 */ { MAD_F(0x06ea1ea6) /* 0.432158136 */, 18 }, - - /* 6176 */ { MAD_F(0x06ea807f) /* 0.432251452 */, 18 }, - /* 6177 */ { MAD_F(0x06eae25a) /* 0.432344773 */, 18 }, - /* 6178 */ { MAD_F(0x06eb4436) /* 0.432438099 */, 18 }, - /* 6179 */ { MAD_F(0x06eba614) /* 0.432531431 */, 18 }, - /* 6180 */ { MAD_F(0x06ec07f2) /* 0.432624767 */, 18 }, - /* 6181 */ { MAD_F(0x06ec69d2) /* 0.432718108 */, 18 }, - /* 6182 */ { MAD_F(0x06eccbb4) /* 0.432811454 */, 18 }, - /* 6183 */ { MAD_F(0x06ed2d97) /* 0.432904805 */, 18 }, - /* 6184 */ { MAD_F(0x06ed8f7b) /* 0.432998162 */, 18 }, - /* 6185 */ { MAD_F(0x06edf160) /* 0.433091523 */, 18 }, - /* 6186 */ { MAD_F(0x06ee5347) /* 0.433184889 */, 18 }, - /* 6187 */ { MAD_F(0x06eeb52f) /* 0.433278261 */, 18 }, - /* 6188 */ { MAD_F(0x06ef1719) /* 0.433371637 */, 18 }, - /* 6189 */ { MAD_F(0x06ef7904) /* 0.433465019 */, 18 }, - /* 6190 */ { MAD_F(0x06efdaf0) /* 0.433558405 */, 18 }, - /* 6191 */ { MAD_F(0x06f03cde) /* 0.433651797 */, 18 }, - - /* 6192 */ { MAD_F(0x06f09ecc) /* 0.433745193 */, 18 }, - /* 6193 */ { MAD_F(0x06f100bd) /* 0.433838595 */, 18 }, - /* 6194 */ { MAD_F(0x06f162ae) /* 0.433932001 */, 18 }, - /* 6195 */ { MAD_F(0x06f1c4a1) /* 0.434025413 */, 18 }, - /* 6196 */ { MAD_F(0x06f22696) /* 0.434118830 */, 18 }, - /* 6197 */ { MAD_F(0x06f2888b) /* 0.434212251 */, 18 }, - /* 6198 */ { MAD_F(0x06f2ea82) /* 0.434305678 */, 18 }, - /* 6199 */ { MAD_F(0x06f34c7b) /* 0.434399110 */, 18 }, - /* 6200 */ { MAD_F(0x06f3ae75) /* 0.434492546 */, 18 }, - /* 6201 */ { MAD_F(0x06f41070) /* 0.434585988 */, 18 }, - /* 6202 */ { MAD_F(0x06f4726c) /* 0.434679435 */, 18 }, - /* 6203 */ { MAD_F(0x06f4d46a) /* 0.434772887 */, 18 }, - /* 6204 */ { MAD_F(0x06f53669) /* 0.434866344 */, 18 }, - /* 6205 */ { MAD_F(0x06f59869) /* 0.434959806 */, 18 }, - /* 6206 */ { MAD_F(0x06f5fa6b) /* 0.435053272 */, 18 }, - /* 6207 */ { MAD_F(0x06f65c6e) /* 0.435146744 */, 18 }, - - /* 6208 */ { MAD_F(0x06f6be73) /* 0.435240221 */, 18 }, - /* 6209 */ { MAD_F(0x06f72079) /* 0.435333703 */, 18 }, - /* 6210 */ { MAD_F(0x06f78280) /* 0.435427190 */, 18 }, - /* 6211 */ { MAD_F(0x06f7e489) /* 0.435520682 */, 18 }, - /* 6212 */ { MAD_F(0x06f84693) /* 0.435614179 */, 18 }, - /* 6213 */ { MAD_F(0x06f8a89e) /* 0.435707681 */, 18 }, - /* 6214 */ { MAD_F(0x06f90aaa) /* 0.435801188 */, 18 }, - /* 6215 */ { MAD_F(0x06f96cb8) /* 0.435894700 */, 18 }, - /* 6216 */ { MAD_F(0x06f9cec8) /* 0.435988217 */, 18 }, - /* 6217 */ { MAD_F(0x06fa30d8) /* 0.436081739 */, 18 }, - /* 6218 */ { MAD_F(0x06fa92ea) /* 0.436175266 */, 18 }, - /* 6219 */ { MAD_F(0x06faf4fe) /* 0.436268799 */, 18 }, - /* 6220 */ { MAD_F(0x06fb5712) /* 0.436362336 */, 18 }, - /* 6221 */ { MAD_F(0x06fbb928) /* 0.436455878 */, 18 }, - /* 6222 */ { MAD_F(0x06fc1b40) /* 0.436549425 */, 18 }, - /* 6223 */ { MAD_F(0x06fc7d58) /* 0.436642977 */, 18 }, - - /* 6224 */ { MAD_F(0x06fcdf72) /* 0.436736534 */, 18 }, - /* 6225 */ { MAD_F(0x06fd418e) /* 0.436830096 */, 18 }, - /* 6226 */ { MAD_F(0x06fda3ab) /* 0.436923664 */, 18 }, - /* 6227 */ { MAD_F(0x06fe05c9) /* 0.437017236 */, 18 }, - /* 6228 */ { MAD_F(0x06fe67e8) /* 0.437110813 */, 18 }, - /* 6229 */ { MAD_F(0x06feca09) /* 0.437204395 */, 18 }, - /* 6230 */ { MAD_F(0x06ff2c2b) /* 0.437297982 */, 18 }, - /* 6231 */ { MAD_F(0x06ff8e4f) /* 0.437391575 */, 18 }, - /* 6232 */ { MAD_F(0x06fff073) /* 0.437485172 */, 18 }, - /* 6233 */ { MAD_F(0x0700529a) /* 0.437578774 */, 18 }, - /* 6234 */ { MAD_F(0x0700b4c1) /* 0.437672381 */, 18 }, - /* 6235 */ { MAD_F(0x070116ea) /* 0.437765994 */, 18 }, - /* 6236 */ { MAD_F(0x07017914) /* 0.437859611 */, 18 }, - /* 6237 */ { MAD_F(0x0701db40) /* 0.437953233 */, 18 }, - /* 6238 */ { MAD_F(0x07023d6c) /* 0.438046860 */, 18 }, - /* 6239 */ { MAD_F(0x07029f9b) /* 0.438140493 */, 18 }, - - /* 6240 */ { MAD_F(0x070301ca) /* 0.438234130 */, 18 }, - /* 6241 */ { MAD_F(0x070363fb) /* 0.438327772 */, 18 }, - /* 6242 */ { MAD_F(0x0703c62d) /* 0.438421419 */, 18 }, - /* 6243 */ { MAD_F(0x07042861) /* 0.438515072 */, 18 }, - /* 6244 */ { MAD_F(0x07048a96) /* 0.438608729 */, 18 }, - /* 6245 */ { MAD_F(0x0704eccc) /* 0.438702391 */, 18 }, - /* 6246 */ { MAD_F(0x07054f04) /* 0.438796059 */, 18 }, - /* 6247 */ { MAD_F(0x0705b13d) /* 0.438889731 */, 18 }, - /* 6248 */ { MAD_F(0x07061377) /* 0.438983408 */, 18 }, - /* 6249 */ { MAD_F(0x070675b3) /* 0.439077090 */, 18 }, - /* 6250 */ { MAD_F(0x0706d7f0) /* 0.439170778 */, 18 }, - /* 6251 */ { MAD_F(0x07073a2e) /* 0.439264470 */, 18 }, - /* 6252 */ { MAD_F(0x07079c6e) /* 0.439358167 */, 18 }, - /* 6253 */ { MAD_F(0x0707feaf) /* 0.439451869 */, 18 }, - /* 6254 */ { MAD_F(0x070860f1) /* 0.439545577 */, 18 }, - /* 6255 */ { MAD_F(0x0708c335) /* 0.439639289 */, 18 }, - - /* 6256 */ { MAD_F(0x0709257a) /* 0.439733006 */, 18 }, - /* 6257 */ { MAD_F(0x070987c0) /* 0.439826728 */, 18 }, - /* 6258 */ { MAD_F(0x0709ea08) /* 0.439920456 */, 18 }, - /* 6259 */ { MAD_F(0x070a4c51) /* 0.440014188 */, 18 }, - /* 6260 */ { MAD_F(0x070aae9b) /* 0.440107925 */, 18 }, - /* 6261 */ { MAD_F(0x070b10e7) /* 0.440201667 */, 18 }, - /* 6262 */ { MAD_F(0x070b7334) /* 0.440295414 */, 18 }, - /* 6263 */ { MAD_F(0x070bd583) /* 0.440389167 */, 18 }, - /* 6264 */ { MAD_F(0x070c37d2) /* 0.440482924 */, 18 }, - /* 6265 */ { MAD_F(0x070c9a23) /* 0.440576686 */, 18 }, - /* 6266 */ { MAD_F(0x070cfc76) /* 0.440670453 */, 18 }, - /* 6267 */ { MAD_F(0x070d5eca) /* 0.440764225 */, 18 }, - /* 6268 */ { MAD_F(0x070dc11f) /* 0.440858002 */, 18 }, - /* 6269 */ { MAD_F(0x070e2375) /* 0.440951784 */, 18 }, - /* 6270 */ { MAD_F(0x070e85cd) /* 0.441045572 */, 18 }, - /* 6271 */ { MAD_F(0x070ee826) /* 0.441139364 */, 18 }, - - /* 6272 */ { MAD_F(0x070f4a80) /* 0.441233161 */, 18 }, - /* 6273 */ { MAD_F(0x070facdc) /* 0.441326963 */, 18 }, - /* 6274 */ { MAD_F(0x07100f39) /* 0.441420770 */, 18 }, - /* 6275 */ { MAD_F(0x07107198) /* 0.441514582 */, 18 }, - /* 6276 */ { MAD_F(0x0710d3f8) /* 0.441608399 */, 18 }, - /* 6277 */ { MAD_F(0x07113659) /* 0.441702221 */, 18 }, - /* 6278 */ { MAD_F(0x071198bb) /* 0.441796048 */, 18 }, - /* 6279 */ { MAD_F(0x0711fb1f) /* 0.441889880 */, 18 }, - /* 6280 */ { MAD_F(0x07125d84) /* 0.441983717 */, 18 }, - /* 6281 */ { MAD_F(0x0712bfeb) /* 0.442077559 */, 18 }, - /* 6282 */ { MAD_F(0x07132253) /* 0.442171406 */, 18 }, - /* 6283 */ { MAD_F(0x071384bc) /* 0.442265257 */, 18 }, - /* 6284 */ { MAD_F(0x0713e726) /* 0.442359114 */, 18 }, - /* 6285 */ { MAD_F(0x07144992) /* 0.442452976 */, 18 }, - /* 6286 */ { MAD_F(0x0714abff) /* 0.442546843 */, 18 }, - /* 6287 */ { MAD_F(0x07150e6e) /* 0.442640715 */, 18 }, - - /* 6288 */ { MAD_F(0x071570de) /* 0.442734592 */, 18 }, - /* 6289 */ { MAD_F(0x0715d34f) /* 0.442828473 */, 18 }, - /* 6290 */ { MAD_F(0x071635c1) /* 0.442922360 */, 18 }, - /* 6291 */ { MAD_F(0x07169835) /* 0.443016252 */, 18 }, - /* 6292 */ { MAD_F(0x0716faaa) /* 0.443110148 */, 18 }, - /* 6293 */ { MAD_F(0x07175d21) /* 0.443204050 */, 18 }, - /* 6294 */ { MAD_F(0x0717bf99) /* 0.443297957 */, 18 }, - /* 6295 */ { MAD_F(0x07182212) /* 0.443391868 */, 18 }, - /* 6296 */ { MAD_F(0x0718848d) /* 0.443485785 */, 18 }, - /* 6297 */ { MAD_F(0x0718e709) /* 0.443579706 */, 18 }, - /* 6298 */ { MAD_F(0x07194986) /* 0.443673633 */, 18 }, - /* 6299 */ { MAD_F(0x0719ac04) /* 0.443767564 */, 18 }, - /* 6300 */ { MAD_F(0x071a0e84) /* 0.443861501 */, 18 }, - /* 6301 */ { MAD_F(0x071a7105) /* 0.443955442 */, 18 }, - /* 6302 */ { MAD_F(0x071ad388) /* 0.444049389 */, 18 }, - /* 6303 */ { MAD_F(0x071b360c) /* 0.444143340 */, 18 }, - - /* 6304 */ { MAD_F(0x071b9891) /* 0.444237296 */, 18 }, - /* 6305 */ { MAD_F(0x071bfb18) /* 0.444331258 */, 18 }, - /* 6306 */ { MAD_F(0x071c5d9f) /* 0.444425224 */, 18 }, - /* 6307 */ { MAD_F(0x071cc029) /* 0.444519195 */, 18 }, - /* 6308 */ { MAD_F(0x071d22b3) /* 0.444613171 */, 18 }, - /* 6309 */ { MAD_F(0x071d853f) /* 0.444707153 */, 18 }, - /* 6310 */ { MAD_F(0x071de7cc) /* 0.444801139 */, 18 }, - /* 6311 */ { MAD_F(0x071e4a5b) /* 0.444895130 */, 18 }, - /* 6312 */ { MAD_F(0x071eaceb) /* 0.444989126 */, 18 }, - /* 6313 */ { MAD_F(0x071f0f7c) /* 0.445083127 */, 18 }, - /* 6314 */ { MAD_F(0x071f720e) /* 0.445177133 */, 18 }, - /* 6315 */ { MAD_F(0x071fd4a2) /* 0.445271144 */, 18 }, - /* 6316 */ { MAD_F(0x07203737) /* 0.445365160 */, 18 }, - /* 6317 */ { MAD_F(0x072099ce) /* 0.445459181 */, 18 }, - /* 6318 */ { MAD_F(0x0720fc66) /* 0.445553206 */, 18 }, - /* 6319 */ { MAD_F(0x07215eff) /* 0.445647237 */, 18 }, - - /* 6320 */ { MAD_F(0x0721c19a) /* 0.445741273 */, 18 }, - /* 6321 */ { MAD_F(0x07222436) /* 0.445835314 */, 18 }, - /* 6322 */ { MAD_F(0x072286d3) /* 0.445929359 */, 18 }, - /* 6323 */ { MAD_F(0x0722e971) /* 0.446023410 */, 18 }, - /* 6324 */ { MAD_F(0x07234c11) /* 0.446117466 */, 18 }, - /* 6325 */ { MAD_F(0x0723aeb2) /* 0.446211526 */, 18 }, - /* 6326 */ { MAD_F(0x07241155) /* 0.446305592 */, 18 }, - /* 6327 */ { MAD_F(0x072473f9) /* 0.446399662 */, 18 }, - /* 6328 */ { MAD_F(0x0724d69e) /* 0.446493738 */, 18 }, - /* 6329 */ { MAD_F(0x07253944) /* 0.446587818 */, 18 }, - /* 6330 */ { MAD_F(0x07259bec) /* 0.446681903 */, 18 }, - /* 6331 */ { MAD_F(0x0725fe95) /* 0.446775994 */, 18 }, - /* 6332 */ { MAD_F(0x07266140) /* 0.446870089 */, 18 }, - /* 6333 */ { MAD_F(0x0726c3ec) /* 0.446964189 */, 18 }, - /* 6334 */ { MAD_F(0x07272699) /* 0.447058294 */, 18 }, - /* 6335 */ { MAD_F(0x07278947) /* 0.447152404 */, 18 }, - - /* 6336 */ { MAD_F(0x0727ebf7) /* 0.447246519 */, 18 }, - /* 6337 */ { MAD_F(0x07284ea8) /* 0.447340639 */, 18 }, - /* 6338 */ { MAD_F(0x0728b15b) /* 0.447434764 */, 18 }, - /* 6339 */ { MAD_F(0x0729140f) /* 0.447528894 */, 18 }, - /* 6340 */ { MAD_F(0x072976c4) /* 0.447623029 */, 18 }, - /* 6341 */ { MAD_F(0x0729d97a) /* 0.447717169 */, 18 }, - /* 6342 */ { MAD_F(0x072a3c32) /* 0.447811314 */, 18 }, - /* 6343 */ { MAD_F(0x072a9eeb) /* 0.447905463 */, 18 }, - /* 6344 */ { MAD_F(0x072b01a6) /* 0.447999618 */, 18 }, - /* 6345 */ { MAD_F(0x072b6461) /* 0.448093778 */, 18 }, - /* 6346 */ { MAD_F(0x072bc71e) /* 0.448187942 */, 18 }, - /* 6347 */ { MAD_F(0x072c29dd) /* 0.448282112 */, 18 }, - /* 6348 */ { MAD_F(0x072c8c9d) /* 0.448376286 */, 18 }, - /* 6349 */ { MAD_F(0x072cef5e) /* 0.448470466 */, 18 }, - /* 6350 */ { MAD_F(0x072d5220) /* 0.448564650 */, 18 }, - /* 6351 */ { MAD_F(0x072db4e4) /* 0.448658839 */, 18 }, - - /* 6352 */ { MAD_F(0x072e17a9) /* 0.448753033 */, 18 }, - /* 6353 */ { MAD_F(0x072e7a6f) /* 0.448847233 */, 18 }, - /* 6354 */ { MAD_F(0x072edd37) /* 0.448941437 */, 18 }, - /* 6355 */ { MAD_F(0x072f4000) /* 0.449035646 */, 18 }, - /* 6356 */ { MAD_F(0x072fa2ca) /* 0.449129860 */, 18 }, - /* 6357 */ { MAD_F(0x07300596) /* 0.449224079 */, 18 }, - /* 6358 */ { MAD_F(0x07306863) /* 0.449318303 */, 18 }, - /* 6359 */ { MAD_F(0x0730cb32) /* 0.449412531 */, 18 }, - /* 6360 */ { MAD_F(0x07312e01) /* 0.449506765 */, 18 }, - /* 6361 */ { MAD_F(0x073190d2) /* 0.449601004 */, 18 }, - /* 6362 */ { MAD_F(0x0731f3a5) /* 0.449695247 */, 18 }, - /* 6363 */ { MAD_F(0x07325678) /* 0.449789496 */, 18 }, - /* 6364 */ { MAD_F(0x0732b94d) /* 0.449883749 */, 18 }, - /* 6365 */ { MAD_F(0x07331c23) /* 0.449978008 */, 18 }, - /* 6366 */ { MAD_F(0x07337efb) /* 0.450072271 */, 18 }, - /* 6367 */ { MAD_F(0x0733e1d4) /* 0.450166540 */, 18 }, - - /* 6368 */ { MAD_F(0x073444ae) /* 0.450260813 */, 18 }, - /* 6369 */ { MAD_F(0x0734a78a) /* 0.450355091 */, 18 }, - /* 6370 */ { MAD_F(0x07350a67) /* 0.450449374 */, 18 }, - /* 6371 */ { MAD_F(0x07356d45) /* 0.450543662 */, 18 }, - /* 6372 */ { MAD_F(0x0735d025) /* 0.450637955 */, 18 }, - /* 6373 */ { MAD_F(0x07363306) /* 0.450732253 */, 18 }, - /* 6374 */ { MAD_F(0x073695e8) /* 0.450826556 */, 18 }, - /* 6375 */ { MAD_F(0x0736f8cb) /* 0.450920864 */, 18 }, - /* 6376 */ { MAD_F(0x07375bb0) /* 0.451015176 */, 18 }, - /* 6377 */ { MAD_F(0x0737be96) /* 0.451109494 */, 18 }, - /* 6378 */ { MAD_F(0x0738217e) /* 0.451203817 */, 18 }, - /* 6379 */ { MAD_F(0x07388467) /* 0.451298144 */, 18 }, - /* 6380 */ { MAD_F(0x0738e751) /* 0.451392477 */, 18 }, - /* 6381 */ { MAD_F(0x07394a3d) /* 0.451486814 */, 18 }, - /* 6382 */ { MAD_F(0x0739ad29) /* 0.451581156 */, 18 }, - /* 6383 */ { MAD_F(0x073a1017) /* 0.451675503 */, 18 }, - - /* 6384 */ { MAD_F(0x073a7307) /* 0.451769856 */, 18 }, - /* 6385 */ { MAD_F(0x073ad5f8) /* 0.451864213 */, 18 }, - /* 6386 */ { MAD_F(0x073b38ea) /* 0.451958575 */, 18 }, - /* 6387 */ { MAD_F(0x073b9bdd) /* 0.452052942 */, 18 }, - /* 6388 */ { MAD_F(0x073bfed2) /* 0.452147313 */, 18 }, - /* 6389 */ { MAD_F(0x073c61c8) /* 0.452241690 */, 18 }, - /* 6390 */ { MAD_F(0x073cc4bf) /* 0.452336072 */, 18 }, - /* 6391 */ { MAD_F(0x073d27b8) /* 0.452430458 */, 18 }, - /* 6392 */ { MAD_F(0x073d8ab2) /* 0.452524850 */, 18 }, - /* 6393 */ { MAD_F(0x073dedae) /* 0.452619246 */, 18 }, - /* 6394 */ { MAD_F(0x073e50aa) /* 0.452713648 */, 18 }, - /* 6395 */ { MAD_F(0x073eb3a8) /* 0.452808054 */, 18 }, - /* 6396 */ { MAD_F(0x073f16a8) /* 0.452902465 */, 18 }, - /* 6397 */ { MAD_F(0x073f79a8) /* 0.452996882 */, 18 }, - /* 6398 */ { MAD_F(0x073fdcaa) /* 0.453091303 */, 18 }, - /* 6399 */ { MAD_F(0x07403fad) /* 0.453185729 */, 18 }, - - /* 6400 */ { MAD_F(0x0740a2b2) /* 0.453280160 */, 18 }, - /* 6401 */ { MAD_F(0x074105b8) /* 0.453374595 */, 18 }, - /* 6402 */ { MAD_F(0x074168bf) /* 0.453469036 */, 18 }, - /* 6403 */ { MAD_F(0x0741cbc8) /* 0.453563482 */, 18 }, - /* 6404 */ { MAD_F(0x07422ed2) /* 0.453657932 */, 18 }, - /* 6405 */ { MAD_F(0x074291dd) /* 0.453752388 */, 18 }, - /* 6406 */ { MAD_F(0x0742f4e9) /* 0.453846848 */, 18 }, - /* 6407 */ { MAD_F(0x074357f7) /* 0.453941314 */, 18 }, - /* 6408 */ { MAD_F(0x0743bb06) /* 0.454035784 */, 18 }, - /* 6409 */ { MAD_F(0x07441e17) /* 0.454130259 */, 18 }, - /* 6410 */ { MAD_F(0x07448129) /* 0.454224739 */, 18 }, - /* 6411 */ { MAD_F(0x0744e43c) /* 0.454319224 */, 18 }, - /* 6412 */ { MAD_F(0x07454750) /* 0.454413714 */, 18 }, - /* 6413 */ { MAD_F(0x0745aa66) /* 0.454508209 */, 18 }, - /* 6414 */ { MAD_F(0x07460d7d) /* 0.454602708 */, 18 }, - /* 6415 */ { MAD_F(0x07467095) /* 0.454697213 */, 18 }, - - /* 6416 */ { MAD_F(0x0746d3af) /* 0.454791723 */, 18 }, - /* 6417 */ { MAD_F(0x074736ca) /* 0.454886237 */, 18 }, - /* 6418 */ { MAD_F(0x074799e7) /* 0.454980756 */, 18 }, - /* 6419 */ { MAD_F(0x0747fd04) /* 0.455075281 */, 18 }, - /* 6420 */ { MAD_F(0x07486023) /* 0.455169810 */, 18 }, - /* 6421 */ { MAD_F(0x0748c344) /* 0.455264344 */, 18 }, - /* 6422 */ { MAD_F(0x07492665) /* 0.455358883 */, 18 }, - /* 6423 */ { MAD_F(0x07498988) /* 0.455453427 */, 18 }, - /* 6424 */ { MAD_F(0x0749ecac) /* 0.455547976 */, 18 }, - /* 6425 */ { MAD_F(0x074a4fd2) /* 0.455642529 */, 18 }, - /* 6426 */ { MAD_F(0x074ab2f9) /* 0.455737088 */, 18 }, - /* 6427 */ { MAD_F(0x074b1621) /* 0.455831652 */, 18 }, - /* 6428 */ { MAD_F(0x074b794b) /* 0.455926220 */, 18 }, - /* 6429 */ { MAD_F(0x074bdc75) /* 0.456020793 */, 18 }, - /* 6430 */ { MAD_F(0x074c3fa1) /* 0.456115372 */, 18 }, - /* 6431 */ { MAD_F(0x074ca2cf) /* 0.456209955 */, 18 }, - - /* 6432 */ { MAD_F(0x074d05fe) /* 0.456304543 */, 18 }, - /* 6433 */ { MAD_F(0x074d692e) /* 0.456399136 */, 18 }, - /* 6434 */ { MAD_F(0x074dcc5f) /* 0.456493733 */, 18 }, - /* 6435 */ { MAD_F(0x074e2f92) /* 0.456588336 */, 18 }, - /* 6436 */ { MAD_F(0x074e92c6) /* 0.456682944 */, 18 }, - /* 6437 */ { MAD_F(0x074ef5fb) /* 0.456777556 */, 18 }, - /* 6438 */ { MAD_F(0x074f5932) /* 0.456872174 */, 18 }, - /* 6439 */ { MAD_F(0x074fbc6a) /* 0.456966796 */, 18 }, - /* 6440 */ { MAD_F(0x07501fa3) /* 0.457061423 */, 18 }, - /* 6441 */ { MAD_F(0x075082de) /* 0.457156056 */, 18 }, - /* 6442 */ { MAD_F(0x0750e61a) /* 0.457250693 */, 18 }, - /* 6443 */ { MAD_F(0x07514957) /* 0.457345335 */, 18 }, - /* 6444 */ { MAD_F(0x0751ac96) /* 0.457439981 */, 18 }, - /* 6445 */ { MAD_F(0x07520fd6) /* 0.457534633 */, 18 }, - /* 6446 */ { MAD_F(0x07527317) /* 0.457629290 */, 18 }, - /* 6447 */ { MAD_F(0x0752d659) /* 0.457723951 */, 18 }, - - /* 6448 */ { MAD_F(0x0753399d) /* 0.457818618 */, 18 }, - /* 6449 */ { MAD_F(0x07539ce2) /* 0.457913289 */, 18 }, - /* 6450 */ { MAD_F(0x07540029) /* 0.458007965 */, 18 }, - /* 6451 */ { MAD_F(0x07546371) /* 0.458102646 */, 18 }, - /* 6452 */ { MAD_F(0x0754c6ba) /* 0.458197332 */, 18 }, - /* 6453 */ { MAD_F(0x07552a04) /* 0.458292023 */, 18 }, - /* 6454 */ { MAD_F(0x07558d50) /* 0.458386719 */, 18 }, - /* 6455 */ { MAD_F(0x0755f09d) /* 0.458481420 */, 18 }, - /* 6456 */ { MAD_F(0x075653eb) /* 0.458576125 */, 18 }, - /* 6457 */ { MAD_F(0x0756b73b) /* 0.458670836 */, 18 }, - /* 6458 */ { MAD_F(0x07571a8c) /* 0.458765551 */, 18 }, - /* 6459 */ { MAD_F(0x07577dde) /* 0.458860271 */, 18 }, - /* 6460 */ { MAD_F(0x0757e131) /* 0.458954996 */, 18 }, - /* 6461 */ { MAD_F(0x07584486) /* 0.459049726 */, 18 }, - /* 6462 */ { MAD_F(0x0758a7dd) /* 0.459144461 */, 18 }, - /* 6463 */ { MAD_F(0x07590b34) /* 0.459239201 */, 18 }, - - /* 6464 */ { MAD_F(0x07596e8d) /* 0.459333946 */, 18 }, - /* 6465 */ { MAD_F(0x0759d1e7) /* 0.459428695 */, 18 }, - /* 6466 */ { MAD_F(0x075a3542) /* 0.459523450 */, 18 }, - /* 6467 */ { MAD_F(0x075a989f) /* 0.459618209 */, 18 }, - /* 6468 */ { MAD_F(0x075afbfd) /* 0.459712973 */, 18 }, - /* 6469 */ { MAD_F(0x075b5f5d) /* 0.459807742 */, 18 }, - /* 6470 */ { MAD_F(0x075bc2bd) /* 0.459902516 */, 18 }, - /* 6471 */ { MAD_F(0x075c261f) /* 0.459997295 */, 18 }, - /* 6472 */ { MAD_F(0x075c8983) /* 0.460092079 */, 18 }, - /* 6473 */ { MAD_F(0x075cece7) /* 0.460186867 */, 18 }, - /* 6474 */ { MAD_F(0x075d504d) /* 0.460281661 */, 18 }, - /* 6475 */ { MAD_F(0x075db3b5) /* 0.460376459 */, 18 }, - /* 6476 */ { MAD_F(0x075e171d) /* 0.460471262 */, 18 }, - /* 6477 */ { MAD_F(0x075e7a87) /* 0.460566071 */, 18 }, - /* 6478 */ { MAD_F(0x075eddf2) /* 0.460660884 */, 18 }, - /* 6479 */ { MAD_F(0x075f415f) /* 0.460755701 */, 18 }, - - /* 6480 */ { MAD_F(0x075fa4cc) /* 0.460850524 */, 18 }, - /* 6481 */ { MAD_F(0x0760083b) /* 0.460945352 */, 18 }, - /* 6482 */ { MAD_F(0x07606bac) /* 0.461040184 */, 18 }, - /* 6483 */ { MAD_F(0x0760cf1e) /* 0.461135022 */, 18 }, - /* 6484 */ { MAD_F(0x07613291) /* 0.461229864 */, 18 }, - /* 6485 */ { MAD_F(0x07619605) /* 0.461324711 */, 18 }, - /* 6486 */ { MAD_F(0x0761f97b) /* 0.461419563 */, 18 }, - /* 6487 */ { MAD_F(0x07625cf2) /* 0.461514420 */, 18 }, - /* 6488 */ { MAD_F(0x0762c06a) /* 0.461609282 */, 18 }, - /* 6489 */ { MAD_F(0x076323e3) /* 0.461704149 */, 18 }, - /* 6490 */ { MAD_F(0x0763875e) /* 0.461799020 */, 18 }, - /* 6491 */ { MAD_F(0x0763eadb) /* 0.461893897 */, 18 }, - /* 6492 */ { MAD_F(0x07644e58) /* 0.461988778 */, 18 }, - /* 6493 */ { MAD_F(0x0764b1d7) /* 0.462083664 */, 18 }, - /* 6494 */ { MAD_F(0x07651557) /* 0.462178555 */, 18 }, - /* 6495 */ { MAD_F(0x076578d8) /* 0.462273451 */, 18 }, - - /* 6496 */ { MAD_F(0x0765dc5b) /* 0.462368352 */, 18 }, - /* 6497 */ { MAD_F(0x07663fdf) /* 0.462463257 */, 18 }, - /* 6498 */ { MAD_F(0x0766a364) /* 0.462558168 */, 18 }, - /* 6499 */ { MAD_F(0x076706eb) /* 0.462653083 */, 18 }, - /* 6500 */ { MAD_F(0x07676a73) /* 0.462748003 */, 18 }, - /* 6501 */ { MAD_F(0x0767cdfc) /* 0.462842928 */, 18 }, - /* 6502 */ { MAD_F(0x07683187) /* 0.462937858 */, 18 }, - /* 6503 */ { MAD_F(0x07689513) /* 0.463032793 */, 18 }, - /* 6504 */ { MAD_F(0x0768f8a0) /* 0.463127733 */, 18 }, - /* 6505 */ { MAD_F(0x07695c2e) /* 0.463222678 */, 18 }, - /* 6506 */ { MAD_F(0x0769bfbe) /* 0.463317627 */, 18 }, - /* 6507 */ { MAD_F(0x076a234f) /* 0.463412581 */, 18 }, - /* 6508 */ { MAD_F(0x076a86e2) /* 0.463507540 */, 18 }, - /* 6509 */ { MAD_F(0x076aea75) /* 0.463602504 */, 18 }, - /* 6510 */ { MAD_F(0x076b4e0a) /* 0.463697473 */, 18 }, - /* 6511 */ { MAD_F(0x076bb1a1) /* 0.463792447 */, 18 }, - - /* 6512 */ { MAD_F(0x076c1538) /* 0.463887426 */, 18 }, - /* 6513 */ { MAD_F(0x076c78d1) /* 0.463982409 */, 18 }, - /* 6514 */ { MAD_F(0x076cdc6c) /* 0.464077398 */, 18 }, - /* 6515 */ { MAD_F(0x076d4007) /* 0.464172391 */, 18 }, - /* 6516 */ { MAD_F(0x076da3a4) /* 0.464267389 */, 18 }, - /* 6517 */ { MAD_F(0x076e0742) /* 0.464362392 */, 18 }, - /* 6518 */ { MAD_F(0x076e6ae2) /* 0.464457399 */, 18 }, - /* 6519 */ { MAD_F(0x076ece82) /* 0.464552412 */, 18 }, - /* 6520 */ { MAD_F(0x076f3224) /* 0.464647430 */, 18 }, - /* 6521 */ { MAD_F(0x076f95c8) /* 0.464742452 */, 18 }, - /* 6522 */ { MAD_F(0x076ff96c) /* 0.464837479 */, 18 }, - /* 6523 */ { MAD_F(0x07705d12) /* 0.464932511 */, 18 }, - /* 6524 */ { MAD_F(0x0770c0ba) /* 0.465027548 */, 18 }, - /* 6525 */ { MAD_F(0x07712462) /* 0.465122590 */, 18 }, - /* 6526 */ { MAD_F(0x0771880c) /* 0.465217637 */, 18 }, - /* 6527 */ { MAD_F(0x0771ebb7) /* 0.465312688 */, 18 }, - - /* 6528 */ { MAD_F(0x07724f64) /* 0.465407744 */, 18 }, - /* 6529 */ { MAD_F(0x0772b312) /* 0.465502806 */, 18 }, - /* 6530 */ { MAD_F(0x077316c1) /* 0.465597872 */, 18 }, - /* 6531 */ { MAD_F(0x07737a71) /* 0.465692943 */, 18 }, - /* 6532 */ { MAD_F(0x0773de23) /* 0.465788018 */, 18 }, - /* 6533 */ { MAD_F(0x077441d6) /* 0.465883099 */, 18 }, - /* 6534 */ { MAD_F(0x0774a58a) /* 0.465978184 */, 18 }, - /* 6535 */ { MAD_F(0x07750940) /* 0.466073275 */, 18 }, - /* 6536 */ { MAD_F(0x07756cf7) /* 0.466168370 */, 18 }, - /* 6537 */ { MAD_F(0x0775d0af) /* 0.466263470 */, 18 }, - /* 6538 */ { MAD_F(0x07763468) /* 0.466358575 */, 18 }, - /* 6539 */ { MAD_F(0x07769823) /* 0.466453684 */, 18 }, - /* 6540 */ { MAD_F(0x0776fbdf) /* 0.466548799 */, 18 }, - /* 6541 */ { MAD_F(0x07775f9d) /* 0.466643918 */, 18 }, - /* 6542 */ { MAD_F(0x0777c35c) /* 0.466739043 */, 18 }, - /* 6543 */ { MAD_F(0x0778271c) /* 0.466834172 */, 18 }, - - /* 6544 */ { MAD_F(0x07788add) /* 0.466929306 */, 18 }, - /* 6545 */ { MAD_F(0x0778ee9f) /* 0.467024445 */, 18 }, - /* 6546 */ { MAD_F(0x07795263) /* 0.467119588 */, 18 }, - /* 6547 */ { MAD_F(0x0779b629) /* 0.467214737 */, 18 }, - /* 6548 */ { MAD_F(0x077a19ef) /* 0.467309890 */, 18 }, - /* 6549 */ { MAD_F(0x077a7db7) /* 0.467405048 */, 18 }, - /* 6550 */ { MAD_F(0x077ae180) /* 0.467500211 */, 18 }, - /* 6551 */ { MAD_F(0x077b454b) /* 0.467595379 */, 18 }, - /* 6552 */ { MAD_F(0x077ba916) /* 0.467690552 */, 18 }, - /* 6553 */ { MAD_F(0x077c0ce3) /* 0.467785729 */, 18 }, - /* 6554 */ { MAD_F(0x077c70b2) /* 0.467880912 */, 18 }, - /* 6555 */ { MAD_F(0x077cd481) /* 0.467976099 */, 18 }, - /* 6556 */ { MAD_F(0x077d3852) /* 0.468071291 */, 18 }, - /* 6557 */ { MAD_F(0x077d9c24) /* 0.468166488 */, 18 }, - /* 6558 */ { MAD_F(0x077dfff8) /* 0.468261690 */, 18 }, - /* 6559 */ { MAD_F(0x077e63cd) /* 0.468356896 */, 18 }, - - /* 6560 */ { MAD_F(0x077ec7a3) /* 0.468452108 */, 18 }, - /* 6561 */ { MAD_F(0x077f2b7a) /* 0.468547324 */, 18 }, - /* 6562 */ { MAD_F(0x077f8f53) /* 0.468642545 */, 18 }, - /* 6563 */ { MAD_F(0x077ff32d) /* 0.468737771 */, 18 }, - /* 6564 */ { MAD_F(0x07805708) /* 0.468833002 */, 18 }, - /* 6565 */ { MAD_F(0x0780bae5) /* 0.468928237 */, 18 }, - /* 6566 */ { MAD_F(0x07811ec3) /* 0.469023478 */, 18 }, - /* 6567 */ { MAD_F(0x078182a2) /* 0.469118723 */, 18 }, - /* 6568 */ { MAD_F(0x0781e683) /* 0.469213973 */, 18 }, - /* 6569 */ { MAD_F(0x07824a64) /* 0.469309228 */, 18 }, - /* 6570 */ { MAD_F(0x0782ae47) /* 0.469404488 */, 18 }, - /* 6571 */ { MAD_F(0x0783122c) /* 0.469499752 */, 18 }, - /* 6572 */ { MAD_F(0x07837612) /* 0.469595022 */, 18 }, - /* 6573 */ { MAD_F(0x0783d9f9) /* 0.469690296 */, 18 }, - /* 6574 */ { MAD_F(0x07843de1) /* 0.469785575 */, 18 }, - /* 6575 */ { MAD_F(0x0784a1ca) /* 0.469880859 */, 18 }, - - /* 6576 */ { MAD_F(0x078505b5) /* 0.469976148 */, 18 }, - /* 6577 */ { MAD_F(0x078569a2) /* 0.470071442 */, 18 }, - /* 6578 */ { MAD_F(0x0785cd8f) /* 0.470166740 */, 18 }, - /* 6579 */ { MAD_F(0x0786317e) /* 0.470262043 */, 18 }, - /* 6580 */ { MAD_F(0x0786956e) /* 0.470357351 */, 18 }, - /* 6581 */ { MAD_F(0x0786f95f) /* 0.470452664 */, 18 }, - /* 6582 */ { MAD_F(0x07875d52) /* 0.470547982 */, 18 }, - /* 6583 */ { MAD_F(0x0787c146) /* 0.470643305 */, 18 }, - /* 6584 */ { MAD_F(0x0788253b) /* 0.470738632 */, 18 }, - /* 6585 */ { MAD_F(0x07888932) /* 0.470833964 */, 18 }, - /* 6586 */ { MAD_F(0x0788ed2a) /* 0.470929301 */, 18 }, - /* 6587 */ { MAD_F(0x07895123) /* 0.471024643 */, 18 }, - /* 6588 */ { MAD_F(0x0789b51d) /* 0.471119990 */, 18 }, - /* 6589 */ { MAD_F(0x078a1919) /* 0.471215341 */, 18 }, - /* 6590 */ { MAD_F(0x078a7d16) /* 0.471310698 */, 18 }, - /* 6591 */ { MAD_F(0x078ae114) /* 0.471406059 */, 18 }, - - /* 6592 */ { MAD_F(0x078b4514) /* 0.471501425 */, 18 }, - /* 6593 */ { MAD_F(0x078ba915) /* 0.471596796 */, 18 }, - /* 6594 */ { MAD_F(0x078c0d17) /* 0.471692171 */, 18 }, - /* 6595 */ { MAD_F(0x078c711a) /* 0.471787552 */, 18 }, - /* 6596 */ { MAD_F(0x078cd51f) /* 0.471882937 */, 18 }, - /* 6597 */ { MAD_F(0x078d3925) /* 0.471978327 */, 18 }, - /* 6598 */ { MAD_F(0x078d9d2d) /* 0.472073722 */, 18 }, - /* 6599 */ { MAD_F(0x078e0135) /* 0.472169122 */, 18 }, - /* 6600 */ { MAD_F(0x078e653f) /* 0.472264527 */, 18 }, - /* 6601 */ { MAD_F(0x078ec94b) /* 0.472359936 */, 18 }, - /* 6602 */ { MAD_F(0x078f2d57) /* 0.472455350 */, 18 }, - /* 6603 */ { MAD_F(0x078f9165) /* 0.472550769 */, 18 }, - /* 6604 */ { MAD_F(0x078ff574) /* 0.472646193 */, 18 }, - /* 6605 */ { MAD_F(0x07905985) /* 0.472741622 */, 18 }, - /* 6606 */ { MAD_F(0x0790bd96) /* 0.472837055 */, 18 }, - /* 6607 */ { MAD_F(0x079121a9) /* 0.472932493 */, 18 }, - - /* 6608 */ { MAD_F(0x079185be) /* 0.473027937 */, 18 }, - /* 6609 */ { MAD_F(0x0791e9d3) /* 0.473123384 */, 18 }, - /* 6610 */ { MAD_F(0x07924dea) /* 0.473218837 */, 18 }, - /* 6611 */ { MAD_F(0x0792b202) /* 0.473314295 */, 18 }, - /* 6612 */ { MAD_F(0x0793161c) /* 0.473409757 */, 18 }, - /* 6613 */ { MAD_F(0x07937a37) /* 0.473505224 */, 18 }, - /* 6614 */ { MAD_F(0x0793de53) /* 0.473600696 */, 18 }, - /* 6615 */ { MAD_F(0x07944270) /* 0.473696173 */, 18 }, - /* 6616 */ { MAD_F(0x0794a68f) /* 0.473791655 */, 18 }, - /* 6617 */ { MAD_F(0x07950aaf) /* 0.473887141 */, 18 }, - /* 6618 */ { MAD_F(0x07956ed0) /* 0.473982632 */, 18 }, - /* 6619 */ { MAD_F(0x0795d2f2) /* 0.474078128 */, 18 }, - /* 6620 */ { MAD_F(0x07963716) /* 0.474173629 */, 18 }, - /* 6621 */ { MAD_F(0x07969b3b) /* 0.474269135 */, 18 }, - /* 6622 */ { MAD_F(0x0796ff62) /* 0.474364645 */, 18 }, - /* 6623 */ { MAD_F(0x07976389) /* 0.474460161 */, 18 }, - - /* 6624 */ { MAD_F(0x0797c7b2) /* 0.474555681 */, 18 }, - /* 6625 */ { MAD_F(0x07982bdd) /* 0.474651205 */, 18 }, - /* 6626 */ { MAD_F(0x07989008) /* 0.474746735 */, 18 }, - /* 6627 */ { MAD_F(0x0798f435) /* 0.474842270 */, 18 }, - /* 6628 */ { MAD_F(0x07995863) /* 0.474937809 */, 18 }, - /* 6629 */ { MAD_F(0x0799bc92) /* 0.475033353 */, 18 }, - /* 6630 */ { MAD_F(0x079a20c3) /* 0.475128902 */, 18 }, - /* 6631 */ { MAD_F(0x079a84f5) /* 0.475224456 */, 18 }, - /* 6632 */ { MAD_F(0x079ae929) /* 0.475320014 */, 18 }, - /* 6633 */ { MAD_F(0x079b4d5d) /* 0.475415578 */, 18 }, - /* 6634 */ { MAD_F(0x079bb193) /* 0.475511146 */, 18 }, - /* 6635 */ { MAD_F(0x079c15ca) /* 0.475606719 */, 18 }, - /* 6636 */ { MAD_F(0x079c7a03) /* 0.475702296 */, 18 }, - /* 6637 */ { MAD_F(0x079cde3c) /* 0.475797879 */, 18 }, - /* 6638 */ { MAD_F(0x079d4277) /* 0.475893466 */, 18 }, - /* 6639 */ { MAD_F(0x079da6b4) /* 0.475989058 */, 18 }, - - /* 6640 */ { MAD_F(0x079e0af1) /* 0.476084655 */, 18 }, - /* 6641 */ { MAD_F(0x079e6f30) /* 0.476180257 */, 18 }, - /* 6642 */ { MAD_F(0x079ed370) /* 0.476275863 */, 18 }, - /* 6643 */ { MAD_F(0x079f37b2) /* 0.476371475 */, 18 }, - /* 6644 */ { MAD_F(0x079f9bf5) /* 0.476467091 */, 18 }, - /* 6645 */ { MAD_F(0x07a00039) /* 0.476562712 */, 18 }, - /* 6646 */ { MAD_F(0x07a0647e) /* 0.476658338 */, 18 }, - /* 6647 */ { MAD_F(0x07a0c8c5) /* 0.476753968 */, 18 }, - /* 6648 */ { MAD_F(0x07a12d0c) /* 0.476849603 */, 18 }, - /* 6649 */ { MAD_F(0x07a19156) /* 0.476945243 */, 18 }, - /* 6650 */ { MAD_F(0x07a1f5a0) /* 0.477040888 */, 18 }, - /* 6651 */ { MAD_F(0x07a259ec) /* 0.477136538 */, 18 }, - /* 6652 */ { MAD_F(0x07a2be39) /* 0.477232193 */, 18 }, - /* 6653 */ { MAD_F(0x07a32287) /* 0.477327852 */, 18 }, - /* 6654 */ { MAD_F(0x07a386d7) /* 0.477423516 */, 18 }, - /* 6655 */ { MAD_F(0x07a3eb28) /* 0.477519185 */, 18 }, - - /* 6656 */ { MAD_F(0x07a44f7a) /* 0.477614858 */, 18 }, - /* 6657 */ { MAD_F(0x07a4b3ce) /* 0.477710537 */, 18 }, - /* 6658 */ { MAD_F(0x07a51822) /* 0.477806220 */, 18 }, - /* 6659 */ { MAD_F(0x07a57c78) /* 0.477901908 */, 18 }, - /* 6660 */ { MAD_F(0x07a5e0d0) /* 0.477997601 */, 18 }, - /* 6661 */ { MAD_F(0x07a64528) /* 0.478093299 */, 18 }, - /* 6662 */ { MAD_F(0x07a6a982) /* 0.478189001 */, 18 }, - /* 6663 */ { MAD_F(0x07a70ddd) /* 0.478284708 */, 18 }, - /* 6664 */ { MAD_F(0x07a7723a) /* 0.478380420 */, 18 }, - /* 6665 */ { MAD_F(0x07a7d698) /* 0.478476137 */, 18 }, - /* 6666 */ { MAD_F(0x07a83af7) /* 0.478571858 */, 18 }, - /* 6667 */ { MAD_F(0x07a89f57) /* 0.478667585 */, 18 }, - /* 6668 */ { MAD_F(0x07a903b9) /* 0.478763316 */, 18 }, - /* 6669 */ { MAD_F(0x07a9681c) /* 0.478859052 */, 18 }, - /* 6670 */ { MAD_F(0x07a9cc80) /* 0.478954793 */, 18 }, - /* 6671 */ { MAD_F(0x07aa30e5) /* 0.479050538 */, 18 }, - - /* 6672 */ { MAD_F(0x07aa954c) /* 0.479146288 */, 18 }, - /* 6673 */ { MAD_F(0x07aaf9b4) /* 0.479242043 */, 18 }, - /* 6674 */ { MAD_F(0x07ab5e1e) /* 0.479337803 */, 18 }, - /* 6675 */ { MAD_F(0x07abc288) /* 0.479433568 */, 18 }, - /* 6676 */ { MAD_F(0x07ac26f4) /* 0.479529337 */, 18 }, - /* 6677 */ { MAD_F(0x07ac8b61) /* 0.479625111 */, 18 }, - /* 6678 */ { MAD_F(0x07acefd0) /* 0.479720890 */, 18 }, - /* 6679 */ { MAD_F(0x07ad543f) /* 0.479816674 */, 18 }, - /* 6680 */ { MAD_F(0x07adb8b0) /* 0.479912463 */, 18 }, - /* 6681 */ { MAD_F(0x07ae1d23) /* 0.480008256 */, 18 }, - /* 6682 */ { MAD_F(0x07ae8196) /* 0.480104054 */, 18 }, - /* 6683 */ { MAD_F(0x07aee60b) /* 0.480199857 */, 18 }, - /* 6684 */ { MAD_F(0x07af4a81) /* 0.480295664 */, 18 }, - /* 6685 */ { MAD_F(0x07afaef9) /* 0.480391477 */, 18 }, - /* 6686 */ { MAD_F(0x07b01372) /* 0.480487294 */, 18 }, - /* 6687 */ { MAD_F(0x07b077ec) /* 0.480583116 */, 18 }, - - /* 6688 */ { MAD_F(0x07b0dc67) /* 0.480678943 */, 18 }, - /* 6689 */ { MAD_F(0x07b140e4) /* 0.480774774 */, 18 }, - /* 6690 */ { MAD_F(0x07b1a561) /* 0.480870611 */, 18 }, - /* 6691 */ { MAD_F(0x07b209e1) /* 0.480966452 */, 18 }, - /* 6692 */ { MAD_F(0x07b26e61) /* 0.481062298 */, 18 }, - /* 6693 */ { MAD_F(0x07b2d2e3) /* 0.481158148 */, 18 }, - /* 6694 */ { MAD_F(0x07b33766) /* 0.481254004 */, 18 }, - /* 6695 */ { MAD_F(0x07b39bea) /* 0.481349864 */, 18 }, - /* 6696 */ { MAD_F(0x07b4006f) /* 0.481445729 */, 18 }, - /* 6697 */ { MAD_F(0x07b464f6) /* 0.481541598 */, 18 }, - /* 6698 */ { MAD_F(0x07b4c97e) /* 0.481637473 */, 18 }, - /* 6699 */ { MAD_F(0x07b52e08) /* 0.481733352 */, 18 }, - /* 6700 */ { MAD_F(0x07b59292) /* 0.481829236 */, 18 }, - /* 6701 */ { MAD_F(0x07b5f71e) /* 0.481925125 */, 18 }, - /* 6702 */ { MAD_F(0x07b65bac) /* 0.482021019 */, 18 }, - /* 6703 */ { MAD_F(0x07b6c03a) /* 0.482116917 */, 18 }, - - /* 6704 */ { MAD_F(0x07b724ca) /* 0.482212820 */, 18 }, - /* 6705 */ { MAD_F(0x07b7895b) /* 0.482308728 */, 18 }, - /* 6706 */ { MAD_F(0x07b7eded) /* 0.482404640 */, 18 }, - /* 6707 */ { MAD_F(0x07b85281) /* 0.482500558 */, 18 }, - /* 6708 */ { MAD_F(0x07b8b716) /* 0.482596480 */, 18 }, - /* 6709 */ { MAD_F(0x07b91bac) /* 0.482692407 */, 18 }, - /* 6710 */ { MAD_F(0x07b98044) /* 0.482788339 */, 18 }, - /* 6711 */ { MAD_F(0x07b9e4dc) /* 0.482884275 */, 18 }, - /* 6712 */ { MAD_F(0x07ba4976) /* 0.482980216 */, 18 }, - /* 6713 */ { MAD_F(0x07baae12) /* 0.483076162 */, 18 }, - /* 6714 */ { MAD_F(0x07bb12ae) /* 0.483172113 */, 18 }, - /* 6715 */ { MAD_F(0x07bb774c) /* 0.483268069 */, 18 }, - /* 6716 */ { MAD_F(0x07bbdbeb) /* 0.483364029 */, 18 }, - /* 6717 */ { MAD_F(0x07bc408c) /* 0.483459994 */, 18 }, - /* 6718 */ { MAD_F(0x07bca52d) /* 0.483555964 */, 18 }, - /* 6719 */ { MAD_F(0x07bd09d0) /* 0.483651939 */, 18 }, - - /* 6720 */ { MAD_F(0x07bd6e75) /* 0.483747918 */, 18 }, - /* 6721 */ { MAD_F(0x07bdd31a) /* 0.483843902 */, 18 }, - /* 6722 */ { MAD_F(0x07be37c1) /* 0.483939891 */, 18 }, - /* 6723 */ { MAD_F(0x07be9c69) /* 0.484035885 */, 18 }, - /* 6724 */ { MAD_F(0x07bf0113) /* 0.484131883 */, 18 }, - /* 6725 */ { MAD_F(0x07bf65bd) /* 0.484227886 */, 18 }, - /* 6726 */ { MAD_F(0x07bfca69) /* 0.484323894 */, 18 }, - /* 6727 */ { MAD_F(0x07c02f16) /* 0.484419907 */, 18 }, - /* 6728 */ { MAD_F(0x07c093c5) /* 0.484515924 */, 18 }, - /* 6729 */ { MAD_F(0x07c0f875) /* 0.484611946 */, 18 }, - /* 6730 */ { MAD_F(0x07c15d26) /* 0.484707973 */, 18 }, - /* 6731 */ { MAD_F(0x07c1c1d8) /* 0.484804005 */, 18 }, - /* 6732 */ { MAD_F(0x07c2268b) /* 0.484900041 */, 18 }, - /* 6733 */ { MAD_F(0x07c28b40) /* 0.484996083 */, 18 }, - /* 6734 */ { MAD_F(0x07c2eff6) /* 0.485092128 */, 18 }, - /* 6735 */ { MAD_F(0x07c354ae) /* 0.485188179 */, 18 }, - - /* 6736 */ { MAD_F(0x07c3b967) /* 0.485284235 */, 18 }, - /* 6737 */ { MAD_F(0x07c41e21) /* 0.485380295 */, 18 }, - /* 6738 */ { MAD_F(0x07c482dc) /* 0.485476360 */, 18 }, - /* 6739 */ { MAD_F(0x07c4e798) /* 0.485572430 */, 18 }, - /* 6740 */ { MAD_F(0x07c54c56) /* 0.485668504 */, 18 }, - /* 6741 */ { MAD_F(0x07c5b115) /* 0.485764583 */, 18 }, - /* 6742 */ { MAD_F(0x07c615d6) /* 0.485860667 */, 18 }, - /* 6743 */ { MAD_F(0x07c67a97) /* 0.485956756 */, 18 }, - /* 6744 */ { MAD_F(0x07c6df5a) /* 0.486052849 */, 18 }, - /* 6745 */ { MAD_F(0x07c7441e) /* 0.486148948 */, 18 }, - /* 6746 */ { MAD_F(0x07c7a8e4) /* 0.486245051 */, 18 }, - /* 6747 */ { MAD_F(0x07c80daa) /* 0.486341158 */, 18 }, - /* 6748 */ { MAD_F(0x07c87272) /* 0.486437271 */, 18 }, - /* 6749 */ { MAD_F(0x07c8d73c) /* 0.486533388 */, 18 }, - /* 6750 */ { MAD_F(0x07c93c06) /* 0.486629510 */, 18 }, - /* 6751 */ { MAD_F(0x07c9a0d2) /* 0.486725637 */, 18 }, - - /* 6752 */ { MAD_F(0x07ca059f) /* 0.486821768 */, 18 }, - /* 6753 */ { MAD_F(0x07ca6a6d) /* 0.486917905 */, 18 }, - /* 6754 */ { MAD_F(0x07cacf3d) /* 0.487014045 */, 18 }, - /* 6755 */ { MAD_F(0x07cb340e) /* 0.487110191 */, 18 }, - /* 6756 */ { MAD_F(0x07cb98e0) /* 0.487206342 */, 18 }, - /* 6757 */ { MAD_F(0x07cbfdb4) /* 0.487302497 */, 18 }, - /* 6758 */ { MAD_F(0x07cc6288) /* 0.487398657 */, 18 }, - /* 6759 */ { MAD_F(0x07ccc75e) /* 0.487494821 */, 18 }, - /* 6760 */ { MAD_F(0x07cd2c36) /* 0.487590991 */, 18 }, - /* 6761 */ { MAD_F(0x07cd910e) /* 0.487687165 */, 18 }, - /* 6762 */ { MAD_F(0x07cdf5e8) /* 0.487783344 */, 18 }, - /* 6763 */ { MAD_F(0x07ce5ac3) /* 0.487879528 */, 18 }, - /* 6764 */ { MAD_F(0x07cebfa0) /* 0.487975716 */, 18 }, - /* 6765 */ { MAD_F(0x07cf247d) /* 0.488071909 */, 18 }, - /* 6766 */ { MAD_F(0x07cf895c) /* 0.488168107 */, 18 }, - /* 6767 */ { MAD_F(0x07cfee3c) /* 0.488264310 */, 18 }, - - /* 6768 */ { MAD_F(0x07d0531e) /* 0.488360517 */, 18 }, - /* 6769 */ { MAD_F(0x07d0b801) /* 0.488456729 */, 18 }, - /* 6770 */ { MAD_F(0x07d11ce5) /* 0.488552946 */, 18 }, - /* 6771 */ { MAD_F(0x07d181ca) /* 0.488649167 */, 18 }, - /* 6772 */ { MAD_F(0x07d1e6b0) /* 0.488745394 */, 18 }, - /* 6773 */ { MAD_F(0x07d24b98) /* 0.488841625 */, 18 }, - /* 6774 */ { MAD_F(0x07d2b081) /* 0.488937860 */, 18 }, - /* 6775 */ { MAD_F(0x07d3156c) /* 0.489034101 */, 18 }, - /* 6776 */ { MAD_F(0x07d37a57) /* 0.489130346 */, 18 }, - /* 6777 */ { MAD_F(0x07d3df44) /* 0.489226596 */, 18 }, - /* 6778 */ { MAD_F(0x07d44432) /* 0.489322851 */, 18 }, - /* 6779 */ { MAD_F(0x07d4a922) /* 0.489419110 */, 18 }, - /* 6780 */ { MAD_F(0x07d50e13) /* 0.489515375 */, 18 }, - /* 6781 */ { MAD_F(0x07d57305) /* 0.489611643 */, 18 }, - /* 6782 */ { MAD_F(0x07d5d7f8) /* 0.489707917 */, 18 }, - /* 6783 */ { MAD_F(0x07d63cec) /* 0.489804195 */, 18 }, - - /* 6784 */ { MAD_F(0x07d6a1e2) /* 0.489900479 */, 18 }, - /* 6785 */ { MAD_F(0x07d706d9) /* 0.489996766 */, 18 }, - /* 6786 */ { MAD_F(0x07d76bd2) /* 0.490093059 */, 18 }, - /* 6787 */ { MAD_F(0x07d7d0cb) /* 0.490189356 */, 18 }, - /* 6788 */ { MAD_F(0x07d835c6) /* 0.490285658 */, 18 }, - /* 6789 */ { MAD_F(0x07d89ac2) /* 0.490381965 */, 18 }, - /* 6790 */ { MAD_F(0x07d8ffc0) /* 0.490478277 */, 18 }, - /* 6791 */ { MAD_F(0x07d964be) /* 0.490574593 */, 18 }, - /* 6792 */ { MAD_F(0x07d9c9be) /* 0.490670914 */, 18 }, - /* 6793 */ { MAD_F(0x07da2ebf) /* 0.490767239 */, 18 }, - /* 6794 */ { MAD_F(0x07da93c2) /* 0.490863570 */, 18 }, - /* 6795 */ { MAD_F(0x07daf8c6) /* 0.490959905 */, 18 }, - /* 6796 */ { MAD_F(0x07db5dcb) /* 0.491056245 */, 18 }, - /* 6797 */ { MAD_F(0x07dbc2d1) /* 0.491152589 */, 18 }, - /* 6798 */ { MAD_F(0x07dc27d9) /* 0.491248939 */, 18 }, - /* 6799 */ { MAD_F(0x07dc8ce1) /* 0.491345293 */, 18 }, - - /* 6800 */ { MAD_F(0x07dcf1ec) /* 0.491441651 */, 18 }, - /* 6801 */ { MAD_F(0x07dd56f7) /* 0.491538015 */, 18 }, - /* 6802 */ { MAD_F(0x07ddbc04) /* 0.491634383 */, 18 }, - /* 6803 */ { MAD_F(0x07de2111) /* 0.491730756 */, 18 }, - /* 6804 */ { MAD_F(0x07de8621) /* 0.491827134 */, 18 }, - /* 6805 */ { MAD_F(0x07deeb31) /* 0.491923516 */, 18 }, - /* 6806 */ { MAD_F(0x07df5043) /* 0.492019903 */, 18 }, - /* 6807 */ { MAD_F(0x07dfb556) /* 0.492116295 */, 18 }, - /* 6808 */ { MAD_F(0x07e01a6a) /* 0.492212691 */, 18 }, - /* 6809 */ { MAD_F(0x07e07f80) /* 0.492309093 */, 18 }, - /* 6810 */ { MAD_F(0x07e0e496) /* 0.492405499 */, 18 }, - /* 6811 */ { MAD_F(0x07e149ae) /* 0.492501909 */, 18 }, - /* 6812 */ { MAD_F(0x07e1aec8) /* 0.492598325 */, 18 }, - /* 6813 */ { MAD_F(0x07e213e2) /* 0.492694745 */, 18 }, - /* 6814 */ { MAD_F(0x07e278fe) /* 0.492791170 */, 18 }, - /* 6815 */ { MAD_F(0x07e2de1b) /* 0.492887599 */, 18 }, - - /* 6816 */ { MAD_F(0x07e3433a) /* 0.492984033 */, 18 }, - /* 6817 */ { MAD_F(0x07e3a859) /* 0.493080472 */, 18 }, - /* 6818 */ { MAD_F(0x07e40d7a) /* 0.493176916 */, 18 }, - /* 6819 */ { MAD_F(0x07e4729c) /* 0.493273365 */, 18 }, - /* 6820 */ { MAD_F(0x07e4d7c0) /* 0.493369818 */, 18 }, - /* 6821 */ { MAD_F(0x07e53ce4) /* 0.493466275 */, 18 }, - /* 6822 */ { MAD_F(0x07e5a20a) /* 0.493562738 */, 18 }, - /* 6823 */ { MAD_F(0x07e60732) /* 0.493659205 */, 18 }, - /* 6824 */ { MAD_F(0x07e66c5a) /* 0.493755677 */, 18 }, - /* 6825 */ { MAD_F(0x07e6d184) /* 0.493852154 */, 18 }, - /* 6826 */ { MAD_F(0x07e736af) /* 0.493948635 */, 18 }, - /* 6827 */ { MAD_F(0x07e79bdb) /* 0.494045122 */, 18 }, - /* 6828 */ { MAD_F(0x07e80109) /* 0.494141612 */, 18 }, - /* 6829 */ { MAD_F(0x07e86638) /* 0.494238108 */, 18 }, - /* 6830 */ { MAD_F(0x07e8cb68) /* 0.494334608 */, 18 }, - /* 6831 */ { MAD_F(0x07e93099) /* 0.494431113 */, 18 }, - - /* 6832 */ { MAD_F(0x07e995cc) /* 0.494527623 */, 18 }, - /* 6833 */ { MAD_F(0x07e9fb00) /* 0.494624137 */, 18 }, - /* 6834 */ { MAD_F(0x07ea6035) /* 0.494720656 */, 18 }, - /* 6835 */ { MAD_F(0x07eac56b) /* 0.494817180 */, 18 }, - /* 6836 */ { MAD_F(0x07eb2aa3) /* 0.494913709 */, 18 }, - /* 6837 */ { MAD_F(0x07eb8fdc) /* 0.495010242 */, 18 }, - /* 6838 */ { MAD_F(0x07ebf516) /* 0.495106780 */, 18 }, - /* 6839 */ { MAD_F(0x07ec5a51) /* 0.495203322 */, 18 }, - /* 6840 */ { MAD_F(0x07ecbf8e) /* 0.495299870 */, 18 }, - /* 6841 */ { MAD_F(0x07ed24cc) /* 0.495396422 */, 18 }, - /* 6842 */ { MAD_F(0x07ed8a0b) /* 0.495492978 */, 18 }, - /* 6843 */ { MAD_F(0x07edef4c) /* 0.495589540 */, 18 }, - /* 6844 */ { MAD_F(0x07ee548e) /* 0.495686106 */, 18 }, - /* 6845 */ { MAD_F(0x07eeb9d1) /* 0.495782677 */, 18 }, - /* 6846 */ { MAD_F(0x07ef1f15) /* 0.495879252 */, 18 }, - /* 6847 */ { MAD_F(0x07ef845b) /* 0.495975833 */, 18 }, - - /* 6848 */ { MAD_F(0x07efe9a1) /* 0.496072418 */, 18 }, - /* 6849 */ { MAD_F(0x07f04ee9) /* 0.496169007 */, 18 }, - /* 6850 */ { MAD_F(0x07f0b433) /* 0.496265602 */, 18 }, - /* 6851 */ { MAD_F(0x07f1197d) /* 0.496362201 */, 18 }, - /* 6852 */ { MAD_F(0x07f17ec9) /* 0.496458804 */, 18 }, - /* 6853 */ { MAD_F(0x07f1e416) /* 0.496555413 */, 18 }, - /* 6854 */ { MAD_F(0x07f24965) /* 0.496652026 */, 18 }, - /* 6855 */ { MAD_F(0x07f2aeb5) /* 0.496748644 */, 18 }, - /* 6856 */ { MAD_F(0x07f31405) /* 0.496845266 */, 18 }, - /* 6857 */ { MAD_F(0x07f37958) /* 0.496941894 */, 18 }, - /* 6858 */ { MAD_F(0x07f3deab) /* 0.497038526 */, 18 }, - /* 6859 */ { MAD_F(0x07f44400) /* 0.497135162 */, 18 }, - /* 6860 */ { MAD_F(0x07f4a956) /* 0.497231804 */, 18 }, - /* 6861 */ { MAD_F(0x07f50ead) /* 0.497328450 */, 18 }, - /* 6862 */ { MAD_F(0x07f57405) /* 0.497425100 */, 18 }, - /* 6863 */ { MAD_F(0x07f5d95f) /* 0.497521756 */, 18 }, - - /* 6864 */ { MAD_F(0x07f63eba) /* 0.497618416 */, 18 }, - /* 6865 */ { MAD_F(0x07f6a416) /* 0.497715081 */, 18 }, - /* 6866 */ { MAD_F(0x07f70974) /* 0.497811750 */, 18 }, - /* 6867 */ { MAD_F(0x07f76ed3) /* 0.497908425 */, 18 }, - /* 6868 */ { MAD_F(0x07f7d433) /* 0.498005103 */, 18 }, - /* 6869 */ { MAD_F(0x07f83994) /* 0.498101787 */, 18 }, - /* 6870 */ { MAD_F(0x07f89ef7) /* 0.498198475 */, 18 }, - /* 6871 */ { MAD_F(0x07f9045a) /* 0.498295168 */, 18 }, - /* 6872 */ { MAD_F(0x07f969c0) /* 0.498391866 */, 18 }, - /* 6873 */ { MAD_F(0x07f9cf26) /* 0.498488568 */, 18 }, - /* 6874 */ { MAD_F(0x07fa348e) /* 0.498585275 */, 18 }, - /* 6875 */ { MAD_F(0x07fa99f6) /* 0.498681987 */, 18 }, - /* 6876 */ { MAD_F(0x07faff60) /* 0.498778704 */, 18 }, - /* 6877 */ { MAD_F(0x07fb64cc) /* 0.498875425 */, 18 }, - /* 6878 */ { MAD_F(0x07fbca38) /* 0.498972150 */, 18 }, - /* 6879 */ { MAD_F(0x07fc2fa6) /* 0.499068881 */, 18 }, - - /* 6880 */ { MAD_F(0x07fc9516) /* 0.499165616 */, 18 }, - /* 6881 */ { MAD_F(0x07fcfa86) /* 0.499262356 */, 18 }, - /* 6882 */ { MAD_F(0x07fd5ff8) /* 0.499359101 */, 18 }, - /* 6883 */ { MAD_F(0x07fdc56b) /* 0.499455850 */, 18 }, - /* 6884 */ { MAD_F(0x07fe2adf) /* 0.499552604 */, 18 }, - /* 6885 */ { MAD_F(0x07fe9054) /* 0.499649362 */, 18 }, - /* 6886 */ { MAD_F(0x07fef5cb) /* 0.499746126 */, 18 }, - /* 6887 */ { MAD_F(0x07ff5b43) /* 0.499842894 */, 18 }, - /* 6888 */ { MAD_F(0x07ffc0bc) /* 0.499939666 */, 18 }, - /* 6889 */ { MAD_F(0x0400131b) /* 0.250018222 */, 19 }, - /* 6890 */ { MAD_F(0x040045d9) /* 0.250066613 */, 19 }, - /* 6891 */ { MAD_F(0x04007897) /* 0.250115006 */, 19 }, - /* 6892 */ { MAD_F(0x0400ab57) /* 0.250163402 */, 19 }, - /* 6893 */ { MAD_F(0x0400de16) /* 0.250211800 */, 19 }, - /* 6894 */ { MAD_F(0x040110d7) /* 0.250260200 */, 19 }, - /* 6895 */ { MAD_F(0x04014398) /* 0.250308603 */, 19 }, - - /* 6896 */ { MAD_F(0x04017659) /* 0.250357008 */, 19 }, - /* 6897 */ { MAD_F(0x0401a91c) /* 0.250405415 */, 19 }, - /* 6898 */ { MAD_F(0x0401dbdf) /* 0.250453825 */, 19 }, - /* 6899 */ { MAD_F(0x04020ea2) /* 0.250502237 */, 19 }, - /* 6900 */ { MAD_F(0x04024166) /* 0.250550652 */, 19 }, - /* 6901 */ { MAD_F(0x0402742b) /* 0.250599068 */, 19 }, - /* 6902 */ { MAD_F(0x0402a6f0) /* 0.250647488 */, 19 }, - /* 6903 */ { MAD_F(0x0402d9b6) /* 0.250695909 */, 19 }, - /* 6904 */ { MAD_F(0x04030c7d) /* 0.250744333 */, 19 }, - /* 6905 */ { MAD_F(0x04033f44) /* 0.250792759 */, 19 }, - /* 6906 */ { MAD_F(0x0403720c) /* 0.250841187 */, 19 }, - /* 6907 */ { MAD_F(0x0403a4d5) /* 0.250889618 */, 19 }, - /* 6908 */ { MAD_F(0x0403d79e) /* 0.250938051 */, 19 }, - /* 6909 */ { MAD_F(0x04040a68) /* 0.250986487 */, 19 }, - /* 6910 */ { MAD_F(0x04043d32) /* 0.251034924 */, 19 }, - /* 6911 */ { MAD_F(0x04046ffd) /* 0.251083365 */, 19 }, - - /* 6912 */ { MAD_F(0x0404a2c9) /* 0.251131807 */, 19 }, - /* 6913 */ { MAD_F(0x0404d595) /* 0.251180252 */, 19 }, - /* 6914 */ { MAD_F(0x04050862) /* 0.251228699 */, 19 }, - /* 6915 */ { MAD_F(0x04053b30) /* 0.251277148 */, 19 }, - /* 6916 */ { MAD_F(0x04056dfe) /* 0.251325600 */, 19 }, - /* 6917 */ { MAD_F(0x0405a0cd) /* 0.251374054 */, 19 }, - /* 6918 */ { MAD_F(0x0405d39c) /* 0.251422511 */, 19 }, - /* 6919 */ { MAD_F(0x0406066c) /* 0.251470970 */, 19 }, - /* 6920 */ { MAD_F(0x0406393d) /* 0.251519431 */, 19 }, - /* 6921 */ { MAD_F(0x04066c0e) /* 0.251567894 */, 19 }, - /* 6922 */ { MAD_F(0x04069ee0) /* 0.251616360 */, 19 }, - /* 6923 */ { MAD_F(0x0406d1b3) /* 0.251664828 */, 19 }, - /* 6924 */ { MAD_F(0x04070486) /* 0.251713299 */, 19 }, - /* 6925 */ { MAD_F(0x0407375a) /* 0.251761772 */, 19 }, - /* 6926 */ { MAD_F(0x04076a2e) /* 0.251810247 */, 19 }, - /* 6927 */ { MAD_F(0x04079d03) /* 0.251858724 */, 19 }, - - /* 6928 */ { MAD_F(0x0407cfd9) /* 0.251907204 */, 19 }, - /* 6929 */ { MAD_F(0x040802af) /* 0.251955686 */, 19 }, - /* 6930 */ { MAD_F(0x04083586) /* 0.252004171 */, 19 }, - /* 6931 */ { MAD_F(0x0408685e) /* 0.252052658 */, 19 }, - /* 6932 */ { MAD_F(0x04089b36) /* 0.252101147 */, 19 }, - /* 6933 */ { MAD_F(0x0408ce0f) /* 0.252149638 */, 19 }, - /* 6934 */ { MAD_F(0x040900e8) /* 0.252198132 */, 19 }, - /* 6935 */ { MAD_F(0x040933c2) /* 0.252246628 */, 19 }, - /* 6936 */ { MAD_F(0x0409669d) /* 0.252295127 */, 19 }, - /* 6937 */ { MAD_F(0x04099978) /* 0.252343627 */, 19 }, - /* 6938 */ { MAD_F(0x0409cc54) /* 0.252392131 */, 19 }, - /* 6939 */ { MAD_F(0x0409ff31) /* 0.252440636 */, 19 }, - /* 6940 */ { MAD_F(0x040a320e) /* 0.252489144 */, 19 }, - /* 6941 */ { MAD_F(0x040a64ec) /* 0.252537654 */, 19 }, - /* 6942 */ { MAD_F(0x040a97cb) /* 0.252586166 */, 19 }, - /* 6943 */ { MAD_F(0x040acaaa) /* 0.252634681 */, 19 }, - - /* 6944 */ { MAD_F(0x040afd89) /* 0.252683198 */, 19 }, - /* 6945 */ { MAD_F(0x040b306a) /* 0.252731718 */, 19 }, - /* 6946 */ { MAD_F(0x040b634b) /* 0.252780240 */, 19 }, - /* 6947 */ { MAD_F(0x040b962c) /* 0.252828764 */, 19 }, - /* 6948 */ { MAD_F(0x040bc90e) /* 0.252877290 */, 19 }, - /* 6949 */ { MAD_F(0x040bfbf1) /* 0.252925819 */, 19 }, - /* 6950 */ { MAD_F(0x040c2ed5) /* 0.252974350 */, 19 }, - /* 6951 */ { MAD_F(0x040c61b9) /* 0.253022883 */, 19 }, - /* 6952 */ { MAD_F(0x040c949e) /* 0.253071419 */, 19 }, - /* 6953 */ { MAD_F(0x040cc783) /* 0.253119957 */, 19 }, - /* 6954 */ { MAD_F(0x040cfa69) /* 0.253168498 */, 19 }, - /* 6955 */ { MAD_F(0x040d2d4f) /* 0.253217040 */, 19 }, - /* 6956 */ { MAD_F(0x040d6037) /* 0.253265585 */, 19 }, - /* 6957 */ { MAD_F(0x040d931e) /* 0.253314133 */, 19 }, - /* 6958 */ { MAD_F(0x040dc607) /* 0.253362682 */, 19 }, - /* 6959 */ { MAD_F(0x040df8f0) /* 0.253411234 */, 19 }, - - /* 6960 */ { MAD_F(0x040e2bda) /* 0.253459789 */, 19 }, - /* 6961 */ { MAD_F(0x040e5ec4) /* 0.253508345 */, 19 }, - /* 6962 */ { MAD_F(0x040e91af) /* 0.253556904 */, 19 }, - /* 6963 */ { MAD_F(0x040ec49b) /* 0.253605466 */, 19 }, - /* 6964 */ { MAD_F(0x040ef787) /* 0.253654029 */, 19 }, - /* 6965 */ { MAD_F(0x040f2a74) /* 0.253702595 */, 19 }, - /* 6966 */ { MAD_F(0x040f5d61) /* 0.253751164 */, 19 }, - /* 6967 */ { MAD_F(0x040f904f) /* 0.253799734 */, 19 }, - /* 6968 */ { MAD_F(0x040fc33e) /* 0.253848307 */, 19 }, - /* 6969 */ { MAD_F(0x040ff62d) /* 0.253896883 */, 19 }, - /* 6970 */ { MAD_F(0x0410291d) /* 0.253945460 */, 19 }, - /* 6971 */ { MAD_F(0x04105c0e) /* 0.253994040 */, 19 }, - /* 6972 */ { MAD_F(0x04108eff) /* 0.254042622 */, 19 }, - /* 6973 */ { MAD_F(0x0410c1f1) /* 0.254091207 */, 19 }, - /* 6974 */ { MAD_F(0x0410f4e3) /* 0.254139794 */, 19 }, - /* 6975 */ { MAD_F(0x041127d6) /* 0.254188383 */, 19 }, - - /* 6976 */ { MAD_F(0x04115aca) /* 0.254236974 */, 19 }, - /* 6977 */ { MAD_F(0x04118dbe) /* 0.254285568 */, 19 }, - /* 6978 */ { MAD_F(0x0411c0b3) /* 0.254334165 */, 19 }, - /* 6979 */ { MAD_F(0x0411f3a9) /* 0.254382763 */, 19 }, - /* 6980 */ { MAD_F(0x0412269f) /* 0.254431364 */, 19 }, - /* 6981 */ { MAD_F(0x04125996) /* 0.254479967 */, 19 }, - /* 6982 */ { MAD_F(0x04128c8d) /* 0.254528572 */, 19 }, - /* 6983 */ { MAD_F(0x0412bf85) /* 0.254577180 */, 19 }, - /* 6984 */ { MAD_F(0x0412f27e) /* 0.254625790 */, 19 }, - /* 6985 */ { MAD_F(0x04132577) /* 0.254674403 */, 19 }, - /* 6986 */ { MAD_F(0x04135871) /* 0.254723017 */, 19 }, - /* 6987 */ { MAD_F(0x04138b6c) /* 0.254771635 */, 19 }, - /* 6988 */ { MAD_F(0x0413be67) /* 0.254820254 */, 19 }, - /* 6989 */ { MAD_F(0x0413f163) /* 0.254868876 */, 19 }, - /* 6990 */ { MAD_F(0x0414245f) /* 0.254917500 */, 19 }, - /* 6991 */ { MAD_F(0x0414575c) /* 0.254966126 */, 19 }, - - /* 6992 */ { MAD_F(0x04148a5a) /* 0.255014755 */, 19 }, - /* 6993 */ { MAD_F(0x0414bd58) /* 0.255063386 */, 19 }, - /* 6994 */ { MAD_F(0x0414f057) /* 0.255112019 */, 19 }, - /* 6995 */ { MAD_F(0x04152356) /* 0.255160655 */, 19 }, - /* 6996 */ { MAD_F(0x04155657) /* 0.255209292 */, 19 }, - /* 6997 */ { MAD_F(0x04158957) /* 0.255257933 */, 19 }, - /* 6998 */ { MAD_F(0x0415bc59) /* 0.255306575 */, 19 }, - /* 6999 */ { MAD_F(0x0415ef5b) /* 0.255355220 */, 19 }, - /* 7000 */ { MAD_F(0x0416225d) /* 0.255403867 */, 19 }, - /* 7001 */ { MAD_F(0x04165561) /* 0.255452517 */, 19 }, - /* 7002 */ { MAD_F(0x04168864) /* 0.255501169 */, 19 }, - /* 7003 */ { MAD_F(0x0416bb69) /* 0.255549823 */, 19 }, - /* 7004 */ { MAD_F(0x0416ee6e) /* 0.255598479 */, 19 }, - /* 7005 */ { MAD_F(0x04172174) /* 0.255647138 */, 19 }, - /* 7006 */ { MAD_F(0x0417547a) /* 0.255695799 */, 19 }, - /* 7007 */ { MAD_F(0x04178781) /* 0.255744463 */, 19 }, - - /* 7008 */ { MAD_F(0x0417ba89) /* 0.255793128 */, 19 }, - /* 7009 */ { MAD_F(0x0417ed91) /* 0.255841796 */, 19 }, - /* 7010 */ { MAD_F(0x0418209a) /* 0.255890467 */, 19 }, - /* 7011 */ { MAD_F(0x041853a3) /* 0.255939139 */, 19 }, - /* 7012 */ { MAD_F(0x041886ad) /* 0.255987814 */, 19 }, - /* 7013 */ { MAD_F(0x0418b9b8) /* 0.256036492 */, 19 }, - /* 7014 */ { MAD_F(0x0418ecc3) /* 0.256085171 */, 19 }, - /* 7015 */ { MAD_F(0x04191fcf) /* 0.256133853 */, 19 }, - /* 7016 */ { MAD_F(0x041952dc) /* 0.256182537 */, 19 }, - /* 7017 */ { MAD_F(0x041985e9) /* 0.256231224 */, 19 }, - /* 7018 */ { MAD_F(0x0419b8f7) /* 0.256279913 */, 19 }, - /* 7019 */ { MAD_F(0x0419ec05) /* 0.256328604 */, 19 }, - /* 7020 */ { MAD_F(0x041a1f15) /* 0.256377297 */, 19 }, - /* 7021 */ { MAD_F(0x041a5224) /* 0.256425993 */, 19 }, - /* 7022 */ { MAD_F(0x041a8534) /* 0.256474691 */, 19 }, - /* 7023 */ { MAD_F(0x041ab845) /* 0.256523392 */, 19 }, - - /* 7024 */ { MAD_F(0x041aeb57) /* 0.256572095 */, 19 }, - /* 7025 */ { MAD_F(0x041b1e69) /* 0.256620800 */, 19 }, - /* 7026 */ { MAD_F(0x041b517c) /* 0.256669507 */, 19 }, - /* 7027 */ { MAD_F(0x041b848f) /* 0.256718217 */, 19 }, - /* 7028 */ { MAD_F(0x041bb7a3) /* 0.256766929 */, 19 }, - /* 7029 */ { MAD_F(0x041beab8) /* 0.256815643 */, 19 }, - /* 7030 */ { MAD_F(0x041c1dcd) /* 0.256864359 */, 19 }, - /* 7031 */ { MAD_F(0x041c50e3) /* 0.256913078 */, 19 }, - /* 7032 */ { MAD_F(0x041c83fa) /* 0.256961800 */, 19 }, - /* 7033 */ { MAD_F(0x041cb711) /* 0.257010523 */, 19 }, - /* 7034 */ { MAD_F(0x041cea28) /* 0.257059249 */, 19 }, - /* 7035 */ { MAD_F(0x041d1d41) /* 0.257107977 */, 19 }, - /* 7036 */ { MAD_F(0x041d505a) /* 0.257156708 */, 19 }, - /* 7037 */ { MAD_F(0x041d8373) /* 0.257205440 */, 19 }, - /* 7038 */ { MAD_F(0x041db68e) /* 0.257254175 */, 19 }, - /* 7039 */ { MAD_F(0x041de9a8) /* 0.257302913 */, 19 }, - - /* 7040 */ { MAD_F(0x041e1cc4) /* 0.257351652 */, 19 }, - /* 7041 */ { MAD_F(0x041e4fe0) /* 0.257400394 */, 19 }, - /* 7042 */ { MAD_F(0x041e82fd) /* 0.257449139 */, 19 }, - /* 7043 */ { MAD_F(0x041eb61a) /* 0.257497885 */, 19 }, - /* 7044 */ { MAD_F(0x041ee938) /* 0.257546634 */, 19 }, - /* 7045 */ { MAD_F(0x041f1c57) /* 0.257595386 */, 19 }, - /* 7046 */ { MAD_F(0x041f4f76) /* 0.257644139 */, 19 }, - /* 7047 */ { MAD_F(0x041f8296) /* 0.257692895 */, 19 }, - /* 7048 */ { MAD_F(0x041fb5b6) /* 0.257741653 */, 19 }, - /* 7049 */ { MAD_F(0x041fe8d7) /* 0.257790414 */, 19 }, - /* 7050 */ { MAD_F(0x04201bf9) /* 0.257839176 */, 19 }, - /* 7051 */ { MAD_F(0x04204f1b) /* 0.257887941 */, 19 }, - /* 7052 */ { MAD_F(0x0420823e) /* 0.257936709 */, 19 }, - /* 7053 */ { MAD_F(0x0420b561) /* 0.257985478 */, 19 }, - /* 7054 */ { MAD_F(0x0420e885) /* 0.258034250 */, 19 }, - /* 7055 */ { MAD_F(0x04211baa) /* 0.258083025 */, 19 }, - - /* 7056 */ { MAD_F(0x04214ed0) /* 0.258131801 */, 19 }, - /* 7057 */ { MAD_F(0x042181f6) /* 0.258180580 */, 19 }, - /* 7058 */ { MAD_F(0x0421b51c) /* 0.258229361 */, 19 }, - /* 7059 */ { MAD_F(0x0421e843) /* 0.258278145 */, 19 }, - /* 7060 */ { MAD_F(0x04221b6b) /* 0.258326931 */, 19 }, - /* 7061 */ { MAD_F(0x04224e94) /* 0.258375719 */, 19 }, - /* 7062 */ { MAD_F(0x042281bd) /* 0.258424509 */, 19 }, - /* 7063 */ { MAD_F(0x0422b4e6) /* 0.258473302 */, 19 }, - /* 7064 */ { MAD_F(0x0422e811) /* 0.258522097 */, 19 }, - /* 7065 */ { MAD_F(0x04231b3c) /* 0.258570894 */, 19 }, - /* 7066 */ { MAD_F(0x04234e67) /* 0.258619694 */, 19 }, - /* 7067 */ { MAD_F(0x04238193) /* 0.258668496 */, 19 }, - /* 7068 */ { MAD_F(0x0423b4c0) /* 0.258717300 */, 19 }, - /* 7069 */ { MAD_F(0x0423e7ee) /* 0.258766106 */, 19 }, - /* 7070 */ { MAD_F(0x04241b1c) /* 0.258814915 */, 19 }, - /* 7071 */ { MAD_F(0x04244e4a) /* 0.258863726 */, 19 }, - - /* 7072 */ { MAD_F(0x04248179) /* 0.258912540 */, 19 }, - /* 7073 */ { MAD_F(0x0424b4a9) /* 0.258961356 */, 19 }, - /* 7074 */ { MAD_F(0x0424e7da) /* 0.259010174 */, 19 }, - /* 7075 */ { MAD_F(0x04251b0b) /* 0.259058994 */, 19 }, - /* 7076 */ { MAD_F(0x04254e3d) /* 0.259107817 */, 19 }, - /* 7077 */ { MAD_F(0x0425816f) /* 0.259156642 */, 19 }, - /* 7078 */ { MAD_F(0x0425b4a2) /* 0.259205469 */, 19 }, - /* 7079 */ { MAD_F(0x0425e7d6) /* 0.259254298 */, 19 }, - /* 7080 */ { MAD_F(0x04261b0a) /* 0.259303130 */, 19 }, - /* 7081 */ { MAD_F(0x04264e3f) /* 0.259351964 */, 19 }, - /* 7082 */ { MAD_F(0x04268174) /* 0.259400801 */, 19 }, - /* 7083 */ { MAD_F(0x0426b4aa) /* 0.259449639 */, 19 }, - /* 7084 */ { MAD_F(0x0426e7e1) /* 0.259498480 */, 19 }, - /* 7085 */ { MAD_F(0x04271b18) /* 0.259547324 */, 19 }, - /* 7086 */ { MAD_F(0x04274e50) /* 0.259596169 */, 19 }, - /* 7087 */ { MAD_F(0x04278188) /* 0.259645017 */, 19 }, - - /* 7088 */ { MAD_F(0x0427b4c2) /* 0.259693868 */, 19 }, - /* 7089 */ { MAD_F(0x0427e7fb) /* 0.259742720 */, 19 }, - /* 7090 */ { MAD_F(0x04281b36) /* 0.259791575 */, 19 }, - /* 7091 */ { MAD_F(0x04284e71) /* 0.259840432 */, 19 }, - /* 7092 */ { MAD_F(0x042881ac) /* 0.259889291 */, 19 }, - /* 7093 */ { MAD_F(0x0428b4e8) /* 0.259938153 */, 19 }, - /* 7094 */ { MAD_F(0x0428e825) /* 0.259987017 */, 19 }, - /* 7095 */ { MAD_F(0x04291b63) /* 0.260035883 */, 19 }, - /* 7096 */ { MAD_F(0x04294ea1) /* 0.260084752 */, 19 }, - /* 7097 */ { MAD_F(0x042981df) /* 0.260133623 */, 19 }, - /* 7098 */ { MAD_F(0x0429b51f) /* 0.260182496 */, 19 }, - /* 7099 */ { MAD_F(0x0429e85f) /* 0.260231372 */, 19 }, - /* 7100 */ { MAD_F(0x042a1b9f) /* 0.260280249 */, 19 }, - /* 7101 */ { MAD_F(0x042a4ee0) /* 0.260329129 */, 19 }, - /* 7102 */ { MAD_F(0x042a8222) /* 0.260378012 */, 19 }, - /* 7103 */ { MAD_F(0x042ab564) /* 0.260426896 */, 19 }, - - /* 7104 */ { MAD_F(0x042ae8a7) /* 0.260475783 */, 19 }, - /* 7105 */ { MAD_F(0x042b1beb) /* 0.260524673 */, 19 }, - /* 7106 */ { MAD_F(0x042b4f2f) /* 0.260573564 */, 19 }, - /* 7107 */ { MAD_F(0x042b8274) /* 0.260622458 */, 19 }, - /* 7108 */ { MAD_F(0x042bb5ba) /* 0.260671354 */, 19 }, - /* 7109 */ { MAD_F(0x042be900) /* 0.260720252 */, 19 }, - /* 7110 */ { MAD_F(0x042c1c46) /* 0.260769153 */, 19 }, - /* 7111 */ { MAD_F(0x042c4f8e) /* 0.260818056 */, 19 }, - /* 7112 */ { MAD_F(0x042c82d6) /* 0.260866961 */, 19 }, - /* 7113 */ { MAD_F(0x042cb61e) /* 0.260915869 */, 19 }, - /* 7114 */ { MAD_F(0x042ce967) /* 0.260964779 */, 19 }, - /* 7115 */ { MAD_F(0x042d1cb1) /* 0.261013691 */, 19 }, - /* 7116 */ { MAD_F(0x042d4ffb) /* 0.261062606 */, 19 }, - /* 7117 */ { MAD_F(0x042d8346) /* 0.261111522 */, 19 }, - /* 7118 */ { MAD_F(0x042db692) /* 0.261160441 */, 19 }, - /* 7119 */ { MAD_F(0x042de9de) /* 0.261209363 */, 19 }, - - /* 7120 */ { MAD_F(0x042e1d2b) /* 0.261258286 */, 19 }, - /* 7121 */ { MAD_F(0x042e5078) /* 0.261307212 */, 19 }, - /* 7122 */ { MAD_F(0x042e83c6) /* 0.261356140 */, 19 }, - /* 7123 */ { MAD_F(0x042eb715) /* 0.261405071 */, 19 }, - /* 7124 */ { MAD_F(0x042eea64) /* 0.261454004 */, 19 }, - /* 7125 */ { MAD_F(0x042f1db4) /* 0.261502939 */, 19 }, - /* 7126 */ { MAD_F(0x042f5105) /* 0.261551876 */, 19 }, - /* 7127 */ { MAD_F(0x042f8456) /* 0.261600816 */, 19 }, - /* 7128 */ { MAD_F(0x042fb7a8) /* 0.261649758 */, 19 }, - /* 7129 */ { MAD_F(0x042feafa) /* 0.261698702 */, 19 }, - /* 7130 */ { MAD_F(0x04301e4d) /* 0.261747649 */, 19 }, - /* 7131 */ { MAD_F(0x043051a1) /* 0.261796597 */, 19 }, - /* 7132 */ { MAD_F(0x043084f5) /* 0.261845548 */, 19 }, - /* 7133 */ { MAD_F(0x0430b84a) /* 0.261894502 */, 19 }, - /* 7134 */ { MAD_F(0x0430eb9f) /* 0.261943458 */, 19 }, - /* 7135 */ { MAD_F(0x04311ef5) /* 0.261992416 */, 19 }, - - /* 7136 */ { MAD_F(0x0431524c) /* 0.262041376 */, 19 }, - /* 7137 */ { MAD_F(0x043185a3) /* 0.262090338 */, 19 }, - /* 7138 */ { MAD_F(0x0431b8fb) /* 0.262139303 */, 19 }, - /* 7139 */ { MAD_F(0x0431ec54) /* 0.262188270 */, 19 }, - /* 7140 */ { MAD_F(0x04321fad) /* 0.262237240 */, 19 }, - /* 7141 */ { MAD_F(0x04325306) /* 0.262286211 */, 19 }, - /* 7142 */ { MAD_F(0x04328661) /* 0.262335185 */, 19 }, - /* 7143 */ { MAD_F(0x0432b9bc) /* 0.262384162 */, 19 }, - /* 7144 */ { MAD_F(0x0432ed17) /* 0.262433140 */, 19 }, - /* 7145 */ { MAD_F(0x04332074) /* 0.262482121 */, 19 }, - /* 7146 */ { MAD_F(0x043353d0) /* 0.262531104 */, 19 }, - /* 7147 */ { MAD_F(0x0433872e) /* 0.262580089 */, 19 }, - /* 7148 */ { MAD_F(0x0433ba8c) /* 0.262629077 */, 19 }, - /* 7149 */ { MAD_F(0x0433edea) /* 0.262678067 */, 19 }, - /* 7150 */ { MAD_F(0x0434214a) /* 0.262727059 */, 19 }, - /* 7151 */ { MAD_F(0x043454aa) /* 0.262776054 */, 19 }, - - /* 7152 */ { MAD_F(0x0434880a) /* 0.262825051 */, 19 }, - /* 7153 */ { MAD_F(0x0434bb6b) /* 0.262874050 */, 19 }, - /* 7154 */ { MAD_F(0x0434eecd) /* 0.262923051 */, 19 }, - /* 7155 */ { MAD_F(0x0435222f) /* 0.262972055 */, 19 }, - /* 7156 */ { MAD_F(0x04355592) /* 0.263021061 */, 19 }, - /* 7157 */ { MAD_F(0x043588f6) /* 0.263070069 */, 19 }, - /* 7158 */ { MAD_F(0x0435bc5a) /* 0.263119079 */, 19 }, - /* 7159 */ { MAD_F(0x0435efbf) /* 0.263168092 */, 19 }, - /* 7160 */ { MAD_F(0x04362324) /* 0.263217107 */, 19 }, - /* 7161 */ { MAD_F(0x0436568a) /* 0.263266125 */, 19 }, - /* 7162 */ { MAD_F(0x043689f1) /* 0.263315144 */, 19 }, - /* 7163 */ { MAD_F(0x0436bd58) /* 0.263364166 */, 19 }, - /* 7164 */ { MAD_F(0x0436f0c0) /* 0.263413191 */, 19 }, - /* 7165 */ { MAD_F(0x04372428) /* 0.263462217 */, 19 }, - /* 7166 */ { MAD_F(0x04375791) /* 0.263511246 */, 19 }, - /* 7167 */ { MAD_F(0x04378afb) /* 0.263560277 */, 19 }, - - /* 7168 */ { MAD_F(0x0437be65) /* 0.263609310 */, 19 }, - /* 7169 */ { MAD_F(0x0437f1d0) /* 0.263658346 */, 19 }, - /* 7170 */ { MAD_F(0x0438253c) /* 0.263707384 */, 19 }, - /* 7171 */ { MAD_F(0x043858a8) /* 0.263756424 */, 19 }, - /* 7172 */ { MAD_F(0x04388c14) /* 0.263805466 */, 19 }, - /* 7173 */ { MAD_F(0x0438bf82) /* 0.263854511 */, 19 }, - /* 7174 */ { MAD_F(0x0438f2f0) /* 0.263903558 */, 19 }, - /* 7175 */ { MAD_F(0x0439265e) /* 0.263952607 */, 19 }, - /* 7176 */ { MAD_F(0x043959cd) /* 0.264001659 */, 19 }, - /* 7177 */ { MAD_F(0x04398d3d) /* 0.264050713 */, 19 }, - /* 7178 */ { MAD_F(0x0439c0ae) /* 0.264099769 */, 19 }, - /* 7179 */ { MAD_F(0x0439f41f) /* 0.264148827 */, 19 }, - /* 7180 */ { MAD_F(0x043a2790) /* 0.264197888 */, 19 }, - /* 7181 */ { MAD_F(0x043a5b02) /* 0.264246951 */, 19 }, - /* 7182 */ { MAD_F(0x043a8e75) /* 0.264296016 */, 19 }, - /* 7183 */ { MAD_F(0x043ac1e9) /* 0.264345084 */, 19 }, - - /* 7184 */ { MAD_F(0x043af55d) /* 0.264394153 */, 19 }, - /* 7185 */ { MAD_F(0x043b28d2) /* 0.264443225 */, 19 }, - /* 7186 */ { MAD_F(0x043b5c47) /* 0.264492300 */, 19 }, - /* 7187 */ { MAD_F(0x043b8fbd) /* 0.264541376 */, 19 }, - /* 7188 */ { MAD_F(0x043bc333) /* 0.264590455 */, 19 }, - /* 7189 */ { MAD_F(0x043bf6aa) /* 0.264639536 */, 19 }, - /* 7190 */ { MAD_F(0x043c2a22) /* 0.264688620 */, 19 }, - /* 7191 */ { MAD_F(0x043c5d9a) /* 0.264737706 */, 19 }, - /* 7192 */ { MAD_F(0x043c9113) /* 0.264786794 */, 19 }, - /* 7193 */ { MAD_F(0x043cc48d) /* 0.264835884 */, 19 }, - /* 7194 */ { MAD_F(0x043cf807) /* 0.264884976 */, 19 }, - /* 7195 */ { MAD_F(0x043d2b82) /* 0.264934071 */, 19 }, - /* 7196 */ { MAD_F(0x043d5efd) /* 0.264983168 */, 19 }, - /* 7197 */ { MAD_F(0x043d9279) /* 0.265032268 */, 19 }, - /* 7198 */ { MAD_F(0x043dc5f6) /* 0.265081369 */, 19 }, - /* 7199 */ { MAD_F(0x043df973) /* 0.265130473 */, 19 }, - - /* 7200 */ { MAD_F(0x043e2cf1) /* 0.265179580 */, 19 }, - /* 7201 */ { MAD_F(0x043e6070) /* 0.265228688 */, 19 }, - /* 7202 */ { MAD_F(0x043e93ef) /* 0.265277799 */, 19 }, - /* 7203 */ { MAD_F(0x043ec76e) /* 0.265326912 */, 19 }, - /* 7204 */ { MAD_F(0x043efaef) /* 0.265376027 */, 19 }, - /* 7205 */ { MAD_F(0x043f2e6f) /* 0.265425145 */, 19 }, - /* 7206 */ { MAD_F(0x043f61f1) /* 0.265474264 */, 19 }, - /* 7207 */ { MAD_F(0x043f9573) /* 0.265523387 */, 19 }, - /* 7208 */ { MAD_F(0x043fc8f6) /* 0.265572511 */, 19 }, - /* 7209 */ { MAD_F(0x043ffc79) /* 0.265621638 */, 19 }, - /* 7210 */ { MAD_F(0x04402ffd) /* 0.265670766 */, 19 }, - /* 7211 */ { MAD_F(0x04406382) /* 0.265719898 */, 19 }, - /* 7212 */ { MAD_F(0x04409707) /* 0.265769031 */, 19 }, - /* 7213 */ { MAD_F(0x0440ca8d) /* 0.265818167 */, 19 }, - /* 7214 */ { MAD_F(0x0440fe13) /* 0.265867305 */, 19 }, - /* 7215 */ { MAD_F(0x0441319a) /* 0.265916445 */, 19 }, - - /* 7216 */ { MAD_F(0x04416522) /* 0.265965588 */, 19 }, - /* 7217 */ { MAD_F(0x044198aa) /* 0.266014732 */, 19 }, - /* 7218 */ { MAD_F(0x0441cc33) /* 0.266063880 */, 19 }, - /* 7219 */ { MAD_F(0x0441ffbc) /* 0.266113029 */, 19 }, - /* 7220 */ { MAD_F(0x04423346) /* 0.266162181 */, 19 }, - /* 7221 */ { MAD_F(0x044266d1) /* 0.266211334 */, 19 }, - /* 7222 */ { MAD_F(0x04429a5c) /* 0.266260491 */, 19 }, - /* 7223 */ { MAD_F(0x0442cde8) /* 0.266309649 */, 19 }, - /* 7224 */ { MAD_F(0x04430174) /* 0.266358810 */, 19 }, - /* 7225 */ { MAD_F(0x04433501) /* 0.266407973 */, 19 }, - /* 7226 */ { MAD_F(0x0443688f) /* 0.266457138 */, 19 }, - /* 7227 */ { MAD_F(0x04439c1d) /* 0.266506305 */, 19 }, - /* 7228 */ { MAD_F(0x0443cfac) /* 0.266555475 */, 19 }, - /* 7229 */ { MAD_F(0x0444033c) /* 0.266604647 */, 19 }, - /* 7230 */ { MAD_F(0x044436cc) /* 0.266653822 */, 19 }, - /* 7231 */ { MAD_F(0x04446a5d) /* 0.266702998 */, 19 }, - - /* 7232 */ { MAD_F(0x04449dee) /* 0.266752177 */, 19 }, - /* 7233 */ { MAD_F(0x0444d180) /* 0.266801358 */, 19 }, - /* 7234 */ { MAD_F(0x04450513) /* 0.266850541 */, 19 }, - /* 7235 */ { MAD_F(0x044538a6) /* 0.266899727 */, 19 }, - /* 7236 */ { MAD_F(0x04456c39) /* 0.266948915 */, 19 }, - /* 7237 */ { MAD_F(0x04459fce) /* 0.266998105 */, 19 }, - /* 7238 */ { MAD_F(0x0445d363) /* 0.267047298 */, 19 }, - /* 7239 */ { MAD_F(0x044606f8) /* 0.267096492 */, 19 }, - /* 7240 */ { MAD_F(0x04463a8f) /* 0.267145689 */, 19 }, - /* 7241 */ { MAD_F(0x04466e25) /* 0.267194888 */, 19 }, - /* 7242 */ { MAD_F(0x0446a1bd) /* 0.267244090 */, 19 }, - /* 7243 */ { MAD_F(0x0446d555) /* 0.267293294 */, 19 }, - /* 7244 */ { MAD_F(0x044708ee) /* 0.267342500 */, 19 }, - /* 7245 */ { MAD_F(0x04473c87) /* 0.267391708 */, 19 }, - /* 7246 */ { MAD_F(0x04477021) /* 0.267440919 */, 19 }, - /* 7247 */ { MAD_F(0x0447a3bb) /* 0.267490131 */, 19 }, - - /* 7248 */ { MAD_F(0x0447d756) /* 0.267539347 */, 19 }, - /* 7249 */ { MAD_F(0x04480af2) /* 0.267588564 */, 19 }, - /* 7250 */ { MAD_F(0x04483e8e) /* 0.267637783 */, 19 }, - /* 7251 */ { MAD_F(0x0448722b) /* 0.267687005 */, 19 }, - /* 7252 */ { MAD_F(0x0448a5c9) /* 0.267736229 */, 19 }, - /* 7253 */ { MAD_F(0x0448d967) /* 0.267785456 */, 19 }, - /* 7254 */ { MAD_F(0x04490d05) /* 0.267834685 */, 19 }, - /* 7255 */ { MAD_F(0x044940a5) /* 0.267883915 */, 19 }, - /* 7256 */ { MAD_F(0x04497445) /* 0.267933149 */, 19 }, - /* 7257 */ { MAD_F(0x0449a7e5) /* 0.267982384 */, 19 }, - /* 7258 */ { MAD_F(0x0449db86) /* 0.268031622 */, 19 }, - /* 7259 */ { MAD_F(0x044a0f28) /* 0.268080862 */, 19 }, - /* 7260 */ { MAD_F(0x044a42ca) /* 0.268130104 */, 19 }, - /* 7261 */ { MAD_F(0x044a766d) /* 0.268179349 */, 19 }, - /* 7262 */ { MAD_F(0x044aaa11) /* 0.268228595 */, 19 }, - /* 7263 */ { MAD_F(0x044addb5) /* 0.268277844 */, 19 }, - - /* 7264 */ { MAD_F(0x044b115a) /* 0.268327096 */, 19 }, - /* 7265 */ { MAD_F(0x044b44ff) /* 0.268376349 */, 19 }, - /* 7266 */ { MAD_F(0x044b78a5) /* 0.268425605 */, 19 }, - /* 7267 */ { MAD_F(0x044bac4c) /* 0.268474863 */, 19 }, - /* 7268 */ { MAD_F(0x044bdff3) /* 0.268524123 */, 19 }, - /* 7269 */ { MAD_F(0x044c139b) /* 0.268573386 */, 19 }, - /* 7270 */ { MAD_F(0x044c4743) /* 0.268622651 */, 19 }, - /* 7271 */ { MAD_F(0x044c7aec) /* 0.268671918 */, 19 }, - /* 7272 */ { MAD_F(0x044cae96) /* 0.268721187 */, 19 }, - /* 7273 */ { MAD_F(0x044ce240) /* 0.268770459 */, 19 }, - /* 7274 */ { MAD_F(0x044d15eb) /* 0.268819733 */, 19 }, - /* 7275 */ { MAD_F(0x044d4997) /* 0.268869009 */, 19 }, - /* 7276 */ { MAD_F(0x044d7d43) /* 0.268918287 */, 19 }, - /* 7277 */ { MAD_F(0x044db0ef) /* 0.268967568 */, 19 }, - /* 7278 */ { MAD_F(0x044de49d) /* 0.269016851 */, 19 }, - /* 7279 */ { MAD_F(0x044e184b) /* 0.269066136 */, 19 }, - - /* 7280 */ { MAD_F(0x044e4bf9) /* 0.269115423 */, 19 }, - /* 7281 */ { MAD_F(0x044e7fa8) /* 0.269164713 */, 19 }, - /* 7282 */ { MAD_F(0x044eb358) /* 0.269214005 */, 19 }, - /* 7283 */ { MAD_F(0x044ee708) /* 0.269263299 */, 19 }, - /* 7284 */ { MAD_F(0x044f1ab9) /* 0.269312595 */, 19 }, - /* 7285 */ { MAD_F(0x044f4e6b) /* 0.269361894 */, 19 }, - /* 7286 */ { MAD_F(0x044f821d) /* 0.269411195 */, 19 }, - /* 7287 */ { MAD_F(0x044fb5cf) /* 0.269460498 */, 19 }, - /* 7288 */ { MAD_F(0x044fe983) /* 0.269509804 */, 19 }, - /* 7289 */ { MAD_F(0x04501d37) /* 0.269559111 */, 19 }, - /* 7290 */ { MAD_F(0x045050eb) /* 0.269608421 */, 19 }, - /* 7291 */ { MAD_F(0x045084a0) /* 0.269657734 */, 19 }, - /* 7292 */ { MAD_F(0x0450b856) /* 0.269707048 */, 19 }, - /* 7293 */ { MAD_F(0x0450ec0d) /* 0.269756365 */, 19 }, - /* 7294 */ { MAD_F(0x04511fc4) /* 0.269805684 */, 19 }, - /* 7295 */ { MAD_F(0x0451537b) /* 0.269855005 */, 19 }, - - /* 7296 */ { MAD_F(0x04518733) /* 0.269904329 */, 19 }, - /* 7297 */ { MAD_F(0x0451baec) /* 0.269953654 */, 19 }, - /* 7298 */ { MAD_F(0x0451eea5) /* 0.270002982 */, 19 }, - /* 7299 */ { MAD_F(0x0452225f) /* 0.270052313 */, 19 }, - /* 7300 */ { MAD_F(0x0452561a) /* 0.270101645 */, 19 }, - /* 7301 */ { MAD_F(0x045289d5) /* 0.270150980 */, 19 }, - /* 7302 */ { MAD_F(0x0452bd91) /* 0.270200317 */, 19 }, - /* 7303 */ { MAD_F(0x0452f14d) /* 0.270249656 */, 19 }, - /* 7304 */ { MAD_F(0x0453250a) /* 0.270298998 */, 19 }, - /* 7305 */ { MAD_F(0x045358c8) /* 0.270348341 */, 19 }, - /* 7306 */ { MAD_F(0x04538c86) /* 0.270397687 */, 19 }, - /* 7307 */ { MAD_F(0x0453c045) /* 0.270447036 */, 19 }, - /* 7308 */ { MAD_F(0x0453f405) /* 0.270496386 */, 19 }, - /* 7309 */ { MAD_F(0x045427c5) /* 0.270545739 */, 19 }, - /* 7310 */ { MAD_F(0x04545b85) /* 0.270595094 */, 19 }, - /* 7311 */ { MAD_F(0x04548f46) /* 0.270644451 */, 19 }, - - /* 7312 */ { MAD_F(0x0454c308) /* 0.270693811 */, 19 }, - /* 7313 */ { MAD_F(0x0454f6cb) /* 0.270743173 */, 19 }, - /* 7314 */ { MAD_F(0x04552a8e) /* 0.270792537 */, 19 }, - /* 7315 */ { MAD_F(0x04555e51) /* 0.270841903 */, 19 }, - /* 7316 */ { MAD_F(0x04559216) /* 0.270891271 */, 19 }, - /* 7317 */ { MAD_F(0x0455c5db) /* 0.270940642 */, 19 }, - /* 7318 */ { MAD_F(0x0455f9a0) /* 0.270990015 */, 19 }, - /* 7319 */ { MAD_F(0x04562d66) /* 0.271039390 */, 19 }, - /* 7320 */ { MAD_F(0x0456612d) /* 0.271088768 */, 19 }, - /* 7321 */ { MAD_F(0x045694f4) /* 0.271138148 */, 19 }, - /* 7322 */ { MAD_F(0x0456c8bc) /* 0.271187530 */, 19 }, - /* 7323 */ { MAD_F(0x0456fc84) /* 0.271236914 */, 19 }, - /* 7324 */ { MAD_F(0x0457304e) /* 0.271286301 */, 19 }, - /* 7325 */ { MAD_F(0x04576417) /* 0.271335689 */, 19 }, - /* 7326 */ { MAD_F(0x045797e2) /* 0.271385080 */, 19 }, - /* 7327 */ { MAD_F(0x0457cbac) /* 0.271434474 */, 19 }, - - /* 7328 */ { MAD_F(0x0457ff78) /* 0.271483869 */, 19 }, - /* 7329 */ { MAD_F(0x04583344) /* 0.271533267 */, 19 }, - /* 7330 */ { MAD_F(0x04586711) /* 0.271582667 */, 19 }, - /* 7331 */ { MAD_F(0x04589ade) /* 0.271632069 */, 19 }, - /* 7332 */ { MAD_F(0x0458ceac) /* 0.271681474 */, 19 }, - /* 7333 */ { MAD_F(0x0459027b) /* 0.271730880 */, 19 }, - /* 7334 */ { MAD_F(0x0459364a) /* 0.271780289 */, 19 }, - /* 7335 */ { MAD_F(0x04596a19) /* 0.271829701 */, 19 }, - /* 7336 */ { MAD_F(0x04599dea) /* 0.271879114 */, 19 }, - /* 7337 */ { MAD_F(0x0459d1bb) /* 0.271928530 */, 19 }, - /* 7338 */ { MAD_F(0x045a058c) /* 0.271977948 */, 19 }, - /* 7339 */ { MAD_F(0x045a395e) /* 0.272027368 */, 19 }, - /* 7340 */ { MAD_F(0x045a6d31) /* 0.272076790 */, 19 }, - /* 7341 */ { MAD_F(0x045aa104) /* 0.272126215 */, 19 }, - /* 7342 */ { MAD_F(0x045ad4d8) /* 0.272175642 */, 19 }, - /* 7343 */ { MAD_F(0x045b08ad) /* 0.272225071 */, 19 }, - - /* 7344 */ { MAD_F(0x045b3c82) /* 0.272274503 */, 19 }, - /* 7345 */ { MAD_F(0x045b7058) /* 0.272323936 */, 19 }, - /* 7346 */ { MAD_F(0x045ba42e) /* 0.272373372 */, 19 }, - /* 7347 */ { MAD_F(0x045bd805) /* 0.272422810 */, 19 }, - /* 7348 */ { MAD_F(0x045c0bdd) /* 0.272472251 */, 19 }, - /* 7349 */ { MAD_F(0x045c3fb5) /* 0.272521693 */, 19 }, - /* 7350 */ { MAD_F(0x045c738e) /* 0.272571138 */, 19 }, - /* 7351 */ { MAD_F(0x045ca767) /* 0.272620585 */, 19 }, - /* 7352 */ { MAD_F(0x045cdb41) /* 0.272670035 */, 19 }, - /* 7353 */ { MAD_F(0x045d0f1b) /* 0.272719486 */, 19 }, - /* 7354 */ { MAD_F(0x045d42f7) /* 0.272768940 */, 19 }, - /* 7355 */ { MAD_F(0x045d76d2) /* 0.272818396 */, 19 }, - /* 7356 */ { MAD_F(0x045daaaf) /* 0.272867855 */, 19 }, - /* 7357 */ { MAD_F(0x045dde8c) /* 0.272917315 */, 19 }, - /* 7358 */ { MAD_F(0x045e1269) /* 0.272966778 */, 19 }, - /* 7359 */ { MAD_F(0x045e4647) /* 0.273016243 */, 19 }, - - /* 7360 */ { MAD_F(0x045e7a26) /* 0.273065710 */, 19 }, - /* 7361 */ { MAD_F(0x045eae06) /* 0.273115180 */, 19 }, - /* 7362 */ { MAD_F(0x045ee1e6) /* 0.273164652 */, 19 }, - /* 7363 */ { MAD_F(0x045f15c6) /* 0.273214126 */, 19 }, - /* 7364 */ { MAD_F(0x045f49a7) /* 0.273263602 */, 19 }, - /* 7365 */ { MAD_F(0x045f7d89) /* 0.273313081 */, 19 }, - /* 7366 */ { MAD_F(0x045fb16c) /* 0.273362561 */, 19 }, - /* 7367 */ { MAD_F(0x045fe54f) /* 0.273412044 */, 19 }, - /* 7368 */ { MAD_F(0x04601932) /* 0.273461530 */, 19 }, - /* 7369 */ { MAD_F(0x04604d16) /* 0.273511017 */, 19 }, - /* 7370 */ { MAD_F(0x046080fb) /* 0.273560507 */, 19 }, - /* 7371 */ { MAD_F(0x0460b4e1) /* 0.273609999 */, 19 }, - /* 7372 */ { MAD_F(0x0460e8c7) /* 0.273659493 */, 19 }, - /* 7373 */ { MAD_F(0x04611cad) /* 0.273708989 */, 19 }, - /* 7374 */ { MAD_F(0x04615094) /* 0.273758488 */, 19 }, - /* 7375 */ { MAD_F(0x0461847c) /* 0.273807989 */, 19 }, - - /* 7376 */ { MAD_F(0x0461b864) /* 0.273857492 */, 19 }, - /* 7377 */ { MAD_F(0x0461ec4d) /* 0.273906997 */, 19 }, - /* 7378 */ { MAD_F(0x04622037) /* 0.273956505 */, 19 }, - /* 7379 */ { MAD_F(0x04625421) /* 0.274006015 */, 19 }, - /* 7380 */ { MAD_F(0x0462880c) /* 0.274055527 */, 19 }, - /* 7381 */ { MAD_F(0x0462bbf7) /* 0.274105041 */, 19 }, - /* 7382 */ { MAD_F(0x0462efe3) /* 0.274154558 */, 19 }, - /* 7383 */ { MAD_F(0x046323d0) /* 0.274204076 */, 19 }, - /* 7384 */ { MAD_F(0x046357bd) /* 0.274253597 */, 19 }, - /* 7385 */ { MAD_F(0x04638bab) /* 0.274303121 */, 19 }, - /* 7386 */ { MAD_F(0x0463bf99) /* 0.274352646 */, 19 }, - /* 7387 */ { MAD_F(0x0463f388) /* 0.274402174 */, 19 }, - /* 7388 */ { MAD_F(0x04642778) /* 0.274451704 */, 19 }, - /* 7389 */ { MAD_F(0x04645b68) /* 0.274501236 */, 19 }, - /* 7390 */ { MAD_F(0x04648f59) /* 0.274550771 */, 19 }, - /* 7391 */ { MAD_F(0x0464c34a) /* 0.274600307 */, 19 }, - - /* 7392 */ { MAD_F(0x0464f73c) /* 0.274649846 */, 19 }, - /* 7393 */ { MAD_F(0x04652b2f) /* 0.274699387 */, 19 }, - /* 7394 */ { MAD_F(0x04655f22) /* 0.274748931 */, 19 }, - /* 7395 */ { MAD_F(0x04659316) /* 0.274798476 */, 19 }, - /* 7396 */ { MAD_F(0x0465c70a) /* 0.274848024 */, 19 }, - /* 7397 */ { MAD_F(0x0465faff) /* 0.274897574 */, 19 }, - /* 7398 */ { MAD_F(0x04662ef5) /* 0.274947126 */, 19 }, - /* 7399 */ { MAD_F(0x046662eb) /* 0.274996681 */, 19 }, - /* 7400 */ { MAD_F(0x046696e2) /* 0.275046238 */, 19 }, - /* 7401 */ { MAD_F(0x0466cad9) /* 0.275095797 */, 19 }, - /* 7402 */ { MAD_F(0x0466fed1) /* 0.275145358 */, 19 }, - /* 7403 */ { MAD_F(0x046732ca) /* 0.275194921 */, 19 }, - /* 7404 */ { MAD_F(0x046766c3) /* 0.275244487 */, 19 }, - /* 7405 */ { MAD_F(0x04679abd) /* 0.275294055 */, 19 }, - /* 7406 */ { MAD_F(0x0467ceb7) /* 0.275343625 */, 19 }, - /* 7407 */ { MAD_F(0x046802b2) /* 0.275393198 */, 19 }, - - /* 7408 */ { MAD_F(0x046836ae) /* 0.275442772 */, 19 }, - /* 7409 */ { MAD_F(0x04686aaa) /* 0.275492349 */, 19 }, - /* 7410 */ { MAD_F(0x04689ea7) /* 0.275541928 */, 19 }, - /* 7411 */ { MAD_F(0x0468d2a4) /* 0.275591509 */, 19 }, - /* 7412 */ { MAD_F(0x046906a2) /* 0.275641093 */, 19 }, - /* 7413 */ { MAD_F(0x04693aa1) /* 0.275690679 */, 19 }, - /* 7414 */ { MAD_F(0x04696ea0) /* 0.275740267 */, 19 }, - /* 7415 */ { MAD_F(0x0469a2a0) /* 0.275789857 */, 19 }, - /* 7416 */ { MAD_F(0x0469d6a0) /* 0.275839449 */, 19 }, - /* 7417 */ { MAD_F(0x046a0aa1) /* 0.275889044 */, 19 }, - /* 7418 */ { MAD_F(0x046a3ea3) /* 0.275938641 */, 19 }, - /* 7419 */ { MAD_F(0x046a72a5) /* 0.275988240 */, 19 }, - /* 7420 */ { MAD_F(0x046aa6a8) /* 0.276037842 */, 19 }, - /* 7421 */ { MAD_F(0x046adaab) /* 0.276087445 */, 19 }, - /* 7422 */ { MAD_F(0x046b0eaf) /* 0.276137051 */, 19 }, - /* 7423 */ { MAD_F(0x046b42b3) /* 0.276186659 */, 19 }, - - /* 7424 */ { MAD_F(0x046b76b9) /* 0.276236269 */, 19 }, - /* 7425 */ { MAD_F(0x046baabe) /* 0.276285882 */, 19 }, - /* 7426 */ { MAD_F(0x046bdec5) /* 0.276335497 */, 19 }, - /* 7427 */ { MAD_F(0x046c12cc) /* 0.276385113 */, 19 }, - /* 7428 */ { MAD_F(0x046c46d3) /* 0.276434733 */, 19 }, - /* 7429 */ { MAD_F(0x046c7adb) /* 0.276484354 */, 19 }, - /* 7430 */ { MAD_F(0x046caee4) /* 0.276533978 */, 19 }, - /* 7431 */ { MAD_F(0x046ce2ee) /* 0.276583604 */, 19 }, - /* 7432 */ { MAD_F(0x046d16f7) /* 0.276633232 */, 19 }, - /* 7433 */ { MAD_F(0x046d4b02) /* 0.276682862 */, 19 }, - /* 7434 */ { MAD_F(0x046d7f0d) /* 0.276732495 */, 19 }, - /* 7435 */ { MAD_F(0x046db319) /* 0.276782129 */, 19 }, - /* 7436 */ { MAD_F(0x046de725) /* 0.276831766 */, 19 }, - /* 7437 */ { MAD_F(0x046e1b32) /* 0.276881406 */, 19 }, - /* 7438 */ { MAD_F(0x046e4f40) /* 0.276931047 */, 19 }, - /* 7439 */ { MAD_F(0x046e834e) /* 0.276980691 */, 19 }, - - /* 7440 */ { MAD_F(0x046eb75c) /* 0.277030337 */, 19 }, - /* 7441 */ { MAD_F(0x046eeb6c) /* 0.277079985 */, 19 }, - /* 7442 */ { MAD_F(0x046f1f7c) /* 0.277129635 */, 19 }, - /* 7443 */ { MAD_F(0x046f538c) /* 0.277179288 */, 19 }, - /* 7444 */ { MAD_F(0x046f879d) /* 0.277228942 */, 19 }, - /* 7445 */ { MAD_F(0x046fbbaf) /* 0.277278600 */, 19 }, - /* 7446 */ { MAD_F(0x046fefc1) /* 0.277328259 */, 19 }, - /* 7447 */ { MAD_F(0x047023d4) /* 0.277377920 */, 19 }, - /* 7448 */ { MAD_F(0x047057e8) /* 0.277427584 */, 19 }, - /* 7449 */ { MAD_F(0x04708bfc) /* 0.277477250 */, 19 }, - /* 7450 */ { MAD_F(0x0470c011) /* 0.277526918 */, 19 }, - /* 7451 */ { MAD_F(0x0470f426) /* 0.277576588 */, 19 }, - /* 7452 */ { MAD_F(0x0471283c) /* 0.277626261 */, 19 }, - /* 7453 */ { MAD_F(0x04715c52) /* 0.277675936 */, 19 }, - /* 7454 */ { MAD_F(0x04719069) /* 0.277725613 */, 19 }, - /* 7455 */ { MAD_F(0x0471c481) /* 0.277775292 */, 19 }, - - /* 7456 */ { MAD_F(0x0471f899) /* 0.277824973 */, 19 }, - /* 7457 */ { MAD_F(0x04722cb2) /* 0.277874657 */, 19 }, - /* 7458 */ { MAD_F(0x047260cc) /* 0.277924343 */, 19 }, - /* 7459 */ { MAD_F(0x047294e6) /* 0.277974031 */, 19 }, - /* 7460 */ { MAD_F(0x0472c900) /* 0.278023722 */, 19 }, - /* 7461 */ { MAD_F(0x0472fd1b) /* 0.278073414 */, 19 }, - /* 7462 */ { MAD_F(0x04733137) /* 0.278123109 */, 19 }, - /* 7463 */ { MAD_F(0x04736554) /* 0.278172806 */, 19 }, - /* 7464 */ { MAD_F(0x04739971) /* 0.278222505 */, 19 }, - /* 7465 */ { MAD_F(0x0473cd8e) /* 0.278272207 */, 19 }, - /* 7466 */ { MAD_F(0x047401ad) /* 0.278321910 */, 19 }, - /* 7467 */ { MAD_F(0x047435cb) /* 0.278371616 */, 19 }, - /* 7468 */ { MAD_F(0x047469eb) /* 0.278421324 */, 19 }, - /* 7469 */ { MAD_F(0x04749e0b) /* 0.278471035 */, 19 }, - /* 7470 */ { MAD_F(0x0474d22c) /* 0.278520747 */, 19 }, - /* 7471 */ { MAD_F(0x0475064d) /* 0.278570462 */, 19 }, - - /* 7472 */ { MAD_F(0x04753a6f) /* 0.278620179 */, 19 }, - /* 7473 */ { MAD_F(0x04756e91) /* 0.278669898 */, 19 }, - /* 7474 */ { MAD_F(0x0475a2b4) /* 0.278719619 */, 19 }, - /* 7475 */ { MAD_F(0x0475d6d7) /* 0.278769343 */, 19 }, - /* 7476 */ { MAD_F(0x04760afc) /* 0.278819069 */, 19 }, - /* 7477 */ { MAD_F(0x04763f20) /* 0.278868797 */, 19 }, - /* 7478 */ { MAD_F(0x04767346) /* 0.278918527 */, 19 }, - /* 7479 */ { MAD_F(0x0476a76c) /* 0.278968260 */, 19 }, - /* 7480 */ { MAD_F(0x0476db92) /* 0.279017995 */, 19 }, - /* 7481 */ { MAD_F(0x04770fba) /* 0.279067731 */, 19 }, - /* 7482 */ { MAD_F(0x047743e1) /* 0.279117471 */, 19 }, - /* 7483 */ { MAD_F(0x0477780a) /* 0.279167212 */, 19 }, - /* 7484 */ { MAD_F(0x0477ac33) /* 0.279216956 */, 19 }, - /* 7485 */ { MAD_F(0x0477e05c) /* 0.279266701 */, 19 }, - /* 7486 */ { MAD_F(0x04781486) /* 0.279316449 */, 19 }, - /* 7487 */ { MAD_F(0x047848b1) /* 0.279366200 */, 19 }, - - /* 7488 */ { MAD_F(0x04787cdc) /* 0.279415952 */, 19 }, - /* 7489 */ { MAD_F(0x0478b108) /* 0.279465707 */, 19 }, - /* 7490 */ { MAD_F(0x0478e535) /* 0.279515464 */, 19 }, - /* 7491 */ { MAD_F(0x04791962) /* 0.279565223 */, 19 }, - /* 7492 */ { MAD_F(0x04794d8f) /* 0.279614984 */, 19 }, - /* 7493 */ { MAD_F(0x047981be) /* 0.279664748 */, 19 }, - /* 7494 */ { MAD_F(0x0479b5ed) /* 0.279714513 */, 19 }, - /* 7495 */ { MAD_F(0x0479ea1c) /* 0.279764281 */, 19 }, - /* 7496 */ { MAD_F(0x047a1e4c) /* 0.279814051 */, 19 }, - /* 7497 */ { MAD_F(0x047a527d) /* 0.279863824 */, 19 }, - /* 7498 */ { MAD_F(0x047a86ae) /* 0.279913598 */, 19 }, - /* 7499 */ { MAD_F(0x047abae0) /* 0.279963375 */, 19 }, - /* 7500 */ { MAD_F(0x047aef12) /* 0.280013154 */, 19 }, - /* 7501 */ { MAD_F(0x047b2346) /* 0.280062935 */, 19 }, - /* 7502 */ { MAD_F(0x047b5779) /* 0.280112719 */, 19 }, - /* 7503 */ { MAD_F(0x047b8bad) /* 0.280162504 */, 19 }, - - /* 7504 */ { MAD_F(0x047bbfe2) /* 0.280212292 */, 19 }, - /* 7505 */ { MAD_F(0x047bf418) /* 0.280262082 */, 19 }, - /* 7506 */ { MAD_F(0x047c284e) /* 0.280311875 */, 19 }, - /* 7507 */ { MAD_F(0x047c5c84) /* 0.280361669 */, 19 }, - /* 7508 */ { MAD_F(0x047c90bb) /* 0.280411466 */, 19 }, - /* 7509 */ { MAD_F(0x047cc4f3) /* 0.280461265 */, 19 }, - /* 7510 */ { MAD_F(0x047cf92c) /* 0.280511066 */, 19 }, - /* 7511 */ { MAD_F(0x047d2d65) /* 0.280560869 */, 19 }, - /* 7512 */ { MAD_F(0x047d619e) /* 0.280610675 */, 19 }, - /* 7513 */ { MAD_F(0x047d95d8) /* 0.280660483 */, 19 }, - /* 7514 */ { MAD_F(0x047dca13) /* 0.280710292 */, 19 }, - /* 7515 */ { MAD_F(0x047dfe4e) /* 0.280760105 */, 19 }, - /* 7516 */ { MAD_F(0x047e328a) /* 0.280809919 */, 19 }, - /* 7517 */ { MAD_F(0x047e66c7) /* 0.280859736 */, 19 }, - /* 7518 */ { MAD_F(0x047e9b04) /* 0.280909554 */, 19 }, - /* 7519 */ { MAD_F(0x047ecf42) /* 0.280959375 */, 19 }, - - /* 7520 */ { MAD_F(0x047f0380) /* 0.281009199 */, 19 }, - /* 7521 */ { MAD_F(0x047f37bf) /* 0.281059024 */, 19 }, - /* 7522 */ { MAD_F(0x047f6bff) /* 0.281108852 */, 19 }, - /* 7523 */ { MAD_F(0x047fa03f) /* 0.281158682 */, 19 }, - /* 7524 */ { MAD_F(0x047fd47f) /* 0.281208514 */, 19 }, - /* 7525 */ { MAD_F(0x048008c1) /* 0.281258348 */, 19 }, - /* 7526 */ { MAD_F(0x04803d02) /* 0.281308184 */, 19 }, - /* 7527 */ { MAD_F(0x04807145) /* 0.281358023 */, 19 }, - /* 7528 */ { MAD_F(0x0480a588) /* 0.281407864 */, 19 }, - /* 7529 */ { MAD_F(0x0480d9cc) /* 0.281457707 */, 19 }, - /* 7530 */ { MAD_F(0x04810e10) /* 0.281507552 */, 19 }, - /* 7531 */ { MAD_F(0x04814255) /* 0.281557400 */, 19 }, - /* 7532 */ { MAD_F(0x0481769a) /* 0.281607250 */, 19 }, - /* 7533 */ { MAD_F(0x0481aae0) /* 0.281657101 */, 19 }, - /* 7534 */ { MAD_F(0x0481df27) /* 0.281706956 */, 19 }, - /* 7535 */ { MAD_F(0x0482136e) /* 0.281756812 */, 19 }, - - /* 7536 */ { MAD_F(0x048247b6) /* 0.281806670 */, 19 }, - /* 7537 */ { MAD_F(0x04827bfe) /* 0.281856531 */, 19 }, - /* 7538 */ { MAD_F(0x0482b047) /* 0.281906394 */, 19 }, - /* 7539 */ { MAD_F(0x0482e491) /* 0.281956259 */, 19 }, - /* 7540 */ { MAD_F(0x048318db) /* 0.282006127 */, 19 }, - /* 7541 */ { MAD_F(0x04834d26) /* 0.282055996 */, 19 }, - /* 7542 */ { MAD_F(0x04838171) /* 0.282105868 */, 19 }, - /* 7543 */ { MAD_F(0x0483b5bd) /* 0.282155742 */, 19 }, - /* 7544 */ { MAD_F(0x0483ea0a) /* 0.282205618 */, 19 }, - /* 7545 */ { MAD_F(0x04841e57) /* 0.282255496 */, 19 }, - /* 7546 */ { MAD_F(0x048452a4) /* 0.282305377 */, 19 }, - /* 7547 */ { MAD_F(0x048486f3) /* 0.282355260 */, 19 }, - /* 7548 */ { MAD_F(0x0484bb42) /* 0.282405145 */, 19 }, - /* 7549 */ { MAD_F(0x0484ef91) /* 0.282455032 */, 19 }, - /* 7550 */ { MAD_F(0x048523e1) /* 0.282504921 */, 19 }, - /* 7551 */ { MAD_F(0x04855832) /* 0.282554813 */, 19 }, - - /* 7552 */ { MAD_F(0x04858c83) /* 0.282604707 */, 19 }, - /* 7553 */ { MAD_F(0x0485c0d5) /* 0.282654603 */, 19 }, - /* 7554 */ { MAD_F(0x0485f527) /* 0.282704501 */, 19 }, - /* 7555 */ { MAD_F(0x0486297a) /* 0.282754401 */, 19 }, - /* 7556 */ { MAD_F(0x04865dce) /* 0.282804304 */, 19 }, - /* 7557 */ { MAD_F(0x04869222) /* 0.282854209 */, 19 }, - /* 7558 */ { MAD_F(0x0486c677) /* 0.282904116 */, 19 }, - /* 7559 */ { MAD_F(0x0486facc) /* 0.282954025 */, 19 }, - /* 7560 */ { MAD_F(0x04872f22) /* 0.283003936 */, 19 }, - /* 7561 */ { MAD_F(0x04876379) /* 0.283053850 */, 19 }, - /* 7562 */ { MAD_F(0x048797d0) /* 0.283103766 */, 19 }, - /* 7563 */ { MAD_F(0x0487cc28) /* 0.283153684 */, 19 }, - /* 7564 */ { MAD_F(0x04880080) /* 0.283203604 */, 19 }, - /* 7565 */ { MAD_F(0x048834d9) /* 0.283253527 */, 19 }, - /* 7566 */ { MAD_F(0x04886933) /* 0.283303451 */, 19 }, - /* 7567 */ { MAD_F(0x04889d8d) /* 0.283353378 */, 19 }, - - /* 7568 */ { MAD_F(0x0488d1e8) /* 0.283403307 */, 19 }, - /* 7569 */ { MAD_F(0x04890643) /* 0.283453238 */, 19 }, - /* 7570 */ { MAD_F(0x04893a9f) /* 0.283503172 */, 19 }, - /* 7571 */ { MAD_F(0x04896efb) /* 0.283553107 */, 19 }, - /* 7572 */ { MAD_F(0x0489a358) /* 0.283603045 */, 19 }, - /* 7573 */ { MAD_F(0x0489d7b6) /* 0.283652985 */, 19 }, - /* 7574 */ { MAD_F(0x048a0c14) /* 0.283702927 */, 19 }, - /* 7575 */ { MAD_F(0x048a4073) /* 0.283752872 */, 19 }, - /* 7576 */ { MAD_F(0x048a74d3) /* 0.283802818 */, 19 }, - /* 7577 */ { MAD_F(0x048aa933) /* 0.283852767 */, 19 }, - /* 7578 */ { MAD_F(0x048add93) /* 0.283902718 */, 19 }, - /* 7579 */ { MAD_F(0x048b11f5) /* 0.283952671 */, 19 }, - /* 7580 */ { MAD_F(0x048b4656) /* 0.284002627 */, 19 }, - /* 7581 */ { MAD_F(0x048b7ab9) /* 0.284052584 */, 19 }, - /* 7582 */ { MAD_F(0x048baf1c) /* 0.284102544 */, 19 }, - /* 7583 */ { MAD_F(0x048be37f) /* 0.284152506 */, 19 }, - - /* 7584 */ { MAD_F(0x048c17e3) /* 0.284202470 */, 19 }, - /* 7585 */ { MAD_F(0x048c4c48) /* 0.284252436 */, 19 }, - /* 7586 */ { MAD_F(0x048c80ad) /* 0.284302405 */, 19 }, - /* 7587 */ { MAD_F(0x048cb513) /* 0.284352376 */, 19 }, - /* 7588 */ { MAD_F(0x048ce97a) /* 0.284402349 */, 19 }, - /* 7589 */ { MAD_F(0x048d1de1) /* 0.284452324 */, 19 }, - /* 7590 */ { MAD_F(0x048d5249) /* 0.284502301 */, 19 }, - /* 7591 */ { MAD_F(0x048d86b1) /* 0.284552281 */, 19 }, - /* 7592 */ { MAD_F(0x048dbb1a) /* 0.284602263 */, 19 }, - /* 7593 */ { MAD_F(0x048def83) /* 0.284652246 */, 19 }, - /* 7594 */ { MAD_F(0x048e23ed) /* 0.284702233 */, 19 }, - /* 7595 */ { MAD_F(0x048e5858) /* 0.284752221 */, 19 }, - /* 7596 */ { MAD_F(0x048e8cc3) /* 0.284802211 */, 19 }, - /* 7597 */ { MAD_F(0x048ec12f) /* 0.284852204 */, 19 }, - /* 7598 */ { MAD_F(0x048ef59b) /* 0.284902199 */, 19 }, - /* 7599 */ { MAD_F(0x048f2a08) /* 0.284952196 */, 19 }, - - /* 7600 */ { MAD_F(0x048f5e76) /* 0.285002195 */, 19 }, - /* 7601 */ { MAD_F(0x048f92e4) /* 0.285052197 */, 19 }, - /* 7602 */ { MAD_F(0x048fc753) /* 0.285102201 */, 19 }, - /* 7603 */ { MAD_F(0x048ffbc2) /* 0.285152206 */, 19 }, - /* 7604 */ { MAD_F(0x04903032) /* 0.285202214 */, 19 }, - /* 7605 */ { MAD_F(0x049064a3) /* 0.285252225 */, 19 }, - /* 7606 */ { MAD_F(0x04909914) /* 0.285302237 */, 19 }, - /* 7607 */ { MAD_F(0x0490cd86) /* 0.285352252 */, 19 }, - /* 7608 */ { MAD_F(0x049101f8) /* 0.285402269 */, 19 }, - /* 7609 */ { MAD_F(0x0491366b) /* 0.285452288 */, 19 }, - /* 7610 */ { MAD_F(0x04916ade) /* 0.285502309 */, 19 }, - /* 7611 */ { MAD_F(0x04919f52) /* 0.285552332 */, 19 }, - /* 7612 */ { MAD_F(0x0491d3c7) /* 0.285602358 */, 19 }, - /* 7613 */ { MAD_F(0x0492083c) /* 0.285652386 */, 19 }, - /* 7614 */ { MAD_F(0x04923cb2) /* 0.285702416 */, 19 }, - /* 7615 */ { MAD_F(0x04927128) /* 0.285752448 */, 19 }, - - /* 7616 */ { MAD_F(0x0492a59f) /* 0.285802482 */, 19 }, - /* 7617 */ { MAD_F(0x0492da17) /* 0.285852519 */, 19 }, - /* 7618 */ { MAD_F(0x04930e8f) /* 0.285902557 */, 19 }, - /* 7619 */ { MAD_F(0x04934308) /* 0.285952598 */, 19 }, - /* 7620 */ { MAD_F(0x04937781) /* 0.286002641 */, 19 }, - /* 7621 */ { MAD_F(0x0493abfb) /* 0.286052687 */, 19 }, - /* 7622 */ { MAD_F(0x0493e076) /* 0.286102734 */, 19 }, - /* 7623 */ { MAD_F(0x049414f1) /* 0.286152784 */, 19 }, - /* 7624 */ { MAD_F(0x0494496c) /* 0.286202836 */, 19 }, - /* 7625 */ { MAD_F(0x04947de9) /* 0.286252890 */, 19 }, - /* 7626 */ { MAD_F(0x0494b266) /* 0.286302946 */, 19 }, - /* 7627 */ { MAD_F(0x0494e6e3) /* 0.286353005 */, 19 }, - /* 7628 */ { MAD_F(0x04951b61) /* 0.286403065 */, 19 }, - /* 7629 */ { MAD_F(0x04954fe0) /* 0.286453128 */, 19 }, - /* 7630 */ { MAD_F(0x0495845f) /* 0.286503193 */, 19 }, - /* 7631 */ { MAD_F(0x0495b8df) /* 0.286553260 */, 19 }, - - /* 7632 */ { MAD_F(0x0495ed5f) /* 0.286603329 */, 19 }, - /* 7633 */ { MAD_F(0x049621e0) /* 0.286653401 */, 19 }, - /* 7634 */ { MAD_F(0x04965662) /* 0.286703475 */, 19 }, - /* 7635 */ { MAD_F(0x04968ae4) /* 0.286753551 */, 19 }, - /* 7636 */ { MAD_F(0x0496bf67) /* 0.286803629 */, 19 }, - /* 7637 */ { MAD_F(0x0496f3ea) /* 0.286853709 */, 19 }, - /* 7638 */ { MAD_F(0x0497286e) /* 0.286903792 */, 19 }, - /* 7639 */ { MAD_F(0x04975cf2) /* 0.286953876 */, 19 }, - /* 7640 */ { MAD_F(0x04979177) /* 0.287003963 */, 19 }, - /* 7641 */ { MAD_F(0x0497c5fd) /* 0.287054052 */, 19 }, - /* 7642 */ { MAD_F(0x0497fa83) /* 0.287104143 */, 19 }, - /* 7643 */ { MAD_F(0x04982f0a) /* 0.287154237 */, 19 }, - /* 7644 */ { MAD_F(0x04986392) /* 0.287204332 */, 19 }, - /* 7645 */ { MAD_F(0x0498981a) /* 0.287254430 */, 19 }, - /* 7646 */ { MAD_F(0x0498cca2) /* 0.287304530 */, 19 }, - /* 7647 */ { MAD_F(0x0499012c) /* 0.287354632 */, 19 }, - - /* 7648 */ { MAD_F(0x049935b5) /* 0.287404737 */, 19 }, - /* 7649 */ { MAD_F(0x04996a40) /* 0.287454843 */, 19 }, - /* 7650 */ { MAD_F(0x04999ecb) /* 0.287504952 */, 19 }, - /* 7651 */ { MAD_F(0x0499d356) /* 0.287555063 */, 19 }, - /* 7652 */ { MAD_F(0x049a07e2) /* 0.287605176 */, 19 }, - /* 7653 */ { MAD_F(0x049a3c6f) /* 0.287655291 */, 19 }, - /* 7654 */ { MAD_F(0x049a70fc) /* 0.287705409 */, 19 }, - /* 7655 */ { MAD_F(0x049aa58a) /* 0.287755528 */, 19 }, - /* 7656 */ { MAD_F(0x049ada19) /* 0.287805650 */, 19 }, - /* 7657 */ { MAD_F(0x049b0ea8) /* 0.287855774 */, 19 }, - /* 7658 */ { MAD_F(0x049b4337) /* 0.287905900 */, 19 }, - /* 7659 */ { MAD_F(0x049b77c8) /* 0.287956028 */, 19 }, - /* 7660 */ { MAD_F(0x049bac58) /* 0.288006159 */, 19 }, - /* 7661 */ { MAD_F(0x049be0ea) /* 0.288056292 */, 19 }, - /* 7662 */ { MAD_F(0x049c157c) /* 0.288106427 */, 19 }, - /* 7663 */ { MAD_F(0x049c4a0e) /* 0.288156564 */, 19 }, - - /* 7664 */ { MAD_F(0x049c7ea1) /* 0.288206703 */, 19 }, - /* 7665 */ { MAD_F(0x049cb335) /* 0.288256844 */, 19 }, - /* 7666 */ { MAD_F(0x049ce7ca) /* 0.288306988 */, 19 }, - /* 7667 */ { MAD_F(0x049d1c5e) /* 0.288357134 */, 19 }, - /* 7668 */ { MAD_F(0x049d50f4) /* 0.288407282 */, 19 }, - /* 7669 */ { MAD_F(0x049d858a) /* 0.288457432 */, 19 }, - /* 7670 */ { MAD_F(0x049dba21) /* 0.288507584 */, 19 }, - /* 7671 */ { MAD_F(0x049deeb8) /* 0.288557739 */, 19 }, - /* 7672 */ { MAD_F(0x049e2350) /* 0.288607895 */, 19 }, - /* 7673 */ { MAD_F(0x049e57e8) /* 0.288658054 */, 19 }, - /* 7674 */ { MAD_F(0x049e8c81) /* 0.288708215 */, 19 }, - /* 7675 */ { MAD_F(0x049ec11b) /* 0.288758379 */, 19 }, - /* 7676 */ { MAD_F(0x049ef5b5) /* 0.288808544 */, 19 }, - /* 7677 */ { MAD_F(0x049f2a50) /* 0.288858712 */, 19 }, - /* 7678 */ { MAD_F(0x049f5eeb) /* 0.288908881 */, 19 }, - /* 7679 */ { MAD_F(0x049f9387) /* 0.288959053 */, 19 }, - - /* 7680 */ { MAD_F(0x049fc824) /* 0.289009227 */, 19 }, - /* 7681 */ { MAD_F(0x049ffcc1) /* 0.289059404 */, 19 }, - /* 7682 */ { MAD_F(0x04a0315e) /* 0.289109582 */, 19 }, - /* 7683 */ { MAD_F(0x04a065fd) /* 0.289159763 */, 19 }, - /* 7684 */ { MAD_F(0x04a09a9b) /* 0.289209946 */, 19 }, - /* 7685 */ { MAD_F(0x04a0cf3b) /* 0.289260131 */, 19 }, - /* 7686 */ { MAD_F(0x04a103db) /* 0.289310318 */, 19 }, - /* 7687 */ { MAD_F(0x04a1387b) /* 0.289360507 */, 19 }, - /* 7688 */ { MAD_F(0x04a16d1d) /* 0.289410699 */, 19 }, - /* 7689 */ { MAD_F(0x04a1a1be) /* 0.289460893 */, 19 }, - /* 7690 */ { MAD_F(0x04a1d661) /* 0.289511088 */, 19 }, - /* 7691 */ { MAD_F(0x04a20b04) /* 0.289561287 */, 19 }, - /* 7692 */ { MAD_F(0x04a23fa7) /* 0.289611487 */, 19 }, - /* 7693 */ { MAD_F(0x04a2744b) /* 0.289661689 */, 19 }, - /* 7694 */ { MAD_F(0x04a2a8f0) /* 0.289711894 */, 19 }, - /* 7695 */ { MAD_F(0x04a2dd95) /* 0.289762101 */, 19 }, - - /* 7696 */ { MAD_F(0x04a3123b) /* 0.289812309 */, 19 }, - /* 7697 */ { MAD_F(0x04a346e2) /* 0.289862521 */, 19 }, - /* 7698 */ { MAD_F(0x04a37b89) /* 0.289912734 */, 19 }, - /* 7699 */ { MAD_F(0x04a3b030) /* 0.289962949 */, 19 }, - /* 7700 */ { MAD_F(0x04a3e4d8) /* 0.290013167 */, 19 }, - /* 7701 */ { MAD_F(0x04a41981) /* 0.290063387 */, 19 }, - /* 7702 */ { MAD_F(0x04a44e2b) /* 0.290113609 */, 19 }, - /* 7703 */ { MAD_F(0x04a482d5) /* 0.290163833 */, 19 }, - /* 7704 */ { MAD_F(0x04a4b77f) /* 0.290214059 */, 19 }, - /* 7705 */ { MAD_F(0x04a4ec2a) /* 0.290264288 */, 19 }, - /* 7706 */ { MAD_F(0x04a520d6) /* 0.290314519 */, 19 }, - /* 7707 */ { MAD_F(0x04a55582) /* 0.290364751 */, 19 }, - /* 7708 */ { MAD_F(0x04a58a2f) /* 0.290414986 */, 19 }, - /* 7709 */ { MAD_F(0x04a5bedd) /* 0.290465224 */, 19 }, - /* 7710 */ { MAD_F(0x04a5f38b) /* 0.290515463 */, 19 }, - /* 7711 */ { MAD_F(0x04a62839) /* 0.290565705 */, 19 }, - - /* 7712 */ { MAD_F(0x04a65ce8) /* 0.290615948 */, 19 }, - /* 7713 */ { MAD_F(0x04a69198) /* 0.290666194 */, 19 }, - /* 7714 */ { MAD_F(0x04a6c648) /* 0.290716442 */, 19 }, - /* 7715 */ { MAD_F(0x04a6faf9) /* 0.290766692 */, 19 }, - /* 7716 */ { MAD_F(0x04a72fab) /* 0.290816945 */, 19 }, - /* 7717 */ { MAD_F(0x04a7645d) /* 0.290867199 */, 19 }, - /* 7718 */ { MAD_F(0x04a79910) /* 0.290917456 */, 19 }, - /* 7719 */ { MAD_F(0x04a7cdc3) /* 0.290967715 */, 19 }, - /* 7720 */ { MAD_F(0x04a80277) /* 0.291017976 */, 19 }, - /* 7721 */ { MAD_F(0x04a8372b) /* 0.291068239 */, 19 }, - /* 7722 */ { MAD_F(0x04a86be0) /* 0.291118505 */, 19 }, - /* 7723 */ { MAD_F(0x04a8a096) /* 0.291168772 */, 19 }, - /* 7724 */ { MAD_F(0x04a8d54c) /* 0.291219042 */, 19 }, - /* 7725 */ { MAD_F(0x04a90a03) /* 0.291269314 */, 19 }, - /* 7726 */ { MAD_F(0x04a93eba) /* 0.291319588 */, 19 }, - /* 7727 */ { MAD_F(0x04a97372) /* 0.291369865 */, 19 }, - - /* 7728 */ { MAD_F(0x04a9a82b) /* 0.291420143 */, 19 }, - /* 7729 */ { MAD_F(0x04a9dce4) /* 0.291470424 */, 19 }, - /* 7730 */ { MAD_F(0x04aa119d) /* 0.291520706 */, 19 }, - /* 7731 */ { MAD_F(0x04aa4658) /* 0.291570991 */, 19 }, - /* 7732 */ { MAD_F(0x04aa7b13) /* 0.291621278 */, 19 }, - /* 7733 */ { MAD_F(0x04aaafce) /* 0.291671568 */, 19 }, - /* 7734 */ { MAD_F(0x04aae48a) /* 0.291721859 */, 19 }, - /* 7735 */ { MAD_F(0x04ab1947) /* 0.291772153 */, 19 }, - /* 7736 */ { MAD_F(0x04ab4e04) /* 0.291822449 */, 19 }, - /* 7737 */ { MAD_F(0x04ab82c2) /* 0.291872747 */, 19 }, - /* 7738 */ { MAD_F(0x04abb780) /* 0.291923047 */, 19 }, - /* 7739 */ { MAD_F(0x04abec3f) /* 0.291973349 */, 19 }, - /* 7740 */ { MAD_F(0x04ac20fe) /* 0.292023653 */, 19 }, - /* 7741 */ { MAD_F(0x04ac55be) /* 0.292073960 */, 19 }, - /* 7742 */ { MAD_F(0x04ac8a7f) /* 0.292124269 */, 19 }, - /* 7743 */ { MAD_F(0x04acbf40) /* 0.292174580 */, 19 }, - - /* 7744 */ { MAD_F(0x04acf402) /* 0.292224893 */, 19 }, - /* 7745 */ { MAD_F(0x04ad28c5) /* 0.292275208 */, 19 }, - /* 7746 */ { MAD_F(0x04ad5d88) /* 0.292325526 */, 19 }, - /* 7747 */ { MAD_F(0x04ad924b) /* 0.292375845 */, 19 }, - /* 7748 */ { MAD_F(0x04adc70f) /* 0.292426167 */, 19 }, - /* 7749 */ { MAD_F(0x04adfbd4) /* 0.292476491 */, 19 }, - /* 7750 */ { MAD_F(0x04ae3099) /* 0.292526817 */, 19 }, - /* 7751 */ { MAD_F(0x04ae655f) /* 0.292577145 */, 19 }, - /* 7752 */ { MAD_F(0x04ae9a26) /* 0.292627476 */, 19 }, - /* 7753 */ { MAD_F(0x04aeceed) /* 0.292677808 */, 19 }, - /* 7754 */ { MAD_F(0x04af03b4) /* 0.292728143 */, 19 }, - /* 7755 */ { MAD_F(0x04af387d) /* 0.292778480 */, 19 }, - /* 7756 */ { MAD_F(0x04af6d45) /* 0.292828819 */, 19 }, - /* 7757 */ { MAD_F(0x04afa20f) /* 0.292879160 */, 19 }, - /* 7758 */ { MAD_F(0x04afd6d9) /* 0.292929504 */, 19 }, - /* 7759 */ { MAD_F(0x04b00ba3) /* 0.292979849 */, 19 }, - - /* 7760 */ { MAD_F(0x04b0406e) /* 0.293030197 */, 19 }, - /* 7761 */ { MAD_F(0x04b0753a) /* 0.293080547 */, 19 }, - /* 7762 */ { MAD_F(0x04b0aa06) /* 0.293130899 */, 19 }, - /* 7763 */ { MAD_F(0x04b0ded3) /* 0.293181253 */, 19 }, - /* 7764 */ { MAD_F(0x04b113a1) /* 0.293231610 */, 19 }, - /* 7765 */ { MAD_F(0x04b1486f) /* 0.293281968 */, 19 }, - /* 7766 */ { MAD_F(0x04b17d3d) /* 0.293332329 */, 19 }, - /* 7767 */ { MAD_F(0x04b1b20c) /* 0.293382692 */, 19 }, - /* 7768 */ { MAD_F(0x04b1e6dc) /* 0.293433057 */, 19 }, - /* 7769 */ { MAD_F(0x04b21bad) /* 0.293483424 */, 19 }, - /* 7770 */ { MAD_F(0x04b2507d) /* 0.293533794 */, 19 }, - /* 7771 */ { MAD_F(0x04b2854f) /* 0.293584165 */, 19 }, - /* 7772 */ { MAD_F(0x04b2ba21) /* 0.293634539 */, 19 }, - /* 7773 */ { MAD_F(0x04b2eef4) /* 0.293684915 */, 19 }, - /* 7774 */ { MAD_F(0x04b323c7) /* 0.293735293 */, 19 }, - /* 7775 */ { MAD_F(0x04b3589b) /* 0.293785673 */, 19 }, - - /* 7776 */ { MAD_F(0x04b38d6f) /* 0.293836055 */, 19 }, - /* 7777 */ { MAD_F(0x04b3c244) /* 0.293886440 */, 19 }, - /* 7778 */ { MAD_F(0x04b3f71a) /* 0.293936826 */, 19 }, - /* 7779 */ { MAD_F(0x04b42bf0) /* 0.293987215 */, 19 }, - /* 7780 */ { MAD_F(0x04b460c7) /* 0.294037606 */, 19 }, - /* 7781 */ { MAD_F(0x04b4959e) /* 0.294087999 */, 19 }, - /* 7782 */ { MAD_F(0x04b4ca76) /* 0.294138395 */, 19 }, - /* 7783 */ { MAD_F(0x04b4ff4e) /* 0.294188792 */, 19 }, - /* 7784 */ { MAD_F(0x04b53427) /* 0.294239192 */, 19 }, - /* 7785 */ { MAD_F(0x04b56901) /* 0.294289593 */, 19 }, - /* 7786 */ { MAD_F(0x04b59ddb) /* 0.294339997 */, 19 }, - /* 7787 */ { MAD_F(0x04b5d2b6) /* 0.294390403 */, 19 }, - /* 7788 */ { MAD_F(0x04b60791) /* 0.294440812 */, 19 }, - /* 7789 */ { MAD_F(0x04b63c6d) /* 0.294491222 */, 19 }, - /* 7790 */ { MAD_F(0x04b6714a) /* 0.294541635 */, 19 }, - /* 7791 */ { MAD_F(0x04b6a627) /* 0.294592049 */, 19 }, - - /* 7792 */ { MAD_F(0x04b6db05) /* 0.294642466 */, 19 }, - /* 7793 */ { MAD_F(0x04b70fe3) /* 0.294692885 */, 19 }, - /* 7794 */ { MAD_F(0x04b744c2) /* 0.294743306 */, 19 }, - /* 7795 */ { MAD_F(0x04b779a1) /* 0.294793730 */, 19 }, - /* 7796 */ { MAD_F(0x04b7ae81) /* 0.294844155 */, 19 }, - /* 7797 */ { MAD_F(0x04b7e362) /* 0.294894583 */, 19 }, - /* 7798 */ { MAD_F(0x04b81843) /* 0.294945013 */, 19 }, - /* 7799 */ { MAD_F(0x04b84d24) /* 0.294995445 */, 19 }, - /* 7800 */ { MAD_F(0x04b88207) /* 0.295045879 */, 19 }, - /* 7801 */ { MAD_F(0x04b8b6ea) /* 0.295096315 */, 19 }, - /* 7802 */ { MAD_F(0x04b8ebcd) /* 0.295146753 */, 19 }, - /* 7803 */ { MAD_F(0x04b920b1) /* 0.295197194 */, 19 }, - /* 7804 */ { MAD_F(0x04b95596) /* 0.295247637 */, 19 }, - /* 7805 */ { MAD_F(0x04b98a7b) /* 0.295298082 */, 19 }, - /* 7806 */ { MAD_F(0x04b9bf61) /* 0.295348529 */, 19 }, - /* 7807 */ { MAD_F(0x04b9f447) /* 0.295398978 */, 19 }, - - /* 7808 */ { MAD_F(0x04ba292e) /* 0.295449429 */, 19 }, - /* 7809 */ { MAD_F(0x04ba5e16) /* 0.295499883 */, 19 }, - /* 7810 */ { MAD_F(0x04ba92fe) /* 0.295550338 */, 19 }, - /* 7811 */ { MAD_F(0x04bac7e6) /* 0.295600796 */, 19 }, - /* 7812 */ { MAD_F(0x04bafcd0) /* 0.295651256 */, 19 }, - /* 7813 */ { MAD_F(0x04bb31b9) /* 0.295701718 */, 19 }, - /* 7814 */ { MAD_F(0x04bb66a4) /* 0.295752183 */, 19 }, - /* 7815 */ { MAD_F(0x04bb9b8f) /* 0.295802649 */, 19 }, - /* 7816 */ { MAD_F(0x04bbd07a) /* 0.295853118 */, 19 }, - /* 7817 */ { MAD_F(0x04bc0566) /* 0.295903588 */, 19 }, - /* 7818 */ { MAD_F(0x04bc3a53) /* 0.295954061 */, 19 }, - /* 7819 */ { MAD_F(0x04bc6f40) /* 0.296004536 */, 19 }, - /* 7820 */ { MAD_F(0x04bca42e) /* 0.296055013 */, 19 }, - /* 7821 */ { MAD_F(0x04bcd91d) /* 0.296105493 */, 19 }, - /* 7822 */ { MAD_F(0x04bd0e0c) /* 0.296155974 */, 19 }, - /* 7823 */ { MAD_F(0x04bd42fb) /* 0.296206458 */, 19 }, - - /* 7824 */ { MAD_F(0x04bd77ec) /* 0.296256944 */, 19 }, - /* 7825 */ { MAD_F(0x04bdacdc) /* 0.296307432 */, 19 }, - /* 7826 */ { MAD_F(0x04bde1ce) /* 0.296357922 */, 19 }, - /* 7827 */ { MAD_F(0x04be16c0) /* 0.296408414 */, 19 }, - /* 7828 */ { MAD_F(0x04be4bb2) /* 0.296458908 */, 19 }, - /* 7829 */ { MAD_F(0x04be80a5) /* 0.296509405 */, 19 }, - /* 7830 */ { MAD_F(0x04beb599) /* 0.296559904 */, 19 }, - /* 7831 */ { MAD_F(0x04beea8d) /* 0.296610404 */, 19 }, - /* 7832 */ { MAD_F(0x04bf1f82) /* 0.296660907 */, 19 }, - /* 7833 */ { MAD_F(0x04bf5477) /* 0.296711413 */, 19 }, - /* 7834 */ { MAD_F(0x04bf896d) /* 0.296761920 */, 19 }, - /* 7835 */ { MAD_F(0x04bfbe64) /* 0.296812429 */, 19 }, - /* 7836 */ { MAD_F(0x04bff35b) /* 0.296862941 */, 19 }, - /* 7837 */ { MAD_F(0x04c02852) /* 0.296913455 */, 19 }, - /* 7838 */ { MAD_F(0x04c05d4b) /* 0.296963971 */, 19 }, - /* 7839 */ { MAD_F(0x04c09243) /* 0.297014489 */, 19 }, - - /* 7840 */ { MAD_F(0x04c0c73d) /* 0.297065009 */, 19 }, - /* 7841 */ { MAD_F(0x04c0fc37) /* 0.297115531 */, 19 }, - /* 7842 */ { MAD_F(0x04c13131) /* 0.297166056 */, 19 }, - /* 7843 */ { MAD_F(0x04c1662d) /* 0.297216582 */, 19 }, - /* 7844 */ { MAD_F(0x04c19b28) /* 0.297267111 */, 19 }, - /* 7845 */ { MAD_F(0x04c1d025) /* 0.297317642 */, 19 }, - /* 7846 */ { MAD_F(0x04c20521) /* 0.297368175 */, 19 }, - /* 7847 */ { MAD_F(0x04c23a1f) /* 0.297418710 */, 19 }, - /* 7848 */ { MAD_F(0x04c26f1d) /* 0.297469248 */, 19 }, - /* 7849 */ { MAD_F(0x04c2a41b) /* 0.297519787 */, 19 }, - /* 7850 */ { MAD_F(0x04c2d91b) /* 0.297570329 */, 19 }, - /* 7851 */ { MAD_F(0x04c30e1a) /* 0.297620873 */, 19 }, - /* 7852 */ { MAD_F(0x04c3431b) /* 0.297671418 */, 19 }, - /* 7853 */ { MAD_F(0x04c3781c) /* 0.297721967 */, 19 }, - /* 7854 */ { MAD_F(0x04c3ad1d) /* 0.297772517 */, 19 }, - /* 7855 */ { MAD_F(0x04c3e21f) /* 0.297823069 */, 19 }, - - /* 7856 */ { MAD_F(0x04c41722) /* 0.297873624 */, 19 }, - /* 7857 */ { MAD_F(0x04c44c25) /* 0.297924180 */, 19 }, - /* 7858 */ { MAD_F(0x04c48129) /* 0.297974739 */, 19 }, - /* 7859 */ { MAD_F(0x04c4b62d) /* 0.298025300 */, 19 }, - /* 7860 */ { MAD_F(0x04c4eb32) /* 0.298075863 */, 19 }, - /* 7861 */ { MAD_F(0x04c52038) /* 0.298126429 */, 19 }, - /* 7862 */ { MAD_F(0x04c5553e) /* 0.298176996 */, 19 }, - /* 7863 */ { MAD_F(0x04c58a44) /* 0.298227565 */, 19 }, - /* 7864 */ { MAD_F(0x04c5bf4c) /* 0.298278137 */, 19 }, - /* 7865 */ { MAD_F(0x04c5f453) /* 0.298328711 */, 19 }, - /* 7866 */ { MAD_F(0x04c6295c) /* 0.298379287 */, 19 }, - /* 7867 */ { MAD_F(0x04c65e65) /* 0.298429865 */, 19 }, - /* 7868 */ { MAD_F(0x04c6936e) /* 0.298480445 */, 19 }, - /* 7869 */ { MAD_F(0x04c6c878) /* 0.298531028 */, 19 }, - /* 7870 */ { MAD_F(0x04c6fd83) /* 0.298581612 */, 19 }, - /* 7871 */ { MAD_F(0x04c7328e) /* 0.298632199 */, 19 }, - - /* 7872 */ { MAD_F(0x04c7679a) /* 0.298682788 */, 19 }, - /* 7873 */ { MAD_F(0x04c79ca7) /* 0.298733379 */, 19 }, - /* 7874 */ { MAD_F(0x04c7d1b4) /* 0.298783972 */, 19 }, - /* 7875 */ { MAD_F(0x04c806c1) /* 0.298834567 */, 19 }, - /* 7876 */ { MAD_F(0x04c83bcf) /* 0.298885165 */, 19 }, - /* 7877 */ { MAD_F(0x04c870de) /* 0.298935764 */, 19 }, - /* 7878 */ { MAD_F(0x04c8a5ed) /* 0.298986366 */, 19 }, - /* 7879 */ { MAD_F(0x04c8dafd) /* 0.299036970 */, 19 }, - /* 7880 */ { MAD_F(0x04c9100d) /* 0.299087576 */, 19 }, - /* 7881 */ { MAD_F(0x04c9451e) /* 0.299138184 */, 19 }, - /* 7882 */ { MAD_F(0x04c97a30) /* 0.299188794 */, 19 }, - /* 7883 */ { MAD_F(0x04c9af42) /* 0.299239406 */, 19 }, - /* 7884 */ { MAD_F(0x04c9e455) /* 0.299290021 */, 19 }, - /* 7885 */ { MAD_F(0x04ca1968) /* 0.299340638 */, 19 }, - /* 7886 */ { MAD_F(0x04ca4e7c) /* 0.299391256 */, 19 }, - /* 7887 */ { MAD_F(0x04ca8391) /* 0.299441877 */, 19 }, - - /* 7888 */ { MAD_F(0x04cab8a6) /* 0.299492500 */, 19 }, - /* 7889 */ { MAD_F(0x04caedbb) /* 0.299543126 */, 19 }, - /* 7890 */ { MAD_F(0x04cb22d1) /* 0.299593753 */, 19 }, - /* 7891 */ { MAD_F(0x04cb57e8) /* 0.299644382 */, 19 }, - /* 7892 */ { MAD_F(0x04cb8d00) /* 0.299695014 */, 19 }, - /* 7893 */ { MAD_F(0x04cbc217) /* 0.299745648 */, 19 }, - /* 7894 */ { MAD_F(0x04cbf730) /* 0.299796284 */, 19 }, - /* 7895 */ { MAD_F(0x04cc2c49) /* 0.299846922 */, 19 }, - /* 7896 */ { MAD_F(0x04cc6163) /* 0.299897562 */, 19 }, - /* 7897 */ { MAD_F(0x04cc967d) /* 0.299948204 */, 19 }, - /* 7898 */ { MAD_F(0x04cccb98) /* 0.299998849 */, 19 }, - /* 7899 */ { MAD_F(0x04cd00b3) /* 0.300049495 */, 19 }, - /* 7900 */ { MAD_F(0x04cd35cf) /* 0.300100144 */, 19 }, - /* 7901 */ { MAD_F(0x04cd6aeb) /* 0.300150795 */, 19 }, - /* 7902 */ { MAD_F(0x04cda008) /* 0.300201448 */, 19 }, - /* 7903 */ { MAD_F(0x04cdd526) /* 0.300252103 */, 19 }, - - /* 7904 */ { MAD_F(0x04ce0a44) /* 0.300302761 */, 19 }, - /* 7905 */ { MAD_F(0x04ce3f63) /* 0.300353420 */, 19 }, - /* 7906 */ { MAD_F(0x04ce7482) /* 0.300404082 */, 19 }, - /* 7907 */ { MAD_F(0x04cea9a2) /* 0.300454745 */, 19 }, - /* 7908 */ { MAD_F(0x04cedec3) /* 0.300505411 */, 19 }, - /* 7909 */ { MAD_F(0x04cf13e4) /* 0.300556079 */, 19 }, - /* 7910 */ { MAD_F(0x04cf4906) /* 0.300606749 */, 19 }, - /* 7911 */ { MAD_F(0x04cf7e28) /* 0.300657421 */, 19 }, - /* 7912 */ { MAD_F(0x04cfb34b) /* 0.300708096 */, 19 }, - /* 7913 */ { MAD_F(0x04cfe86e) /* 0.300758772 */, 19 }, - /* 7914 */ { MAD_F(0x04d01d92) /* 0.300809451 */, 19 }, - /* 7915 */ { MAD_F(0x04d052b6) /* 0.300860132 */, 19 }, - /* 7916 */ { MAD_F(0x04d087db) /* 0.300910815 */, 19 }, - /* 7917 */ { MAD_F(0x04d0bd01) /* 0.300961500 */, 19 }, - /* 7918 */ { MAD_F(0x04d0f227) /* 0.301012187 */, 19 }, - /* 7919 */ { MAD_F(0x04d1274e) /* 0.301062876 */, 19 }, - - /* 7920 */ { MAD_F(0x04d15c76) /* 0.301113568 */, 19 }, - /* 7921 */ { MAD_F(0x04d1919e) /* 0.301164261 */, 19 }, - /* 7922 */ { MAD_F(0x04d1c6c6) /* 0.301214957 */, 19 }, - /* 7923 */ { MAD_F(0x04d1fbef) /* 0.301265655 */, 19 }, - /* 7924 */ { MAD_F(0x04d23119) /* 0.301316355 */, 19 }, - /* 7925 */ { MAD_F(0x04d26643) /* 0.301367057 */, 19 }, - /* 7926 */ { MAD_F(0x04d29b6e) /* 0.301417761 */, 19 }, - /* 7927 */ { MAD_F(0x04d2d099) /* 0.301468468 */, 19 }, - /* 7928 */ { MAD_F(0x04d305c5) /* 0.301519176 */, 19 }, - /* 7929 */ { MAD_F(0x04d33af2) /* 0.301569887 */, 19 }, - /* 7930 */ { MAD_F(0x04d3701f) /* 0.301620599 */, 19 }, - /* 7931 */ { MAD_F(0x04d3a54d) /* 0.301671314 */, 19 }, - /* 7932 */ { MAD_F(0x04d3da7b) /* 0.301722031 */, 19 }, - /* 7933 */ { MAD_F(0x04d40faa) /* 0.301772751 */, 19 }, - /* 7934 */ { MAD_F(0x04d444d9) /* 0.301823472 */, 19 }, - /* 7935 */ { MAD_F(0x04d47a09) /* 0.301874195 */, 19 }, - - /* 7936 */ { MAD_F(0x04d4af3a) /* 0.301924921 */, 19 }, - /* 7937 */ { MAD_F(0x04d4e46b) /* 0.301975649 */, 19 }, - /* 7938 */ { MAD_F(0x04d5199c) /* 0.302026378 */, 19 }, - /* 7939 */ { MAD_F(0x04d54ecf) /* 0.302077110 */, 19 }, - /* 7940 */ { MAD_F(0x04d58401) /* 0.302127845 */, 19 }, - /* 7941 */ { MAD_F(0x04d5b935) /* 0.302178581 */, 19 }, - /* 7942 */ { MAD_F(0x04d5ee69) /* 0.302229319 */, 19 }, - /* 7943 */ { MAD_F(0x04d6239d) /* 0.302280060 */, 19 }, - /* 7944 */ { MAD_F(0x04d658d2) /* 0.302330802 */, 19 }, - /* 7945 */ { MAD_F(0x04d68e08) /* 0.302381547 */, 19 }, - /* 7946 */ { MAD_F(0x04d6c33e) /* 0.302432294 */, 19 }, - /* 7947 */ { MAD_F(0x04d6f875) /* 0.302483043 */, 19 }, - /* 7948 */ { MAD_F(0x04d72dad) /* 0.302533794 */, 19 }, - /* 7949 */ { MAD_F(0x04d762e5) /* 0.302584547 */, 19 }, - /* 7950 */ { MAD_F(0x04d7981d) /* 0.302635303 */, 19 }, - /* 7951 */ { MAD_F(0x04d7cd56) /* 0.302686060 */, 19 }, - - /* 7952 */ { MAD_F(0x04d80290) /* 0.302736820 */, 19 }, - /* 7953 */ { MAD_F(0x04d837ca) /* 0.302787581 */, 19 }, - /* 7954 */ { MAD_F(0x04d86d05) /* 0.302838345 */, 19 }, - /* 7955 */ { MAD_F(0x04d8a240) /* 0.302889111 */, 19 }, - /* 7956 */ { MAD_F(0x04d8d77c) /* 0.302939879 */, 19 }, - /* 7957 */ { MAD_F(0x04d90cb9) /* 0.302990650 */, 19 }, - /* 7958 */ { MAD_F(0x04d941f6) /* 0.303041422 */, 19 }, - /* 7959 */ { MAD_F(0x04d97734) /* 0.303092197 */, 19 }, - /* 7960 */ { MAD_F(0x04d9ac72) /* 0.303142973 */, 19 }, - /* 7961 */ { MAD_F(0x04d9e1b1) /* 0.303193752 */, 19 }, - /* 7962 */ { MAD_F(0x04da16f0) /* 0.303244533 */, 19 }, - /* 7963 */ { MAD_F(0x04da4c30) /* 0.303295316 */, 19 }, - /* 7964 */ { MAD_F(0x04da8171) /* 0.303346101 */, 19 }, - /* 7965 */ { MAD_F(0x04dab6b2) /* 0.303396889 */, 19 }, - /* 7966 */ { MAD_F(0x04daebf4) /* 0.303447678 */, 19 }, - /* 7967 */ { MAD_F(0x04db2136) /* 0.303498469 */, 19 }, - - /* 7968 */ { MAD_F(0x04db5679) /* 0.303549263 */, 19 }, - /* 7969 */ { MAD_F(0x04db8bbc) /* 0.303600059 */, 19 }, - /* 7970 */ { MAD_F(0x04dbc100) /* 0.303650857 */, 19 }, - /* 7971 */ { MAD_F(0x04dbf644) /* 0.303701657 */, 19 }, - /* 7972 */ { MAD_F(0x04dc2b8a) /* 0.303752459 */, 19 }, - /* 7973 */ { MAD_F(0x04dc60cf) /* 0.303803263 */, 19 }, - /* 7974 */ { MAD_F(0x04dc9616) /* 0.303854070 */, 19 }, - /* 7975 */ { MAD_F(0x04dccb5c) /* 0.303904878 */, 19 }, - /* 7976 */ { MAD_F(0x04dd00a4) /* 0.303955689 */, 19 }, - /* 7977 */ { MAD_F(0x04dd35ec) /* 0.304006502 */, 19 }, - /* 7978 */ { MAD_F(0x04dd6b34) /* 0.304057317 */, 19 }, - /* 7979 */ { MAD_F(0x04dda07d) /* 0.304108134 */, 19 }, - /* 7980 */ { MAD_F(0x04ddd5c7) /* 0.304158953 */, 19 }, - /* 7981 */ { MAD_F(0x04de0b11) /* 0.304209774 */, 19 }, - /* 7982 */ { MAD_F(0x04de405c) /* 0.304260597 */, 19 }, - /* 7983 */ { MAD_F(0x04de75a7) /* 0.304311423 */, 19 }, - - /* 7984 */ { MAD_F(0x04deaaf3) /* 0.304362251 */, 19 }, - /* 7985 */ { MAD_F(0x04dee040) /* 0.304413080 */, 19 }, - /* 7986 */ { MAD_F(0x04df158d) /* 0.304463912 */, 19 }, - /* 7987 */ { MAD_F(0x04df4adb) /* 0.304514746 */, 19 }, - /* 7988 */ { MAD_F(0x04df8029) /* 0.304565582 */, 19 }, - /* 7989 */ { MAD_F(0x04dfb578) /* 0.304616421 */, 19 }, - /* 7990 */ { MAD_F(0x04dfeac7) /* 0.304667261 */, 19 }, - /* 7991 */ { MAD_F(0x04e02017) /* 0.304718103 */, 19 }, - /* 7992 */ { MAD_F(0x04e05567) /* 0.304768948 */, 19 }, - /* 7993 */ { MAD_F(0x04e08ab8) /* 0.304819795 */, 19 }, - /* 7994 */ { MAD_F(0x04e0c00a) /* 0.304870644 */, 19 }, - /* 7995 */ { MAD_F(0x04e0f55c) /* 0.304921495 */, 19 }, - /* 7996 */ { MAD_F(0x04e12aaf) /* 0.304972348 */, 19 }, - /* 7997 */ { MAD_F(0x04e16002) /* 0.305023203 */, 19 }, - /* 7998 */ { MAD_F(0x04e19556) /* 0.305074060 */, 19 }, - /* 7999 */ { MAD_F(0x04e1caab) /* 0.305124920 */, 19 }, - - /* 8000 */ { MAD_F(0x04e20000) /* 0.305175781 */, 19 }, - /* 8001 */ { MAD_F(0x04e23555) /* 0.305226645 */, 19 }, - /* 8002 */ { MAD_F(0x04e26aac) /* 0.305277511 */, 19 }, - /* 8003 */ { MAD_F(0x04e2a002) /* 0.305328379 */, 19 }, - /* 8004 */ { MAD_F(0x04e2d55a) /* 0.305379249 */, 19 }, - /* 8005 */ { MAD_F(0x04e30ab2) /* 0.305430121 */, 19 }, - /* 8006 */ { MAD_F(0x04e3400a) /* 0.305480995 */, 19 }, - /* 8007 */ { MAD_F(0x04e37563) /* 0.305531872 */, 19 }, - /* 8008 */ { MAD_F(0x04e3aabd) /* 0.305582750 */, 19 }, - /* 8009 */ { MAD_F(0x04e3e017) /* 0.305633631 */, 19 }, - /* 8010 */ { MAD_F(0x04e41572) /* 0.305684513 */, 19 }, - /* 8011 */ { MAD_F(0x04e44acd) /* 0.305735398 */, 19 }, - /* 8012 */ { MAD_F(0x04e48029) /* 0.305786285 */, 19 }, - /* 8013 */ { MAD_F(0x04e4b585) /* 0.305837174 */, 19 }, - /* 8014 */ { MAD_F(0x04e4eae2) /* 0.305888066 */, 19 }, - /* 8015 */ { MAD_F(0x04e52040) /* 0.305938959 */, 19 }, - - /* 8016 */ { MAD_F(0x04e5559e) /* 0.305989854 */, 19 }, - /* 8017 */ { MAD_F(0x04e58afd) /* 0.306040752 */, 19 }, - /* 8018 */ { MAD_F(0x04e5c05c) /* 0.306091652 */, 19 }, - /* 8019 */ { MAD_F(0x04e5f5bc) /* 0.306142554 */, 19 }, - /* 8020 */ { MAD_F(0x04e62b1c) /* 0.306193457 */, 19 }, - /* 8021 */ { MAD_F(0x04e6607d) /* 0.306244364 */, 19 }, - /* 8022 */ { MAD_F(0x04e695df) /* 0.306295272 */, 19 }, - /* 8023 */ { MAD_F(0x04e6cb41) /* 0.306346182 */, 19 }, - /* 8024 */ { MAD_F(0x04e700a3) /* 0.306397094 */, 19 }, - /* 8025 */ { MAD_F(0x04e73607) /* 0.306448009 */, 19 }, - /* 8026 */ { MAD_F(0x04e76b6b) /* 0.306498925 */, 19 }, - /* 8027 */ { MAD_F(0x04e7a0cf) /* 0.306549844 */, 19 }, - /* 8028 */ { MAD_F(0x04e7d634) /* 0.306600765 */, 19 }, - /* 8029 */ { MAD_F(0x04e80b99) /* 0.306651688 */, 19 }, - /* 8030 */ { MAD_F(0x04e84100) /* 0.306702613 */, 19 }, - /* 8031 */ { MAD_F(0x04e87666) /* 0.306753540 */, 19 }, - - /* 8032 */ { MAD_F(0x04e8abcd) /* 0.306804470 */, 19 }, - /* 8033 */ { MAD_F(0x04e8e135) /* 0.306855401 */, 19 }, - /* 8034 */ { MAD_F(0x04e9169e) /* 0.306906334 */, 19 }, - /* 8035 */ { MAD_F(0x04e94c07) /* 0.306957270 */, 19 }, - /* 8036 */ { MAD_F(0x04e98170) /* 0.307008208 */, 19 }, - /* 8037 */ { MAD_F(0x04e9b6da) /* 0.307059148 */, 19 }, - /* 8038 */ { MAD_F(0x04e9ec45) /* 0.307110090 */, 19 }, - /* 8039 */ { MAD_F(0x04ea21b0) /* 0.307161034 */, 19 }, - /* 8040 */ { MAD_F(0x04ea571c) /* 0.307211980 */, 19 }, - /* 8041 */ { MAD_F(0x04ea8c88) /* 0.307262928 */, 19 }, - /* 8042 */ { MAD_F(0x04eac1f5) /* 0.307313879 */, 19 }, - /* 8043 */ { MAD_F(0x04eaf762) /* 0.307364831 */, 19 }, - /* 8044 */ { MAD_F(0x04eb2cd0) /* 0.307415786 */, 19 }, - /* 8045 */ { MAD_F(0x04eb623f) /* 0.307466743 */, 19 }, - /* 8046 */ { MAD_F(0x04eb97ae) /* 0.307517702 */, 19 }, - /* 8047 */ { MAD_F(0x04ebcd1e) /* 0.307568663 */, 19 }, - - /* 8048 */ { MAD_F(0x04ec028e) /* 0.307619626 */, 19 }, - /* 8049 */ { MAD_F(0x04ec37ff) /* 0.307670591 */, 19 }, - /* 8050 */ { MAD_F(0x04ec6d71) /* 0.307721558 */, 19 }, - /* 8051 */ { MAD_F(0x04eca2e3) /* 0.307772528 */, 19 }, - /* 8052 */ { MAD_F(0x04ecd855) /* 0.307823499 */, 19 }, - /* 8053 */ { MAD_F(0x04ed0dc8) /* 0.307874473 */, 19 }, - /* 8054 */ { MAD_F(0x04ed433c) /* 0.307925449 */, 19 }, - /* 8055 */ { MAD_F(0x04ed78b0) /* 0.307976426 */, 19 }, - /* 8056 */ { MAD_F(0x04edae25) /* 0.308027406 */, 19 }, - /* 8057 */ { MAD_F(0x04ede39a) /* 0.308078389 */, 19 }, - /* 8058 */ { MAD_F(0x04ee1910) /* 0.308129373 */, 19 }, - /* 8059 */ { MAD_F(0x04ee4e87) /* 0.308180359 */, 19 }, - /* 8060 */ { MAD_F(0x04ee83fe) /* 0.308231347 */, 19 }, - /* 8061 */ { MAD_F(0x04eeb976) /* 0.308282338 */, 19 }, - /* 8062 */ { MAD_F(0x04eeeeee) /* 0.308333331 */, 19 }, - /* 8063 */ { MAD_F(0x04ef2467) /* 0.308384325 */, 19 }, - - /* 8064 */ { MAD_F(0x04ef59e0) /* 0.308435322 */, 19 }, - /* 8065 */ { MAD_F(0x04ef8f5a) /* 0.308486321 */, 19 }, - /* 8066 */ { MAD_F(0x04efc4d5) /* 0.308537322 */, 19 }, - /* 8067 */ { MAD_F(0x04effa50) /* 0.308588325 */, 19 }, - /* 8068 */ { MAD_F(0x04f02fcb) /* 0.308639331 */, 19 }, - /* 8069 */ { MAD_F(0x04f06547) /* 0.308690338 */, 19 }, - /* 8070 */ { MAD_F(0x04f09ac4) /* 0.308741348 */, 19 }, - /* 8071 */ { MAD_F(0x04f0d041) /* 0.308792359 */, 19 }, - /* 8072 */ { MAD_F(0x04f105bf) /* 0.308843373 */, 19 }, - /* 8073 */ { MAD_F(0x04f13b3e) /* 0.308894389 */, 19 }, - /* 8074 */ { MAD_F(0x04f170bd) /* 0.308945407 */, 19 }, - /* 8075 */ { MAD_F(0x04f1a63c) /* 0.308996427 */, 19 }, - /* 8076 */ { MAD_F(0x04f1dbbd) /* 0.309047449 */, 19 }, - /* 8077 */ { MAD_F(0x04f2113d) /* 0.309098473 */, 19 }, - /* 8078 */ { MAD_F(0x04f246bf) /* 0.309149499 */, 19 }, - /* 8079 */ { MAD_F(0x04f27c40) /* 0.309200528 */, 19 }, - - /* 8080 */ { MAD_F(0x04f2b1c3) /* 0.309251558 */, 19 }, - /* 8081 */ { MAD_F(0x04f2e746) /* 0.309302591 */, 19 }, - /* 8082 */ { MAD_F(0x04f31cc9) /* 0.309353626 */, 19 }, - /* 8083 */ { MAD_F(0x04f3524d) /* 0.309404663 */, 19 }, - /* 8084 */ { MAD_F(0x04f387d2) /* 0.309455702 */, 19 }, - /* 8085 */ { MAD_F(0x04f3bd57) /* 0.309506743 */, 19 }, - /* 8086 */ { MAD_F(0x04f3f2dd) /* 0.309557786 */, 19 }, - /* 8087 */ { MAD_F(0x04f42864) /* 0.309608831 */, 19 }, - /* 8088 */ { MAD_F(0x04f45dea) /* 0.309659879 */, 19 }, - /* 8089 */ { MAD_F(0x04f49372) /* 0.309710928 */, 19 }, - /* 8090 */ { MAD_F(0x04f4c8fa) /* 0.309761980 */, 19 }, - /* 8091 */ { MAD_F(0x04f4fe83) /* 0.309813033 */, 19 }, - /* 8092 */ { MAD_F(0x04f5340c) /* 0.309864089 */, 19 }, - /* 8093 */ { MAD_F(0x04f56996) /* 0.309915147 */, 19 }, - /* 8094 */ { MAD_F(0x04f59f20) /* 0.309966207 */, 19 }, - /* 8095 */ { MAD_F(0x04f5d4ab) /* 0.310017269 */, 19 }, - - /* 8096 */ { MAD_F(0x04f60a36) /* 0.310068333 */, 19 }, - /* 8097 */ { MAD_F(0x04f63fc2) /* 0.310119400 */, 19 }, - /* 8098 */ { MAD_F(0x04f6754f) /* 0.310170468 */, 19 }, - /* 8099 */ { MAD_F(0x04f6aadc) /* 0.310221539 */, 19 }, - /* 8100 */ { MAD_F(0x04f6e06a) /* 0.310272611 */, 19 }, - /* 8101 */ { MAD_F(0x04f715f8) /* 0.310323686 */, 19 }, - /* 8102 */ { MAD_F(0x04f74b87) /* 0.310374763 */, 19 }, - /* 8103 */ { MAD_F(0x04f78116) /* 0.310425842 */, 19 }, - /* 8104 */ { MAD_F(0x04f7b6a6) /* 0.310476923 */, 19 }, - /* 8105 */ { MAD_F(0x04f7ec37) /* 0.310528006 */, 19 }, - /* 8106 */ { MAD_F(0x04f821c8) /* 0.310579091 */, 19 }, - /* 8107 */ { MAD_F(0x04f85759) /* 0.310630179 */, 19 }, - /* 8108 */ { MAD_F(0x04f88cec) /* 0.310681268 */, 19 }, - /* 8109 */ { MAD_F(0x04f8c27e) /* 0.310732360 */, 19 }, - /* 8110 */ { MAD_F(0x04f8f812) /* 0.310783453 */, 19 }, - /* 8111 */ { MAD_F(0x04f92da6) /* 0.310834549 */, 19 }, - - /* 8112 */ { MAD_F(0x04f9633a) /* 0.310885647 */, 19 }, - /* 8113 */ { MAD_F(0x04f998cf) /* 0.310936747 */, 19 }, - /* 8114 */ { MAD_F(0x04f9ce65) /* 0.310987849 */, 19 }, - /* 8115 */ { MAD_F(0x04fa03fb) /* 0.311038953 */, 19 }, - /* 8116 */ { MAD_F(0x04fa3992) /* 0.311090059 */, 19 }, - /* 8117 */ { MAD_F(0x04fa6f29) /* 0.311141168 */, 19 }, - /* 8118 */ { MAD_F(0x04faa4c1) /* 0.311192278 */, 19 }, - /* 8119 */ { MAD_F(0x04fada59) /* 0.311243390 */, 19 }, - /* 8120 */ { MAD_F(0x04fb0ff2) /* 0.311294505 */, 19 }, - /* 8121 */ { MAD_F(0x04fb458c) /* 0.311345622 */, 19 }, - /* 8122 */ { MAD_F(0x04fb7b26) /* 0.311396741 */, 19 }, - /* 8123 */ { MAD_F(0x04fbb0c1) /* 0.311447862 */, 19 }, - /* 8124 */ { MAD_F(0x04fbe65c) /* 0.311498985 */, 19 }, - /* 8125 */ { MAD_F(0x04fc1bf8) /* 0.311550110 */, 19 }, - /* 8126 */ { MAD_F(0x04fc5194) /* 0.311601237 */, 19 }, - /* 8127 */ { MAD_F(0x04fc8731) /* 0.311652366 */, 19 }, - - /* 8128 */ { MAD_F(0x04fcbcce) /* 0.311703498 */, 19 }, - /* 8129 */ { MAD_F(0x04fcf26c) /* 0.311754631 */, 19 }, - /* 8130 */ { MAD_F(0x04fd280b) /* 0.311805767 */, 19 }, - /* 8131 */ { MAD_F(0x04fd5daa) /* 0.311856905 */, 19 }, - /* 8132 */ { MAD_F(0x04fd934a) /* 0.311908044 */, 19 }, - /* 8133 */ { MAD_F(0x04fdc8ea) /* 0.311959186 */, 19 }, - /* 8134 */ { MAD_F(0x04fdfe8b) /* 0.312010330 */, 19 }, - /* 8135 */ { MAD_F(0x04fe342c) /* 0.312061476 */, 19 }, - /* 8136 */ { MAD_F(0x04fe69ce) /* 0.312112625 */, 19 }, - /* 8137 */ { MAD_F(0x04fe9f71) /* 0.312163775 */, 19 }, - /* 8138 */ { MAD_F(0x04fed514) /* 0.312214927 */, 19 }, - /* 8139 */ { MAD_F(0x04ff0ab8) /* 0.312266082 */, 19 }, - /* 8140 */ { MAD_F(0x04ff405c) /* 0.312317238 */, 19 }, - /* 8141 */ { MAD_F(0x04ff7601) /* 0.312368397 */, 19 }, - /* 8142 */ { MAD_F(0x04ffaba6) /* 0.312419558 */, 19 }, - /* 8143 */ { MAD_F(0x04ffe14c) /* 0.312470720 */, 19 }, - - /* 8144 */ { MAD_F(0x050016f3) /* 0.312521885 */, 19 }, - /* 8145 */ { MAD_F(0x05004c9a) /* 0.312573052 */, 19 }, - /* 8146 */ { MAD_F(0x05008241) /* 0.312624222 */, 19 }, - /* 8147 */ { MAD_F(0x0500b7e9) /* 0.312675393 */, 19 }, - /* 8148 */ { MAD_F(0x0500ed92) /* 0.312726566 */, 19 }, - /* 8149 */ { MAD_F(0x0501233b) /* 0.312777742 */, 19 }, - /* 8150 */ { MAD_F(0x050158e5) /* 0.312828919 */, 19 }, - /* 8151 */ { MAD_F(0x05018e90) /* 0.312880099 */, 19 }, - /* 8152 */ { MAD_F(0x0501c43b) /* 0.312931280 */, 19 }, - /* 8153 */ { MAD_F(0x0501f9e6) /* 0.312982464 */, 19 }, - /* 8154 */ { MAD_F(0x05022f92) /* 0.313033650 */, 19 }, - /* 8155 */ { MAD_F(0x0502653f) /* 0.313084838 */, 19 }, - /* 8156 */ { MAD_F(0x05029aec) /* 0.313136028 */, 19 }, - /* 8157 */ { MAD_F(0x0502d09a) /* 0.313187220 */, 19 }, - /* 8158 */ { MAD_F(0x05030648) /* 0.313238414 */, 19 }, - /* 8159 */ { MAD_F(0x05033bf7) /* 0.313289611 */, 19 }, - - /* 8160 */ { MAD_F(0x050371a7) /* 0.313340809 */, 19 }, - /* 8161 */ { MAD_F(0x0503a757) /* 0.313392010 */, 19 }, - /* 8162 */ { MAD_F(0x0503dd07) /* 0.313443212 */, 19 }, - /* 8163 */ { MAD_F(0x050412b9) /* 0.313494417 */, 19 }, - /* 8164 */ { MAD_F(0x0504486a) /* 0.313545624 */, 19 }, - /* 8165 */ { MAD_F(0x05047e1d) /* 0.313596833 */, 19 }, - /* 8166 */ { MAD_F(0x0504b3cf) /* 0.313648044 */, 19 }, - /* 8167 */ { MAD_F(0x0504e983) /* 0.313699257 */, 19 }, - /* 8168 */ { MAD_F(0x05051f37) /* 0.313750472 */, 19 }, - /* 8169 */ { MAD_F(0x050554eb) /* 0.313801689 */, 19 }, - /* 8170 */ { MAD_F(0x05058aa0) /* 0.313852909 */, 19 }, - /* 8171 */ { MAD_F(0x0505c056) /* 0.313904130 */, 19 }, - /* 8172 */ { MAD_F(0x0505f60c) /* 0.313955354 */, 19 }, - /* 8173 */ { MAD_F(0x05062bc3) /* 0.314006579 */, 19 }, - /* 8174 */ { MAD_F(0x0506617a) /* 0.314057807 */, 19 }, - /* 8175 */ { MAD_F(0x05069732) /* 0.314109037 */, 19 }, - - /* 8176 */ { MAD_F(0x0506cceb) /* 0.314160269 */, 19 }, - /* 8177 */ { MAD_F(0x050702a4) /* 0.314211502 */, 19 }, - /* 8178 */ { MAD_F(0x0507385d) /* 0.314262739 */, 19 }, - /* 8179 */ { MAD_F(0x05076e17) /* 0.314313977 */, 19 }, - /* 8180 */ { MAD_F(0x0507a3d2) /* 0.314365217 */, 19 }, - /* 8181 */ { MAD_F(0x0507d98d) /* 0.314416459 */, 19 }, - /* 8182 */ { MAD_F(0x05080f49) /* 0.314467704 */, 19 }, - /* 8183 */ { MAD_F(0x05084506) /* 0.314518950 */, 19 }, - /* 8184 */ { MAD_F(0x05087ac2) /* 0.314570199 */, 19 }, - /* 8185 */ { MAD_F(0x0508b080) /* 0.314621449 */, 19 }, - /* 8186 */ { MAD_F(0x0508e63e) /* 0.314672702 */, 19 }, - /* 8187 */ { MAD_F(0x05091bfd) /* 0.314723957 */, 19 }, - /* 8188 */ { MAD_F(0x050951bc) /* 0.314775214 */, 19 }, - /* 8189 */ { MAD_F(0x0509877c) /* 0.314826473 */, 19 }, - /* 8190 */ { MAD_F(0x0509bd3c) /* 0.314877734 */, 19 }, - /* 8191 */ { MAD_F(0x0509f2fd) /* 0.314928997 */, 19 }, - - /* 8192 */ { MAD_F(0x050a28be) /* 0.314980262 */, 19 }, - /* 8193 */ { MAD_F(0x050a5e80) /* 0.315031530 */, 19 }, - /* 8194 */ { MAD_F(0x050a9443) /* 0.315082799 */, 19 }, - /* 8195 */ { MAD_F(0x050aca06) /* 0.315134071 */, 19 }, - /* 8196 */ { MAD_F(0x050affc9) /* 0.315185344 */, 19 }, - /* 8197 */ { MAD_F(0x050b358e) /* 0.315236620 */, 19 }, - /* 8198 */ { MAD_F(0x050b6b52) /* 0.315287898 */, 19 }, - /* 8199 */ { MAD_F(0x050ba118) /* 0.315339178 */, 19 }, - /* 8200 */ { MAD_F(0x050bd6de) /* 0.315390460 */, 19 }, - /* 8201 */ { MAD_F(0x050c0ca4) /* 0.315441744 */, 19 }, - /* 8202 */ { MAD_F(0x050c426b) /* 0.315493030 */, 19 }, - /* 8203 */ { MAD_F(0x050c7833) /* 0.315544318 */, 19 }, - /* 8204 */ { MAD_F(0x050cadfb) /* 0.315595608 */, 19 }, - /* 8205 */ { MAD_F(0x050ce3c4) /* 0.315646901 */, 19 }, - /* 8206 */ { MAD_F(0x050d198d) /* 0.315698195 */, 19 } diff --git a/lib-src/libmad/sf_table.dat b/lib-src/libmad/sf_table.dat deleted file mode 100644 index 9fceae86d..000000000 --- a/lib-src/libmad/sf_table.dat +++ /dev/null @@ -1,106 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: sf_table.dat,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -/* - * These are the scalefactor values for Layer I and Layer II. - * The values are from Table B.1 of ISO/IEC 11172-3. - * - * There is some error introduced by the 32-bit fixed-point representation; - * the amount of error is shown. For 16-bit PCM output, this shouldn't be - * too much of a problem. - * - * Strictly speaking, Table B.1 has only 63 entries (0-62), thus a strict - * interpretation of ISO/IEC 11172-3 would suggest that a scalefactor index of - * 63 is invalid. However, for better compatibility with current practices, we - * add a 64th entry. - */ - - MAD_F(0x20000000), /* 2.000000000000 => 2.000000000000, e 0.000000000000 */ - MAD_F(0x1965fea5), /* 1.587401051968 => 1.587401051074, e 0.000000000894 */ - MAD_F(0x1428a2fa), /* 1.259921049895 => 1.259921051562, e -0.000000001667 */ - MAD_F(0x10000000), /* 1.000000000000 => 1.000000000000, e 0.000000000000 */ - MAD_F(0x0cb2ff53), /* 0.793700525984 => 0.793700527400, e -0.000000001416 */ - MAD_F(0x0a14517d), /* 0.629960524947 => 0.629960525781, e -0.000000000833 */ - MAD_F(0x08000000), /* 0.500000000000 => 0.500000000000, e 0.000000000000 */ - MAD_F(0x06597fa9), /* 0.396850262992 => 0.396850261837, e 0.000000001155 */ - - MAD_F(0x050a28be), /* 0.314980262474 => 0.314980261028, e 0.000000001446 */ - MAD_F(0x04000000), /* 0.250000000000 => 0.250000000000, e 0.000000000000 */ - MAD_F(0x032cbfd5), /* 0.198425131496 => 0.198425132781, e -0.000000001285 */ - MAD_F(0x0285145f), /* 0.157490131237 => 0.157490130514, e 0.000000000723 */ - MAD_F(0x02000000), /* 0.125000000000 => 0.125000000000, e 0.000000000000 */ - MAD_F(0x01965fea), /* 0.099212565748 => 0.099212564528, e 0.000000001220 */ - MAD_F(0x01428a30), /* 0.078745065618 => 0.078745067120, e -0.000000001501 */ - MAD_F(0x01000000), /* 0.062500000000 => 0.062500000000, e 0.000000000000 */ - - MAD_F(0x00cb2ff5), /* 0.049606282874 => 0.049606282264, e 0.000000000610 */ - MAD_F(0x00a14518), /* 0.039372532809 => 0.039372533560, e -0.000000000751 */ - MAD_F(0x00800000), /* 0.031250000000 => 0.031250000000, e 0.000000000000 */ - MAD_F(0x006597fb), /* 0.024803141437 => 0.024803142995, e -0.000000001558 */ - MAD_F(0x0050a28c), /* 0.019686266405 => 0.019686266780, e -0.000000000375 */ - MAD_F(0x00400000), /* 0.015625000000 => 0.015625000000, e 0.000000000000 */ - MAD_F(0x0032cbfd), /* 0.012401570719 => 0.012401569635, e 0.000000001084 */ - MAD_F(0x00285146), /* 0.009843133202 => 0.009843133390, e -0.000000000188 */ - - MAD_F(0x00200000), /* 0.007812500000 => 0.007812500000, e 0.000000000000 */ - MAD_F(0x001965ff), /* 0.006200785359 => 0.006200786680, e -0.000000001321 */ - MAD_F(0x001428a3), /* 0.004921566601 => 0.004921566695, e -0.000000000094 */ - MAD_F(0x00100000), /* 0.003906250000 => 0.003906250000, e 0.000000000000 */ - MAD_F(0x000cb2ff), /* 0.003100392680 => 0.003100391477, e 0.000000001202 */ - MAD_F(0x000a1451), /* 0.002460783301 => 0.002460781485, e 0.000000001816 */ - MAD_F(0x00080000), /* 0.001953125000 => 0.001953125000, e 0.000000000000 */ - MAD_F(0x00065980), /* 0.001550196340 => 0.001550197601, e -0.000000001262 */ - - MAD_F(0x00050a29), /* 0.001230391650 => 0.001230392605, e -0.000000000955 */ - MAD_F(0x00040000), /* 0.000976562500 => 0.000976562500, e 0.000000000000 */ - MAD_F(0x00032cc0), /* 0.000775098170 => 0.000775098801, e -0.000000000631 */ - MAD_F(0x00028514), /* 0.000615195825 => 0.000615194440, e 0.000000001385 */ - MAD_F(0x00020000), /* 0.000488281250 => 0.000488281250, e 0.000000000000 */ - MAD_F(0x00019660), /* 0.000387549085 => 0.000387549400, e -0.000000000315 */ - MAD_F(0x0001428a), /* 0.000307597913 => 0.000307597220, e 0.000000000693 */ - MAD_F(0x00010000), /* 0.000244140625 => 0.000244140625, e 0.000000000000 */ - - MAD_F(0x0000cb30), /* 0.000193774542 => 0.000193774700, e -0.000000000158 */ - MAD_F(0x0000a145), /* 0.000153798956 => 0.000153798610, e 0.000000000346 */ - MAD_F(0x00008000), /* 0.000122070313 => 0.000122070313, e 0.000000000000 */ - MAD_F(0x00006598), /* 0.000096887271 => 0.000096887350, e -0.000000000079 */ - MAD_F(0x000050a3), /* 0.000076899478 => 0.000076901168, e -0.000000001689 */ - MAD_F(0x00004000), /* 0.000061035156 => 0.000061035156, e 0.000000000000 */ - MAD_F(0x000032cc), /* 0.000048443636 => 0.000048443675, e -0.000000000039 */ - MAD_F(0x00002851), /* 0.000038449739 => 0.000038448721, e 0.000000001018 */ - - MAD_F(0x00002000), /* 0.000030517578 => 0.000030517578, e 0.000000000000 */ - MAD_F(0x00001966), /* 0.000024221818 => 0.000024221838, e -0.000000000020 */ - MAD_F(0x00001429), /* 0.000019224870 => 0.000019226223, e -0.000000001354 */ - MAD_F(0x00001000), /* 0.000015258789 => 0.000015258789, e -0.000000000000 */ - MAD_F(0x00000cb3), /* 0.000012110909 => 0.000012110919, e -0.000000000010 */ - MAD_F(0x00000a14), /* 0.000009612435 => 0.000009611249, e 0.000000001186 */ - MAD_F(0x00000800), /* 0.000007629395 => 0.000007629395, e -0.000000000000 */ - MAD_F(0x00000659), /* 0.000006055454 => 0.000006053597, e 0.000000001858 */ - - MAD_F(0x0000050a), /* 0.000004806217 => 0.000004805624, e 0.000000000593 */ - MAD_F(0x00000400), /* 0.000003814697 => 0.000003814697, e 0.000000000000 */ - MAD_F(0x0000032d), /* 0.000003027727 => 0.000003028661, e -0.000000000934 */ - MAD_F(0x00000285), /* 0.000002403109 => 0.000002402812, e 0.000000000296 */ - MAD_F(0x00000200), /* 0.000001907349 => 0.000001907349, e -0.000000000000 */ - MAD_F(0x00000196), /* 0.000001513864 => 0.000001512468, e 0.000000001396 */ - MAD_F(0x00000143), /* 0.000001201554 => 0.000001203269, e -0.000000001714 */ - MAD_F(0x00000000) /* this compatibility entry is not part of Table B.1 */ diff --git a/lib-src/libmad/stamp-h.in b/lib-src/libmad/stamp-h.in deleted file mode 100644 index 9788f7023..000000000 --- a/lib-src/libmad/stamp-h.in +++ /dev/null @@ -1 +0,0 @@ -timestamp diff --git a/lib-src/libmad/stream.c b/lib-src/libmad/stream.c deleted file mode 100644 index a9f9394a5..000000000 --- a/lib-src/libmad/stream.c +++ /dev/null @@ -1,161 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: stream.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# include "bit.h" -# include "stream.h" - -/* - * NAME: stream->init() - * DESCRIPTION: initialize stream struct - */ -void mad_stream_init(struct mad_stream *stream) -{ - stream->buffer = 0; - stream->bufend = 0; - stream->skiplen = 0; - - stream->sync = 0; - stream->freerate = 0; - - stream->this_frame = 0; - stream->next_frame = 0; - mad_bit_init(&stream->ptr, 0); - - mad_bit_init(&stream->anc_ptr, 0); - stream->anc_bitlen = 0; - - stream->main_data = 0; - stream->md_len = 0; - - stream->options = 0; - stream->error = MAD_ERROR_NONE; -} - -/* - * NAME: stream->finish() - * DESCRIPTION: deallocate any dynamic memory associated with stream - */ -void mad_stream_finish(struct mad_stream *stream) -{ - if (stream->main_data) { - free(stream->main_data); - stream->main_data = 0; - } - - mad_bit_finish(&stream->anc_ptr); - mad_bit_finish(&stream->ptr); -} - -/* - * NAME: stream->buffer() - * DESCRIPTION: set stream buffer pointers - */ -void mad_stream_buffer(struct mad_stream *stream, - unsigned char const *buffer, unsigned long length) -{ - stream->buffer = buffer; - stream->bufend = buffer + length; - - stream->this_frame = buffer; - stream->next_frame = buffer; - - stream->sync = 1; - - mad_bit_init(&stream->ptr, buffer); -} - -/* - * NAME: stream->skip() - * DESCRIPTION: arrange to skip bytes before the next frame - */ -void mad_stream_skip(struct mad_stream *stream, unsigned long length) -{ - stream->skiplen += length; -} - -/* - * NAME: stream->sync() - * DESCRIPTION: locate the next stream sync word - */ -int mad_stream_sync(struct mad_stream *stream) -{ - register unsigned char const *ptr, *end; - - ptr = mad_bit_nextbyte(&stream->ptr); - end = stream->bufend; - - while (ptr < end - 1 && - !(ptr[0] == 0xff && (ptr[1] & 0xe0) == 0xe0)) - ++ptr; - - if (end - ptr < MAD_BUFFER_GUARD) - return -1; - - mad_bit_init(&stream->ptr, ptr); - - return 0; -} - -/* - * NAME: stream->errorstr() - * DESCRIPTION: return a string description of the current error condition - */ -char const *mad_stream_errorstr(struct mad_stream const *stream) -{ - switch (stream->error) { - case MAD_ERROR_NONE: return "no error"; - - case MAD_ERROR_BUFLEN: return "input buffer too small (or EOF)"; - case MAD_ERROR_BUFPTR: return "invalid (null) buffer pointer"; - - case MAD_ERROR_NOMEM: return "not enough memory"; - - case MAD_ERROR_LOSTSYNC: return "lost synchronization"; - case MAD_ERROR_BADLAYER: return "reserved header layer value"; - case MAD_ERROR_BADBITRATE: return "forbidden bitrate value"; - case MAD_ERROR_BADSAMPLERATE: return "reserved sample frequency value"; - case MAD_ERROR_BADEMPHASIS: return "reserved emphasis value"; - - case MAD_ERROR_BADCRC: return "CRC check failed"; - case MAD_ERROR_BADBITALLOC: return "forbidden bit allocation value"; - case MAD_ERROR_BADSCALEFACTOR: return "bad scalefactor index"; - case MAD_ERROR_BADMODE: return "bad bitrate/mode combination"; - case MAD_ERROR_BADFRAMELEN: return "bad frame length"; - case MAD_ERROR_BADBIGVALUES: return "bad big_values count"; - case MAD_ERROR_BADBLOCKTYPE: return "reserved block_type"; - case MAD_ERROR_BADSCFSI: return "bad scalefactor selection info"; - case MAD_ERROR_BADDATAPTR: return "bad main_data_begin pointer"; - case MAD_ERROR_BADPART3LEN: return "bad audio data length"; - case MAD_ERROR_BADHUFFTABLE: return "bad Huffman table select"; - case MAD_ERROR_BADHUFFDATA: return "Huffman data overrun"; - case MAD_ERROR_BADSTEREO: return "incompatible block_type for JS"; - } - - return 0; -} diff --git a/lib-src/libmad/stream.h b/lib-src/libmad/stream.h deleted file mode 100644 index 9caebfd41..000000000 --- a/lib-src/libmad/stream.h +++ /dev/null @@ -1,108 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: stream.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_STREAM_H -# define LIBMAD_STREAM_H - -# include "bit.h" - -# define MAD_BUFFER_GUARD 8 -# define MAD_BUFFER_MDLEN (511 + 2048 + MAD_BUFFER_GUARD) - -enum mad_error { - MAD_ERROR_NONE = 0x0000, /* no error */ - - MAD_ERROR_BUFLEN = 0x0001, /* input buffer too small (or EOF) */ - MAD_ERROR_BUFPTR = 0x0002, /* invalid (null) buffer pointer */ - - MAD_ERROR_NOMEM = 0x0031, /* not enough memory */ - - MAD_ERROR_LOSTSYNC = 0x0101, /* lost synchronization */ - MAD_ERROR_BADLAYER = 0x0102, /* reserved header layer value */ - MAD_ERROR_BADBITRATE = 0x0103, /* forbidden bitrate value */ - MAD_ERROR_BADSAMPLERATE = 0x0104, /* reserved sample frequency value */ - MAD_ERROR_BADEMPHASIS = 0x0105, /* reserved emphasis value */ - - MAD_ERROR_BADCRC = 0x0201, /* CRC check failed */ - MAD_ERROR_BADBITALLOC = 0x0211, /* forbidden bit allocation value */ - MAD_ERROR_BADSCALEFACTOR = 0x0221, /* bad scalefactor index */ - MAD_ERROR_BADMODE = 0x0222, /* bad bitrate/mode combination */ - MAD_ERROR_BADFRAMELEN = 0x0231, /* bad frame length */ - MAD_ERROR_BADBIGVALUES = 0x0232, /* bad big_values count */ - MAD_ERROR_BADBLOCKTYPE = 0x0233, /* reserved block_type */ - MAD_ERROR_BADSCFSI = 0x0234, /* bad scalefactor selection info */ - MAD_ERROR_BADDATAPTR = 0x0235, /* bad main_data_begin pointer */ - MAD_ERROR_BADPART3LEN = 0x0236, /* bad audio data length */ - MAD_ERROR_BADHUFFTABLE = 0x0237, /* bad Huffman table select */ - MAD_ERROR_BADHUFFDATA = 0x0238, /* Huffman data overrun */ - MAD_ERROR_BADSTEREO = 0x0239 /* incompatible block_type for JS */ -}; - -# define MAD_RECOVERABLE(error) ((error) & 0xff00) - -struct mad_stream { - unsigned char const *buffer; /* input bitstream buffer */ - unsigned char const *bufend; /* end of buffer */ - unsigned long skiplen; /* bytes to skip before next frame */ - - int sync; /* stream sync found */ - unsigned long freerate; /* free bitrate (fixed) */ - - unsigned char const *this_frame; /* start of current frame */ - unsigned char const *next_frame; /* start of next frame */ - struct mad_bitptr ptr; /* current processing bit pointer */ - - struct mad_bitptr anc_ptr; /* ancillary bits pointer */ - unsigned int anc_bitlen; /* number of ancillary bits */ - - unsigned char (*main_data)[MAD_BUFFER_MDLEN]; - /* Layer III main_data() */ - unsigned int md_len; /* bytes in main_data */ - - int options; /* decoding options (see below) */ - enum mad_error error; /* error code (see above) */ -}; - -enum { - MAD_OPTION_IGNORECRC = 0x0001, /* ignore CRC errors */ - MAD_OPTION_HALFSAMPLERATE = 0x0002 /* generate PCM at 1/2 sample rate */ -# if 0 /* not yet implemented */ - MAD_OPTION_LEFTCHANNEL = 0x0010, /* decode left channel only */ - MAD_OPTION_RIGHTCHANNEL = 0x0020, /* decode right channel only */ - MAD_OPTION_SINGLECHANNEL = 0x0030 /* combine channels */ -# endif -}; - -void mad_stream_init(struct mad_stream *); -void mad_stream_finish(struct mad_stream *); - -# define mad_stream_options(stream, opts) \ - ((void) ((stream)->options = (opts))) - -void mad_stream_buffer(struct mad_stream *, - unsigned char const *, unsigned long); -void mad_stream_skip(struct mad_stream *, unsigned long); - -int mad_stream_sync(struct mad_stream *); - -char const *mad_stream_errorstr(struct mad_stream const *); - -# endif diff --git a/lib-src/libmad/synth.c b/lib-src/libmad/synth.c deleted file mode 100644 index 221de5be7..000000000 --- a/lib-src/libmad/synth.c +++ /dev/null @@ -1,857 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: synth.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "fixed.h" -# include "frame.h" -# include "synth.h" - -/* - * NAME: synth->init() - * DESCRIPTION: initialize synth struct - */ -void mad_synth_init(struct mad_synth *synth) -{ - mad_synth_mute(synth); - - synth->phase = 0; - - synth->pcm.samplerate = 0; - synth->pcm.channels = 0; - synth->pcm.length = 0; -} - -/* - * NAME: synth->mute() - * DESCRIPTION: zero all polyphase filterbank values, resetting synthesis - */ -void mad_synth_mute(struct mad_synth *synth) -{ - unsigned int ch, s, v; - - for (ch = 0; ch < 2; ++ch) { - for (s = 0; s < 16; ++s) { - for (v = 0; v < 8; ++v) { - synth->filter[ch][0][0][s][v] = synth->filter[ch][0][1][s][v] = - synth->filter[ch][1][0][s][v] = synth->filter[ch][1][1][s][v] = 0; - } - } - } -} - -/* - * An optional optimization called here the Subband Synthesis Optimization - * (SSO) improves the performance of subband synthesis at the expense of - * accuracy. - * - * The idea is to simplify 32x32->64-bit multiplication to 32x32->32 such - * that extra scaling and rounding are not necessary. This often allows the - * compiler to use faster 32-bit multiply-accumulate instructions instead of - * explicit 64-bit multiply, shift, and add instructions. - * - * SSO works like this: a full 32x32->64-bit multiply of two mad_fixed_t - * values requires the result to be right-shifted 28 bits to be properly - * scaled to the same fixed-point format. Right shifts can be applied at any - * time to either operand or to the result, so the optimization involves - * careful placement of these shifts to minimize the loss of accuracy. - * - * First, a 14-bit shift is applied with rounding at compile-time to the D[] - * table of coefficients for the subband synthesis window. This only loses 2 - * bits of accuracy because the lower 12 bits are always zero. A second - * 12-bit shift occurs after the DCT calculation. This loses 12 bits of - * accuracy. Finally, a third 2-bit shift occurs just before the sample is - * saved in the PCM buffer. 14 + 12 + 2 == 28 bits. - */ - -/* FPM_DEFAULT without OPT_SSO will actually lose accuracy and performance */ - -# if defined(FPM_DEFAULT) && !defined(OPT_SSO) -# define OPT_SSO -# endif - -/* second SSO shift, with rounding */ - -# if defined(OPT_SSO) -# define SHIFT(x) (((x) + (1L << 11)) >> 12) -# else -# define SHIFT(x) (x) -# endif - -/* possible DCT speed optimization */ - -# if defined(OPT_SPEED) && defined(MAD_F_MLX) -# define OPT_DCTO -# define MUL(x, y) \ - ({ mad_fixed64hi_t hi; \ - mad_fixed64lo_t lo; \ - MAD_F_MLX(hi, lo, (x), (y)); \ - hi << (32 - MAD_F_SCALEBITS - 3); \ - }) -# else -# undef OPT_DCTO -# define MUL(x, y) mad_f_mul((x), (y)) -# endif - -/* - * NAME: dct32() - * DESCRIPTION: perform fast in[32]->out[32] DCT - */ -static -void dct32(mad_fixed_t const in[32], unsigned int slot, - mad_fixed_t lo[16][8], mad_fixed_t hi[16][8]) -{ - mad_fixed_t t0, t1, t2, t3, t4, t5, t6, t7; - mad_fixed_t t8, t9, t10, t11, t12, t13, t14, t15; - mad_fixed_t t16, t17, t18, t19, t20, t21, t22, t23; - mad_fixed_t t24, t25, t26, t27, t28, t29, t30, t31; - mad_fixed_t t32, t33, t34, t35, t36, t37, t38, t39; - mad_fixed_t t40, t41, t42, t43, t44, t45, t46, t47; - mad_fixed_t t48, t49, t50, t51, t52, t53, t54, t55; - mad_fixed_t t56, t57, t58, t59, t60, t61, t62, t63; - mad_fixed_t t64, t65, t66, t67, t68, t69, t70, t71; - mad_fixed_t t72, t73, t74, t75, t76, t77, t78, t79; - mad_fixed_t t80, t81, t82, t83, t84, t85, t86, t87; - mad_fixed_t t88, t89, t90, t91, t92, t93, t94, t95; - mad_fixed_t t96, t97, t98, t99, t100, t101, t102, t103; - mad_fixed_t t104, t105, t106, t107, t108, t109, t110, t111; - mad_fixed_t t112, t113, t114, t115, t116, t117, t118, t119; - mad_fixed_t t120, t121, t122, t123, t124, t125, t126, t127; - mad_fixed_t t128, t129, t130, t131, t132, t133, t134, t135; - mad_fixed_t t136, t137, t138, t139, t140, t141, t142, t143; - mad_fixed_t t144, t145, t146, t147, t148, t149, t150, t151; - mad_fixed_t t152, t153, t154, t155, t156, t157, t158, t159; - mad_fixed_t t160, t161, t162, t163, t164, t165, t166, t167; - mad_fixed_t t168, t169, t170, t171, t172, t173, t174, t175; - mad_fixed_t t176; - - /* costab[i] = cos(PI / (2 * 32) * i) */ - -# if defined(OPT_DCTO) -# define costab1 MAD_F(0x7fd8878e) -# define costab2 MAD_F(0x7f62368f) -# define costab3 MAD_F(0x7e9d55fc) -# define costab4 MAD_F(0x7d8a5f40) -# define costab5 MAD_F(0x7c29fbee) -# define costab6 MAD_F(0x7a7d055b) -# define costab7 MAD_F(0x78848414) -# define costab8 MAD_F(0x7641af3d) -# define costab9 MAD_F(0x73b5ebd1) -# define costab10 MAD_F(0x70e2cbc6) -# define costab11 MAD_F(0x6dca0d14) -# define costab12 MAD_F(0x6a6d98a4) -# define costab13 MAD_F(0x66cf8120) -# define costab14 MAD_F(0x62f201ac) -# define costab15 MAD_F(0x5ed77c8a) -# define costab16 MAD_F(0x5a82799a) -# define costab17 MAD_F(0x55f5a4d2) -# define costab18 MAD_F(0x5133cc94) -# define costab19 MAD_F(0x4c3fdff4) -# define costab20 MAD_F(0x471cece7) -# define costab21 MAD_F(0x41ce1e65) -# define costab22 MAD_F(0x3c56ba70) -# define costab23 MAD_F(0x36ba2014) -# define costab24 MAD_F(0x30fbc54d) -# define costab25 MAD_F(0x2b1f34eb) -# define costab26 MAD_F(0x25280c5e) -# define costab27 MAD_F(0x1f19f97b) -# define costab28 MAD_F(0x18f8b83c) -# define costab29 MAD_F(0x12c8106f) -# define costab30 MAD_F(0x0c8bd35e) -# define costab31 MAD_F(0x0647d97c) -# else -# define costab1 MAD_F(0x0ffb10f2) /* 0.998795456 */ -# define costab2 MAD_F(0x0fec46d2) /* 0.995184727 */ -# define costab3 MAD_F(0x0fd3aac0) /* 0.989176510 */ -# define costab4 MAD_F(0x0fb14be8) /* 0.980785280 */ -# define costab5 MAD_F(0x0f853f7e) /* 0.970031253 */ -# define costab6 MAD_F(0x0f4fa0ab) /* 0.956940336 */ -# define costab7 MAD_F(0x0f109082) /* 0.941544065 */ -# define costab8 MAD_F(0x0ec835e8) /* 0.923879533 */ -# define costab9 MAD_F(0x0e76bd7a) /* 0.903989293 */ -# define costab10 MAD_F(0x0e1c5979) /* 0.881921264 */ -# define costab11 MAD_F(0x0db941a3) /* 0.857728610 */ -# define costab12 MAD_F(0x0d4db315) /* 0.831469612 */ -# define costab13 MAD_F(0x0cd9f024) /* 0.803207531 */ -# define costab14 MAD_F(0x0c5e4036) /* 0.773010453 */ -# define costab15 MAD_F(0x0bdaef91) /* 0.740951125 */ -# define costab16 MAD_F(0x0b504f33) /* 0.707106781 */ -# define costab17 MAD_F(0x0abeb49a) /* 0.671558955 */ -# define costab18 MAD_F(0x0a267993) /* 0.634393284 */ -# define costab19 MAD_F(0x0987fbfe) /* 0.595699304 */ -# define costab20 MAD_F(0x08e39d9d) /* 0.555570233 */ -# define costab21 MAD_F(0x0839c3cd) /* 0.514102744 */ -# define costab22 MAD_F(0x078ad74e) /* 0.471396737 */ -# define costab23 MAD_F(0x06d74402) /* 0.427555093 */ -# define costab24 MAD_F(0x061f78aa) /* 0.382683432 */ -# define costab25 MAD_F(0x0563e69d) /* 0.336889853 */ -# define costab26 MAD_F(0x04a5018c) /* 0.290284677 */ -# define costab27 MAD_F(0x03e33f2f) /* 0.242980180 */ -# define costab28 MAD_F(0x031f1708) /* 0.195090322 */ -# define costab29 MAD_F(0x0259020e) /* 0.146730474 */ -# define costab30 MAD_F(0x01917a6c) /* 0.098017140 */ -# define costab31 MAD_F(0x00c8fb30) /* 0.049067674 */ -# endif - - t0 = in[0] + in[31]; t16 = MUL(in[0] - in[31], costab1); - t1 = in[15] + in[16]; t17 = MUL(in[15] - in[16], costab31); - - t41 = t16 + t17; - t59 = MUL(t16 - t17, costab2); - t33 = t0 + t1; - t50 = MUL(t0 - t1, costab2); - - t2 = in[7] + in[24]; t18 = MUL(in[7] - in[24], costab15); - t3 = in[8] + in[23]; t19 = MUL(in[8] - in[23], costab17); - - t42 = t18 + t19; - t60 = MUL(t18 - t19, costab30); - t34 = t2 + t3; - t51 = MUL(t2 - t3, costab30); - - t4 = in[3] + in[28]; t20 = MUL(in[3] - in[28], costab7); - t5 = in[12] + in[19]; t21 = MUL(in[12] - in[19], costab25); - - t43 = t20 + t21; - t61 = MUL(t20 - t21, costab14); - t35 = t4 + t5; - t52 = MUL(t4 - t5, costab14); - - t6 = in[4] + in[27]; t22 = MUL(in[4] - in[27], costab9); - t7 = in[11] + in[20]; t23 = MUL(in[11] - in[20], costab23); - - t44 = t22 + t23; - t62 = MUL(t22 - t23, costab18); - t36 = t6 + t7; - t53 = MUL(t6 - t7, costab18); - - t8 = in[1] + in[30]; t24 = MUL(in[1] - in[30], costab3); - t9 = in[14] + in[17]; t25 = MUL(in[14] - in[17], costab29); - - t45 = t24 + t25; - t63 = MUL(t24 - t25, costab6); - t37 = t8 + t9; - t54 = MUL(t8 - t9, costab6); - - t10 = in[6] + in[25]; t26 = MUL(in[6] - in[25], costab13); - t11 = in[9] + in[22]; t27 = MUL(in[9] - in[22], costab19); - - t46 = t26 + t27; - t64 = MUL(t26 - t27, costab26); - t38 = t10 + t11; - t55 = MUL(t10 - t11, costab26); - - t12 = in[2] + in[29]; t28 = MUL(in[2] - in[29], costab5); - t13 = in[13] + in[18]; t29 = MUL(in[13] - in[18], costab27); - - t47 = t28 + t29; - t65 = MUL(t28 - t29, costab10); - t39 = t12 + t13; - t56 = MUL(t12 - t13, costab10); - - t14 = in[5] + in[26]; t30 = MUL(in[5] - in[26], costab11); - t15 = in[10] + in[21]; t31 = MUL(in[10] - in[21], costab21); - - t48 = t30 + t31; - t66 = MUL(t30 - t31, costab22); - t40 = t14 + t15; - t57 = MUL(t14 - t15, costab22); - - t69 = t33 + t34; t89 = MUL(t33 - t34, costab4); - t70 = t35 + t36; t90 = MUL(t35 - t36, costab28); - t71 = t37 + t38; t91 = MUL(t37 - t38, costab12); - t72 = t39 + t40; t92 = MUL(t39 - t40, costab20); - t73 = t41 + t42; t94 = MUL(t41 - t42, costab4); - t74 = t43 + t44; t95 = MUL(t43 - t44, costab28); - t75 = t45 + t46; t96 = MUL(t45 - t46, costab12); - t76 = t47 + t48; t97 = MUL(t47 - t48, costab20); - - t78 = t50 + t51; t100 = MUL(t50 - t51, costab4); - t79 = t52 + t53; t101 = MUL(t52 - t53, costab28); - t80 = t54 + t55; t102 = MUL(t54 - t55, costab12); - t81 = t56 + t57; t103 = MUL(t56 - t57, costab20); - - t83 = t59 + t60; t106 = MUL(t59 - t60, costab4); - t84 = t61 + t62; t107 = MUL(t61 - t62, costab28); - t85 = t63 + t64; t108 = MUL(t63 - t64, costab12); - t86 = t65 + t66; t109 = MUL(t65 - t66, costab20); - - t113 = t69 + t70; - t114 = t71 + t72; - - /* 0 */ hi[15][slot] = SHIFT(t113 + t114); - /* 16 */ lo[ 0][slot] = SHIFT(MUL(t113 - t114, costab16)); - - t115 = t73 + t74; - t116 = t75 + t76; - - t32 = t115 + t116; - - /* 1 */ hi[14][slot] = SHIFT(t32); - - t118 = t78 + t79; - t119 = t80 + t81; - - t58 = t118 + t119; - - /* 2 */ hi[13][slot] = SHIFT(t58); - - t121 = t83 + t84; - t122 = t85 + t86; - - t67 = t121 + t122; - - t49 = (t67 * 2) - t32; - - /* 3 */ hi[12][slot] = SHIFT(t49); - - t125 = t89 + t90; - t126 = t91 + t92; - - t93 = t125 + t126; - - /* 4 */ hi[11][slot] = SHIFT(t93); - - t128 = t94 + t95; - t129 = t96 + t97; - - t98 = t128 + t129; - - t68 = (t98 * 2) - t49; - - /* 5 */ hi[10][slot] = SHIFT(t68); - - t132 = t100 + t101; - t133 = t102 + t103; - - t104 = t132 + t133; - - t82 = (t104 * 2) - t58; - - /* 6 */ hi[ 9][slot] = SHIFT(t82); - - t136 = t106 + t107; - t137 = t108 + t109; - - t110 = t136 + t137; - - t87 = (t110 * 2) - t67; - - t77 = (t87 * 2) - t68; - - /* 7 */ hi[ 8][slot] = SHIFT(t77); - - t141 = MUL(t69 - t70, costab8); - t142 = MUL(t71 - t72, costab24); - t143 = t141 + t142; - - /* 8 */ hi[ 7][slot] = SHIFT(t143); - /* 24 */ lo[ 8][slot] = - SHIFT((MUL(t141 - t142, costab16) * 2) - t143); - - t144 = MUL(t73 - t74, costab8); - t145 = MUL(t75 - t76, costab24); - t146 = t144 + t145; - - t88 = (t146 * 2) - t77; - - /* 9 */ hi[ 6][slot] = SHIFT(t88); - - t148 = MUL(t78 - t79, costab8); - t149 = MUL(t80 - t81, costab24); - t150 = t148 + t149; - - t105 = (t150 * 2) - t82; - - /* 10 */ hi[ 5][slot] = SHIFT(t105); - - t152 = MUL(t83 - t84, costab8); - t153 = MUL(t85 - t86, costab24); - t154 = t152 + t153; - - t111 = (t154 * 2) - t87; - - t99 = (t111 * 2) - t88; - - /* 11 */ hi[ 4][slot] = SHIFT(t99); - - t157 = MUL(t89 - t90, costab8); - t158 = MUL(t91 - t92, costab24); - t159 = t157 + t158; - - t127 = (t159 * 2) - t93; - - /* 12 */ hi[ 3][slot] = SHIFT(t127); - - t160 = (MUL(t125 - t126, costab16) * 2) - t127; - - /* 20 */ lo[ 4][slot] = SHIFT(t160); - /* 28 */ lo[12][slot] = - SHIFT((((MUL(t157 - t158, costab16) * 2) - t159) * 2) - t160); - - t161 = MUL(t94 - t95, costab8); - t162 = MUL(t96 - t97, costab24); - t163 = t161 + t162; - - t130 = (t163 * 2) - t98; - - t112 = (t130 * 2) - t99; - - /* 13 */ hi[ 2][slot] = SHIFT(t112); - - t164 = (MUL(t128 - t129, costab16) * 2) - t130; - - t166 = MUL(t100 - t101, costab8); - t167 = MUL(t102 - t103, costab24); - t168 = t166 + t167; - - t134 = (t168 * 2) - t104; - - t120 = (t134 * 2) - t105; - - /* 14 */ hi[ 1][slot] = SHIFT(t120); - - t135 = (MUL(t118 - t119, costab16) * 2) - t120; - - /* 18 */ lo[ 2][slot] = SHIFT(t135); - - t169 = (MUL(t132 - t133, costab16) * 2) - t134; - - t151 = (t169 * 2) - t135; - - /* 22 */ lo[ 6][slot] = SHIFT(t151); - - t170 = (((MUL(t148 - t149, costab16) * 2) - t150) * 2) - t151; - - /* 26 */ lo[10][slot] = SHIFT(t170); - /* 30 */ lo[14][slot] = - SHIFT((((((MUL(t166 - t167, costab16) * 2) - - t168) * 2) - t169) * 2) - t170); - - t171 = MUL(t106 - t107, costab8); - t172 = MUL(t108 - t109, costab24); - t173 = t171 + t172; - - t138 = (t173 * 2) - t110; - - t123 = (t138 * 2) - t111; - - t139 = (MUL(t121 - t122, costab16) * 2) - t123; - - t117 = (t123 * 2) - t112; - - /* 15 */ hi[ 0][slot] = SHIFT(t117); - - t124 = (MUL(t115 - t116, costab16) * 2) - t117; - - /* 17 */ lo[ 1][slot] = SHIFT(t124); - - t131 = (t139 * 2) - t124; - - /* 19 */ lo[ 3][slot] = SHIFT(t131); - - t140 = (t164 * 2) - t131; - - /* 21 */ lo[ 5][slot] = SHIFT(t140); - - t174 = (MUL(t136 - t137, costab16) * 2) - t138; - - t155 = (t174 * 2) - t139; - - t147 = (t155 * 2) - t140; - - /* 23 */ lo[ 7][slot] = SHIFT(t147); - - t156 = (((MUL(t144 - t145, costab16) * 2) - t146) * 2) - t147; - - /* 25 */ lo[ 9][slot] = SHIFT(t156); - - t175 = (((MUL(t152 - t153, costab16) * 2) - t154) * 2) - t155; - - t165 = (t175 * 2) - t156; - - /* 27 */ lo[11][slot] = SHIFT(t165); - - t176 = (((((MUL(t161 - t162, costab16) * 2) - - t163) * 2) - t164) * 2) - t165; - - /* 29 */ lo[13][slot] = SHIFT(t176); - /* 31 */ lo[15][slot] = - SHIFT((((((((MUL(t171 - t172, costab16) * 2) - - t173) * 2) - t174) * 2) - t175) * 2) - t176); - - /* - * Totals: - * 80 multiplies - * 80 additions - * 119 subtractions - * 49 shifts (not counting SSO) - */ -} - -# undef MUL -# undef SHIFT - -/* third SSO shift and/or D[] optimization preshift */ - -# if defined(OPT_SSO) -# if MAD_F_FRACBITS != 28 -# error "MAD_F_FRACBITS must be 28 to use OPT_SSO" -# endif -# define ML0(hi, lo, x, y) ((lo) = (x) * (y)) -# define MLA(hi, lo, x, y) ((lo) += (x) * (y)) -# define MLN(hi, lo) ((lo) = -(lo)) -# define MLZ(hi, lo) ((void) (hi), (mad_fixed_t) (lo)) -# define SHIFT(x) ((x) >> 2) -# define PRESHIFT(x) ((MAD_F(x) + (1L << 13)) >> 14) -# else -# define ML0(hi, lo, x, y) MAD_F_ML0((hi), (lo), (x), (y)) -# define MLA(hi, lo, x, y) MAD_F_MLA((hi), (lo), (x), (y)) -# define MLN(hi, lo) MAD_F_MLN((hi), (lo)) -# define MLZ(hi, lo) MAD_F_MLZ((hi), (lo)) -# define SHIFT(x) (x) -# if defined(MAD_F_SCALEBITS) -# undef MAD_F_SCALEBITS -# define MAD_F_SCALEBITS (MAD_F_FRACBITS - 12) -# define PRESHIFT(x) (MAD_F(x) >> 12) -# else -# define PRESHIFT(x) MAD_F(x) -# endif -# endif - -static -mad_fixed_t const D[17][32] = { -# include "D.dat" -}; - -# if defined(ASO_SYNTH) -void synth_full(struct mad_synth *, struct mad_frame const *, - unsigned int, unsigned int); -# else -/* - * NAME: synth->full() - * DESCRIPTION: perform full frequency PCM synthesis - */ -static -void synth_full(struct mad_synth *synth, struct mad_frame const *frame, - unsigned int nch, unsigned int ns) -{ - unsigned int phase, ch, s, sb, pe, po; - mad_fixed_t *pcm1, *pcm2, (*filter)[2][2][16][8]; - mad_fixed_t const (*sbsample)[36][32]; - register mad_fixed_t (*fe)[8], (*fx)[8], (*fo)[8]; - register mad_fixed_t const (*Dptr)[32], *ptr; - register mad_fixed64hi_t hi; - register mad_fixed64lo_t lo; - - for (ch = 0; ch < nch; ++ch) { - sbsample = &frame->sbsample[ch]; - filter = &synth->filter[ch]; - phase = synth->phase; - pcm1 = synth->pcm.samples[ch]; - - for (s = 0; s < ns; ++s) { - dct32((*sbsample)[s], phase >> 1, - (*filter)[0][phase & 1], (*filter)[1][phase & 1]); - - pe = phase & ~1; - po = ((phase - 1) & 0xf) | 1; - - /* calculate 32 samples */ - - fe = &(*filter)[0][ phase & 1][0]; - fx = &(*filter)[0][~phase & 1][0]; - fo = &(*filter)[1][~phase & 1][0]; - - Dptr = &D[0]; - - ptr = *Dptr + po; - ML0(hi, lo, (*fx)[0], ptr[ 0]); - MLA(hi, lo, (*fx)[1], ptr[14]); - MLA(hi, lo, (*fx)[2], ptr[12]); - MLA(hi, lo, (*fx)[3], ptr[10]); - MLA(hi, lo, (*fx)[4], ptr[ 8]); - MLA(hi, lo, (*fx)[5], ptr[ 6]); - MLA(hi, lo, (*fx)[6], ptr[ 4]); - MLA(hi, lo, (*fx)[7], ptr[ 2]); - MLN(hi, lo); - - ptr = *Dptr + pe; - MLA(hi, lo, (*fe)[0], ptr[ 0]); - MLA(hi, lo, (*fe)[1], ptr[14]); - MLA(hi, lo, (*fe)[2], ptr[12]); - MLA(hi, lo, (*fe)[3], ptr[10]); - MLA(hi, lo, (*fe)[4], ptr[ 8]); - MLA(hi, lo, (*fe)[5], ptr[ 6]); - MLA(hi, lo, (*fe)[6], ptr[ 4]); - MLA(hi, lo, (*fe)[7], ptr[ 2]); - - *pcm1++ = SHIFT(MLZ(hi, lo)); - - pcm2 = pcm1 + 30; - - for (sb = 1; sb < 16; ++sb) { - ++fe; - ++Dptr; - - /* D[32 - sb][i] == -D[sb][31 - i] */ - - ptr = *Dptr + po; - ML0(hi, lo, (*fo)[0], ptr[ 0]); - MLA(hi, lo, (*fo)[1], ptr[14]); - MLA(hi, lo, (*fo)[2], ptr[12]); - MLA(hi, lo, (*fo)[3], ptr[10]); - MLA(hi, lo, (*fo)[4], ptr[ 8]); - MLA(hi, lo, (*fo)[5], ptr[ 6]); - MLA(hi, lo, (*fo)[6], ptr[ 4]); - MLA(hi, lo, (*fo)[7], ptr[ 2]); - MLN(hi, lo); - - ptr = *Dptr + pe; - MLA(hi, lo, (*fe)[7], ptr[ 2]); - MLA(hi, lo, (*fe)[6], ptr[ 4]); - MLA(hi, lo, (*fe)[5], ptr[ 6]); - MLA(hi, lo, (*fe)[4], ptr[ 8]); - MLA(hi, lo, (*fe)[3], ptr[10]); - MLA(hi, lo, (*fe)[2], ptr[12]); - MLA(hi, lo, (*fe)[1], ptr[14]); - MLA(hi, lo, (*fe)[0], ptr[ 0]); - - *pcm1++ = SHIFT(MLZ(hi, lo)); - - ptr = *Dptr - pe; - ML0(hi, lo, (*fe)[0], ptr[31 - 16]); - MLA(hi, lo, (*fe)[1], ptr[31 - 14]); - MLA(hi, lo, (*fe)[2], ptr[31 - 12]); - MLA(hi, lo, (*fe)[3], ptr[31 - 10]); - MLA(hi, lo, (*fe)[4], ptr[31 - 8]); - MLA(hi, lo, (*fe)[5], ptr[31 - 6]); - MLA(hi, lo, (*fe)[6], ptr[31 - 4]); - MLA(hi, lo, (*fe)[7], ptr[31 - 2]); - - ptr = *Dptr - po; - MLA(hi, lo, (*fo)[7], ptr[31 - 2]); - MLA(hi, lo, (*fo)[6], ptr[31 - 4]); - MLA(hi, lo, (*fo)[5], ptr[31 - 6]); - MLA(hi, lo, (*fo)[4], ptr[31 - 8]); - MLA(hi, lo, (*fo)[3], ptr[31 - 10]); - MLA(hi, lo, (*fo)[2], ptr[31 - 12]); - MLA(hi, lo, (*fo)[1], ptr[31 - 14]); - MLA(hi, lo, (*fo)[0], ptr[31 - 16]); - - *pcm2-- = SHIFT(MLZ(hi, lo)); - - ++fo; - } - - ++Dptr; - - ptr = *Dptr + po; - ML0(hi, lo, (*fo)[0], ptr[ 0]); - MLA(hi, lo, (*fo)[1], ptr[14]); - MLA(hi, lo, (*fo)[2], ptr[12]); - MLA(hi, lo, (*fo)[3], ptr[10]); - MLA(hi, lo, (*fo)[4], ptr[ 8]); - MLA(hi, lo, (*fo)[5], ptr[ 6]); - MLA(hi, lo, (*fo)[6], ptr[ 4]); - MLA(hi, lo, (*fo)[7], ptr[ 2]); - - *pcm1 = SHIFT(-MLZ(hi, lo)); - pcm1 += 16; - - phase = (phase + 1) % 16; - } - } -} -# endif - -/* - * NAME: synth->half() - * DESCRIPTION: perform half frequency PCM synthesis - */ -static -void synth_half(struct mad_synth *synth, struct mad_frame const *frame, - unsigned int nch, unsigned int ns) -{ - unsigned int phase, ch, s, sb, pe, po; - mad_fixed_t *pcm1, *pcm2, (*filter)[2][2][16][8]; - mad_fixed_t const (*sbsample)[36][32]; - register mad_fixed_t (*fe)[8], (*fx)[8], (*fo)[8]; - register mad_fixed_t const (*Dptr)[32], *ptr; - register mad_fixed64hi_t hi; - register mad_fixed64lo_t lo; - - for (ch = 0; ch < nch; ++ch) { - sbsample = &frame->sbsample[ch]; - filter = &synth->filter[ch]; - phase = synth->phase; - pcm1 = synth->pcm.samples[ch]; - - for (s = 0; s < ns; ++s) { - dct32((*sbsample)[s], phase >> 1, - (*filter)[0][phase & 1], (*filter)[1][phase & 1]); - - pe = phase & ~1; - po = ((phase - 1) & 0xf) | 1; - - /* calculate 16 samples */ - - fe = &(*filter)[0][ phase & 1][0]; - fx = &(*filter)[0][~phase & 1][0]; - fo = &(*filter)[1][~phase & 1][0]; - - Dptr = &D[0]; - - ptr = *Dptr + po; - ML0(hi, lo, (*fx)[0], ptr[ 0]); - MLA(hi, lo, (*fx)[1], ptr[14]); - MLA(hi, lo, (*fx)[2], ptr[12]); - MLA(hi, lo, (*fx)[3], ptr[10]); - MLA(hi, lo, (*fx)[4], ptr[ 8]); - MLA(hi, lo, (*fx)[5], ptr[ 6]); - MLA(hi, lo, (*fx)[6], ptr[ 4]); - MLA(hi, lo, (*fx)[7], ptr[ 2]); - MLN(hi, lo); - - ptr = *Dptr + pe; - MLA(hi, lo, (*fe)[0], ptr[ 0]); - MLA(hi, lo, (*fe)[1], ptr[14]); - MLA(hi, lo, (*fe)[2], ptr[12]); - MLA(hi, lo, (*fe)[3], ptr[10]); - MLA(hi, lo, (*fe)[4], ptr[ 8]); - MLA(hi, lo, (*fe)[5], ptr[ 6]); - MLA(hi, lo, (*fe)[6], ptr[ 4]); - MLA(hi, lo, (*fe)[7], ptr[ 2]); - - *pcm1++ = SHIFT(MLZ(hi, lo)); - - pcm2 = pcm1 + 14; - - for (sb = 1; sb < 16; ++sb) { - ++fe; - ++Dptr; - - /* D[32 - sb][i] == -D[sb][31 - i] */ - - if (!(sb & 1)) { - ptr = *Dptr + po; - ML0(hi, lo, (*fo)[0], ptr[ 0]); - MLA(hi, lo, (*fo)[1], ptr[14]); - MLA(hi, lo, (*fo)[2], ptr[12]); - MLA(hi, lo, (*fo)[3], ptr[10]); - MLA(hi, lo, (*fo)[4], ptr[ 8]); - MLA(hi, lo, (*fo)[5], ptr[ 6]); - MLA(hi, lo, (*fo)[6], ptr[ 4]); - MLA(hi, lo, (*fo)[7], ptr[ 2]); - MLN(hi, lo); - - ptr = *Dptr + pe; - MLA(hi, lo, (*fe)[7], ptr[ 2]); - MLA(hi, lo, (*fe)[6], ptr[ 4]); - MLA(hi, lo, (*fe)[5], ptr[ 6]); - MLA(hi, lo, (*fe)[4], ptr[ 8]); - MLA(hi, lo, (*fe)[3], ptr[10]); - MLA(hi, lo, (*fe)[2], ptr[12]); - MLA(hi, lo, (*fe)[1], ptr[14]); - MLA(hi, lo, (*fe)[0], ptr[ 0]); - - *pcm1++ = SHIFT(MLZ(hi, lo)); - - ptr = *Dptr - po; - ML0(hi, lo, (*fo)[7], ptr[31 - 2]); - MLA(hi, lo, (*fo)[6], ptr[31 - 4]); - MLA(hi, lo, (*fo)[5], ptr[31 - 6]); - MLA(hi, lo, (*fo)[4], ptr[31 - 8]); - MLA(hi, lo, (*fo)[3], ptr[31 - 10]); - MLA(hi, lo, (*fo)[2], ptr[31 - 12]); - MLA(hi, lo, (*fo)[1], ptr[31 - 14]); - MLA(hi, lo, (*fo)[0], ptr[31 - 16]); - - ptr = *Dptr - pe; - MLA(hi, lo, (*fe)[0], ptr[31 - 16]); - MLA(hi, lo, (*fe)[1], ptr[31 - 14]); - MLA(hi, lo, (*fe)[2], ptr[31 - 12]); - MLA(hi, lo, (*fe)[3], ptr[31 - 10]); - MLA(hi, lo, (*fe)[4], ptr[31 - 8]); - MLA(hi, lo, (*fe)[5], ptr[31 - 6]); - MLA(hi, lo, (*fe)[6], ptr[31 - 4]); - MLA(hi, lo, (*fe)[7], ptr[31 - 2]); - - *pcm2-- = SHIFT(MLZ(hi, lo)); - } - - ++fo; - } - - ++Dptr; - - ptr = *Dptr + po; - ML0(hi, lo, (*fo)[0], ptr[ 0]); - MLA(hi, lo, (*fo)[1], ptr[14]); - MLA(hi, lo, (*fo)[2], ptr[12]); - MLA(hi, lo, (*fo)[3], ptr[10]); - MLA(hi, lo, (*fo)[4], ptr[ 8]); - MLA(hi, lo, (*fo)[5], ptr[ 6]); - MLA(hi, lo, (*fo)[6], ptr[ 4]); - MLA(hi, lo, (*fo)[7], ptr[ 2]); - - *pcm1 = SHIFT(-MLZ(hi, lo)); - pcm1 += 8; - - phase = (phase + 1) % 16; - } - } -} - -/* - * NAME: synth->frame() - * DESCRIPTION: perform PCM synthesis of frame subband samples - */ -void mad_synth_frame(struct mad_synth *synth, struct mad_frame const *frame) -{ - unsigned int nch, ns; - void (*synth_frame)(struct mad_synth *, struct mad_frame const *, - unsigned int, unsigned int); - - nch = MAD_NCHANNELS(&frame->header); - ns = MAD_NSBSAMPLES(&frame->header); - - synth->pcm.samplerate = frame->header.samplerate; - synth->pcm.channels = nch; - synth->pcm.length = 32 * ns; - - synth_frame = synth_full; - - if (frame->options & MAD_OPTION_HALFSAMPLERATE) { - synth->pcm.samplerate /= 2; - synth->pcm.length /= 2; - - synth_frame = synth_half; - } - - synth_frame(synth, frame, nch, ns); - - synth->phase = (synth->phase + ns) % 16; -} diff --git a/lib-src/libmad/synth.h b/lib-src/libmad/synth.h deleted file mode 100644 index 2f17fd7a4..000000000 --- a/lib-src/libmad/synth.h +++ /dev/null @@ -1,69 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: synth.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_SYNTH_H -# define LIBMAD_SYNTH_H - -# include "fixed.h" -# include "frame.h" - -struct mad_pcm { - unsigned int samplerate; /* sampling frequency (Hz) */ - unsigned short channels; /* number of channels */ - unsigned short length; /* number of samples per channel */ - mad_fixed_t samples[2][1152]; /* PCM output samples [ch][sample] */ -}; - -struct mad_synth { - mad_fixed_t filter[2][2][2][16][8]; /* polyphase filterbank outputs */ - /* [ch][eo][peo][s][v] */ - - unsigned int phase; /* current processing phase */ - - struct mad_pcm pcm; /* PCM output */ -}; - -/* single channel PCM selector */ -enum { - MAD_PCM_CHANNEL_SINGLE = 0 -}; - -/* dual channel PCM selector */ -enum { - MAD_PCM_CHANNEL_DUAL_1 = 0, - MAD_PCM_CHANNEL_DUAL_2 = 1 -}; - -/* stereo PCM selector */ -enum { - MAD_PCM_CHANNEL_STEREO_LEFT = 0, - MAD_PCM_CHANNEL_STEREO_RIGHT = 1 -}; - -void mad_synth_init(struct mad_synth *); - -# define mad_synth_finish(synth) /* nothing */ - -void mad_synth_mute(struct mad_synth *); - -void mad_synth_frame(struct mad_synth *, struct mad_frame const *); - -# endif diff --git a/lib-src/libmad/timer.c b/lib-src/libmad/timer.c deleted file mode 100644 index 6f779d747..000000000 --- a/lib-src/libmad/timer.c +++ /dev/null @@ -1,485 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: timer.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include - -# ifdef HAVE_ASSERT_H -# include -# endif - -# include "timer.h" - -mad_timer_t const mad_timer_zero = { 0, 0 }; - -/* - * NAME: timer->compare() - * DESCRIPTION: indicate relative order of two timers - */ -int mad_timer_compare(mad_timer_t timer1, mad_timer_t timer2) -{ - signed long diff; - - diff = timer1.seconds - timer2.seconds; - if (diff < 0) - return -1; - else if (diff > 0) - return +1; - - diff = timer1.fraction - timer2.fraction; - if (diff < 0) - return -1; - else if (diff > 0) - return +1; - - return 0; -} - -/* - * NAME: timer->negate() - * DESCRIPTION: invert the sign of a timer - */ -void mad_timer_negate(mad_timer_t *timer) -{ - timer->seconds = -timer->seconds; - - if (timer->fraction) { - timer->seconds -= 1; - timer->fraction = MAD_TIMER_RESOLUTION - timer->fraction; - } -} - -/* - * NAME: timer->abs() - * DESCRIPTION: return the absolute value of a timer - */ -mad_timer_t mad_timer_abs(mad_timer_t timer) -{ - if (timer.seconds < 0) - mad_timer_negate(&timer); - - return timer; -} - -/* - * NAME: reduce_timer() - * DESCRIPTION: carry timer fraction into seconds - */ -static -void reduce_timer(mad_timer_t *timer) -{ - timer->seconds += timer->fraction / MAD_TIMER_RESOLUTION; - timer->fraction %= MAD_TIMER_RESOLUTION; -} - -/* - * NAME: gcd() - * DESCRIPTION: compute greatest common denominator - */ -static -unsigned long gcd(unsigned long num1, unsigned long num2) -{ - unsigned long tmp; - - while (num2) { - tmp = num2; - num2 = num1 % num2; - num1 = tmp; - } - - return num1; -} - -/* - * NAME: reduce_rational() - * DESCRIPTION: convert rational expression to lowest terms - */ -static -void reduce_rational(unsigned long *numer, unsigned long *denom) -{ - unsigned long factor; - - factor = gcd(*numer, *denom); - - assert(factor != 0); - - *numer /= factor; - *denom /= factor; -} - -/* - * NAME: scale_rational() - * DESCRIPTION: solve numer/denom == ?/scale avoiding overflowing - */ -static -unsigned long scale_rational(unsigned long numer, unsigned long denom, - unsigned long scale) -{ - reduce_rational(&numer, &denom); - reduce_rational(&scale, &denom); - - assert(denom != 0); - - if (denom < scale) - return numer * (scale / denom) + numer * (scale % denom) / denom; - if (denom < numer) - return scale * (numer / denom) + scale * (numer % denom) / denom; - - return numer * scale / denom; -} - -/* - * NAME: timer->set() - * DESCRIPTION: set timer to specific (positive) value - */ -void mad_timer_set(mad_timer_t *timer, unsigned long seconds, - unsigned long numer, unsigned long denom) -{ - timer->seconds = seconds; - if (numer >= denom && denom > 0) { - timer->seconds += numer / denom; - numer %= denom; - } - - switch (denom) { - case 0: - case 1: - timer->fraction = 0; - break; - - case MAD_TIMER_RESOLUTION: - timer->fraction = numer; - break; - - case 1000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 1000); - break; - - case 8000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 8000); - break; - - case 11025: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 11025); - break; - - case 12000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 12000); - break; - - case 16000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 16000); - break; - - case 22050: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 22050); - break; - - case 24000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 24000); - break; - - case 32000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 32000); - break; - - case 44100: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 44100); - break; - - case 48000: - timer->fraction = numer * (MAD_TIMER_RESOLUTION / 48000); - break; - - default: - timer->fraction = scale_rational(numer, denom, MAD_TIMER_RESOLUTION); - break; - } - - if (timer->fraction >= MAD_TIMER_RESOLUTION) - reduce_timer(timer); -} - -/* - * NAME: timer->add() - * DESCRIPTION: add one timer to another - */ -void mad_timer_add(mad_timer_t *timer, mad_timer_t incr) -{ - timer->seconds += incr.seconds; - timer->fraction += incr.fraction; - - if (timer->fraction >= MAD_TIMER_RESOLUTION) - reduce_timer(timer); -} - -/* - * NAME: timer->multiply() - * DESCRIPTION: multiply a timer by a scalar value - */ -void mad_timer_multiply(mad_timer_t *timer, signed long scalar) -{ - mad_timer_t addend; - unsigned long factor; - - factor = scalar; - if (scalar < 0) { - factor = -scalar; - mad_timer_negate(timer); - } - - addend = *timer; - *timer = mad_timer_zero; - - while (factor) { - if (factor & 1) - mad_timer_add(timer, addend); - - mad_timer_add(&addend, addend); - factor >>= 1; - } -} - -/* - * NAME: timer->count() - * DESCRIPTION: return timer value in selected units - */ -signed long mad_timer_count(mad_timer_t timer, enum mad_units units) -{ - switch (units) { - case MAD_UNITS_HOURS: - return timer.seconds / 60 / 60; - - case MAD_UNITS_MINUTES: - return timer.seconds / 60; - - case MAD_UNITS_SECONDS: - return timer.seconds; - - case MAD_UNITS_DECISECONDS: - case MAD_UNITS_CENTISECONDS: - case MAD_UNITS_MILLISECONDS: - - case MAD_UNITS_8000_HZ: - case MAD_UNITS_11025_HZ: - case MAD_UNITS_12000_HZ: - case MAD_UNITS_16000_HZ: - case MAD_UNITS_22050_HZ: - case MAD_UNITS_24000_HZ: - case MAD_UNITS_32000_HZ: - case MAD_UNITS_44100_HZ: - case MAD_UNITS_48000_HZ: - - case MAD_UNITS_24_FPS: - case MAD_UNITS_25_FPS: - case MAD_UNITS_30_FPS: - case MAD_UNITS_48_FPS: - case MAD_UNITS_50_FPS: - case MAD_UNITS_60_FPS: - case MAD_UNITS_75_FPS: - return timer.seconds * (signed long) units + - (signed long) scale_rational(timer.fraction, MAD_TIMER_RESOLUTION, - units); - - case MAD_UNITS_23_976_FPS: - case MAD_UNITS_24_975_FPS: - case MAD_UNITS_29_97_FPS: - case MAD_UNITS_47_952_FPS: - case MAD_UNITS_49_95_FPS: - case MAD_UNITS_59_94_FPS: - return (mad_timer_count(timer, -units) + 1) * 1000 / 1001; - } - - /* unsupported units */ - return 0; -} - -/* - * NAME: timer->fraction() - * DESCRIPTION: return fractional part of timer in arbitrary terms - */ -unsigned long mad_timer_fraction(mad_timer_t timer, unsigned long denom) -{ - timer = mad_timer_abs(timer); - - switch (denom) { - case 0: - return timer.fraction ? - MAD_TIMER_RESOLUTION / timer.fraction : MAD_TIMER_RESOLUTION + 1; - - case MAD_TIMER_RESOLUTION: - return timer.fraction; - - default: - return scale_rational(timer.fraction, MAD_TIMER_RESOLUTION, denom); - } -} - -/* - * NAME: timer->string() - * DESCRIPTION: write a string representation of a timer using a template - */ -void mad_timer_string(mad_timer_t timer, - char *dest, char const *format, enum mad_units units, - enum mad_units fracunits, unsigned long subparts) -{ - unsigned long hours, minutes, seconds, sub; - unsigned int frac; - - timer = mad_timer_abs(timer); - - seconds = timer.seconds; - frac = sub = 0; - - switch (fracunits) { - case MAD_UNITS_HOURS: - case MAD_UNITS_MINUTES: - case MAD_UNITS_SECONDS: - break; - - case MAD_UNITS_DECISECONDS: - case MAD_UNITS_CENTISECONDS: - case MAD_UNITS_MILLISECONDS: - - case MAD_UNITS_8000_HZ: - case MAD_UNITS_11025_HZ: - case MAD_UNITS_12000_HZ: - case MAD_UNITS_16000_HZ: - case MAD_UNITS_22050_HZ: - case MAD_UNITS_24000_HZ: - case MAD_UNITS_32000_HZ: - case MAD_UNITS_44100_HZ: - case MAD_UNITS_48000_HZ: - - case MAD_UNITS_24_FPS: - case MAD_UNITS_25_FPS: - case MAD_UNITS_30_FPS: - case MAD_UNITS_48_FPS: - case MAD_UNITS_50_FPS: - case MAD_UNITS_60_FPS: - case MAD_UNITS_75_FPS: - { - unsigned long denom; - - denom = MAD_TIMER_RESOLUTION / fracunits; - - frac = timer.fraction / denom; - sub = scale_rational(timer.fraction % denom, denom, subparts); - } - break; - - case MAD_UNITS_23_976_FPS: - case MAD_UNITS_24_975_FPS: - case MAD_UNITS_29_97_FPS: - case MAD_UNITS_47_952_FPS: - case MAD_UNITS_49_95_FPS: - case MAD_UNITS_59_94_FPS: - /* drop-frame encoding */ - /* N.B. this is only well-defined for MAD_UNITS_29_97_FPS */ - { - unsigned long frame, cycle, d, m; - - frame = mad_timer_count(timer, fracunits); - - cycle = -fracunits * 60 * 10 - (10 - 1) * 2; - - d = frame / cycle; - m = frame % cycle; - frame += (10 - 1) * 2 * d; - if (m > 2) - frame += 2 * ((m - 2) / (cycle / 10)); - - frac = frame % -fracunits; - seconds = frame / -fracunits; - } - break; - } - - switch (units) { - case MAD_UNITS_HOURS: - minutes = seconds / 60; - hours = minutes / 60; - - sprintf(dest, format, - hours, - (unsigned int) (minutes % 60), - (unsigned int) (seconds % 60), - frac, sub); - break; - - case MAD_UNITS_MINUTES: - minutes = seconds / 60; - - sprintf(dest, format, - minutes, - (unsigned int) (seconds % 60), - frac, sub); - break; - - case MAD_UNITS_SECONDS: - sprintf(dest, format, - seconds, - frac, sub); - break; - - case MAD_UNITS_23_976_FPS: - case MAD_UNITS_24_975_FPS: - case MAD_UNITS_29_97_FPS: - case MAD_UNITS_47_952_FPS: - case MAD_UNITS_49_95_FPS: - case MAD_UNITS_59_94_FPS: - if (fracunits < 0) { - /* not yet implemented */ - sub = 0; - } - - /* fall through */ - - case MAD_UNITS_DECISECONDS: - case MAD_UNITS_CENTISECONDS: - case MAD_UNITS_MILLISECONDS: - - case MAD_UNITS_8000_HZ: - case MAD_UNITS_11025_HZ: - case MAD_UNITS_12000_HZ: - case MAD_UNITS_16000_HZ: - case MAD_UNITS_22050_HZ: - case MAD_UNITS_24000_HZ: - case MAD_UNITS_32000_HZ: - case MAD_UNITS_44100_HZ: - case MAD_UNITS_48000_HZ: - - case MAD_UNITS_24_FPS: - case MAD_UNITS_25_FPS: - case MAD_UNITS_30_FPS: - case MAD_UNITS_48_FPS: - case MAD_UNITS_50_FPS: - case MAD_UNITS_60_FPS: - case MAD_UNITS_75_FPS: - sprintf(dest, format, mad_timer_count(timer, units), sub); - break; - } -} diff --git a/lib-src/libmad/timer.h b/lib-src/libmad/timer.h deleted file mode 100644 index 51afd842d..000000000 --- a/lib-src/libmad/timer.h +++ /dev/null @@ -1,100 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: timer.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_TIMER_H -# define LIBMAD_TIMER_H - -typedef struct { - signed long seconds; /* whole seconds */ - unsigned long fraction; /* 1/MAD_TIMER_RESOLUTION seconds */ -} mad_timer_t; - -extern mad_timer_t const mad_timer_zero; - -# define MAD_TIMER_RESOLUTION 352800000UL - -enum mad_units { - MAD_UNITS_HOURS = -2, - MAD_UNITS_MINUTES = -1, - MAD_UNITS_SECONDS = 0, - - /* metric units */ - - MAD_UNITS_DECISECONDS = 10, - MAD_UNITS_CENTISECONDS = 100, - MAD_UNITS_MILLISECONDS = 1000, - - /* audio sample units */ - - MAD_UNITS_8000_HZ = 8000, - MAD_UNITS_11025_HZ = 11025, - MAD_UNITS_12000_HZ = 12000, - - MAD_UNITS_16000_HZ = 16000, - MAD_UNITS_22050_HZ = 22050, - MAD_UNITS_24000_HZ = 24000, - - MAD_UNITS_32000_HZ = 32000, - MAD_UNITS_44100_HZ = 44100, - MAD_UNITS_48000_HZ = 48000, - - /* video frame/field units */ - - MAD_UNITS_24_FPS = 24, - MAD_UNITS_25_FPS = 25, - MAD_UNITS_30_FPS = 30, - MAD_UNITS_48_FPS = 48, - MAD_UNITS_50_FPS = 50, - MAD_UNITS_60_FPS = 60, - - /* CD audio frames */ - - MAD_UNITS_75_FPS = 75, - - /* video drop-frame units */ - - MAD_UNITS_23_976_FPS = -24, - MAD_UNITS_24_975_FPS = -25, - MAD_UNITS_29_97_FPS = -30, - MAD_UNITS_47_952_FPS = -48, - MAD_UNITS_49_95_FPS = -50, - MAD_UNITS_59_94_FPS = -60 -}; - -# define mad_timer_reset(timer) ((void) (*(timer) = mad_timer_zero)) - -int mad_timer_compare(mad_timer_t, mad_timer_t); - -# define mad_timer_sign(timer) mad_timer_compare((timer), mad_timer_zero) - -void mad_timer_negate(mad_timer_t *); -mad_timer_t mad_timer_abs(mad_timer_t); - -void mad_timer_set(mad_timer_t *, unsigned long, unsigned long, unsigned long); -void mad_timer_add(mad_timer_t *, mad_timer_t); -void mad_timer_multiply(mad_timer_t *, signed long); - -signed long mad_timer_count(mad_timer_t, enum mad_units); -unsigned long mad_timer_fraction(mad_timer_t, unsigned long); -void mad_timer_string(mad_timer_t, char *, char const *, - enum mad_units, enum mad_units, unsigned long); - -# endif diff --git a/lib-src/libmad/version.c b/lib-src/libmad/version.c deleted file mode 100644 index a7344bef3..000000000 --- a/lib-src/libmad/version.c +++ /dev/null @@ -1,91 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: version.c,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifdef HAVE_CONFIG_H -# include "config.h" -# endif - -# include "global.h" - -# include "version.h" - -char const mad_version[] = "MPEG Audio Decoder " MAD_VERSION; -char const mad_copyright[] = "Copyright (C) " MAD_PUBLISHYEAR " " MAD_AUTHOR; -char const mad_author[] = MAD_AUTHOR " <" MAD_EMAIL ">"; - -char const mad_build[] = "" -# if defined(DEBUG) - "DEBUG " -# elif defined(NDEBUG) - "NDEBUG " -# endif - -# if defined(EXPERIMENTAL) - "EXPERIMENTAL " -# endif - -# if defined(FPM_64BIT) - "FPM_64BIT " -# elif defined(FPM_INTEL) - "FPM_INTEL " -# elif defined(FPM_ARM) - "FPM_ARM " -# elif defined(FPM_MIPS) - "FPM_MIPS " -# elif defined(FPM_SPARC) - "FPM_SPARC " -# elif defined(FPM_PPC) - "FPM_PPC " -# elif defined(FPM_DEFAULT) - "FPM_DEFAULT " -# endif - -# if defined(ASO_IMDCT) - "ASO_IMDCT " -# endif -# if defined(ASO_INTERLEAVE1) - "ASO_INTERLEAVE1 " -# endif -# if defined(ASO_INTERLEAVE2) - "ASO_INTERLEAVE2 " -# endif -# if defined(ASO_ZEROCHECK) - "ASO_ZEROCHECK " -# endif - -# if defined(OPT_SPEED) - "OPT_SPEED " -# elif defined(OPT_ACCURACY) - "OPT_ACCURACY " -# endif - -# if defined(OPT_SSO) - "OPT_SSO " -# endif - -# if defined(OPT_DCTO) /* never defined here */ - "OPT_DCTO " -# endif - -# if defined(OPT_STRICT) - "OPT_STRICT " -# endif -; diff --git a/lib-src/libmad/version.h b/lib-src/libmad/version.h deleted file mode 100644 index 27f5e56fc..000000000 --- a/lib-src/libmad/version.h +++ /dev/null @@ -1,47 +0,0 @@ -/* - * libmad - MPEG audio decoder library - * Copyright (C) 2000-2004 Underbit Technologies, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: version.h,v 1.2 2005-09-12 07:01:30 dmazzoni Exp $ - */ - -# ifndef LIBMAD_VERSION_H -# define LIBMAD_VERSION_H - -# define MAD_VERSION_MAJOR 0 -# define MAD_VERSION_MINOR 15 -# define MAD_VERSION_PATCH 1 -# define MAD_VERSION_EXTRA " (beta)" - -# define MAD_VERSION_STRINGIZE(str) #str -# define MAD_VERSION_STRING(num) MAD_VERSION_STRINGIZE(num) - -# define MAD_VERSION MAD_VERSION_STRING(MAD_VERSION_MAJOR) "." \ - MAD_VERSION_STRING(MAD_VERSION_MINOR) "." \ - MAD_VERSION_STRING(MAD_VERSION_PATCH) \ - MAD_VERSION_EXTRA - -# define MAD_PUBLISHYEAR "2000-2004" -# define MAD_AUTHOR "Underbit Technologies, Inc." -# define MAD_EMAIL "info@underbit.com" - -extern char const mad_version[]; -extern char const mad_copyright[]; -extern char const mad_author[]; -extern char const mad_build[]; - -# endif