nutcracker 0.2.4.mac9 → 0.2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +13 -46
- data/Rakefile +20 -15
- data/bin/nutcracker +1 -6
- data/ext/nutcracker/ChangeLog +0 -9
- data/ext/nutcracker/LICENSE +0 -0
- data/ext/nutcracker/Makefile.am +0 -0
- data/ext/nutcracker/Makefile.in +149 -66
- data/ext/nutcracker/NOTICE +0 -0
- data/ext/nutcracker/README.md +11 -13
- data/ext/nutcracker/aclocal.m4 +201 -112
- data/ext/nutcracker/conf/nutcracker.leaf.yml +0 -0
- data/ext/nutcracker/conf/nutcracker.root.yml +0 -0
- data/ext/nutcracker/conf/nutcracker.yml +0 -0
- data/ext/nutcracker/config.h.in +0 -15
- data/ext/nutcracker/config/config.guess +84 -23
- data/ext/nutcracker/config/config.sub +93 -23
- data/ext/nutcracker/config/depcomp +81 -35
- data/ext/nutcracker/config/install-sh +122 -109
- data/ext/nutcracker/config/ltmain.sh +721 -1053
- data/ext/nutcracker/config/missing +29 -20
- data/ext/nutcracker/configure +2311 -2113
- data/ext/nutcracker/configure.ac +3 -35
- data/ext/nutcracker/contrib/Makefile.am +0 -0
- data/ext/nutcracker/contrib/Makefile.in +107 -41
- data/ext/nutcracker/contrib/yaml-0.1.4.tar.gz +0 -0
- data/ext/nutcracker/extconf.rb +5 -3
- data/ext/nutcracker/m4/libtool.m4 +492 -553
- data/ext/nutcracker/m4/ltoptions.m4 +6 -7
- data/ext/nutcracker/m4/ltversion.m4 +5 -5
- data/ext/nutcracker/m4/lt~obsolete.m4 +3 -9
- data/ext/nutcracker/notes/c-styleguide.txt +0 -0
- data/ext/nutcracker/notes/debug.txt +0 -0
- data/ext/nutcracker/notes/memcache.txt +0 -0
- data/ext/nutcracker/notes/recommendation.md +2 -21
- data/ext/nutcracker/notes/redis.md +9 -9
- data/ext/nutcracker/notes/socket.txt +0 -0
- data/ext/nutcracker/scripts/nutcracker.init +0 -0
- data/ext/nutcracker/scripts/nutcracker.spec +0 -0
- data/ext/nutcracker/scripts/redis-check.py +0 -0
- data/ext/nutcracker/scripts/redis-check.sh +0 -9
- data/ext/nutcracker/src/Makefile.am +1 -1
- data/ext/nutcracker/src/Makefile.in +153 -74
- data/ext/nutcracker/src/hashkit/Makefile.am +0 -1
- data/ext/nutcracker/src/hashkit/Makefile.in +64 -39
- data/ext/nutcracker/src/hashkit/nc_crc32.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_fnv.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_hashkit.h +0 -2
- data/ext/nutcracker/src/hashkit/nc_hsieh.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_jenkins.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_ketama.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_md5.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_modula.c +6 -18
- data/ext/nutcracker/src/hashkit/nc_murmur.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_one_at_a_time.c +0 -0
- data/ext/nutcracker/src/hashkit/nc_random.c +0 -0
- data/ext/nutcracker/src/nc.c +0 -0
- data/ext/nutcracker/src/nc_array.c +0 -0
- data/ext/nutcracker/src/nc_array.h +0 -0
- data/ext/nutcracker/src/nc_client.c +0 -0
- data/ext/nutcracker/src/nc_client.h +0 -0
- data/ext/nutcracker/src/nc_conf.c +35 -14
- data/ext/nutcracker/src/nc_conf.h +1 -1
- data/ext/nutcracker/src/nc_connection.c +0 -0
- data/ext/nutcracker/src/nc_connection.h +0 -0
- data/ext/nutcracker/src/nc_core.c +26 -29
- data/ext/nutcracker/src/nc_core.h +5 -13
- data/ext/nutcracker/src/{nc_epoll.c → nc_event.c} +30 -94
- data/ext/nutcracker/src/nc_event.h +13 -33
- data/ext/nutcracker/src/nc_log.c +0 -0
- data/ext/nutcracker/src/nc_log.h +0 -0
- data/ext/nutcracker/src/nc_mbuf.c +0 -0
- data/ext/nutcracker/src/nc_mbuf.h +0 -0
- data/ext/nutcracker/src/nc_message.c +0 -0
- data/ext/nutcracker/src/nc_message.h +0 -2
- data/ext/nutcracker/src/nc_proxy.c +8 -8
- data/ext/nutcracker/src/nc_proxy.h +0 -0
- data/ext/nutcracker/src/nc_queue.h +0 -0
- data/ext/nutcracker/src/nc_rbtree.c +0 -0
- data/ext/nutcracker/src/nc_rbtree.h +0 -0
- data/ext/nutcracker/src/nc_request.c +3 -3
- data/ext/nutcracker/src/nc_response.c +6 -4
- data/ext/nutcracker/src/nc_server.c +12 -14
- data/ext/nutcracker/src/nc_server.h +0 -0
- data/ext/nutcracker/src/nc_signal.c +0 -0
- data/ext/nutcracker/src/nc_signal.h +0 -0
- data/ext/nutcracker/src/nc_stats.c +21 -16
- data/ext/nutcracker/src/nc_stats.h +4 -3
- data/ext/nutcracker/src/nc_string.c +0 -0
- data/ext/nutcracker/src/nc_string.h +0 -0
- data/ext/nutcracker/src/nc_util.c +0 -16
- data/ext/nutcracker/src/nc_util.h +0 -1
- data/ext/nutcracker/src/proto/Makefile.am +0 -0
- data/ext/nutcracker/src/proto/Makefile.in +60 -32
- data/ext/nutcracker/src/proto/nc_memcache.c +0 -0
- data/ext/nutcracker/src/proto/nc_proto.h +0 -0
- data/ext/nutcracker/src/proto/nc_redis.c +4 -17
- data/lib/nutcracker.rb +2 -187
- data/lib/nutcracker/version.rb +1 -1
- metadata +10 -256
- data/ext/nutcracker/Makefile +0 -643
- data/ext/nutcracker/autom4te.cache/output.0 +0 -18664
- data/ext/nutcracker/autom4te.cache/output.1 +0 -18664
- data/ext/nutcracker/autom4te.cache/output.2 +0 -18664
- data/ext/nutcracker/autom4te.cache/requests +0 -494
- data/ext/nutcracker/autom4te.cache/traces.0 +0 -2415
- data/ext/nutcracker/autom4te.cache/traces.1 +0 -945
- data/ext/nutcracker/autom4te.cache/traces.2 +0 -2415
- data/ext/nutcracker/config.h +0 -332
- data/ext/nutcracker/config.log +0 -2684
- data/ext/nutcracker/config.status +0 -2317
- data/ext/nutcracker/contrib/Makefile +0 -494
- data/ext/nutcracker/contrib/yaml-0.1.4/Makefile +0 -736
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.0 +0 -13102
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.1 +0 -13085
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.2 +0 -13085
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/requests +0 -476
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.0 +0 -2339
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.1 +0 -545
- data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.2 +0 -2339
- data/ext/nutcracker/contrib/yaml-0.1.4/config.h +0 -81
- data/ext/nutcracker/contrib/yaml-0.1.4/config.h.in~ +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/config.log +0 -688
- data/ext/nutcracker/contrib/yaml-0.1.4/config.status +0 -2032
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/annotated.html +0 -51
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/bc_s.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/classes.html +0 -41
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/closed.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/doxygen.css +0 -656
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/doxygen.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/files.html +0 -40
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions.html +0 -91
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x62.html +0 -84
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x63.html +0 -87
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x64.html +0 -83
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x65.html +0 -110
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x66.html +0 -79
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x68.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x69.html +0 -92
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6b.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6c.html +0 -88
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6d.html +0 -96
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6e.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6f.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x70.html +0 -100
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x71.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x72.html +0 -87
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x73.html +0 -163
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x74.html +0 -115
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x75.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x76.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x77.html +0 -77
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars.html +0 -91
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x62.html +0 -84
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x63.html +0 -87
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x64.html +0 -83
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x65.html +0 -110
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x66.html +0 -79
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x68.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x69.html +0 -92
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6b.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6c.html +0 -88
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6d.html +0 -96
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6e.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6f.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x70.html +0 -100
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x71.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x72.html +0 -87
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x73.html +0 -163
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x74.html +0 -115
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x75.html +0 -71
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x76.html +0 -80
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x77.html +0 -77
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals.html +0 -667
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_defs.html +0 -81
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_enum.html +0 -78
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_eval.html +0 -373
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_func.html +0 -196
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_type.html +0 -126
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__basic.html +0 -320
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__emitter.html +0 -819
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__events.html +0 -664
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__export.html +0 -60
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__nodes.html +0 -795
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__parser.html +0 -606
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__styles.html +0 -222
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__tokens.html +0 -246
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__version.html +0 -106
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/index.html +0 -31
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/modules.html +0 -42
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/nav_f.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/nav_h.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/open.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__alias__data__s.html +0 -108
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__document__s.html +0 -235
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__emitter__s.html +0 -1300
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__event__s.html +0 -496
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__mark__s.html +0 -108
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__node__pair__s.html +0 -91
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__node__s.html +0 -420
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__parser__s.html +0 -1229
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__simple__key__s.html +0 -97
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__tag__directive__s.html +0 -91
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__token__s.html +0 -413
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__version__directive__s.html +0 -91
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_a.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_b.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_h.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_s.png +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tabs.css +0 -59
- data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/yaml_8h.html +0 -525
- data/ext/nutcracker/contrib/yaml-0.1.4/include/Makefile.am +0 -17
- data/ext/nutcracker/contrib/yaml-0.1.4/include/Makefile.in +0 -470
- data/ext/nutcracker/contrib/yaml-0.1.4/libtool +0 -8890
- data/ext/nutcracker/contrib/yaml-0.1.4/src/Makefile +0 -484
- data/ext/nutcracker/contrib/yaml-0.1.4/src/api.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/api.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/dumper.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/dumper.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/emitter.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/emitter.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/libyaml.la +0 -41
- data/ext/nutcracker/contrib/yaml-0.1.4/src/loader.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/loader.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/parser.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/parser.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/reader.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/reader.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/scanner.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/scanner.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/src/writer.lo +0 -12
- data/ext/nutcracker/contrib/yaml-0.1.4/src/writer.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/stamp-h1 +0 -1
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/Makefile +0 -675
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor-alt +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor-alt.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter-alt +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter-alt.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-dumper +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-dumper.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-emitter +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-emitter.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-loader +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-loader.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-parser +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-parser.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-scanner +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-scanner.o +0 -0
- data/ext/nutcracker/contrib/yaml-0.1.4/yaml-0.1.pc +0 -10
- data/ext/nutcracker/contrib/yaml-0.1.4/yaml-0.1.pc.in +0 -10
- data/ext/nutcracker/libtool +0 -9403
- data/ext/nutcracker/src/Makefile +0 -647
- data/ext/nutcracker/src/hashkit/Makefile +0 -476
- data/ext/nutcracker/src/hashkit/libhashkit.a +0 -0
- data/ext/nutcracker/src/hashkit/nc_crc16.c +0 -66
- data/ext/nutcracker/src/hashkit/nc_crc16.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_crc32.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_fnv.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_hsieh.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_jenkins.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_ketama.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_md5.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_modula.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_murmur.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_one_at_a_time.o +0 -0
- data/ext/nutcracker/src/hashkit/nc_random.o +0 -0
- data/ext/nutcracker/src/nc.o +0 -0
- data/ext/nutcracker/src/nc_array.o +0 -0
- data/ext/nutcracker/src/nc_client.o +0 -0
- data/ext/nutcracker/src/nc_conf.o +0 -0
- data/ext/nutcracker/src/nc_connection.o +0 -0
- data/ext/nutcracker/src/nc_core.o +0 -0
- data/ext/nutcracker/src/nc_epoll.o +0 -0
- data/ext/nutcracker/src/nc_kqueue.c +0 -296
- data/ext/nutcracker/src/nc_kqueue.o +0 -0
- data/ext/nutcracker/src/nc_log.o +0 -0
- data/ext/nutcracker/src/nc_mbuf.o +0 -0
- data/ext/nutcracker/src/nc_message.o +0 -0
- data/ext/nutcracker/src/nc_proxy.o +0 -0
- data/ext/nutcracker/src/nc_rbtree.o +0 -0
- data/ext/nutcracker/src/nc_request.o +0 -0
- data/ext/nutcracker/src/nc_response.o +0 -0
- data/ext/nutcracker/src/nc_server.o +0 -0
- data/ext/nutcracker/src/nc_signal.o +0 -0
- data/ext/nutcracker/src/nc_stats.o +0 -0
- data/ext/nutcracker/src/nc_string.o +0 -0
- data/ext/nutcracker/src/nc_util.o +0 -0
- data/ext/nutcracker/src/nutcracker +0 -0
- data/ext/nutcracker/src/proto/Makefile +0 -454
- data/ext/nutcracker/src/proto/libproto.a +0 -0
- data/ext/nutcracker/src/proto/nc_memcache.o +0 -0
- data/ext/nutcracker/src/proto/nc_redis.o +0 -0
- data/ext/nutcracker/stamp-h1 +0 -1
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
# Generated from ltmain.m4sh.
|
|
2
2
|
|
|
3
|
-
#
|
|
3
|
+
# ltmain.sh (GNU libtool) 2.2.6
|
|
4
4
|
# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
|
5
5
|
|
|
6
|
-
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
|
|
7
|
-
# 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
|
|
6
|
+
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 2008 Free Software Foundation, Inc.
|
|
8
7
|
# This is free software; see the source for copying conditions. There is NO
|
|
9
8
|
# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
10
9
|
|
|
@@ -33,54 +32,50 @@
|
|
|
33
32
|
#
|
|
34
33
|
# Provide generalized library-building support services.
|
|
35
34
|
#
|
|
36
|
-
#
|
|
37
|
-
#
|
|
38
|
-
#
|
|
39
|
-
#
|
|
40
|
-
#
|
|
41
|
-
#
|
|
42
|
-
#
|
|
43
|
-
#
|
|
44
|
-
#
|
|
45
|
-
#
|
|
46
|
-
#
|
|
47
|
-
# --no-verbose don't print the extra informational messages
|
|
48
|
-
# --version print version information
|
|
49
|
-
# -h, --help, --help-all print short, long, or detailed help message
|
|
35
|
+
# --config show all configuration variables
|
|
36
|
+
# --debug enable verbose shell tracing
|
|
37
|
+
# -n, --dry-run display commands without modifying any files
|
|
38
|
+
# --features display basic configuration information and exit
|
|
39
|
+
# --mode=MODE use operation mode MODE
|
|
40
|
+
# --preserve-dup-deps don't remove duplicate dependency libraries
|
|
41
|
+
# --quiet, --silent don't print informational messages
|
|
42
|
+
# --tag=TAG use configuration variables from tag TAG
|
|
43
|
+
# -v, --verbose print informational messages (default)
|
|
44
|
+
# --version print version information
|
|
45
|
+
# -h, --help print short or long help message
|
|
50
46
|
#
|
|
51
47
|
# MODE must be one of the following:
|
|
52
48
|
#
|
|
53
|
-
#
|
|
54
|
-
#
|
|
55
|
-
#
|
|
56
|
-
#
|
|
57
|
-
#
|
|
58
|
-
#
|
|
59
|
-
#
|
|
49
|
+
# clean remove files from the build directory
|
|
50
|
+
# compile compile a source file into a libtool object
|
|
51
|
+
# execute automatically set library path, then run a program
|
|
52
|
+
# finish complete the installation of libtool libraries
|
|
53
|
+
# install install libraries or executables
|
|
54
|
+
# link create a library or an executable
|
|
55
|
+
# uninstall remove libraries from an installed directory
|
|
60
56
|
#
|
|
61
|
-
# MODE-ARGS vary depending on the MODE.
|
|
62
|
-
# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that.
|
|
57
|
+
# MODE-ARGS vary depending on the MODE.
|
|
63
58
|
# Try `$progname --help --mode=MODE' for a more detailed description of MODE.
|
|
64
59
|
#
|
|
65
60
|
# When reporting a bug, please describe a test case to reproduce it and
|
|
66
61
|
# include the following information:
|
|
67
62
|
#
|
|
68
|
-
#
|
|
69
|
-
#
|
|
70
|
-
#
|
|
71
|
-
#
|
|
72
|
-
#
|
|
73
|
-
#
|
|
74
|
-
#
|
|
75
|
-
#
|
|
63
|
+
# host-triplet: $host
|
|
64
|
+
# shell: $SHELL
|
|
65
|
+
# compiler: $LTCC
|
|
66
|
+
# compiler flags: $LTCFLAGS
|
|
67
|
+
# linker: $LD (gnu? $with_gnu_ld)
|
|
68
|
+
# $progname: (GNU libtool) 2.2.6 Debian-2.2.6a-4
|
|
69
|
+
# automake: $automake_version
|
|
70
|
+
# autoconf: $autoconf_version
|
|
76
71
|
#
|
|
77
72
|
# Report bugs to <bug-libtool@gnu.org>.
|
|
78
73
|
|
|
79
|
-
PROGRAM=
|
|
74
|
+
PROGRAM=ltmain.sh
|
|
80
75
|
PACKAGE=libtool
|
|
81
|
-
VERSION=2.2.
|
|
76
|
+
VERSION="2.2.6 Debian-2.2.6a-4"
|
|
82
77
|
TIMESTAMP=""
|
|
83
|
-
package_revision=1.
|
|
78
|
+
package_revision=1.3012
|
|
84
79
|
|
|
85
80
|
# Be Bourne compatible
|
|
86
81
|
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
|
|
@@ -96,15 +91,10 @@ fi
|
|
|
96
91
|
BIN_SH=xpg4; export BIN_SH # for Tru64
|
|
97
92
|
DUALCASE=1; export DUALCASE # for MKS sh
|
|
98
93
|
|
|
99
|
-
# A function that is used when there is no print builtin or printf.
|
|
100
|
-
func_fallback_echo ()
|
|
101
|
-
{
|
|
102
|
-
eval 'cat <<_LTECHO_EOF
|
|
103
|
-
$1
|
|
104
|
-
_LTECHO_EOF'
|
|
105
|
-
}
|
|
106
|
-
|
|
107
94
|
# NLS nuisances: We save the old values to restore during execute mode.
|
|
95
|
+
# Only set LANG and LC_ALL to C if already set.
|
|
96
|
+
# These must not be set unconditionally because not all systems understand
|
|
97
|
+
# e.g. LANG=C (notably SCO).
|
|
108
98
|
lt_user_locale=
|
|
109
99
|
lt_safe_locale=
|
|
110
100
|
for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
|
|
@@ -117,33 +107,24 @@ do
|
|
|
117
107
|
lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
|
|
118
108
|
fi"
|
|
119
109
|
done
|
|
120
|
-
LC_ALL=C
|
|
121
|
-
LANGUAGE=C
|
|
122
|
-
export LANGUAGE LC_ALL
|
|
123
110
|
|
|
124
111
|
$lt_unset CDPATH
|
|
125
112
|
|
|
126
113
|
|
|
127
|
-
# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
|
|
128
|
-
# is ksh but when the shell is invoked as "sh" and the current value of
|
|
129
|
-
# the _XPG environment variable is not equal to 1 (one), the special
|
|
130
|
-
# positional parameter $0, within a function call, is the name of the
|
|
131
|
-
# function.
|
|
132
|
-
progpath="$0"
|
|
133
114
|
|
|
134
115
|
|
|
135
116
|
|
|
136
117
|
: ${CP="cp -f"}
|
|
137
|
-
|
|
138
|
-
: ${EGREP="/
|
|
139
|
-
: ${FGREP="/
|
|
140
|
-
: ${GREP="/
|
|
118
|
+
: ${ECHO="echo"}
|
|
119
|
+
: ${EGREP="/bin/grep -E"}
|
|
120
|
+
: ${FGREP="/bin/grep -F"}
|
|
121
|
+
: ${GREP="/bin/grep"}
|
|
141
122
|
: ${LN_S="ln -s"}
|
|
142
123
|
: ${MAKE="make"}
|
|
143
124
|
: ${MKDIR="mkdir"}
|
|
144
125
|
: ${MV="mv -f"}
|
|
145
126
|
: ${RM="rm -f"}
|
|
146
|
-
: ${SED="/
|
|
127
|
+
: ${SED="/bin/sed"}
|
|
147
128
|
: ${SHELL="${CONFIG_SHELL-/bin/sh}"}
|
|
148
129
|
: ${Xsed="$SED -e 1s/^X//"}
|
|
149
130
|
|
|
@@ -178,168 +159,32 @@ basename="s,^.*/,,"
|
|
|
178
159
|
func_dirname_and_basename ()
|
|
179
160
|
{
|
|
180
161
|
# Extract subdirectory from the argument.
|
|
181
|
-
func_dirname_result=`$ECHO "${1}" | $
|
|
162
|
+
func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
|
|
182
163
|
if test "X$func_dirname_result" = "X${1}"; then
|
|
183
164
|
func_dirname_result="${3}"
|
|
184
165
|
else
|
|
185
166
|
func_dirname_result="$func_dirname_result${2}"
|
|
186
167
|
fi
|
|
187
|
-
func_basename_result=`$ECHO "${1}" | $
|
|
168
|
+
func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
|
|
188
169
|
}
|
|
189
170
|
|
|
190
171
|
# Generated shell functions inserted here.
|
|
191
172
|
|
|
192
|
-
#
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
s,/\.$,/,'
|
|
199
|
-
collapseslashes='s@/\{1,\}@/@g'
|
|
200
|
-
finalslash='s,/*$,/,'
|
|
201
|
-
|
|
202
|
-
# func_normal_abspath PATH
|
|
203
|
-
# Remove doubled-up and trailing slashes, "." path components,
|
|
204
|
-
# and cancel out any ".." path components in PATH after making
|
|
205
|
-
# it an absolute path.
|
|
206
|
-
# value returned in "$func_normal_abspath_result"
|
|
207
|
-
func_normal_abspath ()
|
|
208
|
-
{
|
|
209
|
-
# Start from root dir and reassemble the path.
|
|
210
|
-
func_normal_abspath_result=
|
|
211
|
-
func_normal_abspath_tpath=$1
|
|
212
|
-
func_normal_abspath_altnamespace=
|
|
213
|
-
case $func_normal_abspath_tpath in
|
|
214
|
-
"")
|
|
215
|
-
# Empty path, that just means $cwd.
|
|
216
|
-
func_stripname '' '/' "`pwd`"
|
|
217
|
-
func_normal_abspath_result=$func_stripname_result
|
|
218
|
-
return
|
|
219
|
-
;;
|
|
220
|
-
# The next three entries are used to spot a run of precisely
|
|
221
|
-
# two leading slashes without using negated character classes;
|
|
222
|
-
# we take advantage of case's first-match behaviour.
|
|
223
|
-
///*)
|
|
224
|
-
# Unusual form of absolute path, do nothing.
|
|
225
|
-
;;
|
|
226
|
-
//*)
|
|
227
|
-
# Not necessarily an ordinary path; POSIX reserves leading '//'
|
|
228
|
-
# and for example Cygwin uses it to access remote file shares
|
|
229
|
-
# over CIFS/SMB, so we conserve a leading double slash if found.
|
|
230
|
-
func_normal_abspath_altnamespace=/
|
|
231
|
-
;;
|
|
232
|
-
/*)
|
|
233
|
-
# Absolute path, do nothing.
|
|
234
|
-
;;
|
|
235
|
-
*)
|
|
236
|
-
# Relative path, prepend $cwd.
|
|
237
|
-
func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
|
|
238
|
-
;;
|
|
239
|
-
esac
|
|
240
|
-
# Cancel out all the simple stuff to save iterations. We also want
|
|
241
|
-
# the path to end with a slash for ease of parsing, so make sure
|
|
242
|
-
# there is one (and only one) here.
|
|
243
|
-
func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
|
|
244
|
-
-e "$removedotparts" -e "$collapseslashes" -e "$finalslash"`
|
|
245
|
-
while :; do
|
|
246
|
-
# Processed it all yet?
|
|
247
|
-
if test "$func_normal_abspath_tpath" = / ; then
|
|
248
|
-
# If we ascended to the root using ".." the result may be empty now.
|
|
249
|
-
if test -z "$func_normal_abspath_result" ; then
|
|
250
|
-
func_normal_abspath_result=/
|
|
251
|
-
fi
|
|
252
|
-
break
|
|
253
|
-
fi
|
|
254
|
-
func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
|
|
255
|
-
-e "$pathcar"`
|
|
256
|
-
func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
|
|
257
|
-
-e "$pathcdr"`
|
|
258
|
-
# Figure out what to do with it
|
|
259
|
-
case $func_normal_abspath_tcomponent in
|
|
260
|
-
"")
|
|
261
|
-
# Trailing empty path component, ignore it.
|
|
262
|
-
;;
|
|
263
|
-
..)
|
|
264
|
-
# Parent dir; strip last assembled component from result.
|
|
265
|
-
func_dirname "$func_normal_abspath_result"
|
|
266
|
-
func_normal_abspath_result=$func_dirname_result
|
|
267
|
-
;;
|
|
268
|
-
*)
|
|
269
|
-
# Actual path component, append it.
|
|
270
|
-
func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent
|
|
271
|
-
;;
|
|
272
|
-
esac
|
|
273
|
-
done
|
|
274
|
-
# Restore leading double-slash if one was found on entry.
|
|
275
|
-
func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
# func_relative_path SRCDIR DSTDIR
|
|
279
|
-
# generates a relative path from SRCDIR to DSTDIR, with a trailing
|
|
280
|
-
# slash if non-empty, suitable for immediately appending a filename
|
|
281
|
-
# without needing to append a separator.
|
|
282
|
-
# value returned in "$func_relative_path_result"
|
|
283
|
-
func_relative_path ()
|
|
284
|
-
{
|
|
285
|
-
func_relative_path_result=
|
|
286
|
-
func_normal_abspath "$1"
|
|
287
|
-
func_relative_path_tlibdir=$func_normal_abspath_result
|
|
288
|
-
func_normal_abspath "$2"
|
|
289
|
-
func_relative_path_tbindir=$func_normal_abspath_result
|
|
290
|
-
|
|
291
|
-
# Ascend the tree starting from libdir
|
|
292
|
-
while :; do
|
|
293
|
-
# check if we have found a prefix of bindir
|
|
294
|
-
case $func_relative_path_tbindir in
|
|
295
|
-
$func_relative_path_tlibdir)
|
|
296
|
-
# found an exact match
|
|
297
|
-
func_relative_path_tcancelled=
|
|
298
|
-
break
|
|
299
|
-
;;
|
|
300
|
-
$func_relative_path_tlibdir*)
|
|
301
|
-
# found a matching prefix
|
|
302
|
-
func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
|
|
303
|
-
func_relative_path_tcancelled=$func_stripname_result
|
|
304
|
-
if test -z "$func_relative_path_result"; then
|
|
305
|
-
func_relative_path_result=.
|
|
306
|
-
fi
|
|
307
|
-
break
|
|
308
|
-
;;
|
|
309
|
-
*)
|
|
310
|
-
func_dirname $func_relative_path_tlibdir
|
|
311
|
-
func_relative_path_tlibdir=${func_dirname_result}
|
|
312
|
-
if test "x$func_relative_path_tlibdir" = x ; then
|
|
313
|
-
# Have to descend all the way to the root!
|
|
314
|
-
func_relative_path_result=../$func_relative_path_result
|
|
315
|
-
func_relative_path_tcancelled=$func_relative_path_tbindir
|
|
316
|
-
break
|
|
317
|
-
fi
|
|
318
|
-
func_relative_path_result=../$func_relative_path_result
|
|
319
|
-
;;
|
|
320
|
-
esac
|
|
321
|
-
done
|
|
322
|
-
|
|
323
|
-
# Now calculate path; take care to avoid doubling-up slashes.
|
|
324
|
-
func_stripname '' '/' "$func_relative_path_result"
|
|
325
|
-
func_relative_path_result=$func_stripname_result
|
|
326
|
-
func_stripname '/' '/' "$func_relative_path_tcancelled"
|
|
327
|
-
if test "x$func_stripname_result" != x ; then
|
|
328
|
-
func_relative_path_result=${func_relative_path_result}/${func_stripname_result}
|
|
329
|
-
fi
|
|
330
|
-
|
|
331
|
-
# Normalisation. If bindir is libdir, return empty string,
|
|
332
|
-
# else relative path ending with a slash; either way, target
|
|
333
|
-
# file name can be directly appended.
|
|
334
|
-
if test ! -z "$func_relative_path_result"; then
|
|
335
|
-
func_stripname './' '' "$func_relative_path_result/"
|
|
336
|
-
func_relative_path_result=$func_stripname_result
|
|
337
|
-
fi
|
|
338
|
-
}
|
|
173
|
+
# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
|
|
174
|
+
# is ksh but when the shell is invoked as "sh" and the current value of
|
|
175
|
+
# the _XPG environment variable is not equal to 1 (one), the special
|
|
176
|
+
# positional parameter $0, within a function call, is the name of the
|
|
177
|
+
# function.
|
|
178
|
+
progpath="$0"
|
|
339
179
|
|
|
340
180
|
# The name of this program:
|
|
181
|
+
# In the unlikely event $progname began with a '-', it would play havoc with
|
|
182
|
+
# func_echo (imagine progname=-n), so we prepend ./ in that case:
|
|
341
183
|
func_dirname_and_basename "$progpath"
|
|
342
184
|
progname=$func_basename_result
|
|
185
|
+
case $progname in
|
|
186
|
+
-*) progname=./$progname ;;
|
|
187
|
+
esac
|
|
343
188
|
|
|
344
189
|
# Make sure we have an absolute path for reexecution:
|
|
345
190
|
case $progpath in
|
|
@@ -413,13 +258,6 @@ func_verbose ()
|
|
|
413
258
|
:
|
|
414
259
|
}
|
|
415
260
|
|
|
416
|
-
# func_echo_all arg...
|
|
417
|
-
# Invoke $ECHO with all args, space-separated.
|
|
418
|
-
func_echo_all ()
|
|
419
|
-
{
|
|
420
|
-
$ECHO "$*"
|
|
421
|
-
}
|
|
422
|
-
|
|
423
261
|
# func_error arg...
|
|
424
262
|
# Echo program name prefixed message to standard error.
|
|
425
263
|
func_error ()
|
|
@@ -488,9 +326,9 @@ func_mkdir_p ()
|
|
|
488
326
|
case $my_directory_path in */*) ;; *) break ;; esac
|
|
489
327
|
|
|
490
328
|
# ...otherwise throw away the child directory and loop
|
|
491
|
-
my_directory_path=`$ECHO "$my_directory_path" | $
|
|
329
|
+
my_directory_path=`$ECHO "X$my_directory_path" | $Xsed -e "$dirname"`
|
|
492
330
|
done
|
|
493
|
-
my_dir_list=`$ECHO "$my_dir_list" | $
|
|
331
|
+
my_dir_list=`$ECHO "X$my_dir_list" | $Xsed -e 's,:*$,,'`
|
|
494
332
|
|
|
495
333
|
save_mkdir_p_IFS="$IFS"; IFS=':'
|
|
496
334
|
for my_dir in $my_dir_list; do
|
|
@@ -540,7 +378,7 @@ func_mktempdir ()
|
|
|
540
378
|
func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
|
|
541
379
|
fi
|
|
542
380
|
|
|
543
|
-
$ECHO "$my_tmpdir"
|
|
381
|
+
$ECHO "X$my_tmpdir" | $Xsed
|
|
544
382
|
}
|
|
545
383
|
|
|
546
384
|
|
|
@@ -554,7 +392,7 @@ func_quote_for_eval ()
|
|
|
554
392
|
{
|
|
555
393
|
case $1 in
|
|
556
394
|
*[\\\`\"\$]*)
|
|
557
|
-
func_quote_for_eval_unquoted_result=`$ECHO "$1" | $
|
|
395
|
+
func_quote_for_eval_unquoted_result=`$ECHO "X$1" | $Xsed -e "$sed_quote_subst"` ;;
|
|
558
396
|
*)
|
|
559
397
|
func_quote_for_eval_unquoted_result="$1" ;;
|
|
560
398
|
esac
|
|
@@ -581,7 +419,7 @@ func_quote_for_expand ()
|
|
|
581
419
|
{
|
|
582
420
|
case $1 in
|
|
583
421
|
*[\\\`\"]*)
|
|
584
|
-
my_arg=`$ECHO "$1" | $
|
|
422
|
+
my_arg=`$ECHO "X$1" | $Xsed \
|
|
585
423
|
-e "$double_quote_subst" -e "$sed_double_backslash"` ;;
|
|
586
424
|
*)
|
|
587
425
|
my_arg="$1" ;;
|
|
@@ -651,19 +489,14 @@ func_show_eval_locale ()
|
|
|
651
489
|
}
|
|
652
490
|
|
|
653
491
|
|
|
492
|
+
|
|
493
|
+
|
|
494
|
+
|
|
654
495
|
# func_version
|
|
655
496
|
# Echo version message to standard output and exit.
|
|
656
497
|
func_version ()
|
|
657
498
|
{
|
|
658
|
-
$SED -n '
|
|
659
|
-
:more
|
|
660
|
-
/\./!{
|
|
661
|
-
N
|
|
662
|
-
s/\n# / /
|
|
663
|
-
b more
|
|
664
|
-
}
|
|
665
|
-
:go
|
|
666
|
-
/^# '$PROGRAM' (GNU /,/# warranty; / {
|
|
499
|
+
$SED -n '/^# '$PROGRAM' (GNU /,/# warranty; / {
|
|
667
500
|
s/^# //
|
|
668
501
|
s/^# *$//
|
|
669
502
|
s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
|
|
@@ -676,20 +509,19 @@ func_version ()
|
|
|
676
509
|
# Echo short help message to standard output and exit.
|
|
677
510
|
func_usage ()
|
|
678
511
|
{
|
|
679
|
-
$SED -n '/^# Usage
|
|
512
|
+
$SED -n '/^# Usage:/,/# -h/ {
|
|
680
513
|
s/^# //
|
|
681
514
|
s/^# *$//
|
|
682
515
|
s/\$progname/'$progname'/
|
|
683
516
|
p
|
|
684
517
|
}' < "$progpath"
|
|
685
|
-
|
|
518
|
+
$ECHO
|
|
686
519
|
$ECHO "run \`$progname --help | more' for full usage"
|
|
687
520
|
exit $?
|
|
688
521
|
}
|
|
689
522
|
|
|
690
|
-
# func_help
|
|
691
|
-
# Echo long help message to standard output and exit
|
|
692
|
-
# unless 'noexit' is passed as argument.
|
|
523
|
+
# func_help
|
|
524
|
+
# Echo long help message to standard output and exit.
|
|
693
525
|
func_help ()
|
|
694
526
|
{
|
|
695
527
|
$SED -n '/^# Usage:/,/# Report bugs to/ {
|
|
@@ -706,10 +538,7 @@ func_help ()
|
|
|
706
538
|
s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/
|
|
707
539
|
p
|
|
708
540
|
}' < "$progpath"
|
|
709
|
-
|
|
710
|
-
if test -z "$1"; then
|
|
711
|
-
exit $ret
|
|
712
|
-
fi
|
|
541
|
+
exit $?
|
|
713
542
|
}
|
|
714
543
|
|
|
715
544
|
# func_missing_arg argname
|
|
@@ -717,7 +546,7 @@ func_help ()
|
|
|
717
546
|
# exit_cmd.
|
|
718
547
|
func_missing_arg ()
|
|
719
548
|
{
|
|
720
|
-
func_error "missing argument for $1
|
|
549
|
+
func_error "missing argument for $1"
|
|
721
550
|
exit_cmd=exit
|
|
722
551
|
}
|
|
723
552
|
|
|
@@ -727,6 +556,29 @@ exit_cmd=:
|
|
|
727
556
|
|
|
728
557
|
|
|
729
558
|
|
|
559
|
+
# Check that we have a working $ECHO.
|
|
560
|
+
if test "X$1" = X--no-reexec; then
|
|
561
|
+
# Discard the --no-reexec flag, and continue.
|
|
562
|
+
shift
|
|
563
|
+
elif test "X$1" = X--fallback-echo; then
|
|
564
|
+
# Avoid inline document here, it may be left over
|
|
565
|
+
:
|
|
566
|
+
elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t'; then
|
|
567
|
+
# Yippee, $ECHO works!
|
|
568
|
+
:
|
|
569
|
+
else
|
|
570
|
+
# Restart under the correct shell, and then maybe $ECHO will work.
|
|
571
|
+
exec $SHELL "$progpath" --no-reexec ${1+"$@"}
|
|
572
|
+
fi
|
|
573
|
+
|
|
574
|
+
if test "X$1" = X--fallback-echo; then
|
|
575
|
+
# used as fallback echo
|
|
576
|
+
shift
|
|
577
|
+
cat <<EOF
|
|
578
|
+
$*
|
|
579
|
+
EOF
|
|
580
|
+
exit $EXIT_SUCCESS
|
|
581
|
+
fi
|
|
730
582
|
|
|
731
583
|
magic="%%%MAGIC variable%%%"
|
|
732
584
|
magic_exe="%%%MAGIC EXE variable%%%"
|
|
@@ -784,16 +636,16 @@ func_config ()
|
|
|
784
636
|
# Display the features supported by this script.
|
|
785
637
|
func_features ()
|
|
786
638
|
{
|
|
787
|
-
|
|
639
|
+
$ECHO "host: $host"
|
|
788
640
|
if test "$build_libtool_libs" = yes; then
|
|
789
|
-
|
|
641
|
+
$ECHO "enable shared libraries"
|
|
790
642
|
else
|
|
791
|
-
|
|
643
|
+
$ECHO "disable shared libraries"
|
|
792
644
|
fi
|
|
793
645
|
if test "$build_old_libs" = yes; then
|
|
794
|
-
|
|
646
|
+
$ECHO "enable static libraries"
|
|
795
647
|
else
|
|
796
|
-
|
|
648
|
+
$ECHO "disable static libraries"
|
|
797
649
|
fi
|
|
798
650
|
|
|
799
651
|
exit $?
|
|
@@ -920,21 +772,10 @@ func_enable_tag ()
|
|
|
920
772
|
|
|
921
773
|
--quiet|--silent) preserve_args="$preserve_args $opt"
|
|
922
774
|
opt_silent=:
|
|
923
|
-
opt_verbose=false
|
|
924
|
-
;;
|
|
925
|
-
|
|
926
|
-
--no-quiet|--no-silent)
|
|
927
|
-
preserve_args="$preserve_args $opt"
|
|
928
|
-
opt_silent=false
|
|
929
775
|
;;
|
|
930
776
|
|
|
931
777
|
--verbose| -v) preserve_args="$preserve_args $opt"
|
|
932
778
|
opt_silent=false
|
|
933
|
-
opt_verbose=:
|
|
934
|
-
;;
|
|
935
|
-
|
|
936
|
-
--no-verbose) preserve_args="$preserve_args $opt"
|
|
937
|
-
opt_verbose=false
|
|
938
779
|
;;
|
|
939
780
|
|
|
940
781
|
--tag) test "$#" -eq 0 && func_missing_arg "$opt" && break
|
|
@@ -952,7 +793,6 @@ func_enable_tag ()
|
|
|
952
793
|
|
|
953
794
|
-\?|-h) func_usage ;;
|
|
954
795
|
--help) opt_help=: ;;
|
|
955
|
-
--help-all) opt_help=': help-all' ;;
|
|
956
796
|
--version) func_version ;;
|
|
957
797
|
|
|
958
798
|
-*) func_fatal_help "unrecognized option \`$opt'" ;;
|
|
@@ -1176,13 +1016,10 @@ func_infer_tag ()
|
|
|
1176
1016
|
func_quote_for_eval "$arg"
|
|
1177
1017
|
CC_quoted="$CC_quoted $func_quote_for_eval_result"
|
|
1178
1018
|
done
|
|
1179
|
-
CC_expanded=`func_echo_all $CC`
|
|
1180
|
-
CC_quoted_expanded=`func_echo_all $CC_quoted`
|
|
1181
1019
|
case $@ in
|
|
1182
1020
|
# Blanks in the command may have been stripped by the calling shell,
|
|
1183
1021
|
# but not from the CC environment variable when configure was run.
|
|
1184
|
-
" $CC "* | "$CC "* | " $
|
|
1185
|
-
" $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;;
|
|
1022
|
+
" $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) ;;
|
|
1186
1023
|
# Blanks at the start of $base_compile will cause this to fail
|
|
1187
1024
|
# if we don't check for them as well.
|
|
1188
1025
|
*)
|
|
@@ -1196,11 +1033,8 @@ func_infer_tag ()
|
|
|
1196
1033
|
func_quote_for_eval "$arg"
|
|
1197
1034
|
CC_quoted="$CC_quoted $func_quote_for_eval_result"
|
|
1198
1035
|
done
|
|
1199
|
-
CC_expanded=`func_echo_all $CC`
|
|
1200
|
-
CC_quoted_expanded=`func_echo_all $CC_quoted`
|
|
1201
1036
|
case "$@ " in
|
|
1202
|
-
|
|
1203
|
-
" $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*)
|
|
1037
|
+
" $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*)
|
|
1204
1038
|
# The compiler in the base compile command matches
|
|
1205
1039
|
# the one in the tagged configuration.
|
|
1206
1040
|
# Assume this is the tagged configuration we want.
|
|
@@ -1379,7 +1213,7 @@ func_mode_compile ()
|
|
|
1379
1213
|
*.[cCFSifmso] | \
|
|
1380
1214
|
*.ada | *.adb | *.ads | *.asm | \
|
|
1381
1215
|
*.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \
|
|
1382
|
-
*.[fF][09]? | *.for | *.java | *.obj | *.sx
|
|
1216
|
+
*.[fF][09]? | *.for | *.java | *.obj | *.sx)
|
|
1383
1217
|
func_xform "$libobj"
|
|
1384
1218
|
libobj=$func_xform_result
|
|
1385
1219
|
;;
|
|
@@ -1454,7 +1288,7 @@ func_mode_compile ()
|
|
|
1454
1288
|
# Calculate the filename of the output object if compiler does
|
|
1455
1289
|
# not support -o with -c
|
|
1456
1290
|
if test "$compiler_c_o" = no; then
|
|
1457
|
-
output_obj=`$ECHO "$srcfile" | $
|
|
1291
|
+
output_obj=`$ECHO "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext}
|
|
1458
1292
|
lockfile="$output_obj.lock"
|
|
1459
1293
|
else
|
|
1460
1294
|
output_obj=
|
|
@@ -1611,7 +1445,7 @@ compiler."
|
|
|
1611
1445
|
}
|
|
1612
1446
|
|
|
1613
1447
|
$opt_help || {
|
|
1614
|
-
|
|
1448
|
+
test "$mode" = compile && func_mode_compile ${1+"$@"}
|
|
1615
1449
|
}
|
|
1616
1450
|
|
|
1617
1451
|
func_mode_help ()
|
|
@@ -1648,11 +1482,10 @@ This mode accepts the following additional options:
|
|
|
1648
1482
|
|
|
1649
1483
|
-o OUTPUT-FILE set the output file name to OUTPUT-FILE
|
|
1650
1484
|
-no-suppress do not suppress compiler output for multiple passes
|
|
1651
|
-
-prefer-pic try to
|
|
1652
|
-
-prefer-non-pic try to
|
|
1485
|
+
-prefer-pic try to building PIC objects only
|
|
1486
|
+
-prefer-non-pic try to building non-PIC objects only
|
|
1653
1487
|
-shared do not build a \`.o' file suitable for static linking
|
|
1654
1488
|
-static only build a \`.o' file suitable for static linking
|
|
1655
|
-
-Wc,FLAG pass FLAG directly to the compiler
|
|
1656
1489
|
|
|
1657
1490
|
COMPILE-COMMAND is a command to be used in creating a \`standard' object file
|
|
1658
1491
|
from the given SOURCEFILE.
|
|
@@ -1705,7 +1538,7 @@ either the \`install' or \`cp' program.
|
|
|
1705
1538
|
|
|
1706
1539
|
The following components of INSTALL-COMMAND are treated specially:
|
|
1707
1540
|
|
|
1708
|
-
-inst-prefix
|
|
1541
|
+
-inst-prefix PREFIX-DIR Use PREFIX-DIR as a staging area for installation
|
|
1709
1542
|
|
|
1710
1543
|
The rest of the components are interpreted as arguments to that command (only
|
|
1711
1544
|
BSD-compatible install options are recognized)."
|
|
@@ -1725,8 +1558,6 @@ The following components of LINK-COMMAND are treated specially:
|
|
|
1725
1558
|
|
|
1726
1559
|
-all-static do not do any dynamic linking at all
|
|
1727
1560
|
-avoid-version do not add a version suffix if possible
|
|
1728
|
-
-bindir BINDIR specify path to binaries directory (for systems where
|
|
1729
|
-
libraries must be found in the PATH setting at runtime)
|
|
1730
1561
|
-dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime
|
|
1731
1562
|
-dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols
|
|
1732
1563
|
-export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
|
|
@@ -1755,11 +1586,6 @@ The following components of LINK-COMMAND are treated specially:
|
|
|
1755
1586
|
-version-info CURRENT[:REVISION[:AGE]]
|
|
1756
1587
|
specify library version info [each variable defaults to 0]
|
|
1757
1588
|
-weak LIBNAME declare that the target provides the LIBNAME interface
|
|
1758
|
-
-Wc,FLAG
|
|
1759
|
-
-Xcompiler FLAG pass linker-specific FLAG directly to the compiler
|
|
1760
|
-
-Wl,FLAG
|
|
1761
|
-
-Xlinker FLAG pass linker-specific FLAG directly to the linker
|
|
1762
|
-
-XCClinker FLAG pass link-specific FLAG to the compiler driver (CC)
|
|
1763
1589
|
|
|
1764
1590
|
All other options (arguments beginning with \`-') are ignored.
|
|
1765
1591
|
|
|
@@ -1797,40 +1623,14 @@ Otherwise, only FILE itself is deleted using RM."
|
|
|
1797
1623
|
;;
|
|
1798
1624
|
esac
|
|
1799
1625
|
|
|
1800
|
-
|
|
1626
|
+
$ECHO
|
|
1801
1627
|
$ECHO "Try \`$progname --help' for more information about other modes."
|
|
1628
|
+
|
|
1629
|
+
exit $?
|
|
1802
1630
|
}
|
|
1803
1631
|
|
|
1804
|
-
# Now that we've collected a possible --mode arg, show help if necessary
|
|
1805
|
-
|
|
1806
|
-
if test "$opt_help" = :; then
|
|
1807
|
-
func_mode_help
|
|
1808
|
-
else
|
|
1809
|
-
{
|
|
1810
|
-
func_help noexit
|
|
1811
|
-
for mode in compile link execute install finish uninstall clean; do
|
|
1812
|
-
func_mode_help
|
|
1813
|
-
done
|
|
1814
|
-
} | sed -n '1p; 2,$s/^Usage:/ or: /p'
|
|
1815
|
-
{
|
|
1816
|
-
func_help noexit
|
|
1817
|
-
for mode in compile link execute install finish uninstall clean; do
|
|
1818
|
-
echo
|
|
1819
|
-
func_mode_help
|
|
1820
|
-
done
|
|
1821
|
-
} |
|
|
1822
|
-
sed '1d
|
|
1823
|
-
/^When reporting/,/^Report/{
|
|
1824
|
-
H
|
|
1825
|
-
d
|
|
1826
|
-
}
|
|
1827
|
-
$x
|
|
1828
|
-
/information about other modes/d
|
|
1829
|
-
/more detailed .*MODE/d
|
|
1830
|
-
s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/'
|
|
1831
|
-
fi
|
|
1832
|
-
exit $?
|
|
1833
|
-
fi
|
|
1632
|
+
# Now that we've collected a possible --mode arg, show help if necessary
|
|
1633
|
+
$opt_help && func_mode_help
|
|
1834
1634
|
|
|
1835
1635
|
|
|
1836
1636
|
# func_mode_execute arg...
|
|
@@ -1912,7 +1712,7 @@ func_mode_execute ()
|
|
|
1912
1712
|
for file
|
|
1913
1713
|
do
|
|
1914
1714
|
case $file in
|
|
1915
|
-
-*
|
|
1715
|
+
-*) ;;
|
|
1916
1716
|
*)
|
|
1917
1717
|
# Do a test to see if this is really a libtool program.
|
|
1918
1718
|
if func_ltwrapper_script_p "$file"; then
|
|
@@ -1954,7 +1754,7 @@ func_mode_execute ()
|
|
|
1954
1754
|
# Display what would be done.
|
|
1955
1755
|
if test -n "$shlibpath_var"; then
|
|
1956
1756
|
eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
|
|
1957
|
-
|
|
1757
|
+
$ECHO "export $shlibpath_var"
|
|
1958
1758
|
fi
|
|
1959
1759
|
$ECHO "$cmd$args"
|
|
1960
1760
|
exit $EXIT_SUCCESS
|
|
@@ -1995,23 +1795,23 @@ func_mode_finish ()
|
|
|
1995
1795
|
# Exit here if they wanted silent mode.
|
|
1996
1796
|
$opt_silent && exit $EXIT_SUCCESS
|
|
1997
1797
|
|
|
1998
|
-
|
|
1999
|
-
|
|
1798
|
+
$ECHO "X----------------------------------------------------------------------" | $Xsed
|
|
1799
|
+
$ECHO "Libraries have been installed in:"
|
|
2000
1800
|
for libdir in $libdirs; do
|
|
2001
1801
|
$ECHO " $libdir"
|
|
2002
1802
|
done
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
1803
|
+
$ECHO
|
|
1804
|
+
$ECHO "If you ever happen to want to link against installed libraries"
|
|
1805
|
+
$ECHO "in a given directory, LIBDIR, you must either use libtool, and"
|
|
1806
|
+
$ECHO "specify the full pathname of the library, or use the \`-LLIBDIR'"
|
|
1807
|
+
$ECHO "flag during linking and do at least one of the following:"
|
|
2008
1808
|
if test -n "$shlibpath_var"; then
|
|
2009
|
-
|
|
2010
|
-
|
|
1809
|
+
$ECHO " - add LIBDIR to the \`$shlibpath_var' environment variable"
|
|
1810
|
+
$ECHO " during execution"
|
|
2011
1811
|
fi
|
|
2012
1812
|
if test -n "$runpath_var"; then
|
|
2013
|
-
|
|
2014
|
-
|
|
1813
|
+
$ECHO " - add LIBDIR to the \`$runpath_var' environment variable"
|
|
1814
|
+
$ECHO " during linking"
|
|
2015
1815
|
fi
|
|
2016
1816
|
if test -n "$hardcode_libdir_flag_spec"; then
|
|
2017
1817
|
libdir=LIBDIR
|
|
@@ -2023,21 +1823,21 @@ func_mode_finish ()
|
|
|
2023
1823
|
$ECHO " - have your system administrator run these commands:$admincmds"
|
|
2024
1824
|
fi
|
|
2025
1825
|
if test -f /etc/ld.so.conf; then
|
|
2026
|
-
|
|
1826
|
+
$ECHO " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
|
|
2027
1827
|
fi
|
|
2028
|
-
|
|
1828
|
+
$ECHO
|
|
2029
1829
|
|
|
2030
|
-
|
|
1830
|
+
$ECHO "See any operating system documentation about shared libraries for"
|
|
2031
1831
|
case $host in
|
|
2032
1832
|
solaris2.[6789]|solaris2.1[0-9])
|
|
2033
|
-
|
|
2034
|
-
|
|
1833
|
+
$ECHO "more information, such as the ld(1), crle(1) and ld.so(8) manual"
|
|
1834
|
+
$ECHO "pages."
|
|
2035
1835
|
;;
|
|
2036
1836
|
*)
|
|
2037
|
-
|
|
1837
|
+
$ECHO "more information, such as the ld(1) and ld.so(8) manual pages."
|
|
2038
1838
|
;;
|
|
2039
1839
|
esac
|
|
2040
|
-
|
|
1840
|
+
$ECHO "X----------------------------------------------------------------------" | $Xsed
|
|
2041
1841
|
exit $EXIT_SUCCESS
|
|
2042
1842
|
}
|
|
2043
1843
|
|
|
@@ -2052,7 +1852,7 @@ func_mode_install ()
|
|
|
2052
1852
|
# install_prog (especially on Windows NT).
|
|
2053
1853
|
if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
|
|
2054
1854
|
# Allow the use of GNU shtool's install command.
|
|
2055
|
-
|
|
1855
|
+
$ECHO "X$nonopt" | $GREP shtool >/dev/null; then
|
|
2056
1856
|
# Aesthetically quote it.
|
|
2057
1857
|
func_quote_for_eval "$nonopt"
|
|
2058
1858
|
install_prog="$func_quote_for_eval_result "
|
|
@@ -2067,11 +1867,6 @@ func_mode_install ()
|
|
|
2067
1867
|
# Aesthetically quote it.
|
|
2068
1868
|
func_quote_for_eval "$arg"
|
|
2069
1869
|
install_prog="$install_prog$func_quote_for_eval_result"
|
|
2070
|
-
install_shared_prog=$install_prog
|
|
2071
|
-
case " $install_prog " in
|
|
2072
|
-
*[\\\ /]cp\ *) install_cp=: ;;
|
|
2073
|
-
*) install_cp=false ;;
|
|
2074
|
-
esac
|
|
2075
1870
|
|
|
2076
1871
|
# We need to accept at least all the BSD install flags.
|
|
2077
1872
|
dest=
|
|
@@ -2081,10 +1876,8 @@ func_mode_install ()
|
|
|
2081
1876
|
install_type=
|
|
2082
1877
|
isdir=no
|
|
2083
1878
|
stripme=
|
|
2084
|
-
no_mode=:
|
|
2085
1879
|
for arg
|
|
2086
1880
|
do
|
|
2087
|
-
arg2=
|
|
2088
1881
|
if test -n "$dest"; then
|
|
2089
1882
|
files="$files $dest"
|
|
2090
1883
|
dest=$arg
|
|
@@ -2094,9 +1887,10 @@ func_mode_install ()
|
|
|
2094
1887
|
case $arg in
|
|
2095
1888
|
-d) isdir=yes ;;
|
|
2096
1889
|
-f)
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
1890
|
+
case " $install_prog " in
|
|
1891
|
+
*[\\\ /]cp\ *) ;;
|
|
1892
|
+
*) prev=$arg ;;
|
|
1893
|
+
esac
|
|
2100
1894
|
;;
|
|
2101
1895
|
-g | -m | -o)
|
|
2102
1896
|
prev=$arg
|
|
@@ -2110,10 +1904,6 @@ func_mode_install ()
|
|
|
2110
1904
|
*)
|
|
2111
1905
|
# If the previous option needed an argument, then skip it.
|
|
2112
1906
|
if test -n "$prev"; then
|
|
2113
|
-
if test "x$prev" = x-m && test -n "$install_override_mode"; then
|
|
2114
|
-
arg2=$install_override_mode
|
|
2115
|
-
no_mode=false
|
|
2116
|
-
fi
|
|
2117
1907
|
prev=
|
|
2118
1908
|
else
|
|
2119
1909
|
dest=$arg
|
|
@@ -2125,10 +1915,6 @@ func_mode_install ()
|
|
|
2125
1915
|
# Aesthetically quote the argument.
|
|
2126
1916
|
func_quote_for_eval "$arg"
|
|
2127
1917
|
install_prog="$install_prog $func_quote_for_eval_result"
|
|
2128
|
-
if test -n "$arg2"; then
|
|
2129
|
-
func_quote_for_eval "$arg2"
|
|
2130
|
-
fi
|
|
2131
|
-
install_shared_prog="$install_shared_prog $func_quote_for_eval_result"
|
|
2132
1918
|
done
|
|
2133
1919
|
|
|
2134
1920
|
test -z "$install_prog" && \
|
|
@@ -2137,13 +1923,6 @@ func_mode_install ()
|
|
|
2137
1923
|
test -n "$prev" && \
|
|
2138
1924
|
func_fatal_help "the \`$prev' option requires an argument"
|
|
2139
1925
|
|
|
2140
|
-
if test -n "$install_override_mode" && $no_mode; then
|
|
2141
|
-
if $install_cp; then :; else
|
|
2142
|
-
func_quote_for_eval "$install_override_mode"
|
|
2143
|
-
install_shared_prog="$install_shared_prog -m $func_quote_for_eval_result"
|
|
2144
|
-
fi
|
|
2145
|
-
fi
|
|
2146
|
-
|
|
2147
1926
|
if test -z "$files"; then
|
|
2148
1927
|
if test -z "$dest"; then
|
|
2149
1928
|
func_fatal_help "no file or destination specified"
|
|
@@ -2231,7 +2010,7 @@ func_mode_install ()
|
|
|
2231
2010
|
|
|
2232
2011
|
if test -n "$relink_command"; then
|
|
2233
2012
|
# Determine the prefix the user has applied to our future dir.
|
|
2234
|
-
inst_prefix_dir=`$ECHO "$destdir" | $
|
|
2013
|
+
inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$libdir\$%%"`
|
|
2235
2014
|
|
|
2236
2015
|
# Don't allow the user to place us outside of our expected
|
|
2237
2016
|
# location b/c this prevents finding dependent libraries that
|
|
@@ -2244,9 +2023,9 @@ func_mode_install ()
|
|
|
2244
2023
|
|
|
2245
2024
|
if test -n "$inst_prefix_dir"; then
|
|
2246
2025
|
# Stick the inst_prefix_dir data into the link command.
|
|
2247
|
-
relink_command=`$ECHO "$relink_command" | $
|
|
2026
|
+
relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
|
|
2248
2027
|
else
|
|
2249
|
-
relink_command=`$ECHO "$relink_command" | $
|
|
2028
|
+
relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%%"`
|
|
2250
2029
|
fi
|
|
2251
2030
|
|
|
2252
2031
|
func_warning "relinking \`$file'"
|
|
@@ -2264,7 +2043,7 @@ func_mode_install ()
|
|
|
2264
2043
|
test -n "$relink_command" && srcname="$realname"T
|
|
2265
2044
|
|
|
2266
2045
|
# Install the shared library and build the symlinks.
|
|
2267
|
-
func_show_eval "$
|
|
2046
|
+
func_show_eval "$install_prog $dir/$srcname $destdir/$realname" \
|
|
2268
2047
|
'exit $?'
|
|
2269
2048
|
tstripme="$stripme"
|
|
2270
2049
|
case $host_os in
|
|
@@ -2404,7 +2183,7 @@ func_mode_install ()
|
|
|
2404
2183
|
if test -f "$lib"; then
|
|
2405
2184
|
func_source "$lib"
|
|
2406
2185
|
fi
|
|
2407
|
-
libfile="$libdir/"`$ECHO "$lib" | $
|
|
2186
|
+
libfile="$libdir/"`$ECHO "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test
|
|
2408
2187
|
if test -n "$libdir" && test ! -f "$libfile"; then
|
|
2409
2188
|
func_warning "\`$lib' has not been installed in \`$libdir'"
|
|
2410
2189
|
finalize=no
|
|
@@ -2423,7 +2202,7 @@ func_mode_install ()
|
|
|
2423
2202
|
file="$func_basename_result"
|
|
2424
2203
|
outputname="$tmpdir/$file"
|
|
2425
2204
|
# Replace the output file specification.
|
|
2426
|
-
relink_command=`$ECHO "$relink_command" | $
|
|
2205
|
+
relink_command=`$ECHO "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
|
|
2427
2206
|
|
|
2428
2207
|
$opt_silent || {
|
|
2429
2208
|
func_quote_for_expand "$relink_command"
|
|
@@ -2442,7 +2221,7 @@ func_mode_install ()
|
|
|
2442
2221
|
}
|
|
2443
2222
|
else
|
|
2444
2223
|
# Install the binary that we compiled earlier.
|
|
2445
|
-
file=`$ECHO "$file$stripped_ext" | $
|
|
2224
|
+
file=`$ECHO "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
|
|
2446
2225
|
fi
|
|
2447
2226
|
fi
|
|
2448
2227
|
|
|
@@ -2544,10 +2323,6 @@ func_generate_dlsyms ()
|
|
|
2544
2323
|
extern \"C\" {
|
|
2545
2324
|
#endif
|
|
2546
2325
|
|
|
2547
|
-
#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
|
|
2548
|
-
#pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
|
|
2549
|
-
#endif
|
|
2550
|
-
|
|
2551
2326
|
/* External symbol declarations for the compiler. */\
|
|
2552
2327
|
"
|
|
2553
2328
|
|
|
@@ -2557,7 +2332,7 @@ extern \"C\" {
|
|
|
2557
2332
|
$opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
|
|
2558
2333
|
|
|
2559
2334
|
# Add our own program objects to the symbol list.
|
|
2560
|
-
progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $
|
|
2335
|
+
progfiles=`$ECHO "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
|
|
2561
2336
|
for progfile in $progfiles; do
|
|
2562
2337
|
func_verbose "extracting global C symbols from \`$progfile'"
|
|
2563
2338
|
$opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'"
|
|
@@ -2596,7 +2371,7 @@ extern \"C\" {
|
|
|
2596
2371
|
eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
|
|
2597
2372
|
eval '$MV "$nlist"T "$nlist"'
|
|
2598
2373
|
case $host in
|
|
2599
|
-
*cygwin
|
|
2374
|
+
*cygwin | *mingw* | *cegcc* )
|
|
2600
2375
|
eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
|
|
2601
2376
|
eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
|
|
2602
2377
|
;;
|
|
@@ -2640,10 +2415,10 @@ extern \"C\" {
|
|
|
2640
2415
|
if test -f "$nlist"S; then
|
|
2641
2416
|
eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"'
|
|
2642
2417
|
else
|
|
2643
|
-
|
|
2418
|
+
$ECHO '/* NONE */' >> "$output_objdir/$my_dlsyms"
|
|
2644
2419
|
fi
|
|
2645
2420
|
|
|
2646
|
-
|
|
2421
|
+
$ECHO >> "$output_objdir/$my_dlsyms" "\
|
|
2647
2422
|
|
|
2648
2423
|
/* The mapping between symbol names and symbols. */
|
|
2649
2424
|
typedef struct {
|
|
@@ -2653,7 +2428,7 @@ typedef struct {
|
|
|
2653
2428
|
"
|
|
2654
2429
|
case $host in
|
|
2655
2430
|
*cygwin* | *mingw* | *cegcc* )
|
|
2656
|
-
|
|
2431
|
+
$ECHO >> "$output_objdir/$my_dlsyms" "\
|
|
2657
2432
|
/* DATA imports from DLLs on WIN32 con't be const, because
|
|
2658
2433
|
runtime relocations are performed -- see ld's documentation
|
|
2659
2434
|
on pseudo-relocs. */"
|
|
@@ -2666,7 +2441,7 @@ typedef struct {
|
|
|
2666
2441
|
lt_dlsym_const=const ;;
|
|
2667
2442
|
esac
|
|
2668
2443
|
|
|
2669
|
-
|
|
2444
|
+
$ECHO >> "$output_objdir/$my_dlsyms" "\
|
|
2670
2445
|
extern $lt_dlsym_const lt_dlsymlist
|
|
2671
2446
|
lt_${my_prefix}_LTX_preloaded_symbols[];
|
|
2672
2447
|
$lt_dlsym_const lt_dlsymlist
|
|
@@ -2682,7 +2457,7 @@ lt_${my_prefix}_LTX_preloaded_symbols[] =
|
|
|
2682
2457
|
eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms"
|
|
2683
2458
|
;;
|
|
2684
2459
|
esac
|
|
2685
|
-
|
|
2460
|
+
$ECHO >> "$output_objdir/$my_dlsyms" "\
|
|
2686
2461
|
{0, (void *) 0}
|
|
2687
2462
|
};
|
|
2688
2463
|
|
|
@@ -2740,16 +2515,16 @@ static const void *lt_preloaded_setup() {
|
|
|
2740
2515
|
case $host in
|
|
2741
2516
|
*cygwin* | *mingw* | *cegcc* )
|
|
2742
2517
|
if test -f "$output_objdir/$my_outputname.def"; then
|
|
2743
|
-
compile_command=`$ECHO "$compile_command" | $
|
|
2744
|
-
finalize_command=`$ECHO "$finalize_command" | $
|
|
2518
|
+
compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
|
|
2519
|
+
finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
|
|
2745
2520
|
else
|
|
2746
|
-
compile_command=`$ECHO "$compile_command" | $
|
|
2747
|
-
finalize_command=`$ECHO "$finalize_command" | $
|
|
2521
|
+
compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
|
|
2522
|
+
finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
|
|
2748
2523
|
fi
|
|
2749
2524
|
;;
|
|
2750
2525
|
*)
|
|
2751
|
-
compile_command=`$ECHO "$compile_command" | $
|
|
2752
|
-
finalize_command=`$ECHO "$finalize_command" | $
|
|
2526
|
+
compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
|
|
2527
|
+
finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
|
|
2753
2528
|
;;
|
|
2754
2529
|
esac
|
|
2755
2530
|
;;
|
|
@@ -2763,8 +2538,8 @@ static const void *lt_preloaded_setup() {
|
|
|
2763
2538
|
# really was required.
|
|
2764
2539
|
|
|
2765
2540
|
# Nullify the symbol file.
|
|
2766
|
-
compile_command=`$ECHO "$compile_command" | $
|
|
2767
|
-
finalize_command=`$ECHO "$finalize_command" | $
|
|
2541
|
+
compile_command=`$ECHO "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"`
|
|
2542
|
+
finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"`
|
|
2768
2543
|
fi
|
|
2769
2544
|
}
|
|
2770
2545
|
|
|
@@ -2774,7 +2549,6 @@ static const void *lt_preloaded_setup() {
|
|
|
2774
2549
|
# Need a lot of goo to handle *both* DLLs and import libs
|
|
2775
2550
|
# Has to be a shell function in order to 'eat' the argument
|
|
2776
2551
|
# that is supplied when $file_magic_command is called.
|
|
2777
|
-
# Despite the name, also deal with 64 bit binaries.
|
|
2778
2552
|
func_win32_libid ()
|
|
2779
2553
|
{
|
|
2780
2554
|
$opt_debug
|
|
@@ -2785,9 +2559,8 @@ func_win32_libid ()
|
|
|
2785
2559
|
win32_libid_type="x86 archive import"
|
|
2786
2560
|
;;
|
|
2787
2561
|
*ar\ archive*) # could be an import, or static
|
|
2788
|
-
# Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
|
|
2789
2562
|
if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
|
|
2790
|
-
$EGREP 'file format
|
|
2563
|
+
$EGREP 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then
|
|
2791
2564
|
win32_nmres=`eval $NM -f posix -A $1 |
|
|
2792
2565
|
$SED -n -e '
|
|
2793
2566
|
1,100{
|
|
@@ -2825,18 +2598,7 @@ func_extract_an_archive ()
|
|
|
2825
2598
|
$opt_debug
|
|
2826
2599
|
f_ex_an_ar_dir="$1"; shift
|
|
2827
2600
|
f_ex_an_ar_oldlib="$1"
|
|
2828
|
-
|
|
2829
|
-
lockfile=$f_ex_an_ar_oldlib.lock
|
|
2830
|
-
until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
|
|
2831
|
-
func_echo "Waiting for $lockfile to be removed"
|
|
2832
|
-
sleep 2
|
|
2833
|
-
done
|
|
2834
|
-
fi
|
|
2835
|
-
func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \
|
|
2836
|
-
'stat=$?; rm -f "$lockfile"; exit $stat'
|
|
2837
|
-
if test "$lock_old_archive_extraction" = yes; then
|
|
2838
|
-
$opt_dry_run || rm -f "$lockfile"
|
|
2839
|
-
fi
|
|
2601
|
+
func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" 'exit $?'
|
|
2840
2602
|
if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
|
|
2841
2603
|
:
|
|
2842
2604
|
else
|
|
@@ -2907,7 +2669,7 @@ func_extract_archives ()
|
|
|
2907
2669
|
darwin_file=
|
|
2908
2670
|
darwin_files=
|
|
2909
2671
|
for darwin_file in $darwin_filelist; do
|
|
2910
|
-
darwin_files=`find unfat-$$ -name $darwin_file -print |
|
|
2672
|
+
darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP`
|
|
2911
2673
|
$LIPO -create -output "$darwin_file" $darwin_files
|
|
2912
2674
|
done # $darwin_filelist
|
|
2913
2675
|
$RM -rf unfat-$$
|
|
@@ -2922,30 +2684,25 @@ func_extract_archives ()
|
|
|
2922
2684
|
func_extract_an_archive "$my_xdir" "$my_xabs"
|
|
2923
2685
|
;;
|
|
2924
2686
|
esac
|
|
2925
|
-
my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print |
|
|
2687
|
+
my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP`
|
|
2926
2688
|
done
|
|
2927
2689
|
|
|
2928
2690
|
func_extract_archives_result="$my_oldobjs"
|
|
2929
2691
|
}
|
|
2930
2692
|
|
|
2931
2693
|
|
|
2932
|
-
|
|
2933
|
-
#
|
|
2934
|
-
# Emit a libtool wrapper script on stdout.
|
|
2935
|
-
# Don't directly open a file because we may want to
|
|
2936
|
-
# incorporate the script contents within a cygwin/mingw
|
|
2937
|
-
# wrapper executable. Must ONLY be called from within
|
|
2938
|
-
# func_mode_link because it depends on a number of variables
|
|
2939
|
-
# set therein.
|
|
2694
|
+
|
|
2695
|
+
# func_emit_wrapper_part1 [arg=no]
|
|
2940
2696
|
#
|
|
2941
|
-
#
|
|
2942
|
-
#
|
|
2943
|
-
#
|
|
2944
|
-
|
|
2945
|
-
# behavior.
|
|
2946
|
-
func_emit_wrapper ()
|
|
2697
|
+
# Emit the first part of a libtool wrapper script on stdout.
|
|
2698
|
+
# For more information, see the description associated with
|
|
2699
|
+
# func_emit_wrapper(), below.
|
|
2700
|
+
func_emit_wrapper_part1 ()
|
|
2947
2701
|
{
|
|
2948
|
-
|
|
2702
|
+
func_emit_wrapper_part1_arg1=no
|
|
2703
|
+
if test -n "$1" ; then
|
|
2704
|
+
func_emit_wrapper_part1_arg1=$1
|
|
2705
|
+
fi
|
|
2949
2706
|
|
|
2950
2707
|
$ECHO "\
|
|
2951
2708
|
#! $SHELL
|
|
@@ -2961,6 +2718,7 @@ func_emit_wrapper ()
|
|
|
2961
2718
|
|
|
2962
2719
|
# Sed substitution that helps us do robust quoting. It backslashifies
|
|
2963
2720
|
# metacharacters that are still active within double-quoted strings.
|
|
2721
|
+
Xsed='${SED} -e 1s/^X//'
|
|
2964
2722
|
sed_quote_subst='$sed_quote_subst'
|
|
2965
2723
|
|
|
2966
2724
|
# Be Bourne compatible
|
|
@@ -2991,132 +2749,31 @@ if test \"\$libtool_install_magic\" = \"$magic\"; then
|
|
|
2991
2749
|
else
|
|
2992
2750
|
# When we are sourced in execute mode, \$file and \$ECHO are already set.
|
|
2993
2751
|
if test \"\$libtool_execute_magic\" != \"$magic\"; then
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
|
|
2999
|
-
|
|
3000
|
-
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3005
|
-
}
|
|
3006
|
-
|
|
3007
|
-
fi
|
|
3008
|
-
|
|
3009
|
-
# Very basic option parsing. These options are (a) specific to
|
|
3010
|
-
# the libtool wrapper, (b) are identical between the wrapper
|
|
3011
|
-
# /script/ and the wrapper /executable/ which is used only on
|
|
3012
|
-
# windows platforms, and (c) all begin with the string "--lt-"
|
|
3013
|
-
# (application programs are unlikely to have options which match
|
|
3014
|
-
# this pattern).
|
|
3015
|
-
#
|
|
3016
|
-
# There are only two supported options: --lt-debug and
|
|
3017
|
-
# --lt-dump-script. There is, deliberately, no --lt-help.
|
|
3018
|
-
#
|
|
3019
|
-
# The first argument to this parsing function should be the
|
|
3020
|
-
# script's $0 value, followed by "$@".
|
|
3021
|
-
lt_option_debug=
|
|
3022
|
-
func_parse_lt_options ()
|
|
3023
|
-
{
|
|
3024
|
-
lt_script_arg0=\$0
|
|
3025
|
-
shift
|
|
3026
|
-
for lt_opt
|
|
3027
|
-
do
|
|
3028
|
-
case \"\$lt_opt\" in
|
|
3029
|
-
--lt-debug) lt_option_debug=1 ;;
|
|
3030
|
-
--lt-dump-script)
|
|
3031
|
-
lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\`
|
|
3032
|
-
test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=.
|
|
3033
|
-
lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\`
|
|
3034
|
-
cat \"\$lt_dump_D/\$lt_dump_F\"
|
|
3035
|
-
exit 0
|
|
3036
|
-
;;
|
|
3037
|
-
--lt-*)
|
|
3038
|
-
\$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2
|
|
3039
|
-
exit 1
|
|
3040
|
-
;;
|
|
3041
|
-
esac
|
|
3042
|
-
done
|
|
3043
|
-
|
|
3044
|
-
# Print the debug banner immediately:
|
|
3045
|
-
if test -n \"\$lt_option_debug\"; then
|
|
3046
|
-
echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
|
|
3047
|
-
fi
|
|
3048
|
-
}
|
|
3049
|
-
|
|
3050
|
-
# Used when --lt-debug. Prints its arguments to stdout
|
|
3051
|
-
# (redirection is the responsibility of the caller)
|
|
3052
|
-
func_lt_dump_args ()
|
|
3053
|
-
{
|
|
3054
|
-
lt_dump_args_N=1;
|
|
3055
|
-
for lt_arg
|
|
3056
|
-
do
|
|
3057
|
-
\$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
|
|
3058
|
-
lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
|
|
3059
|
-
done
|
|
3060
|
-
}
|
|
3061
|
-
|
|
3062
|
-
# Core function for launching the target application
|
|
3063
|
-
func_exec_program_core ()
|
|
3064
|
-
{
|
|
3065
|
-
"
|
|
3066
|
-
case $host in
|
|
3067
|
-
# Backslashes separate directories on plain windows
|
|
3068
|
-
*-*-mingw | *-*-os2* | *-cegcc*)
|
|
3069
|
-
$ECHO "\
|
|
3070
|
-
if test -n \"\$lt_option_debug\"; then
|
|
3071
|
-
\$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
|
|
3072
|
-
func_lt_dump_args \${1+\"\$@\"} 1>&2
|
|
3073
|
-
fi
|
|
3074
|
-
exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
|
|
3075
|
-
"
|
|
3076
|
-
;;
|
|
3077
|
-
|
|
3078
|
-
*)
|
|
3079
|
-
$ECHO "\
|
|
3080
|
-
if test -n \"\$lt_option_debug\"; then
|
|
3081
|
-
\$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
|
|
3082
|
-
func_lt_dump_args \${1+\"\$@\"} 1>&2
|
|
3083
|
-
fi
|
|
3084
|
-
exec \"\$progdir/\$program\" \${1+\"\$@\"}
|
|
2752
|
+
ECHO=\"$qecho\"
|
|
2753
|
+
file=\"\$0\"
|
|
2754
|
+
# Make sure echo works.
|
|
2755
|
+
if test \"X\$1\" = X--no-reexec; then
|
|
2756
|
+
# Discard the --no-reexec flag, and continue.
|
|
2757
|
+
shift
|
|
2758
|
+
elif test \"X\`{ \$ECHO '\t'; } 2>/dev/null\`\" = 'X\t'; then
|
|
2759
|
+
# Yippee, \$ECHO works!
|
|
2760
|
+
:
|
|
2761
|
+
else
|
|
2762
|
+
# Restart under the correct shell, and then maybe \$ECHO will work.
|
|
2763
|
+
exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"}
|
|
2764
|
+
fi
|
|
2765
|
+
fi\
|
|
3085
2766
|
"
|
|
3086
|
-
|
|
3087
|
-
esac
|
|
3088
|
-
$ECHO "\
|
|
3089
|
-
\$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
|
|
3090
|
-
exit 1
|
|
3091
|
-
}
|
|
3092
|
-
|
|
3093
|
-
# A function to encapsulate launching the target application
|
|
3094
|
-
# Strips options in the --lt-* namespace from \$@ and
|
|
3095
|
-
# launches target application with the remaining arguments.
|
|
3096
|
-
func_exec_program ()
|
|
3097
|
-
{
|
|
3098
|
-
for lt_wr_arg
|
|
3099
|
-
do
|
|
3100
|
-
case \$lt_wr_arg in
|
|
3101
|
-
--lt-*) ;;
|
|
3102
|
-
*) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
|
|
3103
|
-
esac
|
|
3104
|
-
shift
|
|
3105
|
-
done
|
|
3106
|
-
func_exec_program_core \${1+\"\$@\"}
|
|
3107
|
-
}
|
|
3108
|
-
|
|
3109
|
-
# Parse options
|
|
3110
|
-
func_parse_lt_options \"\$0\" \${1+\"\$@\"}
|
|
2767
|
+
$ECHO "\
|
|
3111
2768
|
|
|
3112
2769
|
# Find the directory that this script lives in.
|
|
3113
|
-
thisdir=\`\$ECHO \"\$file\" |
|
|
2770
|
+
thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\`
|
|
3114
2771
|
test \"x\$thisdir\" = \"x\$file\" && thisdir=.
|
|
3115
2772
|
|
|
3116
2773
|
# Follow symbolic links until we get to the real thisdir.
|
|
3117
|
-
file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\`
|
|
2774
|
+
file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\`
|
|
3118
2775
|
while test -n \"\$file\"; do
|
|
3119
|
-
destdir=\`\$ECHO \"\$file\" |
|
|
2776
|
+
destdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\`
|
|
3120
2777
|
|
|
3121
2778
|
# If there was a directory component, then change thisdir.
|
|
3122
2779
|
if test \"x\$destdir\" != \"x\$file\"; then
|
|
@@ -3126,13 +2783,30 @@ func_exec_program ()
|
|
|
3126
2783
|
esac
|
|
3127
2784
|
fi
|
|
3128
2785
|
|
|
3129
|
-
file=\`\$ECHO \"\$file\" |
|
|
3130
|
-
file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\`
|
|
2786
|
+
file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\`
|
|
2787
|
+
file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\`
|
|
3131
2788
|
done
|
|
2789
|
+
"
|
|
2790
|
+
}
|
|
2791
|
+
# end: func_emit_wrapper_part1
|
|
2792
|
+
|
|
2793
|
+
# func_emit_wrapper_part2 [arg=no]
|
|
2794
|
+
#
|
|
2795
|
+
# Emit the second part of a libtool wrapper script on stdout.
|
|
2796
|
+
# For more information, see the description associated with
|
|
2797
|
+
# func_emit_wrapper(), below.
|
|
2798
|
+
func_emit_wrapper_part2 ()
|
|
2799
|
+
{
|
|
2800
|
+
func_emit_wrapper_part2_arg1=no
|
|
2801
|
+
if test -n "$1" ; then
|
|
2802
|
+
func_emit_wrapper_part2_arg1=$1
|
|
2803
|
+
fi
|
|
2804
|
+
|
|
2805
|
+
$ECHO "\
|
|
3132
2806
|
|
|
3133
2807
|
# Usually 'no', except on cygwin/mingw when embedded into
|
|
3134
2808
|
# the cwrapper.
|
|
3135
|
-
WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$
|
|
2809
|
+
WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_part2_arg1
|
|
3136
2810
|
if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then
|
|
3137
2811
|
# special case for '.'
|
|
3138
2812
|
if test \"\$thisdir\" = \".\"; then
|
|
@@ -3140,7 +2814,7 @@ func_exec_program ()
|
|
|
3140
2814
|
fi
|
|
3141
2815
|
# remove .libs from thisdir
|
|
3142
2816
|
case \"\$thisdir\" in
|
|
3143
|
-
*[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" |
|
|
2817
|
+
*[\\\\/]$objdir ) thisdir=\`\$ECHO \"X\$thisdir\" | \$Xsed -e 's%[\\\\/][^\\\\/]*$%%'\` ;;
|
|
3144
2818
|
$objdir ) thisdir=. ;;
|
|
3145
2819
|
esac
|
|
3146
2820
|
fi
|
|
@@ -3203,7 +2877,7 @@ func_exec_program ()
|
|
|
3203
2877
|
|
|
3204
2878
|
# Some systems cannot cope with colon-terminated $shlibpath_var
|
|
3205
2879
|
# The second colon is a workaround for a bug in BeOS R4 sed
|
|
3206
|
-
$shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" |
|
|
2880
|
+
$shlibpath_var=\`\$ECHO \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\`
|
|
3207
2881
|
|
|
3208
2882
|
export $shlibpath_var
|
|
3209
2883
|
"
|
|
@@ -3220,18 +2894,64 @@ func_exec_program ()
|
|
|
3220
2894
|
$ECHO "\
|
|
3221
2895
|
if test \"\$libtool_execute_magic\" != \"$magic\"; then
|
|
3222
2896
|
# Run the actual program with our arguments.
|
|
3223
|
-
|
|
2897
|
+
"
|
|
2898
|
+
case $host in
|
|
2899
|
+
# Backslashes separate directories on plain windows
|
|
2900
|
+
*-*-mingw | *-*-os2* | *-cegcc*)
|
|
2901
|
+
$ECHO "\
|
|
2902
|
+
exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
|
|
2903
|
+
"
|
|
2904
|
+
;;
|
|
2905
|
+
|
|
2906
|
+
*)
|
|
2907
|
+
$ECHO "\
|
|
2908
|
+
exec \"\$progdir/\$program\" \${1+\"\$@\"}
|
|
2909
|
+
"
|
|
2910
|
+
;;
|
|
2911
|
+
esac
|
|
2912
|
+
$ECHO "\
|
|
2913
|
+
\$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
|
|
2914
|
+
exit 1
|
|
3224
2915
|
fi
|
|
3225
2916
|
else
|
|
3226
2917
|
# The program doesn't exist.
|
|
3227
2918
|
\$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
|
|
3228
2919
|
\$ECHO \"This script is just a wrapper for \$program.\" 1>&2
|
|
3229
|
-
|
|
2920
|
+
$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
|
|
3230
2921
|
exit 1
|
|
3231
2922
|
fi
|
|
3232
2923
|
fi\
|
|
3233
2924
|
"
|
|
3234
2925
|
}
|
|
2926
|
+
# end: func_emit_wrapper_part2
|
|
2927
|
+
|
|
2928
|
+
|
|
2929
|
+
# func_emit_wrapper [arg=no]
|
|
2930
|
+
#
|
|
2931
|
+
# Emit a libtool wrapper script on stdout.
|
|
2932
|
+
# Don't directly open a file because we may want to
|
|
2933
|
+
# incorporate the script contents within a cygwin/mingw
|
|
2934
|
+
# wrapper executable. Must ONLY be called from within
|
|
2935
|
+
# func_mode_link because it depends on a number of variables
|
|
2936
|
+
# set therein.
|
|
2937
|
+
#
|
|
2938
|
+
# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
|
|
2939
|
+
# variable will take. If 'yes', then the emitted script
|
|
2940
|
+
# will assume that the directory in which it is stored is
|
|
2941
|
+
# the $objdir directory. This is a cygwin/mingw-specific
|
|
2942
|
+
# behavior.
|
|
2943
|
+
func_emit_wrapper ()
|
|
2944
|
+
{
|
|
2945
|
+
func_emit_wrapper_arg1=no
|
|
2946
|
+
if test -n "$1" ; then
|
|
2947
|
+
func_emit_wrapper_arg1=$1
|
|
2948
|
+
fi
|
|
2949
|
+
|
|
2950
|
+
# split this up so that func_emit_cwrapperexe_src
|
|
2951
|
+
# can call each part independently.
|
|
2952
|
+
func_emit_wrapper_part1 "${func_emit_wrapper_arg1}"
|
|
2953
|
+
func_emit_wrapper_part2 "${func_emit_wrapper_arg1}"
|
|
2954
|
+
}
|
|
3235
2955
|
|
|
3236
2956
|
|
|
3237
2957
|
# func_to_host_path arg
|
|
@@ -3258,19 +2978,23 @@ fi\
|
|
|
3258
2978
|
func_to_host_path ()
|
|
3259
2979
|
{
|
|
3260
2980
|
func_to_host_path_result="$1"
|
|
3261
|
-
if test -n "$1"; then
|
|
2981
|
+
if test -n "$1" ; then
|
|
3262
2982
|
case $host in
|
|
3263
2983
|
*mingw* )
|
|
3264
2984
|
lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
|
|
3265
2985
|
case $build in
|
|
3266
2986
|
*mingw* ) # actually, msys
|
|
3267
2987
|
# awkward: cmd appends spaces to result
|
|
3268
|
-
|
|
3269
|
-
|
|
2988
|
+
lt_sed_strip_trailing_spaces="s/[ ]*\$//"
|
|
2989
|
+
func_to_host_path_tmp1=`( cmd //c echo "$1" |\
|
|
2990
|
+
$SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
|
|
2991
|
+
func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
|
|
2992
|
+
$SED -e "$lt_sed_naive_backslashify"`
|
|
3270
2993
|
;;
|
|
3271
2994
|
*cygwin* )
|
|
3272
|
-
|
|
3273
|
-
|
|
2995
|
+
func_to_host_path_tmp1=`cygpath -w "$1"`
|
|
2996
|
+
func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
|
|
2997
|
+
$SED -e "$lt_sed_naive_backslashify"`
|
|
3274
2998
|
;;
|
|
3275
2999
|
* )
|
|
3276
3000
|
# Unfortunately, winepath does not exit with a non-zero
|
|
@@ -3282,17 +3006,17 @@ func_to_host_path ()
|
|
|
3282
3006
|
# the odd construction:
|
|
3283
3007
|
func_to_host_path_tmp1=`winepath -w "$1" 2>/dev/null`
|
|
3284
3008
|
if test "$?" -eq 0 && test -n "${func_to_host_path_tmp1}"; then
|
|
3285
|
-
func_to_host_path_result
|
|
3009
|
+
func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
|
|
3286
3010
|
$SED -e "$lt_sed_naive_backslashify"`
|
|
3287
3011
|
else
|
|
3288
3012
|
# Allow warning below.
|
|
3289
|
-
func_to_host_path_result=
|
|
3013
|
+
func_to_host_path_result=""
|
|
3290
3014
|
fi
|
|
3291
3015
|
;;
|
|
3292
3016
|
esac
|
|
3293
3017
|
if test -z "$func_to_host_path_result" ; then
|
|
3294
3018
|
func_error "Could not determine host path corresponding to"
|
|
3295
|
-
func_error "
|
|
3019
|
+
func_error " '$1'"
|
|
3296
3020
|
func_error "Continuing, but uninstalled executables may not work."
|
|
3297
3021
|
# Fallback:
|
|
3298
3022
|
func_to_host_path_result="$1"
|
|
@@ -3325,24 +3049,30 @@ func_to_host_path ()
|
|
|
3325
3049
|
func_to_host_pathlist ()
|
|
3326
3050
|
{
|
|
3327
3051
|
func_to_host_pathlist_result="$1"
|
|
3328
|
-
if test -n "$1"; then
|
|
3052
|
+
if test -n "$1" ; then
|
|
3329
3053
|
case $host in
|
|
3330
3054
|
*mingw* )
|
|
3331
3055
|
lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
|
|
3332
3056
|
# Remove leading and trailing path separator characters from
|
|
3333
3057
|
# ARG. msys behavior is inconsistent here, cygpath turns them
|
|
3334
3058
|
# into '.;' and ';.', and winepath ignores them completely.
|
|
3335
|
-
|
|
3336
|
-
|
|
3059
|
+
func_to_host_pathlist_tmp2="$1"
|
|
3060
|
+
# Once set for this call, this variable should not be
|
|
3061
|
+
# reassigned. It is used in tha fallback case.
|
|
3062
|
+
func_to_host_pathlist_tmp1=`echo "$func_to_host_pathlist_tmp2" |\
|
|
3063
|
+
$SED -e 's|^:*||' -e 's|:*$||'`
|
|
3337
3064
|
case $build in
|
|
3338
3065
|
*mingw* ) # Actually, msys.
|
|
3339
3066
|
# Awkward: cmd appends spaces to result.
|
|
3340
|
-
|
|
3341
|
-
|
|
3342
|
-
|
|
3067
|
+
lt_sed_strip_trailing_spaces="s/[ ]*\$//"
|
|
3068
|
+
func_to_host_pathlist_tmp2=`( cmd //c echo "$func_to_host_pathlist_tmp1" |\
|
|
3069
|
+
$SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
|
|
3070
|
+
func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
|
|
3071
|
+
$SED -e "$lt_sed_naive_backslashify"`
|
|
3343
3072
|
;;
|
|
3344
3073
|
*cygwin* )
|
|
3345
|
-
|
|
3074
|
+
func_to_host_pathlist_tmp2=`cygpath -w -p "$func_to_host_pathlist_tmp1"`
|
|
3075
|
+
func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
|
|
3346
3076
|
$SED -e "$lt_sed_naive_backslashify"`
|
|
3347
3077
|
;;
|
|
3348
3078
|
* )
|
|
@@ -3358,17 +3088,18 @@ func_to_host_pathlist ()
|
|
|
3358
3088
|
if test -z "$func_to_host_pathlist_result" ; then
|
|
3359
3089
|
func_to_host_pathlist_result="$func_to_host_path_result"
|
|
3360
3090
|
else
|
|
3361
|
-
|
|
3091
|
+
func_to_host_pathlist_result="$func_to_host_pathlist_result;$func_to_host_path_result"
|
|
3362
3092
|
fi
|
|
3363
3093
|
fi
|
|
3364
3094
|
fi
|
|
3095
|
+
IFS=:
|
|
3365
3096
|
done
|
|
3366
3097
|
IFS=$func_to_host_pathlist_oldIFS
|
|
3367
3098
|
;;
|
|
3368
3099
|
esac
|
|
3369
|
-
if test -z "$func_to_host_pathlist_result"; then
|
|
3100
|
+
if test -z "$func_to_host_pathlist_result" ; then
|
|
3370
3101
|
func_error "Could not determine the host path(s) corresponding to"
|
|
3371
|
-
func_error "
|
|
3102
|
+
func_error " '$1'"
|
|
3372
3103
|
func_error "Continuing, but uninstalled executables may not work."
|
|
3373
3104
|
# Fallback. This may break if $1 contains DOS-style drive
|
|
3374
3105
|
# specifications. The fix is not to complicate the expression
|
|
@@ -3385,7 +3116,7 @@ func_to_host_pathlist ()
|
|
|
3385
3116
|
;;
|
|
3386
3117
|
esac
|
|
3387
3118
|
case "$1" in
|
|
3388
|
-
*: )
|
|
3119
|
+
*: ) func_to_host_pathlist_result="$func_to_host_pathlist_result;"
|
|
3389
3120
|
;;
|
|
3390
3121
|
esac
|
|
3391
3122
|
;;
|
|
@@ -3410,23 +3141,31 @@ func_emit_cwrapperexe_src ()
|
|
|
3410
3141
|
|
|
3411
3142
|
This wrapper executable should never be moved out of the build directory.
|
|
3412
3143
|
If it is, it will not operate correctly.
|
|
3144
|
+
|
|
3145
|
+
Currently, it simply execs the wrapper *script* "$SHELL $output",
|
|
3146
|
+
but could eventually absorb all of the scripts functionality and
|
|
3147
|
+
exec $objdir/$outputname directly.
|
|
3413
3148
|
*/
|
|
3414
3149
|
EOF
|
|
3415
3150
|
cat <<"EOF"
|
|
3416
|
-
#ifdef _MSC_VER
|
|
3417
|
-
# define _CRT_SECURE_NO_DEPRECATE 1
|
|
3418
|
-
#endif
|
|
3419
3151
|
#include <stdio.h>
|
|
3420
3152
|
#include <stdlib.h>
|
|
3421
3153
|
#ifdef _MSC_VER
|
|
3422
3154
|
# include <direct.h>
|
|
3423
3155
|
# include <process.h>
|
|
3424
3156
|
# include <io.h>
|
|
3157
|
+
# define setmode _setmode
|
|
3425
3158
|
#else
|
|
3426
3159
|
# include <unistd.h>
|
|
3427
3160
|
# include <stdint.h>
|
|
3428
3161
|
# ifdef __CYGWIN__
|
|
3429
3162
|
# include <io.h>
|
|
3163
|
+
# define HAVE_SETENV
|
|
3164
|
+
# ifdef __STRICT_ANSI__
|
|
3165
|
+
char *realpath (const char *, char *);
|
|
3166
|
+
int putenv (char *);
|
|
3167
|
+
int setenv (const char *, const char *, int);
|
|
3168
|
+
# endif
|
|
3430
3169
|
# endif
|
|
3431
3170
|
#endif
|
|
3432
3171
|
#include <malloc.h>
|
|
@@ -3438,44 +3177,6 @@ EOF
|
|
|
3438
3177
|
#include <fcntl.h>
|
|
3439
3178
|
#include <sys/stat.h>
|
|
3440
3179
|
|
|
3441
|
-
/* declarations of non-ANSI functions */
|
|
3442
|
-
#if defined(__MINGW32__)
|
|
3443
|
-
# ifdef __STRICT_ANSI__
|
|
3444
|
-
int _putenv (const char *);
|
|
3445
|
-
# endif
|
|
3446
|
-
#elif defined(__CYGWIN__)
|
|
3447
|
-
# ifdef __STRICT_ANSI__
|
|
3448
|
-
char *realpath (const char *, char *);
|
|
3449
|
-
int putenv (char *);
|
|
3450
|
-
int setenv (const char *, const char *, int);
|
|
3451
|
-
# endif
|
|
3452
|
-
/* #elif defined (other platforms) ... */
|
|
3453
|
-
#endif
|
|
3454
|
-
|
|
3455
|
-
/* portability defines, excluding path handling macros */
|
|
3456
|
-
#if defined(_MSC_VER)
|
|
3457
|
-
# define setmode _setmode
|
|
3458
|
-
# define stat _stat
|
|
3459
|
-
# define chmod _chmod
|
|
3460
|
-
# define getcwd _getcwd
|
|
3461
|
-
# define putenv _putenv
|
|
3462
|
-
# define S_IXUSR _S_IEXEC
|
|
3463
|
-
# ifndef _INTPTR_T_DEFINED
|
|
3464
|
-
# define _INTPTR_T_DEFINED
|
|
3465
|
-
# define intptr_t int
|
|
3466
|
-
# endif
|
|
3467
|
-
#elif defined(__MINGW32__)
|
|
3468
|
-
# define setmode _setmode
|
|
3469
|
-
# define stat _stat
|
|
3470
|
-
# define chmod _chmod
|
|
3471
|
-
# define getcwd _getcwd
|
|
3472
|
-
# define putenv _putenv
|
|
3473
|
-
#elif defined(__CYGWIN__)
|
|
3474
|
-
# define HAVE_SETENV
|
|
3475
|
-
# define FOPEN_WB "wb"
|
|
3476
|
-
/* #elif defined (other platforms) ... */
|
|
3477
|
-
#endif
|
|
3478
|
-
|
|
3479
3180
|
#if defined(PATH_MAX)
|
|
3480
3181
|
# define LT_PATHMAX PATH_MAX
|
|
3481
3182
|
#elif defined(MAXPATHLEN)
|
|
@@ -3491,7 +3192,14 @@ int setenv (const char *, const char *, int);
|
|
|
3491
3192
|
# define S_IXGRP 0
|
|
3492
3193
|
#endif
|
|
3493
3194
|
|
|
3494
|
-
|
|
3195
|
+
#ifdef _MSC_VER
|
|
3196
|
+
# define S_IXUSR _S_IEXEC
|
|
3197
|
+
# define stat _stat
|
|
3198
|
+
# ifndef _INTPTR_T_DEFINED
|
|
3199
|
+
# define intptr_t int
|
|
3200
|
+
# endif
|
|
3201
|
+
#endif
|
|
3202
|
+
|
|
3495
3203
|
#ifndef DIR_SEPARATOR
|
|
3496
3204
|
# define DIR_SEPARATOR '/'
|
|
3497
3205
|
# define PATH_SEPARATOR ':'
|
|
@@ -3522,6 +3230,10 @@ int setenv (const char *, const char *, int);
|
|
|
3522
3230
|
# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
|
|
3523
3231
|
#endif /* PATH_SEPARATOR_2 */
|
|
3524
3232
|
|
|
3233
|
+
#ifdef __CYGWIN__
|
|
3234
|
+
# define FOPEN_WB "wb"
|
|
3235
|
+
#endif
|
|
3236
|
+
|
|
3525
3237
|
#ifndef FOPEN_WB
|
|
3526
3238
|
# define FOPEN_WB "w"
|
|
3527
3239
|
#endif
|
|
@@ -3534,13 +3246,22 @@ int setenv (const char *, const char *, int);
|
|
|
3534
3246
|
if (stale) { free ((void *) stale); stale = 0; } \
|
|
3535
3247
|
} while (0)
|
|
3536
3248
|
|
|
3537
|
-
#
|
|
3538
|
-
|
|
3249
|
+
#undef LTWRAPPER_DEBUGPRINTF
|
|
3250
|
+
#if defined DEBUGWRAPPER
|
|
3251
|
+
# define LTWRAPPER_DEBUGPRINTF(args) ltwrapper_debugprintf args
|
|
3252
|
+
static void
|
|
3253
|
+
ltwrapper_debugprintf (const char *fmt, ...)
|
|
3254
|
+
{
|
|
3255
|
+
va_list args;
|
|
3256
|
+
va_start (args, fmt);
|
|
3257
|
+
(void) vfprintf (stderr, fmt, args);
|
|
3258
|
+
va_end (args);
|
|
3259
|
+
}
|
|
3539
3260
|
#else
|
|
3540
|
-
|
|
3261
|
+
# define LTWRAPPER_DEBUGPRINTF(args)
|
|
3541
3262
|
#endif
|
|
3542
3263
|
|
|
3543
|
-
const char *program_name =
|
|
3264
|
+
const char *program_name = NULL;
|
|
3544
3265
|
|
|
3545
3266
|
void *xmalloc (size_t num);
|
|
3546
3267
|
char *xstrdup (const char *string);
|
|
@@ -3550,17 +3271,31 @@ char *chase_symlinks (const char *pathspec);
|
|
|
3550
3271
|
int make_executable (const char *path);
|
|
3551
3272
|
int check_executable (const char *path);
|
|
3552
3273
|
char *strendzap (char *str, const char *pat);
|
|
3553
|
-
void
|
|
3554
|
-
void lt_fatal (const char *file, int line, const char *message, ...);
|
|
3555
|
-
static const char *nonnull (const char *s);
|
|
3556
|
-
static const char *nonempty (const char *s);
|
|
3274
|
+
void lt_fatal (const char *message, ...);
|
|
3557
3275
|
void lt_setenv (const char *name, const char *value);
|
|
3558
3276
|
char *lt_extend_str (const char *orig_value, const char *add, int to_end);
|
|
3277
|
+
void lt_opt_process_env_set (const char *arg);
|
|
3278
|
+
void lt_opt_process_env_prepend (const char *arg);
|
|
3279
|
+
void lt_opt_process_env_append (const char *arg);
|
|
3280
|
+
int lt_split_name_value (const char *arg, char** name, char** value);
|
|
3559
3281
|
void lt_update_exe_path (const char *name, const char *value);
|
|
3560
3282
|
void lt_update_lib_path (const char *name, const char *value);
|
|
3561
|
-
|
|
3562
|
-
|
|
3283
|
+
|
|
3284
|
+
static const char *script_text_part1 =
|
|
3285
|
+
EOF
|
|
3286
|
+
|
|
3287
|
+
func_emit_wrapper_part1 yes |
|
|
3288
|
+
$SED -e 's/\([\\"]\)/\\\1/g' \
|
|
3289
|
+
-e 's/^/ "/' -e 's/$/\\n"/'
|
|
3290
|
+
echo ";"
|
|
3291
|
+
cat <<EOF
|
|
3292
|
+
|
|
3293
|
+
static const char *script_text_part2 =
|
|
3563
3294
|
EOF
|
|
3295
|
+
func_emit_wrapper_part2 yes |
|
|
3296
|
+
$SED -e 's/\([\\"]\)/\\\1/g' \
|
|
3297
|
+
-e 's/^/ "/' -e 's/$/\\n"/'
|
|
3298
|
+
echo ";"
|
|
3564
3299
|
|
|
3565
3300
|
cat <<EOF
|
|
3566
3301
|
const char * MAGIC_EXE = "$magic_exe";
|
|
@@ -3605,10 +3340,24 @@ EOF
|
|
|
3605
3340
|
cat <<"EOF"
|
|
3606
3341
|
|
|
3607
3342
|
#define LTWRAPPER_OPTION_PREFIX "--lt-"
|
|
3343
|
+
#define LTWRAPPER_OPTION_PREFIX_LENGTH 5
|
|
3608
3344
|
|
|
3345
|
+
static const size_t opt_prefix_len = LTWRAPPER_OPTION_PREFIX_LENGTH;
|
|
3609
3346
|
static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX;
|
|
3347
|
+
|
|
3610
3348
|
static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script";
|
|
3611
|
-
|
|
3349
|
+
|
|
3350
|
+
static const size_t env_set_opt_len = LTWRAPPER_OPTION_PREFIX_LENGTH + 7;
|
|
3351
|
+
static const char *env_set_opt = LTWRAPPER_OPTION_PREFIX "env-set";
|
|
3352
|
+
/* argument is putenv-style "foo=bar", value of foo is set to bar */
|
|
3353
|
+
|
|
3354
|
+
static const size_t env_prepend_opt_len = LTWRAPPER_OPTION_PREFIX_LENGTH + 11;
|
|
3355
|
+
static const char *env_prepend_opt = LTWRAPPER_OPTION_PREFIX "env-prepend";
|
|
3356
|
+
/* argument is putenv-style "foo=bar", new value of foo is bar${foo} */
|
|
3357
|
+
|
|
3358
|
+
static const size_t env_append_opt_len = LTWRAPPER_OPTION_PREFIX_LENGTH + 10;
|
|
3359
|
+
static const char *env_append_opt = LTWRAPPER_OPTION_PREFIX "env-append";
|
|
3360
|
+
/* argument is putenv-style "foo=bar", new value of foo is ${foo}bar */
|
|
3612
3361
|
|
|
3613
3362
|
int
|
|
3614
3363
|
main (int argc, char *argv[])
|
|
@@ -3625,13 +3374,10 @@ main (int argc, char *argv[])
|
|
|
3625
3374
|
int i;
|
|
3626
3375
|
|
|
3627
3376
|
program_name = (char *) xstrdup (base_name (argv[0]));
|
|
3628
|
-
|
|
3377
|
+
LTWRAPPER_DEBUGPRINTF (("(main) argv[0] : %s\n", argv[0]));
|
|
3378
|
+
LTWRAPPER_DEBUGPRINTF (("(main) program_name : %s\n", program_name));
|
|
3629
3379
|
|
|
3630
|
-
/* very simple arg parsing; don't want to rely on getopt
|
|
3631
|
-
* also, copy all non cwrapper options to newargz, except
|
|
3632
|
-
* argz[0], which is handled differently
|
|
3633
|
-
*/
|
|
3634
|
-
newargc=0;
|
|
3380
|
+
/* very simple arg parsing; don't want to rely on getopt */
|
|
3635
3381
|
for (i = 1; i < argc; i++)
|
|
3636
3382
|
{
|
|
3637
3383
|
if (strcmp (argv[i], dumpscript_opt) == 0)
|
|
@@ -3645,57 +3391,25 @@ EOF
|
|
|
3645
3391
|
esac
|
|
3646
3392
|
|
|
3647
3393
|
cat <<"EOF"
|
|
3648
|
-
|
|
3394
|
+
printf ("%s", script_text_part1);
|
|
3395
|
+
printf ("%s", script_text_part2);
|
|
3649
3396
|
return 0;
|
|
3650
3397
|
}
|
|
3651
|
-
if (strcmp (argv[i], debug_opt) == 0)
|
|
3652
|
-
{
|
|
3653
|
-
lt_debug = 1;
|
|
3654
|
-
continue;
|
|
3655
|
-
}
|
|
3656
|
-
if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
|
|
3657
|
-
{
|
|
3658
|
-
/* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
|
|
3659
|
-
namespace, but it is not one of the ones we know about and
|
|
3660
|
-
have already dealt with, above (inluding dump-script), then
|
|
3661
|
-
report an error. Otherwise, targets might begin to believe
|
|
3662
|
-
they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
|
|
3663
|
-
namespace. The first time any user complains about this, we'll
|
|
3664
|
-
need to make LTWRAPPER_OPTION_PREFIX a configure-time option
|
|
3665
|
-
or a configure.ac-settable value.
|
|
3666
|
-
*/
|
|
3667
|
-
lt_fatal (__FILE__, __LINE__,
|
|
3668
|
-
"unrecognized %s option: '%s'",
|
|
3669
|
-
ltwrapper_option_prefix, argv[i]);
|
|
3670
|
-
}
|
|
3671
|
-
/* otherwise ... */
|
|
3672
|
-
newargz[++newargc] = xstrdup (argv[i]);
|
|
3673
3398
|
}
|
|
3674
|
-
newargz[++newargc] = NULL;
|
|
3675
|
-
|
|
3676
|
-
EOF
|
|
3677
|
-
cat <<EOF
|
|
3678
|
-
/* The GNU banner must be the first non-error debug message */
|
|
3679
|
-
lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
|
|
3680
|
-
EOF
|
|
3681
|
-
cat <<"EOF"
|
|
3682
|
-
lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
|
|
3683
|
-
lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name);
|
|
3684
3399
|
|
|
3400
|
+
newargz = XMALLOC (char *, argc + 1);
|
|
3685
3401
|
tmp_pathspec = find_executable (argv[0]);
|
|
3686
3402
|
if (tmp_pathspec == NULL)
|
|
3687
|
-
lt_fatal (
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
tmp_pathspec);
|
|
3403
|
+
lt_fatal ("Couldn't find %s", argv[0]);
|
|
3404
|
+
LTWRAPPER_DEBUGPRINTF (("(main) found exe (before symlink chase) at : %s\n",
|
|
3405
|
+
tmp_pathspec));
|
|
3691
3406
|
|
|
3692
3407
|
actual_cwrapper_path = chase_symlinks (tmp_pathspec);
|
|
3693
|
-
|
|
3694
|
-
|
|
3695
|
-
actual_cwrapper_path);
|
|
3408
|
+
LTWRAPPER_DEBUGPRINTF (("(main) found exe (after symlink chase) at : %s\n",
|
|
3409
|
+
actual_cwrapper_path));
|
|
3696
3410
|
XFREE (tmp_pathspec);
|
|
3697
3411
|
|
|
3698
|
-
actual_cwrapper_name = xstrdup
|
|
3412
|
+
actual_cwrapper_name = xstrdup( base_name (actual_cwrapper_path));
|
|
3699
3413
|
strendzap (actual_cwrapper_path, actual_cwrapper_name);
|
|
3700
3414
|
|
|
3701
3415
|
/* wrapper name transforms */
|
|
@@ -3713,9 +3427,8 @@ EOF
|
|
|
3713
3427
|
target_name = tmp_pathspec;
|
|
3714
3428
|
tmp_pathspec = 0;
|
|
3715
3429
|
|
|
3716
|
-
|
|
3717
|
-
|
|
3718
|
-
target_name);
|
|
3430
|
+
LTWRAPPER_DEBUGPRINTF (("(main) libtool target name: %s\n",
|
|
3431
|
+
target_name));
|
|
3719
3432
|
EOF
|
|
3720
3433
|
|
|
3721
3434
|
cat <<EOF
|
|
@@ -3768,12 +3481,77 @@ EOF
|
|
|
3768
3481
|
lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
|
|
3769
3482
|
lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE);
|
|
3770
3483
|
|
|
3771
|
-
|
|
3772
|
-
|
|
3484
|
+
newargc=0;
|
|
3485
|
+
for (i = 1; i < argc; i++)
|
|
3486
|
+
{
|
|
3487
|
+
if (strncmp (argv[i], env_set_opt, env_set_opt_len) == 0)
|
|
3488
|
+
{
|
|
3489
|
+
if (argv[i][env_set_opt_len] == '=')
|
|
3490
|
+
{
|
|
3491
|
+
const char *p = argv[i] + env_set_opt_len + 1;
|
|
3492
|
+
lt_opt_process_env_set (p);
|
|
3493
|
+
}
|
|
3494
|
+
else if (argv[i][env_set_opt_len] == '\0' && i + 1 < argc)
|
|
3495
|
+
{
|
|
3496
|
+
lt_opt_process_env_set (argv[++i]); /* don't copy */
|
|
3497
|
+
}
|
|
3498
|
+
else
|
|
3499
|
+
lt_fatal ("%s missing required argument", env_set_opt);
|
|
3500
|
+
continue;
|
|
3501
|
+
}
|
|
3502
|
+
if (strncmp (argv[i], env_prepend_opt, env_prepend_opt_len) == 0)
|
|
3503
|
+
{
|
|
3504
|
+
if (argv[i][env_prepend_opt_len] == '=')
|
|
3505
|
+
{
|
|
3506
|
+
const char *p = argv[i] + env_prepend_opt_len + 1;
|
|
3507
|
+
lt_opt_process_env_prepend (p);
|
|
3508
|
+
}
|
|
3509
|
+
else if (argv[i][env_prepend_opt_len] == '\0' && i + 1 < argc)
|
|
3510
|
+
{
|
|
3511
|
+
lt_opt_process_env_prepend (argv[++i]); /* don't copy */
|
|
3512
|
+
}
|
|
3513
|
+
else
|
|
3514
|
+
lt_fatal ("%s missing required argument", env_prepend_opt);
|
|
3515
|
+
continue;
|
|
3516
|
+
}
|
|
3517
|
+
if (strncmp (argv[i], env_append_opt, env_append_opt_len) == 0)
|
|
3518
|
+
{
|
|
3519
|
+
if (argv[i][env_append_opt_len] == '=')
|
|
3520
|
+
{
|
|
3521
|
+
const char *p = argv[i] + env_append_opt_len + 1;
|
|
3522
|
+
lt_opt_process_env_append (p);
|
|
3523
|
+
}
|
|
3524
|
+
else if (argv[i][env_append_opt_len] == '\0' && i + 1 < argc)
|
|
3525
|
+
{
|
|
3526
|
+
lt_opt_process_env_append (argv[++i]); /* don't copy */
|
|
3527
|
+
}
|
|
3528
|
+
else
|
|
3529
|
+
lt_fatal ("%s missing required argument", env_append_opt);
|
|
3530
|
+
continue;
|
|
3531
|
+
}
|
|
3532
|
+
if (strncmp (argv[i], ltwrapper_option_prefix, opt_prefix_len) == 0)
|
|
3533
|
+
{
|
|
3534
|
+
/* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
|
|
3535
|
+
namespace, but it is not one of the ones we know about and
|
|
3536
|
+
have already dealt with, above (inluding dump-script), then
|
|
3537
|
+
report an error. Otherwise, targets might begin to believe
|
|
3538
|
+
they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
|
|
3539
|
+
namespace. The first time any user complains about this, we'll
|
|
3540
|
+
need to make LTWRAPPER_OPTION_PREFIX a configure-time option
|
|
3541
|
+
or a configure.ac-settable value.
|
|
3542
|
+
*/
|
|
3543
|
+
lt_fatal ("Unrecognized option in %s namespace: '%s'",
|
|
3544
|
+
ltwrapper_option_prefix, argv[i]);
|
|
3545
|
+
}
|
|
3546
|
+
/* otherwise ... */
|
|
3547
|
+
newargz[++newargc] = xstrdup (argv[i]);
|
|
3548
|
+
}
|
|
3549
|
+
newargz[++newargc] = NULL;
|
|
3550
|
+
|
|
3551
|
+
LTWRAPPER_DEBUGPRINTF (("(main) lt_argv_zero : %s\n", (lt_argv_zero ? lt_argv_zero : "<NULL>")));
|
|
3773
3552
|
for (i = 0; i < newargc; i++)
|
|
3774
3553
|
{
|
|
3775
|
-
|
|
3776
|
-
i, nonnull (newargz[i]));
|
|
3554
|
+
LTWRAPPER_DEBUGPRINTF (("(main) newargz[%d] : %s\n", i, (newargz[i] ? newargz[i] : "<NULL>")));
|
|
3777
3555
|
}
|
|
3778
3556
|
|
|
3779
3557
|
EOF
|
|
@@ -3782,14 +3560,11 @@ EOF
|
|
|
3782
3560
|
mingw*)
|
|
3783
3561
|
cat <<"EOF"
|
|
3784
3562
|
/* execv doesn't actually work on mingw as expected on unix */
|
|
3785
|
-
newargz = prepare_spawn (newargz);
|
|
3786
3563
|
rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
|
|
3787
3564
|
if (rval == -1)
|
|
3788
3565
|
{
|
|
3789
3566
|
/* failed to start process */
|
|
3790
|
-
|
|
3791
|
-
"(main) failed to launch target \"%s\": %s\n",
|
|
3792
|
-
lt_argv_zero, nonnull (strerror (errno)));
|
|
3567
|
+
LTWRAPPER_DEBUGPRINTF (("(main) failed to launch target \"%s\": errno = %d\n", lt_argv_zero, errno));
|
|
3793
3568
|
return 127;
|
|
3794
3569
|
}
|
|
3795
3570
|
return rval;
|
|
@@ -3811,7 +3586,7 @@ xmalloc (size_t num)
|
|
|
3811
3586
|
{
|
|
3812
3587
|
void *p = (void *) malloc (num);
|
|
3813
3588
|
if (!p)
|
|
3814
|
-
lt_fatal (
|
|
3589
|
+
lt_fatal ("Memory exhausted");
|
|
3815
3590
|
|
|
3816
3591
|
return p;
|
|
3817
3592
|
}
|
|
@@ -3845,8 +3620,8 @@ check_executable (const char *path)
|
|
|
3845
3620
|
{
|
|
3846
3621
|
struct stat st;
|
|
3847
3622
|
|
|
3848
|
-
|
|
3849
|
-
|
|
3623
|
+
LTWRAPPER_DEBUGPRINTF (("(check_executable) : %s\n",
|
|
3624
|
+
path ? (*path ? path : "EMPTY!") : "NULL!"));
|
|
3850
3625
|
if ((!path) || (!*path))
|
|
3851
3626
|
return 0;
|
|
3852
3627
|
|
|
@@ -3863,8 +3638,8 @@ make_executable (const char *path)
|
|
|
3863
3638
|
int rval = 0;
|
|
3864
3639
|
struct stat st;
|
|
3865
3640
|
|
|
3866
|
-
|
|
3867
|
-
|
|
3641
|
+
LTWRAPPER_DEBUGPRINTF (("(make_executable) : %s\n",
|
|
3642
|
+
path ? (*path ? path : "EMPTY!") : "NULL!"));
|
|
3868
3643
|
if ((!path) || (!*path))
|
|
3869
3644
|
return 0;
|
|
3870
3645
|
|
|
@@ -3890,8 +3665,8 @@ find_executable (const char *wrapper)
|
|
|
3890
3665
|
int tmp_len;
|
|
3891
3666
|
char *concat_name;
|
|
3892
3667
|
|
|
3893
|
-
|
|
3894
|
-
|
|
3668
|
+
LTWRAPPER_DEBUGPRINTF (("(find_executable) : %s\n",
|
|
3669
|
+
wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"));
|
|
3895
3670
|
|
|
3896
3671
|
if ((wrapper == NULL) || (*wrapper == '\0'))
|
|
3897
3672
|
return NULL;
|
|
@@ -3944,8 +3719,7 @@ find_executable (const char *wrapper)
|
|
|
3944
3719
|
{
|
|
3945
3720
|
/* empty path: current directory */
|
|
3946
3721
|
if (getcwd (tmp, LT_PATHMAX) == NULL)
|
|
3947
|
-
lt_fatal (
|
|
3948
|
-
nonnull (strerror (errno)));
|
|
3722
|
+
lt_fatal ("getcwd failed");
|
|
3949
3723
|
tmp_len = strlen (tmp);
|
|
3950
3724
|
concat_name =
|
|
3951
3725
|
XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
|
|
@@ -3970,8 +3744,7 @@ find_executable (const char *wrapper)
|
|
|
3970
3744
|
}
|
|
3971
3745
|
/* Relative path | not found in path: prepend cwd */
|
|
3972
3746
|
if (getcwd (tmp, LT_PATHMAX) == NULL)
|
|
3973
|
-
lt_fatal (
|
|
3974
|
-
nonnull (strerror (errno)));
|
|
3747
|
+
lt_fatal ("getcwd failed");
|
|
3975
3748
|
tmp_len = strlen (tmp);
|
|
3976
3749
|
concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
|
|
3977
3750
|
memcpy (concat_name, tmp, tmp_len);
|
|
@@ -3997,9 +3770,8 @@ chase_symlinks (const char *pathspec)
|
|
|
3997
3770
|
int has_symlinks = 0;
|
|
3998
3771
|
while (strlen (tmp_pathspec) && !has_symlinks)
|
|
3999
3772
|
{
|
|
4000
|
-
|
|
4001
|
-
|
|
4002
|
-
tmp_pathspec);
|
|
3773
|
+
LTWRAPPER_DEBUGPRINTF (("checking path component for symlinks: %s\n",
|
|
3774
|
+
tmp_pathspec));
|
|
4003
3775
|
if (lstat (tmp_pathspec, &s) == 0)
|
|
4004
3776
|
{
|
|
4005
3777
|
if (S_ISLNK (s.st_mode) != 0)
|
|
@@ -4021,9 +3793,8 @@ chase_symlinks (const char *pathspec)
|
|
|
4021
3793
|
}
|
|
4022
3794
|
else
|
|
4023
3795
|
{
|
|
4024
|
-
|
|
4025
|
-
|
|
4026
|
-
tmp_pathspec, nonnull (strerror (errno)));
|
|
3796
|
+
char *errstr = strerror (errno);
|
|
3797
|
+
lt_fatal ("Error accessing file %s (%s)", tmp_pathspec, errstr);
|
|
4027
3798
|
}
|
|
4028
3799
|
}
|
|
4029
3800
|
XFREE (tmp_pathspec);
|
|
@@ -4036,8 +3807,7 @@ chase_symlinks (const char *pathspec)
|
|
|
4036
3807
|
tmp_pathspec = realpath (pathspec, buf);
|
|
4037
3808
|
if (tmp_pathspec == 0)
|
|
4038
3809
|
{
|
|
4039
|
-
lt_fatal (
|
|
4040
|
-
"could not follow symlinks for %s", pathspec);
|
|
3810
|
+
lt_fatal ("Could not follow symlinks for %s", pathspec);
|
|
4041
3811
|
}
|
|
4042
3812
|
return xstrdup (tmp_pathspec);
|
|
4043
3813
|
#endif
|
|
@@ -4063,25 +3833,11 @@ strendzap (char *str, const char *pat)
|
|
|
4063
3833
|
return str;
|
|
4064
3834
|
}
|
|
4065
3835
|
|
|
4066
|
-
void
|
|
4067
|
-
lt_debugprintf (const char *file, int line, const char *fmt, ...)
|
|
4068
|
-
{
|
|
4069
|
-
va_list args;
|
|
4070
|
-
if (lt_debug)
|
|
4071
|
-
{
|
|
4072
|
-
(void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line);
|
|
4073
|
-
va_start (args, fmt);
|
|
4074
|
-
(void) vfprintf (stderr, fmt, args);
|
|
4075
|
-
va_end (args);
|
|
4076
|
-
}
|
|
4077
|
-
}
|
|
4078
|
-
|
|
4079
3836
|
static void
|
|
4080
|
-
lt_error_core (int exit_status, const char *
|
|
4081
|
-
int line, const char *mode,
|
|
3837
|
+
lt_error_core (int exit_status, const char *mode,
|
|
4082
3838
|
const char *message, va_list ap)
|
|
4083
3839
|
{
|
|
4084
|
-
fprintf (stderr, "%s
|
|
3840
|
+
fprintf (stderr, "%s: %s: ", program_name, mode);
|
|
4085
3841
|
vfprintf (stderr, message, ap);
|
|
4086
3842
|
fprintf (stderr, ".\n");
|
|
4087
3843
|
|
|
@@ -4090,32 +3846,20 @@ lt_error_core (int exit_status, const char *file,
|
|
|
4090
3846
|
}
|
|
4091
3847
|
|
|
4092
3848
|
void
|
|
4093
|
-
lt_fatal (const char *
|
|
3849
|
+
lt_fatal (const char *message, ...)
|
|
4094
3850
|
{
|
|
4095
3851
|
va_list ap;
|
|
4096
3852
|
va_start (ap, message);
|
|
4097
|
-
lt_error_core (EXIT_FAILURE,
|
|
3853
|
+
lt_error_core (EXIT_FAILURE, "FATAL", message, ap);
|
|
4098
3854
|
va_end (ap);
|
|
4099
3855
|
}
|
|
4100
3856
|
|
|
4101
|
-
static const char *
|
|
4102
|
-
nonnull (const char *s)
|
|
4103
|
-
{
|
|
4104
|
-
return s ? s : "(null)";
|
|
4105
|
-
}
|
|
4106
|
-
|
|
4107
|
-
static const char *
|
|
4108
|
-
nonempty (const char *s)
|
|
4109
|
-
{
|
|
4110
|
-
return (s && !*s) ? "(empty)" : nonnull (s);
|
|
4111
|
-
}
|
|
4112
|
-
|
|
4113
3857
|
void
|
|
4114
3858
|
lt_setenv (const char *name, const char *value)
|
|
4115
3859
|
{
|
|
4116
|
-
|
|
4117
|
-
|
|
4118
|
-
|
|
3860
|
+
LTWRAPPER_DEBUGPRINTF (("(lt_setenv) setting '%s' to '%s'\n",
|
|
3861
|
+
(name ? name : "<NULL>"),
|
|
3862
|
+
(value ? value : "<NULL>")));
|
|
4119
3863
|
{
|
|
4120
3864
|
#ifdef HAVE_SETENV
|
|
4121
3865
|
/* always make a copy, for consistency with !HAVE_SETENV */
|
|
@@ -4160,12 +3904,95 @@ lt_extend_str (const char *orig_value, const char *add, int to_end)
|
|
|
4160
3904
|
return new_value;
|
|
4161
3905
|
}
|
|
4162
3906
|
|
|
3907
|
+
int
|
|
3908
|
+
lt_split_name_value (const char *arg, char** name, char** value)
|
|
3909
|
+
{
|
|
3910
|
+
const char *p;
|
|
3911
|
+
int len;
|
|
3912
|
+
if (!arg || !*arg)
|
|
3913
|
+
return 1;
|
|
3914
|
+
|
|
3915
|
+
p = strchr (arg, (int)'=');
|
|
3916
|
+
|
|
3917
|
+
if (!p)
|
|
3918
|
+
return 1;
|
|
3919
|
+
|
|
3920
|
+
*value = xstrdup (++p);
|
|
3921
|
+
|
|
3922
|
+
len = strlen (arg) - strlen (*value);
|
|
3923
|
+
*name = XMALLOC (char, len);
|
|
3924
|
+
strncpy (*name, arg, len-1);
|
|
3925
|
+
(*name)[len - 1] = '\0';
|
|
3926
|
+
|
|
3927
|
+
return 0;
|
|
3928
|
+
}
|
|
3929
|
+
|
|
3930
|
+
void
|
|
3931
|
+
lt_opt_process_env_set (const char *arg)
|
|
3932
|
+
{
|
|
3933
|
+
char *name = NULL;
|
|
3934
|
+
char *value = NULL;
|
|
3935
|
+
|
|
3936
|
+
if (lt_split_name_value (arg, &name, &value) != 0)
|
|
3937
|
+
{
|
|
3938
|
+
XFREE (name);
|
|
3939
|
+
XFREE (value);
|
|
3940
|
+
lt_fatal ("bad argument for %s: '%s'", env_set_opt, arg);
|
|
3941
|
+
}
|
|
3942
|
+
|
|
3943
|
+
lt_setenv (name, value);
|
|
3944
|
+
XFREE (name);
|
|
3945
|
+
XFREE (value);
|
|
3946
|
+
}
|
|
3947
|
+
|
|
3948
|
+
void
|
|
3949
|
+
lt_opt_process_env_prepend (const char *arg)
|
|
3950
|
+
{
|
|
3951
|
+
char *name = NULL;
|
|
3952
|
+
char *value = NULL;
|
|
3953
|
+
char *new_value = NULL;
|
|
3954
|
+
|
|
3955
|
+
if (lt_split_name_value (arg, &name, &value) != 0)
|
|
3956
|
+
{
|
|
3957
|
+
XFREE (name);
|
|
3958
|
+
XFREE (value);
|
|
3959
|
+
lt_fatal ("bad argument for %s: '%s'", env_prepend_opt, arg);
|
|
3960
|
+
}
|
|
3961
|
+
|
|
3962
|
+
new_value = lt_extend_str (getenv (name), value, 0);
|
|
3963
|
+
lt_setenv (name, new_value);
|
|
3964
|
+
XFREE (new_value);
|
|
3965
|
+
XFREE (name);
|
|
3966
|
+
XFREE (value);
|
|
3967
|
+
}
|
|
3968
|
+
|
|
3969
|
+
void
|
|
3970
|
+
lt_opt_process_env_append (const char *arg)
|
|
3971
|
+
{
|
|
3972
|
+
char *name = NULL;
|
|
3973
|
+
char *value = NULL;
|
|
3974
|
+
char *new_value = NULL;
|
|
3975
|
+
|
|
3976
|
+
if (lt_split_name_value (arg, &name, &value) != 0)
|
|
3977
|
+
{
|
|
3978
|
+
XFREE (name);
|
|
3979
|
+
XFREE (value);
|
|
3980
|
+
lt_fatal ("bad argument for %s: '%s'", env_append_opt, arg);
|
|
3981
|
+
}
|
|
3982
|
+
|
|
3983
|
+
new_value = lt_extend_str (getenv (name), value, 1);
|
|
3984
|
+
lt_setenv (name, new_value);
|
|
3985
|
+
XFREE (new_value);
|
|
3986
|
+
XFREE (name);
|
|
3987
|
+
XFREE (value);
|
|
3988
|
+
}
|
|
3989
|
+
|
|
4163
3990
|
void
|
|
4164
3991
|
lt_update_exe_path (const char *name, const char *value)
|
|
4165
3992
|
{
|
|
4166
|
-
|
|
4167
|
-
|
|
4168
|
-
|
|
3993
|
+
LTWRAPPER_DEBUGPRINTF (("(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
|
|
3994
|
+
(name ? name : "<NULL>"),
|
|
3995
|
+
(value ? value : "<NULL>")));
|
|
4169
3996
|
|
|
4170
3997
|
if (name && *name && value && *value)
|
|
4171
3998
|
{
|
|
@@ -4184,9 +4011,9 @@ lt_update_exe_path (const char *name, const char *value)
|
|
|
4184
4011
|
void
|
|
4185
4012
|
lt_update_lib_path (const char *name, const char *value)
|
|
4186
4013
|
{
|
|
4187
|
-
|
|
4188
|
-
|
|
4189
|
-
|
|
4014
|
+
LTWRAPPER_DEBUGPRINTF (("(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
|
|
4015
|
+
(name ? name : "<NULL>"),
|
|
4016
|
+
(value ? value : "<NULL>")));
|
|
4190
4017
|
|
|
4191
4018
|
if (name && *name && value && *value)
|
|
4192
4019
|
{
|
|
@@ -4196,152 +4023,11 @@ lt_update_lib_path (const char *name, const char *value)
|
|
|
4196
4023
|
}
|
|
4197
4024
|
}
|
|
4198
4025
|
|
|
4199
|
-
EOF
|
|
4200
|
-
case $host_os in
|
|
4201
|
-
mingw*)
|
|
4202
|
-
cat <<"EOF"
|
|
4203
|
-
|
|
4204
|
-
/* Prepares an argument vector before calling spawn().
|
|
4205
|
-
Note that spawn() does not by itself call the command interpreter
|
|
4206
|
-
(getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") :
|
|
4207
|
-
({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
|
|
4208
|
-
GetVersionEx(&v);
|
|
4209
|
-
v.dwPlatformId == VER_PLATFORM_WIN32_NT;
|
|
4210
|
-
}) ? "cmd.exe" : "command.com").
|
|
4211
|
-
Instead it simply concatenates the arguments, separated by ' ', and calls
|
|
4212
|
-
CreateProcess(). We must quote the arguments since Win32 CreateProcess()
|
|
4213
|
-
interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a
|
|
4214
|
-
special way:
|
|
4215
|
-
- Space and tab are interpreted as delimiters. They are not treated as
|
|
4216
|
-
delimiters if they are surrounded by double quotes: "...".
|
|
4217
|
-
- Unescaped double quotes are removed from the input. Their only effect is
|
|
4218
|
-
that within double quotes, space and tab are treated like normal
|
|
4219
|
-
characters.
|
|
4220
|
-
- Backslashes not followed by double quotes are not special.
|
|
4221
|
-
- But 2*n+1 backslashes followed by a double quote become
|
|
4222
|
-
n backslashes followed by a double quote (n >= 0):
|
|
4223
|
-
\" -> "
|
|
4224
|
-
\\\" -> \"
|
|
4225
|
-
\\\\\" -> \\"
|
|
4226
|
-
*/
|
|
4227
|
-
#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"
|
|
4228
|
-
#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"
|
|
4229
|
-
char **
|
|
4230
|
-
prepare_spawn (char **argv)
|
|
4231
|
-
{
|
|
4232
|
-
size_t argc;
|
|
4233
|
-
char **new_argv;
|
|
4234
|
-
size_t i;
|
|
4235
|
-
|
|
4236
|
-
/* Count number of arguments. */
|
|
4237
|
-
for (argc = 0; argv[argc] != NULL; argc++)
|
|
4238
|
-
;
|
|
4239
|
-
|
|
4240
|
-
/* Allocate new argument vector. */
|
|
4241
|
-
new_argv = XMALLOC (char *, argc + 1);
|
|
4242
|
-
|
|
4243
|
-
/* Put quoted arguments into the new argument vector. */
|
|
4244
|
-
for (i = 0; i < argc; i++)
|
|
4245
|
-
{
|
|
4246
|
-
const char *string = argv[i];
|
|
4247
|
-
|
|
4248
|
-
if (string[0] == '\0')
|
|
4249
|
-
new_argv[i] = xstrdup ("\"\"");
|
|
4250
|
-
else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL)
|
|
4251
|
-
{
|
|
4252
|
-
int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL);
|
|
4253
|
-
size_t length;
|
|
4254
|
-
unsigned int backslashes;
|
|
4255
|
-
const char *s;
|
|
4256
|
-
char *quoted_string;
|
|
4257
|
-
char *p;
|
|
4258
|
-
|
|
4259
|
-
length = 0;
|
|
4260
|
-
backslashes = 0;
|
|
4261
|
-
if (quote_around)
|
|
4262
|
-
length++;
|
|
4263
|
-
for (s = string; *s != '\0'; s++)
|
|
4264
|
-
{
|
|
4265
|
-
char c = *s;
|
|
4266
|
-
if (c == '"')
|
|
4267
|
-
length += backslashes + 1;
|
|
4268
|
-
length++;
|
|
4269
|
-
if (c == '\\')
|
|
4270
|
-
backslashes++;
|
|
4271
|
-
else
|
|
4272
|
-
backslashes = 0;
|
|
4273
|
-
}
|
|
4274
|
-
if (quote_around)
|
|
4275
|
-
length += backslashes + 1;
|
|
4276
|
-
|
|
4277
|
-
quoted_string = XMALLOC (char, length + 1);
|
|
4278
|
-
|
|
4279
|
-
p = quoted_string;
|
|
4280
|
-
backslashes = 0;
|
|
4281
|
-
if (quote_around)
|
|
4282
|
-
*p++ = '"';
|
|
4283
|
-
for (s = string; *s != '\0'; s++)
|
|
4284
|
-
{
|
|
4285
|
-
char c = *s;
|
|
4286
|
-
if (c == '"')
|
|
4287
|
-
{
|
|
4288
|
-
unsigned int j;
|
|
4289
|
-
for (j = backslashes + 1; j > 0; j--)
|
|
4290
|
-
*p++ = '\\';
|
|
4291
|
-
}
|
|
4292
|
-
*p++ = c;
|
|
4293
|
-
if (c == '\\')
|
|
4294
|
-
backslashes++;
|
|
4295
|
-
else
|
|
4296
|
-
backslashes = 0;
|
|
4297
|
-
}
|
|
4298
|
-
if (quote_around)
|
|
4299
|
-
{
|
|
4300
|
-
unsigned int j;
|
|
4301
|
-
for (j = backslashes; j > 0; j--)
|
|
4302
|
-
*p++ = '\\';
|
|
4303
|
-
*p++ = '"';
|
|
4304
|
-
}
|
|
4305
|
-
*p = '\0';
|
|
4306
|
-
|
|
4307
|
-
new_argv[i] = quoted_string;
|
|
4308
|
-
}
|
|
4309
|
-
else
|
|
4310
|
-
new_argv[i] = (char *) string;
|
|
4311
|
-
}
|
|
4312
|
-
new_argv[argc] = NULL;
|
|
4313
|
-
|
|
4314
|
-
return new_argv;
|
|
4315
|
-
}
|
|
4316
|
-
EOF
|
|
4317
|
-
;;
|
|
4318
|
-
esac
|
|
4319
|
-
|
|
4320
|
-
cat <<"EOF"
|
|
4321
|
-
void lt_dump_script (FILE* f)
|
|
4322
|
-
{
|
|
4323
|
-
EOF
|
|
4324
|
-
func_emit_wrapper yes |
|
|
4325
|
-
$SED -e 's/\([\\"]\)/\\\1/g' \
|
|
4326
|
-
-e 's/^/ fputs ("/' -e 's/$/\\n", f);/'
|
|
4327
4026
|
|
|
4328
|
-
cat <<"EOF"
|
|
4329
|
-
}
|
|
4330
4027
|
EOF
|
|
4331
4028
|
}
|
|
4332
4029
|
# end: func_emit_cwrapperexe_src
|
|
4333
4030
|
|
|
4334
|
-
# func_win32_import_lib_p ARG
|
|
4335
|
-
# True if ARG is an import lib, as indicated by $file_magic_cmd
|
|
4336
|
-
func_win32_import_lib_p ()
|
|
4337
|
-
{
|
|
4338
|
-
$opt_debug
|
|
4339
|
-
case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
|
|
4340
|
-
*import*) : ;;
|
|
4341
|
-
*) false ;;
|
|
4342
|
-
esac
|
|
4343
|
-
}
|
|
4344
|
-
|
|
4345
4031
|
# func_mode_link arg...
|
|
4346
4032
|
func_mode_link ()
|
|
4347
4033
|
{
|
|
@@ -4386,7 +4072,6 @@ func_mode_link ()
|
|
|
4386
4072
|
new_inherited_linker_flags=
|
|
4387
4073
|
|
|
4388
4074
|
avoid_version=no
|
|
4389
|
-
bindir=
|
|
4390
4075
|
dlfiles=
|
|
4391
4076
|
dlprefiles=
|
|
4392
4077
|
dlself=no
|
|
@@ -4479,11 +4164,6 @@ func_mode_link ()
|
|
|
4479
4164
|
esac
|
|
4480
4165
|
|
|
4481
4166
|
case $prev in
|
|
4482
|
-
bindir)
|
|
4483
|
-
bindir="$arg"
|
|
4484
|
-
prev=
|
|
4485
|
-
continue
|
|
4486
|
-
;;
|
|
4487
4167
|
dlfiles|dlprefiles)
|
|
4488
4168
|
if test "$preload" = no; then
|
|
4489
4169
|
# Add the symbol object into the linking commands.
|
|
@@ -4745,11 +4425,6 @@ func_mode_link ()
|
|
|
4745
4425
|
continue
|
|
4746
4426
|
;;
|
|
4747
4427
|
|
|
4748
|
-
-bindir)
|
|
4749
|
-
prev=bindir
|
|
4750
|
-
continue
|
|
4751
|
-
;;
|
|
4752
|
-
|
|
4753
4428
|
-dlopen)
|
|
4754
4429
|
prev=dlfiles
|
|
4755
4430
|
continue
|
|
@@ -4828,7 +4503,7 @@ func_mode_link ()
|
|
|
4828
4503
|
esac
|
|
4829
4504
|
case $host in
|
|
4830
4505
|
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
|
|
4831
|
-
testbindir=`$ECHO "$dir" | $
|
|
4506
|
+
testbindir=`$ECHO "X$dir" | $Xsed -e 's*/lib$*/bin*'`
|
|
4832
4507
|
case :$dllsearchpath: in
|
|
4833
4508
|
*":$dir:"*) ;;
|
|
4834
4509
|
::) dllsearchpath=$dir;;
|
|
@@ -4847,7 +4522,7 @@ func_mode_link ()
|
|
|
4847
4522
|
-l*)
|
|
4848
4523
|
if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
|
|
4849
4524
|
case $host in
|
|
4850
|
-
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc*
|
|
4525
|
+
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc*)
|
|
4851
4526
|
# These systems don't actually have a C or math library (as such)
|
|
4852
4527
|
continue
|
|
4853
4528
|
;;
|
|
@@ -5033,7 +4708,7 @@ func_mode_link ()
|
|
|
5033
4708
|
for flag in $args; do
|
|
5034
4709
|
IFS="$save_ifs"
|
|
5035
4710
|
func_quote_for_eval "$flag"
|
|
5036
|
-
arg="$arg $func_quote_for_eval_result"
|
|
4711
|
+
arg="$arg $wl$func_quote_for_eval_result"
|
|
5037
4712
|
compiler_flags="$compiler_flags $func_quote_for_eval_result"
|
|
5038
4713
|
done
|
|
5039
4714
|
IFS="$save_ifs"
|
|
@@ -5079,19 +4754,18 @@ func_mode_link ()
|
|
|
5079
4754
|
arg="$func_quote_for_eval_result"
|
|
5080
4755
|
;;
|
|
5081
4756
|
|
|
5082
|
-
#
|
|
5083
|
-
# -
|
|
5084
|
-
# -
|
|
5085
|
-
#
|
|
5086
|
-
#
|
|
5087
|
-
# -
|
|
5088
|
-
#
|
|
5089
|
-
# -F/path
|
|
5090
|
-
# -p, -pg, --coverage, -fprofile-*
|
|
5091
|
-
# @file
|
|
5092
|
-
# -tp=* Portland pgcc target processor selection
|
|
4757
|
+
# -64, -mips[0-9] enable 64-bit mode on the SGI compiler
|
|
4758
|
+
# -r[0-9][0-9]* specifies the processor on the SGI compiler
|
|
4759
|
+
# -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler
|
|
4760
|
+
# +DA*, +DD* enable 64-bit mode on the HP compiler
|
|
4761
|
+
# -q* pass through compiler args for the IBM compiler
|
|
4762
|
+
# -m*, -t[45]*, -txscale* pass through architecture-specific
|
|
4763
|
+
# compiler args for GCC
|
|
4764
|
+
# -F/path gives path to uninstalled frameworks, gcc on darwin
|
|
4765
|
+
# -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC
|
|
4766
|
+
# @file GCC response files
|
|
5093
4767
|
-64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
|
|
5094
|
-
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F
|
|
4768
|
+
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*)
|
|
5095
4769
|
func_quote_for_eval "$arg"
|
|
5096
4770
|
arg="$func_quote_for_eval_result"
|
|
5097
4771
|
func_append compile_command " $arg"
|
|
@@ -5251,7 +4925,7 @@ func_mode_link ()
|
|
|
5251
4925
|
|
|
5252
4926
|
if test -n "$shlibpath_var"; then
|
|
5253
4927
|
# get the directories listed in $shlibpath_var
|
|
5254
|
-
eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$
|
|
4928
|
+
eval shlib_search_path=\`\$ECHO \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\`
|
|
5255
4929
|
else
|
|
5256
4930
|
shlib_search_path=
|
|
5257
4931
|
fi
|
|
@@ -5359,7 +5033,10 @@ func_mode_link ()
|
|
|
5359
5033
|
case $pass in
|
|
5360
5034
|
dlopen) libs="$dlfiles" ;;
|
|
5361
5035
|
dlpreopen) libs="$dlprefiles" ;;
|
|
5362
|
-
link)
|
|
5036
|
+
link)
|
|
5037
|
+
libs="$deplibs %DEPLIBS%"
|
|
5038
|
+
test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs"
|
|
5039
|
+
;;
|
|
5363
5040
|
esac
|
|
5364
5041
|
fi
|
|
5365
5042
|
if test "$linkmode,$pass" = "lib,dlpreopen"; then
|
|
@@ -5374,8 +5051,7 @@ func_mode_link ()
|
|
|
5374
5051
|
# Collect preopened libtool deplibs, except any this library
|
|
5375
5052
|
# has declared as weak libs
|
|
5376
5053
|
for deplib in $dependency_libs; do
|
|
5377
|
-
|
|
5378
|
-
deplib_base=$func_basename_result
|
|
5054
|
+
deplib_base=`$ECHO "X$deplib" | $Xsed -e "$basename"`
|
|
5379
5055
|
case " $weak_libs " in
|
|
5380
5056
|
*" $deplib_base "*) ;;
|
|
5381
5057
|
*) deplibs="$deplibs $deplib" ;;
|
|
@@ -5554,7 +5230,7 @@ func_mode_link ()
|
|
|
5554
5230
|
match_pattern*)
|
|
5555
5231
|
set dummy $deplibs_check_method; shift
|
|
5556
5232
|
match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
|
|
5557
|
-
if eval "\$ECHO \"$deplib\"" 2>/dev/null | $
|
|
5233
|
+
if eval "\$ECHO \"X$deplib\"" 2>/dev/null | $Xsed -e 10q \
|
|
5558
5234
|
| $EGREP "$match_pattern_regex" > /dev/null; then
|
|
5559
5235
|
valid_a_lib=yes
|
|
5560
5236
|
fi
|
|
@@ -5564,15 +5240,15 @@ func_mode_link ()
|
|
|
5564
5240
|
;;
|
|
5565
5241
|
esac
|
|
5566
5242
|
if test "$valid_a_lib" != yes; then
|
|
5567
|
-
|
|
5243
|
+
$ECHO
|
|
5568
5244
|
$ECHO "*** Warning: Trying to link with static lib archive $deplib."
|
|
5569
|
-
|
|
5570
|
-
|
|
5571
|
-
|
|
5572
|
-
|
|
5573
|
-
|
|
5245
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
5246
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
5247
|
+
$ECHO "*** shared version of the library, which you do not appear to have"
|
|
5248
|
+
$ECHO "*** because the file extensions .$libext of this argument makes me believe"
|
|
5249
|
+
$ECHO "*** that it is just a static archive that I should not use here."
|
|
5574
5250
|
else
|
|
5575
|
-
|
|
5251
|
+
$ECHO
|
|
5576
5252
|
$ECHO "*** Warning: Linking the shared library $output against the"
|
|
5577
5253
|
$ECHO "*** static library $deplib is not portable!"
|
|
5578
5254
|
deplibs="$deplib $deplibs"
|
|
@@ -5645,7 +5321,7 @@ func_mode_link ()
|
|
|
5645
5321
|
|
|
5646
5322
|
# Convert "-framework foo" to "foo.ltframework"
|
|
5647
5323
|
if test -n "$inherited_linker_flags"; then
|
|
5648
|
-
tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $
|
|
5324
|
+
tmp_inherited_linker_flags=`$ECHO "X$inherited_linker_flags" | $Xsed -e 's/-framework \([^ $]*\)/\1.ltframework/g'`
|
|
5649
5325
|
for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
|
|
5650
5326
|
case " $new_inherited_linker_flags " in
|
|
5651
5327
|
*" $tmp_inherited_linker_flag "*) ;;
|
|
@@ -5653,7 +5329,7 @@ func_mode_link ()
|
|
|
5653
5329
|
esac
|
|
5654
5330
|
done
|
|
5655
5331
|
fi
|
|
5656
|
-
dependency_libs=`$ECHO " $dependency_libs" | $
|
|
5332
|
+
dependency_libs=`$ECHO "X $dependency_libs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
5657
5333
|
if test "$linkmode,$pass" = "lib,link" ||
|
|
5658
5334
|
test "$linkmode,$pass" = "prog,scan" ||
|
|
5659
5335
|
{ test "$linkmode" != prog && test "$linkmode" != lib; }; then
|
|
@@ -5671,19 +5347,19 @@ func_mode_link ()
|
|
|
5671
5347
|
# It is a libtool convenience library, so add in its objects.
|
|
5672
5348
|
convenience="$convenience $ladir/$objdir/$old_library"
|
|
5673
5349
|
old_convenience="$old_convenience $ladir/$objdir/$old_library"
|
|
5350
|
+
tmp_libs=
|
|
5351
|
+
for deplib in $dependency_libs; do
|
|
5352
|
+
deplibs="$deplib $deplibs"
|
|
5353
|
+
if $opt_duplicate_deps ; then
|
|
5354
|
+
case "$tmp_libs " in
|
|
5355
|
+
*" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
|
|
5356
|
+
esac
|
|
5357
|
+
fi
|
|
5358
|
+
tmp_libs="$tmp_libs $deplib"
|
|
5359
|
+
done
|
|
5674
5360
|
elif test "$linkmode" != prog && test "$linkmode" != lib; then
|
|
5675
5361
|
func_fatal_error "\`$lib' is not a convenience library"
|
|
5676
5362
|
fi
|
|
5677
|
-
tmp_libs=
|
|
5678
|
-
for deplib in $dependency_libs; do
|
|
5679
|
-
deplibs="$deplib $deplibs"
|
|
5680
|
-
if $opt_duplicate_deps ; then
|
|
5681
|
-
case "$tmp_libs " in
|
|
5682
|
-
*" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
|
|
5683
|
-
esac
|
|
5684
|
-
fi
|
|
5685
|
-
tmp_libs="$tmp_libs $deplib"
|
|
5686
|
-
done
|
|
5687
5363
|
continue
|
|
5688
5364
|
fi # $pass = conv
|
|
5689
5365
|
|
|
@@ -5907,7 +5583,7 @@ func_mode_link ()
|
|
|
5907
5583
|
fi
|
|
5908
5584
|
done
|
|
5909
5585
|
if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
|
|
5910
|
-
|
|
5586
|
+
$ECHO
|
|
5911
5587
|
if test "$linkmode" = prog; then
|
|
5912
5588
|
$ECHO "*** Warning: Linking the executable $output against the loadable module"
|
|
5913
5589
|
else
|
|
@@ -6010,9 +5686,9 @@ func_mode_link ()
|
|
|
6010
5686
|
if test "X$dlopenmodule" != "X$lib"; then
|
|
6011
5687
|
$ECHO "*** Warning: lib $linklib is a module, not a shared library"
|
|
6012
5688
|
if test -z "$old_library" ; then
|
|
6013
|
-
|
|
6014
|
-
|
|
6015
|
-
|
|
5689
|
+
$ECHO
|
|
5690
|
+
$ECHO "*** And there doesn't seem to be a static archive available"
|
|
5691
|
+
$ECHO "*** The link will probably fail, sorry"
|
|
6016
5692
|
else
|
|
6017
5693
|
add="$dir/$old_library"
|
|
6018
5694
|
fi
|
|
@@ -6152,21 +5828,21 @@ func_mode_link ()
|
|
|
6152
5828
|
|
|
6153
5829
|
# Just print a warning and add the library to dependency_libs so
|
|
6154
5830
|
# that the program can be linked against the static library.
|
|
6155
|
-
|
|
5831
|
+
$ECHO
|
|
6156
5832
|
$ECHO "*** Warning: This system can not link to static lib archive $lib."
|
|
6157
|
-
|
|
6158
|
-
|
|
6159
|
-
|
|
5833
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
5834
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
5835
|
+
$ECHO "*** shared version of the library, which you do not appear to have."
|
|
6160
5836
|
if test "$module" = yes; then
|
|
6161
|
-
|
|
6162
|
-
|
|
6163
|
-
|
|
5837
|
+
$ECHO "*** But as you try to build a module library, libtool will still create "
|
|
5838
|
+
$ECHO "*** a static module, that should work as long as the dlopening application"
|
|
5839
|
+
$ECHO "*** is linked with the -dlopen flag to resolve symbols at runtime."
|
|
6164
5840
|
if test -z "$global_symbol_pipe"; then
|
|
6165
|
-
|
|
6166
|
-
|
|
6167
|
-
|
|
6168
|
-
|
|
6169
|
-
|
|
5841
|
+
$ECHO
|
|
5842
|
+
$ECHO "*** However, this would only work if libtool was able to extract symbol"
|
|
5843
|
+
$ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
|
|
5844
|
+
$ECHO "*** not find such a program. So, this module is probably useless."
|
|
5845
|
+
$ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
|
|
6170
5846
|
fi
|
|
6171
5847
|
if test "$build_old_libs" = no; then
|
|
6172
5848
|
build_libtool_libs=module
|
|
@@ -6286,7 +5962,7 @@ func_mode_link ()
|
|
|
6286
5962
|
compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
|
|
6287
5963
|
finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
|
|
6288
5964
|
else
|
|
6289
|
-
compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $
|
|
5965
|
+
compiler_flags="$compiler_flags "`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
6290
5966
|
fi
|
|
6291
5967
|
fi
|
|
6292
5968
|
dependency_libs="$newdependency_libs"
|
|
@@ -6454,7 +6130,7 @@ func_mode_link ()
|
|
|
6454
6130
|
if test "$deplibs_check_method" != pass_all; then
|
|
6455
6131
|
func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
|
|
6456
6132
|
else
|
|
6457
|
-
|
|
6133
|
+
$ECHO
|
|
6458
6134
|
$ECHO "*** Warning: Linking the shared library $output against the non-libtool"
|
|
6459
6135
|
$ECHO "*** objects $objs is not portable!"
|
|
6460
6136
|
libobjs="$libobjs $objs"
|
|
@@ -6522,7 +6198,7 @@ func_mode_link ()
|
|
|
6522
6198
|
age="$number_minor"
|
|
6523
6199
|
revision="$number_revision"
|
|
6524
6200
|
;;
|
|
6525
|
-
freebsd-aout|freebsd-elf|
|
|
6201
|
+
freebsd-aout|freebsd-elf|sunos)
|
|
6526
6202
|
current="$number_major"
|
|
6527
6203
|
revision="$number_minor"
|
|
6528
6204
|
age="0"
|
|
@@ -6534,6 +6210,9 @@ func_mode_link ()
|
|
|
6534
6210
|
revision="$number_minor"
|
|
6535
6211
|
lt_irix_increment=no
|
|
6536
6212
|
;;
|
|
6213
|
+
*)
|
|
6214
|
+
func_fatal_configuration "$modename: unknown library version type \`$version_type'"
|
|
6215
|
+
;;
|
|
6537
6216
|
esac
|
|
6538
6217
|
;;
|
|
6539
6218
|
no)
|
|
@@ -6756,14 +6435,14 @@ func_mode_link ()
|
|
|
6756
6435
|
oldlibs="$oldlibs $output_objdir/$libname.$libext"
|
|
6757
6436
|
|
|
6758
6437
|
# Transform .lo files to .o files.
|
|
6759
|
-
oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $
|
|
6438
|
+
oldobjs="$objs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP`
|
|
6760
6439
|
fi
|
|
6761
6440
|
|
|
6762
6441
|
# Eliminate all temporary directories.
|
|
6763
6442
|
#for path in $notinst_path; do
|
|
6764
|
-
# lib_search_path=`$ECHO "$lib_search_path " | $
|
|
6765
|
-
# deplibs=`$ECHO "$deplibs " | $
|
|
6766
|
-
# dependency_libs=`$ECHO "$dependency_libs " | $
|
|
6443
|
+
# lib_search_path=`$ECHO "X$lib_search_path " | $Xsed -e "s% $path % %g"`
|
|
6444
|
+
# deplibs=`$ECHO "X$deplibs " | $Xsed -e "s% -L$path % %g"`
|
|
6445
|
+
# dependency_libs=`$ECHO "X$dependency_libs " | $Xsed -e "s% -L$path % %g"`
|
|
6767
6446
|
#done
|
|
6768
6447
|
|
|
6769
6448
|
if test -n "$xrpath"; then
|
|
@@ -6804,7 +6483,7 @@ func_mode_link ()
|
|
|
6804
6483
|
if test "$build_libtool_libs" = yes; then
|
|
6805
6484
|
if test -n "$rpath"; then
|
|
6806
6485
|
case $host in
|
|
6807
|
-
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc*
|
|
6486
|
+
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc*)
|
|
6808
6487
|
# these systems don't actually have a c library (as such)!
|
|
6809
6488
|
;;
|
|
6810
6489
|
*-*-rhapsody* | *-*-darwin1.[012])
|
|
@@ -6889,13 +6568,13 @@ EOF
|
|
|
6889
6568
|
newdeplibs="$newdeplibs $i"
|
|
6890
6569
|
else
|
|
6891
6570
|
droppeddeps=yes
|
|
6892
|
-
|
|
6571
|
+
$ECHO
|
|
6893
6572
|
$ECHO "*** Warning: dynamic linker does not accept needed library $i."
|
|
6894
|
-
|
|
6895
|
-
|
|
6896
|
-
|
|
6897
|
-
|
|
6898
|
-
|
|
6573
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
6574
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
6575
|
+
$ECHO "*** shared version of the library, which I believe you do not have"
|
|
6576
|
+
$ECHO "*** because a test_compile did reveal that the linker did not use it for"
|
|
6577
|
+
$ECHO "*** its dynamic dependency list that programs get resolved with at runtime."
|
|
6899
6578
|
fi
|
|
6900
6579
|
fi
|
|
6901
6580
|
;;
|
|
@@ -6932,22 +6611,22 @@ EOF
|
|
|
6932
6611
|
newdeplibs="$newdeplibs $i"
|
|
6933
6612
|
else
|
|
6934
6613
|
droppeddeps=yes
|
|
6935
|
-
|
|
6614
|
+
$ECHO
|
|
6936
6615
|
$ECHO "*** Warning: dynamic linker does not accept needed library $i."
|
|
6937
|
-
|
|
6938
|
-
|
|
6939
|
-
|
|
6940
|
-
|
|
6941
|
-
|
|
6616
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
6617
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
6618
|
+
$ECHO "*** shared version of the library, which you do not appear to have"
|
|
6619
|
+
$ECHO "*** because a test_compile did reveal that the linker did not use this one"
|
|
6620
|
+
$ECHO "*** as a dynamic dependency that programs can get resolved with at runtime."
|
|
6942
6621
|
fi
|
|
6943
6622
|
fi
|
|
6944
6623
|
else
|
|
6945
6624
|
droppeddeps=yes
|
|
6946
|
-
|
|
6625
|
+
$ECHO
|
|
6947
6626
|
$ECHO "*** Warning! Library $i is needed by this library but I was not able to"
|
|
6948
|
-
|
|
6949
|
-
|
|
6950
|
-
|
|
6627
|
+
$ECHO "*** make it link in! You will probably need to install it or some"
|
|
6628
|
+
$ECHO "*** library that it depends on before this library will be fully"
|
|
6629
|
+
$ECHO "*** functional. Installing it before continuing would be even better."
|
|
6951
6630
|
fi
|
|
6952
6631
|
;;
|
|
6953
6632
|
*)
|
|
@@ -6993,7 +6672,7 @@ EOF
|
|
|
6993
6672
|
potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
|
|
6994
6673
|
case $potliblink in
|
|
6995
6674
|
[\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
|
|
6996
|
-
*) potlib=`$ECHO "$potlib" | $
|
|
6675
|
+
*) potlib=`$ECHO "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";;
|
|
6997
6676
|
esac
|
|
6998
6677
|
done
|
|
6999
6678
|
if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
|
|
@@ -7008,12 +6687,12 @@ EOF
|
|
|
7008
6687
|
fi
|
|
7009
6688
|
if test -n "$a_deplib" ; then
|
|
7010
6689
|
droppeddeps=yes
|
|
7011
|
-
|
|
6690
|
+
$ECHO
|
|
7012
6691
|
$ECHO "*** Warning: linker path does not have real file for library $a_deplib."
|
|
7013
|
-
|
|
7014
|
-
|
|
7015
|
-
|
|
7016
|
-
|
|
6692
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
6693
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
6694
|
+
$ECHO "*** shared version of the library, which you do not appear to have"
|
|
6695
|
+
$ECHO "*** because I did check the linker path looking for a file starting"
|
|
7017
6696
|
if test -z "$potlib" ; then
|
|
7018
6697
|
$ECHO "*** with $libname but no candidates were found. (...for file magic test)"
|
|
7019
6698
|
else
|
|
@@ -7051,7 +6730,7 @@ EOF
|
|
|
7051
6730
|
potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
|
|
7052
6731
|
for potent_lib in $potential_libs; do
|
|
7053
6732
|
potlib="$potent_lib" # see symlink-check above in file_magic test
|
|
7054
|
-
if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $
|
|
6733
|
+
if eval "\$ECHO \"X$potent_lib\"" 2>/dev/null | $Xsed -e 10q | \
|
|
7055
6734
|
$EGREP "$match_pattern_regex" > /dev/null; then
|
|
7056
6735
|
newdeplibs="$newdeplibs $a_deplib"
|
|
7057
6736
|
a_deplib=""
|
|
@@ -7062,12 +6741,12 @@ EOF
|
|
|
7062
6741
|
fi
|
|
7063
6742
|
if test -n "$a_deplib" ; then
|
|
7064
6743
|
droppeddeps=yes
|
|
7065
|
-
|
|
6744
|
+
$ECHO
|
|
7066
6745
|
$ECHO "*** Warning: linker path does not have real file for library $a_deplib."
|
|
7067
|
-
|
|
7068
|
-
|
|
7069
|
-
|
|
7070
|
-
|
|
6746
|
+
$ECHO "*** I have the capability to make that library automatically link in when"
|
|
6747
|
+
$ECHO "*** you link to this library. But I can only do this if you have a"
|
|
6748
|
+
$ECHO "*** shared version of the library, which you do not appear to have"
|
|
6749
|
+
$ECHO "*** because I did check the linker path looking for a file starting"
|
|
7071
6750
|
if test -z "$potlib" ; then
|
|
7072
6751
|
$ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
|
|
7073
6752
|
else
|
|
@@ -7085,25 +6764,25 @@ EOF
|
|
|
7085
6764
|
;;
|
|
7086
6765
|
none | unknown | *)
|
|
7087
6766
|
newdeplibs=""
|
|
7088
|
-
tmp_deplibs=`$ECHO " $deplibs" | $
|
|
6767
|
+
tmp_deplibs=`$ECHO "X $deplibs" | $Xsed \
|
|
6768
|
+
-e 's/ -lc$//' -e 's/ -[LR][^ ]*//g'`
|
|
7089
6769
|
if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
|
|
7090
6770
|
for i in $predeps $postdeps ; do
|
|
7091
6771
|
# can't use Xsed below, because $i might contain '/'
|
|
7092
|
-
tmp_deplibs=`$ECHO " $tmp_deplibs" | $
|
|
6772
|
+
tmp_deplibs=`$ECHO "X $tmp_deplibs" | $Xsed -e "s,$i,,"`
|
|
7093
6773
|
done
|
|
7094
6774
|
fi
|
|
7095
|
-
|
|
7096
|
-
|
|
7097
|
-
|
|
6775
|
+
if $ECHO "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' |
|
|
6776
|
+
$GREP . >/dev/null; then
|
|
6777
|
+
$ECHO
|
|
7098
6778
|
if test "X$deplibs_check_method" = "Xnone"; then
|
|
7099
|
-
|
|
6779
|
+
$ECHO "*** Warning: inter-library dependencies are not supported in this platform."
|
|
7100
6780
|
else
|
|
7101
|
-
|
|
6781
|
+
$ECHO "*** Warning: inter-library dependencies are not known to be supported."
|
|
7102
6782
|
fi
|
|
7103
|
-
|
|
6783
|
+
$ECHO "*** All declared inter-library dependencies are being dropped."
|
|
7104
6784
|
droppeddeps=yes
|
|
7105
|
-
|
|
7106
|
-
esac
|
|
6785
|
+
fi
|
|
7107
6786
|
;;
|
|
7108
6787
|
esac
|
|
7109
6788
|
versuffix=$versuffix_save
|
|
@@ -7115,23 +6794,23 @@ EOF
|
|
|
7115
6794
|
case $host in
|
|
7116
6795
|
*-*-rhapsody* | *-*-darwin1.[012])
|
|
7117
6796
|
# On Rhapsody replace the C library with the System framework
|
|
7118
|
-
newdeplibs=`$ECHO " $newdeplibs" | $
|
|
6797
|
+
newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
|
|
7119
6798
|
;;
|
|
7120
6799
|
esac
|
|
7121
6800
|
|
|
7122
6801
|
if test "$droppeddeps" = yes; then
|
|
7123
6802
|
if test "$module" = yes; then
|
|
7124
|
-
|
|
7125
|
-
|
|
6803
|
+
$ECHO
|
|
6804
|
+
$ECHO "*** Warning: libtool could not satisfy all declared inter-library"
|
|
7126
6805
|
$ECHO "*** dependencies of module $libname. Therefore, libtool will create"
|
|
7127
|
-
|
|
7128
|
-
|
|
6806
|
+
$ECHO "*** a static module, that should work as long as the dlopening"
|
|
6807
|
+
$ECHO "*** application is linked with the -dlopen flag."
|
|
7129
6808
|
if test -z "$global_symbol_pipe"; then
|
|
7130
|
-
|
|
7131
|
-
|
|
7132
|
-
|
|
7133
|
-
|
|
7134
|
-
|
|
6809
|
+
$ECHO
|
|
6810
|
+
$ECHO "*** However, this would only work if libtool was able to extract symbol"
|
|
6811
|
+
$ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
|
|
6812
|
+
$ECHO "*** not find such a program. So, this module is probably useless."
|
|
6813
|
+
$ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
|
|
7135
6814
|
fi
|
|
7136
6815
|
if test "$build_old_libs" = no; then
|
|
7137
6816
|
oldlibs="$output_objdir/$libname.$libext"
|
|
@@ -7141,16 +6820,16 @@ EOF
|
|
|
7141
6820
|
build_libtool_libs=no
|
|
7142
6821
|
fi
|
|
7143
6822
|
else
|
|
7144
|
-
|
|
7145
|
-
|
|
7146
|
-
|
|
6823
|
+
$ECHO "*** The inter-library dependencies that have been dropped here will be"
|
|
6824
|
+
$ECHO "*** automatically added whenever a program is linked with this library"
|
|
6825
|
+
$ECHO "*** or is declared to -dlopen it."
|
|
7147
6826
|
|
|
7148
6827
|
if test "$allow_undefined" = no; then
|
|
7149
|
-
|
|
7150
|
-
|
|
7151
|
-
|
|
7152
|
-
|
|
7153
|
-
|
|
6828
|
+
$ECHO
|
|
6829
|
+
$ECHO "*** Since this library must not contain undefined symbols,"
|
|
6830
|
+
$ECHO "*** because either the platform does not support them or"
|
|
6831
|
+
$ECHO "*** it was explicitly requested with -no-undefined,"
|
|
6832
|
+
$ECHO "*** libtool will only create a static version of it."
|
|
7154
6833
|
if test "$build_old_libs" = no; then
|
|
7155
6834
|
oldlibs="$output_objdir/$libname.$libext"
|
|
7156
6835
|
build_libtool_libs=module
|
|
@@ -7167,9 +6846,9 @@ EOF
|
|
|
7167
6846
|
# Time to change all our "foo.ltframework" stuff back to "-framework foo"
|
|
7168
6847
|
case $host in
|
|
7169
6848
|
*-*-darwin*)
|
|
7170
|
-
newdeplibs=`$ECHO " $newdeplibs" | $
|
|
7171
|
-
new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $
|
|
7172
|
-
deplibs=`$ECHO " $deplibs" | $
|
|
6849
|
+
newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
6850
|
+
new_inherited_linker_flags=`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
6851
|
+
deplibs=`$ECHO "X $deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
7173
6852
|
;;
|
|
7174
6853
|
esac
|
|
7175
6854
|
|
|
@@ -7291,7 +6970,7 @@ EOF
|
|
|
7291
6970
|
done
|
|
7292
6971
|
|
|
7293
6972
|
# Use standard objects if they are pic
|
|
7294
|
-
test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $
|
|
6973
|
+
test -z "$pic_flag" && libobjs=`$ECHO "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
|
|
7295
6974
|
test "X$libobjs" = "X " && libobjs=
|
|
7296
6975
|
|
|
7297
6976
|
delfiles=
|
|
@@ -7357,7 +7036,7 @@ EOF
|
|
|
7357
7036
|
if test -n "$export_symbols" && test -n "$include_expsyms"; then
|
|
7358
7037
|
tmp_export_symbols="$export_symbols"
|
|
7359
7038
|
test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
|
|
7360
|
-
$opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
|
|
7039
|
+
$opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
|
|
7361
7040
|
fi
|
|
7362
7041
|
|
|
7363
7042
|
if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
|
|
@@ -7458,8 +7137,7 @@ EOF
|
|
|
7458
7137
|
save_libobjs=$libobjs
|
|
7459
7138
|
fi
|
|
7460
7139
|
save_output=$output
|
|
7461
|
-
|
|
7462
|
-
output_la=$func_basename_result
|
|
7140
|
+
output_la=`$ECHO "X$output" | $Xsed -e "$basename"`
|
|
7463
7141
|
|
|
7464
7142
|
# Clear the reloadable object creation command queue and
|
|
7465
7143
|
# initialize k to one.
|
|
@@ -7472,12 +7150,12 @@ EOF
|
|
|
7472
7150
|
if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
|
|
7473
7151
|
output=${output_objdir}/${output_la}.lnkscript
|
|
7474
7152
|
func_verbose "creating GNU ld script: $output"
|
|
7475
|
-
|
|
7153
|
+
$ECHO 'INPUT (' > $output
|
|
7476
7154
|
for obj in $save_libobjs
|
|
7477
7155
|
do
|
|
7478
7156
|
$ECHO "$obj" >> $output
|
|
7479
7157
|
done
|
|
7480
|
-
|
|
7158
|
+
$ECHO ')' >> $output
|
|
7481
7159
|
delfiles="$delfiles $output"
|
|
7482
7160
|
elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
|
|
7483
7161
|
output=${output_objdir}/${output_la}.lnk
|
|
@@ -7519,19 +7197,17 @@ EOF
|
|
|
7519
7197
|
# command to the queue.
|
|
7520
7198
|
if test "$k" -eq 1 ; then
|
|
7521
7199
|
# The first file doesn't have a previous command to add.
|
|
7522
|
-
|
|
7523
|
-
eval concat_cmds=\"$reload_cmds\"
|
|
7200
|
+
eval concat_cmds=\"$reload_cmds $objlist $last_robj\"
|
|
7524
7201
|
else
|
|
7525
7202
|
# All subsequent reloadable object files will link in
|
|
7526
7203
|
# the last one created.
|
|
7527
|
-
|
|
7528
|
-
eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
|
|
7204
|
+
eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj~\$RM $last_robj\"
|
|
7529
7205
|
fi
|
|
7530
7206
|
last_robj=$output_objdir/$output_la-${k}.$objext
|
|
7531
7207
|
func_arith $k + 1
|
|
7532
7208
|
k=$func_arith_result
|
|
7533
7209
|
output=$output_objdir/$output_la-${k}.$objext
|
|
7534
|
-
objlist
|
|
7210
|
+
objlist=$obj
|
|
7535
7211
|
func_len " $last_robj"
|
|
7536
7212
|
func_arith $len0 + $func_len_result
|
|
7537
7213
|
len=$func_arith_result
|
|
@@ -7541,8 +7217,7 @@ EOF
|
|
|
7541
7217
|
# reloadable object file. All subsequent reloadable object
|
|
7542
7218
|
# files will link in the last one created.
|
|
7543
7219
|
test -z "$concat_cmds" || concat_cmds=$concat_cmds~
|
|
7544
|
-
|
|
7545
|
-
eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
|
|
7220
|
+
eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\"
|
|
7546
7221
|
if test -n "$last_robj"; then
|
|
7547
7222
|
eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
|
|
7548
7223
|
fi
|
|
@@ -7601,7 +7276,7 @@ EOF
|
|
|
7601
7276
|
if test -n "$export_symbols" && test -n "$include_expsyms"; then
|
|
7602
7277
|
tmp_export_symbols="$export_symbols"
|
|
7603
7278
|
test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
|
|
7604
|
-
$opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
|
|
7279
|
+
$opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
|
|
7605
7280
|
fi
|
|
7606
7281
|
|
|
7607
7282
|
if test -n "$orig_export_symbols"; then
|
|
@@ -7766,7 +7441,7 @@ EOF
|
|
|
7766
7441
|
if test -n "$convenience"; then
|
|
7767
7442
|
if test -n "$whole_archive_flag_spec"; then
|
|
7768
7443
|
eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
|
|
7769
|
-
reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $
|
|
7444
|
+
reload_conv_objs=$reload_objs\ `$ECHO "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'`
|
|
7770
7445
|
else
|
|
7771
7446
|
gentop="$output_objdir/${obj}x"
|
|
7772
7447
|
generated="$generated $gentop"
|
|
@@ -7777,7 +7452,7 @@ EOF
|
|
|
7777
7452
|
fi
|
|
7778
7453
|
|
|
7779
7454
|
# Create the old-style object.
|
|
7780
|
-
reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $
|
|
7455
|
+
reload_objs="$objs$old_deplibs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
|
|
7781
7456
|
|
|
7782
7457
|
output="$obj"
|
|
7783
7458
|
func_execute_cmds "$reload_cmds" 'exit $?'
|
|
@@ -7837,8 +7512,8 @@ EOF
|
|
|
7837
7512
|
case $host in
|
|
7838
7513
|
*-*-rhapsody* | *-*-darwin1.[012])
|
|
7839
7514
|
# On Rhapsody replace the C library is the System framework
|
|
7840
|
-
compile_deplibs=`$ECHO " $compile_deplibs" | $
|
|
7841
|
-
finalize_deplibs=`$ECHO " $finalize_deplibs" | $
|
|
7515
|
+
compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
|
|
7516
|
+
finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
|
|
7842
7517
|
;;
|
|
7843
7518
|
esac
|
|
7844
7519
|
|
|
@@ -7855,8 +7530,8 @@ EOF
|
|
|
7855
7530
|
esac
|
|
7856
7531
|
fi
|
|
7857
7532
|
# Time to change all our "foo.ltframework" stuff back to "-framework foo"
|
|
7858
|
-
compile_deplibs=`$ECHO " $compile_deplibs" | $
|
|
7859
|
-
finalize_deplibs=`$ECHO " $finalize_deplibs" | $
|
|
7533
|
+
compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
7534
|
+
finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
|
|
7860
7535
|
;;
|
|
7861
7536
|
esac
|
|
7862
7537
|
|
|
@@ -7993,8 +7668,8 @@ EOF
|
|
|
7993
7668
|
|
|
7994
7669
|
if test -n "$libobjs" && test "$build_old_libs" = yes; then
|
|
7995
7670
|
# Transform all the library objects into standard objects.
|
|
7996
|
-
compile_command=`$ECHO "$compile_command" | $SP2NL | $
|
|
7997
|
-
finalize_command=`$ECHO "$finalize_command" | $SP2NL | $
|
|
7671
|
+
compile_command=`$ECHO "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
|
|
7672
|
+
finalize_command=`$ECHO "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
|
|
7998
7673
|
fi
|
|
7999
7674
|
|
|
8000
7675
|
func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
|
|
@@ -8006,15 +7681,15 @@ EOF
|
|
|
8006
7681
|
|
|
8007
7682
|
wrappers_required=yes
|
|
8008
7683
|
case $host in
|
|
8009
|
-
*cegcc* | *mingw32ce*)
|
|
8010
|
-
# Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway.
|
|
8011
|
-
wrappers_required=no
|
|
8012
|
-
;;
|
|
8013
7684
|
*cygwin* | *mingw* )
|
|
8014
7685
|
if test "$build_libtool_libs" != yes; then
|
|
8015
7686
|
wrappers_required=no
|
|
8016
7687
|
fi
|
|
8017
7688
|
;;
|
|
7689
|
+
*cegcc)
|
|
7690
|
+
# Disable wrappers for cegcc, we are cross compiling anyway.
|
|
7691
|
+
wrappers_required=no
|
|
7692
|
+
;;
|
|
8018
7693
|
*)
|
|
8019
7694
|
if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
|
|
8020
7695
|
wrappers_required=no
|
|
@@ -8023,7 +7698,7 @@ EOF
|
|
|
8023
7698
|
esac
|
|
8024
7699
|
if test "$wrappers_required" = no; then
|
|
8025
7700
|
# Replace the output file specification.
|
|
8026
|
-
compile_command=`$ECHO "$compile_command" | $
|
|
7701
|
+
compile_command=`$ECHO "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
|
|
8027
7702
|
link_command="$compile_command$compile_rpath"
|
|
8028
7703
|
|
|
8029
7704
|
# We have no uninstalled library dependencies, so finalize right now.
|
|
@@ -8070,7 +7745,7 @@ EOF
|
|
|
8070
7745
|
# We don't need to create a wrapper script.
|
|
8071
7746
|
link_command="$compile_var$compile_command$compile_rpath"
|
|
8072
7747
|
# Replace the output file specification.
|
|
8073
|
-
link_command=`$ECHO "$link_command" | $
|
|
7748
|
+
link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
|
|
8074
7749
|
# Delete the old output file.
|
|
8075
7750
|
$opt_dry_run || $RM $output
|
|
8076
7751
|
# Link the executable and exit
|
|
@@ -8089,7 +7764,7 @@ EOF
|
|
|
8089
7764
|
if test "$fast_install" != no; then
|
|
8090
7765
|
link_command="$finalize_var$compile_command$finalize_rpath"
|
|
8091
7766
|
if test "$fast_install" = yes; then
|
|
8092
|
-
relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $
|
|
7767
|
+
relink_command=`$ECHO "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'`
|
|
8093
7768
|
else
|
|
8094
7769
|
# fast_install is set to needless
|
|
8095
7770
|
relink_command=
|
|
@@ -8101,7 +7776,7 @@ EOF
|
|
|
8101
7776
|
fi
|
|
8102
7777
|
|
|
8103
7778
|
# Replace the output file specification.
|
|
8104
|
-
link_command=`$ECHO "$link_command" | $
|
|
7779
|
+
link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
|
|
8105
7780
|
|
|
8106
7781
|
# Delete the old output files.
|
|
8107
7782
|
$opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname
|
|
@@ -8125,7 +7800,18 @@ EOF
|
|
|
8125
7800
|
fi
|
|
8126
7801
|
done
|
|
8127
7802
|
relink_command="(cd `pwd`; $relink_command)"
|
|
8128
|
-
relink_command=`$ECHO "$relink_command" | $
|
|
7803
|
+
relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
|
|
7804
|
+
fi
|
|
7805
|
+
|
|
7806
|
+
# Quote $ECHO for shipping.
|
|
7807
|
+
if test "X$ECHO" = "X$SHELL $progpath --fallback-echo"; then
|
|
7808
|
+
case $progpath in
|
|
7809
|
+
[\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";;
|
|
7810
|
+
*) qecho="$SHELL `pwd`/$progpath --fallback-echo";;
|
|
7811
|
+
esac
|
|
7812
|
+
qecho=`$ECHO "X$qecho" | $Xsed -e "$sed_quote_subst"`
|
|
7813
|
+
else
|
|
7814
|
+
qecho=`$ECHO "X$ECHO" | $Xsed -e "$sed_quote_subst"`
|
|
8129
7815
|
fi
|
|
8130
7816
|
|
|
8131
7817
|
# Only actually do things if not in dry run mode.
|
|
@@ -8246,7 +7932,7 @@ EOF
|
|
|
8246
7932
|
done | sort | sort -uc >/dev/null 2>&1); then
|
|
8247
7933
|
:
|
|
8248
7934
|
else
|
|
8249
|
-
|
|
7935
|
+
$ECHO "copying selected object files to avoid basename conflicts..."
|
|
8250
7936
|
gentop="$output_objdir/${outputname}x"
|
|
8251
7937
|
generated="$generated $gentop"
|
|
8252
7938
|
func_mkdir_p "$gentop"
|
|
@@ -8357,7 +8043,7 @@ EOF
|
|
|
8357
8043
|
done
|
|
8358
8044
|
# Quote the link command for shipping.
|
|
8359
8045
|
relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
|
|
8360
|
-
relink_command=`$ECHO "$relink_command" | $
|
|
8046
|
+
relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
|
|
8361
8047
|
if test "$hardcode_automatic" = yes ; then
|
|
8362
8048
|
relink_command=
|
|
8363
8049
|
fi
|
|
@@ -8442,27 +8128,9 @@ EOF
|
|
|
8442
8128
|
fi
|
|
8443
8129
|
$RM $output
|
|
8444
8130
|
# place dlname in correct position for cygwin
|
|
8445
|
-
# In fact, it would be nice if we could use this code for all target
|
|
8446
|
-
# systems that can't hard-code library paths into their executables
|
|
8447
|
-
# and that have no shared library path variable independent of PATH,
|
|
8448
|
-
# but it turns out we can't easily determine that from inspecting
|
|
8449
|
-
# libtool variables, so we have to hard-code the OSs to which it
|
|
8450
|
-
# applies here; at the moment, that means platforms that use the PE
|
|
8451
|
-
# object format with DLL files. See the long comment at the top of
|
|
8452
|
-
# tests/bindir.at for full details.
|
|
8453
8131
|
tdlname=$dlname
|
|
8454
8132
|
case $host,$output,$installed,$module,$dlname in
|
|
8455
|
-
*cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll)
|
|
8456
|
-
# If a -bindir argument was supplied, place the dll there.
|
|
8457
|
-
if test "x$bindir" != x ;
|
|
8458
|
-
then
|
|
8459
|
-
func_relative_path "$install_libdir" "$bindir"
|
|
8460
|
-
tdlname=$func_relative_path_result$dlname
|
|
8461
|
-
else
|
|
8462
|
-
# Otherwise fall back on heuristic.
|
|
8463
|
-
tdlname=../bin/$dlname
|
|
8464
|
-
fi
|
|
8465
|
-
;;
|
|
8133
|
+
*cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;;
|
|
8466
8134
|
esac
|
|
8467
8135
|
$ECHO > $output "\
|
|
8468
8136
|
# $outputname - a libtool library file
|